hexsha
stringlengths
40
40
size
int64
2
1.02M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
245
max_stars_repo_name
stringlengths
6
130
max_stars_repo_head_hexsha
stringlengths
40
40
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
⌀
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
⌀
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
⌀
max_issues_repo_path
stringlengths
4
245
max_issues_repo_name
stringlengths
6
130
max_issues_repo_head_hexsha
stringlengths
40
40
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
67k
⌀
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
⌀
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
⌀
max_forks_repo_path
stringlengths
4
245
max_forks_repo_name
stringlengths
6
130
max_forks_repo_head_hexsha
stringlengths
40
40
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
⌀
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
⌀
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
⌀
content
stringlengths
2
1.02M
avg_line_length
float64
1
958k
max_line_length
int64
1
987k
alphanum_fraction
float64
0
1
content_no_comment
stringlengths
0
1.01M
is_comment_constant_removed
bool
2 classes
is_sharp_comment_removed
bool
1 class
f778257019c2a00e2dfe63384f77dc7c71027378
39,882
py
Python
discord/ext/test/backend.py
KoalaBotUK/testcord
124d2ad9aa8359e5b24c9db2e9d6d00c89d73b8d
[ "MIT" ]
null
null
null
discord/ext/test/backend.py
KoalaBotUK/testcord
124d2ad9aa8359e5b24c9db2e9d6d00c89d73b8d
[ "MIT" ]
7
2022-01-20T08:37:08.000Z
2022-01-20T18:15:25.000Z
discord/ext/test/backend.py
KoalaBotUK/testcord
124d2ad9aa8359e5b24c9db2e9d6d00c89d73b8d
[ "MIT" ]
null
null
null
""" Module for 'server-side' state during testing. This module should contain methods for altering said server-side state, which then are responsible for triggering a ``parse_*`` call in the configured client state to inform the bot of the change. This setup matches discord's actual setup, where an HTT...
36.190563
120
0.636778
import asyncio import sys import logging import re import typing import datetime import discord from discord.errors import NotFound, Forbidden import discord.http as dhttp from discord.types import embed, message, components, sticker from discord.types.snowflake import Snowflake import pathlib import urllib.parse impo...
true
true
f778266c1911daa444c506acdcc06fcdc235a04d
3,478
py
Python
src/jbdl/experimental/contact/solve_contact_simple_lcp.py
yz-mao/jbdl
a5380233b3795c8aaa9acd9e5c07fa44f8a5dadb
[ "MIT" ]
21
2021-08-29T06:59:18.000Z
2022-01-13T22:53:02.000Z
src/jbdl/experimental/contact/solve_contact_simple_lcp.py
yz-mao/jbdl
a5380233b3795c8aaa9acd9e5c07fa44f8a5dadb
[ "MIT" ]
2
2021-08-31T08:34:09.000Z
2021-09-06T07:40:51.000Z
src/jbdl/experimental/contact/solve_contact_simple_lcp.py
yz-mao/jbdl
a5380233b3795c8aaa9acd9e5c07fa44f8a5dadb
[ "MIT" ]
4
2021-08-29T06:59:22.000Z
2021-10-04T05:59:41.000Z
import numpy as np from jbdl.experimental.contact import calc_contact_jacobian_core from jbdl.experimental.contact.calc_contact_jacobian import calc_contact_jacobian_core_jit_flag from jbdl.experimental.contact.calc_contact_jdot_qdot import calc_contact_jdot_qdot_core from jbdl.experimental.contact.calc_contact_jdot_qd...
35.489796
118
0.677688
import numpy as np from jbdl.experimental.contact import calc_contact_jacobian_core from jbdl.experimental.contact.calc_contact_jacobian import calc_contact_jacobian_core_jit_flag from jbdl.experimental.contact.calc_contact_jdot_qdot import calc_contact_jdot_qdot_core from jbdl.experimental.contact.calc_contact_jdot_qd...
true
true
f77826d842f28c948c1b2ae2ad92c8c5be2c5878
3,456
py
Python
kernel/examples/handler/component/horz_nn.py
rinceyuan/WeFe
8482cb737cb7ba37b2856d184cd42c1bd35a6318
[ "Apache-2.0" ]
39
2021-10-12T01:43:27.000Z
2022-03-28T04:46:35.000Z
kernel/examples/handler/component/horz_nn.py
rinceyuan/WeFe
8482cb737cb7ba37b2856d184cd42c1bd35a6318
[ "Apache-2.0" ]
6
2021-10-14T02:11:47.000Z
2022-03-23T02:41:50.000Z
kernel/examples/handler/component/horz_nn.py
rinceyuan/WeFe
8482cb737cb7ba37b2856d184cd42c1bd35a6318
[ "Apache-2.0" ]
10
2021-10-14T09:36:03.000Z
2022-02-10T11:05:12.000Z
# Copyright 2021 Tianmian Tech. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable la...
38.831461
77
0.703704
from kernel.examples.handler.component.component_base import Component from kernel.examples.handler.component.nn.models.sequantial import Sequential from kernel.examples.handler.interface import Input from kernel.examples.handler.interface import Output from kernel.examples.handler.utils.tools import extract_explicit...
true
true
f77828062db09dc6464e097da23c7bf0090522db
6,448
py
Python
scarlet/cache/groups.py
ff0000/scarlet
6c37befd810916a2d7ffff2cdb2dab57bcb6d12e
[ "MIT" ]
9
2015-10-13T04:35:56.000Z
2017-03-16T19:00:44.000Z
scarlet/cache/groups.py
ff0000/scarlet
6c37befd810916a2d7ffff2cdb2dab57bcb6d12e
[ "MIT" ]
32
2015-02-10T21:09:18.000Z
2017-07-18T20:26:51.000Z
scarlet/cache/groups.py
ff0000/scarlet
6c37befd810916a2d7ffff2cdb2dab57bcb6d12e
[ "MIT" ]
3
2017-07-13T13:32:21.000Z
2019-04-08T20:18:58.000Z
import router class CacheConfig(object): ALL = 'all' return_all = False def __init__(self, values, instance_values): self.values = values and values or [] self.instance_values = instance_values and instance_values or [] class CacheGroup(object): """ Tracks versions for a collecti...
33.066667
78
0.605924
import router class CacheConfig(object): ALL = 'all' return_all = False def __init__(self, values, instance_values): self.values = values and values or [] self.instance_values = instance_values and instance_values or [] class CacheGroup(object): def __init__(self, key=None, version_...
true
true
f77829659698d051037c2d44cbacc57cd5090796
16,247
py
Python
unoletutils/libs_old/report/generic.py
wilmerm/unolet-2022
18119a9381b763e38c888bafdb7f97028bd80ea1
[ "BSD-3-Clause" ]
null
null
null
unoletutils/libs_old/report/generic.py
wilmerm/unolet-2022
18119a9381b763e38c888bafdb7f97028bd80ea1
[ "BSD-3-Clause" ]
null
null
null
unoletutils/libs_old/report/generic.py
wilmerm/unolet-2022
18119a9381b763e38c888bafdb7f97028bd80ea1
[ "BSD-3-Clause" ]
null
null
null
""" Reportes genéricos, preconfigurados para su uso. """ from django import forms from django.utils.translation import gettext as _ from django.urls import reverse_lazy from fuente import var from fuente.report.base import (Report, ModelReport, ReportDoesNotExist, ReportLocked, Total, TotalFor) from fue...
33.707469
88
0.582077
from django import forms from django.utils.translation import gettext as _ from django.urls import reverse_lazy from fuente import var from fuente.report.base import (Report, ModelReport, ReportDoesNotExist, ReportLocked, Total, TotalFor) from fuente.report.fields import (TextField, IntegerField, FloatFiel...
true
true
f7782989b70354f8b78cbd30a2d0ed31796aea6e
23,237
py
Python
IPython/utils/text.py
pyarnold/ipython
c4797f7f069d0a974ddfa1e4251c7550c809dba0
[ "BSD-3-Clause-Clear" ]
1
2020-12-18T01:07:55.000Z
2020-12-18T01:07:55.000Z
IPython/utils/text.py
pyarnold/ipython
c4797f7f069d0a974ddfa1e4251c7550c809dba0
[ "BSD-3-Clause-Clear" ]
null
null
null
IPython/utils/text.py
pyarnold/ipython
c4797f7f069d0a974ddfa1e4251c7550c809dba0
[ "BSD-3-Clause-Clear" ]
null
null
null
# encoding: utf-8 """ Utilities for working with strings and text. Inheritance diagram: .. inheritance-diagram:: IPython.utils.text :parts: 3 """ #----------------------------------------------------------------------------- # Copyright (C) 2008-2011 The IPython Development Team # # Distributed under the terms...
29.413924
116
0.554116
import os import re import sys import textwrap from string import Formatter from IPython.external.path import path from IPython.testing.skipdoctest import skip_doctest_py3, skip_doctest from IPython.utils import py3compat if sys.platform == 'win32': date_format = "%B %d, %Y" else: date_format = "%B %-d, %...
true
true
f77829da340095f16330b324fd97cc35e39fe50b
8,362
py
Python
pkgs/applications/office/libreoffice/generate-libreoffice-srcs.py
nicknovitski/nixpkgs
ed8a59f44a8919dc9ad3f281d7e71dae91f5c3e4
[ "MIT" ]
1
2017-10-30T17:22:08.000Z
2017-10-30T17:22:08.000Z
pkgs/applications/office/libreoffice/generate-libreoffice-srcs.py
nicknovitski/nixpkgs
ed8a59f44a8919dc9ad3f281d7e71dae91f5c3e4
[ "MIT" ]
2
2016-09-05T15:25:39.000Z
2017-02-18T09:45:35.000Z
pkgs/applications/office/libreoffice/generate-libreoffice-srcs.py
nicknovitski/nixpkgs
ed8a59f44a8919dc9ad3f281d7e71dae91f5c3e4
[ "MIT" ]
2
2017-10-19T07:38:38.000Z
2018-12-07T15:32:05.000Z
#!/usr/bin/env python3 """ Converts the LibreOffice `download.lst` file into a Nix expression. Requires an environment variable named `downloadList` identifying the path of the input file, and writes the result to stdout. todo - Ideally we would move as much as possible into derivation dependencies. """ import colle...
27.149351
78
0.529299
import collections, itertools, json, re, subprocess, sys, os def main(): packages = list(get_packages()) for x in packages: print(x, file=sys.stderr) print('[') for x in packages: md5 = x['md5'] tarball = x['tarball'] url = construct_url(x) print('url: {}'...
true
true
f7782ac598d2c3b5d810af1705a6a553e91072fd
9,853
py
Python
api-dev/venv/lib/python3.6/site-packages/marshmallow/utils.py
twaddle-dev/CoVid-19
37b1ca12d7ca1a066ab1c0d4a02d9b038d44e62f
[ "Apache-2.0" ]
10
2020-06-28T15:39:28.000Z
2020-07-01T16:20:21.000Z
api-dev/venv/lib/python3.6/site-packages/marshmallow/utils.py
twaddle-dev/CoVid-19
37b1ca12d7ca1a066ab1c0d4a02d9b038d44e62f
[ "Apache-2.0" ]
5
2021-03-10T00:13:51.000Z
2022-03-02T06:26:38.000Z
api-dev/venv/lib/python3.6/site-packages/marshmallow/utils.py
twaddle-dev/CoVid-19
37b1ca12d7ca1a066ab1c0d4a02d9b038d44e62f
[ "Apache-2.0" ]
5
2020-07-16T04:13:01.000Z
2020-10-01T08:19:42.000Z
"""Utility methods for marshmallow.""" import collections import functools import datetime as dt import inspect import json import re import typing from collections.abc import Mapping from email.utils import format_datetime, parsedate_to_datetime from pprint import pprint as py_pprint from marshmallow.base import Fiel...
31.279365
117
0.648229
import collections import functools import datetime as dt import inspect import json import re import typing from collections.abc import Mapping from email.utils import format_datetime, parsedate_to_datetime from pprint import pprint as py_pprint from marshmallow.base import FieldABC from marshmallow.exceptions import...
true
true
f7782d10d8b5a9af340545afb1cf2030109f7ebd
3,456
py
Python
huaweicloud-sdk-cloudide/huaweicloudsdkcloudide/v2/model/delete_instance_response.py
githubmilesma/huaweicloud-sdk-python-v3
9d9449ed68a609ca65f0aa50b5b2a1c28445bf03
[ "Apache-2.0" ]
1
2021-04-16T07:59:28.000Z
2021-04-16T07:59:28.000Z
huaweicloud-sdk-cloudide/huaweicloudsdkcloudide/v2/model/delete_instance_response.py
Lencof/huaweicloud-sdk-python-v3
d13dc4e2830a83e295be6e4de021999b3376e34e
[ "Apache-2.0" ]
null
null
null
huaweicloud-sdk-cloudide/huaweicloudsdkcloudide/v2/model/delete_instance_response.py
Lencof/huaweicloud-sdk-python-v3
d13dc4e2830a83e295be6e4de021999b3376e34e
[ "Apache-2.0" ]
1
2022-01-17T02:24:18.000Z
2022-01-17T02:24:18.000Z
# coding: utf-8 import pprint import re import six from huaweicloudsdkcore.sdk_response import SdkResponse class DeleteInstanceResponse(SdkResponse): """ Attributes: openapi_types (dict): The key is attribute name and the value is attribute type. attribute_map (di...
25.043478
74
0.543981
import pprint import re import six from huaweicloudsdkcore.sdk_response import SdkResponse class DeleteInstanceResponse(SdkResponse): sensitive_list = [] openapi_types = { 'result': 'bool', 'status': 'str' } attribute_map = { 'result': 'result', 'status': 'stat...
true
true
f7782ea18e2bac07c957e9d5830bc8c0e9bbb0b7
1,868
py
Python
fastjsonschema/exceptions.py
giladbarneaallot/python-fastjsonschema
1e5e16bf893ac9549ce69eb01b5d3cda556bd7e4
[ "BSD-3-Clause" ]
null
null
null
fastjsonschema/exceptions.py
giladbarneaallot/python-fastjsonschema
1e5e16bf893ac9549ce69eb01b5d3cda556bd7e4
[ "BSD-3-Clause" ]
null
null
null
fastjsonschema/exceptions.py
giladbarneaallot/python-fastjsonschema
1e5e16bf893ac9549ce69eb01b5d3cda556bd7e4
[ "BSD-3-Clause" ]
null
null
null
import re SPLIT_RE = re.compile(r'[\.\[\]]+') class JsonSchemaException(ValueError): """ Base exception of ``fastjsonschema`` library. """ class JsonSchemaValueException(JsonSchemaException): """ Exception raised by validation function. Available properties: * ``message`` containing huma...
31.133333
139
0.596895
import re SPLIT_RE = re.compile(r'[\.\[\]]+') class JsonSchemaException(ValueError): class JsonSchemaValueException(JsonSchemaException): def __init__(self, message, value=None, name=None, definition=None, rule=None): super().__init__(message) self.message = message self.value = value...
true
true
f778308dab31f88330e871a25c586733e0473634
118,470
py
Python
stubs-legacy/NationalInstruments/Restricted.py
NISystemsEngineering/rpyc-rfmx-remoting
b90c7b84a61a7d063680bcc692bc8c32374291dd
[ "MIT" ]
6
2020-02-20T14:41:14.000Z
2021-04-16T08:09:05.000Z
stubs-legacy/NationalInstruments/Restricted.py
NISystemsEngineering/rpyc-rfmx-remoting
b90c7b84a61a7d063680bcc692bc8c32374291dd
[ "MIT" ]
1
2020-01-06T19:37:49.000Z
2020-02-20T22:44:29.000Z
stubs-legacy/NationalInstruments/Restricted.py
NISystemsEngineering/rpyc-rfmx-remoting
b90c7b84a61a7d063680bcc692bc8c32374291dd
[ "MIT" ]
4
2020-02-27T00:21:08.000Z
2022-03-21T05:23:03.000Z
# encoding: utf-8 # module NationalInstruments.Restricted calls itself Restricted # from NationalInstruments.Common, Version=19.0.40.49152, Culture=neutral, PublicKeyToken=dc6ad606294fc298 # by generator 1.145 # no doc # no imports # functions def IAnalogWaveformService(*args, **kwargs): # real signature unk...
38.240801
429
0.643437
def IAnalogWaveformService(*args, **kwargs): """ """ pass class AssertionConditionAttribute(Attribute, _Attribute): """ AssertionConditionAttribute(conditionType: AssertionConditionType) """ def __init__(self, *args): """ x.__init__(...) initializes x; see x.__class__.__doc__ for si...
false
true
f77831578041197bc6b2432876dd4fa804108e1f
8,412
py
Python
tools/accuracy_checker/accuracy_checker/adapters/attributes_recognition.py
allnes/open_model_zoo
693ba31b3b7671f5fb8ecf8f9b8d670cfec21bc3
[ "Apache-2.0" ]
1
2019-10-31T06:38:49.000Z
2019-10-31T06:38:49.000Z
tools/accuracy_checker/accuracy_checker/adapters/attributes_recognition.py
allnes/open_model_zoo
693ba31b3b7671f5fb8ecf8f9b8d670cfec21bc3
[ "Apache-2.0" ]
6
2020-09-26T01:24:39.000Z
2022-02-10T02:16:03.000Z
tools/accuracy_checker/accuracy_checker/adapters/attributes_recognition.py
allnes/open_model_zoo
693ba31b3b7671f5fb8ecf8f9b8d670cfec21bc3
[ "Apache-2.0" ]
2
2020-10-11T13:47:20.000Z
2021-08-12T08:08:06.000Z
""" Copyright (c) 2019 Intel Corporation Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing,...
39.125581
115
0.670471
import numpy as np from ..adapters import Adapter from ..config import ConfigValidator, StringField from ..representation import ( ContainerPrediction, RegressionPrediction, ClassificationPrediction, FacialLandmarksPrediction, MultiLabelRecognitionPrediction, GazeVectorPrediction ) class HeadP...
true
true
f77832bb6af8bd28183e1f4ed0571806ca9fe8a3
819
py
Python
recipes/engine_tests/functools_partial.py
luci/recipes-py
13b77f0e1dc3e0f15f540679262ce966917c15a3
[ "Apache-2.0" ]
23
2016-01-20T00:45:26.000Z
2022-02-26T04:25:30.000Z
recipes/engine_tests/functools_partial.py
luci/recipes-py
13b77f0e1dc3e0f15f540679262ce966917c15a3
[ "Apache-2.0" ]
8
2016-01-15T19:00:38.000Z
2018-03-06T00:15:24.000Z
recipes/engine_tests/functools_partial.py
luci/recipes-py
13b77f0e1dc3e0f15f540679262ce966917c15a3
[ "Apache-2.0" ]
13
2015-09-05T05:52:43.000Z
2019-07-08T17:34:27.000Z
# Copyright 2021 The LUCI Authors. All rights reserved. # Use of this source code is governed under the Apache License, Version 2.0 # that can be found in the LICENSE file. """Engine shouldn't explode when step_test_data gets functools.partial. This is a regression test for a bug caused by this revision: http://src.c...
30.333333
76
0.733822
import functools from recipe_engine import recipe_test_api PYTHON_VERSION_COMPATIBILITY = 'PY2+3' DEPS = ['step'] def RunSteps(api): api.step('Here\'s a step brah', ['echo', 'steppity', 'doo', 'dah'], step_test_data=functools.partial( lambda x: recipe_test_api.StepTestData(), None)) def...
true
true
f77833f32db20ad30b33b31c71422d01262729e9
495
py
Python
setup.py
cidreixd/webmo-library-python
b08830a7d9589c1e29ae66fdb6d1533eae6db094
[ "MIT" ]
3
2016-10-11T01:09:39.000Z
2019-04-11T06:50:32.000Z
setup.py
cidreixd/webmo-library-python
b08830a7d9589c1e29ae66fdb6d1533eae6db094
[ "MIT" ]
null
null
null
setup.py
cidreixd/webmo-library-python
b08830a7d9589c1e29ae66fdb6d1533eae6db094
[ "MIT" ]
null
null
null
from setuptools import setup setup( name = 'PyWebmo', packages = ['PyWebmo'], version = '0.1', description = 'Webmo client library for Python', author = 'Cidre Interaction Design Inc.', author_email = 'info@cidre.tokyo', url = 'https://github.com/cidreixd/webmo-library-python', download_url = 'https://g...
30.9375
80
0.682828
from setuptools import setup setup( name = 'PyWebmo', packages = ['PyWebmo'], version = '0.1', description = 'Webmo client library for Python', author = 'Cidre Interaction Design Inc.', author_email = 'info@cidre.tokyo', url = 'https://github.com/cidreixd/webmo-library-python', download_url = 'https://g...
true
true
f77834197e99152efd2fa9c5808902b1d7b21e07
2,414
py
Python
scrapers/pet_finder_api.py
jamestenglish/PyDog
38572b36b7899c91327f727df782d8bec4285ea5
[ "MIT" ]
null
null
null
scrapers/pet_finder_api.py
jamestenglish/PyDog
38572b36b7899c91327f727df782d8bec4285ea5
[ "MIT" ]
null
null
null
scrapers/pet_finder_api.py
jamestenglish/PyDog
38572b36b7899c91327f727df782d8bec4285ea5
[ "MIT" ]
null
null
null
import re import requests from scrapers.models.dog import Dog #Small reverse engineering of the pet finder api class PetFinderApi(): def __init__(self, zip_code): self.zip_code = zip_code @staticmethod def _get_api_key(): response = requests.get('https://www.petfinder.com/wp-content/th...
27.123596
113
0.514913
import re import requests from scrapers.models.dog import Dog class PetFinderApi(): def __init__(self, zip_code): self.zip_code = zip_code @staticmethod def _get_api_key(): response = requests.get('https://www.petfinder.com/wp-content/themes/petfinder2013/js/build/main.min.js') ...
true
true
f778345049604749e72d4cd3a083d8c29ad620b9
2,433
py
Python
Loan-Approval-Analysis/code.py
SubhamSingh285/greyatom-python-for-data-science
16a70eaa2732f1cd30bcc013847150b8caf33f02
[ "MIT" ]
null
null
null
Loan-Approval-Analysis/code.py
SubhamSingh285/greyatom-python-for-data-science
16a70eaa2732f1cd30bcc013847150b8caf33f02
[ "MIT" ]
null
null
null
Loan-Approval-Analysis/code.py
SubhamSingh285/greyatom-python-for-data-science
16a70eaa2732f1cd30bcc013847150b8caf33f02
[ "MIT" ]
null
null
null
# -------------- # Import packages import numpy as np import pandas as pd from scipy.stats import mode # code starts here #Load Dataset bank = pd.read_csv(path) # Display categorical variable categorical_var=bank.select_dtypes(include='object') #print("Categorical variables : ",categorical_var) #Co...
18.022222
119
0.715166
import numpy as np import pandas as pd from scipy.stats import mode bank = pd.read_csv(path) categorical_var=bank.select_dtypes(include='object') numerical_var=bank.select_dtypes(include='number') banks= bank.drop(columns='Loan_ID') print(banks.isnull().sum()) bank_mode = banks.mode()....
true
true
f77834a2474fcb3253ad5501ee5f3a4a2ec98573
302
py
Python
bitwrap_io/_brython/main.py
stackdump/factom-hackathon
14ca64428121f4cb7b8aa18c76f452b7b79f0168
[ "MIT" ]
3
2018-07-30T15:04:55.000Z
2018-08-10T02:42:13.000Z
bitwrap_io/_brython/main.py
stackdump/factom-hackathon
14ca64428121f4cb7b8aa18c76f452b7b79f0168
[ "MIT" ]
null
null
null
bitwrap_io/_brython/main.py
stackdump/factom-hackathon
14ca64428121f4cb7b8aa18c76f452b7b79f0168
[ "MIT" ]
1
2018-08-10T02:42:42.000Z
2018-08-10T02:42:42.000Z
""" main app entrypoint """ import terminal def application(editor_ns): """ load application into editor namespace """ exec(""" null = None true = True false = False from context import Context self = Context() """, editor_ns) terminal.onload(callback=application)
17.764706
51
0.645695
import terminal def application(editor_ns): exec(""" null = None true = True false = False from context import Context self = Context() """, editor_ns) terminal.onload(callback=application)
true
true
f77834b31c34fece658872a6e6734c4e3b5dcde2
114,554
py
Python
lib/googlecloudsdk/third_party/apis/gkemulticloud/v1/gkemulticloud_v1_messages.py
google-cloud-sdk-unofficial/google-cloud-sdk
2a48a04df14be46c8745050f98768e30474a1aac
[ "Apache-2.0" ]
2
2019-11-10T09:17:07.000Z
2019-12-18T13:44:08.000Z
lib/googlecloudsdk/third_party/apis/gkemulticloud/v1/gkemulticloud_v1_messages.py
google-cloud-sdk-unofficial/google-cloud-sdk
2a48a04df14be46c8745050f98768e30474a1aac
[ "Apache-2.0" ]
null
null
null
lib/googlecloudsdk/third_party/apis/gkemulticloud/v1/gkemulticloud_v1_messages.py
google-cloud-sdk-unofficial/google-cloud-sdk
2a48a04df14be46c8745050f98768e30474a1aac
[ "Apache-2.0" ]
1
2020-07-25T01:40:19.000Z
2020-07-25T01:40:19.000Z
"""Generated message classes for gkemulticloud version v1. Anthos Multi-Cloud provides a way to manage Kubernetes clusters that run on AWS and Azure infrastructure using the Anthos Multi-Cloud API. Combined with Connect, you can manage Kubernetes clusters on Google Cloud, AWS, and Azure from the Google Cloud Console....
42.616815
112
0.752807
from __future__ import absolute_import from apitools.base.protorpclite import messages as _messages from apitools.base.py import encoding from apitools.base.py import extra_types package = 'gkemulticloud' class GkemulticloudProjectsLocationsAwsClustersAwsNodePoolsCreateRequest(_messages.Message): awsNodePoolId...
true
true
f778357f0b001d46a4de46de73a13310fc59c2f9
1,581
py
Python
aliyun-python-sdk-cusanalytic_sc_online/aliyunsdkcusanalytic_sc_online/request/v20190524/GetEMapRequest.py
yndu13/aliyun-openapi-python-sdk
12ace4fb39fe2fb0e3927a4b1b43ee4872da43f5
[ "Apache-2.0" ]
1,001
2015-07-24T01:32:41.000Z
2022-03-25T01:28:18.000Z
aliyun-python-sdk-cusanalytic_sc_online/aliyunsdkcusanalytic_sc_online/request/v20190524/GetEMapRequest.py
yndu13/aliyun-openapi-python-sdk
12ace4fb39fe2fb0e3927a4b1b43ee4872da43f5
[ "Apache-2.0" ]
363
2015-10-20T03:15:00.000Z
2022-03-08T12:26:19.000Z
aliyun-python-sdk-cusanalytic_sc_online/aliyunsdkcusanalytic_sc_online/request/v20190524/GetEMapRequest.py
yndu13/aliyun-openapi-python-sdk
12ace4fb39fe2fb0e3927a4b1b43ee4872da43f5
[ "Apache-2.0" ]
682
2015-09-22T07:19:02.000Z
2022-03-22T09:51:46.000Z
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
36.767442
77
0.768501
from aliyunsdkcore.request import RpcRequest from aliyunsdkcusanalytic_sc_online.endpoint import endpoint_data class GetEMapRequest(RpcRequest): def __init__(self): RpcRequest.__init__(self, 'cusanalytic_sc_online', '2019-05-24', 'GetEMap') if hasattr(self, "endpoint_map"): setattr(self, "endpoint_map", endp...
true
true
f7783702969cad745b72e7bdb437cbfe895e24c9
8,091
bzl
Python
api/bazel/repositories.bzl
scw00/envoy
c167c65b8b93a3bcd92ba24c50c6f175b053f06e
[ "Apache-2.0" ]
1
2020-08-29T14:20:09.000Z
2020-08-29T14:20:09.000Z
api/bazel/repositories.bzl
scw00/envoy
c167c65b8b93a3bcd92ba24c50c6f175b053f06e
[ "Apache-2.0" ]
null
null
null
api/bazel/repositories.bzl
scw00/envoy
c167c65b8b93a3bcd92ba24c50c6f175b053f06e
[ "Apache-2.0" ]
1
2020-09-27T11:47:03.000Z
2020-09-27T11:47:03.000Z
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive") load(":envoy_http_archive.bzl", "envoy_http_archive") load(":repository_locations.bzl", "REPOSITORY_LOCATIONS") def api_dependencies(): envoy_http_archive( "bazel_skylib", locations = REPOSITORY_LOCATIONS, ) envoy_http_arc...
26.441176
83
0.653071
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive") load(":envoy_http_archive.bzl", "envoy_http_archive") load(":repository_locations.bzl", "REPOSITORY_LOCATIONS") def api_dependencies(): envoy_http_archive( "bazel_skylib", locations = REPOSITORY_LOCATIONS, ) envoy_http_arc...
true
true
f77837f0c4ea68a0713516b7f8608a9842d6d254
1,340
py
Python
src/tests/long_cluster_tests.py
gcsideal/debian-qpid-cpp
e4d034036f29408f940805f5505ae62ce89650cc
[ "Apache-2.0" ]
null
null
null
src/tests/long_cluster_tests.py
gcsideal/debian-qpid-cpp
e4d034036f29408f940805f5505ae62ce89650cc
[ "Apache-2.0" ]
null
null
null
src/tests/long_cluster_tests.py
gcsideal/debian-qpid-cpp
e4d034036f29408f940805f5505ae62ce89650cc
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "L...
34.358974
92
0.732836
import os, signal, sys, unittest from testlib import TestBaseCluster class LongClusterTests(TestBaseCluster): """Long/Soak cluster tests with async store ability""" def test_LongCluster_01_DummyTest(self): """Dummy test - a placeholder for the first of the long/soak python cluster tests""" ...
false
true
f7783829aa6b8e407aed2a3847a8c6c2d0450675
317
py
Python
experiments/jacobi-1d/tmp_files/613.py
LoopTilingBenchmark/benchmark
52a3d2e70216552a498fd91de02a2fa9cb62122c
[ "BSD-2-Clause" ]
null
null
null
experiments/jacobi-1d/tmp_files/613.py
LoopTilingBenchmark/benchmark
52a3d2e70216552a498fd91de02a2fa9cb62122c
[ "BSD-2-Clause" ]
null
null
null
experiments/jacobi-1d/tmp_files/613.py
LoopTilingBenchmark/benchmark
52a3d2e70216552a498fd91de02a2fa9cb62122c
[ "BSD-2-Clause" ]
null
null
null
from chill import * source('/uufs/chpc.utah.edu/common/home/u1142914/lib/ytopt_vinu/polybench/polybench-code/stencils/jacobi-1d/kernel.c') destination('/uufs/chpc.utah.edu/common/home/u1142914/lib/ytopt_vinu/experiments/jacobi-1d/tmp_files/613.c') procedure('kernel_jacobi_1d') loop(0) tile(0,2,32,2) tile(1,2,32,2)
35.222222
118
0.785489
from chill import * source('/uufs/chpc.utah.edu/common/home/u1142914/lib/ytopt_vinu/polybench/polybench-code/stencils/jacobi-1d/kernel.c') destination('/uufs/chpc.utah.edu/common/home/u1142914/lib/ytopt_vinu/experiments/jacobi-1d/tmp_files/613.c') procedure('kernel_jacobi_1d') loop(0) tile(0,2,32,2) tile(1,2,32,2)
true
true
f77838e12ce45128e3f5cfa68387655b24618851
48
py
Python
ciaa-nxp/pyExamples/Main_welcome.py
braytac/micropython
4fba270b6061395367e7f49eb3baa77365557ace
[ "MIT" ]
2
2019-07-28T05:27:42.000Z
2020-05-26T04:39:43.000Z
ciaa-nxp/pyExamples/Main_welcome.py
braytac/micropython
4fba270b6061395367e7f49eb3baa77365557ace
[ "MIT" ]
null
null
null
ciaa-nxp/pyExamples/Main_welcome.py
braytac/micropython
4fba270b6061395367e7f49eb3baa77365557ace
[ "MIT" ]
1
2018-06-23T22:07:06.000Z
2018-06-23T22:07:06.000Z
print("Welcome to Micropython on EDU-CIAA-NXP")
24
47
0.770833
print("Welcome to Micropython on EDU-CIAA-NXP")
true
true
f77838e81de040cc1953f6faee93aaaa725b54c2
1,348
py
Python
docs/conf.py
KyleRConway/beets
d0cbf098c60ca27f3e75cf899026979f19dcca00
[ "MIT" ]
2
2021-01-21T08:33:49.000Z
2021-04-23T08:43:04.000Z
docs/conf.py
KyleRConway/beets
d0cbf098c60ca27f3e75cf899026979f19dcca00
[ "MIT" ]
12
2020-06-09T07:51:42.000Z
2022-03-23T22:07:43.000Z
docs/conf.py
KyleRConway/beets
d0cbf098c60ca27f3e75cf899026979f19dcca00
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from __future__ import division, absolute_import, print_function AUTHOR = u'Adrian Sampson' # General configuration extensions = ['sphinx.ext.autodoc', 'sphinx.ext.extlinks'] exclude_patterns = ['_build'] source_suffix = '.rst' master_doc = 'index' project = u'beets' copyright = u'2016, Ad...
24.509091
68
0.646142
from __future__ import division, absolute_import, print_function AUTHOR = u'Adrian Sampson' extensions = ['sphinx.ext.autodoc', 'sphinx.ext.extlinks'] exclude_patterns = ['_build'] source_suffix = '.rst' master_doc = 'index' project = u'beets' copyright = u'2016, Adrian Sampson' version = '1.5' release = '1.5.0'...
true
true
f77839b7ae90aad066d1dcc2d22eafb49aadc2a3
899
py
Python
src/sauce_bot/schemas/chat.py
asmello/feed-tracker-bot
f33ca7766453e93402f5ce4f556382a529a8240c
[ "MIT" ]
null
null
null
src/sauce_bot/schemas/chat.py
asmello/feed-tracker-bot
f33ca7766453e93402f5ce4f556382a529a8240c
[ "MIT" ]
4
2021-03-31T19:29:22.000Z
2021-12-13T20:25:45.000Z
src/sauce_bot/schemas/chat.py
asmello/feed-tracker-bot
f33ca7766453e93402f5ce4f556382a529a8240c
[ "MIT" ]
null
null
null
import telegram from sqlalchemy import Column, Integer, String, Boolean from sqlalchemy.orm import relationship from . import Base class Chat(Base): __tablename__ = 'chats' db_id = Column(Integer, primary_key=True) type = Column(String) title = Column(String) username = Column(String, unique=True) first_name ...
23.657895
72
0.736374
import telegram from sqlalchemy import Column, Integer, String, Boolean from sqlalchemy.orm import relationship from . import Base class Chat(Base): __tablename__ = 'chats' db_id = Column(Integer, primary_key=True) type = Column(String) title = Column(String) username = Column(String, unique=True) first_name ...
true
true
f7783c16796b3bfd9f37c6f0664c1ad088dbd504
88
py
Python
tests/test_frontend/test_posts.py
Rshep3087/log-five-three-one
b30f95ba66a7e57061454f9a476200d71cc77d82
[ "MIT" ]
2
2020-11-21T03:36:59.000Z
2021-04-18T15:13:55.000Z
tests/test_frontend/test_posts.py
Rshep3087/log-five-three-one
b30f95ba66a7e57061454f9a476200d71cc77d82
[ "MIT" ]
20
2020-11-21T03:37:30.000Z
2020-12-13T20:16:41.000Z
tests/test_frontend/test_posts.py
Rshep3087/log-five-three-one
b30f95ba66a7e57061454f9a476200d71cc77d82
[ "MIT" ]
1
2020-12-13T02:43:13.000Z
2020-12-13T02:43:13.000Z
class TestPost: def test_create_and_delete_post(self, driver_login): pass
14.666667
56
0.715909
class TestPost: def test_create_and_delete_post(self, driver_login): pass
true
true
f7783c1e131867fe1d775769f7be1db4a2dfa66f
1,799
py
Python
tests/test_serializers.py
EugenePY/faust-avro
e8439fb299d8aff9f09a597e8fead2ad0be74b3c
[ "BSD-3-Clause" ]
null
null
null
tests/test_serializers.py
EugenePY/faust-avro
e8439fb299d8aff9f09a597e8fead2ad0be74b3c
[ "BSD-3-Clause" ]
null
null
null
tests/test_serializers.py
EugenePY/faust-avro
e8439fb299d8aff9f09a597e8fead2ad0be74b3c
[ "BSD-3-Clause" ]
null
null
null
import json from datetime import datetime, timezone from faust.exceptions import ValueDecodeError from faust.types.tuples import Message import pytest from assertpy import assert_that from faust_avro import Record from faust_avro import context as ctx class Key(Record): idx: int class Person(Record): name...
25.7
78
0.667037
import json from datetime import datetime, timezone from faust.exceptions import ValueDecodeError from faust.types.tuples import Message import pytest from assertpy import assert_that from faust_avro import Record from faust_avro import context as ctx class Key(Record): idx: int class Person(Record): name...
true
true
f7783e9c000e4738834a8e4a2adb1c2b97a99dd9
1,247
py
Python
unyt/tests/test_define_unit.py
migueldvb/unyt
57744cc7a481179eb86174218a5d1d6279b16078
[ "BSD-3-Clause" ]
291
2018-04-30T16:29:32.000Z
2022-03-18T09:48:25.000Z
unyt/tests/test_define_unit.py
migueldvb/unyt
57744cc7a481179eb86174218a5d1d6279b16078
[ "BSD-3-Clause" ]
175
2018-04-11T19:35:32.000Z
2022-03-30T19:38:30.000Z
unyt/tests/test_define_unit.py
migueldvb/unyt
57744cc7a481179eb86174218a5d1d6279b16078
[ "BSD-3-Clause" ]
48
2018-04-12T15:20:47.000Z
2021-12-13T14:35:23.000Z
import pytest from unyt.unit_object import define_unit from unyt.unit_registry import UnitRegistry from unyt.array import unyt_quantity def test_define_unit(): define_unit("mph", (1.0, "mile/hr")) a = unyt_quantity(2.0, "mph") b = unyt_quantity(1.0, "mile") c = unyt_quantity(1.0, "hr") assert a =...
28.340909
51
0.619086
import pytest from unyt.unit_object import define_unit from unyt.unit_registry import UnitRegistry from unyt.array import unyt_quantity def test_define_unit(): define_unit("mph", (1.0, "mile/hr")) a = unyt_quantity(2.0, "mph") b = unyt_quantity(1.0, "mile") c = unyt_quantity(1.0, "hr") assert a =...
true
true
f7783eb971e8c3142ee19a820c1c14bd38682cb6
932
py
Python
scraper/storage_spiders/sieuthiytecomvn.py
chongiadung/choinho
d2a216fe7a5064d73cdee3e928a7beef7f511fd1
[ "MIT" ]
null
null
null
scraper/storage_spiders/sieuthiytecomvn.py
chongiadung/choinho
d2a216fe7a5064d73cdee3e928a7beef7f511fd1
[ "MIT" ]
10
2020-02-11T23:34:28.000Z
2022-03-11T23:16:12.000Z
scraper/storage_spiders/sieuthiytecomvn.py
chongiadung/choinho
d2a216fe7a5064d73cdee3e928a7beef7f511fd1
[ "MIT" ]
3
2018-08-05T14:54:25.000Z
2021-06-07T01:49:59.000Z
# Auto generated by generator.py. Delete this line if you make modification. from scrapy.spiders import Rule from scrapy.linkextractors import LinkExtractor XPATH = { 'name' : "//div[@class='product-info']/h2[@class='title']", 'price' : "//span[@class='price']", 'category' : "//div[@class='br']/a", 'de...
34.518519
98
0.619099
from scrapy.spiders import Rule from scrapy.linkextractors import LinkExtractor XPATH = { 'name' : "//div[@class='product-info']/h2[@class='title']", 'price' : "//span[@class='price']", 'category' : "//div[@class='br']/a", 'description' : "//div[@id='description']/p", 'images' : "//a[@class='z-fea'...
true
true
f7783ef1372a40a6593a4bef4b7c4c4f2c022186
1,055
py
Python
src/server/app/main/routes/HotelDisplay.py
ray-abhishek/onefinestay
7bf5871622707f476722275fa98c3b02b3004aab
[ "MIT" ]
1
2020-08-03T17:35:13.000Z
2020-08-03T17:35:13.000Z
src/server/app/main/routes/HotelDisplay.py
ray-abhishek/onefinestay
7bf5871622707f476722275fa98c3b02b3004aab
[ "MIT" ]
44
2020-07-21T10:40:23.000Z
2020-08-03T17:34:21.000Z
src/server/app/main/routes/HotelDisplay.py
ray2294/onefinestay
7bf5871622707f476722275fa98c3b02b3004aab
[ "MIT" ]
null
null
null
from flask import request from flask_restful import Resource, reqparse from ..models import db from ..services.hotel_display import get_hotel_data import jwt from ..settings import key import datetime # Route for HotelDisplay class HotelDisplay(Resource): parser = reqparse.RequestParser() @classmethod def...
31.969697
103
0.652133
from flask import request from flask_restful import Resource, reqparse from ..models import db from ..services.hotel_display import get_hotel_data import jwt from ..settings import key import datetime class HotelDisplay(Resource): parser = reqparse.RequestParser() @classmethod def get(self, hotelid=None):...
true
true
f7783f532a7be9558e53765db92f4b23355032ef
5,724
py
Python
custom_components/heatzy/climate.py
moreau-se/hass-heatzy
aa5e490b473c1e63cbd3155e6c54f2f6eda34fb4
[ "MIT" ]
14
2020-12-26T00:52:26.000Z
2022-03-13T14:15:35.000Z
custom_components/heatzy/climate.py
moreau-se/hass-heatzy
aa5e490b473c1e63cbd3155e6c54f2f6eda34fb4
[ "MIT" ]
12
2021-01-16T14:21:52.000Z
2022-03-26T12:20:19.000Z
custom_components/heatzy/climate.py
Cyr-ius/hass-heatzy
aa5e490b473c1e63cbd3155e6c54f2f6eda34fb4
[ "MIT" ]
6
2021-03-14T12:51:45.000Z
2022-03-02T18:06:06.000Z
"""Climate sensors for Heatzy.""" import logging from heatzypy.exception import HeatzyException from homeassistant.components.climate import ClimateEntity from homeassistant.components.climate.const import ( HVAC_MODE_HEAT, HVAC_MODE_OFF, PRESET_AWAY, PRESET_COMFORT, PRESET_ECO, PRESET_NONE, ...
30.285714
80
0.631202
import logging from heatzypy.exception import HeatzyException from homeassistant.components.climate import ClimateEntity from homeassistant.components.climate.const import ( HVAC_MODE_HEAT, HVAC_MODE_OFF, PRESET_AWAY, PRESET_COMFORT, PRESET_ECO, PRESET_NONE, SUPPORT_PRESET_MODE, ) from hom...
true
true
f77840ea3ee5a5eb6e08d585d553418850529d27
2,011
py
Python
adminplus/tests.py
TabbedOut/django-adminplus
d466d5aecd6d36999aa53d7f207be6e1ed6a7d80
[ "BSD-3-Clause" ]
null
null
null
adminplus/tests.py
TabbedOut/django-adminplus
d466d5aecd6d36999aa53d7f207be6e1ed6a7d80
[ "BSD-3-Clause" ]
null
null
null
adminplus/tests.py
TabbedOut/django-adminplus
d466d5aecd6d36999aa53d7f207be6e1ed6a7d80
[ "BSD-3-Clause" ]
null
null
null
from django.test import TestCase from adminplus.sites import AdminSitePlus class AdminPlusTests(TestCase): def test_decorator(self): """register_view works as a decorator.""" site = AdminSitePlus() @site.register_view(r'foo/bar') def foo_bar(request): return 'foo-bar'...
28.728571
54
0.586275
from django.test import TestCase from adminplus.sites import AdminSitePlus class AdminPlusTests(TestCase): def test_decorator(self): site = AdminSitePlus() @site.register_view(r'foo/bar') def foo_bar(request): return 'foo-bar' urls = site.get_urls() assert an...
true
true
f77841433cb3363baa2169191721dbd8053ef8ba
11,278
py
Python
dalle-mini-custom/tools/inference/inference.py
gxxu-ml/Natural-Disaster-Image-Generation-to-raise-Environmental-Awareness
930e30fb2b3eca0fa3aeeeb05462538669405d54
[ "MIT" ]
null
null
null
dalle-mini-custom/tools/inference/inference.py
gxxu-ml/Natural-Disaster-Image-Generation-to-raise-Environmental-Awareness
930e30fb2b3eca0fa3aeeeb05462538669405d54
[ "MIT" ]
null
null
null
dalle-mini-custom/tools/inference/inference.py
gxxu-ml/Natural-Disaster-Image-Generation-to-raise-Environmental-Awareness
930e30fb2b3eca0fa3aeeeb05462538669405d54
[ "MIT" ]
null
null
null
import jax import jax.numpy as jnp import os # Load models & tokenizer from dalle_mini.model import DalleBart, DalleBartTokenizer from vqgan_jax.modeling_flax_vqgan import VQModel from transformers import CLIPProcessor, FlaxCLIPModel import wandb from transformers import CLIPProcessor, CLIPModel from dalle_mini.model i...
35.354232
211
0.646923
import jax import jax.numpy as jnp import os from dalle_mini.model import DalleBart, DalleBartTokenizer from vqgan_jax.modeling_flax_vqgan import VQModel from transformers import CLIPProcessor, FlaxCLIPModel import wandb from transformers import CLIPProcessor, CLIPModel from dalle_mini.model import DalleBart, DalleBart...
true
true
f77841478373a2eb84239d2d6a5ea886f9d7c1d2
1,082
py
Python
acm/livearchive/6604-airport-sort.py
neizod/problems
180aaf7d0ecfc3d0dd5f1d4345a7a4d83b1b884a
[ "MIT" ]
1
2015-10-17T11:15:42.000Z
2015-10-17T11:15:42.000Z
acm/livearchive/6604-airport-sort.py
neizod/problems
180aaf7d0ecfc3d0dd5f1d4345a7a4d83b1b884a
[ "MIT" ]
null
null
null
acm/livearchive/6604-airport-sort.py
neizod/problems
180aaf7d0ecfc3d0dd5f1d4345a7a4d83b1b884a
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 def ceil_div(n, k): return n//k + (n%k!=0) def lowbit(x): return x & (-x) def sum_until(rs, n): c = 0 while n > 0: c += rs[n] n -= lowbit(n) return c def increase(rs, n): while n < len(rs): rs[n] += 1 n += lowbit(n) def method_a(ls...
20.415094
73
0.494455
def ceil_div(n, k): return n//k + (n%k!=0) def lowbit(x): return x & (-x) def sum_until(rs, n): c = 0 while n > 0: c += rs[n] n -= lowbit(n) return c def increase(rs, n): while n < len(rs): rs[n] += 1 n += lowbit(n) def method_a(ls, k): ls = [1+(n-1)...
true
true
f778415333e1e2bfe7d478f655a79727e8d47829
17,555
py
Python
vertizee/classes/tests/test_vertex.py
cpeisert/vertizee
648e9813380f8e45e7f5d765713e93a72289b9d5
[ "Apache-2.0" ]
null
null
null
vertizee/classes/tests/test_vertex.py
cpeisert/vertizee
648e9813380f8e45e7f5d765713e93a72289b9d5
[ "Apache-2.0" ]
1
2021-02-10T17:04:35.000Z
2021-02-12T21:29:59.000Z
vertizee/classes/tests/test_vertex.py
cpeisert/vertizee
648e9813380f8e45e7f5d765713e93a72289b9d5
[ "Apache-2.0" ]
null
null
null
# Copyright 2020 The Vertizee Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in ...
40.825581
100
0.613842
import pytest from vertizee import ( Graph, Vertex, DiGraph, DiVertex, MultiGraph, MultiVertex, MultiDiGraph, MultiDiVertex, VertizeeException, ) from vertizee.classes import vertex as vertex_module class TestVertexModuleFunctions: def test_get_vertex_label(self) -> None: ...
true
true
f77841e722711e320161dee1cd78a9371da49b7c
11,673
py
Python
motifs.py
nmasse/Meta-Networks
1ac4c233e71221ee6ce9acd96220b313f3560160
[ "Apache-2.0" ]
1
2018-07-04T14:58:33.000Z
2018-07-04T14:58:33.000Z
motifs.py
nmasse/Meta-Networks
1ac4c233e71221ee6ce9acd96220b313f3560160
[ "Apache-2.0" ]
null
null
null
motifs.py
nmasse/Meta-Networks
1ac4c233e71221ee6ce9acd96220b313f3560160
[ "Apache-2.0" ]
null
null
null
import numpy as np from itertools import product from itertools import permutations import matplotlib.pyplot as plt import pickle import os import stimulus import parameters import analysis class Motifs: def __init__(self, data_dir, file_prefix, N = None): self.motifs = {} self.motif_sizes = [2,...
39.569492
151
0.471944
import numpy as np from itertools import product from itertools import permutations import matplotlib.pyplot as plt import pickle import os import stimulus import parameters import analysis class Motifs: def __init__(self, data_dir, file_prefix, N = None): self.motifs = {} self.motif_sizes = [2,...
true
true
f77841ec7111dbc1d249a9274ec0d5d46c69e350
1,342
py
Python
ixnetwork_restpy/testplatform/sessions/ixnetwork/traffic/trafficitem/configelement/stack/POP_RETR_1_template.py
Vibaswan/ixnetwork_restpy
239fedc7050890746cbabd71ea1e91c68d9e5cad
[ "MIT" ]
null
null
null
ixnetwork_restpy/testplatform/sessions/ixnetwork/traffic/trafficitem/configelement/stack/POP_RETR_1_template.py
Vibaswan/ixnetwork_restpy
239fedc7050890746cbabd71ea1e91c68d9e5cad
[ "MIT" ]
null
null
null
ixnetwork_restpy/testplatform/sessions/ixnetwork/traffic/trafficitem/configelement/stack/POP_RETR_1_template.py
Vibaswan/ixnetwork_restpy
239fedc7050890746cbabd71ea1e91c68d9e5cad
[ "MIT" ]
null
null
null
from ixnetwork_restpy.base import Base from ixnetwork_restpy.files import Files class POP_RETR_1(Base): __slots__ = () _SDM_NAME = 'POP_RETR_1' _SDM_ATT_MAP = { 'Request command': 'POP_RETR_1.REQUESTX.Request command', 'Space7': 'POP_RETR_1.REQUESTX.Space7', 'Request parameter': 'P...
33.55
92
0.707154
from ixnetwork_restpy.base import Base from ixnetwork_restpy.files import Files class POP_RETR_1(Base): __slots__ = () _SDM_NAME = 'POP_RETR_1' _SDM_ATT_MAP = { 'Request command': 'POP_RETR_1.REQUESTX.Request command', 'Space7': 'POP_RETR_1.REQUESTX.Space7', 'Request parameter': 'P...
true
true
f7784532e901c192f3aee126d2bcf39d7566ae66
173,527
py
Python
mermaid/multiscale_optimizer.py
HastingsGreer/mermaid
bd13c5fc427eb8cd9054973a8eaaeb302078182d
[ "Apache-2.0" ]
120
2019-10-29T23:53:02.000Z
2022-03-30T02:59:58.000Z
mermaid/multiscale_optimizer.py
AlexanderChristgau/mermaid
ba07883cc3cb5982e4655048a434b4495cb49c6d
[ "Apache-2.0" ]
10
2019-11-05T09:28:35.000Z
2022-01-09T19:12:51.000Z
mermaid/multiscale_optimizer.py
AlexanderChristgau/mermaid
ba07883cc3cb5982e4655048a434b4495cb49c6d
[ "Apache-2.0" ]
19
2019-11-10T13:34:39.000Z
2022-03-13T20:30:10.000Z
""" This package enables easy single-scale and multi-scale optimization support. """ from __future__ import print_function from __future__ import absolute_import # from builtins import zip # from builtins import str # from builtins import range # from builtins import object from abc import ABCMeta, abstractmethod impo...
46.18765
260
0.6266
from __future__ import print_function from __future__ import absolute_import from abc import ABCMeta, abstractmethod import os import time import copy from . import utils from . import visualize_registration_results as vizReg from . import custom_optimizers as CO import numpy as np import torch from .data_wrapper impo...
true
true
f778455195296f1b230acbb9c0b5fa31b4b95cce
3,994
py
Python
geonetworkx/tests/datasets/import_datasets.py
Artelys/geonetworkx
1dacddc08bb2e7b80000eb1135a5203b2ef89dbe
[ "MIT" ]
29
2019-10-28T13:30:07.000Z
2022-01-26T09:25:06.000Z
geonetworkx/tests/datasets/import_datasets.py
Artelys/geonetworkx
1dacddc08bb2e7b80000eb1135a5203b2ef89dbe
[ "MIT" ]
5
2020-10-12T12:04:04.000Z
2022-03-13T09:39:26.000Z
geonetworkx/tests/datasets/import_datasets.py
Artelys/geonetworkx
1dacddc08bb2e7b80000eb1135a5203b2ef89dbe
[ "MIT" ]
null
null
null
import os import networkx as nx import geonetworkx as gnx import geopandas as gpd def get_copenhagen_street_net(): """Reads dataset geojson and return the corresponding geograph.""" dir_path = os.path.dirname(os.path.realpath(__file__)) nodes_path = os.path.join(dir_path, "copenhagen_streets_net_nodes.geo...
44.876404
106
0.74687
import os import networkx as nx import geonetworkx as gnx import geopandas as gpd def get_copenhagen_street_net(): dir_path = os.path.dirname(os.path.realpath(__file__)) nodes_path = os.path.join(dir_path, "copenhagen_streets_net_nodes.geojson") edges_path = os.path.join(dir_path, "copenhagen_streets_net_...
true
true
f778469d4137818ca8f1a424b4fe03ff124c51ce
2,700
py
Python
Module04/assignment4-2.py
kholt90/DataStruct
acc42358f27ec4bac15b87e2bfd53b5843d592b6
[ "Unlicense" ]
null
null
null
Module04/assignment4-2.py
kholt90/DataStruct
acc42358f27ec4bac15b87e2bfd53b5843d592b6
[ "Unlicense" ]
null
null
null
Module04/assignment4-2.py
kholt90/DataStruct
acc42358f27ec4bac15b87e2bfd53b5843d592b6
[ "Unlicense" ]
null
null
null
# You are a renowned thief who has recently switched from stealing precious metals to stealing cakes because of the insane profit margins. # You end up hitting the jackpot, breaking into the world's largest privately owned stock of cakes—the vault of the Queen of England. # While Queen Elizabeth has a limited number o...
36.486486
275
0.684074
# While Queen Elizabeth has a limited number of types of cake, she has an unlimited supply of each type. # Each type of cake has a weight and a value, stored in a tuple with two indices: # An integer representing the weight of the cake in kilograms # An integer representing the monetary value of the cake in British sh...
true
true
f77846c186e213c5353252f1f95da06159c32efa
401
py
Python
app.py
jmaldon1/Python-basic_template
2fa15631b7afce356105016c4236f7ba6b5cafc2
[ "MIT" ]
1
2021-01-17T02:20:29.000Z
2021-01-17T02:20:29.000Z
app.py
jmaldon1/Python-basic_template
2fa15631b7afce356105016c4236f7ba6b5cafc2
[ "MIT" ]
null
null
null
app.py
jmaldon1/Python-basic_template
2fa15631b7afce356105016c4236f7ba6b5cafc2
[ "MIT" ]
null
null
null
"""Entry point of the project """ import json import settings as _ # Loader script for initializing things. from conf import config from src.logger import logger def main(): """Main function Run this file with `python app.py` """ print("\n") logger.info("Success! Here is you're config:\n") l...
19.095238
62
0.665835
import json import settings as _ from conf import config from src.logger import logger def main(): print("\n") logger.info("Success! Here is you're config:\n") logger.info(json.dumps(config, indent=4)) if __name__ == "__main__": main()
true
true
f77846cbb94db4d23aac1f13c9bae305d2156637
2,223
py
Python
datasets/__init__.py
D-Sokol/lazy-pattern-classifier
a0cc5e7a5db8177b6e12cc9a0f0e4acf61233603
[ "MIT" ]
null
null
null
datasets/__init__.py
D-Sokol/lazy-pattern-classifier
a0cc5e7a5db8177b6e12cc9a0f0e4acf61233603
[ "MIT" ]
null
null
null
datasets/__init__.py
D-Sokol/lazy-pattern-classifier
a0cc5e7a5db8177b6e12cc9a0f0e4acf61233603
[ "MIT" ]
null
null
null
from functools import wraps import os import pandas as pd def _read_csv(name, **kw): path = os.path.join(os.path.dirname(__file__), 'data', name) return pd.read_csv(path, **kw) def apply_one_hot(fun): @wraps(fun) def wrapper(*args, **kw): X, y = fun(*args, **kw) X = pd.get_dummies(X,...
28.5
98
0.619883
from functools import wraps import os import pandas as pd def _read_csv(name, **kw): path = os.path.join(os.path.dirname(__file__), 'data', name) return pd.read_csv(path, **kw) def apply_one_hot(fun): @wraps(fun) def wrapper(*args, **kw): X, y = fun(*args, **kw) X = pd.get_dummies(X,...
true
true
f778479026861256bce8ee30db4a9ac53ed010d7
6,927
py
Python
aws-inventory/lambda/inventory-transit-gateway.py
dkeppel626/antiope
c8a540e92878cb220be9918c20bb9458d4541d1a
[ "Apache-2.0" ]
210
2019-01-11T20:58:23.000Z
2022-03-16T18:51:17.000Z
aws-inventory/lambda/inventory-transit-gateway.py
dkeppel626/antiope
c8a540e92878cb220be9918c20bb9458d4541d1a
[ "Apache-2.0" ]
13
2018-11-23T19:06:05.000Z
2020-08-19T20:05:28.000Z
aws-inventory/lambda/inventory-transit-gateway.py
dkeppel626/antiope
c8a540e92878cb220be9918c20bb9458d4541d1a
[ "Apache-2.0" ]
44
2018-11-21T15:51:24.000Z
2022-03-11T01:21:24.000Z
import boto3 from botocore.exceptions import ClientError import json import os import time from datetime import datetime, timezone from dateutil import tz from antiope.aws_account import * from common import * import logging logger = logging.getLogger() logger.setLevel(getattr(logging, os.getenv('LOG_LEVEL', default=...
44.121019
172
0.602425
import boto3 from botocore.exceptions import ClientError import json import os import time from datetime import datetime, timezone from dateutil import tz from antiope.aws_account import * from common import * import logging logger = logging.getLogger() logger.setLevel(getattr(logging, os.getenv('LOG_LEVEL', default=...
true
true
f77847af4315ff6ea3099763822613ebed71dcec
920
py
Python
molecool/measure.py
hienerd/molecool
35817f23c0f2a64cbaffa7c8ed3b421bf4774130
[ "BSD-3-Clause" ]
null
null
null
molecool/measure.py
hienerd/molecool
35817f23c0f2a64cbaffa7c8ed3b421bf4774130
[ "BSD-3-Clause" ]
null
null
null
molecool/measure.py
hienerd/molecool
35817f23c0f2a64cbaffa7c8ed3b421bf4774130
[ "BSD-3-Clause" ]
null
null
null
import numpy as np def calculate_distance(rA, rB): """ This function calculates the distance between two points. Parameters ---------- rA, rB : np.ndarray The coordinates of each point. Returns ------- distance : float The distance between two points. Examples ...
23
114
0.592391
import numpy as np def calculate_distance(rA, rB): dist_vec = (rA - rB) distance = np.linalg.norm(dist_vec) return distance def calculate_angle(rA, rB, rC, degrees=False): AB = rB - rA BC = rB - rC theta=np.arccos(np.dot(AB, BC)/(np.linalg.norm(AB)*np.linalg.norm(BC))) if degrees...
true
true
f7784a774fec8201de110fccaa93fd486ac5ab5f
92
py
Python
2014/07/guinea-worms/graphic_config.py
nprapps/graphics-archive
97b0ef326b46a959df930f5522d325e537f7a655
[ "FSFAP" ]
14
2015-05-08T13:41:51.000Z
2021-02-24T12:34:55.000Z
2014/07/guinea-worms/graphic_config.py
nprapps/graphics-archive
97b0ef326b46a959df930f5522d325e537f7a655
[ "FSFAP" ]
null
null
null
2014/07/guinea-worms/graphic_config.py
nprapps/graphics-archive
97b0ef326b46a959df930f5522d325e537f7a655
[ "FSFAP" ]
7
2015-04-04T04:45:54.000Z
2021-02-18T11:12:48.000Z
#!/usr/bin/env python COPY_GOOGLE_DOC_KEY = '1nXqNsO6ZbUpAxKpFe7eWM8x7SQKd7MDcH6AT0fWyNaY'
23
68
0.847826
COPY_GOOGLE_DOC_KEY = '1nXqNsO6ZbUpAxKpFe7eWM8x7SQKd7MDcH6AT0fWyNaY'
true
true
f7784add495bb4b7b6d19f9cba4520d28b29e0bf
123
py
Python
src/meltano/core/extractor.py
siilats/meltano
404605c83f441c3fc2b729e26416c6caa8b0ed0b
[ "MIT" ]
122
2021-06-21T17:30:29.000Z
2022-03-25T06:21:38.000Z
src/meltano/core/extractor.py
siilats/meltano
404605c83f441c3fc2b729e26416c6caa8b0ed0b
[ "MIT" ]
38
2019-12-09T06:53:33.000Z
2022-03-29T22:29:19.000Z
src/meltano/core/extractor.py
siilats/meltano
404605c83f441c3fc2b729e26416c6caa8b0ed0b
[ "MIT" ]
21
2021-06-22T10:08:15.000Z
2022-03-18T08:57:02.000Z
from abc import ABC, abstractmethod class MeltanoExtractor(ABC): @abstractmethod def extract(self): pass
15.375
35
0.699187
from abc import ABC, abstractmethod class MeltanoExtractor(ABC): @abstractmethod def extract(self): pass
true
true
f7784b3dc9bbb605f302927a27ce15fb2b8922d5
32,472
py
Python
square/api/labor_api.py
sdolemelipone/square-python-sdk
4674d4867542ff5a32dc29a4bde483e62df065fb
[ "Apache-2.0" ]
null
null
null
square/api/labor_api.py
sdolemelipone/square-python-sdk
4674d4867542ff5a32dc29a4bde483e62df065fb
[ "Apache-2.0" ]
null
null
null
square/api/labor_api.py
sdolemelipone/square-python-sdk
4674d4867542ff5a32dc29a4bde483e62df065fb
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- from deprecation import deprecated from square.api_helper import APIHelper from square.http.api_response import ApiResponse from square.api.base_api import BaseApi from square.http.auth.o_auth_2 import OAuth2 class LaborApi(BaseApi): """A Controller to access Endpoints in the square API....
36
120
0.599409
from deprecation import deprecated from square.api_helper import APIHelper from square.http.api_response import ApiResponse from square.api.base_api import BaseApi from square.http.auth.o_auth_2 import OAuth2 class LaborApi(BaseApi): def __init__(self, config, call_back=None): super(LaborApi, self).__i...
true
true
f7784b9e99bf4d827ae3dc7090c9f2f8bf8839cb
767
py
Python
application/migrations/0002_auto_20200818_2129.py
754Bree/Django-ip-4
5aec1d892062f40950c6f882dc61990f241831bb
[ "MIT" ]
1
2020-12-10T20:40:27.000Z
2020-12-10T20:40:27.000Z
application/migrations/0002_auto_20200818_2129.py
754Bree/Django-ip-4
5aec1d892062f40950c6f882dc61990f241831bb
[ "MIT" ]
1
2020-08-19T15:23:01.000Z
2020-08-19T15:23:01.000Z
application/migrations/0002_auto_20200818_2129.py
754Bree/Django-ip-4
5aec1d892062f40950c6f882dc61990f241831bb
[ "MIT" ]
null
null
null
# Generated by Django 3.1 on 2020-08-18 18:29 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('application', '0001_initial'), ] operations = [ migrations.CreateModel( name='Neighbourhood', fields=[ ...
28.407407
114
0.556714
from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('application', '0001_initial'), ] operations = [ migrations.CreateModel( name='Neighbourhood', fields=[ ('id', models.AutoField(auto_created=True, pr...
true
true
f7784ba855622b3b89b4050f4d339f109c6a03bf
10,844
py
Python
nomad/api/client.py
i4s-pserrano/python-nomad
0f8dd9dfa1d448465be490f0acf9f5df96cd893f
[ "MIT" ]
null
null
null
nomad/api/client.py
i4s-pserrano/python-nomad
0f8dd9dfa1d448465be490f0acf9f5df96cd893f
[ "MIT" ]
null
null
null
nomad/api/client.py
i4s-pserrano/python-nomad
0f8dd9dfa1d448465be490f0acf9f5df96cd893f
[ "MIT" ]
null
null
null
from nomad.api.base import Requester class Client(object): def __init__(self, **kwargs): self.ls = ls(**kwargs) self.cat = cat(**kwargs) self.stat = stat(**kwargs) self.stats = stats(**kwargs) self.allocation = allocation(**kwargs) self.read_at = read_at(**kwargs) ...
30.546479
107
0.603283
from nomad.api.base import Requester class Client(object): def __init__(self, **kwargs): self.ls = ls(**kwargs) self.cat = cat(**kwargs) self.stat = stat(**kwargs) self.stats = stats(**kwargs) self.allocation = allocation(**kwargs) self.read_at = read_at(**kwargs) ...
true
true
f7784bba35b66276b1b4228363bc514164e8802d
2,565
py
Python
src/ertk/sklearn/utils.py
agkphysics/emotion
36bb9265f9439b10676fb539d5334cce645e49ef
[ "MIT" ]
1
2020-06-14T03:37:46.000Z
2020-06-14T03:37:46.000Z
src/ertk/sklearn/utils.py
agkphysics/emotion
36bb9265f9439b10676fb539d5334cce645e49ef
[ "MIT" ]
null
null
null
src/ertk/sklearn/utils.py
agkphysics/emotion
36bb9265f9439b10676fb539d5334cce645e49ef
[ "MIT" ]
null
null
null
import warnings import numpy as np from joblib import Parallel, delayed from sklearn.base import MetaEstimatorMixin, clone from sklearn.multiclass import OneVsRestClassifier as _SKOvR from sklearn.multiclass import _ConstantPredictor from sklearn.pipeline import Pipeline from sklearn.preprocessing import LabelBinarize...
32.0625
82
0.612476
import warnings import numpy as np from joblib import Parallel, delayed from sklearn.base import MetaEstimatorMixin, clone from sklearn.multiclass import OneVsRestClassifier as _SKOvR from sklearn.multiclass import _ConstantPredictor from sklearn.pipeline import Pipeline from sklearn.preprocessing import LabelBinarize...
true
true
f7784bc6d4dc8e21ce42c9dd0baa48435d445061
3,931
py
Python
parser_tl.py
MikeAleksa/Toy-Language-Interpreter
2992af40696ddd2bc2930e319592f8342a318ce6
[ "MIT" ]
1
2019-03-24T19:33:34.000Z
2019-03-24T19:33:34.000Z
parser_tl.py
MikeAleksa/Toy-Language-Interpreter
2992af40696ddd2bc2930e319592f8342a318ce6
[ "MIT" ]
null
null
null
parser_tl.py
MikeAleksa/Toy-Language-Interpreter
2992af40696ddd2bc2930e319592f8342a318ce6
[ "MIT" ]
null
null
null
# The Parser is a recursive descent parser that takes some input program and recursively parses the text starting at # the program level, until an EOF token or an error is found. Variable names and values are stored and updated in a # dictionary representing a symbol table. # # To construct a recursive descent pars...
35.098214
119
0.57568
# Exp' ::= + Term Exp' | - Term Exp' | null # Term' ::= * Fact Term' | null # Fact ::= ( Exp ) | - Fact | + Fact | Literal | Identifier # Identifier ::= Letter [Letter | Digit]* # Letter ::= a|...|z|A|...|Z|_ # Literal ::= 0 | [1-9] [0-9]*# # # parser_tl.py uses tokenizer_tl.py to ex...
true
true
f7784c19361fb3b80f9bd2fbb8309db97e57afa3
1,148
py
Python
gui/kivy/uix/dialogs/qr_scanner.py
awemany/Electron-Cash
530b84e62f584380c1e9eedb80a28c652f77b737
[ "MIT" ]
16
2018-11-05T13:19:02.000Z
2021-04-06T12:11:49.000Z
gui/kivy/uix/dialogs/qr_scanner.py
awemany/Electron-Cash
530b84e62f584380c1e9eedb80a28c652f77b737
[ "MIT" ]
96
2018-11-09T12:46:17.000Z
2019-04-16T21:26:59.000Z
gui/kivy/uix/dialogs/qr_scanner.py
awemany/Electron-Cash
530b84e62f584380c1e9eedb80a28c652f77b737
[ "MIT" ]
5
2019-01-07T13:45:05.000Z
2020-06-12T14:13:21.000Z
from kivy.app import App from kivy.factory import Factory from kivy.lang import Builder Factory.register('QRScanner', module='electroncash_gui.kivy.qr_scanner') class QrScannerDialog(Factory.AnimatedPopup): __events__ = ('on_complete', ) def on_symbols(self, instance, value): instance.stop() ...
25.511111
82
0.623693
from kivy.app import App from kivy.factory import Factory from kivy.lang import Builder Factory.register('QRScanner', module='electroncash_gui.kivy.qr_scanner') class QrScannerDialog(Factory.AnimatedPopup): __events__ = ('on_complete', ) def on_symbols(self, instance, value): instance.stop() ...
true
true
f7784d84ae4f728b6c571af1adb4077b02ba4644
1,759
py
Python
Desafios/Desafio109.py
Felix-xilef/Curso-de-Python
cdff7c7f3850e6326e274c8c1987b9e1a18ce910
[ "MIT" ]
null
null
null
Desafios/Desafio109.py
Felix-xilef/Curso-de-Python
cdff7c7f3850e6326e274c8c1987b9e1a18ce910
[ "MIT" ]
null
null
null
Desafios/Desafio109.py
Felix-xilef/Curso-de-Python
cdff7c7f3850e6326e274c8c1987b9e1a18ce910
[ "MIT" ]
null
null
null
from auxiliar import receberInt, receberFixo import moeda def receberPreco(): preco = float(input(f'\n\tDigite o preço: {md}')) return preco def receberPorcentagem(): preco = float(input('\n\tDigite a porcentagem (10 para 10%, 5 para 5%, etc): ')) return preco # main menu = f""" \t {'=~'*20}= \t :{...
31.410714
116
0.58556
from auxiliar import receberInt, receberFixo import moeda def receberPreco(): preco = float(input(f'\n\tDigite o preço: {md}')) return preco def receberPorcentagem(): preco = float(input('\n\tDigite a porcentagem (10 para 10%, 5 para 5%, etc): ')) return preco menu = f""" \t {'=~'*20}= \t :{'Digite...
true
true
f7784eacf9f8bb40afbaadc3cccffbaf84bb27d8
1,966
py
Python
modules/commands/lockdown.py
FuelRats/FIDO
bc2e58a931e77c6e688ae5bdfe110c5e6be082e6
[ "BSD-3-Clause" ]
1
2020-01-21T13:32:53.000Z
2020-01-21T13:32:53.000Z
modules/commands/lockdown.py
FuelRats/FIDO
bc2e58a931e77c6e688ae5bdfe110c5e6be082e6
[ "BSD-3-Clause" ]
null
null
null
modules/commands/lockdown.py
FuelRats/FIDO
bc2e58a931e77c6e688ae5bdfe110c5e6be082e6
[ "BSD-3-Clause" ]
3
2019-12-03T21:08:52.000Z
2020-10-04T18:08:04.000Z
from typing import List from config import IRC import requests import ipaddress import fido from modules.access import require_permission, Levels from models import SessionManager, config from modules import configmanager import logging log = logging.getLogger(__name__) @require_permission(level=Levels.OP, message=...
45.72093
101
0.654629
from typing import List from config import IRC import requests import ipaddress import fido from modules.access import require_permission, Levels from models import SessionManager, config from modules import configmanager import logging log = logging.getLogger(__name__) @require_permission(level=Levels.OP, message=...
true
true
f7784f5ce6377862a192c2b67512f547b77b6953
6,248
py
Python
tavplus.py
udif/tavplus
c98337d6dfb36ad8bf19ed1a2d5eac8fb97e5b98
[ "MIT" ]
null
null
null
tavplus.py
udif/tavplus
c98337d6dfb36ad8bf19ed1a2d5eac8fb97e5b98
[ "MIT" ]
null
null
null
tavplus.py
udif/tavplus
c98337d6dfb36ad8bf19ed1a2d5eac8fb97e5b98
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 import json import requests from openpyxl import Workbook, load_workbook from openpyxl.utils import datetime from openpyxl.styles import numbers from requests.packages.urllib3.exceptions import InsecureRequestWarning import warnings import pickle import os import sys import argparse #import ppri...
33.956522
171
0.641965
import json import requests from openpyxl import Workbook, load_workbook from openpyxl.utils import datetime from openpyxl.styles import numbers from requests.packages.urllib3.exceptions import InsecureRequestWarning import warnings import pickle import os import sys import argparse cards = {} xactions = {} def sav...
true
true
f7784fd582fce76b1c54f4f45818c9785b40f2a3
8,432
py
Python
src/djangopypi/migrations/0007_init_normalized_name.py
Infinidat/djangopypi
fb25440166907b65bfbed01963e590414e41bdd5
[ "BSD-3-Clause" ]
2
2015-02-09T16:28:00.000Z
2019-02-15T12:57:42.000Z
src/djangopypi/migrations/0007_init_normalized_name.py
Infinidat/djangopypi
fb25440166907b65bfbed01963e590414e41bdd5
[ "BSD-3-Clause" ]
null
null
null
src/djangopypi/migrations/0007_init_normalized_name.py
Infinidat/djangopypi
fb25440166907b65bfbed01963e590414e41bdd5
[ "BSD-3-Clause" ]
1
2019-04-07T00:29:46.000Z
2019-04-07T00:29:46.000Z
# -*- coding: utf-8 -*- from south.utils import datetime_utils as datetime from south.db import db from south.v2 import DataMigration from django.db import models class Migration(DataMigration): def forwards(self, orm): from djangopypi.models import Package for package in Package.objects.iterator(...
73.964912
200
0.568074
from south.utils import datetime_utils as datetime from south.db import db from south.v2 import DataMigration from django.db import models class Migration(DataMigration): def forwards(self, orm): from djangopypi.models import Package for package in Package.objects.iterator(): package.s...
true
true
f77850e86801fd6b244ecfa285eeb17ebc59aa99
25,928
py
Python
Lib/site-packages/django/template/defaultfilters.py
Lucas11200/LocaPy
5d1f214c091aa3703b2ff7d3c0713a91ed4a1f48
[ "bzip2-1.0.6" ]
42
2019-03-01T09:51:13.000Z
2021-07-22T12:22:49.000Z
Lib/site-packages/django/template/defaultfilters.py
Lucas11200/LocaPy
5d1f214c091aa3703b2ff7d3c0713a91ed4a1f48
[ "bzip2-1.0.6" ]
23
2019-01-19T08:54:48.000Z
2022-03-11T23:39:37.000Z
virtual/lib/python3.6/site-packages/django/template/defaultfilters.py
eyern/instagram_clone
c18da15b35d28d91c3f63904af9d5da4e8e3e8ae
[ "MIT" ]
33
2019-10-18T17:53:53.000Z
2022-01-29T23:44:27.000Z
"""Default variable filters.""" import random as random_module import re import types from decimal import ROUND_HALF_UP, Context, Decimal, InvalidOperation from functools import wraps from operator import itemgetter from pprint import pformat from urllib.parse import quote from django.utils import formats from django....
28.555066
101
0.616476
import random as random_module import re import types from decimal import ROUND_HALF_UP, Context, Decimal, InvalidOperation from functools import wraps from operator import itemgetter from pprint import pformat from urllib.parse import quote from django.utils import formats from django.utils.dateformat import format, ...
true
true
f778515190581986a1609ad13aa00870e713d1f3
2,407
py
Python
flow/benchmarks/figureeight0.py
pcmoritz/flow
bc97132e9e2d05262bb6bbad5bda173fd9f4ae92
[ "MIT" ]
null
null
null
flow/benchmarks/figureeight0.py
pcmoritz/flow
bc97132e9e2d05262bb6bbad5bda173fd9f4ae92
[ "MIT" ]
null
null
null
flow/benchmarks/figureeight0.py
pcmoritz/flow
bc97132e9e2d05262bb6bbad5bda173fd9f4ae92
[ "MIT" ]
null
null
null
"""Benchmark for figureeight0. Trains a fraction of vehicles in a ring road structure to regulate the flow of vehicles through an intersection. In this example, the last vehicle in the network is an autonomous vehicle. Action Dimension: (1, ) Observation Dimension: (28, ) Horizon: 1500 steps """ from flow.core.par...
29
78
0.71209
from flow.core.params import SumoParams, EnvParams, InitialConfig, NetParams from flow.core.vehicles import Vehicles from flow.controllers import IDMController, ContinuousRouter, RLController from flow.scenarios.figure8.figure8_scenario import ADDITIONAL_NET_PARAMS HORIZON = 1500 vehicles = Vehicles() vehicles.add( ...
true
true
f778525db4f5d69115cdbad89c7e329297d184f7
8,485
py
Python
datadog_checks_dev/datadog_checks/dev/tooling/commands/validate/models.py
kjmadscience/integrations-core
663bdf44730dd6c9f3565c121318b320bfcb4988
[ "BSD-3-Clause" ]
null
null
null
datadog_checks_dev/datadog_checks/dev/tooling/commands/validate/models.py
kjmadscience/integrations-core
663bdf44730dd6c9f3565c121318b320bfcb4988
[ "BSD-3-Clause" ]
null
null
null
datadog_checks_dev/datadog_checks/dev/tooling/commands/validate/models.py
kjmadscience/integrations-core
663bdf44730dd6c9f3565c121318b320bfcb4988
[ "BSD-3-Clause" ]
null
null
null
# (C) Datadog, Inc. 2021-present # All rights reserved # Licensed under a 3-clause BSD style license (see LICENSE) import click from ....fs import ( chdir, dir_exists, ensure_parent_dir_exists, file_exists, path_join, read_file, read_file_lines, write_file_lines, ) from ...configuration...
36.573276
120
0.635828
import click from ....fs import ( chdir, dir_exists, ensure_parent_dir_exists, file_exists, path_join, read_file, read_file_lines, write_file_lines, ) from ...configuration import ConfigSpec from ...configuration.consumers import ModelConsumer from ...constants import get_root from ...m...
true
true
f778549eb2c44da60f4146d82200e83a00db3f7a
734
py
Python
src/pyutils/test/test_here.py
dzhang32/pyutils
dd53ce46cab916ff1f794fe9cce26c583ac25a4c
[ "MIT" ]
null
null
null
src/pyutils/test/test_here.py
dzhang32/pyutils
dd53ce46cab916ff1f794fe9cce26c583ac25a4c
[ "MIT" ]
null
null
null
src/pyutils/test/test_here.py
dzhang32/pyutils
dd53ce46cab916ff1f794fe9cce26c583ac25a4c
[ "MIT" ]
null
null
null
import pytest import os from pyutils import here def test_here_default(): assert here(__file__) == os.path.dirname(__file__) def test_here_appends_paths(): assert here(__file__, "a", "path") == os.path.join(os.path.dirname(__file__), "a", "path") def test_here_gets_abs_path(): assert here(__file__, "..")...
30.583333
103
0.69346
import pytest import os from pyutils import here def test_here_default(): assert here(__file__) == os.path.dirname(__file__) def test_here_appends_paths(): assert here(__file__, "a", "path") == os.path.join(os.path.dirname(__file__), "a", "path") def test_here_gets_abs_path(): assert here(__file__, "..")...
true
true
f77854f005a9ef54328921544a349d2cdb5ff160
11,396
py
Python
tfx/orchestration/kubeflow/kubeflow_gcp_integration_test.py
shizukanaskytree/tfx
6490e102850e91489722a49b20efef9ef64ef2d2
[ "Apache-2.0" ]
null
null
null
tfx/orchestration/kubeflow/kubeflow_gcp_integration_test.py
shizukanaskytree/tfx
6490e102850e91489722a49b20efef9ef64ef2d2
[ "Apache-2.0" ]
null
null
null
tfx/orchestration/kubeflow/kubeflow_gcp_integration_test.py
shizukanaskytree/tfx
6490e102850e91489722a49b20efef9ef64ef2d2
[ "Apache-2.0" ]
null
null
null
# Lint as: python2, python3 # Copyright 2019 Google LLC. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless req...
41.44
100
0.692787
from __future__ import absolute_import from __future__ import division from __future__ import print_function import logging import os import subprocess import sys import absl import tensorflow as tf from tfx.components.base import executor_spec from tfx.components.common_nodes.importer_node import ImporterNode from...
true
true
f778555ca73e29e71b68050b3827ab6d518dcde9
63,844
py
Python
experiment/evaluate.py
Trustworthy-Software/BATS
eb122150dff61543bd8c88ac7e08987a0a3e47e0
[ "MIT" ]
1
2022-03-17T13:17:35.000Z
2022-03-17T13:17:35.000Z
experiment/evaluate.py
HaoyeTianCoder/BATS
eb122150dff61543bd8c88ac7e08987a0a3e47e0
[ "MIT" ]
null
null
null
experiment/evaluate.py
HaoyeTianCoder/BATS
eb122150dff61543bd8c88ac7e08987a0a3e47e0
[ "MIT" ]
null
null
null
import pickle import matplotlib.pyplot as plt import numpy as np import Levenshtein import math import pandas as pd from sklearn.metrics import silhouette_score ,calinski_harabasz_score,davies_bouldin_score from scipy.spatial import distance from sklearn.preprocessing import StandardScaler, Normalizer, MinMaxScaler im...
48.922605
463
0.553051
import pickle import matplotlib.pyplot as plt import numpy as np import Levenshtein import math import pandas as pd from sklearn.metrics import silhouette_score ,calinski_harabasz_score,davies_bouldin_score from scipy.spatial import distance from sklearn.preprocessing import StandardScaler, Normalizer, MinMaxScaler im...
true
true
f778556116e4ab562e4f2cf981b39b1fde38b5f7
829
py
Python
zerver/views/muting.py
GauravVirmani/zulip
5a204d7c84d60e193f1ea0900d42848c5276a095
[ "Apache-2.0" ]
null
null
null
zerver/views/muting.py
GauravVirmani/zulip
5a204d7c84d60e193f1ea0900d42848c5276a095
[ "Apache-2.0" ]
null
null
null
zerver/views/muting.py
GauravVirmani/zulip
5a204d7c84d60e193f1ea0900d42848c5276a095
[ "Apache-2.0" ]
1
2021-06-10T15:12:52.000Z
2021-06-10T15:12:52.000Z
from __future__ import absolute_import from django.http import HttpResponse, HttpRequest from typing import List, Text from zerver.decorator import authenticated_json_post_view from zerver.lib.actions import do_set_muted_topics from zerver.lib.request import has_request_variables, REQ from zerver.lib.response import ...
39.47619
80
0.778046
from __future__ import absolute_import from django.http import HttpResponse, HttpRequest from typing import List, Text from zerver.decorator import authenticated_json_post_view from zerver.lib.actions import do_set_muted_topics from zerver.lib.request import has_request_variables, REQ from zerver.lib.response import ...
true
true
f77855a19b464d4d76987640290f4cb1f42fe546
39,334
py
Python
tensorflow/python/tools/saved_model_cli.py
monk1337/tensorflow
885577afd802204096cde524ed2a3acd9e29a75c
[ "Apache-2.0" ]
1
2016-06-13T15:21:05.000Z
2016-06-13T15:21:05.000Z
tensorflow/python/tools/saved_model_cli.py
monk1337/tensorflow
885577afd802204096cde524ed2a3acd9e29a75c
[ "Apache-2.0" ]
1
2022-02-10T00:32:22.000Z
2022-02-10T00:32:22.000Z
tensorflow/python/tools/saved_model_cli.py
monk1337/tensorflow
885577afd802204096cde524ed2a3acd9e29a75c
[ "Apache-2.0" ]
2
2020-01-16T12:41:10.000Z
2020-01-16T12:42:02.000Z
# Copyright 2017 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
39.373373
107
0.694285
from __future__ import absolute_import from __future__ import division from __future__ import print_function import argparse import collections import os import re import sys import warnings import numpy as np import six from tensorflow.core.example import example_pb2 from tensorflow.core.framework import types_pb2...
true
true
f77855af26caf086d05ab66ca72b99eb48d838b5
521
py
Python
residentadvisor/migrations/0014_auto_20200211_0537.py
lemoswilson/NewsAggregator
87da34681f12d0edb088f8bb88805667dc12dff8
[ "MIT" ]
null
null
null
residentadvisor/migrations/0014_auto_20200211_0537.py
lemoswilson/NewsAggregator
87da34681f12d0edb088f8bb88805667dc12dff8
[ "MIT" ]
8
2020-06-06T01:29:53.000Z
2022-03-12T00:16:57.000Z
residentadvisor/migrations/0014_auto_20200211_0537.py
lemoswilson/NewsAggregator
87da34681f12d0edb088f8bb88805667dc12dff8
[ "MIT" ]
null
null
null
# Generated by Django 2.2.2 on 2020-02-11 05:37 import datetime from django.db import migrations, models from django.utils.timezone import utc class Migration(migrations.Migration): dependencies = [ ('residentadvisor', '0013_auto_20200211_0535'), ] operations = [ migrations.AlterField( ...
24.809524
110
0.652591
import datetime from django.db import migrations, models from django.utils.timezone import utc class Migration(migrations.Migration): dependencies = [ ('residentadvisor', '0013_auto_20200211_0535'), ] operations = [ migrations.AlterField( model_name='residentadvisor_model', ...
true
true
f77855e7ddcd90f0f5ad64938a7de05825056938
4,423
py
Python
purity_fb/purity_fb_1dot6/models/dns_response.py
tlewis-ps/purity_fb_python_client
652835cbd485c95a86da27f8b661679727ec6ea0
[ "Apache-2.0" ]
5
2017-09-08T20:47:22.000Z
2021-06-29T02:11:05.000Z
purity_fb/purity_fb_1dot6/models/dns_response.py
tlewis-ps/purity_fb_python_client
652835cbd485c95a86da27f8b661679727ec6ea0
[ "Apache-2.0" ]
16
2017-11-27T20:57:48.000Z
2021-11-23T18:46:43.000Z
purity_fb/purity_fb_1dot6/models/dns_response.py
tlewis-ps/purity_fb_python_client
652835cbd485c95a86da27f8b661679727ec6ea0
[ "Apache-2.0" ]
22
2017-10-13T15:33:05.000Z
2021-11-08T19:56:21.000Z
# coding: utf-8 """ Pure Storage FlashBlade REST 1.6 Python SDK Pure Storage FlashBlade REST 1.6 Python SDK, developed by [Pure Storage, Inc](http://www.purestorage.com/). Documentations can be found at [purity-fb.readthedocs.io](http://purity-fb.readthedocs.io/). OpenAPI spec version: 1.6 Contact: i...
29.291391
204
0.590549
import pprint import re import six class DnsResponse(object): __test__ = False swagger_types = { 'pagination_info': 'PaginationInfo', 'items': 'list[Dns]' } attribute_map = { 'pagination_info': 'pagination_info', 'items': 'items' } def __init__(self...
true
true
f778575709f0c895cb408aaa6003a2a4d444173b
1,001
py
Python
app.py
rudzki/moldy-tweets
dc578b62c9b5b9d552f1085a8d55ea03767f93cd
[ "MIT" ]
null
null
null
app.py
rudzki/moldy-tweets
dc578b62c9b5b9d552f1085a8d55ea03767f93cd
[ "MIT" ]
null
null
null
app.py
rudzki/moldy-tweets
dc578b62c9b5b9d552f1085a8d55ea03767f93cd
[ "MIT" ]
null
null
null
from datetime import datetime, timedelta, timezone import twitter from creds import TWITTER_KEY, TWITTER_KEY_SECRET, TWITTER_TOKEN, TWITTER_TOKEN_SECRET from dateutil import tz # twitter api object api = twitter.Api(consumer_key=TWITTER_KEY, consumer_secret=TWITTER_KEY_SECRET, acce...
32.290323
87
0.675325
from datetime import datetime, timedelta, timezone import twitter from creds import TWITTER_KEY, TWITTER_KEY_SECRET, TWITTER_TOKEN, TWITTER_TOKEN_SECRET from dateutil import tz api = twitter.Api(consumer_key=TWITTER_KEY, consumer_secret=TWITTER_KEY_SECRET, access_token_key=TWITTER_...
true
true
f77857a6bba191b9236ce1fe3a5e9c361ac186c5
497
py
Python
profiles_api/urls.py
macieJJarocki/profiles-rest-api
e73c3cc4d6f9c410d65866e64ab58852c0606af4
[ "MIT" ]
null
null
null
profiles_api/urls.py
macieJJarocki/profiles-rest-api
e73c3cc4d6f9c410d65866e64ab58852c0606af4
[ "MIT" ]
3
2020-06-06T01:50:44.000Z
2021-06-09T19:04:03.000Z
profiles_api/urls.py
johannescruz/profiles-rest-api
ea7173908fc5a76f8805af4388a0f6d56246e8f1
[ "MIT" ]
null
null
null
from django.urls import path, include from rest_framework.routers import DefaultRouter from profiles_api import views router = DefaultRouter() router.register('hello-viewset', views.HelloViewSet, base_name='hello-viewset') router.register('profile', views.UserProfileViewSet) router.register('feed', views.UserProfil...
27.611111
79
0.764588
from django.urls import path, include from rest_framework.routers import DefaultRouter from profiles_api import views router = DefaultRouter() router.register('hello-viewset', views.HelloViewSet, base_name='hello-viewset') router.register('profile', views.UserProfileViewSet) router.register('feed', views.UserProfil...
true
true
f778590e306b75714c906a4ab63ec5853366867b
6,999
py
Python
coclust/coclustering/coclust_mod.py
miraaitsaada/cclust_package
4256693b424350ba3332861c7e937100f7a432c5
[ "BSD-3-Clause" ]
1
2019-01-04T00:17:46.000Z
2019-01-04T00:17:46.000Z
coclust/coclustering/coclust_mod.py
miraaitsaada/cclust_package
4256693b424350ba3332861c7e937100f7a432c5
[ "BSD-3-Clause" ]
null
null
null
coclust/coclustering/coclust_mod.py
miraaitsaada/cclust_package
4256693b424350ba3332861c7e937100f7a432c5
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- """ The :mod:`coclust.coclustering.coclust_mod` module provides an implementation of a co-clustering algorithm by direct maximization of graph modularity. """ # Author: Francois Role <francois.role@gmail.com> # Stanislas Morbieu <stanislas.morbieu@gmail.com> # License: BSD 3 clause i...
33.811594
178
0.614659
import numpy as np from sklearn.utils import check_random_state, check_array from joblib import Parallel, delayed, effective_n_jobs from ..initialization import random_init from .base_diagonal_coclust import BaseDiagonalCoclust def _fit_single(X, n_clusters, random_state, init, max_iter, tol, y=None): if...
true
true
f778592ca86ceb336a422371e997f2b187bf04b7
11,089
py
Python
couchbase/management/views.py
dfresh613/couchbase-python-client
c77af56490ed4c6d364fcf8fc1a374570de0239b
[ "Apache-2.0" ]
null
null
null
couchbase/management/views.py
dfresh613/couchbase-python-client
c77af56490ed4c6d364fcf8fc1a374570de0239b
[ "Apache-2.0" ]
null
null
null
couchbase/management/views.py
dfresh613/couchbase-python-client
c77af56490ed4c6d364fcf8fc1a374570de0239b
[ "Apache-2.0" ]
null
null
null
# # Copyright 2019, Couchbase, Inc. # All Rights Reserved # # Licensed under the Apache License, Version 2.0 (the "License") # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable l...
37.846416
163
0.618361
from enum import Enum import json from couchbase.options import forward_args from couchbase_core.client import Client from couchbase.exceptions import HTTPException, ErrorMapper from couchbase.options import OptionBlockTimeOut import couchbase_core._libcouchbase as _LCB class DesignDocumentNamespace(Enum): PROD...
true
true
f778598b352c573d25c8de84b32963310330c4cd
8,353
py
Python
main.py
XingyuXie/PKUAutoSubmit
e23643b8ce849a2b6911ace609e40b05ac6d3dc3
[ "Apache-2.0" ]
null
null
null
main.py
XingyuXie/PKUAutoSubmit
e23643b8ce849a2b6911ace609e40b05ac6d3dc3
[ "Apache-2.0" ]
null
null
null
main.py
XingyuXie/PKUAutoSubmit
e23643b8ce849a2b6911ace609e40b05ac6d3dc3
[ "Apache-2.0" ]
null
null
null
from selenium.webdriver.support import expected_conditions as EC from selenium.webdriver.support.ui import WebDriverWait from selenium.webdriver.support.ui import Select from selenium.webdriver.common.keys import Keys from selenium.webdriver.common.by import By from selenium.webdriver import Firefox, Chrome, PhantomJS ...
31.881679
92
0.675805
from selenium.webdriver.support import expected_conditions as EC from selenium.webdriver.support.ui import WebDriverWait from selenium.webdriver.support.ui import Select from selenium.webdriver.common.keys import Keys from selenium.webdriver.common.by import By from selenium.webdriver import Firefox, Chrome, PhantomJS ...
true
true
f7785c23569d395777502a80fd0c3d3cc081c5c9
1,295
py
Python
tools/config/open_source_test/database_table_schema.py
ibyte2011/LaserDB
326fa477c4cbee36f46706ecb3b4a48d3bdab057
[ "Apache-2.0" ]
26
2021-01-07T09:32:37.000Z
2022-02-17T04:00:03.000Z
tools/config/open_source_test/database_table_schema.py
imotai/LaserDB
16f02fe001751b26e4221f54f9d3e2ca8c1a0607
[ "Apache-2.0" ]
1
2021-09-01T09:16:53.000Z
2021-12-04T02:25:15.000Z
tools/config/open_source_test/database_table_schema.py
imotai/LaserDB
16f02fe001751b26e4221f54f9d3e2ca8c1a0607
[ "Apache-2.0" ]
10
2021-01-21T06:26:46.000Z
2022-02-08T02:41:23.000Z
# -*- coding: UTF8 -*- # vim: set expandtab tabstop=2 shiftwidth=2 softtabstop=2 foldmethod=marker: # import json # 本地 db 规则: # # /data/group_name/node_id/database_name/table_name/partition_id/ # /source_data/base/database_name/table_name/partition_id/version # /source_data/delta/database_name/table_name/partition_id...
22.719298
85
0.570656
import json def get_config() : config = [ { "DatabaseName" : "test", "Tables" : [ { "TableName" : "test", "PartitionNumber": 10, "ConfigName": "default", }, ] } ] return json.dumps(config);
true
true
f7785d0827b4db60b41bede352383c550e15d678
3,872
py
Python
web/addons/account/report/account_treasury_report.py
diogocs1/comps
63df07f6cf21c41e4527c06e2d0499f23f4322e7
[ "Apache-2.0" ]
1
2019-12-29T11:53:56.000Z
2019-12-29T11:53:56.000Z
odoo/addons/account/report/account_treasury_report.py
tuanquanghpvn/odoo8-tutorial
52d25f1ca5f233c431cb9d3b24b79c3b4fb5127e
[ "MIT" ]
null
null
null
odoo/addons/account/report/account_treasury_report.py
tuanquanghpvn/odoo8-tutorial
52d25f1ca5f233c431cb9d3b24b79c3b4fb5127e
[ "MIT" ]
3
2020-10-08T14:42:10.000Z
2022-01-28T14:12:29.000Z
# -*- coding: utf-8 -*- ############################################################################## # # OpenERP, Open Source Management Solution # Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>). # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU...
46.650602
151
0.620351
from openerp import tools from openerp.osv import fields,osv import openerp.addons.decimal_precision as dp class account_treasury_report(osv.osv): _name = "account.treasury.report" _description = "Treasury Analysis" _auto = False def _compute_balances(self, cr, uid, ids, field_names, arg=None, contex...
true
true
f7785e42f3f95dba8ae866bab227e8992db561c5
2,501
py
Python
tensorflow_datasets/image_classification/flowers.py
shubhamkumaR630/datasets
fe9ee91849cefed0953141ea3588f73b7def78fd
[ "Apache-2.0" ]
2
2022-02-14T09:51:39.000Z
2022-02-14T13:27:49.000Z
tensorflow_datasets/image_classification/flowers.py
shubhamkumaR630/datasets
fe9ee91849cefed0953141ea3588f73b7def78fd
[ "Apache-2.0" ]
null
null
null
tensorflow_datasets/image_classification/flowers.py
shubhamkumaR630/datasets
fe9ee91849cefed0953141ea3588f73b7def78fd
[ "Apache-2.0" ]
1
2020-12-13T22:11:33.000Z
2020-12-13T22:11:33.000Z
# coding=utf-8 # Copyright 2022 The TensorFlow Datasets Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by appl...
31.2625
75
0.665734
import os import tensorflow_datasets.public_api as tfds _CITATION = """\ @ONLINE {tfflowers, author = "The TensorFlow Team", title = "Flowers", month = "jan", year = "2019", url = "http://download.tensorflow.org/example_images/flower_photos.tgz" } """ _URL = "http://download.tensorflow.org/example_images/flower_ph...
true
true
f7785f4086b291d8664ca385523212eb22eeeff3
375
py
Python
day21/day21.py
throx/advent2021
2295a65e14a8defacd3e83229985c97134c21501
[ "Unlicense" ]
1
2021-12-05T14:19:59.000Z
2021-12-05T14:19:59.000Z
day21/day21.py
throx/advent2021
2295a65e14a8defacd3e83229985c97134c21501
[ "Unlicense" ]
null
null
null
day21/day21.py
throx/advent2021
2295a65e14a8defacd3e83229985c97134c21501
[ "Unlicense" ]
null
null
null
import functools @functools.cache def play(pos1, pos2, score1=0, score2=0): if score2 >= 3: return 0, 1 wins1, wins2 = 0, 0 for move, n in (3,1),(4,3),(5,6),(6,7),(7,6),(8,3),(9,1): pos1_ = (pos1 + move) % 10 or 10 w2, w1 = play(pos2, pos1_, score2, score1 + pos1_) wins1, wins2 = wins1 + n*w1,...
25
59
0.578667
import functools @functools.cache def play(pos1, pos2, score1=0, score2=0): if score2 >= 3: return 0, 1 wins1, wins2 = 0, 0 for move, n in (3,1),(4,3),(5,6),(6,7),(7,6),(8,3),(9,1): pos1_ = (pos1 + move) % 10 or 10 w2, w1 = play(pos2, pos1_, score2, score1 + pos1_) wins1, wins2 = wins1 + n*w1,...
true
true
f778620531ef34c515258a82942add409c58a0d9
2,352
py
Python
holmes/migrations/versions/4cf3e398a81f_change_keys_of_facters_and_violations.py
scorphus/holmes-api
6b3c76d4299fecf2d8799d7b5c3c6a6442cacd59
[ "MIT" ]
null
null
null
holmes/migrations/versions/4cf3e398a81f_change_keys_of_facters_and_violations.py
scorphus/holmes-api
6b3c76d4299fecf2d8799d7b5c3c6a6442cacd59
[ "MIT" ]
null
null
null
holmes/migrations/versions/4cf3e398a81f_change_keys_of_facters_and_violations.py
scorphus/holmes-api
6b3c76d4299fecf2d8799d7b5c3c6a6442cacd59
[ "MIT" ]
null
null
null
"""change_keys_of_facters_and_violations_to_separated_table Revision ID: 4cf3e398a81f Revises: 21087e990aa8 Create Date: 2013-12-04 17:42:02.709200 """ # revision identifiers, used by Alembic. revision = '4cf3e398a81f' down_revision = '21087e990aa8' from alembic import op import sqlalchemy as sa def upgrade(): ...
31.783784
129
0.637755
revision = '4cf3e398a81f' down_revision = '21087e990aa8' from alembic import op import sqlalchemy as sa def upgrade(): connection = op.get_bind() op.create_table( 'keys', sa.Column('id', sa.Integer, primary_key=True), sa.Column('name', sa.String(2000), nullable=False) ) op.a...
true
true
f7786399859247f7d2c5d0f69cbf7dd2cc49a49d
7,183
py
Python
cairis/gui/CodingTextCtrl.py
nathanjenx/cairis
06d2d592b64af20746b9a2713551db597af46805
[ "Apache-2.0" ]
null
null
null
cairis/gui/CodingTextCtrl.py
nathanjenx/cairis
06d2d592b64af20746b9a2713551db597af46805
[ "Apache-2.0" ]
null
null
null
cairis/gui/CodingTextCtrl.py
nathanjenx/cairis
06d2d592b64af20746b9a2713551db597af46805
[ "Apache-2.0" ]
null
null
null
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may...
36.095477
98
0.714325
import wx import wx.richtext from cairis.core.armid import * from cairis.core.ARM import * from cairis.core.Borg import Borg from DimensionNameDialog import DimensionNameDialog from CodeDialog import CodeDialog from MemoDialog import MemoDialog from cairis.core.MemoParameters import MemoParameters from DialogClassPar...
true
true
f77863ba98745dbcd793a73a6a17a23fa44e8fc3
13,499
py
Python
detectron/datasets/task_evaluation.py
At1a8/DeepPest
ea224268906c10ae92824c58492c19782279534b
[ "Apache-2.0" ]
5
2019-01-21T03:19:39.000Z
2021-04-13T06:29:06.000Z
detectron/datasets/task_evaluation.py
At1a8/DeepPest
ea224268906c10ae92824c58492c19782279534b
[ "Apache-2.0" ]
1
2020-11-02T01:02:38.000Z
2021-03-17T10:13:22.000Z
detectron/datasets/task_evaluation.py
At1a8/DeepPest
ea224268906c10ae92824c58492c19782279534b
[ "Apache-2.0" ]
1
2020-04-28T15:57:20.000Z
2020-04-28T15:57:20.000Z
# Copyright (c) 2017-present, Facebook, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed...
34.436224
123
0.602267
from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals from collections import OrderedDict import logging import os import pprint from detectron.core.config import cfg from detectron.utils.logging import send_email import ...
true
true
f7786408bb7b85d359ff111f719bd5d98fbf7772
422
py
Python
robots/LoCoBot/locobot_navigation/orb_slam2_ros/setup.py
stuart-fb/pyrobot
2f06f337f84e2c0b172dcf5ee0cd8c7de73a50e1
[ "MIT" ]
6
2020-03-08T00:56:25.000Z
2021-05-21T03:32:37.000Z
robots/LoCoBot/locobot_navigation/orb_slam2_ros/setup.py
stuart-fb/pyrobot
2f06f337f84e2c0b172dcf5ee0cd8c7de73a50e1
[ "MIT" ]
16
2020-01-28T22:49:47.000Z
2022-03-11T23:51:24.000Z
robots/LoCoBot/locobot_navigation/orb_slam2_ros/setup.py
stuart-fb/pyrobot
2f06f337f84e2c0b172dcf5ee0cd8c7de73a50e1
[ "MIT" ]
2
2020-06-04T00:59:50.000Z
2020-10-16T05:43:48.000Z
#!/usr/bin/env python # Copyright (c) Facebook, Inc. and its affiliates. # This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. from distutils.core import setup from catkin_pkg.python_setup import generate_distutils_setup setup_args = generate_dis...
24.823529
65
0.760664
from distutils.core import setup from catkin_pkg.python_setup import generate_distutils_setup setup_args = generate_distutils_setup( packages=['orb_slam2_ros'], package_dir={'': 'scripts'}, ) setup(**setup_args)
true
true
f7786457ea2527d4d0c5f51ccf22618103d1e56d
5,813
py
Python
venv/Lib/site-packages/selenium/webdriver/common/service.py
gilbertekalea/booking.com_crawler
71e52c87cd72a77f80a3e5fc0af0e1a68a5712ae
[ "MIT" ]
25,151
2015-01-01T15:40:17.000Z
2022-03-31T18:44:03.000Z
venv/Lib/site-packages/selenium/webdriver/common/service.py
gilbertekalea/booking.com_crawler
71e52c87cd72a77f80a3e5fc0af0e1a68a5712ae
[ "MIT" ]
9,885
2015-01-03T17:53:00.000Z
2022-03-31T21:48:12.000Z
venv/Lib/site-packages/selenium/webdriver/common/service.py
gilbertekalea/booking.com_crawler
71e52c87cd72a77f80a3e5fc0af0e1a68a5712ae
[ "MIT" ]
8,441
2015-01-05T09:36:44.000Z
2022-03-31T19:58:06.000Z
# Licensed to the Software Freedom Conservancy (SFC) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The SFC licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not...
33.217143
95
0.561672
from subprocess import DEVNULL import errno import os import subprocess from platform import system from subprocess import PIPE from time import sleep from selenium.common.exceptions import WebDriverException from selenium.webdriver.common import utils _HAS_NATIVE_DEVNULL = True class Service(object): def __i...
true
true
f77864c4cfd26f3a56f9aaf7d3b7102a932133f3
4,467
py
Python
Projects/plant_monitor/plant_project.py
joemarshall/GrovePi
d128ab734f216f5b2d82c1b629cfca3f31af4993
[ "MIT" ]
1
2021-04-18T05:52:03.000Z
2021-04-18T05:52:03.000Z
Projects/plant_monitor/plant_project.py
joemarshall/GrovePi
d128ab734f216f5b2d82c1b629cfca3f31af4993
[ "MIT" ]
null
null
null
Projects/plant_monitor/plant_project.py
joemarshall/GrovePi
d128ab734f216f5b2d82c1b629cfca3f31af4993
[ "MIT" ]
2
2017-07-25T13:56:56.000Z
2019-12-02T09:32:01.000Z
#!/usr/bin/env python # # GrovePi Project for a Plant monitoring project. # * Reads the data from moisture, light, temperature and humidity sensor # and takes pictures from the Pi camera periodically and logs them # * Sensor Connections on the GrovePi: # -> Grove Moisture sensor - Port A1 # -> Grove light sensor ...
34.361538
139
0.746586
import time import grovepi import subprocess import math mositure_sensor = 1 light_sensor = 2 temp_himidity_sensor = 4 blue=0 white=1 time_for_sensor = 4 time_for_picture = 12 time_to_sleep = 1 log_file="plant_monitor_log.csv" def read_sensor(): try: moisture=grovepi.analogRead(mositure_sensor) ligh...
true
true
f778650de4114bb290fdb9738b63a98d6f54a036
4,412
py
Python
sa/profiles/Cisco/NXOS/get_lldp_neighbors.py
prorevizor/noc
37e44b8afc64318b10699c06a1138eee9e7d6a4e
[ "BSD-3-Clause" ]
84
2017-10-22T11:01:39.000Z
2022-02-27T03:43:48.000Z
sa/profiles/Cisco/NXOS/get_lldp_neighbors.py
prorevizor/noc
37e44b8afc64318b10699c06a1138eee9e7d6a4e
[ "BSD-3-Clause" ]
22
2017-12-11T07:21:56.000Z
2021-09-23T02:53:50.000Z
sa/profiles/Cisco/NXOS/get_lldp_neighbors.py
prorevizor/noc
37e44b8afc64318b10699c06a1138eee9e7d6a4e
[ "BSD-3-Clause" ]
23
2017-12-06T06:59:52.000Z
2022-02-24T00:02:25.000Z
# --------------------------------------------------------------------- # Cisco.NXOS.get_lldp_neighbors # --------------------------------------------------------------------- # Copyright (C) 2007-2019 The NOC Project # See LICENSE for details # --------------------------------------------------------------------- # P...
38.701754
100
0.481641
import re from noc.core.script.base import BaseScript from noc.sa.interfaces.igetlldpneighbors import IGetLLDPNeighbors from noc.sa.interfaces.base import MACAddressParameter from noc.core.validators import is_int, is_ipv4 class Script(BaseScript): name = "Cisco.NXOS.get_lldp_neighbors" interface = IGetLLDP...
true
true
f77865b6ec3880ce247ab3dd7dc4c4b048a9c5dc
23,228
py
Python
chapter08/maze.py
FHsong/reinforcement-learning-an-introduction
4eb5b36a5d59487ae1c3ea6cc90010c11bda5897
[ "MIT" ]
null
null
null
chapter08/maze.py
FHsong/reinforcement-learning-an-introduction
4eb5b36a5d59487ae1c3ea6cc90010c11bda5897
[ "MIT" ]
null
null
null
chapter08/maze.py
FHsong/reinforcement-learning-an-introduction
4eb5b36a5d59487ae1c3ea6cc90010c11bda5897
[ "MIT" ]
null
null
null
####################################################################### # Copyright (C) # # 2016-2018 Shangtong Zhang(zhangshangtong.cpp@gmail.com) # # 2016 Kenta Shimada(hyperkentakun@gmail.com) # # Permission given to modify the...
35.247344
119
0.622869
import numpy as np import matplotlib matplotlib.use('Agg') import matplotlib.pyplot as plt from tqdm import tqdm import heapq from copy import deepcopy class PriorityQueue: def __init__(self): self.pq = [] self.entry_finder = {} self.REMOVED = '<removed-task>' self.counter = 0 ...
true
true
f7786683d3da06a2e402048da13d51ab5af72be8
5,611
py
Python
pyscilog/wrapper.py
gijzelaerr/pyscilog
b0159723181efac0c23e76b51b66a1a9363a6ade
[ "MIT" ]
null
null
null
pyscilog/wrapper.py
gijzelaerr/pyscilog
b0159723181efac0c23e76b51b66a1a9363a6ade
[ "MIT" ]
2
2021-03-16T10:35:22.000Z
2021-03-16T14:36:06.000Z
pyscilog/wrapper.py
gijzelaerr/pyscilog
b0159723181efac0c23e76b51b66a1a9363a6ade
[ "MIT" ]
null
null
null
import logging import sys from re import sub from pyscilog.filter import LogFilter from pyscilog.writer import Writer from pyscilog.state import State state = State() log_filter = LogFilter() fmt = "%(asctime)s - %(shortname)-18.18s %(subprocess)s%(memory)s%(separator)s%(message)s" datefmt = '%H:%M:%S' # '%H:%M:%S.%f...
36.914474
118
0.655855
import logging import sys from re import sub from pyscilog.filter import LogFilter from pyscilog.writer import Writer from pyscilog.state import State state = State() log_filter = LogFilter() fmt = "%(asctime)s - %(shortname)-18.18s %(subprocess)s%(memory)s%(separator)s%(message)s" datefmt = '%H:%M:%S' null_handler ...
true
true
f77866f288effbc87144afaa07598188bb07c090
1,864
py
Python
ros2topic/test/test_primitives.py
rarvolt/ros2cli
451bb5268daabc77a2808e12898192a48c07ef07
[ "Apache-2.0" ]
null
null
null
ros2topic/test/test_primitives.py
rarvolt/ros2cli
451bb5268daabc77a2808e12898192a48c07ef07
[ "Apache-2.0" ]
null
null
null
ros2topic/test/test_primitives.py
rarvolt/ros2cli
451bb5268daabc77a2808e12898192a48c07ef07
[ "Apache-2.0" ]
1
2019-01-02T18:57:16.000Z
2019-01-02T18:57:16.000Z
# Copyright 2017 Open Source Robotics Foundation, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law...
41.422222
75
0.786481
from argparse import Namespace from ros2topic.verb.echo import DEFAULT_TRUNCATE_LENGTH from ros2topic.verb.echo import msg_to_csv from ros2topic.verb.echo import msg_to_yaml from ros2topic.verb.echo import register_yaml_representer from test_msgs import message_fixtures def test_primitives(): register_yaml_repr...
true
true
f77867ff5aec001b1878e93357728d00b2f41f60
144,776
py
Python
src/unity/python/turicreate/test/test_sframe.py
BitJetKit/turicreate
4fc93fb8873b90a1a57da499db4ca710e78f1478
[ "BSD-3-Clause" ]
null
null
null
src/unity/python/turicreate/test/test_sframe.py
BitJetKit/turicreate
4fc93fb8873b90a1a57da499db4ca710e78f1478
[ "BSD-3-Clause" ]
null
null
null
src/unity/python/turicreate/test/test_sframe.py
BitJetKit/turicreate
4fc93fb8873b90a1a57da499db4ca710e78f1478
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright © 2017 Apple Inc. All rights reserved. # # Use of this source code is governed by a BSD-3-clause license that can # be found in the LICENSE.txt file or at https://opensource.org/licenses/BSD-3-Clause from __future__ import print_function as _ from __future__ import division as _ from...
40.781972
191
0.570046
from __future__ import print_function as _ from __future__ import division as _ from __future__ import absolute_import as _ from ..data_structures.sframe import SFrame from ..data_structures.sarray import SArray from ..data_structures.image import Image from ..util import _assert_sframe_equal, generate_random_sframe fr...
true
true
f778693100a12491c3b3d9402d17a819cf8e66c0
724
py
Python
sermacs_workshop/tests/test_list_util.py
whitneyjmorgan/SERMACS_is_really_cold
94e178793b0d2d1616bb9eefb397904e397d6712
[ "BSD-3-Clause" ]
null
null
null
sermacs_workshop/tests/test_list_util.py
whitneyjmorgan/SERMACS_is_really_cold
94e178793b0d2d1616bb9eefb397904e397d6712
[ "BSD-3-Clause" ]
null
null
null
sermacs_workshop/tests/test_list_util.py
whitneyjmorgan/SERMACS_is_really_cold
94e178793b0d2d1616bb9eefb397904e397d6712
[ "BSD-3-Clause" ]
null
null
null
""" Tests for list_util module """ # Import package, test suite, and other packages as needed import sermacs_workshop as acs import pytest import sys def test_title_case(): """Sample test, will always pass so long as import statement worked""" test_string = 'this IS a Test sTrinG' title_string = acs.title...
24.965517
74
0.701657
import sermacs_workshop as acs import pytest import sys def test_title_case(): test_string = 'this IS a Test sTrinG' title_string = acs.title_case(test_string) print(title_string) assert title_string == 'This Is A Test String' return True @pytest.mark.other def test_type_failure(): test_input...
true
true
f77869947955c78fa2258ea88c676ac556daef3f
5,101
py
Python
nova/tests/api/openstack/compute/contrib/test_hide_server_addresses.py
NetApp/nova
ca490d48a762a423449c654d5a7caeadecf2f6ca
[ "Apache-2.0" ]
2
2015-11-05T04:52:34.000Z
2016-03-07T03:00:06.000Z
nova/tests/api/openstack/compute/contrib/test_hide_server_addresses.py
NetApp/nova
ca490d48a762a423449c654d5a7caeadecf2f6ca
[ "Apache-2.0" ]
1
2018-01-19T07:50:49.000Z
2018-01-19T07:50:49.000Z
nova/tests/api/openstack/compute/contrib/test_hide_server_addresses.py
NetApp/nova
ca490d48a762a423449c654d5a7caeadecf2f6ca
[ "Apache-2.0" ]
1
2020-07-24T07:32:11.000Z
2020-07-24T07:32:11.000Z
# Copyright 2012 OpenStack Foundation # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless requ...
33.559211
78
0.658498
import itertools from lxml import etree import webob from nova.api.openstack import wsgi from nova import compute from nova.compute import vm_states from nova import exception from nova.openstack.common import jsonutils from nova import test from nova.tests.api.openstack import fakes SENTINEL = object() def fake...
true
true
f77869af8240afca82f809d741ca7fa022c5b28b
451
py
Python
HashTable/202. Happy Number.py
thewires2/Leetcode
a37ff81d60dd9195ba637b970b40aabbea5f4680
[ "Unlicense" ]
1
2021-06-30T17:51:56.000Z
2021-06-30T17:51:56.000Z
HashTable/202. Happy Number.py
thewires2/Leetcode
a37ff81d60dd9195ba637b970b40aabbea5f4680
[ "Unlicense" ]
null
null
null
HashTable/202. Happy Number.py
thewires2/Leetcode
a37ff81d60dd9195ba637b970b40aabbea5f4680
[ "Unlicense" ]
null
null
null
class Solution: def isHappy(self, n: int) -> bool: x=[] def Happy(n,x): t,k=0,0 while n>0: t=n%10 n=n//10 k=k+t*t if k==1: return True else: if k in x: ...
23.736842
38
0.314856
class Solution: def isHappy(self, n: int) -> bool: x=[] def Happy(n,x): t,k=0,0 while n>0: t=n%10 n=n//10 k=k+t*t if k==1: return True else: if k in x: ...
true
true
f7786a5d8c183c5369b7164573b171aa00646735
15,611
py
Python
venv/Lib/site-packages/twilio/rest/monitor/v1/event.py
Kenny-Z/IOT-Message-Board-with-Face-Recognition
81b9a778ebf850b9f78e5d18a52720bd78593565
[ "MIT" ]
4
2020-11-13T02:31:25.000Z
2020-12-24T22:04:30.000Z
twilio/rest/monitor/v1/event.py
Sephra1/twilio-python
7dd04209e2d38a31c2783ee8f8ae8be6222a43f2
[ "MIT" ]
7
2020-06-03T19:08:42.000Z
2021-09-22T19:08:32.000Z
bot/lib/python3.7/site-packages/twilio/rest/monitor/v1/event.py
carlosrh18/DavinciBot
d73a6b7f68d7bab25d134d3f85c6b63a86c206c5
[ "MIT" ]
1
2020-06-03T19:22:39.000Z
2020-06-03T19:22:39.000Z
# coding=utf-8 r""" This code was generated by \ / _ _ _| _ _ | (_)\/(_)(_|\/| |(/_ v1.0.0 / / """ from twilio.base import deserialize from twilio.base import serialize from twilio.base import values from twilio.base.instance_context import InstanceContext from twilio.base.instance_resource import...
34.234649
98
0.62078
from twilio.base import deserialize from twilio.base import serialize from twilio.base import values from twilio.base.instance_context import InstanceContext from twilio.base.instance_resource import InstanceResource from twilio.base.list_resource import ListResource from twilio.base.page import Page class EventList...
true
true
f7786b730f1a8764e4a8b4dd69dacc1936263227
298
py
Python
missions/Road To Centurion/1.3 Going In Circles.py
thecnoNSMB/ktane-mission-solver
237d969a8acd21533b5fb18cc5a47dd03ba1cc7d
[ "MIT" ]
1
2022-01-04T03:47:34.000Z
2022-01-04T03:47:34.000Z
missions/Road To Centurion/1.3 Going In Circles.py
thecnoNSMB/ktane-mission-solver
237d969a8acd21533b5fb18cc5a47dd03ba1cc7d
[ "MIT" ]
4
2021-04-13T07:03:37.000Z
2021-12-15T11:34:05.000Z
missions/Road To Centurion/1.3 Going In Circles.py
thecnoNSMB/ktane-mission-solver
237d969a8acd21533b5fb18cc5a47dd03ba1cc7d
[ "MIT" ]
null
null
null
from ktane.directors import BombSolver, from_pool from ktane.mods.f import FollowTheLeader from ktane.vanilla import Wires, ComplicatedWires, WireSequence BombSolver( Wires(), ComplicatedWires(), WireSequence(), FollowTheLeader(), *from_pool(Wires, ComplicatedWires) ).solve()
24.833333
63
0.758389
from ktane.directors import BombSolver, from_pool from ktane.mods.f import FollowTheLeader from ktane.vanilla import Wires, ComplicatedWires, WireSequence BombSolver( Wires(), ComplicatedWires(), WireSequence(), FollowTheLeader(), *from_pool(Wires, ComplicatedWires) ).solve()
true
true
f7786c2539cd275f3f91c2f92409d80887b68330
720
py
Python
project/books/forms.py
spyderboy/flask-book-notes
507f3c964594c0e133350f3c3bd9eb45cd909dbd
[ "MIT" ]
null
null
null
project/books/forms.py
spyderboy/flask-book-notes
507f3c964594c0e133350f3c3bd9eb45cd909dbd
[ "MIT" ]
1
2021-06-02T01:47:38.000Z
2021-06-02T01:47:38.000Z
project/books/forms.py
spyderboy/flask-book-notes
507f3c964594c0e133350f3c3bd9eb45cd909dbd
[ "MIT" ]
null
null
null
from flask_wtf import FlaskForm from wtforms import TextField from wtforms.validators import DataRequired, Length from wtforms.fields.html5 import DateField class BooksForm(FlaskForm): title = TextField('Title', validators=[DataRequired(), Length(min=1, max=254)]) autho...
36
65
0.630556
from flask_wtf import FlaskForm from wtforms import TextField from wtforms.validators import DataRequired, Length from wtforms.fields.html5 import DateField class BooksForm(FlaskForm): title = TextField('Title', validators=[DataRequired(), Length(min=1, max=254)]) autho...
true
true
f7786c900d82ac7a7221ecd29ad75c4cb15de84c
2,424
py
Python
packit_service/service/api/__init__.py
IceWreck/packit-service
ab8a3ae7b7f078f4a5bf3465516c1abc894fe3dc
[ "MIT" ]
null
null
null
packit_service/service/api/__init__.py
IceWreck/packit-service
ab8a3ae7b7f078f4a5bf3465516c1abc894fe3dc
[ "MIT" ]
null
null
null
packit_service/service/api/__init__.py
IceWreck/packit-service
ab8a3ae7b7f078f4a5bf3465516c1abc894fe3dc
[ "MIT" ]
null
null
null
# MIT License # # Copyright (c) 2019 Red Hat, Inc. # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge...
41.793103
80
0.804043
from flask import Blueprint from packit_service.service.api.koji_builds import koji_builds_ns try: from flask_restx import Api except ModuleNotFoundError: from flask_restplus import Api from packit_service.service.api.copr_builds import ns as copr_builds_ns from packit_service.service.api.srpm_builds import ...
true
true
f7786c9b3d4f72500c71407a0685c6f6b12a9c26
415
py
Python
timberr/core/migrations/0009_auto_20200119_2143.py
luckyadogun/timberinvoice
07dd3435eed7e1985307b2c6dcdf81536189a014
[ "MIT" ]
1
2021-01-01T01:09:39.000Z
2021-01-01T01:09:39.000Z
timberr/core/migrations/0009_auto_20200119_2143.py
luckyadogun/timberinvoice
07dd3435eed7e1985307b2c6dcdf81536189a014
[ "MIT" ]
null
null
null
timberr/core/migrations/0009_auto_20200119_2143.py
luckyadogun/timberinvoice
07dd3435eed7e1985307b2c6dcdf81536189a014
[ "MIT" ]
null
null
null
# Generated by Django 2.1.15 on 2020-01-19 20:43 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('core', '0008_auto_20200119_2142'), ] operations = [ migrations.AlterField( model_name='user', name='office_telephon...
21.842105
73
0.612048
from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('core', '0008_auto_20200119_2142'), ] operations = [ migrations.AlterField( model_name='user', name='office_telephone', field=models.CharField(blank=True...
true
true
f7786cc333f5c47580677c563914a3d49901dc05
4,090
py
Python
venv/Lib/site-packages/gensim/scripts/glove2word2vec.py
arnoyu-hub/COMP0016miemie
59af664dcf190eab4f93cefb8471908717415fea
[ "MIT" ]
null
null
null
venv/Lib/site-packages/gensim/scripts/glove2word2vec.py
arnoyu-hub/COMP0016miemie
59af664dcf190eab4f93cefb8471908717415fea
[ "MIT" ]
null
null
null
venv/Lib/site-packages/gensim/scripts/glove2word2vec.py
arnoyu-hub/COMP0016miemie
59af664dcf190eab4f93cefb8471908717415fea
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- # # Copyright (C) 2016 Radim Rehurek <radimrehurek@seznam.cz> # Copyright (C) 2016 Manas Ranjan Kar <manasrkar91@gmail.com> # Licensed under the GNU LGPL v2.1 - http://www.gnu.org/licenses/lgpl.html """This script allows to convert GloVe vectors into the word2vec....
32.204724
119
0.669682
import sys import logging import argparse from gensim import utils from gensim.utils import deprecated from gensim.models.keyedvectors import KeyedVectors logger = logging.getLogger(__name__) def get_glove_info(glove_file_name): with utils.open(glove_file_name, 'rb') as f: num_lines = s...
true
true
f7786dba0f1ec88cf5f1fa87dd54c9e93f700037
6,015
py
Python
examples/utils.py
pbmanis/pyqtgraph
3558216be2b50d6b0069c82e51e5a048dad34c73
[ "MIT" ]
150
2018-03-27T16:45:37.000Z
2022-03-30T03:47:56.000Z
examples/utils.py
Jhongesell/pyqtgraph
229f650adfd04053213fe6567d6308a4751a349b
[ "MIT" ]
34
2018-09-28T00:01:59.000Z
2022-03-21T15:40:02.000Z
examples/utils.py
Jhongesell/pyqtgraph
229f650adfd04053213fe6567d6308a4751a349b
[ "MIT" ]
40
2018-04-06T19:42:21.000Z
2022-01-11T00:34:17.000Z
from __future__ import division, print_function, absolute_import import subprocess import time import os import sys import errno from pyqtgraph.pgcollections import OrderedDict from pyqtgraph.python2_3 import basestring path = os.path.abspath(os.path.dirname(__file__)) examples = OrderedDict([ ('Command-line usa...
34.176136
141
0.585702
from __future__ import division, print_function, absolute_import import subprocess import time import os import sys import errno from pyqtgraph.pgcollections import OrderedDict from pyqtgraph.python2_3 import basestring path = os.path.abspath(os.path.dirname(__file__)) examples = OrderedDict([ ('Command-line usa...
true
true
f7786f16bc7d370b488ae96142d12d44b202246c
6,873
py
Python
custom_components/brink_home/core/brink_home_cloud.py
samuolis/brink
50beca63e5f1d864a982675671c8b4d92d3249c5
[ "MIT" ]
1
2022-03-01T19:47:04.000Z
2022-03-01T19:47:04.000Z
custom_components/brink_home/core/brink_home_cloud.py
samuolis/brink
50beca63e5f1d864a982675671c8b4d92d3249c5
[ "MIT" ]
1
2022-03-18T08:15:02.000Z
2022-03-18T13:22:13.000Z
custom_components/brink_home/core/brink_home_cloud.py
samuolis/brink
50beca63e5f1d864a982675671c8b4d92d3249c5
[ "MIT" ]
null
null
null
"""Implementation for Brink-Home Cloud""" import asyncio import async_timeout import logging import aiohttp from ..const import API_URL, NAMES, MODES, MODE_TO_VALUE _LOGGER = logging.getLogger(__name__) class BrinkHomeCloud: """Interacts with Brink Home via public API.""" def __init__(self, session: aiohtt...
29.371795
100
0.532664
import asyncio import async_timeout import logging import aiohttp from ..const import API_URL, NAMES, MODES, MODE_TO_VALUE _LOGGER = logging.getLogger(__name__) class BrinkHomeCloud: def __init__(self, session: aiohttp.ClientSession, username: str, password: str): self.timeout = 20 self.headers...
true
true
f7786fb7f73d6489e8d2fc52aaf6cd1cd60c1dc2
6,490
py
Python
students/tests/test_command.py
PyDev777/studentsdb
9fd7f7a66b6fe346ad0bc742f154dead5e72f561
[ "MIT" ]
11
2016-12-05T19:07:05.000Z
2022-02-15T07:21:28.000Z
students/tests/test_command.py
PyDev777/studentsdb
9fd7f7a66b6fe346ad0bc742f154dead5e72f561
[ "MIT" ]
null
null
null
students/tests/test_command.py
PyDev777/studentsdb
9fd7f7a66b6fe346ad0bc742f154dead5e72f561
[ "MIT" ]
4
2016-12-06T07:22:30.000Z
2018-09-25T09:56:50.000Z
from django.core.management import call_command from django.test import TestCase from django.utils.six import StringIO import os from django.contrib.auth.models import User from students.models import Student, Group from django.test import override_settings class FillDBTest(TestCase): """Test fill_db command""" ...
36.666667
92
0.608475
from django.core.management import call_command from django.test import TestCase from django.utils.six import StringIO import os from django.contrib.auth.models import User from students.models import Student, Group from django.test import override_settings class FillDBTest(TestCase): """Test fill_db command""" ...
false
true
f778700c927fd721487df1e626d81a504dd93bd9
1,425
py
Python
parsl/configs/midway_ipp_multicore.py
benclifford/parsl
21f8681882779050d2e074591e95ada43789748f
[ "Apache-2.0" ]
2
2019-02-25T16:43:30.000Z
2019-03-04T17:25:00.000Z
parsl/configs/midway_ipp_multicore.py
benclifford/parsl
21f8681882779050d2e074591e95ada43789748f
[ "Apache-2.0" ]
null
null
null
parsl/configs/midway_ipp_multicore.py
benclifford/parsl
21f8681882779050d2e074591e95ada43789748f
[ "Apache-2.0" ]
2
2019-04-30T13:46:23.000Z
2019-06-04T16:14:46.000Z
from parsl.channels import SSHChannel from parsl.providers import SlurmProvider from parsl.launchers import SingleNodeLauncher from parsl.config import Config from parsl.executors.ipp import IPyParallelExecutor from parsl.executors.ipp_controller import Controller # This is an example config, make sure to # re...
37.5
121
0.611228
from parsl.channels import SSHChannel from parsl.providers import SlurmProvider from parsl.launchers import SingleNodeLauncher from parsl.config import Config from parsl.executors.ipp import IPyParallelExecutor from parsl.executors.ipp_controller import Controller config = Config( executors=[ IPyParallel...
true
true
f778713c38b26b9fdd7ed220c36ebbd12ddb7e51
2,289
py
Python
amime/modules/anime/TV-SHOW/SEASON/Musim/2022 ANIME/KTGR MUSIM/WINTER/01 WINTER.py
Myudi422/ccgnime_req
a0f7596ba101204539b4120dffa08912b6560efe
[ "MIT" ]
null
null
null
amime/modules/anime/TV-SHOW/SEASON/Musim/2022 ANIME/KTGR MUSIM/WINTER/01 WINTER.py
Myudi422/ccgnime_req
a0f7596ba101204539b4120dffa08912b6560efe
[ "MIT" ]
null
null
null
amime/modules/anime/TV-SHOW/SEASON/Musim/2022 ANIME/KTGR MUSIM/WINTER/01 WINTER.py
Myudi422/ccgnime_req
a0f7596ba101204539b4120dffa08912b6560efe
[ "MIT" ]
null
null
null
import httpx from anilist.types import Anime from pyrogram import filters from pyrogram.types import CallbackQuery from pyromod.helpers import ikb from pyromod.nav import Pagination from amime.amime import Amime @Amime.on_callback_query(filters.regex(r"^winter_2022 anime (?P<page>\d+)")) async def anime_suggestions(...
31.356164
111
0.477501
import httpx from anilist.types import Anime from pyrogram import filters from pyrogram.types import CallbackQuery from pyromod.helpers import ikb from pyromod.nav import Pagination from amime.amime import Amime @Amime.on_callback_query(filters.regex(r"^winter_2022 anime (?P<page>\d+)")) async def anime_suggestions(...
true
true