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
0414f49b201a169a4310448215ca028b77ddbe20
4,017
py
Python
preprocessing/stationarity.py
kbrezinski/complexity
2077825c8ec64df03dfb9f791b7578d64cb35567
[ "MIT" ]
null
null
null
preprocessing/stationarity.py
kbrezinski/complexity
2077825c8ec64df03dfb9f791b7578d64cb35567
[ "MIT" ]
null
null
null
preprocessing/stationarity.py
kbrezinski/complexity
2077825c8ec64df03dfb9f791b7578d64cb35567
[ "MIT" ]
null
null
null
def determine_interval(intervals,df,labels): """ @Author: Kenneth Brezinski, Department of Electrical and Computer Engineering args: df: pandas dataframe containing your time series intervals: how many subintervals will be returned labels: a (2,1) list containing the strings of you...
26.084416
106
0.566592
from statsmodels.tsa.stattools import adfuller,kpss import warnings def fuller_test(interval,y): ## Diadic: 2 or Triadic: 3 shopping cond = False result = adfuller(y) if result[4]['5%'] > result[0]: print('Stationary interval found at frame size equal to epoch') cond = True f...
0
0
0
0
0
2,920
0
24
114
84f3f9c8916a8b8e43e44b2871b160f4c105be8b
229
py
Python
test/ndds2coco/gen_measure_video.py
HienDT27/annotation_utils
1f4e95f4cfa08de5bbab20f90a6a75fba66a69b9
[ "MIT" ]
13
2020-01-28T04:45:22.000Z
2022-03-10T03:35:49.000Z
test/ndds2coco/gen_measure_video.py
HienDT27/annotation_utils
1f4e95f4cfa08de5bbab20f90a6a75fba66a69b9
[ "MIT" ]
4
2020-02-14T08:56:03.000Z
2021-05-21T10:38:30.000Z
test/ndds2coco/gen_measure_video.py
HienDT27/annotation_utils
1f4e95f4cfa08de5bbab20f90a6a75fba66a69b9
[ "MIT" ]
7
2020-04-10T07:56:25.000Z
2021-12-17T11:19:23.000Z
from annotation_utils.coco.structs import COCO_Dataset dataset = COCO_Dataset.load_from_path('measure_coco/measure/output.json') dataset.save_video( save_path='merged_mask_measure_viz.mp4', show_details=True, fps=3 )
28.625
73
0.799127
from annotation_utils.coco.structs import COCO_Dataset dataset = COCO_Dataset.load_from_path('measure_coco/measure/output.json') dataset.save_video( save_path='merged_mask_measure_viz.mp4', show_details=True, fps=3 )
0
0
0
0
0
0
0
0
0
edc22c0a09a19a1b803f3775127300f30edcdb08
6,218
py
Python
tests/test_hgvs_validator.py
jmuhlich/hgvs
26aba8877791b0f94f1e14a5a49c60bcdaf2e6fd
[ "Apache-2.0" ]
null
null
null
tests/test_hgvs_validator.py
jmuhlich/hgvs
26aba8877791b0f94f1e14a5a49c60bcdaf2e6fd
[ "Apache-2.0" ]
null
null
null
tests/test_hgvs_validator.py
jmuhlich/hgvs
26aba8877791b0f94f1e14a5a49c60bcdaf2e6fd
[ "Apache-2.0" ]
3
2016-08-08T03:04:37.000Z
2020-01-16T08:56:16.000Z
# -*- coding: utf-8 -*- from __future__ import absolute_import, division, print_function, unicode_literals import unittest import hgvs.dataproviders.uta import hgvs.variantmapper import hgvs.parser import hgvs.validator db_dir = ['tests/data/sample_data'] hdp = hgvs.dataproviders.uta.connect() if __name__ == '__...
49.349206
134
0.741396
# -*- coding: utf-8 -*- from __future__ import absolute_import, division, print_function, unicode_literals import unittest from nose.plugins.attrib import attr from hgvs.exceptions import HGVSValidationError import hgvs.dataproviders.uta import hgvs.variantmapper import hgvs.parser import hgvs.validator db_dir = ['...
0
4,657
0
400
0
0
0
41
115
c26cbe03b112f329b82be2d9927dce7d09567cc3
2,128
py
Python
f0027/f0027.py
soda-lab/Features
1d94c0f6343d36d9e5b1e150311e4e7ccdf0b7d9
[ "Unlicense" ]
null
null
null
f0027/f0027.py
soda-lab/Features
1d94c0f6343d36d9e5b1e150311e4e7ccdf0b7d9
[ "Unlicense" ]
1
2019-05-05T03:45:14.000Z
2019-05-09T05:04:00.000Z
f0027/f0027.py
soda-lab/Features
1d94c0f6343d36d9e5b1e150311e4e7ccdf0b7d9
[ "Unlicense" ]
null
null
null
# This is necessary for the processing to work ### Otherwise get "algorithm not found" error from qgis.analysis import QgsNativeAlgorithms import sys QgsApplication.setPrefixPath("/usr",True) # Starts the application, with False to not launch the GUI app = QgsApplication([], False) app.initQgis() sys...
32.242424
170
0.711936
from qgis.core import * from PyQt5.QtCore import * # This is necessary for the processing to work ### Otherwise get "algorithm not found" error from qgis.analysis import QgsNativeAlgorithms import sys import os QgsApplication.setPrefixPath("/usr",True) # Starts the application, with False to not launch t...
0
0
0
0
0
0
0
-5
69
fb74f0052b38b91d8368a5c21622053443eb043c
468
py
Python
modules/vtk_basic/vtkTreeWriter.py
chrisidefix/devide
99bfe156e710fa47ba7ae88b0ce1eef592a3a439
[ "BSD-3-Clause" ]
25
2015-08-24T16:05:14.000Z
2020-12-09T20:07:14.000Z
modules/vtk_basic/vtkTreeWriter.py
chrisidefix/devide
99bfe156e710fa47ba7ae88b0ce1eef592a3a439
[ "BSD-3-Clause" ]
1
2016-02-16T21:18:10.000Z
2016-02-16T21:18:10.000Z
modules/vtk_basic/vtkTreeWriter.py
chrisidefix/devide
99bfe156e710fa47ba7ae88b0ce1eef592a3a439
[ "BSD-3-Clause" ]
5
2016-02-16T20:05:37.000Z
2020-01-31T11:27:39.000Z
# class generated by DeVIDE::createDeVIDEModuleFromVTKObject
36
63
0.702991
# class generated by DeVIDE::createDeVIDEModuleFromVTKObject from module_kits.vtk_kit.mixins import SimpleVTKClassModuleBase import vtk class vtkTreeWriter(SimpleVTKClassModuleBase): def __init__(self, module_manager): SimpleVTKClassModuleBase.__init__( self, module_manager, vtk.vtk...
0
0
0
309
0
0
0
31
67
5c910944525a5cbf2bade339ba76bbc12e13c434
2,014
py
Python
pipeline_diagnostics/list_patients_with_endpoints.py
ratschlab/circEWS
b2b1f00dac4f5d46856a2c7abe2ca4f12d4c612d
[ "MIT" ]
34
2020-03-17T16:42:00.000Z
2022-03-29T15:53:24.000Z
pipeline_diagnostics/list_patients_with_endpoints.py
ranxiao/circEWS
1e52880c268f8f763bbc16763131634ffc217153
[ "MIT" ]
3
2020-07-30T22:37:10.000Z
2021-08-10T00:02:30.000Z
pipeline_diagnostics/list_patients_with_endpoints.py
ranxiao/circEWS
1e52880c268f8f763bbc16763131634ffc217153
[ "MIT" ]
14
2020-04-22T01:13:54.000Z
2021-11-27T20:23:41.000Z
#!/usr/bin/env # author: stephanie hyland # make a list of PIDS with non-empty, non-all-unknown endpoint data import pandas as pd import paths def check_list(): """ slow but w/e """ pids_with_endpoints = open(paths.derived_dir + 'patients_with_endpoints_v6b.txt', 'r') pids_without_endpoints = ope...
44.755556
128
0.64995
#!/usr/bin/env # author: stephanie hyland # make a list of PIDS with non-empty, non-all-unknown endpoint data import pandas as pd import glob import ipdb import paths def compile_list(): pids_with_endpoints = open(paths.derived_dir + 'patients_with_endpoints_v6b.txt', 'w') pids_without_endpoints = open(paths...
0
0
0
0
0
874
0
-20
67
2a7ef850855b2c58139264d487c67301ef1b98a4
5,713
py
Python
django_cloud_deploy/tests/unit/cloudlib/project_test.py
wangxf123456/django-cloud-deploy
82c4d5094c44a59226a294bd585dce67cec877c5
[ "Apache-2.0" ]
1
2019-02-12T21:41:18.000Z
2019-02-12T21:41:18.000Z
django_cloud_deploy/tests/unit/cloudlib/project_test.py
DalavanCloud/django-cloud-deploy
ba81fc9698c57c0e23faccf25ad4480e3e416643
[ "Apache-2.0" ]
null
null
null
django_cloud_deploy/tests/unit/cloudlib/project_test.py
DalavanCloud/django-cloud-deploy
ba81fc9698c57c0e23faccf25ad4480e3e416643
[ "Apache-2.0" ]
null
null
null
# Copyright 2018 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 # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, soft...
36.621795
80
0.618064
# Copyright 2018 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 # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, soft...
0
1,286
0
3,484
0
0
0
96
227
d9ac38d2b951b9772b4e8a6d5b30a7c8a86fe00a
277
py
Python
Libraries/Python.framework/Versions/2.7/lib/python2.7/site-packages/Cython-0.22-py2.7-macosx-10.5-intel.egg/Cython/Compiler/Parsing.py
mlewis1973/pyosirix
77757744f250ea1e3be083f50dce70f7aa094c5d
[ "BSD-3-Clause" ]
20
2016-02-02T10:31:41.000Z
2021-11-08T08:35:25.000Z
Libraries/Python.framework/Versions/2.7/lib/python2.7/site-packages/Cython-0.22-py2.7-macosx-10.5-intel.egg/Cython/Compiler/Parsing.py
mlewis1973/pyosirix
77757744f250ea1e3be083f50dce70f7aa094c5d
[ "BSD-3-Clause" ]
7
2016-10-21T04:15:22.000Z
2020-02-15T04:06:19.000Z
Libraries/Python.framework/Versions/2.7/lib/python2.7/site-packages/Cython-0.22-py2.7-macosx-10.5-intel.egg/Cython/Compiler/Parsing.py
mlewis1973/pyosirix
77757744f250ea1e3be083f50dce70f7aa094c5d
[ "BSD-3-Clause" ]
9
2018-01-24T21:46:10.000Z
2022-03-08T09:42:42.000Z
__bootstrap__()
34.625
68
0.783394
def __bootstrap__(): global __bootstrap__, __loader__, __file__ import sys, pkg_resources, imp __file__ = pkg_resources.resource_filename(__name__,'Parsing.so') __loader__ = None; del __bootstrap__, __loader__ imp.load_dynamic(__name__,__file__) __bootstrap__()
0
0
0
0
0
239
0
0
22
a96c2651c4a1f0985f3702ac2a5074d6ad36c543
2,610
py
Python
research/cv/AlignedReID++/src/samplers.py
mindspore-ai/models
9127b128e2961fd698977e918861dadfad00a44c
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
research/cv/AlignedReID++/src/samplers.py
mindspore-ai/models
9127b128e2961fd698977e918861dadfad00a44c
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
research/cv/AlignedReID++/src/samplers.py
mindspore-ai/models
9127b128e2961fd698977e918861dadfad00a44c
[ "Apache-2.0" ]
24
2021-10-15T08:32:45.000Z
2022-03-24T18:45:20.000Z
"""construct the sampler""" # Copyright 2021 Huawei Technologies Co., Ltd # # 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...
37.285714
105
0.651724
"""construct the sampler""" # Copyright 2021 Huawei Technologies Co., Ltd # # 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...
0
0
0
1,765
0
0
0
20
90
194e6fbbe2adf5e01ca6675eab03687e6daff993
1,748
py
Python
model.py
Rahul-404/Handwritten-digit-recognition-MNIST
c20fca30c2cfc26e15c64b45e3065111e9c5b974
[ "MIT" ]
null
null
null
model.py
Rahul-404/Handwritten-digit-recognition-MNIST
c20fca30c2cfc26e15c64b45e3065111e9c5b974
[ "MIT" ]
null
null
null
model.py
Rahul-404/Handwritten-digit-recognition-MNIST
c20fca30c2cfc26e15c64b45e3065111e9c5b974
[ "MIT" ]
null
null
null
import keras from keras.datasets import mnist from keras.utils.np_utils import to_categorical from keras.models import Sequential from keras.layers import Dense, Dropout, Flatten from keras.layers import Conv2D, MaxPool2D # the datam split between train and test (X_train, y_train), (X_test, y_test) = mnist.load_data()...
32.37037
118
0.756865
import keras from keras.datasets import mnist from keras.utils.np_utils import to_categorical from keras.models import Sequential from keras.layers import Dense, Dropout, Flatten from keras.layers import Conv2D, MaxPool2D from keras import backend as K # the datam split between train and test (X_train, y_train), (X_te...
0
0
0
0
0
0
0
9
22
1c52441e909ea6338f7890e372f6689f12cc462d
856
py
Python
setup.py
FabricioSMarin/XRFtomo
f5c9f6411bea9a85082d943af873e83f81431e5a
[ "BSD-3-Clause" ]
null
null
null
setup.py
FabricioSMarin/XRFtomo
f5c9f6411bea9a85082d943af873e83f81431e5a
[ "BSD-3-Clause" ]
null
null
null
setup.py
FabricioSMarin/XRFtomo
f5c9f6411bea9a85082d943af873e83f81431e5a
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- from setuptools import setup, find_packages setup( name='xrftomo', author='Fabricio Marin, Chris Roehrig, Arthur Glowacki, Francesco De Carlo, Si Chen', packages=find_packages(), version=open('VERSION').read().strip(), description = 'Pre-processing too...
31.703704
89
0.608645
#!/usr/bin/env python # -*- coding: utf-8 -*- from setuptools import setup, find_packages setup( name='xrftomo', author='Fabricio Marin, Chris Roehrig, Arthur Glowacki, Francesco De Carlo, Si Chen', packages=find_packages(), version=open('VERSION').read().strip(), description = 'Pre-processing too...
0
0
0
0
0
0
0
0
0
641469b84a75d3d8fdfe422d2a46f28822affd09
11,799
py
Python
Lib/idlelib/idle_test/mock_tk.py
sireliah/polish-python
605df4944c2d3bc25f8bf6964b274c0a0d297cc3
[ "PSF-2.0" ]
1
2018-06-21T18:21:24.000Z
2018-06-21T18:21:24.000Z
Lib/idlelib/idle_test/mock_tk.py
sireliah/polish-python
605df4944c2d3bc25f8bf6964b274c0a0d297cc3
[ "PSF-2.0" ]
null
null
null
Lib/idlelib/idle_test/mock_tk.py
sireliah/polish-python
605df4944c2d3bc25f8bf6964b274c0a0d297cc3
[ "PSF-2.0" ]
null
null
null
"""Classes that replace tkinter gui objects used by an object being tested. A gui object jest anything przy a master albo parent parameter, which jest typically required w spite of what the doc strings say. """ klasa Event: '''Minimal mock przy attributes dla testing event handlers. This jest nie a gui objec...
39.461538
83
0.62251
"""Classes that replace tkinter gui objects used by an object being tested. A gui object jest anything przy a master albo parent parameter, which jest typically required w spite of what the doc strings say. """ klasa Event: '''Minimal mock przy attributes dla testing event handlers. This jest nie a gui objec...
138
0
0
0
0
1,432
0
0
157
a36cc579056371399883bb90df9a7f8742f78705
97
py
Python
wsgidav/addons/__init__.py
monash-merc/wsgidav
ba4aa2f64edfd3e3bb21958b56e18d5d92e3065c
[ "MIT" ]
null
null
null
wsgidav/addons/__init__.py
monash-merc/wsgidav
ba4aa2f64edfd3e3bb21958b56e18d5d92e3065c
[ "MIT" ]
null
null
null
wsgidav/addons/__init__.py
monash-merc/wsgidav
ba4aa2f64edfd3e3bb21958b56e18d5d92e3065c
[ "MIT" ]
null
null
null
#__all__ = ['nt_domain_controller', # 'simplemysqlabstractionlayer', # ]
24.25
43
0.556701
#__all__ = ['nt_domain_controller', # 'simplemysqlabstractionlayer', # ]
0
0
0
0
0
0
0
0
0
221894281469639c1b72dded984705ad5b3472e4
1,390
py
Python
gurklang/stdlib_modules/streams.py
decorator-factory/gurklang-pyimpl-interpreter
bd4275949c094d81a729da6a910b4bbecadaff0f
[ "MIT" ]
4
2020-12-24T21:24:55.000Z
2021-12-02T10:38:04.000Z
gurklang/stdlib_modules/streams.py
decorator-factory/gurklang-pyimpl-interpreter
bd4275949c094d81a729da6a910b4bbecadaff0f
[ "MIT" ]
17
2020-12-21T20:09:18.000Z
2021-12-01T23:24:45.000Z
gurklang/stdlib_modules/streams.py
decorator-factory/gurklang-pyimpl-interpreter
bd4275949c094d81a729da6a910b4bbecadaff0f
[ "MIT" ]
2
2020-12-20T17:23:25.000Z
2020-12-20T21:02:57.000Z
from typing import Tuple from ..builtin_utils import BuiltinModule from ..types import Value, Stack module = BuiltinModule("streams") T, V, S = Tuple, Value, Stack
28.367347
72
0.610791
from typing import List, Tuple from ..builtin_utils import BuiltinModule, Fail, make_simple from ..types import Value, Stack, Str, Atom, Vec module = BuiltinModule("streams") T, V, S = Tuple, Value, Stack def make_str_stream(s: str, i: int = 0): @make_simple() def __str_stream(stack: S, fail: Fail): ...
0
952
0
0
0
136
0
41
92
05046bb9b3ba7d82f4a8c732c14c23e96f21cd6c
7,637
py
Python
ddv_alts.py
bobeu/algorandescrow
1a3715a802f88ee8e491d6445bcf9a3c211ac0aa
[ "Apache-2.0" ]
null
null
null
ddv_alts.py
bobeu/algorandescrow
1a3715a802f88ee8e491d6445bcf9a3c211ac0aa
[ "Apache-2.0" ]
null
null
null
ddv_alts.py
bobeu/algorandescrow
1a3715a802f88ee8e491d6445bcf9a3c211ac0aa
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- from ddv_global import client, reply_keyboard, keyboard, pk_keyboard from ddv_waitforconfirmation import wait_for_confirmation from algosdk.future.transaction import AssetTransferTxn from telegram.inline.inlinekeyboardbutton import InlineKeyboardButton from telegram.inline...
36.023585
125
0.624722
#!/usr/bin/env python # -*- coding: utf-8 -*- from ddv_global import client, reply_keyboard, keyboard, pk_keyboard from ddv_waitforconfirmation import wait_for_confirmation from algosdk.future.transaction import AssetTransferTxn from telegram.inline.inlinekeyboardbutton import InlineKeyboardButton from telegram.inline...
0
0
0
0
0
0
0
0
0
7f1f211773401ad5795860d716016250702f8db0
2,030
py
Python
ObjectRecognition/Multi-Shot/em_algorithm_for_our_dataset.py
Holstrup/ObjectRecognition
7c26c38e09fca6d2b36184acc1784c23cc107731
[ "MIT" ]
2
2020-03-20T01:34:01.000Z
2021-09-22T19:46:28.000Z
ObjectRecognition/Multi-Shot/em_algorithm_for_our_dataset.py
Holstrup/ObjectRecognition
7c26c38e09fca6d2b36184acc1784c23cc107731
[ "MIT" ]
null
null
null
ObjectRecognition/Multi-Shot/em_algorithm_for_our_dataset.py
Holstrup/ObjectRecognition
7c26c38e09fca6d2b36184acc1784c23cc107731
[ "MIT" ]
null
null
null
import numpy as np import matplotlib.pyplot as plt from scipy.stats import multivariate_normal from database_actions import get_known_encodings import sklearn.decomposition as deco ## Helper function for plotting a 2D Gaussian ## Load data data = get_known_encodings()[0].transpose() x = (data - np.mean(data, 0)) / n...
27.066667
82
0.649754
import numpy as np import matplotlib.pyplot as plt from scipy.stats import multivariate_normal from database_actions import get_known_encodings import sklearn.decomposition as deco ## Helper function for plotting a 2D Gaussian def plot_normal(mu, Sigma): l, V = np.linalg.eigh(Sigma) l[l < 0] = 0 t = np.lin...
0
0
0
0
0
220
0
0
22
735e3f60b64c0c4f89bd5dbd3ecfbf19f25d530f
19,692
py
Python
distla/distla_core/distla_core/root_solution_unfold/test_probabilityfunctions.py
google/distla_core
7f0d8ab7b847a75e0fc713627488643a8984712a
[ "Apache-2.0" ]
2
2021-12-19T21:17:06.000Z
2021-12-25T09:19:47.000Z
distla/distla_core/distla_core/root_solution_unfold/test_probabilityfunctions.py
google/distla_core
7f0d8ab7b847a75e0fc713627488643a8984712a
[ "Apache-2.0" ]
null
null
null
distla/distla_core/distla_core/root_solution_unfold/test_probabilityfunctions.py
google/distla_core
7f0d8ab7b847a75e0fc713627488643a8984712a
[ "Apache-2.0" ]
1
2021-12-25T09:19:56.000Z
2021-12-25T09:19:56.000Z
# Copyright 2021 The Distla Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable ...
40.269939
101
0.751828
# Copyright 2021 The Distla Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable ...
0
17,449
0
0
0
0
0
109
454
cf550d5046a14f319037b7c1e06767b5b0ef9a2d
6,493
py
Python
analysis_tools/data_processing.py
google-research/policy-learning-landscape
96c99bc67ce40559c61bdb6110f625671fc96055
[ "Apache-2.0" ]
52
2018-11-01T05:30:19.000Z
2022-01-17T10:44:55.000Z
analysis_tools/data_processing.py
google-research/policy-learning-landscape
96c99bc67ce40559c61bdb6110f625671fc96055
[ "Apache-2.0" ]
null
null
null
analysis_tools/data_processing.py
google-research/policy-learning-landscape
96c99bc67ce40559c61bdb6110f625671fc96055
[ "Apache-2.0" ]
12
2018-11-01T15:04:18.000Z
2022-03-29T10:38:07.000Z
# coding=utf-8 # Copyright 2018 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...
34.354497
97
0.708301
# coding=utf-8 # Copyright 2018 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
0
0
c760fcdd39295f98ff32bcf57538c6ed04f2ad26
1,273
py
Python
bunkai/algorithm/bunkai_sbd/annotator/linebreak_force_annotator.py
t-yamamura/bunkai
6a6da28329fbdde2a53176740d403ef96fab4f28
[ "Apache-2.0" ]
null
null
null
bunkai/algorithm/bunkai_sbd/annotator/linebreak_force_annotator.py
t-yamamura/bunkai
6a6da28329fbdde2a53176740d403ef96fab4f28
[ "Apache-2.0" ]
null
null
null
bunkai/algorithm/bunkai_sbd/annotator/linebreak_force_annotator.py
t-yamamura/bunkai
6a6da28329fbdde2a53176740d403ef96fab4f28
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python3 import re RE_LBS = re.compile(r'[\n\s]*\n[\n\s]*')
28.931818
78
0.586803
#!/usr/bin/env python3 import re from bunkai.base.annotation import Annotations, SpanAnnotation from bunkai.base.annotator import Annotator RE_LBS = re.compile(r'[\n\s]*\n[\n\s]*') class LinebreakForceAnnotator(Annotator): def __init__(self): super().__init__(rule_name=self.__class__.__name__) def ...
0
0
0
1,066
0
0
0
63
68
db2b70ef1b086a4f2912233a9df83803b5a5843a
6,528
py
Python
bpy_lambda/2.78/scripts/addons_contrib/cmu_mocap_browser/__init__.py
resultant-gamedev/bpy_lambda
c8cf46c10c69e74a0892b621d76c62edaa5b04bc
[ "MIT" ]
null
null
null
bpy_lambda/2.78/scripts/addons_contrib/cmu_mocap_browser/__init__.py
resultant-gamedev/bpy_lambda
c8cf46c10c69e74a0892b621d76c62edaa5b04bc
[ "MIT" ]
null
null
null
bpy_lambda/2.78/scripts/addons_contrib/cmu_mocap_browser/__init__.py
resultant-gamedev/bpy_lambda
c8cf46c10c69e74a0892b621d76c62edaa5b04bc
[ "MIT" ]
1
2019-11-24T18:43:42.000Z
2019-11-24T18:43:42.000Z
# ##### BEGIN GPL LICENSE BLOCK ##### # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 3 # of the License, or (at your option) any later version. # # This program is distrib...
37.734104
80
0.633885
# ##### BEGIN GPL LICENSE BLOCK ##### # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 3 # of the License, or (at your option) any later version. # # This program is distrib...
0
0
0
4,452
0
72
0
-23
264
206a9c69306d592c115aec3d15b213f0ce82ace6
10,077
py
Python
tools/blendShape.py
fsanges/glTools
8ff0899de43784a18bd4543285655e68e28fb5e5
[ "MIT" ]
165
2015-01-26T05:22:04.000Z
2022-03-22T02:50:41.000Z
tools/blendShape.py
qeeji/glTools
8ff0899de43784a18bd4543285655e68e28fb5e5
[ "MIT" ]
5
2015-12-02T02:39:44.000Z
2020-12-09T02:45:54.000Z
tools/blendShape.py
qeeji/glTools
8ff0899de43784a18bd4543285655e68e28fb5e5
[ "MIT" ]
83
2015-02-10T17:18:24.000Z
2022-02-10T07:16:47.000Z
import maya.cmds as mc import glTools.utils.blendShape import glTools.utils.stringUtils def createFromSelection(origin='local',deformOrder=None,prefix=None): ''' Create basic blendShape from selection. @param origin: Create a local or world space belndShape deformer. Accepted values - "local" or "world". @type or...
33.148026
191
0.708842
import maya.cmds as mc import glTools.utils.blendShape import glTools.utils.stringUtils def createFromSelection(origin='local',deformOrder=None,prefix=None): ''' Create basic blendShape from selection. @param origin: Create a local or world space belndShape deformer. Accepted values - "local" or "world". @type or...
0
0
0
0
0
0
0
0
0
64f5194701eda95eab1cfdf7781165805dd935b7
75
py
Python
dynamic_formsets/__init__.py
nitr0man/django-dynamic-formsets
e6a738b5f93a4721be3f5612b311fce610b16ed2
[ "BSD-3-Clause" ]
8
2017-04-05T23:18:19.000Z
2021-04-21T12:57:31.000Z
dynamic_formsets/__init__.py
nitr0man/django-dynamic-formsets
e6a738b5f93a4721be3f5612b311fce610b16ed2
[ "BSD-3-Clause" ]
null
null
null
dynamic_formsets/__init__.py
nitr0man/django-dynamic-formsets
e6a738b5f93a4721be3f5612b311fce610b16ed2
[ "BSD-3-Clause" ]
7
2017-07-13T22:21:27.000Z
2021-02-11T10:05:16.000Z
default_app_config = 'dynamic_formsets.apps.DynamicFormsetsConfig' # NOQA
37.5
74
0.84
default_app_config = 'dynamic_formsets.apps.DynamicFormsetsConfig' # NOQA
0
0
0
0
0
0
0
0
0
b91942c0dbb4762fe1182a73cc0430502ed2ae5e
9,900
py
Python
raiden/log_config.py
sangaman/raiden
d67d780909148f34528e129fd777dbfcdf0322dc
[ "MIT" ]
null
null
null
raiden/log_config.py
sangaman/raiden
d67d780909148f34528e129fd777dbfcdf0322dc
[ "MIT" ]
null
null
null
raiden/log_config.py
sangaman/raiden
d67d780909148f34528e129fd777dbfcdf0322dc
[ "MIT" ]
null
null
null
import logging import logging.config import re from typing import Any, Callable, Dict, Pattern import gevent LOG_BLACKLIST: Dict[Pattern, str] = { re.compile(r"\b(access_?token=)([a-z0-9_-]+)", re.I): r"\1<redacted>", re.compile( r"(@0x[0-9a-fA-F]{40}:(?:[\w\d._-]+(?::[0-9]+)?))/([0-9a-zA-Z-]+)" )...
36.666667
99
0.621616
import datetime import logging import logging.config import logging.handlers import os import re import sys from functools import wraps from typing import Any, Callable, Dict, FrozenSet, List, Optional, Pattern, Tuple import gevent import structlog LOG_BLACKLIST: Dict[Pattern, str] = { re.compile(r"\b(access_?tok...
0
176
0
2,027
0
5,918
0
8
278
39ca5346670600658860e3fca56ddd28f8264096
20,311
py
Python
venv/Lib/site-packages/psychopy/experiment/components/button/__init__.py
mintzer/pupillometry-rf-back
cfa86fa984a49dce0123798f8de5b838c02e10d5
[ "CC-BY-4.0" ]
null
null
null
venv/Lib/site-packages/psychopy/experiment/components/button/__init__.py
mintzer/pupillometry-rf-back
cfa86fa984a49dce0123798f8de5b838c02e10d5
[ "CC-BY-4.0" ]
null
null
null
venv/Lib/site-packages/psychopy/experiment/components/button/__init__.py
mintzer/pupillometry-rf-back
cfa86fa984a49dce0123798f8de5b838c02e10d5
[ "CC-BY-4.0" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- # Part of the PsychoPy library # Copyright (C) 2002-2018 Jonathan Peirce (C) 2019-2021 Open Science Tools Ltd. # Distributed under the terms of the GNU General Public License (GPL). from psychopy.experiment.components import _translate from psychopy.localization import _lo...
43.399573
124
0.526808
#!/usr/bin/env python # -*- coding: utf-8 -*- # Part of the PsychoPy library # Copyright (C) 2002-2018 Jonathan Peirce (C) 2019-2021 Open Science Tools Ltd. # Distributed under the terms of the GNU General Public License (GPL). from os import path from pathlib import Path from psychopy.alerts import alerttools from ...
0
0
0
18,737
0
0
0
114
113
e56e313773e1b2213e1ecd8886a75725a9089736
680
py
Python
src/arbies/trays/file.py
broiledmeat/arbies
29f3ce498dbd3265b1181dde62629df3deda0440
[ "MIT" ]
null
null
null
src/arbies/trays/file.py
broiledmeat/arbies
29f3ce498dbd3265b1181dde62629df3deda0440
[ "MIT" ]
null
null
null
src/arbies/trays/file.py
broiledmeat/arbies
29f3ce498dbd3265b1181dde62629df3deda0440
[ "MIT" ]
null
null
null
from __future__ import annotations
27.2
86
0.679412
from __future__ import annotations import os from PIL import Image from arbies.manager import Manager, ConfigDict from . import Tray class FileTray(Tray): def __init__(self, manager: Manager): super().__init__(manager) self.path: str = os.path.join(os.getcwd(), 'arbies.png') def serve(self, ...
0
275
0
248
0
0
0
10
111
0a5fc02a89b762faf6e7f46e4da141e65c89327f
25,178
py
Python
wsme/types.py
mail2nsrajesh/wsme
9f84e4c7c59b172a09341af2ab496d07e29e01aa
[ "MIT" ]
2
2020-11-05T06:09:20.000Z
2021-01-03T07:22:18.000Z
wsme/types.py
mail2nsrajesh/wsme
9f84e4c7c59b172a09341af2ab496d07e29e01aa
[ "MIT" ]
null
null
null
wsme/types.py
mail2nsrajesh/wsme
9f84e4c7c59b172a09341af2ab496d07e29e01aa
[ "MIT" ]
null
null
null
import datetime import decimal import inspect import logging import six import weakref log = logging.getLogger(__name__) #: The 'str' (python 2) or 'bytes' (python 3) type. #: Its use should be restricted to #: pure ascii strings as the protocols will generally not be #: be able to send non-unicode strings. #: To tra...
29.938169
79
0.606085
import base64 import datetime import decimal import inspect import logging import netaddr import re import six import sys import uuid import weakref from wsme import exc log = logging.getLogger(__name__) #: The 'str' (python 2) or 'bytes' (python 3) type. #: Its use should be restricted to #: pure ascii strings as t...
0
1,652
0
16,746
0
2,305
0
-49
731
ea7236400f2e4d07ec79a99a0352e08c19052cd8
121
py
Python
config/youtube_secret.py
SpaceAppsXploration/semantic-data-chronos
f7908f50892781154d623f46303812e88fdecb57
[ "Apache-2.0" ]
1
2017-06-15T17:51:19.000Z
2017-06-15T17:51:19.000Z
config/youtube_secret.py
SpaceAppsXploration/semantic-data-chronos
f7908f50892781154d623f46303812e88fdecb57
[ "Apache-2.0" ]
null
null
null
config/youtube_secret.py
SpaceAppsXploration/semantic-data-chronos
f7908f50892781154d623f46303812e88fdecb57
[ "Apache-2.0" ]
null
null
null
__author__ = 'Lorenzo' YOUTUBE_API_SERVICE_NAME = "youtube" YOUTUBE_API_VERSION = "v3" _KEY = '**********************'
17.285714
36
0.603306
__author__ = 'Lorenzo' YOUTUBE_API_SERVICE_NAME = "youtube" YOUTUBE_API_VERSION = "v3" _KEY = '**********************'
0
0
0
0
0
0
0
0
0
821b5e3b321ad3fc71573d135218765d3909a6ed
304
py
Python
app/User.py
craigderington/serviceauto
28958e3cb82431151c02c4bd600cf887c54d2866
[ "MIT" ]
null
null
null
app/User.py
craigderington/serviceauto
28958e3cb82431151c02c4bd600cf887c54d2866
[ "MIT" ]
null
null
null
app/User.py
craigderington/serviceauto
28958e3cb82431151c02c4bd600cf887c54d2866
[ "MIT" ]
null
null
null
"""User Model."""
17.882353
48
0.611842
"""User Model.""" from config.database import Model from orator.orm import has_many class User(Model): """User Model.""" __fillable__ = ["name", "email", "password"] __auth__ = "email" @has_many("id", "user_id") def cars(self): from app.Car import Car return Car
0
76
0
119
0
0
0
22
68
77baf7062818145f17a9ac9dadf5299f599cb365
1,754
py
Python
fooster/console/demo.py
lilyinstarlight/python-fooster-console
e2cd6a80298ba0c22334fdb0967b8c3f074fa49e
[ "MIT" ]
null
null
null
fooster/console/demo.py
lilyinstarlight/python-fooster-console
e2cd6a80298ba0c22334fdb0967b8c3f074fa49e
[ "MIT" ]
null
null
null
fooster/console/demo.py
lilyinstarlight/python-fooster-console
e2cd6a80298ba0c22334fdb0967b8c3f074fa49e
[ "MIT" ]
null
null
null
if __name__ == '__main__': main()
28.754098
110
0.604903
import paramiko import fooster.console def main(): def docstring(a, b, c='c'): """ This function concatenates input strings. Params: a: str b: str c: str = 'c' Returns: concatenated: str """ return a + b + c def argpa...
0
0
0
0
0
1,650
0
-5
68
46668d45a8679b0fff4d90ba130bc1898c1ed301
9,340
py
Python
src/schemathesis/_hypothesis.py
tuffnatty/schemathesis
c104923f31235df49555ab0c8d92b5cb81957de0
[ "MIT" ]
null
null
null
src/schemathesis/_hypothesis.py
tuffnatty/schemathesis
c104923f31235df49555ab0c8d92b5cb81957de0
[ "MIT" ]
null
null
null
src/schemathesis/_hypothesis.py
tuffnatty/schemathesis
c104923f31235df49555ab0c8d92b5cb81957de0
[ "MIT" ]
null
null
null
"""Provide strategies for given endpoint(s) definition.""" import asyncio from typing import Any, Callable, Dict, List, Optional import hypothesis import hypothesis.strategies as st from . import utils from .hooks import GLOBAL_HOOK_DISPATCHER, HookContext, HookDispatcher from .models import Case, Endpoint PARAMETER...
39.576271
118
0.702677
"""Provide strategies for given endpoint(s) definition.""" import asyncio import inspect import re from base64 import b64encode from functools import partial from typing import Any, Callable, Dict, List, Optional, Tuple, Union from urllib.parse import quote_plus import hypothesis import hypothesis.strategies as st fro...
0
380
0
0
0
4,072
0
86
451
68aa41a2d3e0b64696753524447604d00ab9fee5
233
py
Python
wrds2pg/__init__.py
EvanJo/wrds2pg
a3b754c04df0e1c2330ef202d52faeb2c84304b1
[ "MIT" ]
6
2021-02-25T00:37:27.000Z
2022-03-22T09:36:09.000Z
wrds2pg/__init__.py
EvanJo/wrds2pg
a3b754c04df0e1c2330ef202d52faeb2c84304b1
[ "MIT" ]
22
2019-02-17T22:56:51.000Z
2021-09-11T16:29:24.000Z
wrds2pg/__init__.py
iangow/wrds2pg
80fcf8e6aeec92abaafc9d0e69bf23ad5850eaa9
[ "MIT" ]
4
2019-09-02T22:51:04.000Z
2021-07-18T11:53:26.000Z
name = "wrds2pg"
38.833333
72
0.854077
name = "wrds2pg" from wrds2pg.wrds2pg import wrds_update, run_file_sql, get_modified_str from wrds2pg.wrds2pg import make_engine, get_process, wrds_process_to_pg from wrds2pg.wrds2pg import wrds_id, set_table_comment, get_table_sql
0
0
0
0
0
0
0
149
67
dc13acb0da5decc6829064aff1db1908d6636e11
1,287
py
Python
plugins/servicenow/icon_servicenow/actions/get_attachments_for_an_incident/action.py
lukaszlaszuk/insightconnect-plugins
8c6ce323bfbb12c55f8b5a9c08975d25eb9f8892
[ "MIT" ]
null
null
null
plugins/servicenow/icon_servicenow/actions/get_attachments_for_an_incident/action.py
lukaszlaszuk/insightconnect-plugins
8c6ce323bfbb12c55f8b5a9c08975d25eb9f8892
[ "MIT" ]
null
null
null
plugins/servicenow/icon_servicenow/actions/get_attachments_for_an_incident/action.py
lukaszlaszuk/insightconnect-plugins
8c6ce323bfbb12c55f8b5a9c08975d25eb9f8892
[ "MIT" ]
null
null
null
# Custom imports below
39
113
0.658897
import insightconnect_plugin_runtime from .schema import GetAttachmentsForAnIncidentInput, GetAttachmentsForAnIncidentOutput, Input, Output, Component # Custom imports below from icon_servicenow.util.request_helper import RequestHelper class GetAttachmentsForAnIncident(insightconnect_plugin_runtime.Action): def ...
0
0
0
1,026
0
0
0
147
89
f6576b4a0a23ce06b38d3a12dc2cbbf7b01f643f
41,084
py
Python
vosges.py
vadimkantorov/expsge
224f869b609ff15dfb288bcd0814a2931b1a3d94
[ "MIT" ]
null
null
null
vosges.py
vadimkantorov/expsge
224f869b609ff15dfb288bcd0814a2931b1a3d94
[ "MIT" ]
null
null
null
vosges.py
vadimkantorov/expsge
224f869b609ff15dfb288bcd0814a2931b1a3d94
[ "MIT" ]
null
null
null
import os import re import sys import imp import math import copy import json import time import errno import shutil import hashlib import argparse import traceback import functools import itertools import subprocess import xml.dom.minidom __tool_name__ = 'vosges' if __name__ == '__main__': unhandled_exception_hook...
46.527746
800
0.684622
import os import re import sys import imp import math import copy import json import time import errno import shutil import hashlib import argparse import traceback import functools import itertools import subprocess import xml.dom.minidom __tool_name__ = 'vosges' class P: project_page = 'http://github.com/vadimkant...
0
2,767
0
6,400
0
25,760
0
0
535
2d4bf35c0255a499f94a87d490af68ce091b3901
6,935
py
Python
rl_libarary/network/network_arch.py
Jiayuan-Gu/policy-refactorization
c626c598d735d4c08c2c0553da34196b3fba0b6d
[ "MIT" ]
6
2020-10-22T18:57:41.000Z
2021-04-17T22:57:33.000Z
rl_libarary/network/network_arch.py
Jiayuan-Gu/policy-refactorization
c626c598d735d4c08c2c0553da34196b3fba0b6d
[ "MIT" ]
null
null
null
rl_libarary/network/network_arch.py
Jiayuan-Gu/policy-refactorization
c626c598d735d4c08c2c0553da34196b3fba0b6d
[ "MIT" ]
1
2021-01-23T03:28:52.000Z
2021-01-23T03:28:52.000Z
####################################################################### # Copyright (C) 2017 Shangtong Zhang(zhangshangtong.cpp@gmail.com) # # Permission given to modify the code as long as you keep this # # declaration at the top # ################################...
39.403409
90
0.522855
####################################################################### # Copyright (C) 2017 Shangtong Zhang(zhangshangtong.cpp@gmail.com) # # Permission given to modify the code as long as you keep this # # declaration at the top # ################################...
0
0
0
6,161
0
0
0
63
224
5264c3b556ef8aee1ba4aeea67a683c2bead1caa
686
py
Python
Python/13. Regex and Parsing/exercise11.py
mukeshmithrakumar/HackerRankSolutions
cd9e71be5e8703287b9f4efc042df8827175af1b
[ "MIT" ]
12
2019-10-29T09:49:26.000Z
2022-02-21T09:43:41.000Z
Python/13. Regex and Parsing/exercise11.py
ozturkosu/HackerRankSolutions
cd9e71be5e8703287b9f4efc042df8827175af1b
[ "MIT" ]
null
null
null
Python/13. Regex and Parsing/exercise11.py
ozturkosu/HackerRankSolutions
cd9e71be5e8703287b9f4efc042df8827175af1b
[ "MIT" ]
10
2019-12-22T03:18:50.000Z
2021-09-23T16:55:25.000Z
# HTML Parser - Part 2 "https://www.hackerrank.com/challenges/html-parser-part-2/problem" html = "" for i in range(int(input())): html += input().rstrip() html += '\n' parser = MyHTMLParser() parser.feed(html) parser.close()
22.129032
89
0.580175
# HTML Parser - Part 2 "https://www.hackerrank.com/challenges/html-parser-part-2/problem" from html.parser import HTMLParser class MyHTMLParser(HTMLParser): def handle_comment(self, data): number_of_line = len(data.split('\n')) if number_of_line > 1: print('>>> Multi-line Comment') ...
0
0
0
389
0
0
0
13
46
4a23555eff788fa6188ab6355ad62a5e2404a9ab
23,524
py
Python
appengine/swarming/swarming_bot/api/platforms/win.py
hixio-mh/luci-py
5e2606b0db8f5dac25e9f84fdf71d103da393894
[ "Apache-2.0" ]
null
null
null
appengine/swarming/swarming_bot/api/platforms/win.py
hixio-mh/luci-py
5e2606b0db8f5dac25e9f84fdf71d103da393894
[ "Apache-2.0" ]
1
2022-03-02T11:45:18.000Z
2022-03-02T11:45:18.000Z
appengine/swarming/swarming_bot/api/platforms/win.py
hixio-mh/luci-py
5e2606b0db8f5dac25e9f84fdf71d103da393894
[ "Apache-2.0" ]
1
2021-07-23T15:32:55.000Z
2021-07-23T15:32:55.000Z
# Copyright 2015 The LUCI Authors. All rights reserved. # Use of this source code is governed under the Apache License, Version 2.0 # that can be found in the LICENSE file. """Windows specific utility functions.""" import ctypes import logging import re from api.platforms import gpu ## Private stuff. _WIN32_CLIEN...
33.462304
97
0.682622
# Copyright 2015 The LUCI Authors. All rights reserved. # Use of this source code is governed under the Apache License, Version 2.0 # that can be found in the LICENSE file. """Windows specific utility functions.""" import ctypes import logging import os import platform import re import string import subprocess import...
0
13,589
0
0
0
2,147
0
-39
570
8e12716e979558c2134b43f7954452d2ead815d0
3,639
py
Python
src/nbsvm.py
82ndAirborneDiv/autism_surveillance
e647e8cc70cba72cc8c4c8afdf2f7a9132ac06fa
[ "Apache-2.0" ]
null
null
null
src/nbsvm.py
82ndAirborneDiv/autism_surveillance
e647e8cc70cba72cc8c4c8afdf2f7a9132ac06fa
[ "Apache-2.0" ]
1
2020-03-16T14:20:35.000Z
2020-03-16T14:20:35.000Z
src/nbsvm.py
82ndAirborneDiv/autism_surveillance
e647e8cc70cba72cc8c4c8afdf2f7a9132ac06fa
[ "Apache-2.0" ]
1
2020-11-13T14:19:42.000Z
2020-11-13T14:19:42.000Z
import numpy as np import pandas as pd import GPyOpt from sklearn.model_selection import train_test_split from scipy.sparse import load_npz from stuff.models import simpleNBSVM from stuff.tools import tfidf_to_counts from stuff.metrics import binary_diagnostics # Importing the data filedir = 'C:/data/addm/' seeds = ...
34.990385
75
0.574059
import numpy as np import pandas as pd import GPy, GPyOpt from sklearn.model_selection import train_test_split from sklearn.metrics import brier_score_loss as brier_score from sklearn.metrics import accuracy_score, f1_score from scipy.sparse import load_npz from stuff.models import NBSVM, simpleNBSVM from stuff.tools...
0
0
0
0
0
469
0
81
96
19c3b9de302ca7b988a9a9a91185e1307784caf7
1,113
py
Python
Tests/Methods/Mesh/Mesh/test_get_node.py
tobsen2code/pyleecan
5b1ded9e389e0c79ed7b7c878b6e939f2d9962e9
[ "Apache-2.0" ]
95
2019-01-23T04:19:45.000Z
2022-03-17T18:22:10.000Z
Tests/Methods/Mesh/Mesh/test_get_node.py
ecs-kev/pyleecan
1faedde4b24acc6361fa1fdd4e980eaec4ca3a62
[ "Apache-2.0" ]
366
2019-02-20T07:15:08.000Z
2022-03-31T13:37:23.000Z
Tests/Methods/Mesh/Mesh/test_get_node.py
ecs-kev/pyleecan
1faedde4b24acc6361fa1fdd4e980eaec4ca3a62
[ "Apache-2.0" ]
74
2019-01-24T01:47:31.000Z
2022-02-25T05:44:42.000Z
# -*- coding: utf-8 -*-
31.8
92
0.624438
# -*- coding: utf-8 -*- import pytest from pyleecan.Classes.MeshMat import MeshMat from pyleecan.Classes.NodeMat import NodeMat from pyleecan.Classes.CellMat import CellMat import numpy as np @pytest.mark.MeshSol class Test_get_node(object): """unittest for nodes getter methods""" @classmethod def setup_...
0
897
0
0
0
0
0
58
133
64fa5e300050f6c6cc8f2e49d92ca5a441ee4385
2,397
py
Python
piRNA_analysis/snakemake/05_remove_known_ncRNA.py
rberrens/SPOCD1-piRNA_directed_DNA_met
8e795436197ef41f07159624e45d6b0fddb1ded8
[ "MIT" ]
4
2020-07-17T12:03:38.000Z
2021-03-11T03:30:20.000Z
piRNA_analysis/snakemake/05_remove_known_ncRNA.py
rberrens/SPOCD1-piRNA_directed_DNA_met
8e795436197ef41f07159624e45d6b0fddb1ded8
[ "MIT" ]
null
null
null
piRNA_analysis/snakemake/05_remove_known_ncRNA.py
rberrens/SPOCD1-piRNA_directed_DNA_met
8e795436197ef41f07159624e45d6b0fddb1ded8
[ "MIT" ]
1
2021-08-15T07:11:52.000Z
2021-08-15T07:11:52.000Z
configfile: 'config_spocd1_pi.yaml' bowtie = "/usr/local/Cellar/bowtie/1.2.1.1/bin/bowtie" rule all: input: expand("Processed/mapped/{sample}_mirna_mature.sam", sample = config["samples"]), expand("Processed/unmapped/{sample}_mirna_mature_unmmaped.fasta", sample = config["samples"]), expand("Processed/mappe...
33.760563
98
0.684606
configfile: 'config_spocd1_pi.yaml' bowtie = "/usr/local/Cellar/bowtie/1.2.1.1/bin/bowtie" rule all: input: expand("Processed/mapped/{sample}_mirna_mature.sam", sample = config["samples"]), expand("Processed/unmapped/{sample}_mirna_mature_unmmaped.fasta", sample = config["samples"]), expand("Processed/mappe...
0
0
0
0
0
0
0
0
0
4d0033a6673bd48eda72fbaa68b7bd7aec6aef43
716
py
Python
Lintcode/Ladder_8_System Design/5_Web Crawler & Google Suggestion/500. Inverted Index.py
ctc316/algorithm-python
ac4580d55e05e93e407c6156c9bb801808027d60
[ "MIT" ]
null
null
null
Lintcode/Ladder_8_System Design/5_Web Crawler & Google Suggestion/500. Inverted Index.py
ctc316/algorithm-python
ac4580d55e05e93e407c6156c9bb801808027d60
[ "MIT" ]
null
null
null
Lintcode/Ladder_8_System Design/5_Web Crawler & Google Suggestion/500. Inverted Index.py
ctc316/algorithm-python
ac4580d55e05e93e407c6156c9bb801808027d60
[ "MIT" ]
null
null
null
''' Definition of Document class Document: def __init__(self, id, cotent): self.id = id self.content = content '''
27.538462
53
0.515363
''' Definition of Document class Document: def __init__(self, id, cotent): self.id = id self.content = content ''' class Solution: # @param {Document[]} docs a list of documents # @return {dict(string, int[])} an inverted index def invertedIndex(self, docs): inverted = {} ...
0
0
0
560
0
0
0
0
22
87045c96bb353363f39dc08a1c8d7a1570d2c146
2,320
py
Python
hn_clone/posts/migrations/0001_initial.py
bkavanagh/dj-hackernews-clone
543d2774c2b956dd6aadd81a4f51c3df6c3e9060
[ "MIT" ]
null
null
null
hn_clone/posts/migrations/0001_initial.py
bkavanagh/dj-hackernews-clone
543d2774c2b956dd6aadd81a4f51c3df6c3e9060
[ "MIT" ]
null
null
null
hn_clone/posts/migrations/0001_initial.py
bkavanagh/dj-hackernews-clone
543d2774c2b956dd6aadd81a4f51c3df6c3e9060
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by Django 1.11 on 2017-04-12 08:17 from __future__ import unicode_literals
35.692308
118
0.547414
# -*- coding: utf-8 -*- # Generated by Django 1.11 on 2017-04-12 08:17 from __future__ import unicode_literals from django.conf import settings from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): initial = True dependencies = [ migrations...
0
0
0
2,077
0
0
0
41
90
a76a4ea80ec4b884509d547a9b9e63b9cbd85352
336
py
Python
punchclock/urls.py
Haughar/punchclock
4031167693aab85f3577f0e2a6d50d0b482c4bfe
[ "Apache-2.0" ]
3
2017-01-26T00:15:57.000Z
2021-01-21T00:49:34.000Z
punchclock/urls.py
Haughar/punchclock
4031167693aab85f3577f0e2a6d50d0b482c4bfe
[ "Apache-2.0" ]
null
null
null
punchclock/urls.py
Haughar/punchclock
4031167693aab85f3577f0e2a6d50d0b482c4bfe
[ "Apache-2.0" ]
1
2016-09-14T21:52:03.000Z
2016-09-14T21:52:03.000Z
urlpatterns = patterns('punchclock.views', url(r'^$', 'start_task'), url(r'^switch/$', 'switch_task'), url(r'^activities/$', 'get_activities'), url(r'^shift-details/$', 'shift_details'), )
37.333333
65
0.446429
from django.conf.urls import * urlpatterns = patterns('punchclock.views', url(r'^$', 'start_task'), url(r'^switch/$', 'switch_task'), url(r'^activities/$', 'get_activities'), url(r'^shift-details/$', 'shift_details'), ...
0
0
0
0
0
0
0
9
22
3d9b0bb5afd37fe840d12aefa2edcc7ec1d4f278
15,742
py
Python
fuse_examples/classification/cmmd/runner.py
alexgo1/fuse-med-ml
928375828ff321d2bf7b2084389e34e1db0682e9
[ "Apache-2.0" ]
null
null
null
fuse_examples/classification/cmmd/runner.py
alexgo1/fuse-med-ml
928375828ff321d2bf7b2084389e34e1db0682e9
[ "Apache-2.0" ]
null
null
null
fuse_examples/classification/cmmd/runner.py
alexgo1/fuse-med-ml
928375828ff321d2bf7b2084389e34e1db0682e9
[ "Apache-2.0" ]
null
null
null
""" (C) Copyright 2021 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/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software di...
44.343662
145
0.597955
""" (C) Copyright 2021 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/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software di...
0
0
0
0
0
8,909
0
822
472
983f40fad149e0db228d233c258634dc7ba94784
509
py
Python
src/reader.py
vdragan1993/serbian-document-network
b9efa3ca47dd5d1d93112bd38a9c54fb9cec79b9
[ "Apache-2.0" ]
1
2017-11-16T19:26:54.000Z
2017-11-16T19:26:54.000Z
src/reader.py
vdragan1993/serbian-document-network
b9efa3ca47dd5d1d93112bd38a9c54fb9cec79b9
[ "Apache-2.0" ]
null
null
null
src/reader.py
vdragan1993/serbian-document-network
b9efa3ca47dd5d1d93112bd38a9c54fb9cec79b9
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 __author__ = "Dragan Vidakovic" import codecs def read_file_content(path): """ Read file from given path :param path: file path :return: file content """ f = codecs.open(path, 'r', 'utf8') content = f.read() f.close() return content def read_file_line(path): ""...
18.178571
38
0.59725
# coding=utf-8 __author__ = "Dragan Vidakovic" import codecs def read_file_content(path): """ Read file from given path :param path: file path :return: file content """ f = codecs.open(path, 'r', 'utf8') content = f.read() f.close() return content def read_file_line(path): ""...
0
0
0
0
0
0
0
0
0
ba6e68d632bd87e5d36e4f672a6999c57a5273c3
4,654
py
Python
host_watch.py
iPlantCollaborativeOpenSource/host_watch
f0802a5826905ebc77ac3fa156b7582792da34f3
[ "BSD-3-Clause" ]
null
null
null
host_watch.py
iPlantCollaborativeOpenSource/host_watch
f0802a5826905ebc77ac3fa156b7582792da34f3
[ "BSD-3-Clause" ]
null
null
null
host_watch.py
iPlantCollaborativeOpenSource/host_watch
f0802a5826905ebc77ac3fa156b7582792da34f3
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- import argparse import logging import os import sys from collections import namedtuple os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'atmosphere.settings') sys.path.append("/opt/dev/atmosphere") import django django.setup() try: except ImportError: raise "Requires ...
30.418301
97
0.690374
#!/usr/bin/env python # -*- coding: utf-8 -*- import argparse import csv import json import logging import os import time import sys from collections import namedtuple from datetime import datetime from pprint import pformat from subprocess import Popen, PIPE from celery import Celery from celery.events.snapshot impor...
0
0
0
0
0
2,858
0
41
362
3a74271d83bf8dc84945ccf3b8efcf669534670a
957
py
Python
main.py
gilegue/scraping-saham
bd0902a8f3d5d838ca4a19657ff6cdcb3f2654aa
[ "MIT" ]
null
null
null
main.py
gilegue/scraping-saham
bd0902a8f3d5d838ca4a19657ff6cdcb3f2654aa
[ "MIT" ]
null
null
null
main.py
gilegue/scraping-saham
bd0902a8f3d5d838ca4a19657ff6cdcb3f2654aa
[ "MIT" ]
null
null
null
""" GET: data muncul jika url dijalankan lewat browser POST: data tidak bisa diambil lewat browser, namun hanya bisa diambil berdasar permintaan dengan metode post dari form """ import requests import json # Coba jalankan get dari link try: result = requests.get('https://www.idx.co.id/umbraco/Surface/Helper/GetSt...
28.147059
118
0.62278
""" GET: data muncul jika url dijalankan lewat browser POST: data tidak bisa diambil lewat browser, namun hanya bisa diambil berdasar permintaan dengan metode post dari form """ import requests import json import pprint # Coba jalankan get dari link try: result = requests.get('https://www.idx.co.id/umbraco/Surfac...
0
0
0
0
0
0
0
-8
22
f1159041e146bdb9c5b19510a52d63ee8c4d795e
1,741
py
Python
8/src.py
amalloy/advent-of-code-2016
1623383f6736e856d50ac2b7d2c41e2cf7936964
[ "MIT" ]
null
null
null
8/src.py
amalloy/advent-of-code-2016
1623383f6736e856d50ac2b7d2c41e2cf7936964
[ "MIT" ]
null
null
null
8/src.py
amalloy/advent-of-code-2016
1623383f6736e856d50ac2b7d2c41e2cf7936964
[ "MIT" ]
null
null
null
import sys import regex instr_regex = regex.compile(r"""(?|(rect)\ (\d+)x(\d+) # use same group numbers in each | branch | rotate\ (row)\ y=(\d+)\ by\ (\d+) | rotate\ (column)\ x=(\d+)\ by\ (\d+))""", regex.VERBOSE) parse_...
29.508475
100
0.540494
import sys import regex class Rect: def __init__(self, cols, rows): self.cols = cols self.rows = rows def transform(self, _g): return [(y, x, '#') for y in range(self.rows) for x in range(self.cols)] class Row: def __init__(self, row, amt): self.row = row self.amt ...
0
0
0
924
0
102
0
0
114
28b1a7cbb018ae2d07a51c67ff0b9066ff35fef6
486
py
Python
CryostatGUI/plotting&datahandling/extractdata.py
Cryostat-GUI/Cryostat-GUI
9b538ecaef4f1c0758907b9ee32d79ffd6793867
[ "MIT" ]
2
2018-11-23T15:59:19.000Z
2019-01-28T20:18:58.000Z
CryostatGUI/plotting&datahandling/extractdata.py
Cryostat-GUI/Cryostat-GUI
9b538ecaef4f1c0758907b9ee32d79ffd6793867
[ "MIT" ]
54
2018-10-16T20:03:32.000Z
2021-11-09T09:07:03.000Z
CryostatGUI/plotting&datahandling/extractdata.py
Cryostat-GUI/Cryostat-GUI
9b538ecaef4f1c0758907b9ee32d79ffd6793867
[ "MIT" ]
9
2018-11-04T17:37:30.000Z
2021-05-03T21:15:33.000Z
from data_functions import conf import shutil filebase = "./../Logs/" data = filebase + "cooldown_20200422_19.db" if __name__ == "__main__": df = conf(data) df = df.loc[df.times_res - df.times_temps < 1] # print(df.iloc[:, 1:4:2]) dfexp = df.iloc[:, 1:4:2] # print(data[10:-3]) newfile = data...
24.3
82
0.625514
from data_functions import conf import shutil filebase = "./../Logs/" data = filebase + "cooldown_20200422_19.db" if __name__ == "__main__": df = conf(data) df = df.loc[df.times_res - df.times_temps < 1] # print(df.iloc[:, 1:4:2]) dfexp = df.iloc[:, 1:4:2] # print(data[10:-3]) newfile = data...
0
0
0
0
0
0
0
0
0
360bb258606d79a7e8d9980f9d650a84e413e377
3,416
py
Python
hydrodynamics/prolates.py
saridut/FloriPy
0117d358b9c2362ea32ecf9ec719fdaed87d3e14
[ "MIT" ]
null
null
null
hydrodynamics/prolates.py
saridut/FloriPy
0117d358b9c2362ea32ecf9ec719fdaed87d3e14
[ "MIT" ]
null
null
null
hydrodynamics/prolates.py
saridut/FloriPy
0117d358b9c2362ea32ecf9ec719fdaed87d3e14
[ "MIT" ]
null
null
null
#!/usr/bin/env python
34.16
74
0.510539
#!/usr/bin/env python import math import numpy as np from floripy.mathutils.linalg import perm_tensor class Prolates_hydrodynamics(object): def __init__(self, model, flowfield, kwargs): self._model = model self._num_bodies = self._model.num_bodies self._all_prolate_a = model.get_all_prola...
0
0
0
3,289
0
0
0
14
90
a3ec976157a2053001d5cc542fdb7fe2a39c3953
300
py
Python
api/contests/admin.py
ucpr/onlinejudge
472b4671dc8fde8bd2f2b139ce61bc52e8137fcc
[ "MIT" ]
null
null
null
api/contests/admin.py
ucpr/onlinejudge
472b4671dc8fde8bd2f2b139ce61bc52e8137fcc
[ "MIT" ]
null
null
null
api/contests/admin.py
ucpr/onlinejudge
472b4671dc8fde8bd2f2b139ce61bc52e8137fcc
[ "MIT" ]
null
null
null
from django.contrib import admin from .models import Contest, Problem, Submittion, RegistContestUser, Standing # Register your models here. admin.site.register(Contest) admin.site.register(Problem) admin.site.register(Submittion) admin.site.register(RegistContestUser) admin.site.register(Standing)
30
77
0.83
from django.contrib import admin from .models import Contest, Problem, Submittion, RegistContestUser, Standing # Register your models here. admin.site.register(Contest) admin.site.register(Problem) admin.site.register(Submittion) admin.site.register(RegistContestUser) admin.site.register(Standing)
0
0
0
0
0
0
0
0
0
fce7fafeac05e4f358747e96108b86c1527933b1
153
py
Python
backend/test_workaround.py
Ebraegel/code-challenge-backend
379d2f2d8efc77cfb373c4f118815f1a3f44f5e5
[ "MIT" ]
null
null
null
backend/test_workaround.py
Ebraegel/code-challenge-backend
379d2f2d8efc77cfb373c4f118815f1a3f44f5e5
[ "MIT" ]
null
null
null
backend/test_workaround.py
Ebraegel/code-challenge-backend
379d2f2d8efc77cfb373c4f118815f1a3f44f5e5
[ "MIT" ]
null
null
null
# this is just here to trick pytest into finding my modules # I probably set something up wrong, but this is the quickest workaround I found to fix it :)
76.5
93
0.771242
# this is just here to trick pytest into finding my modules # I probably set something up wrong, but this is the quickest workaround I found to fix it :)
0
0
0
0
0
0
0
0
0
73b991335fc701acd68a4e033e02b5be193dad42
1,147
py
Python
setup.py
telegents/django-rest-framework-nr
601d029d3a01bb8e1e3e633aaabe9da8f071f4db
[ "MIT" ]
null
null
null
setup.py
telegents/django-rest-framework-nr
601d029d3a01bb8e1e3e633aaabe9da8f071f4db
[ "MIT" ]
null
null
null
setup.py
telegents/django-rest-framework-nr
601d029d3a01bb8e1e3e633aaabe9da8f071f4db
[ "MIT" ]
null
null
null
#!/bin/bin/env python # Always prefer setuptools over distutils from setuptools import setup, find_packages # To use a consistent encoding setup( name='djangorestframework-nr', version='0.1.1', description='Provide nested router support to Django REST Framework', url='https://github.com/ipglobal/djang...
32.771429
73
0.636443
#!/bin/bin/env python # Always prefer setuptools over distutils from setuptools import setup, find_packages # To use a consistent encoding from codecs import open setup( name='djangorestframework-nr', version='0.1.1', description='Provide nested router support to Django REST Framework', url='https://g...
0
0
0
0
0
0
0
2
22
31fe204cbf21d1b04873a0024fa37c9b36c54660
791
py
Python
test/add-tables.py
deephaven/action-assert-dh-tables-present
b53127e3ff83c0915ce96662890fbf7ea509a787
[ "Apache-2.0" ]
null
null
null
test/add-tables.py
deephaven/action-assert-dh-tables-present
b53127e3ff83c0915ce96662890fbf7ea509a787
[ "Apache-2.0" ]
3
2021-10-29T18:58:10.000Z
2022-03-21T18:12:44.000Z
test/add-tables.py
deephaven/action-assert-dh-tables-present
b53127e3ff83c0915ce96662890fbf7ea509a787
[ "Apache-2.0" ]
null
null
null
""" add-tables.py A Python script that adds a few tables to Deephaven. @copyright Deephaven Data Labs """ from pydeephaven import Session import time session = None #Simple retry loop in case the server tries to launch before Deephaven is ready count = 0 max_count = 5 while (count < max_count): try: se...
22.6
79
0.702908
""" add-tables.py A Python script that adds a few tables to Deephaven. @copyright Deephaven Data Labs """ from pydeephaven import Session import time session = None #Simple retry loop in case the server tries to launch before Deephaven is ready count = 0 max_count = 5 while (count < max_count): try: se...
0
0
0
0
0
0
0
0
0
ab2a83197c89a1e0ff6cfb6e1d7534c8066151cd
5,834
py
Python
PokerRL/cfr/MCCFR.py
MAWUT0R/PokerRL
95708a5f7a16cb151bc4253132bdfd22ea7a9b25
[ "MIT" ]
1
2022-02-28T11:51:44.000Z
2022-02-28T11:51:44.000Z
PokerRL/cfr/MCCFR.py
MAWUT0R/PokerRL
95708a5f7a16cb151bc4253132bdfd22ea7a9b25
[ "MIT" ]
null
null
null
PokerRL/cfr/MCCFR.py
MAWUT0R/PokerRL
95708a5f7a16cb151bc4253132bdfd22ea7a9b25
[ "MIT" ]
1
2022-03-05T10:10:24.000Z
2022-03-05T10:10:24.000Z
# Copyright (c) 2019 Eric Steinberger
41.375887
108
0.508742
# Copyright (c) 2019 Eric Steinberger import numpy as np import sys from PokerRL.cfr._MCCFRBase import MCCFRBase as _MCCFRBase class MCCFR(_MCCFRBase): def __init__(self, name, chief_handle, game_cls, agent_bet_set, starting_...
0
0
0
5,680
0
0
0
23
91
ed4bdba5a4eae3253f1d7c30cfde20e098d5f149
152
py
Python
CodeUp/2721_순환문자열.py
woorimlee/cpp_CTCI_6E_APSS
ff1d42e871ba853ac3de726df0c609885ba07573
[ "MIT" ]
2
2020-12-30T03:35:51.000Z
2021-02-28T20:39:09.000Z
CodeUp/2721_순환문자열.py
woorimlee/cpp_CTCI_6E_APSS
ff1d42e871ba853ac3de726df0c609885ba07573
[ "MIT" ]
1
2020-12-08T08:48:40.000Z
2021-04-09T04:58:57.000Z
CodeUp/2721_순환문자열.py
woorimlee/Algorithm-Repository
ff1d42e871ba853ac3de726df0c609885ba07573
[ "MIT" ]
null
null
null
s1 = input() s2 = input() s3 = input() if s1[-1] == s2[0] and s2[-1] == s3[0] and s3[-1] == s1[0] : print("good") else : print("bad") #
16.888889
60
0.486842
s1 = input() s2 = input() s3 = input() if s1[-1] == s2[0] and s2[-1] == s3[0] and s3[-1] == s1[0] : print("good") else : print("bad") #이거 뭔가 이상
18
0
0
0
0
0
0
0
0
5383461e118503345bd83f69def60dc7578dfe65
2,685
py
Python
run4.py
Ckst123/KoBERT-events
68eb22845b179bcaf13771fea776be3d9772306f
[ "Apache-2.0" ]
null
null
null
run4.py
Ckst123/KoBERT-events
68eb22845b179bcaf13771fea776be3d9772306f
[ "Apache-2.0" ]
null
null
null
run4.py
Ckst123/KoBERT-events
68eb22845b179bcaf13771fea776be3d9772306f
[ "Apache-2.0" ]
null
null
null
label_list = ['','','','','','','','','',''] if __name__ == '__main__': main()
29.833333
110
0.650279
from data_loader import load_data, tokenizer from models import BertForMultipleLabelSequenceClassificationWithFocalLoss from transformers import AutoConfig import torch from tqdm.auto import tqdm from transformers import get_scheduler from transformers import AdamW from sklearn.metrics import accuracy_score, f1_score ...
117
0
0
0
0
2,154
0
143
246
4bd94a5c4ac0744f7a63a24fc4e6139eb9914015
15,746
py
Python
tspwplib/converter.py
PatrickOHara/tspwplib
fcb6d3fb310f8f6adea1f01d1f2f4f5a732f3319
[ "MIT" ]
1
2020-12-06T12:22:59.000Z
2020-12-06T12:22:59.000Z
tspwplib/converter.py
PatrickOHara/tspwplib
fcb6d3fb310f8f6adea1f01d1f2f4f5a732f3319
[ "MIT" ]
6
2020-11-27T12:53:10.000Z
2021-01-29T11:38:04.000Z
tspwplib/converter.py
PatrickOHara/tspwplib
fcb6d3fb310f8f6adea1f01d1f2f4f5a732f3319
[ "MIT" ]
null
null
null
"""Converting between different types of graphs""" from copy import deepcopy import math from typing import Dict, List, Tuple, Union import networkx as nx import pandas as pd from .exception import UnexpectedSelfLoopException from .types import (Edge, EdgeFunction, EdgeFunctionName, EdgeList, EdgeProperties, MultiEdg...
31.366534
97
0.66582
"""Converting between different types of graphs""" from copy import deepcopy import math from typing import Dict, List, Tuple, Union import networkx as nx import pandas as pd from .exception import UnexpectedSelfLoopException from .types import ( Edge, EdgeFunction, EdgeFunctionName, EdgeList, Edg...
0
0
0
0
0
0
0
43
0
56b0ecee08d118c8c4aa1e0d5b5c4214a1dceb5f
1,597
py
Python
app/segurity.py
Jebux01/fastapi_curse
0cb2587215ff8721d9a7fee0c9a3791c78ca6512
[ "MIT" ]
null
null
null
app/segurity.py
Jebux01/fastapi_curse
0cb2587215ff8721d9a7fee0c9a3791c78ca6512
[ "MIT" ]
null
null
null
app/segurity.py
Jebux01/fastapi_curse
0cb2587215ff8721d9a7fee0c9a3791c78ca6512
[ "MIT" ]
null
null
null
from passlib.context import CryptContext pwd_context = CryptContext(schemes=["bcrypt"], deprecated="auto") SECRET_KEY = "09d25e094faa6ca2556c818166b7a9563b93f7099f6f0f4caa6cf63b88e8d3e7" ALGORITHM = "HS256"
37.139535
83
0.724483
from datetime import datetime, timedelta from typing import Optional from fastapi import HTTPException, status from fastapi.security import OAuth2PasswordBearer, OAuth2PasswordRequestForm from jose import JWTError, jwt from passlib.context import CryptContext from .models import crud from pydantic import BaseModel pwd...
0
993
0
-9
0
0
0
121
286
1c14663942cdee274628e5af587f4c22f3eaaeeb
14,815
py
Python
lhotse/audio.py
leixin/lhotse
24d713b81e8dbc0cdfec1038024a3b8a44eb54bd
[ "Apache-2.0" ]
null
null
null
lhotse/audio.py
leixin/lhotse
24d713b81e8dbc0cdfec1038024a3b8a44eb54bd
[ "Apache-2.0" ]
null
null
null
lhotse/audio.py
leixin/lhotse
24d713b81e8dbc0cdfec1038024a3b8a44eb54bd
[ "Apache-2.0" ]
null
null
null
from typing import List, Union Channels = Union[int, List[int]] # TODO: document the dataclasses like this: # https://stackoverflow.com/a/3051356/5285891
40.040541
114
0.638677
import warnings from dataclasses import asdict, dataclass from io import BytesIO from math import sqrt from pathlib import Path from subprocess import PIPE, run from typing import Callable, Dict, Iterable, List, Optional, Union, Tuple import numpy as np from lhotse.utils import Decibels, Pathlike, Seconds, SetContain...
0
9,516
0
3,973
0
692
0
155
316
7e280785ef49530dd2e1f8d498269eea3692e7e7
3,110
py
Python
gen_layer.py
JohnTanium/attck_empire
acb86a9817217a7f994cbf7266c8355e7cddc6d5
[ "Apache-2.0" ]
41
2018-09-05T05:14:26.000Z
2021-01-10T06:04:08.000Z
gen_layer.py
JohnTanium/attck_empire
acb86a9817217a7f994cbf7266c8355e7cddc6d5
[ "Apache-2.0" ]
null
null
null
gen_layer.py
JohnTanium/attck_empire
acb86a9817217a7f994cbf7266c8355e7cddc6d5
[ "Apache-2.0" ]
9
2018-09-06T02:01:55.000Z
2020-09-13T05:02:44.000Z
# Please note that this script was based on the original code developed by MITRE ATT&CK team used for the generation of # ATT&CK Navigator files. This script was slightly modified and configured to output JSON file instead. # https://github.com/mitre/attack-navigator # attack_layers_simple.py - the "hello, world"...
39.367089
140
0.646624
# Please note that this script was based on the original code developed by MITRE ATT&CK team used for the generation of # ATT&CK Navigator files. This script was slightly modified and configured to output JSON file instead. # https://github.com/mitre/attack-navigator # attack_layers_simple.py - the "hello, world"...
0
0
0
0
0
2,008
0
-50
140
a18bacf6ada98506f47bd947618d1f0cfc7b37a7
20
py
Python
lightcontrol/ledcontrol/__init__.py
reefberrypi/reefberrypi
f1e9977e8f56b402ef4d231ba8d4cdd0e469db42
[ "MIT" ]
null
null
null
lightcontrol/ledcontrol/__init__.py
reefberrypi/reefberrypi
f1e9977e8f56b402ef4d231ba8d4cdd0e469db42
[ "MIT" ]
null
null
null
lightcontrol/ledcontrol/__init__.py
reefberrypi/reefberrypi
f1e9977e8f56b402ef4d231ba8d4cdd0e469db42
[ "MIT" ]
null
null
null
__author__ = 'outm'
10
19
0.7
__author__ = 'outm'
0
0
0
0
0
0
0
0
0
12ec6ffaf1669a125e29a7b1eb6ff548467b3776
3,712
py
Python
_unittests/ut_jenkinshelper/test_yaml_jenkins_startup_linux.py
Pandinosaurus/pyquickhelper
326276f656cf88989e4d0fcd006ada0d3735bd9e
[ "MIT" ]
18
2015-11-10T08:09:23.000Z
2022-02-16T11:46:45.000Z
_unittests/ut_jenkinshelper/test_yaml_jenkins_startup_linux.py
Pandinosaurus/pyquickhelper
326276f656cf88989e4d0fcd006ada0d3735bd9e
[ "MIT" ]
321
2015-06-14T21:34:28.000Z
2021-11-28T17:10:03.000Z
_unittests/ut_jenkinshelper/test_yaml_jenkins_startup_linux.py
Pandinosaurus/pyquickhelper
326276f656cf88989e4d0fcd006ada0d3735bd9e
[ "MIT" ]
10
2015-06-20T01:35:00.000Z
2022-01-19T15:54:32.000Z
""" @brief test log(time=2s) """ import unittest if __name__ == "__main__": unittest.main()
36.038835
96
0.509159
""" @brief test log(time=2s) """ import sys import os import unittest import re from pyquickhelper.loghelper import fLOG from pyquickhelper.jenkinshelper.jenkins_server import JenkinsExt from pyquickhelper.jenkinshelper.jenkins_helper import default_engines, setup_jenkins_server_yml class TestYamlJenkinsStartu...
0
0
0
3,348
0
0
0
103
157
39b93fdfb8a3fe0e22858fcc5cd555c4e5362d12
8,973
py
Python
src/easel/site/contents/proxies.py
tnahs/easel
eb7ed750097729ffb9330207730fd23ff5f6571b
[ "MIT" ]
null
null
null
src/easel/site/contents/proxies.py
tnahs/easel
eb7ed750097729ffb9330207730fd23ff5f6571b
[ "MIT" ]
null
null
null
src/easel/site/contents/proxies.py
tnahs/easel
eb7ed750097729ffb9330207730fd23ff5f6571b
[ "MIT" ]
null
null
null
import logging from typing import TYPE_CHECKING import PIL.Image if TYPE_CHECKING: logger = logging.getLogger()
27.86646
92
0.590327
import abc import json import logging import pathlib from typing import TYPE_CHECKING, Callable, List, Optional, Tuple import PIL.Image import PIL.ImageFilter from ..defaults import Defaults from ..globals import Globals if TYPE_CHECKING: from .contents import Image logger = logging.getLogger() class BasePr...
0
2,135
0
6,412
0
0
0
30
274
9e7b1d76cca47a843354505453349edd0738cce1
1,262
py
Python
client.py
gdelvalle/RU_Python_IV_API
0c6d34fe1ae2b95466077cab730adbc8d39335b3
[ "MIT" ]
null
null
null
client.py
gdelvalle/RU_Python_IV_API
0c6d34fe1ae2b95466077cab730adbc8d39335b3
[ "MIT" ]
null
null
null
client.py
gdelvalle/RU_Python_IV_API
0c6d34fe1ae2b95466077cab730adbc8d39335b3
[ "MIT" ]
1
2019-03-20T21:29:11.000Z
2019-03-20T21:29:11.000Z
#!/usr/bin/env python2 from __future__ import print_function import requests import sys # debug_mode() if len(sys.argv) > 1: url = sys.argv[1] else: url = "http://localhost:5000/" # first request first_hit = requests.get(url) first_json = first_hit.json() token = first_json.pop('token') title, next_url = f...
24.745098
65
0.679081
#!/usr/bin/env python2 from __future__ import print_function import requests import logging import sys def debug_mode(): try: # for Python 3 from http.client import HTTPConnection except ImportError: from httplib import HTTPConnection HTTPConnection.debuglevel = 1 logging.basicConfi...
0
0
0
0
0
385
0
-7
45
e8d92cb30dd56ce55f76ba636b94eaab843a180e
32
py
Python
k12_2_c.py
DerBaum28/PythonKara
a026975c07f928869f0fcb6ed650c124a877f4ed
[ "MIT" ]
null
null
null
k12_2_c.py
DerBaum28/PythonKara
a026975c07f928869f0fcb6ed650c124a877f4ed
[ "MIT" ]
1
2022-02-09T17:42:59.000Z
2022-02-09T17:42:59.000Z
k12_2_c.py
DerBaum28/PythonKara
a026975c07f928869f0fcb6ed650c124a877f4ed
[ "MIT" ]
1
2022-01-26T09:50:13.000Z
2022-01-26T09:50:13.000Z
x = 1 tools.showMessage(str(x))
10.666667
25
0.6875
x = 1 tools.showMessage(str(x))
0
0
0
0
0
0
0
0
0
629fb8eff6414b3bffa9468222c19b974485643e
3,109
py
Python
tests/test_integration.py
evewurtele/pyrpipe
f8f40bba5355a9acac055a5512666549579dc9b9
[ "MIT" ]
null
null
null
tests/test_integration.py
evewurtele/pyrpipe
f8f40bba5355a9acac055a5512666549579dc9b9
[ "MIT" ]
null
null
null
tests/test_integration.py
evewurtele/pyrpipe
f8f40bba5355a9acac055a5512666549579dc9b9
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Sat Jan 11 10:27:44 2020 @author: usingh Test various pyrpipe modules used with each other """ from testingEnvironment import testSpecs testVars=testSpecs() fq1=testVars.fq1 fq2=testVars.fq2 rRNAfasta=testVars.rRNAfa #srr='ERR3770564' #single end arabido...
34.932584
120
0.699904
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Sat Jan 11 10:27:44 2020 @author: usingh Test various pyrpipe modules used with each other """ from pyrpipe import sra,qc,mapping,assembly,quant,tools from pyrpipe import pyrpipe_utils as pu from testingEnvironment import testSpecs import os testVars=tes...
0
0
0
0
0
2,539
0
40
94
5f74f4c683579121f94744d0179b6494bfae72ac
153
py
Python
blockworld/envs/__init__.py
menwhitehead/gym-blockworld
ce3a878487c28c0fd80bd98764e8e8cf65b9eb84
[ "MIT" ]
null
null
null
blockworld/envs/__init__.py
menwhitehead/gym-blockworld
ce3a878487c28c0fd80bd98764e8e8cf65b9eb84
[ "MIT" ]
null
null
null
blockworld/envs/__init__.py
menwhitehead/gym-blockworld
ce3a878487c28c0fd80bd98764e8e8cf65b9eb84
[ "MIT" ]
null
null
null
# from blockworld_env.envs.walkway import BlockworldWalkwayEnv
30.6
62
0.888889
from blockworld_walkway import BlockworldWalkway from bigworld import BlockworldBigworld # from blockworld_env.envs.walkway import BlockworldWalkwayEnv
0
0
0
0
0
0
0
45
44
4352cbf9ffd1fd12aebbf117c96b9205f26dbe75
3,482
py
Python
demos/sysmon/server.py
rob-blackbourn/bareASGI-graphql-next
7ff1b455a0dc61dbf41cb6383d8934155661b2cc
[ "Apache-2.0" ]
2
2020-04-27T19:54:26.000Z
2022-03-30T10:06:29.000Z
demos/sysmon/server.py
rob-blackbourn/bareASGI-graphql-next
7ff1b455a0dc61dbf41cb6383d8934155661b2cc
[ "Apache-2.0" ]
null
null
null
demos/sysmon/server.py
rob-blackbourn/bareASGI-graphql-next
7ff1b455a0dc61dbf41cb6383d8934155661b2cc
[ "Apache-2.0" ]
null
null
null
""" Server """ import asyncio import logging import os from typing import Optional from hypercorn.asyncio import serve from hypercorn.config import Config import uvicorn from sysmon.app import make_application LOGGER = logging.getLogger(__name__) def initialise_logging() -> None: """Initialise logging""" ...
25.05036
80
0.547099
""" Server """ import asyncio import logging import os from typing import Optional from hypercorn.asyncio import serve from hypercorn.config import Config import uvicorn from sysmon.app import make_application LOGGER = logging.getLogger(__name__) def initialise_logging() -> None: """Initialise logging""" ...
0
0
0
0
0
0
0
0
0
dc079868b534e5648a36f9fc47bcc0427f96db96
4,527
py
Python
cinder/api/v3/snapshots.py
mail2nsrajesh/cinder
a688b872bec6d1abd4dcd852bdb8e8a921369d2e
[ "Apache-2.0" ]
null
null
null
cinder/api/v3/snapshots.py
mail2nsrajesh/cinder
a688b872bec6d1abd4dcd852bdb8e8a921369d2e
[ "Apache-2.0" ]
null
null
null
cinder/api/v3/snapshots.py
mail2nsrajesh/cinder
a688b872bec6d1abd4dcd852bdb8e8a921369d2e
[ "Apache-2.0" ]
null
null
null
# Copyright 2016 EMC Corporation # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required ...
40.061947
79
0.625801
# Copyright 2016 EMC Corporation # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required ...
0
624
0
2,835
0
63
0
84
180
95e899c26edccd219f8ce067bcf1b04f98a8e10b
357
py
Python
django_throttling/middleware.py
hotbaby/django-throttling-py
9a8b2f0d9fae7e439c332826b9ac154e48c3f10c
[ "MIT" ]
null
null
null
django_throttling/middleware.py
hotbaby/django-throttling-py
9a8b2f0d9fae7e439c332826b9ac154e48c3f10c
[ "MIT" ]
null
null
null
django_throttling/middleware.py
hotbaby/django-throttling-py
9a8b2f0d9fae7e439c332826b9ac154e48c3f10c
[ "MIT" ]
null
null
null
# encoding: utf8
27.461538
63
0.787115
# encoding: utf8 from django.http.response import JsonResponse from .throttling import AnonRateThrottle from .settings import THROTTLE_TRIGGER_RESPONSE class AnonThrottleMiddleware(object): def process_request(self, request): if not AnonRateThrottle().allow_request(request, None): return Jso...
0
0
0
179
0
0
0
69
91
43f2249288ec5a0aadda34f7ad71b9fbfc846014
304
py
Python
users/admin.py
LeonardoCruzx/Projeto_rede_social
5f6fc9fe4d1fbc1cfea696a4ff1d19fd98697bc0
[ "CC0-1.0" ]
null
null
null
users/admin.py
LeonardoCruzx/Projeto_rede_social
5f6fc9fe4d1fbc1cfea696a4ff1d19fd98697bc0
[ "CC0-1.0" ]
7
2020-06-05T20:31:01.000Z
2021-09-22T18:22:45.000Z
users/admin.py
LeonardoCruzx/Projeto_rede_social
5f6fc9fe4d1fbc1cfea696a4ff1d19fd98697bc0
[ "CC0-1.0" ]
null
null
null
# Register your models here.
30.4
74
0.726974
from django.contrib import admin from .models import User # Register your models here. @admin.register(User) class UserAdmin(admin.ModelAdmin): list_display = ('nick','email','last_login','is_staff','is_superuser') list_filter = ('last_login','date_joined') search_fields = ['nick','email']
0
194
0
0
0
0
0
14
67
cbad31c5a78e4d83b04f6fff8f9b73426ebf50f0
408
py
Python
utils/dictionary.py
devbas/aml-quora
da343ff3499566da082e12329e6228a1d9b34a7a
[ "MIT" ]
null
null
null
utils/dictionary.py
devbas/aml-quora
da343ff3499566da082e12329e6228a1d9b34a7a
[ "MIT" ]
null
null
null
utils/dictionary.py
devbas/aml-quora
da343ff3499566da082e12329e6228a1d9b34a7a
[ "MIT" ]
null
null
null
dictionary = dict()
20.4
49
0.710784
dictionary = dict() def word_to_index(word): if word not in dictionary.values(): dictionary.append(word) print('dictionary: ', dictionary); return dictionary[word] def create_dict(row): for count, word in enumerate(row['question1']): row['question1'][count] = word_to_index(word) for count, word in enu...
0
0
0
0
0
341
0
0
46
1bfa2752c549d969ba1de71e5a1817a77f46995d
2,385
py
Python
module2-sql-for-analysis/titanic_import.py
jonDuke/DS-Unit-3-Sprint-2-SQL-and-Databases
76b951430098bfafd4fc5e882380af98cc302268
[ "MIT" ]
null
null
null
module2-sql-for-analysis/titanic_import.py
jonDuke/DS-Unit-3-Sprint-2-SQL-and-Databases
76b951430098bfafd4fc5e882380af98cc302268
[ "MIT" ]
null
null
null
module2-sql-for-analysis/titanic_import.py
jonDuke/DS-Unit-3-Sprint-2-SQL-and-Databases
76b951430098bfafd4fc5e882380af98cc302268
[ "MIT" ]
null
null
null
### migrates data from titanic.csv to postgresql # load titanic data import pandas as pd url = 'https://raw.githubusercontent.com/jonDuke/DS-Unit-3-Sprint-2-SQL-and-Databases/master/module2-sql-for-analysis/titanic.csv' df = pd.read_csv(url) # df.columns = ['Survived', 'Pclass', 'Name', 'Sex', 'Age', # ...
30.576923
131
0.673795
### migrates data from titanic.csv to postgresql # load titanic data import pandas as pd url = 'https://raw.githubusercontent.com/jonDuke/DS-Unit-3-Sprint-2-SQL-and-Databases/master/module2-sql-for-analysis/titanic.csv' df = pd.read_csv(url) # df.columns = ['Survived', 'Pclass', 'Name', 'Sex', 'Age', # ...
0
0
0
0
0
0
0
0
0
5d4f439b73158e89c246dfc5c2d639f5751c02bd
2,246
py
Python
empire/client/src/utils/autocomplete_util.py
chenxiangfang/Empire
2d93b231e754fbd1277a2e54d89d42d1e954322f
[ "BSD-3-Clause" ]
2,541
2019-08-08T19:38:05.000Z
2022-03-30T22:24:06.000Z
empire/client/src/utils/autocomplete_util.py
Devil123166/Empire
6d8169a8ea818f9af478e173a9a548c626c80d05
[ "BSD-3-Clause" ]
344
2019-10-24T03:06:15.000Z
2022-03-26T10:54:10.000Z
empire/client/src/utils/autocomplete_util.py
Devil123166/Empire
6d8169a8ea818f9af478e173a9a548c626c80d05
[ "BSD-3-Clause" ]
431
2019-08-22T22:45:45.000Z
2022-03-29T18:45:21.000Z
import os from typing import List def filtered_search_list(search: str, keys) -> List[str]: """ Filters the search list by a search string :param search: the string prefix :param keys: the list of strings to search :return: filtered list """ return list(filter(lambda x: (search.lower()) i...
35.09375
103
0.67854
import os from typing import List def filtered_search_list(search: str, keys) -> List[str]: """ Filters the search list by a search string :param search: the string prefix :param keys: the list of strings to search :return: filtered list """ return list(filter(lambda x: (search.lower()) i...
0
0
0
0
0
0
0
0
0
93681128798884254303ff7e0d2b2f44420e0596
6,087
py
Python
BaseNotebooks/LR2DB.py
evgeniy97/taskgenerator
7680989c2a080761ef574fac148a0a94c722ad16
[ "MIT" ]
1
2018-07-19T09:56:35.000Z
2018-07-19T09:56:35.000Z
BaseNotebooks/LR2DB.py
evgeniy97/taskgenerator
7680989c2a080761ef574fac148a0a94c722ad16
[ "MIT" ]
null
null
null
BaseNotebooks/LR2DB.py
evgeniy97/taskgenerator
7680989c2a080761ef574fac148a0a94c722ad16
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Numerical Methods, lab 2 """ from sympy import Rational as syR from sympy import exp, sin, cos, sqrt, log, ln from sympy import sinh, tan # Task_db Tasks_db = { 'Task1': [ # 2.1.1 {'f': lambda x: sin(x)**2 - syR(5, 6)*sin(x) + syR(1, 6), 'g': lambda x: sin(x)**2...
30.742424
85
0.357155
# -*- coding: utf-8 -*- """ Numerical Methods, lab 2 """ import sympy as sy from sympy import Rational as syR from sympy import exp, sin, cos, sqrt, log, ln from sympy import pi, cot, sinh, cosh, atan, tan # Это был Task_db Tasks_db = { 'Task1': [ # 2.1.1 {'f': lambda x: sin(x)**2 - syR(5, 6)*sin(x)...
142
0
0
0
0
0
0
18
23
5e510e6737a7b1df98fc81548f508053cb62b611
980
py
Python
main.py
gstok/stddev-gradient
a13a463438d7d71556bbc4289ade0fbd4314468e
[ "MIT" ]
1
2021-01-16T07:06:31.000Z
2021-01-16T07:06:31.000Z
main.py
gstok/stddev-gradient
a13a463438d7d71556bbc4289ade0fbd4314468e
[ "MIT" ]
null
null
null
main.py
gstok/stddev-gradient
a13a463438d7d71556bbc4289ade0fbd4314468e
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- import numpy as np; a = np.array([3.0, 3.0, 2.0, 4.9, 100.2, -8.9]); # grad = gradient(); print(grad); n1 = func2(0); n2 = func2(1); n3 = func2(2); n4 = func2(3); n5 = func2(4); n6 = func2(5); b = [n1, n2, n3, n4, n5, n6]; print(b);
18.490566
68
0.47551
#!/usr/bin/env python3 # -*- coding: utf-8 -*- import numpy as np; a = np.array([3.0, 3.0, 2.0, 4.9, 100.2, -8.9]); # 数值微分求标准差梯度 def gradient (): d = 1e-5; grad = np.zeros(a.size); func = lambda : np.sqrt(np.sum((a - np.mean(a)) ** 2) / a.size); # func = lambda : np.std(a, ddof = 1); # func = lam...
48
0
0
0
0
628
0
0
45
922d7bcfaefa314c1230ff67b8babf51fea44b0e
2,884
py
Python
anli/corpus_statistics.py
rlebras/abductive-commonsense-reasoning
1632561ea87da2129fc2275498f52e175b75b8ec
[ "Apache-2.0" ]
41
2020-02-27T22:46:13.000Z
2022-03-22T02:53:32.000Z
anli/corpus_statistics.py
higuseonhye/abductive-commonsense-reasoning
3407ad999ccc351fc78dd0598d584d1e9f5bd2fc
[ "Apache-2.0" ]
3
2020-04-05T20:20:06.000Z
2020-09-01T10:19:05.000Z
anli/corpus_statistics.py
higuseonhye/abductive-commonsense-reasoning
3407ad999ccc351fc78dd0598d584d1e9f5bd2fc
[ "Apache-2.0" ]
16
2020-04-29T22:56:27.000Z
2022-03-20T15:22:00.000Z
import argparse import json if __name__ == '__main__': parser = argparse.ArgumentParser( description='Script to compute corpus satistics') # Required Parameters parser.add_argument('--input_file', type=str, help='Location of data', default=None) parser.add_argument('--label_file', type=s...
32.044444
109
0.666782
import argparse import json import numpy as np from utils.file_utils import read_jsonl_lines, read_lines def _key(r): return r['obs1'] + '||' + r['obs2'] def correct_middle(r): return r['hyp' + r['label']] def incorrect_middle(r): if r['label'] == "1": return r['hyp2'] else: retur...
0
0
0
0
0
2,148
0
33
160
4b8a529e609b440497e2750f8e857e41f5fdbd4b
609
py
Python
lcodev/ecom/api/order/models.py
ShahSau/Amina-s
bb57e138b2256f064eb9bc5d44aa1b19300c029a
[ "MIT" ]
null
null
null
lcodev/ecom/api/order/models.py
ShahSau/Amina-s
bb57e138b2256f064eb9bc5d44aa1b19300c029a
[ "MIT" ]
null
null
null
lcodev/ecom/api/order/models.py
ShahSau/Amina-s
bb57e138b2256f064eb9bc5d44aa1b19300c029a
[ "MIT" ]
null
null
null
# Create your models here.
35.823529
89
0.776683
from django.db import models from api.user.models import CustomUser from api.product.models import Product # Create your models here. class Order(models.Model): user = models.ForeignKey(CustomUser, on_delete=models.CASCADE, null=True, blank=True) product_names= models.CharField(max_length=500) total_pro...
0
0
0
450
0
0
0
41
89
ff4968e83e42959d231483637e223fcbbab5bb11
2,437
py
Python
OnlineHeart.py
zhaoqq4/bilibili-live-tools
b61c3ccf20c7bf5cae9e705258651e78ed4886d0
[ "MIT" ]
2
2019-11-18T07:54:17.000Z
2020-04-15T03:24:52.000Z
OnlineHeart.py
zhaoqq4/bilibili-live-tools
b61c3ccf20c7bf5cae9e705258651e78ed4886d0
[ "MIT" ]
null
null
null
OnlineHeart.py
zhaoqq4/bilibili-live-tools
b61c3ccf20c7bf5cae9e705258651e78ed4886d0
[ "MIT" ]
1
2019-04-24T14:33:49.000Z
2019-04-24T14:33:49.000Z
# ,,
37.492308
107
0.539598
from bilibili import bilibili from login import login import time import datetime import asyncio from printer import Printer def CurrentTime(): currenttime = int(time.mktime(datetime.datetime.now().timetuple())) return str(currenttime) class OnlineHeart(): async def apppost_heartbeat(self): awa...
228
0
1,948
-1
0
97
0
-7
312
6e645357ab662bd0d18a805145e739fa2992aed6
5,515
py
Python
libcloud/resource/lb/drivers/rackspace.py
epolyan/libcloud
45cf7c65498ac338d8e211e625a7900352a29a20
[ "Apache-2.0" ]
1
2019-06-26T22:47:33.000Z
2019-06-26T22:47:33.000Z
libcloud/resource/lb/drivers/rackspace.py
epolyan/libcloud
45cf7c65498ac338d8e211e625a7900352a29a20
[ "Apache-2.0" ]
null
null
null
libcloud/resource/lb/drivers/rackspace.py
epolyan/libcloud
45cf7c65498ac338d8e211e625a7900352a29a20
[ "Apache-2.0" ]
null
null
null
# Licensed to the Apache Software Foundation (ASF) under one or more # contributor license agreements. See the NOTICE file distributed with # this work for additional information regarding copyright ownership. # The ASF licenses this file to You under the Apache License, Version 2.0 # (the "License"); you may not use ...
33.628049
80
0.599819
# Licensed to the Apache Software Foundation (ASF) under one or more # contributor license agreements. See the NOTICE file distributed with # this work for additional information regarding copyright ownership. # The ASF licenses this file to You under the Apache License, Version 2.0 # (the "License"); you may not use ...
0
0
0
4,344
0
0
0
130
233
02117903ce1d2d7f42712f62b3d73542777dd9d1
10,420
py
Python
abu/UtilBu/ABuFileUtil.py
zhengfaning/vnpy_andy
403d48768d5915188537aaf376b172b35c8e2999
[ "MIT" ]
1
2019-05-28T05:54:42.000Z
2019-05-28T05:54:42.000Z
abu/UtilBu/ABuFileUtil.py
zhengfaning/vnpy_andy
403d48768d5915188537aaf376b172b35c8e2999
[ "MIT" ]
9
2020-03-24T16:45:25.000Z
2022-03-11T23:40:51.000Z
abupy/UtilBu/ABuFileUtil.py
luqin/firefly
2e5ab17f2d20deb3c68c927f6208ea89db7c639d
[ "MIT" ]
1
2021-09-08T17:39:58.000Z
2021-09-08T17:39:58.000Z
# coding=utf-8 """ """ from __future__ import print_function from __future__ import division from __future__ import absolute_import import logging import os import shutil import pandas as pd # noinspection PyUnresolvedReferences from ..CoreBu.ABuFixes import pickle, Pickler, Unpickler """HDF5_COMP_LEVEL0-9""" HD...
27.277487
118
0.616987
# coding=utf-8 """ 文件处理读取写入 """ from __future__ import print_function from __future__ import division from __future__ import absolute_import import logging import os import shutil from contextlib import contextmanager import functools import pandas as pd from .ABuDTUtil import warnings_filter # noinspection PyUn...
3,378
2,469
0
0
0
395
0
38
191
df890e5e3a3c69496141d46c8ddc412f76d5199a
1,316
py
Python
extra_settings/admin.py
belkka/django-extra-settings
50b98e2ca8a703f1479e724b6df3229750f6cca9
[ "MIT" ]
null
null
null
extra_settings/admin.py
belkka/django-extra-settings
50b98e2ca8a703f1479e724b6df3229750f6cca9
[ "MIT" ]
null
null
null
extra_settings/admin.py
belkka/django-extra-settings
50b98e2ca8a703f1479e724b6df3229750f6cca9
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from django.contrib import admin from extra_settings.models import Setting admin.site.register(Setting, SettingAdmin)
29.244444
77
0.612462
# -*- coding: utf-8 -*- from django.contrib import admin from extra_settings.forms import SettingForm from extra_settings.models import Setting class SettingAdmin(admin.ModelAdmin): form = SettingForm value_fields_names = ( 'value_bool', 'value_date', 'value_datetime', 'value_decimal', 'val...
0
0
0
1,102
0
0
0
23
46
f60ecba7436bd0feccfd955d45034ff47acbac07
1,928
py
Python
boss_grabbing/spiders/company_detail.py
shansb/boss_grabbing
20aabd6b2062099eb287d7586dcf619648569ba2
[ "MIT" ]
null
null
null
boss_grabbing/spiders/company_detail.py
shansb/boss_grabbing
20aabd6b2062099eb287d7586dcf619648569ba2
[ "MIT" ]
null
null
null
boss_grabbing/spiders/company_detail.py
shansb/boss_grabbing
20aabd6b2062099eb287d7586dcf619648569ba2
[ "MIT" ]
null
null
null
#
39.346939
113
0.616183
import sqlite3 import re import scrapy from scrapy import Request # 这个类在最终整合后不再使用 class BossSpider(scrapy.Spider): # 这里是将爬虫定义为scrapy.Spider这个类下的一个实例。 # Spider这个类定义了爬虫的很多基本功能,我们直接实例化就好, # 省却了很多重写方法的麻烦。 name = 'bossDetail' # 这是爬虫的名字,这个非常重要。 # start_urls = ['https://www.zhipin.com/c101210400-p1001...
345
0
0
1,721
0
0
0
-22
110
2bc030ca5db4461ed3574d0129ac264901f570ee
1,442
py
Python
mel/lib/debugrenderer.py
aevri/mel
4451b272ddc2095f757423ff519f36fc57708ec6
[ "Apache-2.0" ]
5
2015-04-20T12:27:29.000Z
2022-02-12T21:01:39.000Z
mel/lib/debugrenderer.py
aevri/mel
4451b272ddc2095f757423ff519f36fc57708ec6
[ "Apache-2.0" ]
27
2016-06-20T15:02:03.000Z
2022-03-29T06:23:01.000Z
mel/lib/debugrenderer.py
aevri/mel
4451b272ddc2095f757423ff519f36fc57708ec6
[ "Apache-2.0" ]
3
2015-12-27T12:33:34.000Z
2019-07-23T04:05:47.000Z
"""A global object for debug rendering into images without around.""" # ----------------------------------------------------------------------------- # Copyright (C) 2018 Angelos Evripiotis. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the ...
29.428571
79
0.549237
"""A global object for debug rendering into images without around.""" import cv2 class GlobalContext: def __init__(self): self._image = None def arrow(self, from_, to): if self._image is None: return cv2.arrowedLine( self._image, tuple(from_.astype...
0
0
0
587
0
0
0
-11
46
4a924f7c51faa62d6417829f67ab54a1b247bf48
44,034
py
Python
dist/Basilisk/simulation/ephemeris_converter/ephemeris_converter.py
ian-cooke/basilisk_mag
a8b1e37c31c1287549d6fd4d71fcaa35b6fc3f14
[ "0BSD" ]
null
null
null
dist/Basilisk/simulation/ephemeris_converter/ephemeris_converter.py
ian-cooke/basilisk_mag
a8b1e37c31c1287549d6fd4d71fcaa35b6fc3f14
[ "0BSD" ]
1
2019-03-13T20:52:22.000Z
2019-03-13T20:52:22.000Z
dist/Basilisk/simulation/ephemeris_converter/ephemeris_converter.py
ian-cooke/basilisk_mag
a8b1e37c31c1287549d6fd4d71fcaa35b6fc3f14
[ "0BSD" ]
null
null
null
# This file was automatically generated by SWIG (http://www.swig.org). # Version 3.0.12 # # Do not make changes to this file unless you know what you are doing--modify # the SWIG interface file instead. from sys import version_info as _swig_python_version_info if _swig_python_version_info >= (2, 7, 0): _ephemeris_...
34.42846
165
0.734569
# This file was automatically generated by SWIG (http://www.swig.org). # Version 3.0.12 # # Do not make changes to this file unless you know what you are doing--modify # the SWIG interface file instead. from sys import version_info as _swig_python_version_info if _swig_python_version_info >= (2, 7, 0): def swig_im...
0
0
0
34,986
0
4,494
0
0
974
a082ba62d382fcbf529a314f3081363baba0a629
5,761
py
Python
monty/exts/info/_global_source_snekcode.py
onerandomusername/monty-python
fcd8b2827eb9bbb2a05d28f80ac9e215589f03f7
[ "MIT" ]
20
2021-12-31T10:17:20.000Z
2022-03-31T04:16:17.000Z
monty/exts/info/_global_source_snekcode.py
onerandomusername/monty-bot
b1c769e44b56bc45f37fc809064571d59c80db27
[ "MIT" ]
1
2022-03-13T22:34:33.000Z
2022-03-13T22:34:52.000Z
monty/exts/info/_global_source_snekcode.py
onerandomusername/monty-bot
b1c769e44b56bc45f37fc809064571d59c80db27
[ "MIT" ]
3
2022-01-02T15:21:46.000Z
2022-03-05T09:37:54.000Z
""" Do not import this file. NOTE: THIS RUNS ON PYTHON 3.10 """ # exit codes: # 0: success # 1: indeterminate error # 2: module not resolvable # 3: attribute does not exist # 4: invalid characters, not a valid object path # 5: dynamically created object # 6: is a builtin object, prints module name # 7: invalid metad...
33.109195
116
0.583753
""" Do not import this file. NOTE: THIS RUNS ON PYTHON 3.10 """ # exit codes: # 0: success # 1: indeterminate error # 2: module not resolvable # 3: attribute does not exist # 4: invalid characters, not a valid object path # 5: dynamically created object # 6: is a builtin object, prints module name # 7: invalid metad...
0
0
0
0
0
0
0
0
0
e5190fa81eba75de95857797fc1d9f5bde486ef3
388
py
Python
config/settings/local.py
jhurtadojerves/product-hunt
4e7df9c038852db22e71717120699ef9bc5edd36
[ "MIT" ]
null
null
null
config/settings/local.py
jhurtadojerves/product-hunt
4e7df9c038852db22e71717120699ef9bc5edd36
[ "MIT" ]
null
null
null
config/settings/local.py
jhurtadojerves/product-hunt
4e7df9c038852db22e71717120699ef9bc5edd36
[ "MIT" ]
null
null
null
DEBUG = True ALLOWED_HOSTS = ['*'] THIRD_PARTY_APPS += ('debug_toolbar',) # Database # https://docs.djangoproject.com/en/2.0/ref/settings/#databases MIDDLEWARE.insert(3, 'debug_toolbar.middleware.DebugToolbarMiddleware') DATABASES = { 'default': { 'ENGINE': 'django.db.backends.sqlite3', 'NAME'...
19.4
71
0.670103
from .base import * DEBUG = True ALLOWED_HOSTS = ['*'] THIRD_PARTY_APPS += ('debug_toolbar',) # Database # https://docs.djangoproject.com/en/2.0/ref/settings/#databases MIDDLEWARE.insert(3, 'debug_toolbar.middleware.DebugToolbarMiddleware') DATABASES = { 'default': { 'ENGINE': 'django.db.backends.sqli...
0
0
0
0
0
0
0
-2
22
ac0af079ef583a59891bbe099e537166e62e4e80
845
py
Python
devel/create_workspace.py
magland/sortingview
0b1be9d55048cd4b8a0b6b6733bd7d35cb440aa7
[ "Apache-2.0" ]
2
2021-11-19T04:51:42.000Z
2022-03-12T23:36:19.000Z
devel/create_workspace.py
magland/sortingview
0b1be9d55048cd4b8a0b6b6733bd7d35cb440aa7
[ "Apache-2.0" ]
172
2021-05-10T17:39:15.000Z
2022-03-18T21:46:15.000Z
devel/create_workspace.py
magland/sortingview
0b1be9d55048cd4b8a0b6b6733bd7d35cb440aa7
[ "Apache-2.0" ]
2
2021-08-29T20:13:57.000Z
2022-03-12T23:36:34.000Z
import sortingview as sv import spikeextractors as se recording, sorting = se.example_datasets.toy_example(K=11, duration=60, seed=6) R = sv.LabboxEphysRecordingExtractor.from_memory(recording, serialize=True, serialize_dtype='float32') S = sv.LabboxEphysSortingExtractor.from_memory(sorting, serialize=True) W = sv.c...
36.73913
135
0.808284
import sortingview as sv import spikeextractors as se recording, sorting = se.example_datasets.toy_example(K=11, duration=60, seed=6) R = sv.LabboxEphysRecordingExtractor.from_memory(recording, serialize=True, serialize_dtype='float32') S = sv.LabboxEphysSortingExtractor.from_memory(sorting, serialize=True) W = sv.c...
0
0
0
0
0
0
0
0
0
676081027b43c842e587bf0a13ec035d57f5746b
2,182
py
Python
django_rest_multitokenauth/models.py
anx-mfischer/django-rest-multitokenauth
ccdf059f8409f55f8c5d908a27cb887a2da9fd5f
[ "BSD-3-Clause" ]
3
2020-11-24T03:00:31.000Z
2021-07-04T20:21:31.000Z
django_rest_multitokenauth/models.py
anx-mfischer/django-rest-multitokenauth
ccdf059f8409f55f8c5d908a27cb887a2da9fd5f
[ "BSD-3-Clause" ]
8
2020-01-14T17:15:21.000Z
2021-11-05T13:59:35.000Z
django_rest_multitokenauth/models.py
anx-mfischer/django-rest-multitokenauth
ccdf059f8409f55f8c5d908a27cb887a2da9fd5f
[ "BSD-3-Clause" ]
5
2020-06-12T06:21:42.000Z
2021-10-08T07:52:49.000Z
from django.conf import settings __all__ = [ 'MultiToken', ] # Prior to Django 1.5, the AUTH_USER_MODEL setting does not exist. # Note that we don't perform this code in the compat module due to # bug report #1297 # See: https://github.com/tomchristie/django-rest-framework/issues/1297 AUTH_USER_MODEL = getattr(s...
27.974359
84
0.634739
import binascii import os from django.conf import settings from django.db import models from django.utils.translation import ugettext_lazy as _ __all__ = [ 'MultiToken', ] # Prior to Django 1.5, the AUTH_USER_MODEL setting does not exist. # Note that we don't perform this code in the compat module due to # bug r...
0
158
0
1,528
0
0
0
23
111
4499bc7cf3785258e6fbb00a6f9ad2f3223bd15f
29,306
py
Python
qpp_ref.py
Zendelo/IRQPP
fdcc11743cd83517363570efe99e03ddf57cc2a1
[ "MIT" ]
2
2020-09-30T12:38:07.000Z
2021-04-01T06:59:56.000Z
qpp_ref.py
Zendelo/IRQPP
fdcc11743cd83517363570efe99e03ddf57cc2a1
[ "MIT" ]
null
null
null
qpp_ref.py
Zendelo/IRQPP
fdcc11743cd83517363570efe99e03ddf57cc2a1
[ "MIT" ]
null
null
null
import argparse import os import numpy as np import pandas as pd from qpputils import dataparser as dp from Timer import Timer LAMBDA = np.linspace(start=0, stop=1, num=11) C_PARAMETERS = [0.01, 0.1, 1, 10] PREDICTORS_WO_QF = ['clarity', 'wig', 'nqc', 'smv', 'rsd', 'uef/clarity', 'uef/wig', 'uef/nqc', 'uef/smv'] PR...
50.878472
120
0.644203
import argparse import glob import itertools import multiprocessing as mp import os from functools import partial from subprocess import run import numpy as np import pandas as pd from qpputils import dataparser as dp from Timer import Timer from crossval import InterTopicCrossValidation from query_features import fe...
0
5,113
0
17,138
0
3,891
0
51
338
30a884640a621c0f4dbfca2f8f5470da114c2391
1,649
py
Python
src/setup.py
salimfadhley/neowrapper
54116d099f4d6e5559931bf5f6a1dace4d847f38
[ "MIT" ]
null
null
null
src/setup.py
salimfadhley/neowrapper
54116d099f4d6e5559931bf5f6a1dace4d847f38
[ "MIT" ]
null
null
null
src/setup.py
salimfadhley/neowrapper
54116d099f4d6e5559931bf5f6a1dace4d847f38
[ "MIT" ]
null
null
null
from setuptools import setup import os import sys SRC_ROOT, _ = os.path.split(__file__) PROJECT_ROOT = os.path.dirname(SRC_ROOT) REVISION = '0.0.1' PROJECT_NAME = 'neowrapper' PROJECT_AUTHORS = "Salim Fadhley" # Please see readme.rst for a complete list of contributors PROJECT_EMAILS = 'salimfadhley@gmail.com' PROJEC...
27.949153
70
0.634324
from setuptools import setup import os import sys SRC_ROOT, _ = os.path.split(__file__) PROJECT_ROOT = os.path.dirname(SRC_ROOT) REVISION = '0.0.1' PROJECT_NAME = 'neowrapper' PROJECT_AUTHORS = "Salim Fadhley" # Please see readme.rst for a complete list of contributors PROJECT_EMAILS = 'salimfadhley@gmail.com' PROJEC...
0
0
0
0
0
0
0
0
0
79b97d03ccf4dbab70af627b1932d5c08cc2c0ed
1,728
py
Python
pythonit_toolkit/pastaporto/entities.py
pythonitalia/pythonit-toolkit
373f703bff0b573c0aa9993868d5a4770d3a2dc1
[ "MIT" ]
56
2018-01-20T17:18:40.000Z
2022-03-28T22:42:04.000Z
toolkit/pythonit_toolkit/pastaporto/entities.py
pythonitalia/pycon
14e03b2158916f9437fdbde70e48e5bf5266997e
[ "MIT" ]
2,029
2018-01-20T11:37:24.000Z
2022-03-31T04:10:51.000Z
pythonit_toolkit/pastaporto/entities.py
pythonitalia/pythonit-toolkit
373f703bff0b573c0aa9993868d5a4770d3a2dc1
[ "MIT" ]
17
2018-03-17T09:44:28.000Z
2021-12-27T19:57:35.000Z
from __future__ import annotations
24.685714
85
0.661458
from __future__ import annotations from dataclasses import dataclass, field from enum import Enum from typing import Any, Optional import jwt from .exceptions import InvalidPastaportoError from .tokens import decode_pastaporto class Credential(str, Enum): AUTHENTICATED = "authenticated" STAFF = "staff" ...
0
1,091
0
311
0
0
0
60
227
360985d17336c167eab4044ad7e51e3f794f7757
2,333
py
Python
socialsim/apps/main/models.py
Harryonismyname/SocialSim
d1c9c8f1aadbf4aaa761d590269a6d60558470f5
[ "MIT" ]
null
null
null
socialsim/apps/main/models.py
Harryonismyname/SocialSim
d1c9c8f1aadbf4aaa761d590269a6d60558470f5
[ "MIT" ]
null
null
null
socialsim/apps/main/models.py
Harryonismyname/SocialSim
d1c9c8f1aadbf4aaa761d590269a6d60558470f5
[ "MIT" ]
null
null
null
# Create your models here.
48.604167
192
0.739391
from re import error from django.db import models from ..login.models import User # Create your models here. class CharacterManager(models.Manager): def character_validator(self, postData): errors = {} if len(postData['first_name'])<1: errors['noName'] = 'Please enter a name' re...
0
0
0
2,110
0
0
0
16
181
0ff026c02ac3218cee4c841a548d710b08845fe6
986
py
Python
net/migrations/0016_equipmentsuggestcredentials.py
dehu4ka/lna
f5ee176bdb5c7507b76fba5ae651ce333b71c3db
[ "MIT" ]
null
null
null
net/migrations/0016_equipmentsuggestcredentials.py
dehu4ka/lna
f5ee176bdb5c7507b76fba5ae651ce333b71c3db
[ "MIT" ]
null
null
null
net/migrations/0016_equipmentsuggestcredentials.py
dehu4ka/lna
f5ee176bdb5c7507b76fba5ae651ce333b71c3db
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by Django 1.11.2 on 2017-07-03 07:24 from __future__ import unicode_literals
34
133
0.616633
# -*- coding: utf-8 -*- # Generated by Django 1.11.2 on 2017-07-03 07:24 from __future__ import unicode_literals from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('net', '0015_auto_20170702_2210'), ] operations = [...
0
0
0
774
0
0
0
30
68
c0aefa9cb92705a6d2af447d674fb79f3c5da767
59
py
Python
{{cookiecutter.project_name}}/api/app/constants/aws_errors.py
seantbaier/fullstack-react-fastapi-dynamodb
3ab1c806b1b7684ba2509463563a0221118506d3
[ "MIT" ]
null
null
null
{{cookiecutter.project_name}}/api/app/constants/aws_errors.py
seantbaier/fullstack-react-fastapi-dynamodb
3ab1c806b1b7684ba2509463563a0221118506d3
[ "MIT" ]
null
null
null
{{cookiecutter.project_name}}/api/app/constants/aws_errors.py
seantbaier/fullstack-react-fastapi-dynamodb
3ab1c806b1b7684ba2509463563a0221118506d3
[ "MIT" ]
null
null
null
RESOURCE_NOT_FOUND_EXCEPTION = "ResourceNotFoundException"
29.5
58
0.898305
RESOURCE_NOT_FOUND_EXCEPTION = "ResourceNotFoundException"
0
0
0
0
0
0
0
0
0
25c8a4ffbd0b78a2d9282f40b59bb59aab41b94b
2,697
py
Python
cmaes/optim_L2M2019Ctrl_2D.py
mcmips/osim-rl
610b95cf0c4484f1acecd31187736b0113dcfb73
[ "MIT" ]
867
2017-01-21T20:53:36.000Z
2022-03-20T09:47:08.000Z
cmaes/optim_L2M2019Ctrl_2D.py
mcmips/osim-rl
610b95cf0c4484f1acecd31187736b0113dcfb73
[ "MIT" ]
197
2017-01-22T21:27:36.000Z
2022-01-10T16:18:35.000Z
cmaes/optim_L2M2019Ctrl_2D.py
mcmips/osim-rl
610b95cf0c4484f1acecd31187736b0113dcfb73
[ "MIT" ]
277
2017-02-01T18:42:18.000Z
2022-03-23T11:30:31.000Z
import numpy as np trial_name = 'trial_190501_L2M2019CtrlEnv_2D_' params = np.ones(37) #params = np.loadtxt('./data/cma/trial_181029_walk_3D_noStand_8_best.txt') if __name__ == '__main__': prob = CMATrain() from cmaes.solver_cma import CMASolver solver = CMASolver(prob) solver.options.set("popsize"...
31.360465
121
0.60178
from osim.env import L2M2019CtrlEnv from osim.control.osim_loco_reflex_song2019 import OsimReflexCtrl import sys import numpy as np trial_name = 'trial_190501_L2M2019CtrlEnv_2D_' class CMATrain(object): def __init__(self, ): self.n_f_call = 0 self.best_total_reward = -np.inf self.flag_mo...
0
0
0
1,984
0
0
0
47
90
f53badafa9e6234f22945066f24e56e6a8901b63
282
py
Python
pacman-termux/test/pacman/tests/querycheck_fast_file_type.py
Maxython/pacman-for-termux
3b208eb9274cbfc7a27fca673ea8a58f09ebad47
[ "MIT" ]
23
2021-05-21T19:11:06.000Z
2022-03-31T18:14:20.000Z
source/pacman-6.0.1/test/pacman/tests/querycheck_fast_file_type.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
11
2021-05-21T12:08:44.000Z
2021-12-21T08:30:08.000Z
source/pacman-6.0.1/test/pacman/tests/querycheck_fast_file_type.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
1
2021-09-26T08:44:40.000Z
2021-09-26T08:44:40.000Z
self.description = "check file type without mtree" self.filesystem = [ "bar/", "foo -> bar/" ] pkg = pmpkg("dummy") pkg.files = [ "foo/" ] self.addpkg2db("local",pkg) self.args = "-Qk" self.addrule("PACMAN_RETCODE=1") self.addrule("PACMAN_OUTPUT=warning.*(File type mismatch)")
21.692308
59
0.677305
self.description = "check file type without mtree" self.filesystem = [ "bar/", "foo -> bar/" ] pkg = pmpkg("dummy") pkg.files = [ "foo/" ] self.addpkg2db("local",pkg) self.args = "-Qk" self.addrule("PACMAN_RETCODE=1") self.addrule("PACMAN_OUTPUT=warning.*(File type mismatch)")
0
0
0
0
0
0
0
0
0
16a55c0e3927ddc84d35389a18aa2e8779ead4b3
154
py
Python
basepy/libs/logger.py
glenacota/basepy
c51883dff1a92486be966b70a950502a862fd7cb
[ "MIT" ]
null
null
null
basepy/libs/logger.py
glenacota/basepy
c51883dff1a92486be966b70a950502a862fd7cb
[ "MIT" ]
1
2021-01-10T20:43:43.000Z
2021-01-10T20:43:43.000Z
basepy/libs/logger.py
glenacota/basepy
c51883dff1a92486be966b70a950502a862fd7cb
[ "MIT" ]
null
null
null
"""Logger """ import logging import logging.config logging.config.fileConfig("logging.ini")
11.846154
45
0.727273
"""Logger """ import logging import logging.config logging.config.fileConfig("logging.ini") def log(): return logging.getLogger("defaultLogger")
0
0
0
0
0
35
0
0
23
7cb42dcb4878f5eea333aacdcea96fbfbdba501d
20,865
py
Python
src/cozmo/annotate.py
wmh123456789/cozmo-python-wmh
ce66a1b22d75c086e413d61cea9b65ade6aefa24
[ "Apache-2.0" ]
null
null
null
src/cozmo/annotate.py
wmh123456789/cozmo-python-wmh
ce66a1b22d75c086e413d61cea9b65ade6aefa24
[ "Apache-2.0" ]
null
null
null
src/cozmo/annotate.py
wmh123456789/cozmo-python-wmh
ce66a1b22d75c086e413d61cea9b65ade6aefa24
[ "Apache-2.0" ]
null
null
null
# Copyright (c) 2016-2017 Anki, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License in the file LICENSE.txt or at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by appli...
36.098616
100
0.638917
# Copyright (c) 2016-2017 Anki, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License in the file LICENSE.txt or at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by appli...
0
80
0
15,442
0
140
0
-7
278
a889917e4af1f1b70c643c40ae9292d5dcd9b175
4,675
py
Python
unittest/unittest.py
mfkiwl/coast-compilerAssistedSoftwareFaultTolerance
397a26ecdb01e7c329884d12c9f6bb2a05c3abc9
[ "MIT" ]
12
2019-08-19T17:05:17.000Z
2022-03-21T23:07:41.000Z
unittest/unittest.py
mfkiwl/coast-compilerAssistedSoftwareFaultTolerance
397a26ecdb01e7c329884d12c9f6bb2a05c3abc9
[ "MIT" ]
3
2020-02-13T12:46:07.000Z
2022-03-23T22:48:29.000Z
unittest/unittest.py
mfkiwl/coast-compilerAssistedSoftwareFaultTolerance
397a26ecdb01e7c329884d12c9f6bb2a05c3abc9
[ "MIT" ]
7
2019-04-23T13:52:28.000Z
2021-09-23T03:49:16.000Z
import pathlib COAST_dir = pathlib.Path(__file__).resolve().parent.parent tests_dir = COAST_dir / "tests" if __name__ == "__main__": main()
32.241379
91
0.588449
import sys import argparse import pathlib import yaml import subprocess import re COAST_dir = pathlib.Path(__file__).resolve().parent.parent tests_dir = COAST_dir / "tests" class bcolors: HEADER = '\033[95m' OKBLUE = '\033[94m' OKGREEN = '\033[92m' WARNING = '\033[93m' FAIL = '\033[91m' ENDC =...
0
0
0
2,451
0
1,872
0
-43
248