hexsha
stringlengths
40
40
size
int64
6
1.04M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
247
max_stars_repo_name
stringlengths
4
130
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
368k
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
247
max_issues_repo_name
stringlengths
4
130
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
116k
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
247
max_forks_repo_name
stringlengths
4
130
max_forks_repo_head_hexsha
stringlengths
40
78
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
1
1.04M
avg_line_length
float64
1.53
618k
max_line_length
int64
1
1.02M
alphanum_fraction
float64
0
1
original_content
stringlengths
6
1.04M
filtered:remove_non_ascii
int64
0
538k
filtered:remove_decorators
int64
0
917k
filtered:remove_async
int64
0
722k
filtered:remove_classes
int64
-45
1M
filtered:remove_generators
int64
0
814k
filtered:remove_function_no_docstring
int64
-102
850k
filtered:remove_class_no_docstring
int64
-3
5.46k
filtered:remove_unused_imports
int64
-1,350
52.4k
filtered:remove_delete_markers
int64
0
59.6k
9128f46dfdc43f9451f8418dcdfd12e28a73cc9f
1,691
py
Python
setup.py
muon-spectroscopy-computational-project/muspinsim
d9e971edd840ab0c33b143f9b5694bc1b09011d2
[ "MIT" ]
null
null
null
setup.py
muon-spectroscopy-computational-project/muspinsim
d9e971edd840ab0c33b143f9b5694bc1b09011d2
[ "MIT" ]
null
null
null
setup.py
muon-spectroscopy-computational-project/muspinsim
d9e971edd840ab0c33b143f9b5694bc1b09011d2
[ "MIT" ]
null
null
null
#!/usr/bin/env python # import setuptools with open("README.md", "r", encoding="utf-8") as fh: long_description = fh.read() version = {} with open("muspinsim/version.py") as fp: exec(fp.read(), version) setuptools.setup( name="muspinsim", version=version["__version__"], author="Simone Sturniolo",...
33.82
83
0.626848
#!/usr/bin/env python # import setuptools with open("README.md", "r", encoding="utf-8") as fh: long_description = fh.read() version = {} with open("muspinsim/version.py") as fp: exec(fp.read(), version) setuptools.setup( name="muspinsim", version=version["__version__"], author="Simone Sturniolo",...
0
0
0
0
0
0
0
0
0
69f5f911ce12976f518733c0e2fcb7d5be7964b3
826
py
Python
PINNFramework/__init__.py
Jeyhun1/NeuralSolvers
46f3214aed881eab04706842eb30ca791821a014
[ "MIT" ]
2
2021-11-02T20:36:25.000Z
2022-02-22T12:16:15.000Z
PINNFramework/__init__.py
harsh1702/NeuralSolvers
3adbe4009bacd18f8aca0a454efac7487aecf7de
[ "MIT" ]
null
null
null
PINNFramework/__init__.py
harsh1702/NeuralSolvers
3adbe4009bacd18f8aca0a454efac7487aecf7de
[ "MIT" ]
null
null
null
from . import models from .InitalCondition import InitialCondition from .BoundaryCondition import PeriodicBC from .BoundaryCondition import DirichletBC from .BoundaryCondition import RobinBC from .BoundaryCondition import TimeDerivativeBC from .BoundaryCondition import NeumannBC from .PDELoss import PDELoss from .HPMLo...
24.294118
49
0.768765
from . import models from .InitalCondition import InitialCondition from .BoundaryCondition import PeriodicBC from .BoundaryCondition import DirichletBC from .BoundaryCondition import RobinBC from .BoundaryCondition import TimeDerivativeBC from .BoundaryCondition import NeumannBC from .PDELoss import PDELoss from .HPMLo...
0
0
0
0
0
0
0
9
22
dbbf71d23f022fbd023d98c88ed3dc98d7be2b45
2,349
py
Python
motion_primitives_py/motion_primitives_py/motion_primitive_types/euclidean_motion_primitive.py
ljarin/dispersion_motion_planning
1c16c95b70915e58e407c1a45aa4065877fbb3de
[ "BSD-3-Clause" ]
1
2022-03-04T12:03:26.000Z
2022-03-04T12:03:26.000Z
motion_primitives_py/motion_primitives_py/motion_primitive_types/euclidean_motion_primitive.py
ljarin/dispersion_motion_planning
1c16c95b70915e58e407c1a45aa4065877fbb3de
[ "BSD-3-Clause" ]
null
null
null
motion_primitives_py/motion_primitives_py/motion_primitive_types/euclidean_motion_primitive.py
ljarin/dispersion_motion_planning
1c16c95b70915e58e407c1a45aa4065877fbb3de
[ "BSD-3-Clause" ]
null
null
null
import numpy as np import matplotlib.pyplot as plt import scipy.integrate as integrate if __name__ == "__main__": # problem parameters num_dims = 2 control_space_q = 3 # setup problem start_state = np.zeros((num_dims * control_space_q,)) # end_state = np.random.rand(num_dims * control_space_...
32.625
125
0.680715
from motion_primitives_py import MotionPrimitive import numpy as np import matplotlib.pyplot as plt import sympy as sym from scipy.linalg import expm import scipy.integrate as integrate class EuclideanMotionPrimitive(MotionPrimitive): """ A motion primitive that is just a straight line, with the norm of the d...
0
230
0
1,171
0
0
0
33
89
70717f2eca1ee1b86f087e4ddaa3247fc908c185
5,652
py
Python
tests/test_plotting.py
Imperial-CMTH/koala
cd05b11be402295468be709db13a957530f66578
[ "MIT" ]
null
null
null
tests/test_plotting.py
Imperial-CMTH/koala
cd05b11be402295468be709db13a957530f66578
[ "MIT" ]
9
2021-12-13T10:16:03.000Z
2022-03-28T10:39:16.000Z
tests/test_plotting.py
Imperial-CMTH/koala
cd05b11be402295468be709db13a957530f66578
[ "MIT" ]
null
null
null
import numpy as np from matplotlib import pyplot as plt from koala.pointsets import generate_bluenoise from koala.voronization import generate_lattice from koala.voronization import Lattice h = Lattice( vertices = np.array([[0.5,0.5], [0.1,0.1], [0.5,0.9], [0.9,0.1]]), edge_indices = np.array([[0,1],[0,2],[0,...
38.189189
146
0.678698
import numpy as np from matplotlib import pyplot as plt from koala.pointsets import generate_bluenoise from koala.voronization import generate_lattice from koala.graph_color import edge_color from koala.plotting import plot_lattice, plot_vertex_indices, plot_degeneracy_breaking, plot_plaquettes, line_intersection from...
0
0
0
0
0
3,557
0
141
228
16c33973fbb2e47abab8065a2fa40e42c6b46e6d
1,223
py
Python
semana-02/lista-exercicio/lista-3/exercicio_3.py
larissajusten/ufsc-object-oriented-programming
839e6abcc20580ea1a47479232c3ed3cb0153e4b
[ "MIT" ]
6
2021-11-29T05:43:19.000Z
2022-03-15T21:54:54.000Z
semana-02/lista-exercicio/lista-3/exercicio_3.py
larissajusten/ufsc-object-oriented-programming
839e6abcc20580ea1a47479232c3ed3cb0153e4b
[ "MIT" ]
3
2021-11-21T03:44:03.000Z
2021-11-21T03:44:05.000Z
semana-02/lista-exercicio/lista-3/exercicio_3.py
larissajusten/ufsc-object-oriented-programming
839e6abcc20580ea1a47479232c3ed3cb0153e4b
[ "MIT" ]
null
null
null
""" Exerccio 3. Escreva um programa que l duas notas de vrios alunos e armazena tais notas em um dicionrio, onde a chave o nome do aluno. A entrada de dados deve terminar quando for lida uma string vazia como nome. Escreva uma funo que retorna a mdia do aluno, dado seu nome. """ if __name__ == '__main...
37.060606
144
0.686836
""" Exercício 3. Escreva um programa que lê duas notas de vários alunos e armazena tais notas em um dicionário, onde a chave é o nome do aluno. A entrada de dados deve terminar quando for lida uma string vazia como nome. Escreva uma função que retorna a média do aluno, dado seu nome. """ def le_notas(dic...
16
0
0
0
0
584
0
0
46
3bb0101e77ff88be5f0f65f8e20796ab57e7b01b
1,865
py
Python
whitebox/grid_search.py
Jonksar/whitebox
b6824d0210e6becb7015c840201b7fb1e3a90f33
[ "BSD-3-Clause" ]
3
2018-05-28T20:29:01.000Z
2019-08-17T11:01:20.000Z
whitebox/grid_search.py
Jonksar/whitebox
b6824d0210e6becb7015c840201b7fb1e3a90f33
[ "BSD-3-Clause" ]
null
null
null
whitebox/grid_search.py
Jonksar/whitebox
b6824d0210e6becb7015c840201b7fb1e3a90f33
[ "BSD-3-Clause" ]
null
null
null
""" -------------------------------------------------- File Name : grid_search.py Creation Date : 2019-06-27 N 10:37 Last Modified : 2019-06-27 N 10:41 Created By : Joonatan Samuel -------------------------------------------------- """ from sklearn.model_selection import cross_validate # ---- Choose a b...
31.610169
93
0.536729
""" -------------------------------------------------- File Name : grid_search.py Creation Date : 2019-06-27 N 10:37 Last Modified : 2019-06-27 N 10:41 Created By : Joonatan Samuel -------------------------------------------------- """ from sklearn.model_selection import cross_validate from pprint import...
0
0
0
0
0
0
0
4
22
fbe665d53ab00f81085628189537e8ede858b943
6,887
py
Python
syntext/inline.py
dmulholland/syntext
69c766a201f36d2975d574df88ad6d550112b034
[ "0BSD" ]
53
2015-08-25T17:02:16.000Z
2017-09-07T19:11:40.000Z
syntext/inline.py
dmulholland/monk
69c766a201f36d2975d574df88ad6d550112b034
[ "0BSD" ]
1
2016-08-12T00:48:20.000Z
2016-08-12T21:20:06.000Z
syntext/inline.py
dmulholland/monk
69c766a201f36d2975d574df88ad6d550112b034
[ "0BSD" ]
null
null
null
# ------------------------------------------------------------------------------ # Functions for parsing and rendering inline markup. # ------------------------------------------------------------------------------ import re # ------------------------------------------------------------------------------ # Regular ex...
27.882591
80
0.543923
# ------------------------------------------------------------------------------ # Functions for parsing and rendering inline markup. # ------------------------------------------------------------------------------ import html import hashlib import re # ---------------------------------------------------------------...
0
0
0
0
0
4,001
0
-17
457
2b2e18b2e9fa5009f200fa275921bf0097ed6a5b
698
py
Python
bin/fresno.py
dmpayton/FresnoPython
d606b1d3604ba25ab0f3d178173ce9d6c05be1b2
[ "MIT" ]
2
2016-05-25T02:38:02.000Z
2016-05-25T02:39:44.000Z
bin/fresno.py
FresnoPython/FresnoPython
d606b1d3604ba25ab0f3d178173ce9d6c05be1b2
[ "MIT" ]
null
null
null
bin/fresno.py
FresnoPython/FresnoPython
d606b1d3604ba25ab0f3d178173ce9d6c05be1b2
[ "MIT" ]
1
2017-05-21T14:01:20.000Z
2017-05-21T14:01:20.000Z
#!/usr/bin/env python import argparse if __name__ == '__main__': parser = argparse.ArgumentParser(description='Process some integers.') parser.add_argument('--website', action='store_true', help='Open the website.') parser.add_argument('--map', action='store_true', help='Open the location on Google Maps....
26.846154
95
0.690544
#!/usr/bin/env python import argparse import FresnoPython def main(args): if args.website: FresnoPython.open_website() if args.map: FresnoPython.open_map() if args.twitter: FresnoPython.open_twitter() print(FresnoPython.message()) if __name__ == '__main__': parser = ar...
0
0
0
0
0
194
0
-2
45
51e65d6a89f738957bf092dfde8598b3c7f0834b
992
py
Python
source/py/tests/test_call.py
shakfu/pymax
67dca5990581d91ffcedf800e585e87646ab94d4
[ "CC0-1.0" ]
25
2020-08-06T12:38:07.000Z
2022-03-23T17:35:09.000Z
source/py/tests/test_call.py
shakfu/pymax
67dca5990581d91ffcedf800e585e87646ab94d4
[ "CC0-1.0" ]
7
2021-04-02T02:58:56.000Z
2022-03-31T22:58:19.000Z
source/py/tests/test_call.py
shakfu/pymax
67dca5990581d91ffcedf800e585e87646ab94d4
[ "CC0-1.0" ]
3
2021-04-04T05:47:07.000Z
2021-06-26T03:30:02.000Z
# dispatch.py """ patterns to parse: 1. func arg1 arg2 key1=val1 key2=val2 2. func arg1 arg2 key1:val1 key2:val2 3. func arg1 arg2 dict(key1=val1, key2=val2) 4. obj.func arg1 arg2 key1=val1 key2=val2 """ obj = Klass() gdict = {'func': func, 'obj': obj} s1 = 'func arg1 arg2 key1=val1 key2=val2' head = lamb...
15.746032
44
0.542339
# dispatch.py """ patterns to parse: 1. func arg1 arg2 key1=val1 key2=val2 2. func arg1 arg2 key1:val1 key2:val2 3. func arg1 arg2 dict(key1=val1, key2=val2) 4. obj.func arg1 arg2 key1=val1 key2=val2 """ def func(*args, **kwargs): return args, kwargs class Klass: def func(self, *args, **kwargs): ...
0
0
0
56
0
499
0
0
69
d3dc30343b3b3ac3fb15b44ae10a2bd7020d8e60
23,363
py
Python
phply/pythonast.py
alex4men/phply
bbc41656e56401ae754c3e0346ef6b6a1a56c322
[ "BSD-3-Clause" ]
null
null
null
phply/pythonast.py
alex4men/phply
bbc41656e56401ae754c3e0346ef6b6a1a56c322
[ "BSD-3-Clause" ]
null
null
null
phply/pythonast.py
alex4men/phply
bbc41656e56401ae754c3e0346ef6b6a1a56c322
[ "BSD-3-Clause" ]
null
null
null
import ast as py unary_ops = { '~': py.Invert, '!': py.Not, '+': py.UAdd, '-': py.USub, } bool_ops = { '&&': py.And, '||': py.Or, 'and': py.And, 'or': py.Or, } cmp_ops = { '!=': py.NotEq, '!==': py.NotEq, '<>': py.NotEq, '<': py.Lt, '<=': py.LtE, '==': py.Eq, ...
41.423759
181
0.448102
from . import phpast as php import ast as py unary_ops = { '~': py.Invert, '!': py.Not, '+': py.UAdd, '-': py.USub, } bool_ops = { '&&': py.And, '||': py.Or, 'and': py.And, 'or': py.Or, } cmp_ops = { '!=': py.NotEq, '!==': py.NotEq, '<>': py.NotEq, '<': py.Lt, '<='...
0
0
0
0
0
22,518
0
6
183
91c50c426964b8ed46db51b3027fbd04fd11f484
14,890
py
Python
matrixprofile/algorithms/mstomp.py
MORE-EU/matrixprofile
7c598385f7723f337d7bf7d3f90cffb690c6b0df
[ "Apache-2.0" ]
262
2020-02-28T20:42:27.000Z
2022-03-30T14:02:28.000Z
matrixprofile/algorithms/mstomp.py
MORE-EU/matrixprofile
7c598385f7723f337d7bf7d3f90cffb690c6b0df
[ "Apache-2.0" ]
79
2020-03-01T01:42:14.000Z
2022-03-30T07:15:48.000Z
matrixprofile/algorithms/mstomp.py
MORE-EU/matrixprofile
7c598385f7723f337d7bf7d3f90cffb690c6b0df
[ "Apache-2.0" ]
56
2020-03-03T14:56:27.000Z
2022-03-22T07:18:42.000Z
# -*- coding: utf-8 -*- from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals range = getattr(__builtins__, 'xrange', range) # end of py2 compatability boilerplate import logging import numpy as np from matrixprofile impo...
39.287599
226
0.605306
# -*- coding: utf-8 -*- from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals range = getattr(__builtins__, 'xrange', range) # end of py2 compatability boilerplate import logging import numpy as np from matrixprofile impo...
0
0
0
0
0
0
0
0
0
06fbd889a7ced5c23a442171b1fd8a0e210890a6
103
py
Python
DataStructuresAlgorithms/ArrayBasedSequences/list_02.py
M1NH42/python-dsa
297e70d68bb81aececad1279e5c16e42eb941975
[ "MIT" ]
null
null
null
DataStructuresAlgorithms/ArrayBasedSequences/list_02.py
M1NH42/python-dsa
297e70d68bb81aececad1279e5c16e42eb941975
[ "MIT" ]
null
null
null
DataStructuresAlgorithms/ArrayBasedSequences/list_02.py
M1NH42/python-dsa
297e70d68bb81aececad1279e5c16e42eb941975
[ "MIT" ]
null
null
null
import array numbers = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] numbers_array = array('i', numbers) # ERROR
20.6
44
0.572816
import array numbers = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] numbers_array = array('i', numbers) # ERROR
0
0
0
0
0
0
0
0
0
a3f36ef3ac086712c7885627548ecf611d881782
8,859
py
Python
docqa/triviaqa/evidence_corpus.py
Willyoung2017/doc-qa
7ee02218952b0b9db63bc82b3895f743cdbd8f22
[ "Apache-2.0" ]
422
2017-10-31T12:20:29.000Z
2022-03-14T11:25:16.000Z
docqa/triviaqa/evidence_corpus.py
Willyoung2017/doc-qa
7ee02218952b0b9db63bc82b3895f743cdbd8f22
[ "Apache-2.0" ]
54
2017-11-02T10:34:45.000Z
2021-02-04T05:05:20.000Z
docqa/triviaqa/evidence_corpus.py
Willyoung2017/doc-qa
7ee02218952b0b9db63bc82b3895f743cdbd8f22
[ "Apache-2.0" ]
138
2017-11-02T10:49:09.000Z
2021-11-26T15:34:01.000Z
from os.path import join, exists from typing import Set from docqa.triviaqa.read_data import normalize_wiki_filename """ Build and cache a tokenized version of the evidence corpus """ def build_tokenized_files(filenames, input_root, output_root, tokenizer, override=True) -> Set[str]: """ For each file in `f...
36.012195
111
0.589683
import argparse import pickle import re from collections import Counter from os import walk, mkdir, makedirs from os.path import relpath, join, exists from typing import Set from tqdm import tqdm from docqa import config from docqa.config import CORPUS_DIR from docqa.data_processing.text_utils import NltkAndPunctToke...
0
0
0
3,316
0
3,680
0
103
429
84efe3bfb727ac976e976b8d9cfe388786b4f2a3
4,122
py
Python
problems/cop/real/Fapp.py
xcsp3team/pycsp3
a11bc370e34cd3fe37faeae9a5df935fcbd7770d
[ "MIT" ]
28
2019-12-14T09:25:52.000Z
2022-03-24T08:15:13.000Z
problems/cop/real/Fapp.py
xcsp3team/pycsp3
a11bc370e34cd3fe37faeae9a5df935fcbd7770d
[ "MIT" ]
7
2020-04-15T11:02:07.000Z
2022-01-20T12:48:54.000Z
problems/cop/real/Fapp.py
xcsp3team/pycsp3
a11bc370e34cd3fe37faeae9a5df935fcbd7770d
[ "MIT" ]
3
2020-04-15T08:23:45.000Z
2021-12-07T14:02:28.000Z
""" See Challenge ROADEF 2001 (FAPP: Problme d'affectation de frquences avec polarization) Examples of Execution: python3 Fapp.py -data=Fapp_ex2.json python3 Fapp.py -data=Fapp_ex2.json -variant=short """ domains, routes, hard_constraints, soft_constraints = data domains = [domains[route.domain] for route in rout...
41.22
159
0.598011
""" See Challenge ROADEF 2001 (FAPP: Problème d'affectation de fréquences avec polarization) Examples of Execution: python3 Fapp.py -data=Fapp_ex2.json python3 Fapp.py -data=Fapp_ex2.json -variant=short """ from pycsp3 import * domains, routes, hard_constraints, soft_constraints = data domains = [domains[route.d...
4
0
0
0
0
1,430
0
-1
46
97bc762620822cae73e686437ed0f6274ebe8a23
19,334
py
Python
tensorflow_checkpoint_reader/pb/tensorflow/lite/tools/evaluation/proto/preprocessing_steps_pb2.py
shawwn/tensorflow-checkpoint-reader
f0e65548411e3bd66a07e36bb1850907a05952d0
[ "MIT" ]
1
2021-12-02T15:06:09.000Z
2021-12-02T15:06:09.000Z
tensorflow_checkpoint_reader/pb/tensorflow/lite/tools/evaluation/proto/preprocessing_steps_pb2.py
shawwn/tensorflow-checkpoint-reader
f0e65548411e3bd66a07e36bb1850907a05952d0
[ "MIT" ]
null
null
null
tensorflow_checkpoint_reader/pb/tensorflow/lite/tools/evaluation/proto/preprocessing_steps_pb2.py
shawwn/tensorflow-checkpoint-reader
f0e65548411e3bd66a07e36bb1850907a05952d0
[ "MIT" ]
null
null
null
'Generated protocol buffer code.' from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf import reflection as _reflection from google.protobuf import symbol_database as _symbol_database _sym_db = _symbol_database.Default() DESCRIPTOR = _descriptor.Fil...
292.939394
2,286
0.843592
'Generated protocol buffer code.' from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf import reflection as _reflection from google.protobuf import symbol_database as _symbol_database _sym_db = _symbol_database.Default() DESCRIPTOR = _descriptor.Fil...
0
0
0
0
0
0
0
0
0
2ffd154bcadc5a7cba4f2b152013f1040183cb56
908
py
Python
scheduler/migrations/0001_initial.py
theju/smp
bee0849a5599bb9635f65f298889c0ea7ea6b46f
[ "MIT" ]
16
2015-12-31T20:52:50.000Z
2022-02-20T16:47:29.000Z
scheduler/migrations/0001_initial.py
theju/smp
bee0849a5599bb9635f65f298889c0ea7ea6b46f
[ "MIT" ]
null
null
null
scheduler/migrations/0001_initial.py
theju/smp
bee0849a5599bb9635f65f298889c0ea7ea6b46f
[ "MIT" ]
6
2016-06-06T20:26:54.000Z
2021-02-11T23:07:53.000Z
# -*- coding: utf-8 -*- from __future__ import unicode_literals
33.62963
125
0.609031
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import migrations, models from django.conf import settings class Migration(migrations.Migration): dependencies = [ migrations.swappable_dependency(settings.AUTH_USER_MODEL), ] operations = [ migrations.Create...
0
0
0
745
0
0
0
30
68
8107e1c4df5175b20a4a3a50cb72501b8a93d9be
3,101
py
Python
4.tweet_preprocessing/tweet_preprocess_part1.py
esh-b/Resources-for-Twitter-related-projects
28f2b54b47b76fdb5d4804692c13bccfef1805a0
[ "BSD-3-Clause" ]
2
2019-12-10T21:54:48.000Z
2020-06-30T20:37:57.000Z
4.tweet_preprocessing/tweet_preprocess_part1.py
esh-b/Resources-for-Twitter-related-projects
28f2b54b47b76fdb5d4804692c13bccfef1805a0
[ "BSD-3-Clause" ]
null
null
null
4.tweet_preprocessing/tweet_preprocess_part1.py
esh-b/Resources-for-Twitter-related-projects
28f2b54b47b76fdb5d4804692c13bccfef1805a0
[ "BSD-3-Clause" ]
null
null
null
""" Part 1 of the tweet preprocessing phase Lang: py3 """ import json import re import csv import sys OUTPUT_DIR = os.path.join(os.getcwd(), 'part1_output') EMOJI_PATTERN = re.compile("[" u"\U0001F600-\U0001F64F" # emoticons u"\U0001F300-\U0001F5FF" # symbols & pictographs u"\U0001F680-\U00...
29.533333
110
0.665592
""" Part 1 of the tweet preprocessing phase Lang: py3 """ import json import re import csv import sys OUTPUT_DIR = os.path.join(os.getcwd(), 'part1_output') EMOJI_PATTERN = re.compile("[" u"\U0001F600-\U0001F64F" # emoticons u"\U0001F300-\U0001F5FF" # symbols & pictographs u"\U0001F680-\U00...
0
0
0
0
0
159
0
0
22
be363a277e03a916241827d0dad6a6e5bee94e45
4,531
py
Python
src/plot_generation_script.py
NicholasJohnson2020/Sequential-Network-Structure-Optimization
c4e141062ecaec70cfd89e7fa5b06389d4e2c879
[ "MIT" ]
null
null
null
src/plot_generation_script.py
NicholasJohnson2020/Sequential-Network-Structure-Optimization
c4e141062ecaec70cfd89e7fa5b06389d4e2c879
[ "MIT" ]
null
null
null
src/plot_generation_script.py
NicholasJohnson2020/Sequential-Network-Structure-Optimization
c4e141062ecaec70cfd89e7fa5b06389d4e2c879
[ "MIT" ]
null
null
null
import matplotlib.pyplot as plt import sys import pickle # Verify the number of command line arguments assert len(sys.argv) == 5 num_agents_path = sys.argv[1] T_path = sys.argv[2] m_path = sys.argv[3] output_path_root = sys.argv[4] data = {} with open(num_agents_path, 'rb') as handle: data['num_agents'] = pickl...
33.316176
88
0.580004
import numpy as np import pandas as pd import matplotlib.pyplot as plt import sys import pickle # Verify the number of command line arguments assert len(sys.argv) == 5 num_agents_path = sys.argv[1] T_path = sys.argv[2] m_path = sys.argv[3] output_path_root = sys.argv[4] data = {} with open(num_agents_path, 'rb') as...
0
0
0
0
0
2,429
0
-5
90
16a964c561916f1a67430c581ee6f1a2b835feff
2,667
py
Python
sdk/python/kfp/v2/compiler_cli_tests/test_data/pipeline_with_various_io_types.py
ConverJens/pipelines
a1d453af214ec9eebad73fb05845dd3499d60d00
[ "Apache-2.0" ]
2
2021-03-11T14:27:12.000Z
2021-03-11T14:27:24.000Z
sdk/python/kfp/v2/compiler_cli_tests/test_data/pipeline_with_various_io_types.py
ConverJens/pipelines
a1d453af214ec9eebad73fb05845dd3499d60d00
[ "Apache-2.0" ]
484
2021-01-21T06:49:17.000Z
2022-03-23T01:21:24.000Z
sdk/python/kfp/v2/compiler_cli_tests/test_data/pipeline_with_various_io_types.py
ConverJens/pipelines
a1d453af214ec9eebad73fb05845dd3499d60d00
[ "Apache-2.0" ]
1
2021-03-19T14:31:00.000Z
2021-03-19T14:31:00.000Z
# Copyright 2020 Google LLC # # 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, ...
27.494845
74
0.667042
# Copyright 2020 Google LLC # # 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, ...
0
674
0
0
0
0
0
-6
68
1cc38f2d129f2a9a2fc3d2af053bb15247ffe26a
764
py
Python
0701. Insert into a Binary Search Tree/solution.py
furutuki/LeetCodeSolution
db5e6573d0c907dfa3e6ad5e5b3b5ff9944a4f53
[ "MIT" ]
null
null
null
0701. Insert into a Binary Search Tree/solution.py
furutuki/LeetCodeSolution
db5e6573d0c907dfa3e6ad5e5b3b5ff9944a4f53
[ "MIT" ]
null
null
null
0701. Insert into a Binary Search Tree/solution.py
furutuki/LeetCodeSolution
db5e6573d0c907dfa3e6ad5e5b3b5ff9944a4f53
[ "MIT" ]
null
null
null
# Definition for a binary tree node.
23.875
66
0.515707
# Definition for a binary tree node. class TreeNode: def __init__(self, val=0, left=None, right=None): self.val = val self.left = left self.right = right class Solution: def solve(self, node: TreeNode, val: int): if not node: return if val < node.val: ...
0
0
0
680
0
0
0
0
45
bb0c87e02ac0a359d88ce24de93cc2c12a5f3464
5,031
py
Python
setup.py
simongormley/python-mqlight
4aace74290d10c37e262cc296dfcbb92e66afb9e
[ "Apache-2.0" ]
13
2015-05-11T21:40:37.000Z
2022-01-18T02:20:23.000Z
setup.py
simongormley/python-mqlight
4aace74290d10c37e262cc296dfcbb92e66afb9e
[ "Apache-2.0" ]
27
2016-03-08T22:35:42.000Z
2021-06-25T15:16:43.000Z
setup.py
simongormley/python-mqlight
4aace74290d10c37e262cc296dfcbb92e66afb9e
[ "Apache-2.0" ]
11
2016-02-21T11:11:55.000Z
2021-11-10T02:43:24.000Z
# python-mqlight - high-level API by which you can interact with MQ Light # # Copyright 2015-2017 IBM Corp. # # 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/licens...
31.248447
78
0.622739
# python-mqlight - high-level API by which you can interact with MQ Light # # Copyright 2015-2017 IBM Corp. # # 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/licens...
0
0
0
843
0
0
0
34
44
3f840d5c29cd464b02e7bb916949d9f28abf657a
10,268
py
Python
app/views/plays/parser.py
julio-am/screenplay-editor
ae891e15f541ecfe40feb731c118cbe4cd79a130
[ "MIT" ]
null
null
null
app/views/plays/parser.py
julio-am/screenplay-editor
ae891e15f541ecfe40feb731c118cbe4cd79a130
[ "MIT" ]
2
2021-09-28T02:34:20.000Z
2022-02-26T07:47:38.000Z
app/views/plays/parser.py
julio-am/screenplay-editor
ae891e15f541ecfe40feb731c118cbe4cd79a130
[ "MIT" ]
null
null
null
import xml.etree.ElementTree as ET """ elemToString This takes in content, a node, and returns the inner text """ """ cleanElemToString This takes in content, a node, and returns the inner text with only one space between words and no line breaks """ """ stageDirInLine This gets the stage directions in the middle o...
42.605809
109
0.62836
import xml.etree.ElementTree as ET """ elemToString This takes in content, a node, and returns the inner text """ def elemToString(content): return ET.tostring(content, encoding='utf8', method='text') """ cleanElemToString This takes in content, a node, and returns the inner text with only one space between words...
0
0
0
0
0
5,959
0
0
268
9873b4d12140f0e1fe8c471ca624a6311ca31727
208
py
Python
Exercicios Loop/exercicio 01 - secao 06.py
cristinamais/exercicios_python
8a09b0b68ffaa62d13afb952998e890a79667c7e
[ "MIT" ]
null
null
null
Exercicios Loop/exercicio 01 - secao 06.py
cristinamais/exercicios_python
8a09b0b68ffaa62d13afb952998e890a79667c7e
[ "MIT" ]
null
null
null
Exercicios Loop/exercicio 01 - secao 06.py
cristinamais/exercicios_python
8a09b0b68ffaa62d13afb952998e890a79667c7e
[ "MIT" ]
null
null
null
""" 1 - Faa um programa que determine e mostre os cinco primeiros mltiplos de 3, considerando nmeros maiores que 0. """ soma = 0 for num in range(1,6): numero = num * 3 soma += 1 print(numero)
23.111111
114
0.663462
""" 1 - Faça um programa que determine e mostre os cinco primeiros múltiplos de 3, considerando números maiores que 0. """ soma = 0 for num in range(1,6): numero = num * 3 soma += 1 print(numero)
6
0
0
0
0
0
0
0
0
c8f6e15e18f3008d4305fe32517b64e216c567cf
2,061
py
Python
practice/demo.py
alfaro28/sqlalchemy-media
c70af4faf8b299212aa18247f9cb26fd5efac7bf
[ "MIT" ]
78
2016-09-27T20:40:39.000Z
2022-02-23T21:08:51.000Z
practice/demo.py
alfaro28/sqlalchemy-media
c70af4faf8b299212aa18247f9cb26fd5efac7bf
[ "MIT" ]
126
2016-09-27T20:39:09.000Z
2022-02-08T08:23:18.000Z
practice/demo.py
jpmn/sqlalchemy-media
7dee4aa70fc8979b6fbb39d04c27d897dd51ae2f
[ "MIT" ]
27
2016-10-04T00:27:24.000Z
2022-03-15T16:52:20.000Z
import functools from pprint import pprint from os.path import join, exists from sqlalchemy import create_engine from sqlalchemy.orm import sessionmaker from sqlalchemy.ext.declarative import declarative_base from sqlalchemy_media import StoreManager, FileSystemStore # Step 1 TEMP_PATH = '/tmp/sqlalchemy-media' Bas...
26.423077
118
0.667637
import json import functools from pprint import pprint from os.path import join, exists from sqlalchemy import Column, Integer, create_engine, Unicode, TypeDecorator from sqlalchemy.orm import sessionmaker from sqlalchemy.ext.declarative import declarative_base from sqlalchemy_media import Image, StoreManager, FileSy...
0
0
0
647
0
0
0
54
90
4573313ea2349bd3cee43c50eeecd9bc30e577e3
84
py
Python
category/urls.py
shaymk1/my-e-commerce-shop
f8d2dacd7c3eaec557ef5a158e4ba41b170008b2
[ "MIT" ]
null
null
null
category/urls.py
shaymk1/my-e-commerce-shop
f8d2dacd7c3eaec557ef5a158e4ba41b170008b2
[ "MIT" ]
null
null
null
category/urls.py
shaymk1/my-e-commerce-shop
f8d2dacd7c3eaec557ef5a158e4ba41b170008b2
[ "MIT" ]
null
null
null
urlpatterns = [ ]
6.461538
32
0.654762
from django.contrib import admin from .models import * urlpatterns = [ ]
0
0
0
0
0
0
0
11
45
4330771e8136c4a6df3587740060dc1e8e0a63cb
876
py
Python
Problemset/sum-lists-lcci/sum-lists-lcci.py
worldwonderer/algorithm
083178b2d987de7f6020aceca869a353c0b4b1f3
[ "MIT" ]
1
2021-01-30T01:52:46.000Z
2021-01-30T01:52:46.000Z
Problemset/sum-lists-lcci/sum-lists-lcci.py
worldwonderer/algorithm
083178b2d987de7f6020aceca869a353c0b4b1f3
[ "MIT" ]
1
2021-12-15T14:54:06.000Z
2021-12-15T14:54:06.000Z
Problemset/sum-lists-lcci/sum-lists-lcci.py
worldwonderer/algorithm
083178b2d987de7f6020aceca869a353c0b4b1f3
[ "MIT" ]
2
2021-04-19T03:32:18.000Z
2021-06-22T07:06:01.000Z
# @Title: (Sum Lists LCCI) # @Author: 18015528893 # @Date: 2021-02-12 21:23:09 # @Runtime: 60 ms # @Memory: 14.8 MB # Definition for singly-linked list. # class ListNode: # def __init__(self, x): # self.val = x # self.next = None
23.675676
68
0.44863
# @Title: 链表求和 (Sum Lists LCCI) # @Author: 18015528893 # @Date: 2021-02-12 21:23:09 # @Runtime: 60 ms # @Memory: 14.8 MB # Definition for singly-linked list. # class ListNode: # def __init__(self, x): # self.val = x # self.next = None class Solution: def addTwoNumbers(self, l1: ListNode, l2: ...
12
0
0
595
0
0
0
0
23
b8f15f38159c642a1546aa6bb014008958980e05
3,338
py
Python
setup.py
bepec/pydvbcss
72bec02d42582416390ea0379dc6b79da8cd0721
[ "Apache-2.0" ]
22
2015-03-15T17:24:47.000Z
2021-12-23T01:42:24.000Z
setup.py
bepec/pydvbcss
72bec02d42582416390ea0379dc6b79da8cd0721
[ "Apache-2.0" ]
15
2016-02-21T20:05:03.000Z
2021-01-11T12:19:18.000Z
setup.py
bepec/pydvbcss
72bec02d42582416390ea0379dc6b79da8cd0721
[ "Apache-2.0" ]
6
2015-03-30T11:41:20.000Z
2020-12-16T11:16:00.000Z
#!/usr/bin/env python # # Copyright 2015 British Broadcasting 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 requ...
36.282609
137
0.641402
#!/usr/bin/env python # # Copyright 2015 British Broadcasting 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 requ...
0
0
0
0
0
0
0
0
0
803202c2b799656ec37b8d405d8275a911b9dcaa
1,242
py
Python
benchmarking/preprocess_data.py
radujica/data-analysis-pipelines
64a6e5613cb1ab2ba2eb2f763c2aa1e3bc5e0d3b
[ "MIT" ]
5
2018-03-05T13:19:35.000Z
2020-11-17T15:59:41.000Z
benchmarking/preprocess_data.py
radujica/data-analysis-pipelines
64a6e5613cb1ab2ba2eb2f763c2aa1e3bc5e0d3b
[ "MIT" ]
1
2021-06-01T22:27:44.000Z
2021-06-01T22:27:44.000Z
benchmarking/preprocess_data.py
radujica/data-analysis-pipelines
64a6e5613cb1ab2ba2eb2f763c2aa1e3bc5e0d3b
[ "MIT" ]
null
null
null
import argparse """ Join and convert the NETCDF3_CLASSIC files into a large NETCDF4 file (with full HDF5 API) """ parser = argparse.ArgumentParser(description='Combine data') parser.add_argument('-i', '--input', required=True, help='Path to folder containing input files; also output folder') args = parser.parse_args(...
32.684211
117
0.649758
import argparse import xarray as xr """ Join and convert the NETCDF3_CLASSIC files into a large NETCDF4 file (with full HDF5 API) """ parser = argparse.ArgumentParser(description='Combine data') parser.add_argument('-i', '--input', required=True, help='Path to folder containing input files; also output folder') args...
0
0
0
0
0
716
0
-2
46
51914992ce4c318882cbb1ecdbab16b2f838dfe3
5,063
py
Python
tools/Test_ATL_HICO_wo_obj.py
abreza/HOI-CL
c5be517bb26eac73ef88a39d6ec9e564c3379714
[ "MIT" ]
40
2021-04-09T17:53:08.000Z
2022-03-30T02:38:10.000Z
tools/Test_ATL_HICO_wo_obj.py
abreza/HOI-CL
c5be517bb26eac73ef88a39d6ec9e564c3379714
[ "MIT" ]
21
2021-04-09T19:05:47.000Z
2022-01-31T23:17:16.000Z
tools/Test_ATL_HICO_wo_obj.py
abreza/HOI-CL
c5be517bb26eac73ef88a39d6ec9e564c3379714
[ "MIT" ]
8
2021-05-30T12:37:00.000Z
2022-03-14T03:13:57.000Z
# -------------------------------------------------------- # Tensorflow iCAN # Licensed under The MIT License [see LICENSE for details] # -------------------------------------------------------- from __future__ import absolute_import from __future__ import division from __future__ import print_function import os os....
38.067669
118
0.595892
# -------------------------------------------------------- # Tensorflow iCAN # Licensed under The MIT License [see LICENSE for details] # -------------------------------------------------------- from __future__ import absolute_import from __future__ import division from __future__ import print_function import os os....
0
0
0
0
0
1,216
0
-6
45
3140f5e66df241402f57b679a55206a4ea912d16
1,414
py
Python
migrations/0026_auto_20160928_1457.py
tobiasbartel/servicium-application_manager
f9dc26b3d7c0c28d42b347fdd26976a908bf95c0
[ "MIT" ]
null
null
null
migrations/0026_auto_20160928_1457.py
tobiasbartel/servicium-application_manager
f9dc26b3d7c0c28d42b347fdd26976a908bf95c0
[ "MIT" ]
null
null
null
migrations/0026_auto_20160928_1457.py
tobiasbartel/servicium-application_manager
f9dc26b3d7c0c28d42b347fdd26976a908bf95c0
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by Django 1.10.1 on 2016-09-28 14:57 from __future__ import unicode_literals
35.35
146
0.630127
# -*- coding: utf-8 -*- # Generated by Django 1.10.1 on 2016-09-28 14:57 from __future__ import unicode_literals from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('servicecatalog', '0025_auto_20160928_1433'), ] ope...
0
0
0
1,202
0
0
0
30
68
2e6ed07b3e7f699d3dcbb48a3aca40686c1c15f6
208
py
Python
Libreria/constantes.py
Sannso/GameCG2
426e22541bf670e0767395c30f15d1b6ad6183f3
[ "CC0-1.0" ]
null
null
null
Libreria/constantes.py
Sannso/GameCG2
426e22541bf670e0767395c30f15d1b6ad6183f3
[ "CC0-1.0" ]
null
null
null
Libreria/constantes.py
Sannso/GameCG2
426e22541bf670e0767395c30f15d1b6ad6183f3
[ "CC0-1.0" ]
null
null
null
#850480 ANCHO=850 #x4 = 3400 ALTO=480 #x3 = 1440 VERDE=[0,255,0] ROJO=[255,0,0] AZUL=[0,0,255] AMARILLO=[255,255,0] AZUL_2=[0,255,255] NEGRO=[0,0,0] BLANCO=[255,255,255] GRIS=[180,180,180] WIN = False
14.857143
22
0.639423
#850×480 ANCHO=850 #x4 = 3400 ALTO=480 #x3 = 1440 VERDE=[0,255,0] ROJO=[255,0,0] AZUL=[0,0,255] AMARILLO=[255,255,0] AZUL_2=[0,255,255] NEGRO=[0,0,0] BLANCO=[255,255,255] GRIS=[180,180,180] WIN = False
2
0
0
0
0
0
0
0
0
7f6ccce8a07d4cda108330f4696011e12061b900
1,938
py
Python
tests/graph/test_edmonds_karp.py
niemmi/algolib
81a013af5ae1ca1e8cf8d3f2e2f1b4a9bce6ead8
[ "BSD-3-Clause" ]
null
null
null
tests/graph/test_edmonds_karp.py
niemmi/algolib
81a013af5ae1ca1e8cf8d3f2e2f1b4a9bce6ead8
[ "BSD-3-Clause" ]
null
null
null
tests/graph/test_edmonds_karp.py
niemmi/algolib
81a013af5ae1ca1e8cf8d3f2e2f1b4a9bce6ead8
[ "BSD-3-Clause" ]
null
null
null
from .context import Directed, Undirected # Figure 6.13 from The Algorithm Design Manual CASES = [ { 'class': Undirected, 'edges': [ [0, 1, 5], [0, 4, 12], [1, 2, 7], [1, 3, 9], [2, 3, 3], [2, 6, 5], [3, 5, 3], ...
21.775281
78
0.301858
from .context import Directed, Undirected, edmonds_karp from unittest import TestCase # Figure 6.13 from The Algorithm Design Manual CASES = [ { 'class': Undirected, 'edges': [ [0, 1, 5], [0, 4, 12], [1, 2, 7], [1, 3, 9], [2, 3, 3], ...
0
0
0
333
0
0
0
22
45
d12c4d0348bebfabc6afc769e18af8912ca70a17
537
py
Python
l_04_list_and_dictionaries/dictionaries/ex_10_shellbound.py
VasAtanasov/SoftUni-Python-Fundamentals
471d0537dd6e5c8b61ede92b7673c0d67e2964fd
[ "MIT" ]
1
2019-06-05T11:16:08.000Z
2019-06-05T11:16:08.000Z
l_04_list_and_dictionaries/dictionaries/ex_10_shellbound.py
VasAtanasov/SoftUni-Python-Fundamentals
471d0537dd6e5c8b61ede92b7673c0d67e2964fd
[ "MIT" ]
null
null
null
l_04_list_and_dictionaries/dictionaries/ex_10_shellbound.py
VasAtanasov/SoftUni-Python-Fundamentals
471d0537dd6e5c8b61ede92b7673c0d67e2964fd
[ "MIT" ]
null
null
null
regions = {} while True: in_line = input() if 'Aggregate' == in_line: break [region, shell] = filter(None, in_line.split(" ")) if region not in regions: regions[region] = [] if int(shell) not in regions[region]: regions[region].append(int(shell)) print(("\n".join( ...
22.375
105
0.603352
regions = {} def calculate_giant_shell(shells): return sum(shells) - (sum(shells) // len(shells)) while True: in_line = input() if 'Aggregate' == in_line: break [region, shell] = filter(None, in_line.split(" ")) if region not in regions: regions[region] = [] if int(shell) ...
0
0
0
0
0
67
0
0
23
8ff68975222c6c7991c82b9ee32f667d41fae4db
5,624
py
Python
manage_user.py
JacquesMironneau/Portfolio
5d4c1c428c40b2885280ccdc05d7a7a3ce302e6a
[ "CNRI-Python" ]
null
null
null
manage_user.py
JacquesMironneau/Portfolio
5d4c1c428c40b2885280ccdc05d7a7a3ce302e6a
[ "CNRI-Python" ]
null
null
null
manage_user.py
JacquesMironneau/Portfolio
5d4c1c428c40b2885280ccdc05d7a7a3ce302e6a
[ "CNRI-Python" ]
null
null
null
from models import db, User import bcrypt import readline # global variables that contains several types of commands create_commands = [ "create", "create_user", "createuser", "adduser", "add" ] update_commands = [ "update", "update_user", "updateuser", "passwd" ] delete_commands = [ "delete", "delete_user", "deluser...
33.879518
135
0.57468
from models import db, User import bcrypt import readline # global variables that contains several types of commands create_commands = [ "create", "create_user", "createuser", "adduser", "add" ] update_commands = [ "update", "update_user", "updateuser", "passwd" ] delete_commands = [ "delete", "delete_user", "deluser...
0
0
0
0
0
139
0
0
23
f5f5752e18cd6726354f2512e52ca5789f0645e1
951
py
Python
pulumi/aws/kic-pulumi-utils/kic_util/external_process.py
fossabot/kic-reference-architectures
0a6ebe4a43f9b21965d1456159f281c9cf414102
[ "Apache-2.0" ]
72
2021-06-15T18:23:14.000Z
2022-03-30T12:39:15.000Z
pulumi/aws/kic-pulumi-utils/kic_util/external_process.py
fossabot/kic-reference-architectures
0a6ebe4a43f9b21965d1456159f281c9cf414102
[ "Apache-2.0" ]
71
2021-06-14T22:45:20.000Z
2022-03-25T18:52:40.000Z
pulumi/aws/kic-pulumi-utils/kic_util/external_process.py
fossabot/kic-reference-architectures
0a6ebe4a43f9b21965d1456159f281c9cf414102
[ "Apache-2.0" ]
32
2021-06-14T22:17:24.000Z
2022-03-29T11:41:18.000Z
import subprocess from typing import Optional, Dict def run(cmd: str, suppress_error=False, env: Optional[Dict[str, str]] = None) -> (str, str): """Runs an external command and returns back its stdout and stderr""" proc = subprocess.Popen(cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE, shell=True, env=...
36.576923
101
0.679285
import subprocess from typing import Optional, Dict class ExternalProcessExecError(RuntimeError): """Error when an external process fails to run successfully""" def __init__(self, cmd: str, message: str): self.cmd = cmd self.message = message super().__init__(f"{message} when running: ...
0
0
0
252
0
0
0
0
23
4e652f29e8860d5a86bd8a22829c65a88c45f18c
2,877
py
Python
code/SelectPlots.py
CnrLwlss/fibreAnnotation
1fcebcd7a4035e2996a04a0aa228c527ec49ccad
[ "MIT" ]
null
null
null
code/SelectPlots.py
CnrLwlss/fibreAnnotation
1fcebcd7a4035e2996a04a0aa228c527ec49ccad
[ "MIT" ]
null
null
null
code/SelectPlots.py
CnrLwlss/fibreAnnotation
1fcebcd7a4035e2996a04a0aa228c527ec49ccad
[ "MIT" ]
null
null
null
import pandas as pd pd.set_option('display.max_columns', None) import numpy as np import matplotlib.pyplot as plt import seaborn as sns import urllib.request import os.path # Download data url = "https://raw.githubusercontent.com/CnrLwlss/Warren_2019/master/shiny/dat.txt" outfile = "dat_py.txt" mitoprot = "VDAC1" if...
35.518519
123
0.697602
import pandas as pd pd.set_option('display.max_columns', None) import numpy as np import matplotlib.pyplot as plt import seaborn as sns import urllib.request import os.path from Selecting import * # Download data url = "https://raw.githubusercontent.com/CnrLwlss/Warren_2019/master/shiny/dat.txt" outfile = "dat_py.txt...
0
0
0
0
0
0
0
2
22
38a00872e8591388575e8ad092f7061f22387e6a
3,876
py
Python
mirdata/datasets/gtzan_genre.py
chrisdonahue/mirdata
c9906e0948adcc75183f5246e7baa879022efcdb
[ "BSD-3-Clause" ]
null
null
null
mirdata/datasets/gtzan_genre.py
chrisdonahue/mirdata
c9906e0948adcc75183f5246e7baa879022efcdb
[ "BSD-3-Clause" ]
null
null
null
mirdata/datasets/gtzan_genre.py
chrisdonahue/mirdata
c9906e0948adcc75183f5246e7baa879022efcdb
[ "BSD-3-Clause" ]
null
null
null
"""GTZAN-Genre Dataset Loader .. admonition:: Dataset Info :class: dropdown This dataset was used for the well known genre classification paper: .. code-block:: latex "Musical genre classification of audio signals " by G. Tzanetakis and P. Cook in IEEE Transactions on Audio and Speech Pr...
24.531646
100
0.600877
"""GTZAN-Genre Dataset Loader .. admonition:: Dataset Info :class: dropdown This dataset was used for the well known genre classification paper: .. code-block:: latex "Musical genre classification of audio signals " by G. Tzanetakis and P. Cook in IEEE Transactions on Audio and Speech Pr...
0
1,141
0
1,226
0
0
0
19
203
715d5623737288c8bb08263b4b7b00de3210ba31
2,591
py
Python
blueprints/boards.py
kusl/maniwani
9c2634342ff3e9cb92dc86cd3a4e3a4225b13a23
[ "MIT" ]
null
null
null
blueprints/boards.py
kusl/maniwani
9c2634342ff3e9cb92dc86cd3a4e3a4225b13a23
[ "MIT" ]
null
null
null
blueprints/boards.py
kusl/maniwani
9c2634342ff3e9cb92dc86cd3a4e3a4225b13a23
[ "MIT" ]
null
null
null
from flask import Blueprint boards_blueprint = Blueprint('boards', __name__, template_folder='template') boards_blueprint.add_app_template_global(style_for_tag)
37.014286
101
0.73408
from flask import Blueprint, render_template, redirect, url_for, flash from flask_restful import reqparse from markdown import markdown from model.Board import Board from model.BoardList import BoardList from model.BoardListCatalog import BoardCatalog from model.Post import render_for_catalog from model.Slip import ge...
0
1,795
0
0
0
142
0
148
337
f96db272efe118cb0d2f81a136209b560bfe188e
5,528
py
Python
config/am.py
googleinterns/text-norm-for-low-resource-languages
500c08f863539fc3aa6d000307c91b25848e1adc
[ "Apache-2.0" ]
1
2020-09-03T18:33:13.000Z
2020-09-03T18:33:13.000Z
config/am.py
googleinterns/text-norm-for-low-resource-languages
500c08f863539fc3aa6d000307c91b25848e1adc
[ "Apache-2.0" ]
3
2020-06-25T22:01:30.000Z
2020-07-30T19:40:04.000Z
config/am.py
googleinterns/text-norm-for-low-resource-languages
500c08f863539fc3aa6d000307c91b25848e1adc
[ "Apache-2.0" ]
null
null
null
"Amharic config with language-specific information." from pynini.lib import byte from config import utils GRAPHEMES = union("'", "-", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "...
41.56391
299
0.31458
"Amharic config with language-specific information." from pynini import * from pynini.lib import byte from config import utils GRAPHEMES = union("'", "-", "ሀ", "ሁ", "ሂ", "ሃ", "ሄ", "ህ", "ሆ", "ለ", "ሉ", "ሊ", "ላ", "ሌ", "ል", "ሎ", "ሏ", "ሐ", "ሑ", "ሒ", "ሓ", "ሔ", "ሕ", "ሖ",...
1,107
0
0
0
0
0
0
-1
23
074a5f38b5f51641068bed34421d80734ffa302f
1,275
py
Python
tests/mr_verbose_job.py
mikiec84/mrjob
801fffffdc6af860edd7813c948f9da341305b21
[ "Apache-2.0" ]
1,538
2015-01-02T10:22:17.000Z
2022-03-29T16:42:33.000Z
tests/mr_verbose_job.py
mikiec84/mrjob
801fffffdc6af860edd7813c948f9da341305b21
[ "Apache-2.0" ]
1,027
2015-01-09T21:30:37.000Z
2022-02-26T18:21:42.000Z
tests/mr_verbose_job.py
mikiec84/mrjob
801fffffdc6af860edd7813c948f9da341305b21
[ "Apache-2.0" ]
403
2015-01-06T15:49:44.000Z
2022-03-29T16:42:34.000Z
# Copyright 2009-2012 Yelp and Contributors # Copyright 2014 Ed Schofield # Copyright 2015 Yelp # # 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 ...
30.357143
74
0.70902
# Copyright 2009-2012 Yelp and Contributors # Copyright 2014 Ed Schofield # Copyright 2015 Yelp # # 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 ...
0
0
0
416
0
0
0
-5
68
ff3ce84693032b7db794d048169346347ad09d7e
5,946
py
Python
RansomeRambo.py
ashfaquekhan/RansomeRambo
bd91f6f6044a7c51730962416adaa83ff7176541
[ "MIT" ]
null
null
null
RansomeRambo.py
ashfaquekhan/RansomeRambo
bd91f6f6044a7c51730962416adaa83ff7176541
[ "MIT" ]
null
null
null
RansomeRambo.py
ashfaquekhan/RansomeRambo
bd91f6f6044a7c51730962416adaa83ff7176541
[ "MIT" ]
1
2021-03-19T07:06:57.000Z
2021-03-19T07:06:57.000Z
k="_________________________YOUR_KEY_________________________" global tDirs global tFiles print(''' ____ ____ _ / \__ | _ \ __ _ _ __ ___ ___ _ __ ___ ___ | _ \ __ _ _ __ ___ | |__ ___ ( @\___ | |_) / _` | '_ \/ __|/ _ \| '_ ` _ \ / _...
38.36129
91
0.581399
import os from cryptography import fernet from cryptography.fernet import Fernet from binascii import Error import string from ctypes import windll from glob import glob from github import Github from uuid import getnode as get_mac from os import path import sys k="_________________________YOUR_KEY___________________...
0
0
0
0
0
4,405
0
21
452
ce7b861febb5ee8d59fd437d679cae5012bc6f16
4,609
py
Python
tests/bdd/features/csi/controller/test_identity.py
Abhinandan-Purkait/mayastor-control-plane
73390a0e61dd93d1fb7c2735ebac579b7bb88434
[ "Apache-2.0" ]
2
2022-01-05T06:55:02.000Z
2022-01-13T22:02:37.000Z
tests/bdd/features/csi/controller/test_identity.py
Abhinandan-Purkait/mayastor-control-plane
73390a0e61dd93d1fb7c2735ebac579b7bb88434
[ "Apache-2.0" ]
67
2021-10-04T08:12:11.000Z
2022-01-19T16:59:10.000Z
tests/bdd/features/csi/controller/test_identity.py
Abhinandan-Purkait/mayastor-control-plane
73390a0e61dd93d1fb7c2735ebac579b7bb88434
[ "Apache-2.0" ]
5
2021-11-18T10:36:23.000Z
2022-01-14T20:51:51.000Z
"""CSI Controller Identity RPC tests."""
27.76506
88
0.740291
"""CSI Controller Identity RPC tests.""" from pytest_bdd import ( given, scenario, then, when, ) import pytest import docker import subprocess import csi_pb2 as pb from common.csi import CsiHandle from common.deployer import Deployer from common.apiclient import ApiClient @pytest.fixture(scope="modu...
0
3,813
0
0
0
49
0
72
615
bf266ca003e5fba0c3b0b9fc1b7a8535de42864b
13
py
Python
openml_data_integration/protobuf_generator/openml_61/myconstants.py
tuix/tutorials
733d35a8a39df079e8c2432c441b70785ab08440
[ "Apache-2.0" ]
8
2020-04-21T13:29:04.000Z
2021-12-13T08:59:09.000Z
openml_data_integration/protobuf_generator/openml_61/myconstants.py
tuix/tutorials
733d35a8a39df079e8c2432c441b70785ab08440
[ "Apache-2.0" ]
3
2021-04-27T11:03:04.000Z
2021-05-24T18:22:57.000Z
openml_data_integration/protobuf_generator/openml_61/myconstants.py
tuix/tutorials
733d35a8a39df079e8c2432c441b70785ab08440
[ "Apache-2.0" ]
6
2020-07-06T08:23:25.000Z
2021-11-24T10:39:34.000Z
DATA_ID = 61
6.5
12
0.692308
DATA_ID = 61
0
0
0
0
0
0
0
0
0
a57f096969ac9ee95489c6e8b7567700ba86d2eb
102
py
Python
models/control_agent.py
KevinJeon/The-Tragedy-of-the-commons
7151faf25fd91732de19a843b39cd1f2614f34ca
[ "Apache-2.0" ]
5
2021-03-21T15:04:36.000Z
2021-06-22T14:09:00.000Z
models/control_agent.py
KevinJeon/The-Tragedy-of-the-commons
7151faf25fd91732de19a843b39cd1f2614f34ca
[ "Apache-2.0" ]
5
2021-04-10T08:16:16.000Z
2021-09-12T09:28:42.000Z
models/control_agent.py
KevinJeon/The-Tragedy-of-the-commons
7151faf25fd91732de19a843b39cd1f2614f34ca
[ "Apache-2.0" ]
2
2021-04-26T22:33:19.000Z
2021-06-08T18:13:49.000Z
import torch.nn as nn
10.2
23
0.666667
import torch.nn as nn import torch as tr class ControlTower: def __init__(self): pass
0
0
0
36
0
0
0
-3
45
ae524e05388437d5528605d101b38fa984ea9adb
3,321
py
Python
snsim/dust_utils.py
bcarreres/snsim
86ffc49f254cd89c74be9c3350c00982e3d216e2
[ "BSD-3-Clause" ]
5
2021-07-14T18:23:59.000Z
2022-02-02T13:09:55.000Z
snsim/dust_utils.py
bcarreres/snsim
86ffc49f254cd89c74be9c3350c00982e3d216e2
[ "BSD-3-Clause" ]
7
2021-02-25T15:19:59.000Z
2021-11-24T08:24:55.000Z
snsim/dust_utils.py
bcarreres/snsim
86ffc49f254cd89c74be9c3350c00982e3d216e2
[ "BSD-3-Clause" ]
1
2021-05-19T11:25:18.000Z
2021-05-19T11:25:18.000Z
"""This module contains dust features.""" import os import sncosmo as snc import sfdmap from snsim import __snsim_dir_path__ import glob import requests import tarfile def check_files_and_dowload(): """Check if sdfmap files are here and download if not. Returns ------- None No return, just d...
28.144068
95
0.613972
"""This module contains dust features.""" import os import sncosmo as snc import sfdmap from snsim import __snsim_dir_path__ import glob import requests import tarfile def check_files_and_dowload(): """Check if sdfmap files are here and download if not. Returns ------- None No return, just d...
0
0
0
0
0
0
0
0
0
5a81acb80f3e5af524b468d8e34e3dbfea839359
67
py
Python
yun/batch/__init__.py
NbKevin/ArduinoYunAPI
9f928cb9b7b99c19a2f255c6194f5a3ff7a06732
[ "Apache-2.0" ]
null
null
null
yun/batch/__init__.py
NbKevin/ArduinoYunAPI
9f928cb9b7b99c19a2f255c6194f5a3ff7a06732
[ "Apache-2.0" ]
null
null
null
yun/batch/__init__.py
NbKevin/ArduinoYunAPI
9f928cb9b7b99c19a2f255c6194f5a3ff7a06732
[ "Apache-2.0" ]
null
null
null
#!/usr/env/bin python # -*- encoding: utf-8 -*- __author__ = 'Nb'
13.4
25
0.58209
#!/usr/env/bin python # -*- encoding: utf-8 -*- __author__ = 'Nb'
0
0
0
0
0
0
0
0
0
39c723183c5ba9cbd0b76ee6b6fd2c3a10c44e46
4,731
py
Python
bytemailgui.py
Max00355/ByteMail-1
576f765da9fb88f23b4d5c46868e0ce16db83c7c
[ "MIT" ]
4
2016-02-18T15:11:58.000Z
2020-01-16T11:07:50.000Z
bytemailgui.py
Max00355/ByteMail-1
576f765da9fb88f23b4d5c46868e0ce16db83c7c
[ "MIT" ]
1
2021-03-06T00:07:14.000Z
2021-03-06T00:15:26.000Z
bytemailgui.py
Max00355/ByteMail-1
576f765da9fb88f23b4d5c46868e0ce16db83c7c
[ "MIT" ]
1
2017-11-08T04:33:38.000Z
2017-11-08T04:33:38.000Z
from flask import Flask app = Flask(__name__) if __name__ == "__main__": app.run(debug=True, port=5044)
31.331126
154
0.535193
from flask import Flask, redirect, render_template, request import db import message import random import read import delete import addressbook import sent as sent_ app = Flask(__name__) def check(): while True: try: c = db.messages.find("messages", "all") break except: ...
0
3,760
0
0
0
462
0
-13
410
b331dfbb5fb50ffa7069ef01c5dd5fd6c434574e
4,413
py
Python
alexander/dqn/func_q_learning.py
Fiona55/hiv_experiment
de79d5bac3499025e1a7e2d456810490c6ecb4e9
[ "MIT" ]
null
null
null
alexander/dqn/func_q_learning.py
Fiona55/hiv_experiment
de79d5bac3499025e1a7e2d456810490c6ecb4e9
[ "MIT" ]
null
null
null
alexander/dqn/func_q_learning.py
Fiona55/hiv_experiment
de79d5bac3499025e1a7e2d456810490c6ecb4e9
[ "MIT" ]
3
2022-03-14T15:27:46.000Z
2022-03-22T13:00:44.000Z
import torch.nn as nn
24.653631
88
0.628144
import math from typing import Callable, Tuple import numpy as np import torch import torch.nn as nn from loguru import logger from tqdm import tqdm from alexander.dqn.buffer import ReplayBuffer from alexander.dqn.hiv_patient import HIVPatient from alexander.dqn.q_agent import Agent from dataclasses import dataclass ...
0
201
0
340
0
3,360
0
76
406
883d362ff7bd311b837cd50bd2844900ea38d650
1,947
py
Python
src/gui_statistics_calculation.py
ukasofisosaari/hp_tilasto_tyokalu
a70349318cf6346caaa5ec90447770200568b026
[ "MIT" ]
1
2017-06-08T07:03:46.000Z
2017-06-08T07:03:46.000Z
src/gui_statistics_calculation.py
ukasofisosaari/hp_tilasto_tyokalu
a70349318cf6346caaa5ec90447770200568b026
[ "MIT" ]
4
2017-10-07T10:57:11.000Z
2017-10-07T11:01:43.000Z
src/gui_statistics_calculation.py
ukasofisosaari/kuksa_tilastotyokalu
a70349318cf6346caaa5ec90447770200568b026
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 #-*- coding: utf-8 -*- """ Module for statistics calculation side of the ui"""
38.176471
99
0.694915
#!/usr/bin/env python3 #-*- coding: utf-8 -*- """ Module for statistics calculation side of the ui""" from PyQt5.QtWidgets import QVBoxLayout, QWidget, QLabel, QPushButton, QFileDialog class GUIStatisticsCalculation(QWidget): """ Right side of UI, ie. the statistics calculation settings and parameters.""" de...
0
0
0
1,737
0
0
0
61
46
2caecc06a26095213805a7eb2eeab68c1980239d
1,001
py
Python
syne_tune/__init__.py
hfurkanbozkurt/syne-tune
05ee2668f0155b40c3ee3b61e4b3d58f3f9f3c4f
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
syne_tune/__init__.py
hfurkanbozkurt/syne-tune
05ee2668f0155b40c3ee3b61e4b3d58f3f9f3c4f
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
syne_tune/__init__.py
hfurkanbozkurt/syne-tune
05ee2668f0155b40c3ee3b61e4b3d58f3f9f3c4f
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
# Copyright 2021 Amazon.com, Inc. or its affiliates. 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. # A copy of the License is located at # # http://www.apache.org/licenses/LICENSE-2.0 # # or in the "license...
33.366667
75
0.73027
# Copyright 2021 Amazon.com, Inc. or its affiliates. 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. # A copy of the License is located at # # http://www.apache.org/licenses/LICENSE-2.0 # # or in the "license...
0
0
0
0
0
107
0
3
49
0a647ce0725e038910f5e586bc9cad57b2a1591d
23,153
py
Python
clients/python-flask/generated/openapi_server/models/free_style_project.py
cliffano/jenkins-api-clients-generator
522d02b3a130a29471df5ec1d3d22c822b3d0813
[ "MIT" ]
null
null
null
clients/python-flask/generated/openapi_server/models/free_style_project.py
cliffano/jenkins-api-clients-generator
522d02b3a130a29471df5ec1d3d22c822b3d0813
[ "MIT" ]
null
null
null
clients/python-flask/generated/openapi_server/models/free_style_project.py
cliffano/jenkins-api-clients-generator
522d02b3a130a29471df5ec1d3d22c822b3d0813
[ "MIT" ]
null
null
null
# coding: utf-8 from __future__ import absolute_import from openapi_server.models.free_style_build import FreeStyleBuild from openapi_server.models.free_style_projectactions import FreeStyleProjectactions from openapi_server.models.free_style_projecthealth_report import FreeStyleProjecthealthReport from openapi_server...
30.911883
557
0.661037
# coding: utf-8 from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 from openapi_server.models.base_model_ import Model from openapi_server.models.free_style_build import FreeStyleBuild from openapi_server.models.free_style_projectactio...
0
13,197
0
9,048
0
0
0
270
286
f657d71bced67aaaaac27a13df0ae0fb35ce68ed
10,329
py
Python
monkNode.py
atria-tools/monk
4961457f4db5dfa98fc6001a289c24e460e5b025
[ "Apache-2.0" ]
null
null
null
monkNode.py
atria-tools/monk
4961457f4db5dfa98fc6001a289c24e460e5b025
[ "Apache-2.0" ]
1
2015-03-22T12:37:18.000Z
2015-03-22T12:37:18.000Z
monkNode.py
HeeroYui/monk
4961457f4db5dfa98fc6001a289c24e460e5b025
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/python access_list = ['private', 'protected', 'public'] genericUID = 0
26.759067
162
0.645367
#!/usr/bin/python import monkDebug as debug import monkModule as module access_list = ['private', 'protected', 'public'] def debug_space(level): ret = "" for iii in range(0,level): ret += " " return ret genericUID = 0 class Node(): def __init__(self, type, name="", file="", line_number=0, documentation=[])...
0
0
0
9,534
0
562
0
10
136
61c6228d07263ba5b340f2078725ac7dc107668c
1,802
py
Python
src/110.BalancedBinaryTree/110.py
Taowyoo/LeetCodeLog
cb05798538dd10675bf81011a419d0e33d85e4e0
[ "MIT" ]
null
null
null
src/110.BalancedBinaryTree/110.py
Taowyoo/LeetCodeLog
cb05798538dd10675bf81011a419d0e33d85e4e0
[ "MIT" ]
null
null
null
src/110.BalancedBinaryTree/110.py
Taowyoo/LeetCodeLog
cb05798538dd10675bf81011a419d0e33d85e4e0
[ "MIT" ]
null
null
null
''' File: 110.py File Created: 2021-01-12 13:48:32 -08:00 Author: Taowyoo (caoyxsh@outlook.com) Brief: https://leetcode.com/problems/balanced-binary-tree/ ----- Last Modified: 2021-01-12 13:48:41 -08:00 Modified By: Taowyoo (caoyxsh@outlook.com>) ----- Copyright 2020 - 2021 ''' # Definition for a binary tree node. # c...
28.603175
86
0.498335
''' File: 110.py File Created: 2021-01-12 13:48:32 -08:00 Author: Taowyoo (caoyxsh@outlook.com) Brief: https://leetcode.com/problems/balanced-binary-tree/ ----- Last Modified: 2021-01-12 13:48:41 -08:00 Modified By: Taowyoo (caoyxsh@outlook.com>) ----- Copyright 2020 - 2021 ''' # Definition for a binary tree node. # c...
0
0
0
1,285
0
0
0
0
45
855b5b5f58d42b9a856daaad9651e9f5bff5e131
486
py
Python
examples/Boards/pyboard/Display/ssd1306Demo.py
myhumankit/ESP32_IDE_accessible
5262a5dd106f3f52a374a6c1ef68ff53d8847001
[ "MIT" ]
1
2020-07-27T19:32:56.000Z
2020-07-27T19:32:56.000Z
examples/Boards/pyboard/Display/ssd1306Demo.py
myhumankit/Blind_IDE
5262a5dd106f3f52a374a6c1ef68ff53d8847001
[ "MIT" ]
null
null
null
examples/Boards/pyboard/Display/ssd1306Demo.py
myhumankit/Blind_IDE
5262a5dd106f3f52a374a6c1ef68ff53d8847001
[ "MIT" ]
null
null
null
#hardware platform: pyboard V1.1 import pyb import ssd1306 i2c=pyb.I2C(1,pyb.I2C.MASTER,baudrate=100000) #Init i2c lcd=ssd1306.SSD1306_I2C(128,64,i2c) #create LCD object,Specify width and height lcd.text("DFRobot",0,0) #set "DFRobot" at (0,0) lcd.text("chengdu",24,16) ...
44.181818
91
0.547325
#hardware platform: pyboard V1.1 import pyb import ssd1306 i2c=pyb.I2C(1,pyb.I2C.MASTER,baudrate=100000) #Init i2c lcd=ssd1306.SSD1306_I2C(128,64,i2c) #create LCD object,Specify width and height lcd.text("DFRobot",0,0) #set "DFRobot" at (0,0) lcd.text("chengdu",24,16) ...
0
0
0
0
0
0
0
0
0
be1fe1edfef0a5b0c9144e72f09f8b6e5ed105d5
35
py
Python
scripts/portal/back_Ludi.py
pantskun/swordiemen
fc33ffec168e6611587fdc75de8270f6827a4176
[ "MIT" ]
null
null
null
scripts/portal/back_Ludi.py
pantskun/swordiemen
fc33ffec168e6611587fdc75de8270f6827a4176
[ "MIT" ]
null
null
null
scripts/portal/back_Ludi.py
pantskun/swordiemen
fc33ffec168e6611587fdc75de8270f6827a4176
[ "MIT" ]
null
null
null
# 223000000 sm.warp(220000000, 26)
11.666667
22
0.742857
# 223000000 sm.warp(220000000, 26)
0
0
0
0
0
0
0
0
0
20c273b1cbd7836ca08eb5b6aa9404af047b5767
816
py
Python
backend/users/migrations/0003_auto_20210710_2236.py
Swannbm/django3-vue2
22bc7cc156e89d40e63f1edd5419547177903ebf
[ "CC0-1.0" ]
null
null
null
backend/users/migrations/0003_auto_20210710_2236.py
Swannbm/django3-vue2
22bc7cc156e89d40e63f1edd5419547177903ebf
[ "CC0-1.0" ]
3
2022-02-10T11:47:58.000Z
2022-02-23T18:50:24.000Z
backend/users/migrations/0003_auto_20210710_2236.py
Swannbm/django3-vue2
22bc7cc156e89d40e63f1edd5419547177903ebf
[ "CC0-1.0" ]
null
null
null
# Generated by Django 3.2.5 on 2021-07-10 22:36
25.5
67
0.555147
# Generated by Django 3.2.5 on 2021-07-10 22:36 from django.db import migrations, models import django.utils.timezone class Migration(migrations.Migration): dependencies = [ ("users", "0002_auto_20210706_2214"), ] operations = [ migrations.AddField( model_name="user", ...
0
0
0
673
0
0
0
26
68
0ed74bd87270d561a4ec564b6ffdc46f62221f3f
2,155
py
Python
cu_parser.py
clownkill/CU_bot
08a42afa7110fc15df35838e1dcaab032b230631
[ "MIT" ]
null
null
null
cu_parser.py
clownkill/CU_bot
08a42afa7110fc15df35838e1dcaab032b230631
[ "MIT" ]
null
null
null
cu_parser.py
clownkill/CU_bot
08a42afa7110fc15df35838e1dcaab032b230631
[ "MIT" ]
null
null
null
if __name__ == '__main__': main()
34.758065
137
0.722042
from selenium.webdriver import Chrome from selenium.webdriver import ChromeOptions from selenium.webdriver.chrome.service import Service from selenium.webdriver.common.by import By from webdriver_manager.chrome import ChromeDriverManager def get_card_links(driver, end_page): card_links = [] for page in range(...
0
0
0
0
0
1,781
0
128
202
4d2ece47a2b1be41bd4a7f580594280353211d45
2,403
py
Python
to-send-a-fax/to_send_a_fax_test.py
simonbates/collected
fd4cbaaf75ca25688983f39d51a02b42a86b3e5a
[ "MIT" ]
1
2019-11-11T12:54:54.000Z
2019-11-11T12:54:54.000Z
to-send-a-fax/to_send_a_fax_test.py
simonbates/collected
fd4cbaaf75ca25688983f39d51a02b42a86b3e5a
[ "MIT" ]
null
null
null
to-send-a-fax/to_send_a_fax_test.py
simonbates/collected
fd4cbaaf75ca25688983f39d51a02b42a86b3e5a
[ "MIT" ]
null
null
null
import unittest if __name__ == '__main__': unittest.main()
36.969231
72
0.55181
from to_send_a_fax import E, f import unittest class ToSendAFaxTest(unittest.TestCase): def test_E(self): self.assertEqual(4, E(0)) # zero self.assertEqual(3, E(1)) # one self.assertEqual(3, E(2)) # two self.assertEqual(5, E(3)) # three self.assertEqual(4, E(4))...
0
0
0
2,285
0
0
0
9
45
67065dc0824fb854b2b7a7e019e82ceb63c779c4
2,404
py
Python
wagtail/wagtailcore/wagtail_hooks.py
chrxr/wagtail
9038da9fcd69f0b39121cc54a72f4a6ae6beb06a
[ "BSD-3-Clause" ]
1
2016-12-28T11:51:15.000Z
2016-12-28T11:51:15.000Z
wagtail/wagtailcore/wagtail_hooks.py
chrxr/wagtail
9038da9fcd69f0b39121cc54a72f4a6ae6beb06a
[ "BSD-3-Clause" ]
null
null
null
wagtail/wagtailcore/wagtail_hooks.py
chrxr/wagtail
9038da9fcd69f0b39121cc54a72f4a6ae6beb06a
[ "BSD-3-Clause" ]
null
null
null
from __future__ import absolute_import, unicode_literals
51.148936
114
0.709235
from __future__ import absolute_import, unicode_literals from django.conf import settings from django.contrib.auth.views import redirect_to_login from django.core.urlresolvers import reverse from wagtail.utils.compat import user_is_authenticated from wagtail.wagtailcore import hooks from wagtail.wagtailcore.models im...
0
1,860
0
0
0
151
0
154
180
ed6e516c8aaad603f5a38fb41ff6e59415eebdc7
2,013
py
Python
var/spack/repos/builtin/packages/vecgeom/package.py
xiki-tempula/spack
9d66c05e93ab8a933fc59915040c0e0c86a4aac4
[ "ECL-2.0", "Apache-2.0", "MIT" ]
null
null
null
var/spack/repos/builtin/packages/vecgeom/package.py
xiki-tempula/spack
9d66c05e93ab8a933fc59915040c0e0c86a4aac4
[ "ECL-2.0", "Apache-2.0", "MIT" ]
1
2018-07-06T19:11:46.000Z
2018-07-06T19:12:28.000Z
var/spack/repos/builtin/packages/vecgeom/package.py
xiki-tempula/spack
9d66c05e93ab8a933fc59915040c0e0c86a4aac4
[ "ECL-2.0", "Apache-2.0", "MIT" ]
1
2020-03-06T11:04:37.000Z
2020-03-06T11:04:37.000Z
# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT)
37.277778
106
0.610035
# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) from spack import * import platform class Vecgeom(CMakePackage): """The vectorized geometry library for particle-de...
0
0
0
1,754
0
0
0
-8
68
e54bcc9091ea82eec692dff25ba500ba8747bb73
1,075
py
Python
fileprocessing.py
lsauthie/nlp
8d562443ffea056a66db6ec87823d9198255884d
[ "MIT" ]
null
null
null
fileprocessing.py
lsauthie/nlp
8d562443ffea056a66db6ec87823d9198255884d
[ "MIT" ]
null
null
null
fileprocessing.py
lsauthie/nlp
8d562443ffea056a66db6ec87823d9198255884d
[ "MIT" ]
null
null
null
# This module is in charge of managing files from pathlib import Path home = Path(__file__).parents[0] #write configuration information
22.395833
81
0.611163
# This module is in charge of managing files import csv import json from pathlib import Path import os home = Path(__file__).parents[0] def read_csv(filename): list_file = [] with open(home / filename, 'r', encoding="utf-8-sig") as f: reader = csv.reader(f, delimiter=';') list_file = list...
0
0
0
0
0
812
0
-33
157
7ef4aae6f3e4070da2cce418773477b7fab5a70f
1,647
py
Python
examples/redirect_print.py
ofek/tqdm
170bf4a353894f4f42190afac817c833b07077a6
[ "MIT" ]
1
2017-09-11T17:48:20.000Z
2017-09-11T17:48:20.000Z
examples/redirect_print.py
ofek/tqdm
170bf4a353894f4f42190afac817c833b07077a6
[ "MIT" ]
null
null
null
examples/redirect_print.py
ofek/tqdm
170bf4a353894f4f42190afac817c833b07077a6
[ "MIT" ]
null
null
null
"""Redirecting writing If using a library that can print messages to the console, editing the library by replacing `print()` with `tqdm.write()` may not be desirable. In that case, redirecting `sys.stdout` to `tqdm.write()` is an option. To redirect `sys.stdout`, create a file-like class that will write any input st...
27
78
0.692168
"""Redirecting writing If using a library that can print messages to the console, editing the library by replacing `print()` with `tqdm.write()` may not be desirable. In that case, redirecting `sys.stdout` to `tqdm.write()` is an option. To redirect `sys.stdout`, create a file-like class that will write any input st...
0
308
0
277
0
16
0
-15
113
5ca73c1342032c6607c82fdb86402a0ba3c46925
54
py
Python
WinPlaceShowAPI/jsonapi/predictions.py
jojordan3/winplaceshow-api
eaa8383935339e4b3abb8167d6005290a731f426
[ "MIT" ]
null
null
null
WinPlaceShowAPI/jsonapi/predictions.py
jojordan3/winplaceshow-api
eaa8383935339e4b3abb8167d6005290a731f426
[ "MIT" ]
6
2020-02-12T00:08:59.000Z
2021-06-10T17:58:35.000Z
WinPlaceShowAPI/jsonapi/predictions.py
jojordan3/winplaceshow-api
eaa8383935339e4b3abb8167d6005290a731f426
[ "MIT" ]
null
null
null
"""Here is a thing"""
13.5
22
0.62963
"""Here is a thing""" class RacePredictor(): pass
0
0
0
10
0
0
0
0
23
1133ddefe5c708be325c6b1aaa0cb80a18cf1bd3
5,120
py
Python
hermite_functions/hermite_functions.py
Rob217/Hermite-functions
f6fc5f8115055619f2b8ec1051eca6c4621569a4
[ "MIT" ]
1
2020-09-14T20:00:52.000Z
2020-09-14T20:00:52.000Z
hermite_functions/hermite_functions.py
Rob217/Hermite-functions
f6fc5f8115055619f2b8ec1051eca6c4621569a4
[ "MIT" ]
8
2020-08-24T10:02:24.000Z
2020-09-14T19:36:26.000Z
hermite_functions/hermite_functions.py
Rob217/Hermite-functions
f6fc5f8115055619f2b8ec1051eca6c4621569a4
[ "MIT" ]
null
null
null
import numpy as np from scipy.special import eval_hermite, factorial def hermite_functions(n, x, all_n=True, move_axes=(), method="recursive"): """ Calculate the Hermite functions up to the nth order at position x, psi_n(x). For details see: https://en.wikipedia.org/wiki/Hermite_polynomials#Hermite_f...
26.947368
84
0.525391
import numpy as np from scipy.special import eval_hermite, factorial def hermite_functions(n, x, all_n=True, move_axes=(), method="recursive"): """ Calculate the Hermite functions up to the nth order at position x, psi_n(x). For details see: https://en.wikipedia.org/wiki/Hermite_polynomials#Hermite_f...
0
0
0
0
0
0
0
0
0
9181edf2bd0bc5bea757c317ebd41cf545bd2f15
2,979
py
Python
sbcdb/reaction_utils.py
neilswainston/Grimoire
42775ff9a03fdbd3b47269b46c883fdf5b37a2be
[ "MIT" ]
9
2019-04-24T12:47:10.000Z
2021-05-12T12:46:33.000Z
sbcdb/reaction_utils.py
neilswainston/Grimoire
42775ff9a03fdbd3b47269b46c883fdf5b37a2be
[ "MIT" ]
1
2017-01-16T08:45:19.000Z
2017-01-16T08:45:19.000Z
sbcdb/reaction_utils.py
synbiochem/biochem4j
42775ff9a03fdbd3b47269b46c883fdf5b37a2be
[ "MIT" ]
5
2019-10-13T14:02:28.000Z
2020-12-23T18:44:29.000Z
''' SYNBIOCHEM-DB (c) University of Manchester 2015 SYNBIOCHEM-DB is licensed under the MIT License. To view a copy of this license, visit <http://opensource.org/licenses/MIT/>. @author: neilswainston '''
35.891566
78
0.570326
''' SYNBIOCHEM-DB (c) University of Manchester 2015 SYNBIOCHEM-DB is licensed under the MIT License. To view a copy of this license, visit <http://opensource.org/licenses/MIT/>. @author: neilswainston ''' from sbcdb.enzyme_utils import EnzymeManager class ReactionManager(object): '''Class to implement a manag...
0
0
0
2,701
0
0
0
23
45
173faf3fa2e7960c16e61ab2a3f0a1a52bc4c745
3,830
py
Python
lib_bgp_data/collectors/as_rank_v2/as_rank_v2_parser.py
jfuruness/lib_bgp_data
25f7d57b9e2101c7aefb325e8d728bd91f47d557
[ "BSD-3-Clause" ]
16
2018-09-24T05:10:03.000Z
2021-11-29T19:18:59.000Z
lib_bgp_data/collectors/as_rank_v2/as_rank_v2_parser.py
jfuruness/lib_bgp_data
25f7d57b9e2101c7aefb325e8d728bd91f47d557
[ "BSD-3-Clause" ]
4
2019-10-09T18:54:17.000Z
2021-03-05T14:02:50.000Z
lib_bgp_data/collectors/as_rank_v2/as_rank_v2_parser.py
jfuruness/lib_bgp_data
25f7d57b9e2101c7aefb325e8d728bd91f47d557
[ "BSD-3-Clause" ]
3
2018-09-17T17:35:18.000Z
2020-03-24T16:03:31.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """Contains AS_Rank_V2 which parses AS Rank data using the Restful API In contrast to the previous parser this also gets organization, rank, and links to other ASNs""" __author__ = "Nicholas Shpetner" __credits__ = ["Nicholas Shpetner", "Abhinna Adhikari", "Justin Furun...
32.735043
81
0.538381
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """Contains AS_Rank_V2 which parses AS Rank data using the Restful API In contrast to the previous parser this also gets organization, rank, and links to other ASNs""" __author__ = "Nicholas Shpetner" __credits__ = ["Nicholas Shpetner", "Abhinna Adhikari", "Justin Furun...
0
0
0
3,207
0
0
0
1
180
c51ed96a09e740368a84781e4fac620344758b83
393
py
Python
codeforces.com/758A/solution.py
zubtsov/competitive-programming
919d63130144347d7f6eddcf8f5bc2afb85fddf3
[ "MIT" ]
null
null
null
codeforces.com/758A/solution.py
zubtsov/competitive-programming
919d63130144347d7f6eddcf8f5bc2afb85fddf3
[ "MIT" ]
null
null
null
codeforces.com/758A/solution.py
zubtsov/competitive-programming
919d63130144347d7f6eddcf8f5bc2afb85fddf3
[ "MIT" ]
null
null
null
max_theoretical_welfare = 1000000 number_of_citizens = int(input()) total_money_spent = 0 max_welfare = 0 for current_welfare in map(int, input().split()): total_money_spent += (max_theoretical_welfare - current_welfare) if current_welfare > max_welfare: max_welfare = current_welfare print(total_mon...
28.071429
87
0.776081
max_theoretical_welfare = 1000000 number_of_citizens = int(input()) total_money_spent = 0 max_welfare = 0 for current_welfare in map(int, input().split()): total_money_spent += (max_theoretical_welfare - current_welfare) if current_welfare > max_welfare: max_welfare = current_welfare print(total_mon...
0
0
0
0
0
0
0
0
0
868d131e12bd9fc7e48c6715c9f81639852f6958
19,704
py
Python
neutron/tests/unit/extensions/test_network_ip_availability.py
ilay09/neutron
b7f9803c88b17a6ebd40fd44d15d4336bea7b394
[ "Apache-2.0" ]
null
null
null
neutron/tests/unit/extensions/test_network_ip_availability.py
ilay09/neutron
b7f9803c88b17a6ebd40fd44d15d4336bea7b394
[ "Apache-2.0" ]
null
null
null
neutron/tests/unit/extensions/test_network_ip_availability.py
ilay09/neutron
b7f9803c88b17a6ebd40fd44d15d4336bea7b394
[ "Apache-2.0" ]
null
null
null
# Copyright 2016 GoDaddy. # # 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, ...
51.989446
79
0.545321
# Copyright 2016 GoDaddy. # # 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, ...
0
186
0
18,279
0
0
0
31
69
216a9777e24096faf53003965097897032262b52
1,530
py
Python
leads/views.py
tapanhp/django_crm
d092af1faf37c62674dc05d5faaeeba5fcc6bb68
[ "MIT" ]
null
null
null
leads/views.py
tapanhp/django_crm
d092af1faf37c62674dc05d5faaeeba5fcc6bb68
[ "MIT" ]
null
null
null
leads/views.py
tapanhp/django_crm
d092af1faf37c62674dc05d5faaeeba5fcc6bb68
[ "MIT" ]
null
null
null
# The newest implementation supporting model forms
30
84
0.69085
from django.shortcuts import render, redirect from .models import Lead, Agent from .forms import LeadModelForm, LeadForm from django.views.generic import TemplateView class LandingPageView(TemplateView): template_name = "landing.html" class LeadListView(TemplateView): template_name = "leads/lead_list.html" ...
0
0
0
156
0
1,012
0
79
225
8a483fb637700edab7aeb2e9ef5a798fec2e6a39
5,156
py
Python
conans/client/build/compiler_flags.py
rukgar/conan
02e0e1718da20d67348761fe24a39110f70b1664
[ "MIT" ]
null
null
null
conans/client/build/compiler_flags.py
rukgar/conan
02e0e1718da20d67348761fe24a39110f70b1664
[ "MIT" ]
null
null
null
conans/client/build/compiler_flags.py
rukgar/conan
02e0e1718da20d67348761fe24a39110f70b1664
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- """ # Visual Studio cl options reference: # https://msdn.microsoft.com/en-us/library/610ecb4h.aspx # "Options are specified by either a forward slash (/) or a dash ()." # Here we use "-" better than "/" that produces invalid escaped chars using Au...
31.82716
97
0.604926
#!/usr/bin/env python # -*- coding: utf-8 -*- """ # Visual Studio cl options reference: # https://msdn.microsoft.com/en-us/library/610ecb4h.aspx # "Options are specified by either a forward slash (/) or a dash (–)." # Here we use "-" better than "/" that produces invalid escaped chars using A...
3
0
0
0
0
1,880
0
0
184
eda29fae963113bfc8359413b963e765ffb35012
3,392
py
Python
make_responsive_images/main.py
mccarthysean/responsive-images-generator
3973bf3de69eaff43e6fbf010190626c2eaae2a8
[ "MIT" ]
null
null
null
make_responsive_images/main.py
mccarthysean/responsive-images-generator
3973bf3de69eaff43e6fbf010190626c2eaae2a8
[ "MIT" ]
null
null
null
make_responsive_images/main.py
mccarthysean/responsive-images-generator
3973bf3de69eaff43e6fbf010190626c2eaae2a8
[ "MIT" ]
null
null
null
import logging import typer app = typer.Typer() logger = logging.getLogger(__name__) logger.setLevel(logging.DEBUG)
29.754386
88
0.600825
import logging from pathlib import Path from typing import Optional import typer from . import __app_name__, __version__ from .utils import make_html, resize_image app = typer.Typer() logger = logging.getLogger(__name__) logger.setLevel(logging.DEBUG) def _version_callback(value: bool) -> None: if value: ...
0
2,949
0
0
0
116
0
48
158
d39c831d0e173af80cda2346e3fcde70b0552897
489
py
Python
service/impl/epoca_cosmeticos.py
ralphavalon/avaloncrawler
1da60d3f463f1ce8e4422604bc59a86b72e60586
[ "MIT" ]
null
null
null
service/impl/epoca_cosmeticos.py
ralphavalon/avaloncrawler
1da60d3f463f1ce8e4422604bc59a86b72e60586
[ "MIT" ]
null
null
null
service/impl/epoca_cosmeticos.py
ralphavalon/avaloncrawler
1da60d3f463f1ce8e4422604bc59a86b72e60586
[ "MIT" ]
null
null
null
# coding: utf-8
23.285714
62
0.640082
# coding: utf-8 import os from ..crawlable import Crawlable class EpocaCosmeticos(Crawlable): def get_crawlable_name(self): return 'EpocaCosmeticos' def get_category_pages(self): return '//div[@class="menu"]//a/@href' def get_product_pages(self): return '.*/p$' def get...
0
0
0
405
0
0
0
0
69
3c6cfb957e3b92b337bc0d431ffb2ddfe0667ac7
12,108
py
Python
src/kepler_apertures/utils.py
jorgemarpa/kepler-apertures
a9a3842016a05a57e79fd47338bef0aa354bb148
[ "MIT" ]
null
null
null
src/kepler_apertures/utils.py
jorgemarpa/kepler-apertures
a9a3842016a05a57e79fd47338bef0aa354bb148
[ "MIT" ]
null
null
null
src/kepler_apertures/utils.py
jorgemarpa/kepler-apertures
a9a3842016a05a57e79fd47338bef0aa354bb148
[ "MIT" ]
null
null
null
""" Collection of utility functions """ import numpy as np from scipy import sparse from patsy import dmatrix def make_A_edges(r, f, type="quadratic"): """ Creates a design matrix to estimate the PSF edge (in pixels) as a function of the flux. Parameters ---------- r : numpy ndarray ...
34.594286
91
0.604972
""" Collection of utility functions """ import numpy as np import functools from scipy import sparse from patsy import dmatrix from tqdm import tqdm import pyia import matplotlib.pyplot as plt from astropy import units from astropy.time import Time from astropy.timeseries import BoxLeastSquares @functools.lru_cach...
0
4,818
0
0
0
0
0
32
178
58fb3a80e8c923b6b6872cddc70637f8833f56d6
9,842
py
Python
platform_tools/android/gyp_gen/makefile_writer.py
AsdMonio/rr-external_skia
3839e72932bcef2f26a4f8826bb92b195f6cc396
[ "Apache-2.0" ]
3
2015-08-16T03:44:19.000Z
2015-08-16T17:31:59.000Z
platform_tools/android/gyp_gen/makefile_writer.py
AsdMonio/rr-external_skia
3839e72932bcef2f26a4f8826bb92b195f6cc396
[ "Apache-2.0" ]
null
null
null
platform_tools/android/gyp_gen/makefile_writer.py
AsdMonio/rr-external_skia
3839e72932bcef2f26a4f8826bb92b195f6cc396
[ "Apache-2.0" ]
20
2017-01-09T01:07:17.000Z
2020-08-19T06:46:45.000Z
#!/usr/bin/python # Copyright 2014 Google Inc. # # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """ Functions for creating an Android.mk from already created dictionaries. """ import os def write_group(f, name, items, append): """Helper function to list all n...
33.705479
80
0.63605
#!/usr/bin/python # Copyright 2014 Google Inc. # # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """ Functions for creating an Android.mk from already created dictionaries. """ import os def write_group(f, name, items, append): """Helper function to list all n...
0
0
0
563
0
0
0
0
23
87e3d4ce5ec6959c3eb2645e9291823efb370d74
8,234
py
Python
scripts/scripted_collect.py
VentusYue/roboverse
bd19e0ef7bdcae1198aa768bfe9fc18c51878b6d
[ "MIT" ]
null
null
null
scripts/scripted_collect.py
VentusYue/roboverse
bd19e0ef7bdcae1198aa768bfe9fc18c51878b6d
[ "MIT" ]
null
null
null
scripts/scripted_collect.py
VentusYue/roboverse
bd19e0ef7bdcae1198aa768bfe9fc18c51878b6d
[ "MIT" ]
null
null
null
import numpy as np import argparse import h5py EPSILON = 0.1 def dump2h5(traj, path, image_rendered): """Dumps a collected trajectory to HDF5 file.""" # convert to numpy arrays states = np.array([o['state'] for o in traj['observations']]) if image_rendered: images = np.array([o['image'] for ...
36.114035
100
0.629342
import numpy as np import time import os import os.path as osp import roboverse from roboverse.policies import policies import argparse from tqdm import tqdm import h5py from roboverse.utils import get_timestamp EPSILON = 0.1 def add_transition(traj, observation, action, reward, info, agent_info, done, ...
0
0
0
0
0
5,732
0
11
224
7d61c1160eddb50ddcacb8eb204ce8b18e82bfac
2,349
py
Python
django/mantistable/urls.py
sizxy3462g5829bz/mantistable4-modified
d894ade055da4aa7f7febb10ead3527fa6cdc57a
[ "Apache-2.0" ]
null
null
null
django/mantistable/urls.py
sizxy3462g5829bz/mantistable4-modified
d894ade055da4aa7f7febb10ead3527fa6cdc57a
[ "Apache-2.0" ]
null
null
null
django/mantistable/urls.py
sizxy3462g5829bz/mantistable4-modified
d894ade055da4aa7f7febb10ead3527fa6cdc57a
[ "Apache-2.0" ]
null
null
null
from django.contrib import admin from django.urls import path, include from django.views.generic.base import RedirectView from api import urls as api_urls from web_api import urls as webapi_urls def get_swagger_view(title=None, url=None, patterns=None, urlconf=None, description=None): """ Returns schema view ...
30.907895
172
0.680289
from django.contrib import admin from django.urls import path, include from django.views.generic.base import RedirectView from rest_framework_swagger import renderers from rest_framework import exceptions from rest_framework.permissions import AllowAny from rest_framework.renderers import CoreJSONRenderer from rest_fr...
0
0
0
794
0
0
0
168
181
2d3a4e48defe14889dec4547a5425bc35ef8360b
1,618
py
Python
scripts/delete_duplicate_tags.py
lokal-profil/isfdb_site
0ce20d6347849926d4eda961ea9249c31519eea5
[ "BSD-3-Clause" ]
null
null
null
scripts/delete_duplicate_tags.py
lokal-profil/isfdb_site
0ce20d6347849926d4eda961ea9249c31519eea5
[ "BSD-3-Clause" ]
null
null
null
scripts/delete_duplicate_tags.py
lokal-profil/isfdb_site
0ce20d6347849926d4eda961ea9249c31519eea5
[ "BSD-3-Clause" ]
null
null
null
#!_PYTHONLOC # # (C) COPYRIGHT 2014 Ahasuerus # ALL RIGHTS RESERVED # # The copyright notice above does not evidence any actual or # intended publication of such source code. # # Version: $Revision$ # Date: $Date$ import cgi import sys import os import string import MySQLdb if __name__ =...
28.892857
138
0.633498
#!_PYTHONLOC # # (C) COPYRIGHT 2014 Ahasuerus # ALL RIGHTS RESERVED # # The copyright notice above does not evidence any actual or # intended publication of such source code. # # Version: $Revision$ # Date: $Date$ import cgi import sys import os import string import MySQLdb from localdefs ...
0
0
0
0
0
160
0
2
68
6ad791046708ce8b4b90ae8c899b17e57d7654a3
9,745
py
Python
pyod/models/combination.py
marchezinixd/pyod
3c2de3237245e682fe0c9c1ae6a987d4d238cced
[ "BSD-2-Clause" ]
1
2021-07-14T08:23:40.000Z
2021-07-14T08:23:40.000Z
pyod/models/combination.py
vgarcialeandro/pyod
03ec97cb95f9a20a39807e7e5983d35b0cd46d31
[ "BSD-2-Clause" ]
null
null
null
pyod/models/combination.py
vgarcialeandro/pyod
03ec97cb95f9a20a39807e7e5983d35b0cd46d31
[ "BSD-2-Clause" ]
null
null
null
# -*- coding: utf-8 -*- """A collection of model combination functionalities. """ # Author: Yue Zhao <zhaoy@cmu.edu> # License: BSD 2 clause from __future__ import division from __future__ import print_function import numpy as np from numpy.random import RandomState from sklearn.utils import check_array # noinspectio...
36.36194
78
0.636018
# -*- coding: utf-8 -*- """A collection of model combination functionalities. """ # Author: Yue Zhao <zhaoy@cmu.edu> # License: BSD 2 clause from __future__ import division from __future__ import print_function import numpy as np from numpy.random import RandomState from sklearn.utils import check_array from sklearn....
0
0
0
0
0
0
0
42
44
6799b6115ad4101e894be13612541c18fac3a3c0
228
py
Python
driver.py
anishLearnsToCode/DES
193e0b59d355b1f5a030e362d704db1199643367
[ "MIT" ]
3
2020-08-27T11:01:54.000Z
2021-08-05T16:47:43.000Z
driver.py
anishLearnsToCode/DES
193e0b59d355b1f5a030e362d704db1199643367
[ "MIT" ]
null
null
null
driver.py
anishLearnsToCode/DES
193e0b59d355b1f5a030e362d704db1199643367
[ "MIT" ]
1
2020-11-01T00:43:13.000Z
2020-11-01T00:43:13.000Z
from des import DES des = DES(key=193) number = 123456 ciphertext = des.encrypt_number(number) decrypted = des.decrypt_number(ciphertext) print('Number:', number) print('Encrypted:', ciphertext) print('Decrypyed', decrypted)
19
42
0.758772
from des import DES des = DES(key=193) number = 123456 ciphertext = des.encrypt_number(number) decrypted = des.decrypt_number(ciphertext) print('Number:', number) print('Encrypted:', ciphertext) print('Decrypyed', decrypted)
0
0
0
0
0
0
0
0
0
78af9b37381badff33d7d5ddb89277c199570422
1,505
py
Python
utils/upperbound.py
atharva-diwan/PolyLaneNet
ec58d1d5207e78233e25dd501a58ce535a82cd1e
[ "MIT" ]
540
2020-11-10T11:09:00.000Z
2022-03-30T01:49:33.000Z
utils/upperbound.py
chisyliu/PolyLaneNet
c89500428ddd72e7c3027955d88fd074603f48e0
[ "MIT" ]
83
2020-11-14T17:43:34.000Z
2022-03-22T08:49:23.000Z
utils/upperbound.py
chisyliu/PolyLaneNet
c89500428ddd72e7c3027955d88fd074603f48e0
[ "MIT" ]
122
2020-11-12T01:29:12.000Z
2022-03-23T09:50:50.000Z
import sys import warnings import numpy as np from lib.config import Config warnings.simplefilter('ignore', np.RankWarning) if __name__ == "__main__": cfg = Config(sys.argv[1] if len(sys.argv) > 1 else 'config.yaml') dataset = cfg.get_dataset('test') for n in range(1, 5 + 1): result = polyfit_...
33.444444
83
0.572093
import sys import warnings import numpy as np from progressbar import progressbar from lib.config import Config from utils.evaluator import Evaluator warnings.simplefilter('ignore', np.RankWarning) def polyfit_upperbound(dataset, degree): evaluator = Evaluator(dataset, '/tmp', degree) print('Predicting wit...
0
0
0
0
0
761
0
30
67
d9f21745b42cce43949cdd8e3409093c49f6d8af
1,697
py
Python
setup.py
cedadev/django-jdma_control
9223aa2f8773e78c6f78197ae89289452d1285c9
[ "BSD-3-Clause" ]
null
null
null
setup.py
cedadev/django-jdma_control
9223aa2f8773e78c6f78197ae89289452d1285c9
[ "BSD-3-Clause" ]
23
2018-03-21T14:36:24.000Z
2020-04-17T07:58:33.000Z
setup.py
cedadev/django-jdma_control
9223aa2f8773e78c6f78197ae89289452d1285c9
[ "BSD-3-Clause" ]
null
null
null
import os from setuptools import setup with open(os.path.join(os.path.dirname(__file__), 'README.md')) as readme: README = readme.read() # allow setup.py to be run from any path os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir))) setup( name='jdma_control', version='0.2.27', ...
30.854545
78
0.595168
import os from setuptools import setup with open(os.path.join(os.path.dirname(__file__), 'README.md')) as readme: README = readme.read() # allow setup.py to be run from any path os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir))) setup( name='jdma_control', version='0.2.27', ...
0
0
0
0
0
0
0
0
0
97654bd538b29c3e1298416c0179a5829ea902ae
1,097
py
Python
build_ECMWF_cca_scratch_catalogue.py
AJueling/EC-Earth3-data
26363e059bd7e9117dcf4fcd30f60fae7008573f
[ "Unlicense" ]
null
null
null
build_ECMWF_cca_scratch_catalogue.py
AJueling/EC-Earth3-data
26363e059bd7e9117dcf4fcd30f60fae7008573f
[ "Unlicense" ]
null
null
null
build_ECMWF_cca_scratch_catalogue.py
AJueling/EC-Earth3-data
26363e059bd7e9117dcf4fcd30f60fae7008573f
[ "Unlicense" ]
null
null
null
import os import csv from tqdm.autonotebook import tqdm csv_file = open("ecmwf_cca_scratch.csv", "w") writer = csv.writer(csv_file) writer.writerow(['mip_era','activity_id','institution_id','source_id','experiment_id','member_id','table_id','variable_id','grid_label','version','dcpp_start_year','time_range','nc_path']...
45.708333
188
0.701003
import os import csv from tqdm.autonotebook import tqdm csv_file = open("ecmwf_cca_scratch.csv", "w") writer = csv.writer(csv_file) writer.writerow(['mip_era','activity_id','institution_id','source_id','experiment_id','member_id','table_id','variable_id','grid_label','version','dcpp_start_year','time_range','nc_path']...
0
0
0
0
0
0
0
0
0
c1ac39e50ebf00d5aed5ccd4b062788c2e2b5e48
1,838
py
Python
python/python-algorithm-intervew/14-Tree/review/44-longest-univalue-path-review.py
bum12ark/algorithm
b6e262b0c29a8b5fb551db5a177a40feebc411b4
[ "MIT" ]
1
2022-03-06T03:49:31.000Z
2022-03-06T03:49:31.000Z
python/python-algorithm-intervew/14-Tree/review/44-longest-univalue-path-review.py
bum12ark/algorithm
b6e262b0c29a8b5fb551db5a177a40feebc411b4
[ "MIT" ]
null
null
null
python/python-algorithm-intervew/14-Tree/review/44-longest-univalue-path-review.py
bum12ark/algorithm
b6e262b0c29a8b5fb551db5a177a40feebc411b4
[ "MIT" ]
null
null
null
""" url: https://leetcode.com/problems/longest-univalue-path/ * . - Example 1 Input : 5 / \ 4 5 / \ \ 1 1 5 Output : 2 Explaination : 5->5->5 2. - Example 2 Input : 1 / \ 4 5 / \ \ 4 4 5 Output : 2 Explain...
20.651685
94
0.495103
""" url: https://leetcode.com/problems/longest-univalue-path/ * 가장 긴 동일 값의 경로 동일한 값을 지닌 가장 긴 경로를 찾아라. - Example 1 Input : 5 / \ 4 5 / \ \ 1 1 5 Output : 2 Explaination : 루트에서 오른쪽 노드 끝까지 5->5->5로 가장 긴 이동 거리가 2이다. - Example 2 Input : 1 / \ 4 5 ...
561
0
0
780
0
0
0
0
45
f3fa924397d5ab69738e473e7a0009efe14f6f77
577
py
Python
setup.py
connor9/python-draytonwiser-api
db90222eda0c5e8b4920396961da8edc815fd920
[ "MIT" ]
7
2019-04-24T08:45:09.000Z
2021-11-26T19:43:59.000Z
setup.py
connor9/python-draytonwiser-api
db90222eda0c5e8b4920396961da8edc815fd920
[ "MIT" ]
1
2019-03-02T22:26:47.000Z
2019-03-02T22:26:47.000Z
setup.py
connor9/python-draytonwiser-api
db90222eda0c5e8b4920396961da8edc815fd920
[ "MIT" ]
1
2021-01-07T21:35:46.000Z
2021-01-07T21:35:46.000Z
#!/usr/bin/env python import os import sys try: from setuptools import setup except ImportError: from distutils.core import setup if sys.argv[-1] == 'publish': os.system('python setup.py sdist upload') sys.exit() version = '1.0.0' setup(name='python-draytonwiser-api', version=version, d...
22.192308
93
0.651646
#!/usr/bin/env python import os import sys try: from setuptools import setup except ImportError: from distutils.core import setup if sys.argv[-1] == 'publish': os.system('python setup.py sdist upload') sys.exit() version = '1.0.0' setup(name='python-draytonwiser-api', version=version, d...
0
0
0
0
0
0
0
0
0
c3391de09389f23314f6f47dc595a5004b17213d
1,167
py
Python
setup.py
ericmbell1/flowsa
d251301864289a4de42dda118c9c6da41bcf4cf0
[ "CC0-1.0" ]
null
null
null
setup.py
ericmbell1/flowsa
d251301864289a4de42dda118c9c6da41bcf4cf0
[ "CC0-1.0" ]
null
null
null
setup.py
ericmbell1/flowsa
d251301864289a4de42dda118c9c6da41bcf4cf0
[ "CC0-1.0" ]
null
null
null
from setuptools import setup setup( name='flowsa', version='0.0.1', packages=['flowsa'], package_dir={'flowsa': 'flowsa'}, package_data={'flowsa': [ "data/*.*", "output/*.*"]}, include_package_data=True, install_requires=[ 'fedelemflowlist @ git+https://github.com/USEPA/Fede...
29.923077
128
0.569837
from setuptools import setup setup( name='flowsa', version='0.0.1', packages=['flowsa'], package_dir={'flowsa': 'flowsa'}, package_data={'flowsa': [ "data/*.*", "output/*.*"]}, include_package_data=True, install_requires=[ 'fedelemflowlist @ git+https://github.com/USEPA/Fede...
0
0
0
0
0
0
0
0
0
4aef9a3d475f82ce4715b6a324d21777ae94670d
2,102
py
Python
kpages/consistenthash.py
leicj/kpages
60a46af26b50b3de8678ec8532b0212c43b58374
[ "MIT" ]
9
2015-01-14T08:53:06.000Z
2018-05-29T07:08:23.000Z
kpages/consistenthash.py
leicj/kpages
60a46af26b50b3de8678ec8532b0212c43b58374
[ "MIT" ]
2
2015-06-02T05:48:48.000Z
2015-06-02T05:48:48.000Z
kpages/consistenthash.py
leicj/kpages
60a46af26b50b3de8678ec8532b0212c43b58374
[ "MIT" ]
4
2015-01-14T08:53:06.000Z
2022-02-21T12:35:14.000Z
# -*- coding:utf-8 -*- """ author comger@gmail.com Consisten hash """ if __name__ == '__main__': ''' loop = 100000 hosts = ["192.168.1.%d" % i for i in xrange(1, 10)] ch = ConsistentHash(hosts,replicas=100) rnd_key = lambda: "".join(sample(letters, 10)) count = {} ...
25.325301
74
0.556137
# -*- coding:utf-8 -*- """ author comger@gmail.com Consisten hash """ from hashlib import md5 from bisect import bisect_right class ConsistentHash(object): """ 算法思路: 1. 在N个机器中、每台M个节点、N*M 个节点形成节点环 2. 计算每个机器拥有的节点Node 3. 新内容key添加时,get_node(key)获取key被分配的node;及get_host(key)获取key 被分配到的机器 ...
222
0
0
1,066
0
0
0
21
119
69141d14f670c53a6708e678c426971f37b401ee
1,824
py
Python
python/2020_18_2.py
wensby/advent-of-code
50cd7fa2d35674d868a79ac8c75be24a43267e2b
[ "MIT" ]
null
null
null
python/2020_18_2.py
wensby/advent-of-code
50cd7fa2d35674d868a79ac8c75be24a43267e2b
[ "MIT" ]
null
null
null
python/2020_18_2.py
wensby/advent-of-code
50cd7fa2d35674d868a79ac8c75be24a43267e2b
[ "MIT" ]
null
null
null
import sys import operator func_by_op = { '*': operator.mul, '+': operator.add } if __name__ == '__main__': print(solve(sys.stdin.read()))
24.986301
75
0.577851
import sys import operator func_by_op = { '*': operator.mul, '+': operator.add } def solve(input): return sum(evaluate(l) for l in input.splitlines()) def evaluate(expression): expression = expression.replace(' ', '') if expression.isnumeric(): return int(expression) parts = get_parts(expression) i...
0
0
0
0
0
1,608
0
0
69
614963d88fcca991bc59d21e5afd5ad6b1ff43b6
3,490
py
Python
lib/python2.7/site-packages/leginon/gridentry.py
leschzinerlab/myami-3.2-freeHand
974b8a48245222de0d9cfb0f433533487ecce60d
[ "MIT" ]
null
null
null
lib/python2.7/site-packages/leginon/gridentry.py
leschzinerlab/myami-3.2-freeHand
974b8a48245222de0d9cfb0f433533487ecce60d
[ "MIT" ]
null
null
null
lib/python2.7/site-packages/leginon/gridentry.py
leschzinerlab/myami-3.2-freeHand
974b8a48245222de0d9cfb0f433533487ecce60d
[ "MIT" ]
1
2019-09-05T20:58:37.000Z
2019-09-05T20:58:37.000Z
# # COPYRIGHT: # The Leginon software is Copyright 2003 # The Scripps Research Institute, La Jolla, CA # For terms of the license agreement # see http://ami.scripps.edu/software/leginon-license #
30.614035
79
0.729513
# # COPYRIGHT: # The Leginon software is Copyright 2003 # The Scripps Research Institute, La Jolla, CA # For terms of the license agreement # see http://ami.scripps.edu/software/leginon-license # from leginon import leginondata import event import threading import node import project import gu...
0
0
0
3,132
0
0
0
-19
156
6853cb88362b98fa5dd8b1c33bab2fb618f22e13
5,047
py
Python
tofnet/pointcloud/metrics.py
victorjoos/tof2net
068f5f08a241dbfb950251bea52fd9379466bf2f
[ "MIT" ]
null
null
null
tofnet/pointcloud/metrics.py
victorjoos/tof2net
068f5f08a241dbfb950251bea52fd9379466bf2f
[ "MIT" ]
8
2021-02-02T23:07:37.000Z
2022-03-12T00:51:26.000Z
tofnet/pointcloud/metrics.py
victorjoos/tof2net
068f5f08a241dbfb950251bea52fd9379466bf2f
[ "MIT" ]
2
2020-10-01T08:23:24.000Z
2020-11-09T22:01:47.000Z
import numpy as np from numpy.linalg import norm from copy import deepcopy from tofnet.pointcloud.utils import rotate, transform_with_conf from tofnet.annotations.segmentation import find_segmentation, find_z def floor_similarity(ground_cfg, pred_cfg, eps=1.e-8): """Uses cosine similarity to compare camera config...
36.309353
127
0.640182
import numpy as np from numpy.linalg import norm from shapely.geometry import Polygon from copy import deepcopy import open3d from tofnet.pointcloud.utils import rotate, transform_with_conf from tofnet.pointcloud.visualize import visualize_pointcloud from tofnet.annotations.segmentation import find_segmentation, find_...
0
0
0
0
0
430
0
46
112
60e04fb4bf1ebf7c0f1ee24522888df26eb7dc5e
7,189
py
Python
amy/trainings/views.py
gaybro8777/amy
3cf99aed58a0f0acf83d2645a30d8408208ccea9
[ "MIT" ]
null
null
null
amy/trainings/views.py
gaybro8777/amy
3cf99aed58a0f0acf83d2645a30d8408208ccea9
[ "MIT" ]
null
null
null
amy/trainings/views.py
gaybro8777/amy
3cf99aed58a0f0acf83d2645a30d8408208ccea9
[ "MIT" ]
null
null
null
# ------------------------------------------------------------ # Instructor Training related views
35.068293
92
0.58826
from django.contrib import messages from django.db.models import ( Case, When, IntegerField, Count, F, Sum, Prefetch, ) from django.shortcuts import render, redirect from django.urls import reverse_lazy from trainings.filters import ( TraineeFilter, ) from trainings.forms import ( T...
0
3,051
0
1,800
0
1,294
0
601
337
cda9f963cddac6e0d22909129a807ae43e6470aa
2,865
py
Python
rubin_sim/maf/mafContrib/GW170817DetMetric.py
RileyWClarke/flarubin
eb7b1ee21c828523f8a5374fe4510fe6e5ec2a2a
[ "MIT" ]
null
null
null
rubin_sim/maf/mafContrib/GW170817DetMetric.py
RileyWClarke/flarubin
eb7b1ee21c828523f8a5374fe4510fe6e5ec2a2a
[ "MIT" ]
null
null
null
rubin_sim/maf/mafContrib/GW170817DetMetric.py
RileyWClarke/flarubin
eb7b1ee21c828523f8a5374fe4510fe6e5ec2a2a
[ "MIT" ]
null
null
null
# Metric for kilonova detectability based on GW170817 SED used in Scolnic et # al. 2018 and Setzer et al. 2019. The chosen detection criteria are related to # those used in the LSST DESC white paper detectability work and the two # references above. # # Contact for this code: # christian.setzer@fysik.su.se from pathlib...
38.716216
79
0.683421
# Metric for kilonova detectability based on GW170817 SED used in Scolnic et # al. 2018 and Setzer et al. 2019. The chosen detection criteria are related to # those used in the LSST DESC white paper detectability work and the two # references above. # # Contact for this code: # christian.setzer@fysik.su.se from pathlib...
0
0
0
2,380
0
0
0
39
45
d7a14ba5f0d62e4479705ffce4dcbd1fd8888727
1,622
py
Python
lib/Config.py
Ch4p34uN0iR/CVE-Scan
d75c8deea53c7c2befd19b66a7f2484201f5f8b6
[ "BSD-4-Clause" ]
246
2015-01-31T16:21:40.000Z
2022-03-23T06:58:06.000Z
lib/Config.py
Ch4p34uN0iR/CVE-Scan
d75c8deea53c7c2befd19b66a7f2484201f5f8b6
[ "BSD-4-Clause" ]
18
2015-02-11T22:24:29.000Z
2022-01-26T22:43:32.000Z
lib/Config.py
tracid56/CVE-Scan
cf919a67b156fef057835cdde0951e527c486a62
[ "BSD-4-Clause" ]
71
2015-02-09T04:07:04.000Z
2022-02-18T13:21:24.000Z
#!/usr/bin/env python3.3 # -*- coding: utf-8 -*- # # Read configuration file or return default values # # Copyright (c) 2015 NorthernSec # Copyright (c) 2015 Pieter-Jan Moreels # This software is licensed under the Original BSD License # Imports import os runpath=os.path.dirname(os.path.realpath(__file__))
27.491525
70
0.667078
#!/usr/bin/env python3.3 # -*- coding: utf-8 -*- # # Read configuration file or return default values # # Copyright (c) 2015 NorthernSec # Copyright (c) 2015 Pieter-Jan Moreels # This software is licensed under the Original BSD License # Imports import os runpath=os.path.dirname(os.path.realpath(__file__)) import con...
0
815
0
454
0
0
0
-2
46
7c5fed6d7a6a960b0030228d0eb5efb838ef3880
559
py
Python
misc/test.py
gingerkirsch/playing-with-python
5c958b22e13207e65bcaa94a982d71e2fe024e22
[ "MIT" ]
null
null
null
misc/test.py
gingerkirsch/playing-with-python
5c958b22e13207e65bcaa94a982d71e2fe024e22
[ "MIT" ]
null
null
null
misc/test.py
gingerkirsch/playing-with-python
5c958b22e13207e65bcaa94a982d71e2fe024e22
[ "MIT" ]
null
null
null
n = 1000 a = list(range(n)) b = dict.fromkeys(range(n)) n = 10 items = range(n) o_one(items) # 1 operation o_n(items) # n operations o_n_squared(items) # n*n = 10 * 10 = 100 operations
19.275862
51
0.595707
n = 1000 a = list(range(n)) b = dict.fromkeys(range(n)) def o_one(items): return 1 # 1 operation so O(1) def o_n(items): total = 0 # Walks through all items once so O(n) for item in items: total += item return total def o_n_squared(items): total = 0 # Walks through all items n...
0
0
0
0
0
300
0
0
72
7449c8ca85a461ad90c59c85503c862e83ebb9ba
2,173
py
Python
lib/rapidsms/tests/test_router.py
dimagi/rapidsms-core-dev
aed753545ae01c279489f5a00e7f12ec432e11bf
[ "BSD-3-Clause" ]
null
null
null
lib/rapidsms/tests/test_router.py
dimagi/rapidsms-core-dev
aed753545ae01c279489f5a00e7f12ec432e11bf
[ "BSD-3-Clause" ]
null
null
null
lib/rapidsms/tests/test_router.py
dimagi/rapidsms-core-dev
aed753545ae01c279489f5a00e7f12ec432e11bf
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python # vim: ai ts=4 sts=4 et sw=4
26.5
73
0.680166
#!/usr/bin/env python # vim: ai ts=4 sts=4 et sw=4 import time import threading from nose.tools import assert_equals, assert_raises from ..backends.base import BackendBase from ..apps.base import AppBase from ..router import Router def test_router_finds_apps(): router = Router() router.add_app("rapidsms.con...
0
0
0
311
0
1,532
0
49
225
e7ad85de2ac83380c9e2a40ebc5a66951c7e0ca4
1,927
py
Python
ioping/ioping.py
annttu/Diamond-collectors
9abe896f5702418136d609f907270b1efa26c491
[ "MIT", "Unlicense" ]
null
null
null
ioping/ioping.py
annttu/Diamond-collectors
9abe896f5702418136d609f907270b1efa26c491
[ "MIT", "Unlicense" ]
1
2016-11-01T13:43:11.000Z
2016-11-02T06:50:01.000Z
ioping/ioping.py
annttu/Diamond-collectors
9abe896f5702418136d609f907270b1efa26c491
[ "MIT", "Unlicense" ]
null
null
null
""" IOPing plugin for Diamond. Author: Antti Jaakkola #### Dependencies * ioping Create /usr/share/diamond/collectors/ioping directory and copy this plugin to it. mkdir /usr/share/diamond/collectors/ioping cp ioping/ioping.py /usr/share/diamond/collectors/ioping/ Create config file /etc/diamond/collectors/IOPi...
26.040541
89
0.585885
""" IOPing plugin for Diamond. Author: Antti Jaakkola #### Dependencies * ioping Create /usr/share/diamond/collectors/ioping directory and copy this plugin to it. mkdir /usr/share/diamond/collectors/ioping cp ioping/ioping.py /usr/share/diamond/collectors/ioping/ Create config file /etc/diamond/collectors/IOPi...
0
0
0
1,477
0
0
0
-1
68
fbb1ede1e97a9d60cbdc658c4844084f3866d59b
1,948
py
Python
gfsa/datasets/mazes/maze_task.py
muell-monster/google-research
04d2024f4723bc4be3d639a668c19fb1f6a31478
[ "Apache-2.0" ]
3
2021-01-18T04:46:49.000Z
2021-03-05T09:21:40.000Z
gfsa/datasets/mazes/maze_task.py
Alfaxad/google-research
2c0043ecd507e75e2df9973a3015daf9253e1467
[ "Apache-2.0" ]
7
2021-11-10T19:44:38.000Z
2022-02-10T06:48:39.000Z
gfsa/datasets/mazes/maze_task.py
Alfaxad/google-research
2c0043ecd507e75e2df9973a3015daf9253e1467
[ "Apache-2.0" ]
4
2021-02-08T10:25:45.000Z
2021-04-17T14:46:26.000Z
# coding=utf-8 # Copyright 2020 The Google Research 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 applicab...
29.969231
74
0.754107
# coding=utf-8 # Copyright 2020 The Google Research 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 applicab...
0
0
0
0
0
0
0
9
23
6279ab1a4ff19e5eafe90e482015ee5b59aa4654
1,252
py
Python
spotfinder/applications/image_viewer.py
dperl-sol/cctbx_project
b9e390221a2bc4fd00b9122e97c3b79c632c6664
[ "BSD-3-Clause-LBNL" ]
155
2016-11-23T12:52:16.000Z
2022-03-31T15:35:44.000Z
spotfinder/applications/image_viewer.py
dperl-sol/cctbx_project
b9e390221a2bc4fd00b9122e97c3b79c632c6664
[ "BSD-3-Clause-LBNL" ]
590
2016-12-10T11:31:18.000Z
2022-03-30T23:10:09.000Z
spotfinder/applications/image_viewer.py
dperl-sol/cctbx_project
b9e390221a2bc4fd00b9122e97c3b79c632c6664
[ "BSD-3-Clause-LBNL" ]
115
2016-11-15T08:17:28.000Z
2022-02-09T15:30:14.000Z
from __future__ import absolute_import, division, print_function "Later go back and refactor this module and signal_strength to avoid code duplication."
37.939394
92
0.729233
from __future__ import absolute_import, division, print_function from spotfinder.applications.wrappers import DistlOrganizer class Empty: pass "Later go back and refactor this module and signal_strength to avoid code duplication." class run_signal_strength_class(DistlOrganizer): def __init__(self,params): E = ...
0
0
0
993
0
0
0
38
67
c4adb1ab10a5473e3829d2a1d242f1a18f0f49f3
3,608
py
Python
predict/predictions.py
JohanObluda/ntua-slp-semeval2018
c9c3ad2c05b4b4ea849dee0db13c3f02b52929b6
[ "MIT" ]
84
2018-05-25T08:26:38.000Z
2021-12-23T06:15:08.000Z
predict/predictions.py
JohanObluda/ntua-slp-semeval2018
c9c3ad2c05b4b4ea849dee0db13c3f02b52929b6
[ "MIT" ]
16
2018-06-06T15:09:45.000Z
2022-01-15T09:17:14.000Z
predict/predictions.py
JohanObluda/ntua-slp-semeval2018
c9c3ad2c05b4b4ea849dee0db13c3f02b52929b6
[ "MIT" ]
33
2018-06-05T18:13:29.000Z
2022-02-04T00:54:12.000Z
from torch.utils.data import DataLoader from config import DEVICE from logger.training import predict from modules.nn.dataloading import WordDataset, CharDataset from utils.nlp import twitter_preprocess from utils.train import load_embeddings, get_pipeline def predictions(task, model, config, data, label_transforme...
34.361905
79
0.509978
import json import os import numpy from torch.utils.data import DataLoader from config import DEVICE, ATT_PATH from logger.training import predict from modules.nn.dataloading import WordDataset, CharDataset from utils.nlp import twitter_preprocess from utils.train import load_embeddings, get_pipeline def dump_atten...
0
0
0
0
0
1,341
0
-21
90
2cd61fe31658cc3071428c898c6644d5725bf290
18,647
py
Python
src/models/cifar.py
kirk86/bdlood
227aaf08585e467415c32235805c8fd17e7484ee
[ "MIT" ]
1
2021-08-30T23:51:02.000Z
2021-08-30T23:51:02.000Z
src/models/cifar.py
kirk86/bdlood
227aaf08585e467415c32235805c8fd17e7484ee
[ "MIT" ]
null
null
null
src/models/cifar.py
kirk86/bdlood
227aaf08585e467415c32235805c8fd17e7484ee
[ "MIT" ]
null
null
null
import torch.nn as nn """ modified to fit dataset size """ # test()
37.071571
106
0.561055
import math import torch import torch.nn as nn import torch.nn.functional as F """ modified to fit dataset size """ class ResNeXtBottleneck(nn.Module): """ RexNeXt bottleneck type C (https://github.com/facebookresearch/ResNeXt/blob/master/models/resnext.lua) """ def __init__(self, in_channels, out...
0
0
0
17,111
0
928
0
-9
526
147be1c987270e7071f33f0664b66e49c7c1a99d
3,460
py
Python
offline/channel.py
wrh-dev/conda-offline
9f6088b1d14d90caf74a170e8448ca7c982a67ef
[ "MIT" ]
null
null
null
offline/channel.py
wrh-dev/conda-offline
9f6088b1d14d90caf74a170e8448ca7c982a67ef
[ "MIT" ]
null
null
null
offline/channel.py
wrh-dev/conda-offline
9f6088b1d14d90caf74a170e8448ca7c982a67ef
[ "MIT" ]
null
null
null
import logging logging.getLogger(__name__).addHandler(logging.NullHandler()) if __name__ == '__main__': _main_cmdline()
37.204301
99
0.69711
import argparse import logging import os import platform import shutil import subprocess logging.getLogger(__name__).addHandler(logging.NullHandler()) def iter_package_dir(path: str): for filename in os.listdir(path): if filename.endswith('.tar.bz2'): yield filename def copy_and_index_file...
0
0
0
0
118
2,996
0
-36
248