hexsha
stringlengths
40
40
size
int64
4
996k
ext
stringclasses
8 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
245
max_stars_repo_name
stringlengths
6
130
max_stars_repo_head_hexsha
stringlengths
40
40
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
4
245
max_issues_repo_name
stringlengths
6
130
max_issues_repo_head_hexsha
stringlengths
40
40
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
67k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
4
245
max_forks_repo_name
stringlengths
6
130
max_forks_repo_head_hexsha
stringlengths
40
40
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
4
996k
avg_line_length
float64
1.33
58.2k
max_line_length
int64
2
323k
alphanum_fraction
float64
0
0.97
content_no_comment
stringlengths
0
946k
is_comment_constant_removed
bool
2 classes
is_sharp_comment_removed
bool
1 class
f727740bd33f10993c9982599ba782f10061bf7f
2,831
py
Python
Bigeleisen_KIE.py
valkenzz/Bigeleisen_KIE
aa82ee63c77be2e9d0bd97702c297aa70dfaa362
[ "MIT" ]
1
2021-06-25T22:48:39.000Z
2021-06-25T22:48:39.000Z
Bigeleisen_KIE.py
valkenzz/Bigeleisen_KIE
aa82ee63c77be2e9d0bd97702c297aa70dfaa362
[ "MIT" ]
null
null
null
Bigeleisen_KIE.py
valkenzz/Bigeleisen_KIE
aa82ee63c77be2e9d0bd97702c297aa70dfaa362
[ "MIT" ]
null
null
null
#Importation : import pandas as pd import numpy as np ################################################ #Parameters : #Planck constant (J/Hz) h=6.62607004*10**-34 #Boltzmann constant (J/K) kB=1.38064852*10**-23 #Light velocity in vaccum (m/s) c=299792458.0 #################################################...
37.746667
131
0.585306
import pandas as pd import numpy as np
true
true
f727743056c35927215b3d1cff28914c0160ba53
1,714
py
Python
examples/python/modulation-example.py
ideoforms/signalflow
1283cdf565d004495f1561d4d0683d51c11da50a
[ "MIT" ]
61
2020-10-12T11:46:09.000Z
2022-02-07T04:26:05.000Z
examples/python/modulation-example.py
ideoforms/signalflow
1283cdf565d004495f1561d4d0683d51c11da50a
[ "MIT" ]
26
2020-10-07T20:25:26.000Z
2022-03-25T11:40:57.000Z
examples/python/modulation-example.py
ideoforms/signalflow
1283cdf565d004495f1561d4d0683d51c11da50a
[ "MIT" ]
6
2021-02-27T19:50:25.000Z
2021-11-09T11:02:20.000Z
#!/usr/bin/env python3 #------------------------------------------------------------------------ # SignalFlow: Modulation example. #------------------------------------------------------------------------ from signalflow import * #------------------------------------------------------------------------ # Create the g...
41.804878
73
0.351225
from signalflow import * graph = AudioGraph(start=True) graph.show_status(1) clock = Impulse(8) frequency = ScaleLinExp(SawLFO(0.2), 0, 1, 200, 2000) sample_hold = SampleAndHold(frequency, clock) sine = TriangleOscillator(sample_hold) * 0.5 env = EnvelopeASR(attack=0.001, sustain=0.001, release=0.1, clock=...
true
true
f7277478cfed614fa4d55c97d1352a6fcb46bccc
2,908
py
Python
cifar10/custom_models.py
apexnetai/cifar-10-guide
7c76f310e93da3a229ce9d66defd770ee1c7dc56
[ "Apache-2.0" ]
null
null
null
cifar10/custom_models.py
apexnetai/cifar-10-guide
7c76f310e93da3a229ce9d66defd770ee1c7dc56
[ "Apache-2.0" ]
null
null
null
cifar10/custom_models.py
apexnetai/cifar-10-guide
7c76f310e93da3a229ce9d66defd770ee1c7dc56
[ "Apache-2.0" ]
null
null
null
import torch import torch.nn as nn import torch.nn.functional as F import torchvision class CustomResnetV1(nn.Module): def __init__(self): super(CustomResnetV1, self).__init__() self.resnet = torchvision.models.resnet18(pretrained=True) self.resnet.conv1 = nn.Conv2d(3, 64, kernel_size=(3...
29.979381
107
0.532669
import torch import torch.nn as nn import torch.nn.functional as F import torchvision class CustomResnetV1(nn.Module): def __init__(self): super(CustomResnetV1, self).__init__() self.resnet = torchvision.models.resnet18(pretrained=True) self.resnet.conv1 = nn.Conv2d(3, 64, kernel_size=(3...
true
true
f72776a94e62bdff703e0bd58ce268bc183b1b92
8,160
py
Python
grr/lib/builders/osx.py
ethicalhackeragnidhra/Grr
9ff9178396d9d16575e42dded33627cb09ac3af1
[ "Apache-2.0" ]
1
2020-12-18T00:47:19.000Z
2020-12-18T00:47:19.000Z
grr/lib/builders/osx.py
ethicalhackeragnidhra/Grr
9ff9178396d9d16575e42dded33627cb09ac3af1
[ "Apache-2.0" ]
null
null
null
grr/lib/builders/osx.py
ethicalhackeragnidhra/Grr
9ff9178396d9d16575e42dded33627cb09ac3af1
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python """An implementation of an OSX client builder.""" import logging import os import shutil import StringIO import subprocess import zipfile from grr import config from grr.lib import build from grr.lib import config_lib from grr.lib import utils class DarwinClientBuilder(build.ClientBuilder): "...
39.804878
80
0.684191
"""An implementation of an OSX client builder.""" import logging import os import shutil import StringIO import subprocess import zipfile from grr import config from grr.lib import build from grr.lib import config_lib from grr.lib import utils class DarwinClientBuilder(build.ClientBuilder): """Builder class for t...
false
true
f7277809d5c13e30181663ab40928852ffba8dea
2,031
py
Python
nyuki/geotiff_reprojector.py
raghuramdr/nyuki
664d3a955ae765214a42e8dbeb009029d5600c15
[ "MIT" ]
null
null
null
nyuki/geotiff_reprojector.py
raghuramdr/nyuki
664d3a955ae765214a42e8dbeb009029d5600c15
[ "MIT" ]
null
null
null
nyuki/geotiff_reprojector.py
raghuramdr/nyuki
664d3a955ae765214a42e8dbeb009029d5600c15
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """Console script for geotiff_reprojector.""" import sys import os import click import rasterio from rasterio.warp import calculate_default_transform, reproject, Resampling def reprojector(sourcefile, target_epsg='EPSG:4326', yes=False): # load file to get epsg info. dat = rasterio.op...
32.758065
141
0.58001
import sys import os import click import rasterio from rasterio.warp import calculate_default_transform, reproject, Resampling def reprojector(sourcefile, target_epsg='EPSG:4326', yes=False): dat = rasterio.open(sourcefile) targetfile = os.path.basename(sourcefile).split('.')[0] \ ...
true
true
f72779a298c969c64055451d767bd20d007cf308
576
py
Python
django_todos/migrations/0005_list_createdat.py
cxhandley/django-ddp-todos
e752133e31c901aba2ca056d16dc2022c57da823
[ "MIT" ]
2
2015-09-27T13:13:31.000Z
2015-09-28T01:16:11.000Z
django_todos/migrations/0005_list_createdat.py
cxhandley/django-ddp-todos-V2
e752133e31c901aba2ca056d16dc2022c57da823
[ "MIT" ]
null
null
null
django_todos/migrations/0005_list_createdat.py
cxhandley/django-ddp-todos-V2
e752133e31c901aba2ca056d16dc2022c57da823
[ "MIT" ]
1
2015-12-27T15:43:42.000Z
2015-12-27T15:43:42.000Z
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import models, migrations import datetime from django.utils.timezone import utc class Migration(migrations.Migration): dependencies = [ ('django_todos', '0004_auto_20150909_1213'), ] operations = [ migrations...
25.043478
130
0.647569
from __future__ import unicode_literals from django.db import models, migrations import datetime from django.utils.timezone import utc class Migration(migrations.Migration): dependencies = [ ('django_todos', '0004_auto_20150909_1213'), ] operations = [ migrations.AddField( ...
true
true
f72779dd707f715614f9cebb5334c248393f7004
90
py
Python
03_operator/03_operator.py
Jasper-Li/PythonTutorial
270d18a1830ae74eaa6fc797a6d4f672688f1cee
[ "CC0-1.0" ]
null
null
null
03_operator/03_operator.py
Jasper-Li/PythonTutorial
270d18a1830ae74eaa6fc797a6d4f672688f1cee
[ "CC0-1.0" ]
null
null
null
03_operator/03_operator.py
Jasper-Li/PythonTutorial
270d18a1830ae74eaa6fc797a6d4f672688f1cee
[ "CC0-1.0" ]
null
null
null
# 03 operator print(4+3) print(4-3) print(4*3) print(4 ** 3) # 这个小学没学 print(4/3)
11.25
24
0.566667
print(4+3) print(4-3) print(4*3) print(4 ** 3) print(4/3)
true
true
f7277a1c322b021d0f7590078adba406bb5b75a3
13,460
py
Python
utils/Finger/tool/tools.py
zxpzhong/DR_3DFM
6ef7d0d86813f4cc407a0d1011a2623e4775fbee
[ "MIT" ]
1
2021-01-19T01:44:47.000Z
2021-01-19T01:44:47.000Z
utils/Finger/tool/tools.py
zxpzhong/DR_3DFM
6ef7d0d86813f4cc407a0d1011a2623e4775fbee
[ "MIT" ]
null
null
null
utils/Finger/tool/tools.py
zxpzhong/DR_3DFM
6ef7d0d86813f4cc407a0d1011a2623e4775fbee
[ "MIT" ]
null
null
null
# 定义全局变量和方法 import numpy as np import math # import process.process_finger_data as pfd # 目前选用的图片尺寸 cur_pic_size = [640, 400] # cur_pic_size = [1280, 800] # 相机索引对应相机名称 camera_index_to_name = ['A', 'B', 'C', 'D', 'E', 'F'] # 6个相机的外参 camera_a_outer_para = np.mat([[0.574322111, 0.771054881, 0.275006333, 0.93847817], ...
52.784314
104
0.568722
import numpy as np import math cur_pic_size = [640, 400] camera_index_to_name = ['A', 'B', 'C', 'D', 'E', 'F'] camera_a_outer_para = np.mat([[0.574322111, 0.771054881, 0.275006333, 0.93847817], [0.565423192, -0.130698104, -0.814379899, -0.36935905], [-0...
true
true
f7277b8d58f1c9891a3e5c1152697cdc9322e98f
2,719
py
Python
hdfscm/tests/test_hdfsmanager_api.py
szhem/hdfscm
427e8c85fc70073d9a980e4371804523773545fb
[ "BSD-3-Clause" ]
15
2019-01-14T13:52:02.000Z
2022-02-27T13:40:38.000Z
hdfscm/tests/test_hdfsmanager_api.py
szhem/hdfscm
427e8c85fc70073d9a980e4371804523773545fb
[ "BSD-3-Clause" ]
5
2019-04-09T15:44:38.000Z
2021-04-02T07:01:11.000Z
hdfscm/tests/test_hdfsmanager_api.py
szhem/hdfscm
427e8c85fc70073d9a980e4371804523773545fb
[ "BSD-3-Clause" ]
6
2019-04-15T03:41:08.000Z
2022-03-07T22:48:50.000Z
import nbformat from notebook.services.contents.tests.test_contents_api import ( APITest, assert_http_error ) from traitlets.config import Config from hdfscm import HDFSContentsManager from hdfscm.utils import to_fs_path from .conftest import random_root_dir class HDFSContentsAPITest(APITest): hidden_dirs =...
29.554348
80
0.681868
import nbformat from notebook.services.contents.tests.test_contents_api import ( APITest, assert_http_error ) from traitlets.config import Config from hdfscm import HDFSContentsManager from hdfscm.utils import to_fs_path from .conftest import random_root_dir class HDFSContentsAPITest(APITest): hidden_dirs =...
true
true
f7277cc36cfb1076bc786e7c041456ee46c61223
379
py
Python
setup.py
CesarCaballeroGaudes/phys2denoise
a86baefb62a45721eaa132b1d47fe6c4a0979f35
[ "Apache-2.0" ]
7
2020-06-18T04:31:18.000Z
2022-03-01T14:54:18.000Z
setup.py
CesarCaballeroGaudes/phys2denoise
a86baefb62a45721eaa132b1d47fe6c4a0979f35
[ "Apache-2.0" ]
32
2020-05-01T18:56:11.000Z
2021-08-18T15:09:22.000Z
setup.py
CesarCaballeroGaudes/phys2denoise
a86baefb62a45721eaa132b1d47fe6c4a0979f35
[ "Apache-2.0" ]
10
2020-03-23T11:24:40.000Z
2021-11-22T12:55:06.000Z
#!/usr/bin/env python import sys from setuptools import setup import versioneer SETUP_REQUIRES = ['setuptools >= 30.3.0'] SETUP_REQUIRES += ['wheel'] if 'bdist_wheel' in sys.argv else [] if __name__ == "__main__": setup(name='phys2denoise', setup_requires=SETUP_REQUIRES, version=versioneer.ge...
25.266667
64
0.693931
import sys from setuptools import setup import versioneer SETUP_REQUIRES = ['setuptools >= 30.3.0'] SETUP_REQUIRES += ['wheel'] if 'bdist_wheel' in sys.argv else [] if __name__ == "__main__": setup(name='phys2denoise', setup_requires=SETUP_REQUIRES, version=versioneer.get_version(), ...
true
true
f7277cee7021a14d2b5b0b8305bca5e412827cf0
710
py
Python
Timers/timers__.py
nageshnnazare/Python-Advanced-Concepts
cc5aac22799b081abd223c9a7f3c1d5557e3528f
[ "MIT" ]
null
null
null
Timers/timers__.py
nageshnnazare/Python-Advanced-Concepts
cc5aac22799b081abd223c9a7f3c1d5557e3528f
[ "MIT" ]
null
null
null
Timers/timers__.py
nageshnnazare/Python-Advanced-Concepts
cc5aac22799b081abd223c9a7f3c1d5557e3528f
[ "MIT" ]
null
null
null
#Timers # Execute code at timed intervals import time from threading import Timer def display(msg): print(msg + ' ' + time.strftime('%H:%M:%S')) #Basic timer def run_once(): display('Run Once : ') t = Timer(5, display, ['Timeout:']) t.start() run_once() print('Waiting ...') #Inter...
20.882353
53
0.622535
import time from threading import Timer def display(msg): print(msg + ' ' + time.strftime('%H:%M:%S')) def run_once(): display('Run Once : ') t = Timer(5, display, ['Timeout:']) t.start() run_once() print('Waiting ...') class RepeatTimer(Timer): def run(self): wh...
true
true
f7277e3b484818974b6db28812e583f2b833d7dd
605
py
Python
tests/mock_generator.py
jcheminform/guacamol
dd7f7b12e1ab59151394aba5f4a95ee204fd0203
[ "MIT" ]
242
2018-11-29T13:34:13.000Z
2022-03-26T19:35:17.000Z
tests/mock_generator.py
jcheminform/guacamol
dd7f7b12e1ab59151394aba5f4a95ee204fd0203
[ "MIT" ]
13
2019-01-31T03:33:36.000Z
2022-01-03T07:03:19.000Z
tests/mock_generator.py
jcheminform/guacamol
dd7f7b12e1ab59151394aba5f4a95ee204fd0203
[ "MIT" ]
68
2018-11-26T10:03:41.000Z
2022-03-28T20:58:20.000Z
from typing import List from guacamol.distribution_matching_generator import DistributionMatchingGenerator class MockGenerator(DistributionMatchingGenerator): """ Mock generator that returns pre-defined molecules, possibly split in several calls """ def __init__(self, molecules: List[str]) -> No...
27.5
82
0.707438
from typing import List from guacamol.distribution_matching_generator import DistributionMatchingGenerator class MockGenerator(DistributionMatchingGenerator): def __init__(self, molecules: List[str]) -> None: self.molecules = molecules self.cursor = 0 def generate(self, number_samples: int)...
true
true
f7277ef92647633965a12e98c00211e924095a71
158
py
Python
03_Estrutura_de_Repeticao/12_gerador_tabuada.py
gabrieldcpadilha/ListaDeExercicios-PythonBrasil
a92d477468bde5eac8987a26ea79af2ffeb6ad81
[ "MIT" ]
null
null
null
03_Estrutura_de_Repeticao/12_gerador_tabuada.py
gabrieldcpadilha/ListaDeExercicios-PythonBrasil
a92d477468bde5eac8987a26ea79af2ffeb6ad81
[ "MIT" ]
10
2020-08-19T04:31:52.000Z
2020-09-21T22:48:29.000Z
03_Estrutura_de_Repeticao/12_gerador_tabuada.py
gabrieldcpadilha/ListaDeExercicios-PythonBrasil
a92d477468bde5eac8987a26ea79af2ffeb6ad81
[ "MIT" ]
null
null
null
num = int(input('Informe o numero que voce deseja ver a tabuada: ')) print(f'Tabuada de {num}') for c in range(0, 11): print(f'{num} X {c} = {num * c}')
26.333333
68
0.607595
num = int(input('Informe o numero que voce deseja ver a tabuada: ')) print(f'Tabuada de {num}') for c in range(0, 11): print(f'{num} X {c} = {num * c}')
true
true
f7277f4bc851f4bcbda0ff622dd70c2d8c114bb2
398
py
Python
tgBCoinBot/wsgi.py
steveyout/bitc
3fb227ba35d0daa8c2337cf8761cf68a752a973d
[ "Apache-2.0" ]
1
2021-01-30T10:25:04.000Z
2021-01-30T10:25:04.000Z
tgBCoinBot/wsgi.py
steveyout/pyth
d7178c76fa1a110c3d95df48bbec555b68dad618
[ "Apache-2.0" ]
2
2020-02-12T01:28:33.000Z
2020-06-05T18:52:39.000Z
tgBCoinBot/wsgi.py
steveyout/bitc
3fb227ba35d0daa8c2337cf8761cf68a752a973d
[ "Apache-2.0" ]
null
null
null
""" WSGI config for tgBCoinBot project. It exposes the WSGI callable as a module-level variable named ``application``. For more information on this file, see https://docs.djangoproject.com/en/1.11/howto/deployment/wsgi/ """ import os from django.core.wsgi import get_wsgi_application os.environ.setdefault("DJANGO_S...
23.411765
78
0.788945
import os from django.core.wsgi import get_wsgi_application os.environ.setdefault("DJANGO_SETTINGS_MODULE", "tgBCoinBot.settings") application = get_wsgi_application()
true
true
f7277fcf10b974b66303d90351215882cab6362f
3,232
py
Python
venv/lib/python2.7/site-packages/test/test_wsgi.py
sravani-m/Web-Application-Security-Framework
d9f71538f5cba6fe1d8eabcb26c557565472f6a6
[ "MIT" ]
3
2019-04-09T22:59:33.000Z
2019-06-14T09:23:24.000Z
venv/lib/python2.7/site-packages/test/test_wsgi.py
sravani-m/Web-Application-Security-Framework
d9f71538f5cba6fe1d8eabcb26c557565472f6a6
[ "MIT" ]
null
null
null
venv/lib/python2.7/site-packages/test/test_wsgi.py
sravani-m/Web-Application-Security-Framework
d9f71538f5cba6fe1d8eabcb26c557565472f6a6
[ "MIT" ]
null
null
null
import cStringIO import sys from netlib import wsgi, odict def tflow(): h = odict.ODictCaseless() h["test"] = ["value"] req = wsgi.Request("http", "GET", "/", h, "") return wsgi.Flow(("127.0.0.1", 8888), req) class TestApp: def __init__(self): self.called = False d...
30.490566
64
0.537438
import cStringIO import sys from netlib import wsgi, odict def tflow(): h = odict.ODictCaseless() h["test"] = ["value"] req = wsgi.Request("http", "GET", "/", h, "") return wsgi.Flow(("127.0.0.1", 8888), req) class TestApp: def __init__(self): self.called = False d...
true
true
f7277fd31391e322ececec43a17017d86e45c1ec
10,296
py
Python
train.py
jojotenya/LAMOL
03c31d9f0c7bf71295bc2d362ddf40a7656956e1
[ "MIT" ]
75
2019-12-22T18:59:05.000Z
2021-09-17T06:30:38.000Z
train.py
chho33/LAMOL
03c31d9f0c7bf71295bc2d362ddf40a7656956e1
[ "MIT" ]
5
2020-05-03T10:00:05.000Z
2021-08-04T05:35:57.000Z
train.py
jojotenya/LAMOL
03c31d9f0c7bf71295bc2d362ddf40a7656956e1
[ "MIT" ]
9
2020-02-14T17:33:58.000Z
2021-06-08T06:02:13.000Z
import torch from torch.utils.data import DataLoader from torch import nn from pytorch_transformers import AdamW, WEIGHTS_NAME, WarmupLinearSchedule import csv import numpy as np import os import logging from fp16 import FP16_Module, FP16_Optimizer from parallel import DataParallelModel, DataParallelCriterion from coll...
49.263158
166
0.668512
import torch from torch.utils.data import DataLoader from torch import nn from pytorch_transformers import AdamW, WEIGHTS_NAME, WarmupLinearSchedule import csv import numpy as np import os import logging from fp16 import FP16_Module, FP16_Optimizer from parallel import DataParallelModel, DataParallelCriterion from coll...
true
true
f7278004acfca10614fa1c33b678146eff3e8f86
1,850
py
Python
scikit-learn-weighted_kde/examples/svm/plot_separating_hyperplane_unbalanced.py
RTHMaK/git-squash-master
76c4c8437dd18114968e69a698f4581927fcdabf
[ "BSD-2-Clause" ]
1
2021-11-26T12:22:13.000Z
2021-11-26T12:22:13.000Z
scikit-learn-weighted_kde/examples/svm/plot_separating_hyperplane_unbalanced.py
RTHMaK/git-squash-master
76c4c8437dd18114968e69a698f4581927fcdabf
[ "BSD-2-Clause" ]
null
null
null
scikit-learn-weighted_kde/examples/svm/plot_separating_hyperplane_unbalanced.py
RTHMaK/git-squash-master
76c4c8437dd18114968e69a698f4581927fcdabf
[ "BSD-2-Clause" ]
null
null
null
""" ================================================= SVM: Separating hyperplane for unbalanced classes ================================================= Find the optimal separating hyperplane using an SVC for classes that are unbalanced. We first find the separating plane with a plain SVC and then plot (dashed) the ...
27.205882
73
0.651351
print(__doc__) import numpy as np import matplotlib.pyplot as plt from sklearn import svm rng = np.random.RandomState(0) n_samples_1 = 1000 n_samples_2 = 100 X = np.r_[1.5 * rng.randn(n_samples_1, 2), 0.5 * rng.randn(n_samples_2, 2) + [2, 2]] y = [0] * (n_samples_1) + [1] * (n_samples_2) clf = svm.SVC(k...
true
true
f727802bb39ec646082acbc4f4eca9a79e31fb09
1,827
py
Python
base.py
thiagosouzalink/Python_Projeto-CRUD_Using_File
20bc87568f1edd69aacc3af7b493b5b2337c6544
[ "MIT" ]
null
null
null
base.py
thiagosouzalink/Python_Projeto-CRUD_Using_File
20bc87568f1edd69aacc3af7b493b5b2337c6544
[ "MIT" ]
null
null
null
base.py
thiagosouzalink/Python_Projeto-CRUD_Using_File
20bc87568f1edd69aacc3af7b493b5b2337c6544
[ "MIT" ]
null
null
null
""" FUNÇÕES BÁSICAS PARA O PROGRAMA """ from time import sleep # Imprimir caracter especial def linha(tam=40): print(f"{'='*tam}") # Recebe e valida um nome def ler_nome(txt): stop = True while stop: stop = False nome = input(txt).strip() lista_nome = nome.split() ...
21.75
71
0.523262
from time import sleep def linha(tam=40): print(f"{'='*tam}") def ler_nome(txt): stop = True while stop: stop = False nome = input(txt).strip() lista_nome = nome.split() if len(lista_nome) == 0: print("ERRO! Você digitou um nome vazio...") ...
true
true
f727809dfe02a4b21995583a93752cc365af2e33
162
py
Python
plugins/baiaozhi_cms.py
cflq3/getcms
6cf07da0ea3ec644866df715cff1f311a46ee378
[ "MIT" ]
22
2016-09-01T08:27:07.000Z
2021-01-11T13:32:59.000Z
plugins/baiaozhi_cms.py
cflq3/getcms
6cf07da0ea3ec644866df715cff1f311a46ee378
[ "MIT" ]
null
null
null
plugins/baiaozhi_cms.py
cflq3/getcms
6cf07da0ea3ec644866df715cff1f311a46ee378
[ "MIT" ]
20
2015-11-07T19:09:48.000Z
2018-05-02T03:10:41.000Z
#!/usr/bin/env python # encoding: utf-8 def run(whatweb, pluginname): whatweb.recog_from_file(pluginname, "portal/dbportal/popup/popupdiv.js", "'mozilla'")
23.142857
89
0.728395
def run(whatweb, pluginname): whatweb.recog_from_file(pluginname, "portal/dbportal/popup/popupdiv.js", "'mozilla'")
true
true
f72780a93d732aedce510f6fc8674fcf936b13b5
2,221
py
Python
test_compare_gw.py
namedyangfan/compare_gw
93d8ed205962c92c32d2cf669ee32eef18577d0e
[ "MIT" ]
null
null
null
test_compare_gw.py
namedyangfan/compare_gw
93d8ed205962c92c32d2cf669ee32eef18577d0e
[ "MIT" ]
null
null
null
test_compare_gw.py
namedyangfan/compare_gw
93d8ed205962c92c32d2cf669ee32eef18577d0e
[ "MIT" ]
null
null
null
from compare_data.compare_gw import Obs_well_hgs import unittest import os file_directory = os.path.join(os.getcwd(), 'test_data') output_folder = os.path.join(file_directory, "output") if not os.path.exists(output_folder): os.mkdir(output_folder) class TestStringMethods(unittest.TestCase): def te...
49.355556
107
0.693381
from compare_data.compare_gw import Obs_well_hgs import unittest import os file_directory = os.path.join(os.getcwd(), 'test_data') output_folder = os.path.join(file_directory, "output") if not os.path.exists(output_folder): os.mkdir(output_folder) class TestStringMethods(unittest.TestCase): def te...
true
true
f72783a0dd98fa8f7f24db93479956beeb8365a7
9,714
py
Python
operators/s3_to_mysql_operator.py
edbizarro/mysql_plugin
ce0175cec20319b996590e4d3e0ca36cf4331c10
[ "Apache-2.0" ]
15
2017-11-29T15:51:12.000Z
2022-02-09T13:19:33.000Z
operators/s3_to_mysql_operator.py
edbizarro/mysql_plugin
ce0175cec20319b996590e4d3e0ca36cf4331c10
[ "Apache-2.0" ]
5
2018-03-22T04:12:25.000Z
2019-04-30T21:14:00.000Z
operators/s3_to_mysql_operator.py
edbizarro/mysql_plugin
ce0175cec20319b996590e4d3e0ca36cf4331c10
[ "Apache-2.0" ]
20
2018-04-11T07:14:03.000Z
2021-09-14T01:17:20.000Z
from airflow.models import BaseOperator from airflow.hooks.S3_hook import S3Hook from airflow.hooks.mysql_hook import MySqlHook import dateutil.parser import json import logging class S3ToMySQLOperator(BaseOperator): """ NOTE: To avoid invalid characters, it is recommended to specify the character encodi...
40.475
109
0.50628
from airflow.models import BaseOperator from airflow.hooks.S3_hook import S3Hook from airflow.hooks.mysql_hook import MySqlHook import dateutil.parser import json import logging class S3ToMySQLOperator(BaseOperator): template_fields = ('s3_key',) def __init__(self, s3_conn_id, ...
true
true
f72783f41e43e7a6ced69380671e393ee8c3f52c
4,382
py
Python
contrib/seeds/generate-seeds.py
glemercier/Core-Smart
4ccc12a1b2a55cbad79ddee07449a5fdadf3082b
[ "MIT" ]
67
2018-05-17T21:54:01.000Z
2022-02-04T09:45:03.000Z
contrib/seeds/generate-seeds.py
glemercier/Core-Smart
4ccc12a1b2a55cbad79ddee07449a5fdadf3082b
[ "MIT" ]
11
2018-06-23T11:27:51.000Z
2021-02-20T17:54:18.000Z
contrib/seeds/generate-seeds.py
glemercier/Core-Smart
4ccc12a1b2a55cbad79ddee07449a5fdadf3082b
[ "MIT" ]
43
2018-05-09T07:27:58.000Z
2021-12-14T15:21:51.000Z
#!/usr/bin/python # Copyright (c) 2014 Wladimir J. van der Laan # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. ''' Script to generate list of seed nodes for chainparams.cpp. This script expects two text files in the directory tha...
31.52518
98
0.582611
from __future__ import print_function, division from base64 import b32decode from binascii import a2b_hex import sys, os import re pchIPv4 = bytearray([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0xff, 0xff]) pchOnionCat = bytearray([0xFD,0x87,0xD8,0x7E,0xEB,0x43]) def name_to_ipv6(addr): if len(addr)>6 and addr.endswith...
true
true
f72785479e692aec1709c88b02e8f2700f756609
1,030
py
Python
userbot/plugins/alive.py
KING-USER1/BLACK-GHOULS-USERBOT-
3db2b42e2f27ce2b4d1fce3e8f016b269e872d05
[ "MIT" ]
null
null
null
userbot/plugins/alive.py
KING-USER1/BLACK-GHOULS-USERBOT-
3db2b42e2f27ce2b4d1fce3e8f016b269e872d05
[ "MIT" ]
null
null
null
userbot/plugins/alive.py
KING-USER1/BLACK-GHOULS-USERBOT-
3db2b42e2f27ce2b4d1fce3e8f016b269e872d05
[ "MIT" ]
null
null
null
"""Check if userbot alive. If you change these, you become the gayest gay such that even the gay world will disown you.""" import asyncio from telethon import events from telethon.tl.types import ChannelParticipantsAdmins from platform import uname from userbot import ALIVE_NAME from userbot.utils import admin_cmd DE...
46.818182
122
0.683495
import asyncio from telethon import events from telethon.tl.types import ChannelParticipantsAdmins from platform import uname from userbot import ALIVE_NAME from userbot.utils import admin_cmd DEFAULTUSER = str(ALIVE_NAME) if ALIVE_NAME else "Set ALIVE_NAME in config vars in Heroku" @borg.on(admin_cmd(pattern=r"ali...
true
true
f727859e96eaa14fd00273ab0b71ffa22bdf4fcf
2,065
py
Python
web/src/contacto/views.py
DelegacionCienciasUSAL/delcien.usal.es
fbf445c05a13eaa9726b0d8823c3aa34c9334dd3
[ "Apache-2.0" ]
1
2018-12-06T19:34:12.000Z
2018-12-06T19:34:12.000Z
web/src/contacto/views.py
DelegacionCienciasUSAL/delcien.usal.es
fbf445c05a13eaa9726b0d8823c3aa34c9334dd3
[ "Apache-2.0" ]
6
2018-12-08T08:45:52.000Z
2018-12-08T08:56:19.000Z
web/src/contacto/views.py
DelegacionCienciasUSAL/delcien.usal.es
fbf445c05a13eaa9726b0d8823c3aa34c9334dd3
[ "Apache-2.0" ]
null
null
null
from django.core.mail import send_mail from django.conf import settings from django.shortcuts import render from django.http import Http404 from django.http import HttpResponseRedirect # Create your views here. def main( request): return( render( request, 'contacto/main.html', {'Titulo' : 'Contacto'})) def get_duda(...
43.020833
87
0.62954
from django.core.mail import send_mail from django.conf import settings from django.shortcuts import render from django.http import Http404 from django.http import HttpResponseRedirect def main( request): return( render( request, 'contacto/main.html', {'Titulo' : 'Contacto'})) def get_duda(request): referer = r...
true
true
f72785f26964192007bad38595a7da8e4e0b7024
629
py
Python
manage.py
BuildForSDG/frontend90
35b7297341f048b08a5ff02c7a96dad968004010
[ "MIT" ]
1
2020-11-16T11:54:29.000Z
2020-11-16T11:54:29.000Z
manage.py
BuildForSDG/frontend90
35b7297341f048b08a5ff02c7a96dad968004010
[ "MIT" ]
11
2020-05-17T18:39:21.000Z
2021-09-22T19:14:28.000Z
manage.py
BuildForSDG/frontend90
35b7297341f048b08a5ff02c7a96dad968004010
[ "MIT" ]
5
2020-05-18T11:19:44.000Z
2020-11-12T14:46:31.000Z
#!/usr/bin/env python """Django's command-line utility for administrative tasks.""" import os import sys def main(): os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'smartcity.settings') try: from django.core.management import execute_from_command_line except ImportError as exc: raise Impo...
28.590909
73
0.683625
import os import sys def main(): os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'smartcity.settings') try: from django.core.management import execute_from_command_line except ImportError as exc: raise ImportError( "Couldn't import Django. Are you sure it's installed and " ...
true
true
f72786710d226ad55e4560292df4916f0c08622e
21,421
py
Python
gupb/controller/tup_tup.py
syforcee/GUPB
f916acf94efe61c54fa7b4cc33d3f94821fdb3d7
[ "MIT" ]
null
null
null
gupb/controller/tup_tup.py
syforcee/GUPB
f916acf94efe61c54fa7b4cc33d3f94821fdb3d7
[ "MIT" ]
null
null
null
gupb/controller/tup_tup.py
syforcee/GUPB
f916acf94efe61c54fa7b4cc33d3f94821fdb3d7
[ "MIT" ]
null
null
null
import random from itertools import product from queue import SimpleQueue from typing import Dict, Type, Optional, Tuple, List, Set from gupb.controller.tup_tup_resources.trained_model import QuartersRelation, MenhirToCentreDistance, Actions, MODEL from gupb.model import arenas, coordinates, weapons, tiles, characters...
46.770742
130
0.6221
import random from itertools import product from queue import SimpleQueue from typing import Dict, Type, Optional, Tuple, List, Set from gupb.controller.tup_tup_resources.trained_model import QuartersRelation, MenhirToCentreDistance, Actions, MODEL from gupb.model import arenas, coordinates, weapons, tiles, characters...
true
true
f72786a183d595e15dd09c998f2bd8b55855c064
314
py
Python
singletask_cli/context.py
lenaKuznetsova/singletask-cli
fb7910c090ddfc8ec9a721536808396abb20bfc3
[ "MIT" ]
null
null
null
singletask_cli/context.py
lenaKuznetsova/singletask-cli
fb7910c090ddfc8ec9a721536808396abb20bfc3
[ "MIT" ]
null
null
null
singletask_cli/context.py
lenaKuznetsova/singletask-cli
fb7910c090ddfc8ec9a721536808396abb20bfc3
[ "MIT" ]
null
null
null
from singletask_sql.settings import BASE_DIR, dotenv_values from singletask_sql.engine import create_engine # todo - config after auth env_path = [ f'{BASE_DIR}/../.env', f'{BASE_DIR}/../.env.local' ] conf = {} for path in env_path: conf.update(dotenv_values(path)) sql_engine = create_engine(conf)
20.933333
59
0.72293
from singletask_sql.settings import BASE_DIR, dotenv_values from singletask_sql.engine import create_engine env_path = [ f'{BASE_DIR}/../.env', f'{BASE_DIR}/../.env.local' ] conf = {} for path in env_path: conf.update(dotenv_values(path)) sql_engine = create_engine(conf)
true
true
f7278700e1134610692fcc8ae7f5634a20a9f268
560
py
Python
tasks/migrations/0009_alter_task_org.py
jordanm88/Django-CRM
5faf22acb30aeb32f5830898fd5d8ecd1ac0bbd8
[ "MIT" ]
1,334
2017-06-04T07:47:14.000Z
2022-03-30T17:12:37.000Z
tasks/migrations/0009_alter_task_org.py
AhmedDoudou/Django-CRM-1
5faf22acb30aeb32f5830898fd5d8ecd1ac0bbd8
[ "MIT" ]
317
2017-06-04T07:48:13.000Z
2022-03-29T19:24:26.000Z
tasks/migrations/0009_alter_task_org.py
AhmedDoudou/Django-CRM-1
5faf22acb30aeb32f5830898fd5d8ecd1ac0bbd8
[ "MIT" ]
786
2017-06-06T09:18:48.000Z
2022-03-29T01:29:29.000Z
# Generated by Django 3.2.7 on 2021-10-06 07:21 from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('common', '0037_alter_profile_org'), ('tasks', '0008_rename_company_task_org'), ] operations = [ mig...
26.666667
147
0.644643
from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('common', '0037_alter_profile_org'), ('tasks', '0008_rename_company_task_org'), ] operations = [ migrations.AlterField( model_name='tas...
true
true
f72788069b5b787b60c74366778c57c504270b5a
14,226
py
Python
mmtbx/cablam/cablam_res.py
rimmartin/cctbx_project
644090f9432d9afc22cfb542fc3ab78ca8e15e5d
[ "BSD-3-Clause-LBNL" ]
null
null
null
mmtbx/cablam/cablam_res.py
rimmartin/cctbx_project
644090f9432d9afc22cfb542fc3ab78ca8e15e5d
[ "BSD-3-Clause-LBNL" ]
null
null
null
mmtbx/cablam/cablam_res.py
rimmartin/cctbx_project
644090f9432d9afc22cfb542fc3ab78ca8e15e5d
[ "BSD-3-Clause-LBNL" ]
null
null
null
from __future__ import division # (jEdit options) :folding=explicit:collapseFolds=1: #This module contains the linked_residue class and the functions needed to build # and access instances of it. #2012-09-05: # prunerestype() moved to this module from cablam_training # linked_residue.id_with_resname() changed to ret...
43.638037
135
0.659145
from __future__ import division import sys from mmtbx.cablam.cablam_math import veclen, vectorize #The class does not deal with alts well, however, as an rg may contain several # ag's. The firstalt() function provides some relief, but is really a dodge class linked_residue(obj...
true
true
f7278954301c90c618734d8aadfe80011bdfffd8
1,640
py
Python
Community/ServiceNow CMDB/cmdb_switches/cmdb_switches_logic.py
spenney-bc/gateway-workflows
0311a9224b2d53c01689eb6a9a0a593177abed63
[ "Apache-2.0" ]
43
2017-12-04T17:38:24.000Z
2021-12-29T09:17:17.000Z
Community/ServiceNow CMDB/cmdb_switches/cmdb_switches_logic.py
spenney-bc/gateway-workflows
0311a9224b2d53c01689eb6a9a0a593177abed63
[ "Apache-2.0" ]
49
2017-12-07T21:02:29.000Z
2022-02-04T22:27:16.000Z
Community/ServiceNow CMDB/cmdb_switches/cmdb_switches_logic.py
spenney-bc/gateway-workflows
0311a9224b2d53c01689eb6a9a0a593177abed63
[ "Apache-2.0" ]
82
2017-12-04T17:56:00.000Z
2021-12-29T09:17:21.000Z
""" Component logic """ from bluecat.util import get_password_from_file from ..cmdb_configuration import cmdb_config import requests def raw_table_data(*args, **kwargs): # pylint: disable=redefined-outer-name data = {'columns': [{'title': 'Name'}, {'title': 'IP Address'}, ...
35.652174
168
0.64878
from bluecat.util import get_password_from_file from ..cmdb_configuration import cmdb_config import requests def raw_table_data(*args, **kwargs): data = {'columns': [{'title': 'Name'}, {'title': 'IP Address'}, {'title': 'Serial Number'}, ...
true
true
f727899ef981f97f2b9272fee3b9581691701dbe
7,848
py
Python
src/pymor/bindings/ngsolve.py
meretp/pymor
0965a5c3d0725466103efae5190493fceb2bf441
[ "Unlicense" ]
null
null
null
src/pymor/bindings/ngsolve.py
meretp/pymor
0965a5c3d0725466103efae5190493fceb2bf441
[ "Unlicense" ]
null
null
null
src/pymor/bindings/ngsolve.py
meretp/pymor
0965a5c3d0725466103efae5190493fceb2bf441
[ "Unlicense" ]
null
null
null
# This file is part of the pyMOR project (https://www.pymor.org). # Copyright 2013-2021 pyMOR developers and contributors. All rights reserved. # License: BSD 2-Clause License (https://opensource.org/licenses/BSD-2-Clause) from pathlib import Path from pymor.core.config import config from pymor.core.defaults import de...
38.660099
120
0.599261
from pathlib import Path from pymor.core.config import config from pymor.core.defaults import defaults from pymor.tools.io import change_to_directory if config.HAVE_NGSOLVE: import ngsolve as ngs import numpy as np from pymor.core.base import ImmutableObject from pymor.operators.list import Linear...
true
true
f72789d0e4c9455e928dc2d9cfcad8d7f2a69dd2
6,167
py
Python
video_pipeline.py
josehoras/Advanced-Lane-Finding
e6b83d602eb89661d3bf0f4d257ed5af0f6a58bb
[ "MIT" ]
null
null
null
video_pipeline.py
josehoras/Advanced-Lane-Finding
e6b83d602eb89661d3bf0f4d257ed5af0f6a58bb
[ "MIT" ]
null
null
null
video_pipeline.py
josehoras/Advanced-Lane-Finding
e6b83d602eb89661d3bf0f4d257ed5af0f6a58bb
[ "MIT" ]
null
null
null
import numpy as np import pickle import cv2 import matplotlib.pyplot as plt import matplotlib.image as mpimg from moviepy.editor import VideoFileClip from image_thresholding import * from plotting_helpers import * from line_fit import * from Line import * # *** PIPELINE *** def pipeline(img): global error_im, ski...
40.572368
113
0.65364
import numpy as np import pickle import cv2 import matplotlib.pyplot as plt import matplotlib.image as mpimg from moviepy.editor import VideoFileClip from image_thresholding import * from plotting_helpers import * from line_fit import * from Line import * def pipeline(img): global error_im, skipped_frames ...
true
true
f7278a13c9265e6e8a34e3ea72f574bcebb85a0d
4,861
py
Python
src/Network/SR4DFlowNet.py
EdwardFerdian/4DFlowNet
e9c8bf72660b41ef5c7b6c677a71283ead32bbab
[ "MIT" ]
14
2020-06-17T04:28:39.000Z
2022-02-24T07:21:51.000Z
src/Network/SR4DFlowNet.py
EdwardFerdian/4DFlowNet
e9c8bf72660b41ef5c7b6c677a71283ead32bbab
[ "MIT" ]
null
null
null
src/Network/SR4DFlowNet.py
EdwardFerdian/4DFlowNet
e9c8bf72660b41ef5c7b6c677a71283ead32bbab
[ "MIT" ]
7
2020-08-13T03:21:31.000Z
2022-02-15T13:01:18.000Z
import tensorflow as tf class SR4DFlowNet(): def __init__(self, res_increase): self.res_increase = res_increase def build_network(self, u, v, w, u_mag, v_mag, w_mag, low_resblock=8, hi_resblock=4, channel_nr=64): channel_nr = 64 speed = (u ** 2 + v ** 2 + w ** 2) ** 0.5 mag = ...
40.173554
163
0.649866
import tensorflow as tf class SR4DFlowNet(): def __init__(self, res_increase): self.res_increase = res_increase def build_network(self, u, v, w, u_mag, v_mag, w_mag, low_resblock=8, hi_resblock=4, channel_nr=64): channel_nr = 64 speed = (u ** 2 + v ** 2 + w ** 2) ** 0.5 mag = ...
true
true
f7278a52cbb84e8828f86b3c9b2a793ccd2f5400
419
py
Python
clientes/forms.py
Etxea/gestion_eide_web
8a59be1ddb59a4713cb3346534fd01f643d8f924
[ "MIT" ]
null
null
null
clientes/forms.py
Etxea/gestion_eide_web
8a59be1ddb59a4713cb3346534fd01f643d8f924
[ "MIT" ]
null
null
null
clientes/forms.py
Etxea/gestion_eide_web
8a59be1ddb59a4713cb3346534fd01f643d8f924
[ "MIT" ]
null
null
null
from django import forms from django.forms import ModelForm from models import * from django.forms.models import inlineformset_factory class ClienteForm(forms.ModelForm): class Meta: model = Cliente class ClienteContactoForm(forms.ModelForm): class Meta: model = ClienteContacto exclude...
24.647059
73
0.74463
from django import forms from django.forms import ModelForm from models import * from django.forms.models import inlineformset_factory class ClienteForm(forms.ModelForm): class Meta: model = Cliente class ClienteContactoForm(forms.ModelForm): class Meta: model = ClienteContacto exclude...
true
true
f7278a76375e3a6c0657a5bf9351de27906e9406
92,087
py
Python
xalpha/universal.py
kingmoon3/xalpha
dd877c6bce1b85a4facd38de9dc35a7bf0acf1c6
[ "MIT" ]
3
2021-08-15T10:00:14.000Z
2022-02-12T22:30:01.000Z
xalpha/universal.py
kingmoon3/xalpha
dd877c6bce1b85a4facd38de9dc35a7bf0acf1c6
[ "MIT" ]
null
null
null
xalpha/universal.py
kingmoon3/xalpha
dd877c6bce1b85a4facd38de9dc35a7bf0acf1c6
[ "MIT" ]
1
2021-10-01T13:12:10.000Z
2021-10-01T13:12:10.000Z
# -*- coding: utf-8 -*- """ modules for universal fetcher that gives historical daily data and realtime data for almost everything in the market """ import os import sys import time import datetime as dt import numpy as np import pandas as pd import logging import inspect from bs4 import BeautifulSoup from functools i...
33.522752
277
0.544876
import os import sys import time import datetime as dt import numpy as np import pandas as pd import logging import inspect from bs4 import BeautifulSoup from functools import wraps, lru_cache from uuid import uuid4 from sqlalchemy import exc from dateutil.relativedelta import relativedelta try: from jqdatasdk i...
true
true
f7278b3f78adb6b6654bc60e19101d05927cea4c
1,039
py
Python
modules/denoise/config.py
gw2cc/godot
addaa48039fff0795b99cf998a11a75a9e280850
[ "MIT", "Apache-2.0", "CC-BY-4.0", "Unlicense" ]
1
2022-02-26T05:16:25.000Z
2022-02-26T05:16:25.000Z
modules/denoise/config.py
gw2cc/godot
addaa48039fff0795b99cf998a11a75a9e280850
[ "MIT", "Apache-2.0", "CC-BY-4.0", "Unlicense" ]
2
2021-12-10T04:07:19.000Z
2021-12-27T20:00:03.000Z
modules/denoise/config.py
gw2cc/godot
addaa48039fff0795b99cf998a11a75a9e280850
[ "MIT", "Apache-2.0", "CC-BY-4.0", "Unlicense" ]
null
null
null
def can_build(env, platform): # Thirdparty dependency OpenImage Denoise includes oneDNN library # and the version we use only supports x86_64. # It's also only relevant for tools build and desktop platforms, # as doing lightmap generation and denoising on Android or HTML5 # would be a bit far-fetche...
41.56
88
0.704524
def can_build(env, platform): # as doing lightmap generation and denoising on Android or HTML5 # would be a bit far-fetched. # Note: oneDNN doesn't support ARM64, OIDN needs updating to the latest version supported_platform = platform in ["x11", "osx", "windows", "server"] supported_b...
true
true
f7278bb2aaab500d948340fdddc1c5f836645f0b
97,520
py
Python
wordlist.py
Finoozer/pypassgen
37a129f0917871f8ea6680e7820a110df779f5f2
[ "MIT" ]
null
null
null
wordlist.py
Finoozer/pypassgen
37a129f0917871f8ea6680e7820a110df779f5f2
[ "MIT" ]
null
null
null
wordlist.py
Finoozer/pypassgen
37a129f0917871f8ea6680e7820a110df779f5f2
[ "MIT" ]
null
null
null
wl = ["aah", "aaron", "aba", "ababa", "aback", "abase", "abash", "abate", "abbas", "abbe", "abbey", "abbot", "abbott", "abc", "abe", "abed", "abel", "abet", "abide", "abject", "ablaze", "able", ...
14.535698
15
0.312151
wl = ["aah", "aaron", "aba", "ababa", "aback", "abase", "abash", "abate", "abbas", "abbe", "abbey", "abbot", "abbott", "abc", "abe", "abed", "abel", "abet", "abide", "abject", "ablaze", "able", ...
true
true
f7278c9a625b2d1059e2cfccec2d387b369c5723
3,269
py
Python
test_src/Tests/test07_scroll_list/test_TC09.py
BJanos87/Vizsgaremek-conduit-app
1ffb309389b0cbe68aca56bfde50ba8b17219d03
[ "MIT" ]
null
null
null
test_src/Tests/test07_scroll_list/test_TC09.py
BJanos87/Vizsgaremek-conduit-app
1ffb309389b0cbe68aca56bfde50ba8b17219d03
[ "MIT" ]
null
null
null
test_src/Tests/test07_scroll_list/test_TC09.py
BJanos87/Vizsgaremek-conduit-app
1ffb309389b0cbe68aca56bfde50ba8b17219d03
[ "MIT" ]
null
null
null
from test_src.Tests.test07_scroll_list.conftest import PyFix from test_src.Pages.HomePage import HomePage from test_src.Pages.LoginPage import LoginPage from test_src.Pages.MainPage import MainPage from test_src.Data.test_data import TestData import time class TestScrollList(PyFix): """this used to check the tit...
44.780822
86
0.674824
from test_src.Tests.test07_scroll_list.conftest import PyFix from test_src.Pages.HomePage import HomePage from test_src.Pages.LoginPage import LoginPage from test_src.Pages.MainPage import MainPage from test_src.Data.test_data import TestData import time class TestScrollList(PyFix): def test_homepage(self): ...
true
true
f7278cd33f1012970fa1eafccf108f1db2ee92aa
1,387
py
Python
python_code/vnev/Lib/site-packages/jdcloud_sdk/services/kubernetes/apis/SetAutoRepairRequest.py
Ureimu/weather-robot
7634195af388538a566ccea9f8a8534c5fb0f4b6
[ "MIT" ]
14
2018-04-19T09:53:56.000Z
2022-01-27T06:05:48.000Z
python_code/vnev/Lib/site-packages/jdcloud_sdk/services/kubernetes/apis/SetAutoRepairRequest.py
Ureimu/weather-robot
7634195af388538a566ccea9f8a8534c5fb0f4b6
[ "MIT" ]
15
2018-09-11T05:39:54.000Z
2021-07-02T12:38:02.000Z
python_code/vnev/Lib/site-packages/jdcloud_sdk/services/kubernetes/apis/SetAutoRepairRequest.py
Ureimu/weather-robot
7634195af388538a566ccea9f8a8534c5fb0f4b6
[ "MIT" ]
33
2018-04-20T05:29:16.000Z
2022-02-17T09:10:05.000Z
# coding=utf8 # Copyright 2018 JDCLOUD.COM # # 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 ...
30.152174
98
0.708724
from jdcloud_sdk.core.jdcloudrequest import JDCloudRequest class SetAutoRepairRequest(JDCloudRequest): def __init__(self, parameters, header=None, version="v1"): super(SetAutoRepairRequest, self).__init__( '/regions/{regionId}/nodeGroups/{nodeGroupId}:setAutoRepair', 'POST',...
true
true
f7278cfa86311c10a1c661a6f7e11feef1b88341
97,964
py
Python
nova/tests/unit/virt/xenapi/test_vm_utils.py
NxtCloud/nova
6f6c3bcc1fea805ece40d64b092eb836ee21c006
[ "Apache-2.0" ]
null
null
null
nova/tests/unit/virt/xenapi/test_vm_utils.py
NxtCloud/nova
6f6c3bcc1fea805ece40d64b092eb836ee21c006
[ "Apache-2.0" ]
null
null
null
nova/tests/unit/virt/xenapi/test_vm_utils.py
NxtCloud/nova
6f6c3bcc1fea805ece40d64b092eb836ee21c006
[ "Apache-2.0" ]
null
null
null
# Copyright 2013 OpenStack Foundation # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless requ...
40.331
79
0.620953
import contextlib import uuid from eventlet import greenthread import fixtures import mock from mox3 import mox from oslo.config import cfg from oslo.config import fixture as config_fixture from oslo.utils import timeutils from oslo.utils import units from oslo_concurrency import lockutils from oslo_con...
false
true
f7278d74a416cfce5eaf0b1a81d51c2651746a7a
5,101
py
Python
logicmonitor_sdk/models/data_source_update_reasons_pagination_response.py
JeremyTangCD/lm-sdk-python
2a15e055e5a3f72d2f2e4fb43bdbed203c5a9983
[ "Apache-2.0" ]
null
null
null
logicmonitor_sdk/models/data_source_update_reasons_pagination_response.py
JeremyTangCD/lm-sdk-python
2a15e055e5a3f72d2f2e4fb43bdbed203c5a9983
[ "Apache-2.0" ]
null
null
null
logicmonitor_sdk/models/data_source_update_reasons_pagination_response.py
JeremyTangCD/lm-sdk-python
2a15e055e5a3f72d2f2e4fb43bdbed203c5a9983
[ "Apache-2.0" ]
null
null
null
# coding: utf-8 """ LogicMonitor REST API LogicMonitor is a SaaS-based performance monitoring platform that provides full visibility into complex, hybrid infrastructures, offering granular performance monitoring and actionable data and insights. logicmonitor_sdk enables you to manage your LogicMonitor account...
30.005882
304
0.612625
import pprint import re import six from logicmonitor_sdk.models.update_reason import UpdateReason class DataSourceUpdateReasonsPaginationResponse(object): swagger_types = { 'total': 'int', 'search_id': 'str', 'items': 'list[UpdateReason]' } attribute_map = { 'to...
true
true
f7278d910a0798fa44f63254194a56095117de1f
3,950
py
Python
superset/embedded/api.py
7vikpeculiar/superset
800ced5e257d5d83d6dbe4ced0e7318ac40d026f
[ "Apache-2.0" ]
null
null
null
superset/embedded/api.py
7vikpeculiar/superset
800ced5e257d5d83d6dbe4ced0e7318ac40d026f
[ "Apache-2.0" ]
null
null
null
superset/embedded/api.py
7vikpeculiar/superset
800ced5e257d5d83d6dbe4ced0e7318ac40d026f
[ "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 u...
37.264151
87
0.704051
import logging from typing import Optional from flask import Response from flask_appbuilder.api import expose, protect, safe from flask_appbuilder.hooks import before_request from flask_appbuilder.models.sqla.interface import SQLAInterface from superset import is_feature_enabled from superset.constant...
true
true
f7278e0192857e4135b5b9ed6748496b57e99211
1,132
py
Python
udemy/01_walkthrough/practice_1.py
inderpal2406/python
7bd7d03a6b3cd09ff16a4447ff495a2393a87a33
[ "MIT" ]
null
null
null
udemy/01_walkthrough/practice_1.py
inderpal2406/python
7bd7d03a6b3cd09ff16a4447ff495a2393a87a33
[ "MIT" ]
null
null
null
udemy/01_walkthrough/practice_1.py
inderpal2406/python
7bd7d03a6b3cd09ff16a4447ff495a2393a87a33
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # This script will accept user input as a string. # Then display this string in left, right, center of a line in title format. string=input("Enter the string: ") # read input string string=string.title() # convert string to title format ''' # in windows cmd, mode command tells us width of a ...
37.733333
123
0.736749
string=input("Enter the string: ") string=string.title() import os width=os.get_terminal_size().columns print(f"{string.ljust(width)}") print(f"{string.center(width)}") print(f"{string.rjust(width)}") # or instead of converting the string to title format separately, # print(f"{string.ljust(width).title()...
true
true
f7278f1e85d824afdd21dc3d53f33b966aca7692
5,600
py
Python
copulas/multivariate/base.py
DAI-Lab/Copulas
d634437aeac02f46615398463038455260b3de25
[ "MIT" ]
71
2018-06-20T12:07:34.000Z
2020-01-03T21:43:01.000Z
copulas/multivariate/base.py
DAI-Lab/Copulas
d634437aeac02f46615398463038455260b3de25
[ "MIT" ]
75
2018-06-20T09:46:07.000Z
2019-12-23T15:04:19.000Z
copulas/multivariate/base.py
DAI-Lab/Copulas
d634437aeac02f46615398463038455260b3de25
[ "MIT" ]
25
2018-06-24T18:01:11.000Z
2020-01-02T14:30:09.000Z
"""Base Multivariate class.""" import pickle import numpy as np from copulas import NotFittedError, get_instance, validate_random_state class Multivariate(object): """Abstract class for a multi-variate copula object.""" fitted = False def __init__(self, random_state=None): self.random_state =...
28
83
0.574821
import pickle import numpy as np from copulas import NotFittedError, get_instance, validate_random_state class Multivariate(object): fitted = False def __init__(self, random_state=None): self.random_state = validate_random_state(random_state) def fit(self, X): raise NotImplementedErr...
true
true
f7278fb2e4cecf1623625e589a46c10c6f0fc89f
2,209
py
Python
lowder/__init__.py
jabernardo/lowder
d7ddc7d2217ba4ab3f2a4f00314b600af9cf0e70
[ "MIT" ]
1
2020-03-02T05:02:33.000Z
2020-03-02T05:02:33.000Z
lowder/__init__.py
jabernardo/lowder
d7ddc7d2217ba4ab3f2a4f00314b600af9cf0e70
[ "MIT" ]
null
null
null
lowder/__init__.py
jabernardo/lowder
d7ddc7d2217ba4ab3f2a4f00314b600af9cf0e70
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- import time import threading LOADERS = { 'default': { 'interval': 0.1, 'frames': ('/', '-', '|', '\\', '-') }, 'dots': { 'interval': 0.2, 'frames': ('⠋', '⠙', '⠹', '⠸', '⠼', '⠴', '⠦', '⠧', '⠇', '⠏') }, 'dot...
28.320513
79
0.383884
import time import threading LOADERS = { 'default': { 'interval': 0.1, 'frames': ('/', '-', '|', '\\', '-') }, 'dots': { 'interval': 0.2, 'frames': ('⠋', '⠙', '⠹', '⠸', '⠼', '⠴', '⠦', '⠧', '⠇', '⠏') }, 'dots-bar': { '...
true
true
f72790e1400c04034e99a0a996957a5a2bd3bdfa
14,106
py
Python
giung2/modeling/backbone/resnet.py
cs-giung/giung2
c8560fd1b56f20eb1f3cf57202975d8325b591f5
[ "MIT" ]
4
2021-10-18T05:15:59.000Z
2022-03-09T04:29:05.000Z
giung2/modeling/backbone/resnet.py
cs-giung/giung2
c8560fd1b56f20eb1f3cf57202975d8325b591f5
[ "MIT" ]
null
null
null
giung2/modeling/backbone/resnet.py
cs-giung/giung2
c8560fd1b56f20eb1f3cf57202975d8325b591f5
[ "MIT" ]
3
2022-01-12T11:47:51.000Z
2022-03-18T06:28:22.000Z
import torch import torch.nn as nn from typing import Dict, List from functools import partial from fvcore.common.config import CfgNode from giung2.layers import * __all__ = [ "build_resnet_backbone", ] class IdentityShortcut(nn.Module): def __init__( self, in_planes: int, ...
36.638961
112
0.59223
import torch import torch.nn as nn from typing import Dict, List from functools import partial from fvcore.common.config import CfgNode from giung2.layers import * __all__ = [ "build_resnet_backbone", ] class IdentityShortcut(nn.Module): def __init__( self, in_planes: int, ...
true
true
f727917d0f068e8d6007ff3141a9580153e749e9
4,756
py
Python
dipy/data/tests/test_fetcher.py
nasimanousheh/dipy
d737a6af80a184322e30de4760e8c205291dbed0
[ "MIT" ]
2
2018-07-25T14:04:20.000Z
2021-02-10T07:10:10.000Z
dipy/data/tests/test_fetcher.py
aarya22/dipy-reco1
9d20c911b4afe83e52ded698eff9ba0f0fafeca8
[ "MIT" ]
null
null
null
dipy/data/tests/test_fetcher.py
aarya22/dipy-reco1
9d20c911b4afe83e52ded698eff9ba0f0fafeca8
[ "MIT" ]
2
2018-07-24T21:20:54.000Z
2018-08-27T04:08:24.000Z
import tempfile import os.path as op import sys import os import numpy.testing as npt from nibabel.tmpdirs import TemporaryDirectory import dipy.data.fetcher as fetcher from dipy.data import SPHERE_FILES from threading import Thread if sys.version_info[0] < 3: from SimpleHTTPServer import SimpleHTTPRequestHandler ...
37.448819
79
0.634567
import tempfile import os.path as op import sys import os import numpy.testing as npt from nibabel.tmpdirs import TemporaryDirectory import dipy.data.fetcher as fetcher from dipy.data import SPHERE_FILES from threading import Thread if sys.version_info[0] < 3: from SimpleHTTPServer import SimpleHTTPRequestHandler ...
true
true
f727925dfeb5359a5f6f7116be96d12c7354d32c
4,577
py
Python
jarviscli/plugins/bmr.py
jronzo99/Jarvis
d63b51a1a7cb5bbff36e6e7dc3c63201ae1470b2
[ "MIT" ]
1
2021-05-25T11:29:25.000Z
2021-05-25T11:29:25.000Z
jarviscli/plugins/bmr.py
nikiboura/Jarvis
eb22f7c84a345e9ae5925b4b98adbc4f2e4a93f3
[ "MIT" ]
null
null
null
jarviscli/plugins/bmr.py
nikiboura/Jarvis
eb22f7c84a345e9ae5925b4b98adbc4f2e4a93f3
[ "MIT" ]
null
null
null
from colorama import Fore from plugin import plugin @plugin("bmr") def bmr(jarvis, s): """A Jarvis plugin to calculate your Basal Metabolic Rate (BMR) and your Active Metabolic Rate(AMR)""" jarvis.say("Hello there! Ready to count your BMR? \n") jarvis.say("1. Yes, let's start! \n2. Sorry," ...
35.757813
76
0.537688
from colorama import Fore from plugin import plugin @plugin("bmr") def bmr(jarvis, s): jarvis.say("Hello there! Ready to count your BMR? \n") jarvis.say("1. Yes, let's start! \n2. Sorry," " I don't know what BMR is :( \n ") jarvis.say("Please enter your choice: ") choice = jarvis....
true
true
f7279315c269b9d8ccac798e0d91c3ab9cba61d7
3,834
py
Python
Project/_visualize.py
BendeguzToth/NeuralLanguageModel
f4bb60375019acd57c7396768d62ad0f3166391c
[ "MIT" ]
1
2021-05-18T04:04:31.000Z
2021-05-18T04:04:31.000Z
Project/_visualize.py
BendeguzToth/NeuralLanguageModel
f4bb60375019acd57c7396768d62ad0f3166391c
[ "MIT" ]
null
null
null
Project/_visualize.py
BendeguzToth/NeuralLanguageModel
f4bb60375019acd57c7396768d62ad0f3166391c
[ "MIT" ]
null
null
null
""" In this file we visualize the activations of particular neurons, at different positions of a provided sample text. """ # Standard libraries import json import tkinter as tk # Third-party libraries import numpy as np # Project files from layers import LSTM # SETUP MODEL = "saves/ShakespeareNet.json" LOOKUP_FILE ...
30.188976
108
0.628326
import json import tkinter as tk import numpy as np from layers import LSTM MODEL = "saves/ShakespeareNet.json" LOOKUP_FILE = "saves/ShakespeareLookup.json" TEXT_FILE = "saves/sample.txt" def main(): with open(LOOKUP_FILE, 'r') as file: chars = json.load(file) char_to_int = dic...
true
true
f72793d54ac528bc12e6cc394f04adc65956cb34
21,296
py
Python
gen_data_fin.py
vjaguilera/BERT4Rec
8c460676af224c90c9cc89f1ba837b38f04e4210
[ "Apache-2.0" ]
null
null
null
gen_data_fin.py
vjaguilera/BERT4Rec
8c460676af224c90c9cc89f1ba837b38f04e4210
[ "Apache-2.0" ]
null
null
null
gen_data_fin.py
vjaguilera/BERT4Rec
8c460676af224c90c9cc89f1ba837b38f04e4210
[ "Apache-2.0" ]
null
null
null
# -*- coding: UTF-8 -*- import os import codecs import collections import random import sys import tensorflow as tf import six from util import * from vocab import * import pickle import multiprocessing import time random_seed = 12345 short_seq_prob = 0 # Probability of creating sequences which are shorter than...
32.864198
158
0.609739
import os import codecs import collections import random import sys import tensorflow as tf import six from util import * from vocab import * import pickle import multiprocessing import time random_seed = 12345 short_seq_prob = 0 flags = tf.flags FLAGS = flags.FLAGS flags.DEFINE_string("signature", 'default...
true
true
f727954b000151483380835b1aa72d1c1ac5eccb
2,275
py
Python
src/scheduler/migrations/0004_scheduledemailaction.py
japesone/ontask_b
17af441f9893c521d2e14011e7790ba4077e3318
[ "MIT" ]
3
2018-08-24T10:48:40.000Z
2020-05-29T06:33:23.000Z
src/scheduler/migrations/0004_scheduledemailaction.py
japesone/ontask_b
17af441f9893c521d2e14011e7790ba4077e3318
[ "MIT" ]
null
null
null
src/scheduler/migrations/0004_scheduledemailaction.py
japesone/ontask_b
17af441f9893c521d2e14011e7790ba4077e3318
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by Django 1.11.3 on 2017-12-16 08:54 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 = [ ('workfl...
51.704545
187
0.648352
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 = [ ('workflow', '0013_auto_20171209_0809'), migrations.swappable_dependenc...
true
true
f72795aa0c613268a934fa6fe9d3601b7683d86e
20,230
py
Python
sdk/core/azure-core/azure/core/polling/base_polling.py
vbarbaresi/azure-sdk-for-python
397ba46c51d001ff89c66b170f5576cf8f49c05f
[ "MIT" ]
8
2021-01-13T23:44:08.000Z
2021-03-17T10:13:36.000Z
sdk/core/azure-core/azure/core/polling/base_polling.py
vbarbaresi/azure-sdk-for-python
397ba46c51d001ff89c66b170f5576cf8f49c05f
[ "MIT" ]
null
null
null
sdk/core/azure-core/azure/core/polling/base_polling.py
vbarbaresi/azure-sdk-for-python
397ba46c51d001ff89c66b170f5576cf8f49c05f
[ "MIT" ]
1
2020-10-11T06:05:00.000Z
2020-10-11T06:05:00.000Z
# -------------------------------------------------------------------------- # # Copyright (c) Microsoft Corporation. All rights reserved. # # The MIT License (MIT) # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the ""Software""), ...
34.057239
118
0.659219
import abc import base64 import json from typing import TYPE_CHECKING, Optional, Any, Union from ..exceptions import HttpResponseError, DecodeError from . import PollingMethod from ..pipeline.policies._utils import get_retry_after if TYPE_CHECKING: from azure.core.pipeline import Pipeline...
true
true
f72796cfdb731f2805f402a224271fe7a843f908
3,858
py
Python
tests/test_similarity.py
dhimmel/sematch
7e92b171c27a8b25e844a467554fe4bb2adfb883
[ "Apache-2.0" ]
397
2015-05-30T11:02:28.000Z
2022-03-09T01:39:31.000Z
tests/test_similarity.py
dhimmel/sematch
7e92b171c27a8b25e844a467554fe4bb2adfb883
[ "Apache-2.0" ]
32
2015-04-27T21:26:29.000Z
2021-08-19T10:20:45.000Z
tests/test_similarity.py
dhimmel/sematch
7e92b171c27a8b25e844a467554fe4bb2adfb883
[ "Apache-2.0" ]
110
2015-11-06T17:01:48.000Z
2022-02-17T05:09:02.000Z
# -*- coding: utf-8 -*- def test_word_similarity(): from sematch.semantic.similarity import WordNetSimilarity wns = WordNetSimilarity() dog = wns.word2synset('dog') cat = wns.word2synset('cat') # Measuring semantic similarity between concepts using Path method assert wns.similarity(dog[0], cat[...
52.849315
126
0.736133
def test_word_similarity(): from sematch.semantic.similarity import WordNetSimilarity wns = WordNetSimilarity() dog = wns.word2synset('dog') cat = wns.word2synset('cat') assert wns.similarity(dog[0], cat[0], 'path') is not None assert wns.word_similarity('dog', 'cat', 'li') is not N...
true
true
f72797852f54a7b4a109a290c7e4ff3ec4e2193c
3,676
py
Python
src/chaospizza/orders/migrations/0001_initial.py
chaosdorf/chaospizza
6f0895f28095260d04b41a8b86edf07a87bcccb8
[ "MIT" ]
9
2017-05-19T23:32:19.000Z
2020-06-28T20:40:13.000Z
src/chaospizza/orders/migrations/0001_initial.py
step21/chaospizza
8011ebb5fd021bf74897099cedd1869bcfbd031f
[ "MIT" ]
31
2017-05-19T21:27:30.000Z
2022-01-25T21:38:13.000Z
src/chaospizza/orders/migrations/0001_initial.py
step21/chaospizza
8011ebb5fd021bf74897099cedd1869bcfbd031f
[ "MIT" ]
4
2017-05-19T23:32:05.000Z
2019-02-26T03:41:51.000Z
# Generated by Django 1.11.3 on 2017-07-07 19:21 from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): # noqa initial = True dependencies = [ ] operations = [ migrations.CreateModel( name='Order', fields=[ ...
59.290323
392
0.612078
from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): initial = True dependencies = [ ] operations = [ migrations.CreateModel( name='Order', fields=[ ('id', models.AutoField(auto_created=Tr...
true
true
f7279801d19e14d38461c4393e790d31ce9d5df4
479
py
Python
accounting/root.py
michellab/BioSimSpaceCloud
456b146a2131565e354352872d3e75a08c3652d1
[ "Apache-2.0" ]
2
2019-02-15T16:04:19.000Z
2019-02-19T15:42:27.000Z
accounting/root.py
michellab/BioSimSpaceCloud
456b146a2131565e354352872d3e75a08c3652d1
[ "Apache-2.0" ]
null
null
null
accounting/root.py
michellab/BioSimSpaceCloud
456b146a2131565e354352872d3e75a08c3652d1
[ "Apache-2.0" ]
null
null
null
from Acquire.Service import create_return_value from Acquire.Service import get_service_info, get_service_private_key def run(args): """This function return the status and service info""" status = 0 message = None service = None service = get_service_info() status = 0 message = "Succes...
19.958333
69
0.707724
from Acquire.Service import create_return_value from Acquire.Service import get_service_info, get_service_private_key def run(args): status = 0 message = None service = None service = get_service_info() status = 0 message = "Success" return_value = create_return_value(status, message)...
true
true
f72798a96967ad3fd309ebf1baee8b1a120bae4d
13,803
py
Python
layers.py
richardsfc/neural_rerendering_plus
f5b2bd2ebe7e9657e3584612818eb0d137714276
[ "Apache-2.0" ]
2
2020-06-09T01:48:13.000Z
2021-07-06T11:53:51.000Z
layers.py
richardsfc/neural_rerendering_plus
f5b2bd2ebe7e9657e3584612818eb0d137714276
[ "Apache-2.0" ]
7
2020-09-26T01:11:45.000Z
2022-03-12T00:34:09.000Z
layers.py
richardsfc/neural_rerendering_plus
f5b2bd2ebe7e9657e3584612818eb0d137714276
[ "Apache-2.0" ]
null
null
null
# Copyright 2019 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, ...
31.658257
110
0.626096
import functools from options import FLAGS as opts import numpy as np import tensorflow as tf from plyfile import PlyData, PlyElement class LayerDescriptor(object): def __init__(self, name, m): with tf.variable_scope(name): plydata = PlyData.read(opts.descriptor_folder + '/fused.ply') ...
true
true
f7279945818ccb74868b87f76d1ec78f62a9ecf6
536
py
Python
pysql/__init__.py
fossabot/PySQL
3cd46130ce12bcd7636d4715176d6610b1dcf279
[ "MIT" ]
12
2021-03-12T12:12:02.000Z
2021-10-04T18:30:19.000Z
pysql/__init__.py
fossabot/PySQL
3cd46130ce12bcd7636d4715176d6610b1dcf279
[ "MIT" ]
28
2021-03-14T05:52:36.000Z
2022-03-17T04:16:28.000Z
pysql/__init__.py
fossabot/PySQL
3cd46130ce12bcd7636d4715176d6610b1dcf279
[ "MIT" ]
8
2021-03-31T14:31:49.000Z
2022-03-13T09:43:31.000Z
""" module for PySQL wrapper functions, for using as a library """ __author__ = "Devansh Singh" __email__ = "devanshamity@gmail.com" __license__ = "MIT" from pysql import * """ classes for functions for initializing object instances, use (username, password) of local MySQL server """ from pysql.packages.auth impor...
17.290323
50
0.772388
__author__ = "Devansh Singh" __email__ = "devanshamity@gmail.com" __license__ = "MIT" from pysql import * from pysql.packages.auth import Database from pysql.packages.ddl_commands import DDL, Alter from pysql.packages.dml_commands import DML from pysql.data.export import Export from pysql.data.imports import Import...
true
true
f72799e9e1cbfc52c99b8a8ba84b5bcb51232a74
982
py
Python
setup.py
AndreJambersi/Project_hours
3f99566e0b1e54aa4e2f848ad34dbe9988f75591
[ "MIT" ]
1
2019-10-23T17:38:07.000Z
2019-10-23T17:38:07.000Z
setup.py
AndreJambersi/TimeBetweenBusinessHours
3f99566e0b1e54aa4e2f848ad34dbe9988f75591
[ "MIT" ]
null
null
null
setup.py
AndreJambersi/TimeBetweenBusinessHours
3f99566e0b1e54aa4e2f848ad34dbe9988f75591
[ "MIT" ]
null
null
null
from distutils.core import setup setup( name = 'TimeBetweenBusinessHours', packages = ['TimeBetweenBusinessHours'], version = '0.1', license='MIT', description = 'Get the Time Between Business Hours', author = 'AndreJambersi', author_email = 'andrejambersi@gmail.com', url = 'https://github.com/...
35.071429
98
0.645621
from distutils.core import setup setup( name = 'TimeBetweenBusinessHours', packages = ['TimeBetweenBusinessHours'], version = '0.1', license='MIT', description = 'Get the Time Between Business Hours', author = 'AndreJambersi', author_email = 'andrejambersi@gmail.com', url = 'https://github.com/...
true
true
f72799ee803e4457c079e7493a5b02931855af6b
4,817
py
Python
docs/_static/pyparsing_examples/simpleSQL.py
emacsway/sqlbuilder
72f32bbbfc1116550343c471dc43ef6284492a5a
[ "BSD-3-Clause" ]
33
2017-07-26T02:33:48.000Z
2022-03-18T06:38:12.000Z
docs/_static/pyparsing_examples/simpleSQL.py
emacsway/sqlbuilder
72f32bbbfc1116550343c471dc43ef6284492a5a
[ "BSD-3-Clause" ]
1
2019-03-03T15:09:46.000Z
2019-03-03T15:09:46.000Z
docs/_static/pyparsing_examples/simpleSQL.py
emacsway/sqlbuilder
72f32bbbfc1116550343c471dc43ef6284492a5a
[ "BSD-3-Clause" ]
3
2017-09-25T03:00:11.000Z
2020-10-21T09:59:09.000Z
# Source: http://pyparsing.wikispaces.com/file/view/simpleSQL.py # simpleSQL.py # # simple demo of using the parsing library to do simple-minded SQL parsing # could be extended to include where clauses etc. # # Copyright (c) 2003, Paul McGuire # from pyparsing import Literal, CaselessLiteral, Word, Upcase, deli...
33.451389
113
0.588333
from pyparsing import Literal, CaselessLiteral, Word, Upcase, delimitedList, Optional, \ Combine, Group, alphas, nums, alphanums, ParseException, Forward, oneOf, quotedString, \ ZeroOrMore, restOfLine, Keyword def test( str ): print str,"->" try: tokens = simpleSQL.parseString( s...
false
true
f7279c891026d6d9c304e4c395e6d04dfac0fd5f
44,050
py
Python
TexSoup/data.py
pablo-angulo/TexSoup
bfd09bcfc8e020f26939a7166d9316bac51515f0
[ "BSD-2-Clause" ]
190
2016-09-26T08:38:31.000Z
2022-02-10T23:18:00.000Z
TexSoup/data.py
pablo-angulo/TexSoup
bfd09bcfc8e020f26939a7166d9316bac51515f0
[ "BSD-2-Clause" ]
127
2016-05-20T07:31:06.000Z
2022-02-16T14:48:09.000Z
TexSoup/data.py
pablo-angulo/TexSoup
bfd09bcfc8e020f26939a7166d9316bac51515f0
[ "BSD-2-Clause" ]
44
2017-07-23T19:58:00.000Z
2021-12-03T12:57:48.000Z
"""TexSoup transforms a LaTeX document into a complex tree of various Python objects, but all objects fall into one of the following three categories: ``TexNode``, ``TexExpr`` (environments and commands), and ``TexGroup`` s. """ import itertools import re from TexSoup.utils import CharToLineOffset, Token, TC, to_list...
30.274914
91
0.545358
import itertools import re from TexSoup.utils import CharToLineOffset, Token, TC, to_list __all__ = ['TexNode', 'TexCmd', 'TexEnv', 'TexGroup', 'BracketGroup', 'BraceGroup', 'TexArgs', 'TexText', 'TexMathEnv', 'TexDisplayMathEnv', 'TexNamedEnv', 'TexMathModeEnv', 'TexDisplayMathModeEn...
true
true
f7279d2a0928d92d1790424e41fa2a880cbb1be9
138
py
Python
multiples_list.py
GYosifov88/Python-Fundamentals
b46ba2822bd2dac6ff46830c6a520e559b448442
[ "MIT" ]
null
null
null
multiples_list.py
GYosifov88/Python-Fundamentals
b46ba2822bd2dac6ff46830c6a520e559b448442
[ "MIT" ]
null
null
null
multiples_list.py
GYosifov88/Python-Fundamentals
b46ba2822bd2dac6ff46830c6a520e559b448442
[ "MIT" ]
null
null
null
factor = int(input()) count = int(input()) new_list = [] for num in range (1, count+1): new_list.append(factor * num) print(new_list)
19.714286
33
0.65942
factor = int(input()) count = int(input()) new_list = [] for num in range (1, count+1): new_list.append(factor * num) print(new_list)
true
true
f7279d86e14fb0fc3c957ab9728d907bc9972e34
712
py
Python
sdk/test/test_user_location.py
aqualinkorg/aqualink-sdk
dad972d1dd5b74e8216bdc30521a8b76f7844733
[ "MIT" ]
1
2022-02-06T23:05:37.000Z
2022-02-06T23:05:37.000Z
sdk/test/test_user_location.py
aqualinkorg/aqualink-sdk
dad972d1dd5b74e8216bdc30521a8b76f7844733
[ "MIT" ]
3
2022-02-07T06:13:31.000Z
2022-03-11T12:43:39.000Z
sdk/test/test_user_location.py
aqualinkorg/aqualink-sdk
dad972d1dd5b74e8216bdc30521a8b76f7844733
[ "MIT" ]
null
null
null
""" Aqualink API documentation The Aqualink public API documentation # noqa: E501 The version of the OpenAPI document: 1.0.0 Generated by: https://openapi-generator.tech """ import sys import unittest import aqualink_sdk from aqualink_sdk.model.user_location import UserLocation class TestUserLoc...
19.777778
79
0.676966
import sys import unittest import aqualink_sdk from aqualink_sdk.model.user_location import UserLocation class TestUserLocation(unittest.TestCase): def setUp(self): pass def tearDown(self): pass def testUserLocation(self): s if __name__ == '__main__': unittest....
true
true
f7279df45c4b42335c35e8630786466cee4cd860
698
py
Python
models/final_model.py
Abxhor/Coldairarrow
3735beec8a6fa7ad9356375081229c68f0e83f3d
[ "MIT" ]
null
null
null
models/final_model.py
Abxhor/Coldairarrow
3735beec8a6fa7ad9356375081229c68f0e83f3d
[ "MIT" ]
null
null
null
models/final_model.py
Abxhor/Coldairarrow
3735beec8a6fa7ad9356375081229c68f0e83f3d
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """Stacking of some good solutions. IMPORTANT: To run this model you need run before the differents models. """ import pandas as pd import numpy as np df1 = pd.read_csv('submission40.csv') # 0.309812 (public leaderboard) df2 = pd.read_csv('submission41.csv') # 0.305985 (public leaderboard) df...
33.238095
85
0.690544
import pandas as pd import numpy as np df1 = pd.read_csv('submission40.csv') df2 = pd.read_csv('submission41.csv') df3 = pd.read_csv('submission42.csv') df4 = pd.read_csv('submission45.csv') df5 = pd.read_csv('submission47.csv') df = pd.DataFrame() df['y'] = 0.2*df1['y'] + 0.23*df2['y'] + 0.2*df3['y'] + 0.15...
true
true
f7279e1c3124420e19cf7b1c5a2e96104f93c057
19,081
py
Python
777_all_in_one_v1.py
vlbthambawita/singan-polyp-aug-exp
b4ec5155f5c36a931fad022aec04dda6b3180b55
[ "MIT" ]
null
null
null
777_all_in_one_v1.py
vlbthambawita/singan-polyp-aug-exp
b4ec5155f5c36a931fad022aec04dda6b3180b55
[ "MIT" ]
null
null
null
777_all_in_one_v1.py
vlbthambawita/singan-polyp-aug-exp
b4ec5155f5c36a931fad022aec04dda6b3180b55
[ "MIT" ]
null
null
null
#========================================================= # Developer: Vajira Thambawita # Reference: https://github.com/meetshah1995/pytorch-semseg #========================================================= import argparse from datetime import datetime import os import copy from tqdm import tqdm import matplotlib....
32.728988
133
0.639432
import argparse from datetime import datetime import os import copy from tqdm import tqdm import matplotlib.pyplot as plt import numpy as np import torch import torch.optim as optim from torch.optim import lr_scheduler import torch.nn as nn from torch.utils.data import DataLoader from torchvision import model...
true
true
f7279ecc02853cb1115ebc5b8d75e8798d77b6ea
5,301
py
Python
tests/app/models/test_webauthn_credential.py
TechforgoodCAST/notifications-admin
0a9e06aafd79d0fbe50c26a85bf757aaeaa59340
[ "MIT" ]
null
null
null
tests/app/models/test_webauthn_credential.py
TechforgoodCAST/notifications-admin
0a9e06aafd79d0fbe50c26a85bf757aaeaa59340
[ "MIT" ]
1
2021-10-19T13:34:15.000Z
2021-10-19T13:34:15.000Z
tests/app/models/test_webauthn_credential.py
TechforgoodCAST/notifications-admin
0a9e06aafd79d0fbe50c26a85bf757aaeaa59340
[ "MIT" ]
1
2021-03-05T13:18:44.000Z
2021-03-05T13:18:44.000Z
import base64 import pytest from fido2 import cbor from fido2.cose import ES256 from app.models.webauthn_credential import RegistrationError, WebAuthnCredential # noqa adapted from https://github.com/duo-labs/py_webauthn/blob/90e3d97e0182899a35a70fc510280b4082cce19b/tests/test_webauthn.py#L14-L24 SESSION_STATE = {'c...
73.625
1,274
0.873986
import base64 import pytest from fido2 import cbor from fido2.cose import ES256 from app.models.webauthn_credential import RegistrationError, WebAuthnCredential _STATE = {'challenge': 'bPzpX3hHQtsp9evyKYkaZtVc9UN07PUdJ22vZUdDp94', 'user_verification': 'discouraged'} CLIENT_DATA_JSON = b'{"type": "webauthn.create", "...
true
true
f727a030df092bb2e0060f668a84075527b879dd
913
py
Python
src/dicom_parser/utils/bids/utils.py
open-dicom/dicom_parser
acc82f6f989a335fd3cf30e716334081ab9ac43b
[ "MIT" ]
6
2021-08-01T17:48:57.000Z
2022-03-07T15:41:26.000Z
src/dicom_parser/utils/bids/utils.py
open-dicom/dicom_parser
acc82f6f989a335fd3cf30e716334081ab9ac43b
[ "MIT" ]
33
2021-08-08T16:09:21.000Z
2022-03-15T15:17:37.000Z
src/dicom_parser/utils/bids/utils.py
open-dicom/dicom_parser
acc82f6f989a335fd3cf30e716334081ab9ac43b
[ "MIT" ]
6
2021-10-19T09:19:22.000Z
2022-03-13T19:26:10.000Z
""" Utilities for the :mod:`dicom_parser.utils.bids` module. """ from typing import Dict, List # A summary of the unique parts (key/value) pairs that make up the appropriate # BIDS-compatible file name by data type. ANATOMICAL_NAME_PARTS: List[str] = ["acq", "ce", "rec", "inv", "run", "part"] DWI_NAME_PARTS: List[str]...
27.666667
78
0.637459
from typing import Dict, List ANATOMICAL_NAME_PARTS: List[str] = ["acq", "ce", "rec", "inv", "run", "part"] DWI_NAME_PARTS: List[str] = ["acq", "dir", "run", "part"] FIELDMAP_NAME_PARTS: List[str] = ["acq", "ce", "dir", "run"] FUNCTIONAL_NAME_PARTS: List[str] = [ "task", "acq", "ce", "rec", "dir"...
true
true
f727a06b1b074152cadb873d888a24a742788ecb
761
py
Python
cride/users/admin.py
valot3/Cride-API
a9e201942e6eecd479f575733e93ff73e6df573d
[ "MIT" ]
null
null
null
cride/users/admin.py
valot3/Cride-API
a9e201942e6eecd479f575733e93ff73e6df573d
[ "MIT" ]
null
null
null
cride/users/admin.py
valot3/Cride-API
a9e201942e6eecd479f575733e93ff73e6df573d
[ "MIT" ]
null
null
null
"""User models admin""" #Django from django.contrib import admin from django.contrib.auth.admin import UserAdmin #Project from cride.users.models import User, Profile class CustomUserAdmin(UserAdmin): """User model admin.""" list_display = ('email', 'username', 'first_name', 'last_name', 'is_staff', 'is_c...
27.178571
92
0.720105
from django.contrib import admin from django.contrib.auth.admin import UserAdmin from cride.users.models import User, Profile class CustomUserAdmin(UserAdmin): list_display = ('email', 'username', 'first_name', 'last_name', 'is_staff', 'is_client') list_filter = ('is_client', 'is_staff', 'created_at', '...
true
true
f727a107c1b6bc630f2298f8758fa301408ca175
105
py
Python
wrapcord/__init__.py
nsde/wrapcord
d9a6225085a658a630a9527edb4fa7b991657856
[ "MIT" ]
null
null
null
wrapcord/__init__.py
nsde/wrapcord
d9a6225085a658a630a9527edb4fa7b991657856
[ "MIT" ]
null
null
null
wrapcord/__init__.py
nsde/wrapcord
d9a6225085a658a630a9527edb4fa7b991657856
[ "MIT" ]
null
null
null
from .channel import Channel from .guild import Guild from .message import Message from .user import User
26.25
28
0.819048
from .channel import Channel from .guild import Guild from .message import Message from .user import User
true
true
f727a133e51c2b5e804c815e0c981bdfa6b73676
3,793
py
Python
pyleecan/GUI/Dialog/DMachineSetup/SWSlot/PWSlot15/Gen_PWSlot15.py
IrakozeFD/pyleecan
5a93bd98755d880176c1ce8ac90f36ca1b907055
[ "Apache-2.0" ]
95
2019-01-23T04:19:45.000Z
2022-03-17T18:22:10.000Z
pyleecan/GUI/Dialog/DMachineSetup/SWSlot/PWSlot15/Gen_PWSlot15.py
IrakozeFD/pyleecan
5a93bd98755d880176c1ce8ac90f36ca1b907055
[ "Apache-2.0" ]
366
2019-02-20T07:15:08.000Z
2022-03-31T13:37:23.000Z
pyleecan/GUI/Dialog/DMachineSetup/SWSlot/PWSlot15/Gen_PWSlot15.py
IrakozeFD/pyleecan
5a93bd98755d880176c1ce8ac90f36ca1b907055
[ "Apache-2.0" ]
74
2019-01-24T01:47:31.000Z
2022-02-25T05:44:42.000Z
# -*- coding: utf-8 -*- """File generated according to PWSlot15/gen_list.json WARNING! All changes made in this file will be lost! """ from pyleecan.GUI.Dialog.DMachineSetup.SWSlot.PWSlot15.Ui_PWSlot15 import Ui_PWSlot15 class Gen_PWSlot15(Ui_PWSlot15): def setupUi(self, PWSlot15): """Abstract class to up...
30.837398
85
0.594516
from pyleecan.GUI.Dialog.DMachineSetup.SWSlot.PWSlot15.Ui_PWSlot15 import Ui_PWSlot15 class Gen_PWSlot15(Ui_PWSlot15): def setupUi(self, PWSlot15): Ui_PWSlot15.setupUi(self, PWSlot15) txt = self.tr(u"""Slot isthmus width.""") self.in_W0.setWhatsThis(txt) self.in_W0.setToo...
true
true
f727a15310a842d4dcb36ff94d72138869d2a3dc
40,610
py
Python
pytorch_lightning/trainer/training_loop.py
MasaYan24/pytorch-lightning
046ac714f6955ed14b831657ea1b7b16bc28ac93
[ "Apache-2.0" ]
1
2021-08-05T01:45:26.000Z
2021-08-05T01:45:26.000Z
pytorch_lightning/trainer/training_loop.py
MasaYan24/pytorch-lightning
046ac714f6955ed14b831657ea1b7b16bc28ac93
[ "Apache-2.0" ]
null
null
null
pytorch_lightning/trainer/training_loop.py
MasaYan24/pytorch-lightning
046ac714f6955ed14b831657ea1b7b16bc28ac93
[ "Apache-2.0" ]
1
2021-02-16T00:47:46.000Z
2021-02-16T00:47:46.000Z
# Copyright The PyTorch Lightning team. # # 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 i...
42.747368
119
0.661241
from contextlib import contextmanager, suppress from copy import copy, deepcopy import numpy as np import torch from pytorch_lightning.callbacks import EarlyStopping from pytorch_lightning.core.memory import ModelSummary from pytorch_lightning.core.optimizer import LightningOptimizer from pytorch_lightn...
true
true
f727a25388ee496e5f885a90c81f3d667b3f2d2c
478
py
Python
dev/Gems/CloudGemMetric/v1/AWS/python/windows/Lib/llvmlite/binding/options.py
jeikabu/lumberyard
07228c605ce16cbf5aaa209a94a3cb9d6c1a4115
[ "AML" ]
1,738
2017-09-21T10:59:12.000Z
2022-03-31T21:05:46.000Z
dev/Gems/CloudGemMetric/v1/AWS/python/windows/Lib/llvmlite/binding/options.py
jeikabu/lumberyard
07228c605ce16cbf5aaa209a94a3cb9d6c1a4115
[ "AML" ]
427
2017-09-29T22:54:36.000Z
2022-02-15T19:26:50.000Z
dev/Gems/CloudGemMetric/v1/AWS/python/windows/Lib/llvmlite/binding/options.py
jeikabu/lumberyard
07228c605ce16cbf5aaa209a94a3cb9d6c1a4115
[ "AML" ]
671
2017-09-21T08:04:01.000Z
2022-03-29T14:30:07.000Z
from . import ffi from .common import _encode_string from ctypes import c_char_p def set_option(name, option): """ Set the given LLVM "command-line" option. For example set_option("test", "-debug-pass=Structure") would display all optimization passes when generating code. """ ffi.lib.LLVMPY_S...
26.555556
73
0.692469
from . import ffi from .common import _encode_string from ctypes import c_char_p def set_option(name, option): ffi.lib.LLVMPY_SetCommandLine(_encode_string(name), _encode_string(option)) ffi.lib.LLVMPY_SetCommandLine.argtypes = [c_char_p, c_char_p]
true
true
f727a288f380466a672dfe1936fa261ebf099560
2,761
py
Python
utils.py
gurbaaz27/fb-ai3
8c294845594ea3e3dce3922385de34b77d8e3dad
[ "MIT" ]
null
null
null
utils.py
gurbaaz27/fb-ai3
8c294845594ea3e3dce3922385de34b77d8e3dad
[ "MIT" ]
null
null
null
utils.py
gurbaaz27/fb-ai3
8c294845594ea3e3dce3922385de34b77d8e3dad
[ "MIT" ]
null
null
null
import pyaudio import wave from wit import Wit class Speech2Intent: def __init__(self, access_token): self.client = Wit(access_token) self.headers = {'authorization': 'Bearer '+ access_token, 'Content-Type': 'audio/wav'} def recognize_speech(self, AUDIO_FILENAME, num_seconds ...
33.26506
114
0.532054
import pyaudio import wave from wit import Wit class Speech2Intent: def __init__(self, access_token): self.client = Wit(access_token) self.headers = {'authorization': 'Bearer '+ access_token, 'Content-Type': 'audio/wav'} def recognize_speech(self, AUDIO_FILENAME, num_seconds ...
true
true
f727a2fc3479a82a78afc6c257c0409a5c9b4b20
330
py
Python
Hello_Python/class_electricalcar.py
JaydenYL/Projects
b51c0476f7be80f0b0d6aa84592966ecb4343d76
[ "MIT" ]
5
2021-09-06T04:27:56.000Z
2021-12-14T14:50:27.000Z
Hello_Python/class_electricalcar.py
JaydenYL/Projects
b51c0476f7be80f0b0d6aa84592966ecb4343d76
[ "MIT" ]
null
null
null
Hello_Python/class_electricalcar.py
JaydenYL/Projects
b51c0476f7be80f0b0d6aa84592966ecb4343d76
[ "MIT" ]
null
null
null
from class_car import car class electrical_car(car): def __init__(self, make, model,year): super().__init__(make, model, year) self.battery_volume = 70 # KWh def describe_battery(self): description = 'This car has a '+str(self.battery_volume)+' KWh battery . ' return descripti...
33
82
0.663636
from class_car import car class electrical_car(car): def __init__(self, make, model,year): super().__init__(make, model, year) self.battery_volume = 70 def describe_battery(self): description = 'This car has a '+str(self.battery_volume)+' KWh battery . ' return description.ti...
true
true
f727a38e124401ba01468b18ed046aa832af9abd
1,461
py
Python
backend/berkeleytime/config/semesters/fall2017.py
Boomaa23/berkeleytime
f4c3f41025576056953fb944f5e978df43fa9cdc
[ "MIT" ]
21
2021-03-01T00:31:23.000Z
2022-03-12T06:11:46.000Z
backend/berkeleytime/config/semesters/fall2017.py
Boomaa23/berkeleytime
f4c3f41025576056953fb944f5e978df43fa9cdc
[ "MIT" ]
28
2021-04-07T19:02:37.000Z
2022-03-27T19:11:21.000Z
backend/berkeleytime/config/semesters/fall2017.py
Boomaa23/berkeleytime
f4c3f41025576056953fb944f5e978df43fa9cdc
[ "MIT" ]
4
2021-04-19T00:42:00.000Z
2021-11-30T06:29:59.000Z
"""Configurations for Fall 2016.""" from berkeleytime.config.finals.semesters.fall2017 import * import datetime CURRENT_SEMESTER = 'fall' CURRENT_YEAR = '2017' CURRENT_SEMESTER_DISPLAY = 'Fall 2017' # SIS API Keys SIS_TERM_ID = 2178 TELEBEARS = { 'phase1_start': datetime.datetime(2017, 4, 18), 'phase2_start...
40.583333
89
0.687885
from berkeleytime.config.finals.semesters.fall2017 import * import datetime CURRENT_SEMESTER = 'fall' CURRENT_YEAR = '2017' CURRENT_SEMESTER_DISPLAY = 'Fall 2017' SIS_TERM_ID = 2178 TELEBEARS = { 'phase1_start': datetime.datetime(2017, 4, 18), 'phase2_start': datetime.datetime(2017, 7, 18), 'phase1_end...
true
true
f727a3cd29e902d31223aa1b5f1bbe02c67a9180
4,804
py
Python
features/command_handler.py
DAgostinateur/Woh-Bot-2.0
4e99d97218a59156bacb1669cc1cb6c8807dd5b1
[ "MIT" ]
null
null
null
features/command_handler.py
DAgostinateur/Woh-Bot-2.0
4e99d97218a59156bacb1669cc1cb6c8807dd5b1
[ "MIT" ]
null
null
null
features/command_handler.py
DAgostinateur/Woh-Bot-2.0
4e99d97218a59156bacb1669cc1cb6c8807dd5b1
[ "MIT" ]
null
null
null
import re import discord from commands import set_presence, avatar, erp from commands.admin import list_user_admin, add_user_admin, rm_user_admin from commands.birthday import (set_channel_bd, show_channel_bd, set_user_bd, set_notif_time, list_user_bd, manual_bd_check, show_message_bd, ...
42.513274
113
0.648626
import re import discord from commands import set_presence, avatar, erp from commands.admin import list_user_admin, add_user_admin, rm_user_admin from commands.birthday import (set_channel_bd, show_channel_bd, set_user_bd, set_notif_time, list_user_bd, manual_bd_check, show_message_bd, ...
true
true
f727a444defc0c229318bcae59c50a66a901568f
737
py
Python
handcoding/fire.py
everyevery/programming_study
ff35e97e13953e4d7a26591f7cdb301d3e8e36c6
[ "MIT" ]
null
null
null
handcoding/fire.py
everyevery/programming_study
ff35e97e13953e4d7a26591f7cdb301d3e8e36c6
[ "MIT" ]
null
null
null
handcoding/fire.py
everyevery/programming_study
ff35e97e13953e4d7a26591f7cdb301d3e8e36c6
[ "MIT" ]
1
2017-04-01T21:34:23.000Z
2017-04-01T21:34:23.000Z
import itertools as it def fire(manager_list, salary_list, productivity_list): acc_list = [val[0] - val[1] for val in it.chain([(0,0)], zip(productivity_list, salary_list))][-1::-1] for i, e in it.takewhile(lambda v: v[0] != 0, zip(range(len(acc_list)-1, -1, -1), acc_list)): acc_list[-...
40.944444
97
0.617368
import itertools as it def fire(manager_list, salary_list, productivity_list): acc_list = [val[0] - val[1] for val in it.chain([(0,0)], zip(productivity_list, salary_list))][-1::-1] for i, e in it.takewhile(lambda v: v[0] != 0, zip(range(len(acc_list)-1, -1, -1), acc_list)): acc_list[-...
true
true
f727a4a852b255e576e4ed8f9b5db24f9d41a4fc
27,397
py
Python
openstack_dashboard/test/api_tests/neutron_tests.py
HaManhDong/Custom-Horizon
17513ebbe03b8ae58e0925f826801343e1e3e3e0
[ "Apache-2.0" ]
null
null
null
openstack_dashboard/test/api_tests/neutron_tests.py
HaManhDong/Custom-Horizon
17513ebbe03b8ae58e0925f826801343e1e3e3e0
[ "Apache-2.0" ]
null
null
null
openstack_dashboard/test/api_tests/neutron_tests.py
HaManhDong/Custom-Horizon
17513ebbe03b8ae58e0925f826801343e1e3e3e0
[ "Apache-2.0" ]
null
null
null
# Copyright 2012 NEC Corporation # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or ag...
42.019939
84
0.638756
import copy import uuid from mox3.mox import IsA from django import http from django.test.utils import override_settings from neutronclient.common import exceptions as neutron_exc from openstack_dashboard import api from openstack_dashboard import policy from openstack_dashboard.test import helpers a...
true
true
f727a6fbe910664403fa49773ddc8bc6ca0f017c
3,896
py
Python
cfgs_fatdet/voc/fatnat/ttfnet_fatnet_ttfheadfull_96_10x_aug_no_pretrain.py
Leotju/ttfnet
94eea28ea22215310140caee492d5de2b01b3d04
[ "Apache-2.0" ]
null
null
null
cfgs_fatdet/voc/fatnat/ttfnet_fatnet_ttfheadfull_96_10x_aug_no_pretrain.py
Leotju/ttfnet
94eea28ea22215310140caee492d5de2b01b3d04
[ "Apache-2.0" ]
null
null
null
cfgs_fatdet/voc/fatnat/ttfnet_fatnet_ttfheadfull_96_10x_aug_no_pretrain.py
Leotju/ttfnet
94eea28ea22215310140caee492d5de2b01b3d04
[ "Apache-2.0" ]
null
null
null
# model settings model = dict( type='TTFNet', # pretrained='modelzoo://resnet18', pretrained=None, backbone=dict( type='FatNetSimple', norm_cfg = dict(type='BN', requires_grad=True), ), neck=None, bbox_head=dict( type='TTFHeadFull', inplanes=16, planes=64,...
29.969231
91
0.592402
model = dict( type='TTFNet', pretrained=None, backbone=dict( type='FatNetSimple', norm_cfg = dict(type='BN', requires_grad=True), ), neck=None, bbox_head=dict( type='TTFHeadFull', inplanes=16, planes=64, head_conv=64, down_ratio=1, ...
true
true
f727a95057ac0c7fae2ad50f1000ff55d2fd438e
35,520
py
Python
tests/test_project.py
Anton-Latukha/wakatime
3035a28a3f996a11d928802dcb05844bb0a52655
[ "BSD-3-Clause" ]
1,198
2015-01-02T12:08:49.000Z
2021-10-07T02:46:59.000Z
tests/test_project.py
Anton-Latukha/wakatime
3035a28a3f996a11d928802dcb05844bb0a52655
[ "BSD-3-Clause" ]
249
2015-01-22T13:31:12.000Z
2021-05-01T08:01:22.000Z
tests/test_project.py
Anton-Latukha/wakatime
3035a28a3f996a11d928802dcb05844bb0a52655
[ "BSD-3-Clause" ]
118
2015-01-16T19:13:15.000Z
2021-07-21T15:09:15.000Z
# -*- coding: utf-8 -*- from wakatime.main import execute from wakatime.packages import requests from wakatime.packages.requests.models import Response import logging import os import shutil import tempfile import time from testfixtures import log_capture from wakatime.compat import u, open from wakatime.constants i...
41.788235
147
0.633136
from wakatime.main import execute from wakatime.packages import requests from wakatime.packages.requests.models import Response import logging import os import shutil import tempfile import time from testfixtures import log_capture from wakatime.compat import u, open from wakatime.constants import API_ERROR, SUCCES...
true
true
f727a9f08929b08e1199a143d5fe11d7e1b8cf8a
2,647
py
Python
flask/tutorial/flaskr/blog.py
jianchengwang/todo-python
36bdaf6fae714531946047ececca995d60f86e4a
[ "MIT" ]
null
null
null
flask/tutorial/flaskr/blog.py
jianchengwang/todo-python
36bdaf6fae714531946047ececca995d60f86e4a
[ "MIT" ]
null
null
null
flask/tutorial/flaskr/blog.py
jianchengwang/todo-python
36bdaf6fae714531946047ececca995d60f86e4a
[ "MIT" ]
null
null
null
from flask import ( Blueprint, flash, g, redirect, render_template, request, url_for ) from werkzeug.exceptions import abort from flaskr.auth import login_required from flaskr.db import get_db bp = Blueprint('blog', __name__) @bp.route('/') def index(): db = get_db() posts = db.execute( ...
27.28866
69
0.530412
from flask import ( Blueprint, flash, g, redirect, render_template, request, url_for ) from werkzeug.exceptions import abort from flaskr.auth import login_required from flaskr.db import get_db bp = Blueprint('blog', __name__) @bp.route('/') def index(): db = get_db() posts = db.execute( ...
true
true
f727ad7b679d2e1f9b7546a04cf754276693bc15
418
py
Python
backend/wishlist/settings/development.py
oaguy1/wishlist.vote
3440cc05cfe039e905064fd2dfcb0ae06402e12c
[ "MIT" ]
null
null
null
backend/wishlist/settings/development.py
oaguy1/wishlist.vote
3440cc05cfe039e905064fd2dfcb0ae06402e12c
[ "MIT" ]
null
null
null
backend/wishlist/settings/development.py
oaguy1/wishlist.vote
3440cc05cfe039e905064fd2dfcb0ae06402e12c
[ "MIT" ]
null
null
null
from .base import * DEBUG = True ALLOWED_HOSTS = [] # Database # https://docs.djangoproject.com/en/3.1/ref/settings/#databases DATABASES = { 'default': { 'ENGINE': 'django.db.backends.postgresql', 'NAME': os.environ.get("POSTGRES_DB"), 'USER': os.environ.get("POSTGRES_USER"), 'P...
20.9
63
0.593301
from .base import * DEBUG = True ALLOWED_HOSTS = [] S = { 'default': { 'ENGINE': 'django.db.backends.postgresql', 'NAME': os.environ.get("POSTGRES_DB"), 'USER': os.environ.get("POSTGRES_USER"), 'PASSWORD': os.environ.get("POSTGRES_PASSWORD"), 'HOST': 'db', 'PORT'...
true
true
f727af1c0db0d85bc6562a4f4ff54917e782503c
1,030
py
Python
annotater/memetext/decorators.py
stricoff92/annotater
8ca471477e2d567945e14f09d3d763d379e7587e
[ "MIT" ]
null
null
null
annotater/memetext/decorators.py
stricoff92/annotater
8ca471477e2d567945e14f09d3d763d379e7587e
[ "MIT" ]
null
null
null
annotater/memetext/decorators.py
stricoff92/annotater
8ca471477e2d567945e14f09d3d763d379e7587e
[ "MIT" ]
null
null
null
from functools import wraps from django.http import HttpResponse from rest_framework.response import Response from rest_framework import status from website.constants import WIDGET_NAMES def user_can_use_web_widget(function): @wraps(function) def decorator(request, *a, **k): if request.user.userpro...
29.428571
80
0.646602
from functools import wraps from django.http import HttpResponse from rest_framework.response import Response from rest_framework import status from website.constants import WIDGET_NAMES def user_can_use_web_widget(function): @wraps(function) def decorator(request, *a, **k): if request.user.userpro...
true
true
f727af8237ad53753e4c67cd9224b1cb5ed49267
4,059
py
Python
tests/module/fetch/test_init.py
mgorny/pkgcore
ab4a718aa1626f4edeb385383f5595a1e262b0dc
[ "BSD-3-Clause" ]
null
null
null
tests/module/fetch/test_init.py
mgorny/pkgcore
ab4a718aa1626f4edeb385383f5595a1e262b0dc
[ "BSD-3-Clause" ]
null
null
null
tests/module/fetch/test_init.py
mgorny/pkgcore
ab4a718aa1626f4edeb385383f5595a1e262b0dc
[ "BSD-3-Clause" ]
null
null
null
# Copyright: 2006 Brian Harring <ferringb@gmail.com> # License: GPL2/BSD from snakeoil.sequences import iflatten_instance from snakeoil.test import TestCase from pkgcore import fetch class base(TestCase): def assertUri(self, obj, uri): uri = list(uri) self.assertEqual(list(iflatten_instance(obj...
32.472
80
0.614437
from snakeoil.sequences import iflatten_instance from snakeoil.test import TestCase from pkgcore import fetch class base(TestCase): def assertUri(self, obj, uri): uri = list(uri) self.assertEqual(list(iflatten_instance(obj)), uri) if uri: self.assertTrue(obj) else:...
true
true
f727aff556ad2c85d3ab130a226c9d8be9a26bce
5,527
py
Python
Practice/adapter_roberta_v4/adapter_model.py
accordproject/labs-cicero-classify
3a52ebaf45252515c417bf94a05e33fc1c2628b8
[ "Apache-2.0" ]
2
2021-07-07T01:06:18.000Z
2021-11-12T18:54:21.000Z
Practice/adapter_roberta_v4/adapter_model.py
accordproject/labs_cicero_classify
3a52ebaf45252515c417bf94a05e33fc1c2628b8
[ "Apache-2.0" ]
3
2021-06-25T12:40:23.000Z
2022-02-14T13:42:30.000Z
Practice/adapter_roberta_v4/adapter_model.py
accordproject/labs_cicero_classify
3a52ebaf45252515c417bf94a05e33fc1c2628b8
[ "Apache-2.0" ]
null
null
null
import pandas as pd import numpy as np import torch print(f"Torch Version: {torch.__version__}") import transformers print(f"transformers (Adapter) Version: {transformers.__version__}") from transformers import RobertaTokenizer import numpy as np tokenizer = RobertaTokenizer.from_pretrained("roberta-base") from tra...
29.875676
87
0.701646
import pandas as pd import numpy as np import torch print(f"Torch Version: {torch.__version__}") import transformers print(f"transformers (Adapter) Version: {transformers.__version__}") from transformers import RobertaTokenizer import numpy as np tokenizer = RobertaTokenizer.from_pretrained("roberta-base") from tra...
true
true
f727b1c8a4f7b616a8ac216e156b396852c3e415
23,151
py
Python
src/python/WMCore/MicroService/MSTransferor/RequestInfo.py
vkuznet/WMCore
001cc51651052405a7ecd811cde91da611b1dc57
[ "Apache-2.0" ]
null
null
null
src/python/WMCore/MicroService/MSTransferor/RequestInfo.py
vkuznet/WMCore
001cc51651052405a7ecd811cde91da611b1dc57
[ "Apache-2.0" ]
1
2018-10-30T16:23:07.000Z
2018-10-30T16:23:07.000Z
src/python/WMCore/MicroService/MSTransferor/RequestInfo.py
vkuznet/WMCore
001cc51651052405a7ecd811cde91da611b1dc57
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python """ _RequestInfo_ Class to hold and parse all information related to a given request """ # futures from __future__ import division, print_function from future.utils import viewitems # system modules import datetime import time # WMCore modules from pprint import pformat from copy import deepcopy...
48.03112
118
0.619066
from __future__ import division, print_function from future.utils import viewitems import datetime import time from pprint import pformat from copy import deepcopy from Utils.IteratorTools import grouper from WMCore.DataStructs.LumiList import LumiList from WMCore.MicroService.MSTransferor.Workflow import Workflow...
true
true
f727b49174b3a60786564bef9812ead45c308098
1,363
py
Python
database/migrations/0016_auto_20190113_0449.py
ccraddock/beiwe-backend-cc
b37c2604800aafcf81c93bc14673ada6aed17a39
[ "BSD-3-Clause" ]
null
null
null
database/migrations/0016_auto_20190113_0449.py
ccraddock/beiwe-backend-cc
b37c2604800aafcf81c93bc14673ada6aed17a39
[ "BSD-3-Clause" ]
null
null
null
database/migrations/0016_auto_20190113_0449.py
ccraddock/beiwe-backend-cc
b37c2604800aafcf81c93bc14673ada6aed17a39
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by Django 1.11.5 on 2019-01-13 04:49 from __future__ import unicode_literals from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('database', '0015_auto_20190112_0251'), ] operation...
38.942857
159
0.623624
from __future__ import unicode_literals from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('database', '0015_auto_20190112_0251'), ] operations = [ migrations.CreateModel( name='ReceivedDataSta...
true
true
f727b5c41eac8de45cd42818ceedba94bf6fbdec
427
py
Python
Extra Exercises/artbyraza.py
luizpavanello/python_udacity
6411af82db8123e5b6b731c5a3bced2c31dc2c57
[ "MIT" ]
null
null
null
Extra Exercises/artbyraza.py
luizpavanello/python_udacity
6411af82db8123e5b6b731c5a3bced2c31dc2c57
[ "MIT" ]
null
null
null
Extra Exercises/artbyraza.py
luizpavanello/python_udacity
6411af82db8123e5b6b731c5a3bced2c31dc2c57
[ "MIT" ]
null
null
null
import turtle t = turtle.Turtle() turtle.bgcolor('black') def triangle(): t.forward(100) t.left(120) t.forward(100) t.left(120) t.forward(100) t.left(120) t.forward(100) t.speed(0) t.pencolor('red') t.penup() t.goto(-350,250) t.pendown() for numbers in range(7): x = 250 - (86*numbers) ...
17.791667
27
0.59719
import turtle t = turtle.Turtle() turtle.bgcolor('black') def triangle(): t.forward(100) t.left(120) t.forward(100) t.left(120) t.forward(100) t.left(120) t.forward(100) t.speed(0) t.pencolor('red') t.penup() t.goto(-350,250) t.pendown() for numbers in range(7): x = 250 - (86*numbers) ...
true
true
f727b654f4653c3f574ae05040ca03e4ed0356f1
1,821
py
Python
setup.py
pauleveritt/wired
629f950176a9682a7ccb68efbb27cb2e23b4e93e
[ "MIT" ]
1
2021-01-09T00:05:54.000Z
2021-01-09T00:05:54.000Z
setup.py
pauleveritt/wired
629f950176a9682a7ccb68efbb27cb2e23b4e93e
[ "MIT" ]
null
null
null
setup.py
pauleveritt/wired
629f950176a9682a7ccb68efbb27cb2e23b4e93e
[ "MIT" ]
1
2019-04-22T14:22:39.000Z
2019-04-22T14:22:39.000Z
from setuptools import setup, find_packages def readfile(name): with open(name) as f: return f.read() readme = readfile('README.rst') changes = readfile('CHANGES.rst') requires = ['zope.interface'] docs_require = ['Sphinx', 'sphinx_rtd_theme'] tests_require = ['pytest', 'pytest-cov', 'venusian', 'syb...
29.852459
74
0.606809
from setuptools import setup, find_packages def readfile(name): with open(name) as f: return f.read() readme = readfile('README.rst') changes = readfile('CHANGES.rst') requires = ['zope.interface'] docs_require = ['Sphinx', 'sphinx_rtd_theme'] tests_require = ['pytest', 'pytest-cov', 'venusian', 'syb...
true
true
f727b7bdfdf05c7eb3a30b160d05ef9a20097bfc
227,887
py
Python
src/borg/testsuite/archiver.py
adrian5/borg
6f371d5522e515c738340c2cd6dc2473b644c4d2
[ "BSD-3-Clause" ]
1
2021-03-20T15:13:11.000Z
2021-03-20T15:13:11.000Z
src/borg/testsuite/archiver.py
adrian5/borg
6f371d5522e515c738340c2cd6dc2473b644c4d2
[ "BSD-3-Clause" ]
9
2020-12-05T01:08:44.000Z
2021-04-19T23:06:12.000Z
src/borg/testsuite/archiver.py
adrian5/borg
6f371d5522e515c738340c2cd6dc2473b644c4d2
[ "BSD-3-Clause" ]
null
null
null
import argparse import dateutil.tz import errno import io import json import logging import os import pstats import random import re import shutil import socket import stat import subprocess import sys import tempfile import time import unittest from binascii import unhexlify, b2a_base64 from configparser import Config...
51.418547
148
0.630304
import argparse import dateutil.tz import errno import io import json import logging import os import pstats import random import re import shutil import socket import stat import subprocess import sys import tempfile import time import unittest from binascii import unhexlify, b2a_base64 from configparser import Config...
true
true
f727b88af81bc3a82c519d895f95d0e68a9f59ab
1,583
py
Python
sandbox/lib/jumpscale/JumpScale9Lib/clients/atyourservice/ays/ClientFactory.py
Jumpscale/sandbox_linux
2aacd36b467ef30ac83718abfa82c6883b67a02f
[ "Apache-2.0" ]
2
2017-06-07T08:11:47.000Z
2017-11-10T02:19:48.000Z
JumpScale9Lib/clients/atyourservice/ays/ClientFactory.py
Jumpscale/lib9
82224784ef2a7071faeb48349007211c367bc673
[ "Apache-2.0" ]
188
2017-06-21T06:16:13.000Z
2020-06-17T14:20:24.000Z
sandbox/lib/jumpscale/JumpScale9Lib/clients/atyourservice/ays/ClientFactory.py
Jumpscale/sandbox_linux
2aacd36b467ef30ac83718abfa82c6883b67a02f
[ "Apache-2.0" ]
3
2018-06-12T05:18:28.000Z
2019-09-24T06:49:17.000Z
from js9 import j from .client import Client JSConfigBase = j.tools.configmanager.base_class_configs JSBASE = j.application.jsbase_get_class() class ClientFactory(JSConfigBase): def __init__(self): self.__jslocation__ = 'j.clients.ays' JSConfigBase.__init__(self, Client) # def get(self, url...
45.228571
140
0.672142
from js9 import j from .client import Client JSConfigBase = j.tools.configmanager.base_class_configs JSBASE = j.application.jsbase_get_class() class ClientFactory(JSConfigBase): def __init__(self): self.__jslocation__ = 'j.clients.ays' JSConfigBase.__init__(self, Client) # Get...
true
true
f727b91907659f8e5e86ad39633e0f340dedda64
3,175
py
Python
models/object_detection/model_templates/horizontal-text-detection/tools/draw_recall_graph.py
dqawami/openvino_training_extensions
dddda1dfd651eaae2d59cecda84275b1b03bd0ad
[ "Apache-2.0" ]
256
2020-09-09T03:27:57.000Z
2022-03-30T10:06:06.000Z
models/object_detection/model_templates/horizontal-text-detection/tools/draw_recall_graph.py
dqawami/openvino_training_extensions
dddda1dfd651eaae2d59cecda84275b1b03bd0ad
[ "Apache-2.0" ]
604
2020-09-08T12:29:49.000Z
2022-03-31T21:51:08.000Z
models/object_detection/model_templates/horizontal-text-detection/tools/draw_recall_graph.py
dqawami/openvino_training_extensions
dddda1dfd651eaae2d59cecda84275b1b03bd0ad
[ "Apache-2.0" ]
160
2020-09-09T14:06:07.000Z
2022-03-30T14:50:48.000Z
# Copyright (C) 2020 Intel Corporation # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in wri...
36.918605
99
0.68
import argparse from os.path import exists import subprocess import mmcv from mmdet.datasets import build_dataset from mmdet.core.evaluation.text_evaluation import text_eval def parse_args(): parser = argparse.ArgumentParser( description='This script draws a histogram of the detected wo...
true
true
f727b9d4cab59ebd33276d381d0c931725d42173
2,391
py
Python
session8/bloomfilter.py
zhiweih/pb-exercises
c5e64075c47503a40063aa836c06a452af14246d
[ "BSD-2-Clause" ]
153
2017-09-27T01:10:19.000Z
2022-03-17T12:13:59.000Z
session8/bloomfilter.py
zhiweih/pb-exercises
c5e64075c47503a40063aa836c06a452af14246d
[ "BSD-2-Clause" ]
3
2018-11-10T20:04:13.000Z
2022-02-15T23:12:53.000Z
session8/bloomfilter.py
zhiweih/pb-exercises
c5e64075c47503a40063aa836c06a452af14246d
[ "BSD-2-Clause" ]
85
2017-10-09T16:18:00.000Z
2022-02-09T14:21:08.000Z
from unittest import TestCase from helper import bit_field_to_bytes, encode_varint, int_to_little_endian, murmur3 from network import GenericMessage BIP37_CONSTANT = 0xfba4c795 class BloomFilter: def __init__(self, size, function_count, tweak): self.size = size self.bit_field = [0] * (size * 8...
34.157143
83
0.634463
from unittest import TestCase from helper import bit_field_to_bytes, encode_varint, int_to_little_endian, murmur3 from network import GenericMessage BIP37_CONSTANT = 0xfba4c795 class BloomFilter: def __init__(self, size, function_count, tweak): self.size = size self.bit_field = [0] * (size * 8...
true
true
f727ba6681f8dfea391e57c63b138af4829f136b
301
py
Python
Communication/temp_driver.py
Forence1999/SmartWalker
635410bf44234eead9fd1e2fe226eb8eafa9d27d
[ "MIT" ]
2
2021-11-13T14:16:06.000Z
2022-01-12T06:07:32.000Z
Communication/temp_driver.py
Forence1999/SmartWalker
635410bf44234eead9fd1e2fe226eb8eafa9d27d
[ "MIT" ]
null
null
null
Communication/temp_driver.py
Forence1999/SmartWalker
635410bf44234eead9fd1e2fe226eb8eafa9d27d
[ "MIT" ]
3
2021-08-30T04:40:39.000Z
2022-01-09T11:34:04.000Z
import os, sys pwd = os.path.abspath(os.path.abspath(__file__)) father_path = os.path.abspath(os.path.dirname(pwd) + os.path.sep + "..") sys.path.append(father_path) from Communication.Modules.Driver_recv import DriverRecv if __name__ == "__main__": drv_recv = DriverRecv() drv_recv.start()
27.363636
72
0.734219
import os, sys pwd = os.path.abspath(os.path.abspath(__file__)) father_path = os.path.abspath(os.path.dirname(pwd) + os.path.sep + "..") sys.path.append(father_path) from Communication.Modules.Driver_recv import DriverRecv if __name__ == "__main__": drv_recv = DriverRecv() drv_recv.start()
true
true
f727bb216c7cc0427cc558d690825ceffb291a96
4,961
py
Python
src/vw/tools/extract_modis_images.py
maxerbubba/visionworkbench
b06ba0597cd3864bb44ca52671966ca580c02af1
[ "Apache-2.0" ]
318
2015-01-02T16:37:34.000Z
2022-03-17T07:12:20.000Z
src/vw/tools/extract_modis_images.py
maxerbubba/visionworkbench
b06ba0597cd3864bb44ca52671966ca580c02af1
[ "Apache-2.0" ]
39
2015-07-30T22:22:42.000Z
2021-03-23T16:11:55.000Z
src/vw/tools/extract_modis_images.py
maxerbubba/visionworkbench
b06ba0597cd3864bb44ca52671966ca580c02af1
[ "Apache-2.0" ]
135
2015-01-19T00:57:20.000Z
2022-03-18T13:51:40.000Z
#!/usr/bin/env python # __BEGIN_LICENSE__ # Copyright (c) 2006-2013, United States Government as represented by the # Administrator of the National Aeronautics and Space Administration. All # rights reserved. # # The NASA Vision Workbench is licensed under the Apache License, # Version 2.0 (the "License"); you may...
28.511494
90
0.555936
subprocess DESIRED_CHANNELS = ['sur_refl_b01_1', 'sur_refl_b02_1', 'sur_refl_b03_1', 'sur_refl_b04_1', 'sur_refl_b05_1', 'sur_refl_b06_1', 'sur_refl_b07_1', 'QC_500m_1',...
false
true
f727bbf4f042610f878f6f2a4448221ae54ed568
147
py
Python
yc166/525.py
c-yan/yukicoder
cdbbd65402177225dd989df7fe01f67908484a69
[ "MIT" ]
null
null
null
yc166/525.py
c-yan/yukicoder
cdbbd65402177225dd989df7fe01f67908484a69
[ "MIT" ]
null
null
null
yc166/525.py
c-yan/yukicoder
cdbbd65402177225dd989df7fe01f67908484a69
[ "MIT" ]
null
null
null
T = input() hh, mm = map(int, T.split(':')) mm += 5 if mm > 59: hh += 1 mm %= 60 if hh > 23: hh %= 24 print('%02d:%02d' % (hh, mm))
11.307692
31
0.428571
T = input() hh, mm = map(int, T.split(':')) mm += 5 if mm > 59: hh += 1 mm %= 60 if hh > 23: hh %= 24 print('%02d:%02d' % (hh, mm))
true
true
f727bc6b391386643fcb9047d7e3f34d29e75ee1
3,712
py
Python
intersight/models/hyperflex_ucsm_config_policy_ref.py
ategaw-cisco/intersight-python
9d6476620507281b1dc358e29ac452d56081bbb0
[ "Apache-2.0" ]
null
null
null
intersight/models/hyperflex_ucsm_config_policy_ref.py
ategaw-cisco/intersight-python
9d6476620507281b1dc358e29ac452d56081bbb0
[ "Apache-2.0" ]
null
null
null
intersight/models/hyperflex_ucsm_config_policy_ref.py
ategaw-cisco/intersight-python
9d6476620507281b1dc358e29ac452d56081bbb0
[ "Apache-2.0" ]
null
null
null
# coding: utf-8 """ Intersight REST API This is Intersight REST API OpenAPI spec version: 1.0.9-262 Generated by: https://github.com/swagger-api/swagger-codegen.git """ from pprint import pformat from six import iteritems import re class HyperflexUcsmConfigPolicyRef(object): """ NOT...
24.746667
81
0.554149
from pprint import pformat from six import iteritems import re class HyperflexUcsmConfigPolicyRef(object): swagger_types = { 'moid': 'str', 'object_type': 'str' } attribute_map = { 'moid': 'Moid', 'object_type': 'ObjectType' } def __init__(self, moid=None, o...
true
true
f727bc6fd1864b3db8c69008ff273cd86317a3fd
545
py
Python
conda_verify/package/test_files.py
soapy1/conda-verify
4941b8ea37bf4afa5ca16366ae855f756037f230
[ "BSD-3-Clause" ]
null
null
null
conda_verify/package/test_files.py
soapy1/conda-verify
4941b8ea37bf4afa5ca16366ae855f756037f230
[ "BSD-3-Clause" ]
null
null
null
conda_verify/package/test_files.py
soapy1/conda-verify
4941b8ea37bf4afa5ca16366ae855f756037f230
[ "BSD-3-Clause" ]
1
2020-02-03T12:43:17.000Z
2020-02-03T12:43:17.000Z
from conda_verify.conda_package_check import CondaPackageCheck def verify(path_to_package=None, verbose=True, **kwargs): package_check = CondaPackageCheck(path_to_package, verbose) package_check.info_files() package_check.no_hardlinks() package_check.not_allowed_files() package_check.index_json() ...
34.0625
78
0.774312
from conda_verify.conda_package_check import CondaPackageCheck def verify(path_to_package=None, verbose=True, **kwargs): package_check = CondaPackageCheck(path_to_package, verbose) package_check.info_files() package_check.no_hardlinks() package_check.not_allowed_files() package_check.index_json() ...
true
true
f727be7b1536a7590641b1a6b3f2745fd7b98775
433
py
Python
src/batch_iterator.py
thealah/imdb-import
fd51d7fbefc419c134277bc0c85b59dcbb457350
[ "MIT" ]
null
null
null
src/batch_iterator.py
thealah/imdb-import
fd51d7fbefc419c134277bc0c85b59dcbb457350
[ "MIT" ]
null
null
null
src/batch_iterator.py
thealah/imdb-import
fd51d7fbefc419c134277bc0c85b59dcbb457350
[ "MIT" ]
null
null
null
def batch_iterator(iterable, size=100, filter_expression=None): current_batch = [] for x in iterable: if filter_expression: if filter_expression(x): current_batch.append(x) else: current_batch.append(x) if len(current_batch) == size: ...
27.0625
63
0.575058
def batch_iterator(iterable, size=100, filter_expression=None): current_batch = [] for x in iterable: if filter_expression: if filter_expression(x): current_batch.append(x) else: current_batch.append(x) if len(current_batch) == size: ...
true
true
f727be9a5c7b0dee1552109b912eec3664b93ab0
3,227
py
Python
exavault/models/share_relationships_notification.py
ExaVault/evapi-python
769bfa9fbb683f2b4653ca2564029ffb72445c8c
[ "MIT" ]
null
null
null
exavault/models/share_relationships_notification.py
ExaVault/evapi-python
769bfa9fbb683f2b4653ca2564029ffb72445c8c
[ "MIT" ]
3
2017-07-13T20:58:05.000Z
2019-08-02T19:08:37.000Z
exavault/models/share_relationships_notification.py
ExaVault/evapi-python
769bfa9fbb683f2b4653ca2564029ffb72445c8c
[ "MIT" ]
4
2016-11-16T00:14:23.000Z
2020-09-24T14:50:46.000Z
# coding: utf-8 """ ExaVault API See our API reference documentation at https://www.exavault.com/developer/api-docs/ # noqa: E501 OpenAPI spec version: 2.0 Contact: support@exavault.com Generated by: https://github.com/swagger-api/swagger-codegen.git """ import pprint import re # noqa: F401 i...
29.072072
101
0.575147
import pprint import re import six class ShareRelationshipsNotification(object): swagger_types = { 'data': 'ShareRelationshipsData' } attribute_map = { 'data': 'data' } def __init__(self, data=None): self._data = None self.discriminator = None if da...
true
true
f727bf0787af05ae30dd3c315f89a1ffc68b1a5f
126
py
Python
models.py
banr1jnts/kaggle-youtube2nd
21248d563afcf707cc7665703a987d71c94f4c5a
[ "MIT" ]
null
null
null
models.py
banr1jnts/kaggle-youtube2nd
21248d563afcf707cc7665703a987d71c94f4c5a
[ "MIT" ]
null
null
null
models.py
banr1jnts/kaggle-youtube2nd
21248d563afcf707cc7665703a987d71c94f4c5a
[ "MIT" ]
null
null
null
class BaseModel(object): def create_model(self, unused_model_input, **unused_params): raise NotImplementedError()
31.5
64
0.746032
class BaseModel(object): def create_model(self, unused_model_input, **unused_params): raise NotImplementedError()
true
true