hexsha
stringlengths
40
40
size
int64
2
1.02M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
245
max_stars_repo_name
stringlengths
6
130
max_stars_repo_head_hexsha
stringlengths
40
40
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
4
245
max_issues_repo_name
stringlengths
6
130
max_issues_repo_head_hexsha
stringlengths
40
40
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
67k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
4
245
max_forks_repo_name
stringlengths
6
130
max_forks_repo_head_hexsha
stringlengths
40
40
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
2
1.02M
avg_line_length
float64
1
958k
max_line_length
int64
1
987k
alphanum_fraction
float64
0
1
content_no_comment
stringlengths
0
1.01M
is_comment_constant_removed
bool
2 classes
is_sharp_comment_removed
bool
1 class
1c378ada774d53aace7e40b7dd9258579b413e9b
1,385
py
Python
source/02_scattering_sphere/radialwave_scattering_porous_coupling/exact/__init__.py
ROMSOC/benchmarks-acoustic-propagation
14dbe64c0279d25053e17c63b3797d6395cd50cc
[ "MIT" ]
2
2021-09-21T15:46:17.000Z
2022-03-10T02:18:56.000Z
source/02_scattering_sphere/radialwave_scattering_porous_coupling/exact/__init__.py
ROMSOC/benchmarks-acoustic-propagation
14dbe64c0279d25053e17c63b3797d6395cd50cc
[ "MIT" ]
null
null
null
source/02_scattering_sphere/radialwave_scattering_porous_coupling/exact/__init__.py
ROMSOC/benchmarks-acoustic-propagation
14dbe64c0279d25053e17c63b3797d6395cd50cc
[ "MIT" ]
1
2021-09-02T00:48:51.000Z
2021-09-02T00:48:51.000Z
# ------------------------------------------------------------------ # # ╦═╗╔═╗╔╦╗╔═╗╔═╗╔═╗ # ╠╦╝║ ║║║║╚═╗║ ║║ # ╩╚═╚═╝╩ ╩╚═╝╚═╝╚═╝ # Reduced Order Modelling, Simulation, Optimization of Coupled Systems # 2017-2021 #...
49.464286
72
0.592058
true
true
1c378b561a90a4ed274c10b232748a03260b27d9
893
py
Python
src/clusto/test/base/countertests.py
thekad/clusto
c141ea3ef4931c6a21fdf42845c6e9de5ee08caa
[ "BSD-3-Clause" ]
216
2015-01-10T17:03:25.000Z
2022-03-24T07:23:41.000Z
src/clusto/test/base/countertests.py
thekad/clusto
c141ea3ef4931c6a21fdf42845c6e9de5ee08caa
[ "BSD-3-Clause" ]
23
2015-01-08T16:51:22.000Z
2021-03-13T12:56:04.000Z
src/clusto/test/base/countertests.py
thekad/clusto
c141ea3ef4931c6a21fdf42845c6e9de5ee08caa
[ "BSD-3-Clause" ]
49
2015-01-08T00:13:17.000Z
2021-09-22T02:01:20.000Z
from clusto.test import testbase from clusto.schema import * from clusto.drivers.base import * class TestClustoCounter(testbase.ClustoTestBase): def testCounterDefault(self): e = Entity('e1') c = Counter(e, 'key1') self.assertEqual(c.value, 0) d = Counter(e, 'key2', start=10) ...
19
49
0.546473
from clusto.test import testbase from clusto.schema import * from clusto.drivers.base import * class TestClustoCounter(testbase.ClustoTestBase): def testCounterDefault(self): e = Entity('e1') c = Counter(e, 'key1') self.assertEqual(c.value, 0) d = Counter(e, 'key2', start=10) ...
true
true
1c378c5f2091666db2d57ad3a5c5280de537cbe5
30
py
Python
auto_schema/fields/__init__.py
tingiskhan/auto-schema
9b6f332347c4283c8d5033c0d7d0085f5ae8e817
[ "MIT" ]
null
null
null
auto_schema/fields/__init__.py
tingiskhan/auto-schema
9b6f332347c4283c8d5033c0d7d0085f5ae8e817
[ "MIT" ]
null
null
null
auto_schema/fields/__init__.py
tingiskhan/auto-schema
9b6f332347c4283c8d5033c0d7d0085f5ae8e817
[ "MIT" ]
null
null
null
from .bytes import BytesField
15
29
0.833333
from .bytes import BytesField
true
true
1c378c93d96d1105b11fbdbe2322d0ec1f5c6a2f
1,368
py
Python
training/distributed_training/pytorch/data_parallel/rnnt/entry_point.py
pollyrolly/amazon-sagemaker-examples
b1a56b4dc96201b769f7bbc1e207649423874586
[ "Apache-2.0" ]
2,610
2020-10-01T14:14:53.000Z
2022-03-31T18:02:31.000Z
training/distributed_training/pytorch/data_parallel/rnnt/entry_point.py
pollyrolly/amazon-sagemaker-examples
b1a56b4dc96201b769f7bbc1e207649423874586
[ "Apache-2.0" ]
1,959
2020-09-30T20:22:42.000Z
2022-03-31T23:58:37.000Z
training/distributed_training/pytorch/data_parallel/rnnt/entry_point.py
pollyrolly/amazon-sagemaker-examples
b1a56b4dc96201b769f7bbc1e207649423874586
[ "Apache-2.0" ]
2,052
2020-09-30T22:11:46.000Z
2022-03-31T23:02:51.000Z
# Copyright 2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file # except in compliance with the License. A copy of the License is located at # # http://aws.amazon.com/apache2.0/ # # or in the "LICENSE.txt" file accom...
44.129032
312
0.72807
import subprocess import sys import os exe = 'python' trainer = '/workspace/rnnt/train.py' cmd_list = [exe] + [trainer] + sys.argv[1:] cmd = ' '.join(cmd_list) cmd += ' ' cmd += '--dataset_dir ' + os.environ['SM_CHANNEL_TRAIN'] + '/datasets/LibriSpeech/ ' cmd += '--output_dir ' + os.environ['SM_OUTPUT_DI...
true
true
1c378ca3536f50fbfdd74c7034b89973888a448c
31
py
Python
confu/arm/__init__.py
tiny-dnn/confu
8f74d9fc0c04efe8cd1b92ae5f43a5d9b686500e
[ "MIT" ]
null
null
null
confu/arm/__init__.py
tiny-dnn/confu
8f74d9fc0c04efe8cd1b92ae5f43a5d9b686500e
[ "MIT" ]
null
null
null
confu/arm/__init__.py
tiny-dnn/confu
8f74d9fc0c04efe8cd1b92ae5f43a5d9b686500e
[ "MIT" ]
1
2020-11-16T18:06:25.000Z
2020-11-16T18:06:25.000Z
from confu.arm.isa import neon
15.5
30
0.806452
from confu.arm.isa import neon
true
true
1c378d3c6a81d3459ec458dc9e030a7377f7e716
1,235
py
Python
glob/setup.py
stlehmann/micropython-lib
fcbf03b152a56f091361cefc7857b4c39891d1a8
[ "PSF-2.0" ]
null
null
null
glob/setup.py
stlehmann/micropython-lib
fcbf03b152a56f091361cefc7857b4c39891d1a8
[ "PSF-2.0" ]
null
null
null
glob/setup.py
stlehmann/micropython-lib
fcbf03b152a56f091361cefc7857b4c39891d1a8
[ "PSF-2.0" ]
null
null
null
import sys # Remove current dir from sys.path, otherwise setuptools will peek up our # module instead of system's. sys.path.pop(0) from setuptools import setup sys.path.append("..") import sdist_upip setup(name='micropython-glob', version='0.5.2', description='CPython glob module ported to MicroPython', ...
56.136364
502
0.746559
import sys sys.path.pop(0) from setuptools import setup sys.path.append("..") import sdist_upip setup(name='micropython-glob', version='0.5.2', description='CPython glob module ported to MicroPython', long_description='This is a module ported from CPython standard library to be compatible with\nMic...
true
true
1c378d69144dec8341b85ba869b0dc66a0e68f41
36,535
py
Python
stockstats.py
Arsh0023/stockstats
3b13bc74b2106d1a5ebbb6f456344abc3a06ed0e
[ "BSD-3-Clause" ]
null
null
null
stockstats.py
Arsh0023/stockstats
3b13bc74b2106d1a5ebbb6f456344abc3a06ed0e
[ "BSD-3-Clause" ]
null
null
null
stockstats.py
Arsh0023/stockstats
3b13bc74b2106d1a5ebbb6f456344abc3a06ed0e
[ "BSD-3-Clause" ]
1
2021-07-24T05:37:47.000Z
2021-07-24T05:37:47.000Z
# coding=utf-8 # Copyright (c) 2016, Cedric Zhuang # All rights reserved. # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # # * Redistributions of source code must retain the above copyright # notice, thi...
33.703875
132
0.545669
from __future__ import unicode_literals import itertools import logging import operator import random import re import numpy as np import pandas as pd from int_date import get_date_from_diff __author__ = 'Cedric Zhuang' log = logging.getLogger(__name__) class StockDataF...
true
true
1c378dcd7d771f6a5c43a3d42e3f42f3b2bf271c
202
py
Python
pra subir/pythonexercicios/ex57.py
daianebandeira88/curso-python
763f5f36b6d7329549ad861c63acc3c84aade887
[ "MIT" ]
null
null
null
pra subir/pythonexercicios/ex57.py
daianebandeira88/curso-python
763f5f36b6d7329549ad861c63acc3c84aade887
[ "MIT" ]
null
null
null
pra subir/pythonexercicios/ex57.py
daianebandeira88/curso-python
763f5f36b6d7329549ad861c63acc3c84aade887
[ "MIT" ]
null
null
null
s='' while s != 'm' and s !='f': s=str(input('qual seu sexo? [ m / f ]:')).lower() if s == 'm': print('vc é do sexo masculino') if s == 'f': print('vc é do sexo feminino')
18.363636
53
0.460396
s='' while s != 'm' and s !='f': s=str(input('qual seu sexo? [ m / f ]:')).lower() if s == 'm': print('vc é do sexo masculino') if s == 'f': print('vc é do sexo feminino')
true
true
1c378e6069e3f1a5bf7f2371219eeaf92876d2c0
36,627
py
Python
infra/bots/recipes/test.py
InvictrixRom/external_skia
5d1778b530aa0b845b8d6996815665f7cc44bf38
[ "BSD-3-Clause" ]
null
null
null
infra/bots/recipes/test.py
InvictrixRom/external_skia
5d1778b530aa0b845b8d6996815665f7cc44bf38
[ "BSD-3-Clause" ]
null
null
null
infra/bots/recipes/test.py
InvictrixRom/external_skia
5d1778b530aa0b845b8d6996815665f7cc44bf38
[ "BSD-3-Clause" ]
7
2017-09-30T23:06:11.000Z
2019-05-30T08:54:33.000Z
# Copyright 2016 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. # Recipe module for Skia Swarming test. DEPS = [ 'core', 'env', 'flavor', 'recipe_engine/context', 'recipe_engine/file', 'recipe_engine/json',...
38.35288
99
0.62413
DEPS = [ 'core', 'env', 'flavor', 'recipe_engine/context', 'recipe_engine/file', 'recipe_engine/json', 'recipe_engine/path', 'recipe_engine/platform', 'recipe_engine/properties', 'recipe_engine/python', 'recipe_engine/raw_io', 'recipe_engine/step', 'run', 'vars', ] def dm_flags(api...
true
true
1c378ff86090ecf7c67520a02e1303f2b422df6c
8,193
py
Python
tfx/examples/chicago_taxi/preprocess.py
MattMorgis/tfx
f11cc054f079c998a52002e14b6ba74063fed986
[ "Apache-2.0" ]
1
2019-04-05T19:39:53.000Z
2019-04-05T19:39:53.000Z
tfx/examples/chicago_taxi/preprocess.py
MattMorgis/tfx
f11cc054f079c998a52002e14b6ba74063fed986
[ "Apache-2.0" ]
null
null
null
tfx/examples/chicago_taxi/preprocess.py
MattMorgis/tfx
f11cc054f079c998a52002e14b6ba74063fed986
[ "Apache-2.0" ]
null
null
null
# Copyright 2019 Google LLC. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or ...
36.575893
80
0.695106
from __future__ import absolute_import from __future__ import division from __future__ import print_function import argparse import os import apache_beam as beam import tensorflow as tf import tensorflow_transform as transform import tensorflow_transform.beam as tft_beam from tensorflow_transform.coder...
true
true
1c3790343ce0bc0f3bce26c0c186f3578f1e1cc6
11,054
py
Python
tests/workers/test_module_event_handler.py
glucoseinc/CircleCore
577f814ce2944efb6e5997f3d7838c71ce9aea6a
[ "MIT" ]
3
2019-01-11T04:30:18.000Z
2019-01-11T04:31:18.000Z
tests/workers/test_module_event_handler.py
glucoseinc/CircleCore
577f814ce2944efb6e5997f3d7838c71ce9aea6a
[ "MIT" ]
16
2018-11-21T11:47:18.000Z
2021-09-01T03:52:35.000Z
tests/workers/test_module_event_handler.py
glucoseinc/CircleCore
577f814ce2944efb6e5997f3d7838c71ce9aea6a
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- import base64 import json import mimetypes import os from email.message import EmailMessage from unittest.mock import MagicMock from tornado import httpclient from tornado.gen import sleep from tornado.testing import AsyncHTTPTestCase, gen_test from tornado.web import Application from tornado.w...
35.203822
115
0.599964
import base64 import json import mimetypes import os from email.message import EmailMessage from unittest.mock import MagicMock from tornado import httpclient from tornado.gen import sleep from tornado.testing import AsyncHTTPTestCase, gen_test from tornado.web import Application from tornado.websocket import websock...
true
true
1c37912e81607ea595ce4d0f840633f776e62b45
4,323
py
Python
gnsstools/satellites/galileo.py
arthurdjn/gnsstools
e496093bcecb4b543d5c73b6f5bdfc70b53dbfab
[ "MIT" ]
3
2021-06-21T08:54:23.000Z
2021-12-09T06:39:52.000Z
gnsstools/satellites/galileo.py
yxw027/gnsstools
e496093bcecb4b543d5c73b6f5bdfc70b53dbfab
[ "MIT" ]
null
null
null
gnsstools/satellites/galileo.py
yxw027/gnsstools
e496093bcecb4b543d5c73b6f5bdfc70b53dbfab
[ "MIT" ]
3
2021-03-14T01:43:15.000Z
2022-01-13T04:12:38.000Z
# File: galileo.py # Creation: Sunday January 24th 2021 # Author: Arthur Dujardin # ------ # Copyright (c) 2021 Arthur Dujardin from .satellite import Satellite class GALILEO(Satellite): def __init__(self, prn=None, toc=None, sv_clock_bias=None, sv_clock_drift=None, sv_clock_drift_rate=None, ...
41.171429
129
0.480453
from .satellite import Satellite class GALILEO(Satellite): def __init__(self, prn=None, toc=None, sv_clock_bias=None, sv_clock_drift=None, sv_clock_drift_rate=None, iod_nav=None, crs=None, delta_n=None, m0=None, cuc=None, e=None, cus=None, sqrt_a=None, ...
true
true
1c379203022852868267188e130ff323afe0d01d
2,790
py
Python
utils/misc.py
samuelbroscheit/open_knowledge_graph_embeddings
1ce37a4261a37e357a0f4dac3ee130ff11cbea4e
[ "MIT" ]
23
2020-11-09T13:17:44.000Z
2021-12-31T09:53:49.000Z
utils/misc.py
samuelbroscheit/open_knowledge_graph_embeddings
1ce37a4261a37e357a0f4dac3ee130ff11cbea4e
[ "MIT" ]
3
2021-03-31T05:41:34.000Z
2022-01-18T12:35:00.000Z
utils/misc.py
samuelbroscheit/open_knowledge_graph_embeddings
1ce37a4261a37e357a0f4dac3ee130ff11cbea4e
[ "MIT" ]
6
2020-11-09T13:18:49.000Z
2022-03-07T21:11:40.000Z
import random import numpy import numpy as np import torch from torch.autograd import Variable def onehot(indexes, N=None, ignore_index=None): """ Creates a one-representation of indexes with N possible entries if N is not specified, it will suit the maximum index appearing. indexes is a long-tensor ...
27.623762
102
0.598925
import random import numpy import numpy as np import torch from torch.autograd import Variable def onehot(indexes, N=None, ignore_index=None): return_variable = False if isinstance(indexes, Variable): return_variable = True indexes = indexes.data if N is None: N = indexes.max() + ...
true
true
1c37920ca1f9519b054419686cf59a0137afe61a
9,474
py
Python
data_process/ops.py
ys10/GCIClassify
a66b1a257ac26b10732a68228721023b99f67a8e
[ "MIT" ]
null
null
null
data_process/ops.py
ys10/GCIClassify
a66b1a257ac26b10732a68228721023b99f67a8e
[ "MIT" ]
null
null
null
data_process/ops.py
ys10/GCIClassify
a66b1a257ac26b10732a68228721023b99f67a8e
[ "MIT" ]
null
null
null
# coding=utf-8 import os import numpy as np from scipy.signal import argrelextrema from scipy.io import wavfile def find_local_minimum(data, threshold=None): """ Find local minimum in data. :param data: input data. :param threshold: (optional) local minimum whose value is not less than threshold won't...
35.750943
110
0.578742
import os import numpy as np from scipy.signal import argrelextrema from scipy.io import wavfile def find_local_minimum(data, threshold=None): local_min_idx = argrelextrema(data, np.less) local_min_idx = local_min_idx[0] if threshold: local_min_idx = [idx for idx in local_min_idx if data[idx] < t...
true
true
1c3793a20513ed473bbca4e1b4bdc673ad328aed
229
py
Python
src/vassal_deployer/__init__.py
evansde77/vassal_deployer
4aaadd35b81c454a6264540f5fb795bfc1daa991
[ "Apache-2.0" ]
null
null
null
src/vassal_deployer/__init__.py
evansde77/vassal_deployer
4aaadd35b81c454a6264540f5fb795bfc1daa991
[ "Apache-2.0" ]
null
null
null
src/vassal_deployer/__init__.py
evansde77/vassal_deployer
4aaadd35b81c454a6264540f5fb795bfc1daa991
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python """ vassal_deployer """ __version__="0.0.2" import os from .logger import get_logger logger = get_logger( os.environ.get('VASSAL_DEPLOYER_LOG'), os.environ.get('VASSAL_DEPLOYER_STDOUT', False) )
14.3125
51
0.716157
__version__="0.0.2" import os from .logger import get_logger logger = get_logger( os.environ.get('VASSAL_DEPLOYER_LOG'), os.environ.get('VASSAL_DEPLOYER_STDOUT', False) )
true
true
1c3794349c3d473d227ff8b97d54267ceb30c171
1,081
py
Python
setup.py
oronibrian/django-mpesa
fb5de34829fedf0d898d4daa5ad8a36efefd3aee
[ "MIT" ]
1
2020-04-06T08:28:46.000Z
2020-04-06T08:28:46.000Z
setup.py
oronibrian/django-mpesa
fb5de34829fedf0d898d4daa5ad8a36efefd3aee
[ "MIT" ]
4
2020-02-11T23:54:32.000Z
2021-06-10T21:16:48.000Z
setup.py
oronibrian/django-mpesa
fb5de34829fedf0d898d4daa5ad8a36efefd3aee
[ "MIT" ]
1
2022-02-19T21:00:56.000Z
2022-02-19T21:00:56.000Z
import os from setuptools import setup README = open(os.path.join(os.path.dirname(__file__), 'README.rst')).read() # Allow setup.py to be run from any path os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir))) setup( name = 'DjangoMpesa', version = '1.4', packages = ['mpesaApp']...
30.885714
100
0.640148
import os from setuptools import setup README = open(os.path.join(os.path.dirname(__file__), 'README.rst')).read() os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir))) setup( name = 'DjangoMpesa', version = '1.4', packages = ['mpesaApp'], include_package_data = True, l...
true
true
1c3794e2265c22e85d615ad0ca29980fd3ca4ac2
1,856
py
Python
tensorflow/utils.py
sutd-visual-computing-group/dag-gans
68a76153650df6de2a6919a93a2d3b98ca6407e6
[ "MIT" ]
32
2021-01-02T14:57:02.000Z
2022-03-15T12:00:16.000Z
tensorflow/utils.py
sutd-visual-computing-group/dag-gans
68a76153650df6de2a6919a93a2d3b98ca6407e6
[ "MIT" ]
1
2021-01-11T06:28:01.000Z
2021-01-11T08:45:04.000Z
tensorflow/utils.py
sutd-visual-computing-group/dag-gans
68a76153650df6de2a6919a93a2d3b98ca6407e6
[ "MIT" ]
5
2021-04-17T08:50:52.000Z
2022-02-06T06:44:24.000Z
import tensorflow as tf import numpy as np import math def rotation(x, degs): x_rot = [] angle = math.pi / 180 for deg in degs: if deg == 0: x_rot.append(x) elif deg == 90: x_rot.append(tf.contrib.image.rotate(x, 90 * angle)) elif deg == 180: x_rot.a...
32.561404
118
0.578125
import tensorflow as tf import numpy as np import math def rotation(x, degs): x_rot = [] angle = math.pi / 180 for deg in degs: if deg == 0: x_rot.append(x) elif deg == 90: x_rot.append(tf.contrib.image.rotate(x, 90 * angle)) elif deg == 180: x_rot.a...
true
true
1c3795887d12e3edea16208d867075490f58e1ec
2,558
py
Python
model_zoo/official/nlp/prophetnet/src/utils/loss_monitor.py
GuoSuiming/mindspore
48afc4cfa53d970c0b20eedfb46e039db2a133d5
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
model_zoo/official/nlp/prophetnet/src/utils/loss_monitor.py
forwhat461/mindspore
59a277756eb4faad9ac9afcc7fd526e8277d4994
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
model_zoo/official/nlp/prophetnet/src/utils/loss_monitor.py
forwhat461/mindspore
59a277756eb4faad9ac9afcc7fd526e8277d4994
[ "Apache-2.0" ]
24
2021-10-15T08:32:45.000Z
2022-03-24T18:45:20.000Z
# Copyright 2020 Huawei Technologies Co., Ltd # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to...
37.072464
88
0.62588
import time from mindspore.train.callback import Callback from config import TransformerConfig class LossCallBack(Callback): time_stamp_init = False time_stamp_first = 0 def __init__(self, config: TransformerConfig, per_print_times: int = 1): super(LossCallBack, self).__init__() ...
true
true
1c37959e88c15de590037cd7eb70979833e39fa3
1,614
py
Python
Data_extraction/CS4.py
CarlOwOs/VH_and_PE_codes
700726332489ed87270ec52d9efe46fcb835c598
[ "MIT" ]
null
null
null
Data_extraction/CS4.py
CarlOwOs/VH_and_PE_codes
700726332489ed87270ec52d9efe46fcb835c598
[ "MIT" ]
null
null
null
Data_extraction/CS4.py
CarlOwOs/VH_and_PE_codes
700726332489ed87270ec52d9efe46fcb835c598
[ "MIT" ]
3
2021-06-22T10:39:44.000Z
2021-09-13T16:05:59.000Z
import pandas as pd import numpy as np import Auxiliary.auxiliary_functions as aux_fun #-------------------------------------------------- def read_and_extract_target(): ''' This function reads the processed "events" df and computes which of the observations correspond to an IC phenomena. After that computa...
47.470588
138
0.639405
import pandas as pd import numpy as np import Auxiliary.auxiliary_functions as aux_fun def read_and_extract_target(): events_label = pd.read_csv("./Temp/events_CS2.csv") aux_fun.delete_csvs(["events_CS2"],"./Temp/") events_label["target"] = 0 for i,row in events_label.iterrows(): if row.ti...
true
true
1c3795dc060d6509c41d3fbbb3beb2a1846b4540
4,040
py
Python
sdk/python/pulumi_azure_nextgen/devices/latest/list_iot_dps_resource_keys_for_key_name.py
test-wiz-sec/pulumi-azure-nextgen
20a695af0d020b34b0f1c336e1b69702755174cc
[ "Apache-2.0" ]
null
null
null
sdk/python/pulumi_azure_nextgen/devices/latest/list_iot_dps_resource_keys_for_key_name.py
test-wiz-sec/pulumi-azure-nextgen
20a695af0d020b34b0f1c336e1b69702755174cc
[ "Apache-2.0" ]
null
null
null
sdk/python/pulumi_azure_nextgen/devices/latest/list_iot_dps_resource_keys_for_key_name.py
test-wiz-sec/pulumi-azure-nextgen
20a695af0d020b34b0f1c336e1b69702755174cc
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi SDK Generator. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union from ... import _utilities, _tables __a...
37.757009
171
0.67005
import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union from ... import _utilities, _tables __all__ = [ 'ListIotDpsResourceKeysForKeyNameResult', 'AwaitableListIotDpsResourceKeysForKeyNameResult', 'list_iot_dps_resource_keys_for_key_name', ] @pulu...
true
true
1c37967573dfccc4488c0576fd333668c6ce05f2
14,794
py
Python
external/logger.py
yunshengtian/ppo-mujoco
1989bc5491d2abc3d015d0ec81d34ea166c3352b
[ "MIT" ]
1
2021-01-27T08:59:31.000Z
2021-01-27T08:59:31.000Z
external/logger.py
yunshengtian/ppo-mujoco
1989bc5491d2abc3d015d0ec81d34ea166c3352b
[ "MIT" ]
null
null
null
external/logger.py
yunshengtian/ppo-mujoco
1989bc5491d2abc3d015d0ec81d34ea166c3352b
[ "MIT" ]
1
2021-01-20T07:56:54.000Z
2021-01-20T07:56:54.000Z
import os import sys import shutil import os.path as osp import json import time import datetime import tempfile from collections import defaultdict from contextlib import contextmanager DEBUG = 10 INFO = 20 WARN = 30 ERROR = 40 DISABLED = 50 class KVWriter(object): def writekvs(self, kvs): raise NotImpl...
29.411531
122
0.56773
import os import sys import shutil import os.path as osp import json import time import datetime import tempfile from collections import defaultdict from contextlib import contextmanager DEBUG = 10 INFO = 20 WARN = 30 ERROR = 40 DISABLED = 50 class KVWriter(object): def writekvs(self, kvs): raise NotImpl...
true
true
1c3799c35730a1160f93225e698987adb9c3c071
4,558
py
Python
kafka-python/json_test.py
pengfei99/KafkaPyClient
b18b361aedec9b58eef27c1d6f97346a64a1f154
[ "Apache-2.0" ]
null
null
null
kafka-python/json_test.py
pengfei99/KafkaPyClient
b18b361aedec9b58eef27c1d6f97346a64a1f154
[ "Apache-2.0" ]
null
null
null
kafka-python/json_test.py
pengfei99/KafkaPyClient
b18b361aedec9b58eef27c1d6f97346a64a1f154
[ "Apache-2.0" ]
null
null
null
import json def main(): msg = """{"tableName":"students","dbName":"default","owner":"pliu","createTime":1647683673,"lastAccessTime":0,"retention":0,"sd":{"cols":[{"name":"student_id","type":"int","comment":null,"setType":true,"setName":true,"setComment":false},{"name":"firstname","type":"string","comment":null,"s...
350.615385
4,394
0.753401
import json def main(): msg = """{"tableName":"students","dbName":"default","owner":"pliu","createTime":1647683673,"lastAccessTime":0,"retention":0,"sd":{"cols":[{"name":"student_id","type":"int","comment":null,"setType":true,"setName":true,"setComment":false},{"name":"firstname","type":"string","comment":null,"s...
true
true
1c3799d44bc7ac749bd8a851ed33c9e6a417e9f2
1,774
py
Python
UserCode/jzhang/bubble_finder_test.py
RunzZhang/SBCcode
e75b8e751cec5fb2c28950edef0c82f005caedcb
[ "MIT" ]
4
2018-08-27T18:02:34.000Z
2020-06-09T21:19:04.000Z
UserCode/jzhang/bubble_finder_test.py
RunzZhang/SBCcode
e75b8e751cec5fb2c28950edef0c82f005caedcb
[ "MIT" ]
null
null
null
UserCode/jzhang/bubble_finder_test.py
RunzZhang/SBCcode
e75b8e751cec5fb2c28950edef0c82f005caedcb
[ "MIT" ]
4
2019-06-20T21:36:26.000Z
2020-11-10T17:23:14.000Z
# python sbc_pmttest_processall.py [run_list] # if run_list is provided, the runs in the list will be processed; otherwise # the runs in the script will be processed import SBCcode.AnalysisModules.ImageAnalysis as ia import SBCcode.DataHandling.WriteBinary as wb import numpy as np # import SBCcode as sbc import os imp...
34.784314
100
0.638106
import SBCcode.AnalysisModules.ImageAnalysis as ia import SBCcode.DataHandling.WriteBinary as wb import numpy as np import os import re import sys datadir = '/mnt/XENON_DAQ/SBC-17-data' recondir = '.' if len(sys.argv) > 1: runlist = sys.argv[1:] else: runlist = ['20170625_0'] for runname in ru...
true
true
1c379ab34d3650c0fbce680f9a59effe54787ad0
857
py
Python
restriction_sites.py
Tiago-Minuzzi/lab-stuff
b4cbca8c578e3cc4035df5686254d9254a876413
[ "MIT" ]
null
null
null
restriction_sites.py
Tiago-Minuzzi/lab-stuff
b4cbca8c578e3cc4035df5686254d9254a876413
[ "MIT" ]
null
null
null
restriction_sites.py
Tiago-Minuzzi/lab-stuff
b4cbca8c578e3cc4035df5686254d9254a876413
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created by Tiago Minuzzi """ import sys from Bio import SeqIO from Bio.Restriction import * INFILE=sys.argv[1] with open(INFILE) as fasta: for record in SeqIO.parse(fasta, 'fasta'): fid = record.id sequencia = record.seq tamanho = len(reco...
28.566667
62
0.590432
import sys from Bio import SeqIO from Bio.Restriction import * INFILE=sys.argv[1] with open(INFILE) as fasta: for record in SeqIO.parse(fasta, 'fasta'): fid = record.id sequencia = record.seq tamanho = len(record.seq) sitiosHIII = HindIII.search(sequencia) sitios...
true
true
1c379b44da55f2f427dc8bdf12f7b203223a0aba
2,990
py
Python
run.py
felix2072/pytorch-CycleGAN-and-pix2pix
4980106ceab5e1eb7bb20c2b492d007b6310d9e1
[ "BSD-3-Clause" ]
null
null
null
run.py
felix2072/pytorch-CycleGAN-and-pix2pix
4980106ceab5e1eb7bb20c2b492d007b6310d9e1
[ "BSD-3-Clause" ]
null
null
null
run.py
felix2072/pytorch-CycleGAN-and-pix2pix
4980106ceab5e1eb7bb20c2b492d007b6310d9e1
[ "BSD-3-Clause" ]
null
null
null
import socket from options.test_options import TestOptions from data import create_dataset from models import create_model import time from util import util UDP_IP = "127.0.0.1" OUT_PORT = 5004 IN_PORT = 5005 buf = 1024 timeout = 3 if __name__ == '__main__': opt = TestOptions().parse() # get test options #...
36.463415
123
0.600669
import socket from options.test_options import TestOptions from data import create_dataset from models import create_model import time from util import util UDP_IP = "127.0.0.1" OUT_PORT = 5004 IN_PORT = 5005 buf = 1024 timeout = 3 if __name__ == '__main__': opt = TestOptions().parse() opt.num_thread...
true
true
1c379c378fffabea367feee717680ccc02e4754d
200,004
py
Python
tests/api_test.py
SCiarella/jax
a7c9b6d11fa833c748d72b3ccc11baeed9c0248c
[ "Apache-2.0" ]
null
null
null
tests/api_test.py
SCiarella/jax
a7c9b6d11fa833c748d72b3ccc11baeed9c0248c
[ "Apache-2.0" ]
6
2022-01-03T08:14:15.000Z
2022-02-14T08:13:40.000Z
tests/api_test.py
SCiarella/jax
a7c9b6d11fa833c748d72b3ccc11baeed9c0248c
[ "Apache-2.0" ]
null
null
null
# Copyright 2018 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, ...
31.378099
127
0.607553
import collections import collections.abc from contextlib import contextmanager import copy import enum from functools import partial import operator import re import subprocess import sys import types import unittest import warnings import weakref import functools import itertools as it import operator ...
true
true
1c379c56877c1c8f51cd44e18e3eba0986f7c3d1
907
py
Python
tmp/wswp/crawler.py
godontop/python
a33391304e3396d2f208dfc8cec3c200e4f18136
[ "MIT" ]
null
null
null
tmp/wswp/crawler.py
godontop/python
a33391304e3396d2f208dfc8cec3c200e4f18136
[ "MIT" ]
null
null
null
tmp/wswp/crawler.py
godontop/python
a33391304e3396d2f208dfc8cec3c200e4f18136
[ "MIT" ]
null
null
null
# coding=utf-8 import datetime import re import time import urllib.error import urllib.parse import urllib.request import urllib.robotparser import sys from downloader import Downloader def crawler(seed_url, delay=1, max_depth=2, user_agent='Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_4) AppleWebKit/537.36 (KHTML, l...
37.791667
243
0.724366
import datetime import re import time import urllib.error import urllib.parse import urllib.request import urllib.robotparser import sys from downloader import Downloader def crawler(seed_url, delay=1, max_depth=2, user_agent='Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_4) AppleWebKit/537.36 (KHTML, like Gecko) Chr...
true
true
1c379db5bb9eb9cc51e5d447527f55bc6ea4f4f7
4,676
py
Python
flink-ai-flow/ai_flow/application_master/master.py
MarvinMiao/flink-ai-extended
e45eecf2deea6976ba3d7ba821ffb8d9ce0a17f4
[ "Apache-2.0", "BSD-2-Clause", "MIT", "ECL-2.0", "BSD-3-Clause" ]
1
2020-12-12T15:21:05.000Z
2020-12-12T15:21:05.000Z
flink-ai-flow/ai_flow/application_master/master.py
MarvinMiao/flink-ai-extended
e45eecf2deea6976ba3d7ba821ffb8d9ce0a17f4
[ "Apache-2.0", "BSD-2-Clause", "MIT", "ECL-2.0", "BSD-3-Clause" ]
1
2021-01-30T11:28:37.000Z
2021-01-30T11:28:37.000Z
flink-ai-flow/ai_flow/application_master/master.py
MarvinMiao/flink-ai-extended
e45eecf2deea6976ba3d7ba821ffb8d9ce0a17f4
[ "Apache-2.0", "BSD-2-Clause", "MIT", "ECL-2.0", "BSD-3-Clause" ]
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...
42.126126
120
0.695252
import os from typing import Text from ai_flow.rest_endpoint.service.server import AIFlowServer, HighAvailableAIFlowServer from ai_flow.store.db.base_model import base from ai_flow.store.sqlalchemy_store import SqlAlchemyStore from ai_flow.store.mongo_store import MongoStoreConnManager from ai_flow.ap...
true
true
1c379de15770b17dc2ba1bf16a65246f51b2f12e
136
py
Python
abc/abc143/abc143c-1.py
c-yan/atcoder
940e49d576e6a2d734288fadaf368e486480a948
[ "MIT" ]
1
2019-08-21T00:49:34.000Z
2019-08-21T00:49:34.000Z
abc/abc143/abc143c-1.py
c-yan/atcoder
940e49d576e6a2d734288fadaf368e486480a948
[ "MIT" ]
null
null
null
abc/abc143/abc143c-1.py
c-yan/atcoder
940e49d576e6a2d734288fadaf368e486480a948
[ "MIT" ]
null
null
null
N = int(input()) S = input() p = '' result = 0 for i in range(N): if p != S[i]: result += 1 p = S[i] print(result)
12.363636
19
0.448529
N = int(input()) S = input() p = '' result = 0 for i in range(N): if p != S[i]: result += 1 p = S[i] print(result)
true
true
1c379e95efb13865d25b98a431b6010d16bbe638
11,345
py
Python
es_test_data.py
unfor19/elasticsearch-test-data
e79be946aee74fb4f4cc77cf9209ac3a62f710be
[ "MIT" ]
1
2021-09-18T06:50:04.000Z
2021-09-18T06:50:04.000Z
es_test_data.py
unfor19/elasticsearch-test-data
e79be946aee74fb4f4cc77cf9209ac3a62f710be
[ "MIT" ]
null
null
null
es_test_data.py
unfor19/elasticsearch-test-data
e79be946aee74fb4f4cc77cf9209ac3a62f710be
[ "MIT" ]
null
null
null
#!/usr/bin/python import json import time import logging import random import string import uuid import datetime import tornado.gen import tornado.httpclient import tornado.ioloop import tornado.options try: xrange range = xrange except NameError: pass async_http_client = tornado.httpclient.AsyncHTTPCli...
40.230496
265
0.65509
import json import time import logging import random import string import uuid import datetime import tornado.gen import tornado.httpclient import tornado.ioloop import tornado.options try: xrange range = xrange except NameError: pass async_http_client = tornado.httpclient.AsyncHTTPClient() headers = t...
true
true
1c379ecbd15812a9820a9f9718e729fc0870bf76
2,178
py
Python
test/lib/git.py
morgante/cnrm-blueprints
34453c4acde2cd321f71b76b3e6c6b086bc8ada1
[ "Apache-2.0" ]
9
2020-07-10T18:20:19.000Z
2021-10-08T23:58:06.000Z
test/lib/git.py
morgante/cnrm-blueprints
34453c4acde2cd321f71b76b3e6c6b086bc8ada1
[ "Apache-2.0" ]
1
2021-03-17T19:20:27.000Z
2021-03-17T19:20:27.000Z
test/lib/git.py
isabella232/cnrm-blueprints
19d7c459c4f71198208282da17bcade53d28cc9c
[ "Apache-2.0" ]
4
2020-07-10T23:22:20.000Z
2021-09-27T19:27:02.000Z
# Copyright 2020 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, ...
34.571429
79
0.624885
import downloads import os class Git(object): def __init__(self, user_email, user_name, env=None): if env is None: env = os.environ.copy() self.bin = "git" self.env = env downloads.exec(["chmod", "600", "/root/.ssh/id_rsa"]) downloads.exec(["git", "...
true
true
1c379f073a5a5d7623ac8b55b3bcc6bed55eeb70
8,763
py
Python
maple/maple/spiders/news.py
honmaple/maple-spider
b9b6b295114149436974f4fe82f75dc7f2797129
[ "MIT" ]
null
null
null
maple/maple/spiders/news.py
honmaple/maple-spider
b9b6b295114149436974f4fe82f75dc7f2797129
[ "MIT" ]
null
null
null
maple/maple/spiders/news.py
honmaple/maple-spider
b9b6b295114149436974f4fe82f75dc7f2797129
[ "MIT" ]
1
2019-04-20T03:22:26.000Z
2019-04-20T03:22:26.000Z
#!/usr/bin/env python # -*- coding=UTF-8 -*- #************************************************************************* # Copyright © 2015 JiangLin. All rights reserved. # File Name: news.py # Author:JiangLin # Mail:xiyang0807@gmail.com # Created Time: 2016-04-03 23:02:32 # Last Update: 星期四 2016-4-7 12:57:8 (CST) # ...
36.665272
80
0.479516
import scrapy from maple.items import NewsItem from scrapy.http import Request from scrapy.selector import Selector from datetime import datetime from maple.models import News, DBSession session = DBSession() def exsit_session(url): a = session.query(News.url).filter_by(url=url).first() if not a:...
true
true
1c37a06c7473a70641c7ae6eeef966e4e43240bc
16,122
py
Python
src/TestRailAPIClient.py
ezywebs/robotframework-testrail-extended
7797905257a590e9764c07a915de2dcbbde1e850
[ "Apache-2.0" ]
null
null
null
src/TestRailAPIClient.py
ezywebs/robotframework-testrail-extended
7797905257a590e9764c07a915de2dcbbde1e850
[ "Apache-2.0" ]
null
null
null
src/TestRailAPIClient.py
ezywebs/robotframework-testrail-extended
7797905257a590e9764c07a915de2dcbbde1e850
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- from requests import post, get from typing import Any, cast, Dict, List, Optional, Sequence, Union DEFAULT_TESTRAIL_HEADERS = {'Content-Type': 'application/json'} TESTRAIL_STATUS_ID_PASSED = 1 # custom types JsonDict = Dict[str, Any] # noqa: E993 JsonList = List[JsonDict] # noqa: E993 Id = ...
42.426316
146
0.56823
from requests import post, get from typing import Any, cast, Dict, List, Optional, Sequence, Union DEFAULT_TESTRAIL_HEADERS = {'Content-Type': 'application/json'} TESTRAIL_STATUS_ID_PASSED = 1 JsonDict = Dict[str, Any] JsonList = List[JsonDict] Id = Union[str, int] class TestRailAPIClient(object): def...
true
true
1c37a07e0ed2366f0d8ed081f69ba7572ae5a7d7
1,108
py
Python
python/paddle_fl/split_learning/core/layer_handler/layer_base.py
kaih70/PaddleFL
515906e2c61ee90f8a1c3f8e8210aac2f4177a4a
[ "Apache-2.0" ]
379
2019-09-27T14:26:42.000Z
2022-03-29T14:28:12.000Z
python/paddle_fl/split_learning/core/layer_handler/layer_base.py
Sprate/PaddleFL
583691acd5db0a7ca331cc9a72415017b18669b8
[ "Apache-2.0" ]
132
2019-10-16T03:22:03.000Z
2022-03-23T08:54:29.000Z
python/paddle_fl/split_learning/core/layer_handler/layer_base.py
Sprate/PaddleFL
583691acd5db0a7ca331cc9a72415017b18669b8
[ "Apache-2.0" ]
106
2019-09-27T12:47:18.000Z
2022-03-29T09:07:25.000Z
# Copyright (c) 2021 PaddlePaddle Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by appli...
31.657143
74
0.73556
import paddle import numpy as np import logging _LOGGER = logging.getLogger(__name__) class LayerBase(paddle.nn.Layer): def __init__(self): super(LayerBase, self).__init__() @paddle.jit.to_static def forward(self, **feed): raise NotImplementedError("Failed to run forward") ...
true
true
1c37a1b755ce6106a519f07b5dd18552e9e34701
2,776
py
Python
test/datacenters/test_gcp.py
aexvir/the-zoo
7816afb9a0a26c6058b030b4a987c73e952d92bd
[ "MIT" ]
90
2018-11-20T10:58:24.000Z
2022-02-19T16:12:46.000Z
test/datacenters/test_gcp.py
kiwicom/the-zoo
fee0108ea7b65112e5b572a146cff4b1c54033fd
[ "MIT" ]
348
2018-11-21T09:22:31.000Z
2021-11-03T13:45:08.000Z
test/datacenters/test_gcp.py
aexvir/the-zoo
7816afb9a0a26c6058b030b4a987c73e952d92bd
[ "MIT" ]
11
2018-12-08T18:42:07.000Z
2021-02-21T06:27:58.000Z
from unittest.mock import MagicMock import pytest from zoo.datacenters import gcp as uut from zoo.datacenters import models pytestmark = pytest.mark.django_db def test_gcp_map_to_nodes(mocker): mocker.patch("zoo.datacenters.utils.gcloud.GCPClient.__init__", return_value=None) mocker.patch( "zoo.dat...
30.173913
86
0.607709
from unittest.mock import MagicMock import pytest from zoo.datacenters import gcp as uut from zoo.datacenters import models pytestmark = pytest.mark.django_db def test_gcp_map_to_nodes(mocker): mocker.patch("zoo.datacenters.utils.gcloud.GCPClient.__init__", return_value=None) mocker.patch( "zoo.dat...
true
true
1c37a1c346f1ed4454020911795eff358c3de77d
2,559
py
Python
plugins/tff_backend/bizz/todo/investor.py
threefoldfoundation/app_backend
b3cea2a3ff9e10efcc90d3d6e5e8e46b9e84312a
[ "Apache-2.0" ]
null
null
null
plugins/tff_backend/bizz/todo/investor.py
threefoldfoundation/app_backend
b3cea2a3ff9e10efcc90d3d6e5e8e46b9e84312a
[ "Apache-2.0" ]
178
2017-08-02T12:58:06.000Z
2017-12-20T15:01:12.000Z
plugins/tff_backend/bizz/todo/investor.py
threefoldfoundation/app_backend
b3cea2a3ff9e10efcc90d3d6e5e8e46b9e84312a
[ "Apache-2.0" ]
2
2018-01-10T10:43:12.000Z
2018-03-18T10:42:23.000Z
# -*- coding: utf-8 -*- # Copyright 2017 GIG Technology NV # # 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...
30.831325
79
0.609222
import logging class InvestorSteps(object): DOWNLOAD = 'DOWNLOAD' ITO_INVITES = 'ITO_INVITES' FLOW_INIT = 'FLOW_INIT' FLOW_AMOUNT = 'FLOW_AMOUNT' FLOW_SIGN = 'FLOW_SIGN' PAY = 'PAY' PAY_PROCESS = 'PAY_PROCESS' ASSIGN_TOKENS = 'ASSIGN_TOKENS' DESCRIPTIONS = { ...
true
true
1c37a20652cba8d9ec66c21d85f77b65e8fdd40d
2,837
py
Python
edna2/tasks/test/H5ToCBFTask/H5ToCBF_exec_test.py
shibom/edna2
31e39b887be88a47bca775cd91310f5a17841bdd
[ "CC0-1.0", "MIT" ]
null
null
null
edna2/tasks/test/H5ToCBFTask/H5ToCBF_exec_test.py
shibom/edna2
31e39b887be88a47bca775cd91310f5a17841bdd
[ "CC0-1.0", "MIT" ]
2
2020-04-06T10:39:50.000Z
2021-04-14T19:24:37.000Z
edna2/tasks/test/H5ToCBFTask/H5ToCBF_exec_test.py
shibom/edna2
31e39b887be88a47bca775cd91310f5a17841bdd
[ "CC0-1.0", "MIT" ]
5
2019-06-14T07:28:38.000Z
2021-04-28T13:10:39.000Z
# # Copyright (c) European Synchrotron Radiation Facility (ESRF) # # Permission is hereby granted, free of charge, to any person obtaining a copy of # this software and associated documentation files (the "Software"), to deal in # the Software without restriction, including without limitation the rights to # use, copy,...
42.984848
82
0.701445
__authors__ = ["O. Svensson"] __license__ = "MIT" __date__ = "21/04/2019" import os import unittest from edna2.tasks.H5ToCBFTask import H5ToCBFTask from edna2.utils import UtilsTest from edna2.utils import UtilsConfig class H5ToCBFExecTest(unittest.TestCase): def setUp(self): self...
true
true
1c37a23f90a79b0e103ea206f96f45072c69bd92
8,150
py
Python
contrib/devtools/update-translations.py
nuyulcore/NuyulX
ccf82925dc72966e911f5c5613558b654dce7d96
[ "MIT" ]
null
null
null
contrib/devtools/update-translations.py
nuyulcore/NuyulX
ccf82925dc72966e911f5c5613558b654dce7d96
[ "MIT" ]
null
null
null
contrib/devtools/update-translations.py
nuyulcore/NuyulX
ccf82925dc72966e911f5c5613558b654dce7d96
[ "MIT" ]
null
null
null
#!/usr/bin/env 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. ''' Run this script from the root of the repository to update all translations from transifex. It will do the follo...
38.625592
124
0.633865
from __future__ import division, print_function import subprocess import re import sys import os import io import xml.etree.ElementTree as ET TX = 'tx' SOURCE_LANG = 'nuyul_en.ts' LOCALE_DIR = 'src/qt/locale' MIN_NUM_MESSAGES = 10 def check_at_repository_root(): if not os.path.exists('.git'): prin...
true
true
1c37a34a195f3289c67ff26374a903d2e2c87e3b
11,126
py
Python
code/python/OverviewReportBuilder/v1/fds/sdk/OverviewReportBuilder/model/description_description.py
factset/enterprise-sdk
3fd4d1360756c515c9737a0c9a992c7451d7de7e
[ "Apache-2.0" ]
6
2022-02-07T16:34:18.000Z
2022-03-30T08:04:57.000Z
code/python/OverviewReportBuilder/v1/fds/sdk/OverviewReportBuilder/model/description_description.py
factset/enterprise-sdk
3fd4d1360756c515c9737a0c9a992c7451d7de7e
[ "Apache-2.0" ]
2
2022-02-07T05:25:57.000Z
2022-03-07T14:18:04.000Z
code/python/OverviewReportBuilder/v1/fds/sdk/OverviewReportBuilder/model/description_description.py
factset/enterprise-sdk
3fd4d1360756c515c9737a0c9a992c7451d7de7e
[ "Apache-2.0" ]
null
null
null
""" FactSet Overview Report Builder API No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 The version of the OpenAPI document: 1.0.0 Generated by: https://openapi-generator.tech """ import re # noqa: F401 import sys # noqa: F40...
43.460938
124
0.571994
import re import sys from fds.sdk.OverviewReportBuilder.model_utils import ( ApiTypeError, ModelComposed, ModelNormal, ModelSimple, cached_property, change_keys_js_to_python, convert_js_args_to_python_args, date, datetime, file_type, none_type, validate_get_compo...
true
true
1c37a46965905b69ae23131d9faa5c47d8f12d9c
27,228
py
Python
src/datasets/utils/file_utils.py
borisdayma/datasets
ab6d9759b8b15c0109947159ff1cb6cb3486fdb8
[ "Apache-2.0" ]
1
2020-09-09T00:44:49.000Z
2020-09-09T00:44:49.000Z
src/datasets/utils/file_utils.py
borisdayma/datasets
ab6d9759b8b15c0109947159ff1cb6cb3486fdb8
[ "Apache-2.0" ]
null
null
null
src/datasets/utils/file_utils.py
borisdayma/datasets
ab6d9759b8b15c0109947159ff1cb6cb3486fdb8
[ "Apache-2.0" ]
1
2020-09-04T02:33:51.000Z
2020-09-04T02:33:51.000Z
""" Utilities for working with the local dataset cache. This file is adapted from the AllenNLP library at https://github.com/allenai/allennlp Copyright by the AllenNLP authors. """ import copy import gzip import json import lzma import os import re import shutil import sys import tarfile import tempfile import time im...
36.844384
144
0.648046
import copy import gzip import json import lzma import os import re import shutil import sys import tarfile import tempfile import time import urllib from contextlib import closing, contextmanager from dataclasses import dataclass from functools import partial from hashlib import sha256 from pathlib import Path from t...
true
true
1c37a7a27277e84f157ef1a0c27c525b20bb63fe
614
py
Python
tests/test_sox.py
ayoubBouziane/TrainingSpeech
799e95d644d69890fa69e488712f10e662827c10
[ "MIT" ]
9
2022-01-24T00:42:31.000Z
2022-03-23T06:32:43.000Z
tests/test_sox.py
wasertech/TrainingSpeech
2a0a7674aa41b3526aeafde58d820a16397923f4
[ "MIT" ]
null
null
null
tests/test_sox.py
wasertech/TrainingSpeech
2a0a7674aa41b3526aeafde58d820a16397923f4
[ "MIT" ]
3
2020-05-05T21:17:12.000Z
2022-01-30T09:20:28.000Z
import subprocess import pytest from training_speech import sox @pytest.mark.parametrize('kwargs, expected_call', [ (dict(path_to_file='/path/to/foo.mp3'), 'play -q /path/to/foo.mp3'), (dict(path_to_file='/path/to/foo.mp3', speed=1.2), 'play -q /path/to/foo.mp3 tempo 1.2'), ]) def test_convert(kwargs, expec...
32.315789
93
0.69544
import subprocess import pytest from training_speech import sox @pytest.mark.parametrize('kwargs, expected_call', [ (dict(path_to_file='/path/to/foo.mp3'), 'play -q /path/to/foo.mp3'), (dict(path_to_file='/path/to/foo.mp3', speed=1.2), 'play -q /path/to/foo.mp3 tempo 1.2'), ]) def test_convert(kwargs, expec...
true
true
1c37a82403707cac934d7f3de7579bf6a5d83368
2,509
py
Python
{{ cookiecutter.project_name | slugify }}/docs/conf.py
ri-gilfanov/python-project-template
0785e2e9dec4d5f901742ad2d53281f5cf70845f
[ "MIT" ]
null
null
null
{{ cookiecutter.project_name | slugify }}/docs/conf.py
ri-gilfanov/python-project-template
0785e2e9dec4d5f901742ad2d53281f5cf70845f
[ "MIT" ]
null
null
null
{{ cookiecutter.project_name | slugify }}/docs/conf.py
ri-gilfanov/python-project-template
0785e2e9dec4d5f901742ad2d53281f5cf70845f
[ "MIT" ]
null
null
null
# Configuration file for the Sphinx documentation builder. # # This file only contains a selection of the most common options. For a full # list see the documentation: # https://www.sphinx-doc.org/en/master/usage/configuration.html # -- Path setup -------------------------------------------------------------- # If ex...
38.6
80
0.66401
from {{ cookiecutter.project_name | slugify(separator='_') }} import __version__ project = '{{ cookiecutter.project_name | slugify }}' copyright = '{% now "local", "%Y" %}, {{ cookiecutter.author_name }}' author = '{{ cookiecutter.author_name }}' release = __version__ extensions = [] templ...
false
true
1c37a83c830cb55ad1916a0c80361da3be597d97
2,801
py
Python
BagModules/bag_digital_ec/tinv.py
xyabc/bag_digital_ec
71b982fc0fbe275fc3901db2e25ab7ca62fb319f
[ "BSD-3-Clause" ]
null
null
null
BagModules/bag_digital_ec/tinv.py
xyabc/bag_digital_ec
71b982fc0fbe275fc3901db2e25ab7ca62fb319f
[ "BSD-3-Clause" ]
null
null
null
BagModules/bag_digital_ec/tinv.py
xyabc/bag_digital_ec
71b982fc0fbe275fc3901db2e25ab7ca62fb319f
[ "BSD-3-Clause" ]
2
2019-06-30T07:03:02.000Z
2020-01-07T04:55:21.000Z
# -*- coding: utf-8 -*- from typing import Dict, Any import os import pkg_resources from bag.design import Module yaml_file = pkg_resources.resource_filename(__name__, os.path.join('netlist_info', 'tinv.yaml')) # noinspection PyPep8Naming class bag_digital_ec__tinv(Module): """Module for library bag_digital_...
32.569767
96
0.555873
from typing import Dict, Any import os import pkg_resources from bag.design import Module yaml_file = pkg_resources.resource_filename(__name__, os.path.join('netlist_info', 'tinv.yaml')) class bag_digital_ec__tinv(Module): def __init__(self, bag_config, parent=None, prj=None, **kwargs): Module.__i...
true
true
1c37a872ef16d6404b68cac4763c8943fe47e889
387
py
Python
tests/dump/graph.full.py
noabauma/Mirheo
bf7979bfbbf402d33c26ac5dc879f880e78e7017
[ "MIT" ]
null
null
null
tests/dump/graph.full.py
noabauma/Mirheo
bf7979bfbbf402d33c26ac5dc879f880e78e7017
[ "MIT" ]
null
null
null
tests/dump/graph.full.py
noabauma/Mirheo
bf7979bfbbf402d33c26ac5dc879f880e78e7017
[ "MIT" ]
1
2021-07-14T13:24:05.000Z
2021-07-14T13:24:05.000Z
#!/usr/bin/env python import mirheo as mir dt = 0.001 ranks = (1, 1, 1) domain = (4, 4, 4) u = mir.Mirheo(ranks, domain, dt, debug_level=3, log_filename='log', no_splash=True) u.save_dependency_graph_graphml("tasks.full", current=False) # sTEST: dump.graph.full # cd dump # rm -rf tasks.graphml # mir.run --runarg...
19.35
84
0.684755
import mirheo as mir dt = 0.001 ranks = (1, 1, 1) domain = (4, 4, 4) u = mir.Mirheo(ranks, domain, dt, debug_level=3, log_filename='log', no_splash=True) u.save_dependency_graph_graphml("tasks.full", current=False)
true
true
1c37a8f2f8562f4283ccad4cc4a0bd62e91558d2
4,788
py
Python
src/m9b_summing_again.py
frazeedj/03-AccumulatorsAndFunctionsWithParameters
1b83b3b33da7ec855563182478526469f682fe51
[ "MIT" ]
null
null
null
src/m9b_summing_again.py
frazeedj/03-AccumulatorsAndFunctionsWithParameters
1b83b3b33da7ec855563182478526469f682fe51
[ "MIT" ]
null
null
null
src/m9b_summing_again.py
frazeedj/03-AccumulatorsAndFunctionsWithParameters
1b83b3b33da7ec855563182478526469f682fe51
[ "MIT" ]
null
null
null
""" This module lets you practice the ACCUMULATOR pattern in its simplest classic forms: SUMMING: total = total + number Authors: David Mutchler, Dave Fisher, Vibha Alangar, Mark Hays, Amanda Stouder, their colleagues and Dylan Frazee. """ # DONE: 1. PUT YOUR NAME IN THE ABOVE LINE. def main(): ...
37.40625
79
0.496032
def main(): run_test_sum_powers() run_test_sum_powers_in_range() def run_test_sum_powers(): print() print('--------------------------------------------------') print('Testing the sum_powers function:') print('---------------------------------------...
true
true
1c37aa413333e3d03690186888d312c16dded533
2,165
py
Python
tavern/_plugins/mqtt/request.py
BangWork/tavern
050308841461894a28b07bd2ece85a9b48ff2df4
[ "MIT" ]
null
null
null
tavern/_plugins/mqtt/request.py
BangWork/tavern
050308841461894a28b07bd2ece85a9b48ff2df4
[ "MIT" ]
null
null
null
tavern/_plugins/mqtt/request.py
BangWork/tavern
050308841461894a28b07bd2ece85a9b48ff2df4
[ "MIT" ]
null
null
null
import logging import json import functools from future.utils import raise_from from box import Box from tavern.util import exceptions from tavern.util.dict_util import format_keys, check_expected_keys from tavern.request.base import BaseRequest logger = logging.getLogger(__name__) def get_publish_args(rspec, te...
27.405063
87
0.651732
import logging import json import functools from future.utils import raise_from from box import Box from tavern.util import exceptions from tavern.util.dict_util import format_keys, check_expected_keys from tavern.request.base import BaseRequest logger = logging.getLogger(__name__) def get_publish_args(rspec, te...
true
true
1c37aaa572f430e147ce57c950d49214c220c7f1
13,738
py
Python
game/data/scripts/quests/605_AllianceWithKetraOrcs/__init__.py
TheDemonLife/Lineage2Server-Interlude
d23d145db533fd899d4064026e4bc7ee45c6624a
[ "Apache-2.0" ]
10
2019-07-27T13:12:11.000Z
2022-01-15T19:13:26.000Z
game/data/scripts/quests/605_AllianceWithKetraOrcs/__init__.py
TheDemonLife/Lineage2Server-Interlude
d23d145db533fd899d4064026e4bc7ee45c6624a
[ "Apache-2.0" ]
1
2021-08-06T12:15:01.000Z
2021-08-09T10:18:47.000Z
game/data/scripts/quests/605_AllianceWithKetraOrcs/__init__.py
TheDemonLife/Lineage2Server-Interlude
d23d145db533fd899d4064026e4bc7ee45c6624a
[ "Apache-2.0" ]
2
2020-02-20T23:02:26.000Z
2020-11-22T09:27:51.000Z
# Made by Emperorc # Rate Fix by Gnat import sys from ru.catssoftware import Config from ru.catssoftware.gameserver.model.quest import State from ru.catssoftware.gameserver.model.quest import QuestState from ru.catssoftware.gameserver.model.quest.jython import QuestJython as JQuest qn = "605_AllianceWithKetraOrcs" #N...
39.705202
153
0.59521
import sys from ru.catssoftware import Config from ru.catssoftware.gameserver.model.quest import State from ru.catssoftware.gameserver.model.quest import QuestState from ru.catssoftware.gameserver.model.quest.jython import QuestJython as JQuest qn = "605_AllianceWithKetraOrcs" Wahkan = 31371 Varka_One = [ 2...
true
true
1c37ab078af008294ab1a5513be042ef121b6fe1
2,517
py
Python
src/sim/power/PowerModelState.py
majid169/gem5-RFDB
a8950687b8cb6a701a387fca4409ff273facb459
[ "BSD-3-Clause" ]
8
2020-02-04T23:39:49.000Z
2021-05-18T14:33:14.000Z
src/sim/power/PowerModelState.py
majid169/gem5-RFDB
a8950687b8cb6a701a387fca4409ff273facb459
[ "BSD-3-Clause" ]
2
2022-02-13T15:54:43.000Z
2022-03-22T06:19:28.000Z
src/sim/power/PowerModelState.py
majid169/gem5-RFDB
a8950687b8cb6a701a387fca4409ff273facb459
[ "BSD-3-Clause" ]
5
2020-04-07T03:38:31.000Z
2020-11-28T04:03:15.000Z
# Copyright (c) 2016 ARM Limited # All rights reserved. # # The license below extends only to copyright in the software and shall # not be construed as granting a license to any other intellectual # property including but not limited to intellectual property relating # to a hardware implementation of the functionality ...
44.946429
72
0.779102
from m5.SimObject import SimObject from m5.params import * class PowerModelState(SimObject): type = 'PowerModelState' cxx_header = "sim/power/power_model.hh" abstract = True cxx_class = 'PowerModelState' @classmethod def export_methods(cls, code): ...
true
true
1c37ab3392a1b72984b4a929b3c69cafec6d7511
4,480
py
Python
object-detector/test-classifier.py
vaibhavhariaramani/object-detector
b5ad46d78dc81b818aed3581f730f85e36c37373
[ "MIT" ]
464
2015-07-07T05:19:20.000Z
2022-03-24T23:46:41.000Z
object-detector/test-classifier.py
tofighi/object-detector
872d519f9e515ab0860b802a157df9b42063f78e
[ "MIT" ]
31
2015-08-27T20:08:31.000Z
2021-09-21T07:43:40.000Z
object-detector/test-classifier.py
tofighi/object-detector
872d519f9e515ab0860b802a157df9b42063f78e
[ "MIT" ]
260
2015-07-08T13:40:27.000Z
2022-03-11T15:22:10.000Z
# Import the required modules from skimage.transform import pyramid_gaussian from skimage.io import imread from skimage.feature import hog from sklearn.externals import joblib import cv2 import argparse as ap from nms import nms from config import * def sliding_window(image, window_size, step_size): ''' This f...
41.100917
101
0.610938
from skimage.transform import pyramid_gaussian from skimage.io import imread from skimage.feature import hog from sklearn.externals import joblib import cv2 import argparse as ap from nms import nms from config import * def sliding_window(image, window_size, step_size): ''' This function returns a patch of th...
false
true
1c37ab451ed1882f94ed21d6cef55d1de5b3dfb2
732
py
Python
app_one/migrations/0003_auto_20180906_1100.py
ngohoangyell/python-django-cbv-to-do-task
325ddbacce44baa6b06f50edd93615eb6c281fb9
[ "MIT" ]
1
2020-03-28T05:41:23.000Z
2020-03-28T05:41:23.000Z
app_one/migrations/0003_auto_20180906_1100.py
ngohoangyell/python-django-cbv-to-do-task
325ddbacce44baa6b06f50edd93615eb6c281fb9
[ "MIT" ]
null
null
null
app_one/migrations/0003_auto_20180906_1100.py
ngohoangyell/python-django-cbv-to-do-task
325ddbacce44baa6b06f50edd93615eb6c281fb9
[ "MIT" ]
null
null
null
# Generated by Django 2.1 on 2018-09-06 04:00 import datetime from django.db import migrations, models from django.utils.timezone import utc class Migration(migrations.Migration): dependencies = [ ('app_one', '0002_auto_20180906_1100'), ] operations = [ migrations.AlterFie...
28.153846
105
0.592896
import datetime from django.db import migrations, models from django.utils.timezone import utc class Migration(migrations.Migration): dependencies = [ ('app_one', '0002_auto_20180906_1100'), ] operations = [ migrations.AlterField( model_name='task', ...
true
true
1c37ac4c8498272775d81d61df98f0c918460bcc
618
py
Python
molecule/default/tests/test_default.py
avinetworks/ansible-role-avise
cce7e4e1b741601aace902e7a28a8e2e9766df36
[ "Apache-2.0" ]
3
2016-10-11T16:43:04.000Z
2016-11-21T16:59:15.000Z
molecule/default/tests/test_default.py
avinetworks/ansible-role-avise
cce7e4e1b741601aace902e7a28a8e2e9766df36
[ "Apache-2.0" ]
2
2019-09-20T05:52:14.000Z
2020-11-26T13:56:33.000Z
molecule/default/tests/test_default.py
avinetworks/ansible-role-avise
cce7e4e1b741601aace902e7a28a8e2e9766df36
[ "Apache-2.0" ]
5
2016-10-11T19:48:37.000Z
2021-09-26T16:17:10.000Z
############################################################################ # ======================================================================== # Copyright 2021 VMware, Inc. All rights reserved. VMware Confidential # ======================================================================== ### import os impo...
28.090909
76
0.456311
true
true
1c37ac78b3368b2cceda6e3f5b8fcb0fbd3a51ab
4,500
py
Python
openstack_dashboard/dashboards/admin/images/tests.py
ameoba/horizon
ff9e367c98a8bb79f10914abffaaa04b0a461819
[ "Apache-2.0" ]
2
2019-12-29T09:20:13.000Z
2020-01-01T13:12:34.000Z
openstack_dashboard/dashboards/admin/images/tests.py
yongquanf/horizon
9aad7fd6f66588fed7c27b720642e47a4a12854b
[ "Apache-2.0" ]
1
2015-03-12T01:03:44.000Z
2015-03-12T01:03:44.000Z
openstack_dashboard/dashboards/admin/images/tests.py
yongquanf/horizon
9aad7fd6f66588fed7c27b720642e47a4a12854b
[ "Apache-2.0" ]
4
2015-05-05T08:17:28.000Z
2020-02-05T10:47:06.000Z
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # Copyright 2012 Nebula, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # ...
42.056075
78
0.555333
from django.conf import settings from django.core.urlresolvers import reverse from django import http from django.test.utils import override_settings from mox import IsA from openstack_dashboard import api from openstack_dashboard.test import helpers as test from openstack_dashboard.dashboard...
true
true
1c37ad3c6e85968813e0b668ff632ccc6145eb04
1,292
py
Python
examples/event_handling/legend_picking.py
jbbrokaw/matplotlib
86ec1b6fc5628bfb2d09797c58d7eed0ca8c2427
[ "MIT", "BSD-3-Clause" ]
16
2016-06-14T19:45:35.000Z
2020-11-30T19:02:58.000Z
lib/mpl_examples/event_handling/legend_picking.py
yingkailiang/matplotlib
255a79b106c98c1904489afe6a754e4d943179d6
[ "MIT", "BSD-3-Clause" ]
7
2015-05-08T19:36:25.000Z
2015-06-30T15:32:17.000Z
lib/mpl_examples/event_handling/legend_picking.py
yingkailiang/matplotlib
255a79b106c98c1904489afe6a754e4d943179d6
[ "MIT", "BSD-3-Clause" ]
14
2015-10-05T04:15:46.000Z
2020-06-11T18:06:02.000Z
""" Enable picking on the legend to toggle the legended line on and off """ import numpy as np import matplotlib.pyplot as plt t = np.arange(0.0, 0.2, 0.1) y1 = 2*np.sin(2*np.pi*t) y2 = 4*np.sin(2*np.pi*2*t) fig, ax = plt.subplots() ax.set_title('Click on legend line to toggle line on/off') line1, = ax.plot(t, y1, lw...
28.086957
73
0.679567
import numpy as np import matplotlib.pyplot as plt t = np.arange(0.0, 0.2, 0.1) y1 = 2*np.sin(2*np.pi*t) y2 = 4*np.sin(2*np.pi*2*t) fig, ax = plt.subplots() ax.set_title('Click on legend line to toggle line on/off') line1, = ax.plot(t, y1, lw=2, color='red', label='1 HZ') line2, = ax.plot(t, y2, lw=2, color='blue', l...
true
true
1c37ae3f173da72ddbce0e44e1eaf2cc654095f9
305
py
Python
2018/11/graphics/bitcoin-nov-drop-20181128/graphic_config.py
nprapps/graphics-archive
97b0ef326b46a959df930f5522d325e537f7a655
[ "FSFAP" ]
14
2015-05-08T13:41:51.000Z
2021-02-24T12:34:55.000Z
2018/11/graphics/bitcoin-nov-drop-20181128/graphic_config.py
nprapps/graphics-archive
97b0ef326b46a959df930f5522d325e537f7a655
[ "FSFAP" ]
null
null
null
2018/11/graphics/bitcoin-nov-drop-20181128/graphic_config.py
nprapps/graphics-archive
97b0ef326b46a959df930f5522d325e537f7a655
[ "FSFAP" ]
7
2015-04-04T04:45:54.000Z
2021-02-18T11:12:48.000Z
#!/usr/bin/env python import base_filters COPY_GOOGLE_DOC_KEY = '1FKqTvQtjYjN9LlhCtkO59hUqZ6SbvUHfYpgetAS5sek' USE_ASSETS = False # Use these variables to override the default cache timeouts for this graphic # DEFAULT_MAX_AGE = 20 # ASSETS_MAX_AGE = 300 JINJA_FILTER_FUNCTIONS = base_filters.FILTERS
21.785714
77
0.819672
import base_filters COPY_GOOGLE_DOC_KEY = '1FKqTvQtjYjN9LlhCtkO59hUqZ6SbvUHfYpgetAS5sek' USE_ASSETS = False JINJA_FILTER_FUNCTIONS = base_filters.FILTERS
true
true
1c37ae41f6079eccf08a8ecad0c0187105559d92
388
py
Python
test1/wsgi.py
arohom/test1
2f8c662fbb347c017aba986e1cd36e2a428bade7
[ "MIT" ]
1
2019-12-15T16:56:44.000Z
2019-12-15T16:56:44.000Z
test1/test1/wsgi.py
1923488289/myfisttwo
a4b30b6944407f3525787eea777c327615e0caa7
[ "MIT" ]
87
2018-01-06T10:18:31.000Z
2022-03-11T23:32:30.000Z
test1/test1/wsgi.py
1923488289/myfisttwo
a4b30b6944407f3525787eea777c327615e0caa7
[ "MIT" ]
null
null
null
""" WSGI config for test1 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_SETTIN...
22.823529
78
0.783505
import os from django.core.wsgi import get_wsgi_application os.environ.setdefault("DJANGO_SETTINGS_MODULE", "test1.settings") application = get_wsgi_application()
true
true
1c37aebef98dc918d1cecaf7e1721cdf921d976a
3,045
py
Python
source/main/transcribe.py
SN-18/scrivener
76ca835b47f84ad231a6b4bf6ab9e212fc6b8724
[ "MIT" ]
null
null
null
source/main/transcribe.py
SN-18/scrivener
76ca835b47f84ad231a6b4bf6ab9e212fc6b8724
[ "MIT" ]
27
2021-10-21T18:39:01.000Z
2021-11-05T14:17:29.000Z
source/main/transcribe.py
SN-18/scrivener
76ca835b47f84ad231a6b4bf6ab9e212fc6b8724
[ "MIT" ]
2
2021-10-30T03:51:33.000Z
2021-11-30T02:10:49.000Z
""" Copyright (c) 2021 Anshul Patel This code is licensed under MIT license (see LICENSE.MD for details) @author: Scrivener """ # Import Libraries from source.main.summarize import Summary import speech_recognition as sr import moviepy.editor as mp from source.helper.split_audio import splitwavaudio import os from so...
30.45
84
0.636453
from source.main.summarize import Summary import speech_recognition as sr import moviepy.editor as mp from source.helper.split_audio import splitwavaudio import os from source.helper.cleanup import Cleanup from source.main.punctuation import Punctuation class TranscribeVideo: def __init(self): self.s...
true
true
1c37afebb69ae9547131b21420229a0cdf1df93e
5,438
py
Python
SpeakerIdentification.py
LL03-Identity-Dowell/100054-dowellvoiceapp
391df14aa4d438591bd7f9cb740d1f751b59e419
[ "Apache-2.0" ]
null
null
null
SpeakerIdentification.py
LL03-Identity-Dowell/100054-dowellvoiceapp
391df14aa4d438591bd7f9cb740d1f751b59e419
[ "Apache-2.0" ]
null
null
null
SpeakerIdentification.py
LL03-Identity-Dowell/100054-dowellvoiceapp
391df14aa4d438591bd7f9cb740d1f751b59e419
[ "Apache-2.0" ]
1
2021-09-16T09:19:38.000Z
2021-09-16T09:19:38.000Z
import os import wave import time import pickle #import pyaudio import warnings import numpy as np import sounddevice as sd from scipy.io.wavfile import write from sklearn import preprocessing from scipy.io.wavfile import read import python_speech_features as mfcc from sklearn.mixture import GaussianMixture...
29.394595
118
0.624127
import os import wave import time import pickle import warnings import numpy as np import sounddevice as sd from scipy.io.wavfile import write from sklearn import preprocessing from scipy.io.wavfile import read import python_speech_features as mfcc from sklearn.mixture import GaussianMixture warnings.fi...
true
true
1c37b0d7ea55b6b89fcebfe22cb902e7179ecae3
2,733
py
Python
shoppingtrends/data.py
jhooey/shopping-cart-trends
e2ee65c2cd1f95942000175479a6666459dff854
[ "BSD-3-Clause" ]
1
2015-01-04T17:02:43.000Z
2015-01-04T17:02:43.000Z
shoppingtrends/data.py
jhooey/shopping-cart-trends
e2ee65c2cd1f95942000175479a6666459dff854
[ "BSD-3-Clause" ]
null
null
null
shoppingtrends/data.py
jhooey/shopping-cart-trends
e2ee65c2cd1f95942000175479a6666459dff854
[ "BSD-3-Clause" ]
null
null
null
from localization import Province, Country, Store from user import User from receipt import Receipt, Item, Category import datetime def populate_all_tables(session): populate_provinces_tbl(session) def populate_provinces_tbl(session): canada = Country("CAN", "Canada") ontario = Province('Ontario','ON...
34.594937
103
0.564581
from localization import Province, Country, Store from user import User from receipt import Receipt, Item, Category import datetime def populate_all_tables(session): populate_provinces_tbl(session) def populate_provinces_tbl(session): canada = Country("CAN", "Canada") ontario = Province('Ontario','ON...
true
true
1c37b17225300688a6ee6cd36fb9cade85c157be
2,612
py
Python
server/tmparser.py
averyhiebert/groundstation
6df5dbbe83c0621f1adfef1f04bbcf098bb30c79
[ "MIT" ]
3
2018-07-01T19:21:22.000Z
2020-09-28T05:52:47.000Z
server/tmparser.py
averyhiebert/groundstation
6df5dbbe83c0621f1adfef1f04bbcf098bb30c79
[ "MIT" ]
null
null
null
server/tmparser.py
averyhiebert/groundstation
6df5dbbe83c0621f1adfef1f04bbcf098bb30c79
[ "MIT" ]
1
2018-06-16T04:47:40.000Z
2018-06-16T04:47:40.000Z
import re import json import time def decode_ll(s,is_lat=True): # s is a 4-character string containing compressed lat or lon data as # described in the APRS documentation. # is_lat is True for latitude and False for longitude. # # Return value is in decimal degrees, or None if not a number. if ...
36.788732
77
0.613323
import re import json import time def decode_ll(s,is_lat=True): if s == "NN!!": return None base_91 = sum((ord(c) - 33)*(91**i) for i,c in enumerate(reversed(s))) if is_lat: return 90 - base_91*1.0/380926 return -180 + base_91*1.0/190463 def dec...
true
true
1c37b1be2c3811d36040ad7c8fa8645101838750
1,213
py
Python
openstack_dashboard/test/integration_tests/tests/test_login.py
hemantsonawane95/horizon-apelby
01a5e72219aeca8c1451701ee85e232ed0618751
[ "Apache-2.0" ]
930
2015-01-04T08:06:03.000Z
2022-03-13T18:47:13.000Z
openstack_dashboard/test/integration_tests/tests/test_login.py
hemantsonawane95/horizon-apelby
01a5e72219aeca8c1451701ee85e232ed0618751
[ "Apache-2.0" ]
106
2019-01-18T03:06:55.000Z
2019-11-29T05:06:18.000Z
openstack_dashboard/test/integration_tests/tests/test_login.py
hemantsonawane95/horizon-apelby
01a5e72219aeca8c1451701ee85e232ed0618751
[ "Apache-2.0" ]
1,040
2015-01-01T18:48:28.000Z
2022-03-19T08:35:18.000Z
# Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # d...
39.129032
78
0.716406
from openstack_dashboard.test.integration_tests import helpers from openstack_dashboard.test.integration_tests.pages import loginpage class TestLogin(helpers.BaseTestCase): def test_login(self): login_pg = loginpage.LoginPage(self.driver, self.CONFIG) login_pg.go_to_login_page() ...
true
true
1c37b27ecc836f268bc8e919c2f06e85513de2ea
3,804
py
Python
carculator_truck/geomap.py
romainsacchi/carculator_truck
2c709ac6a956570a56ad2778619aef457e8d42a2
[ "BSD-3-Clause" ]
7
2021-03-19T12:28:18.000Z
2022-02-22T11:13:08.000Z
carculator_truck/geomap.py
romainsacchi/carculator_truck
2c709ac6a956570a56ad2778619aef457e8d42a2
[ "BSD-3-Clause" ]
1
2021-05-21T09:14:53.000Z
2021-05-27T09:23:29.000Z
carculator_truck/geomap.py
romainsacchi/carculator_truck
2c709ac6a956570a56ad2778619aef457e8d42a2
[ "BSD-3-Clause" ]
1
2022-02-22T11:13:00.000Z
2022-02-22T11:13:00.000Z
from wurst.geo import geomatcher from . import DATA_DIR REGION_MAPPING_FILEPATH = DATA_DIR / "regionmappingH12.csv" class Geomap: """ Map ecoinvent locations to IAM regions and vice-versa. """ def __init__(self): self.geo = self.get_IAM_geomatcher() @staticmethod def get_IAM_geoma...
29.261538
89
0.52103
from wurst.geo import geomatcher from . import DATA_DIR REGION_MAPPING_FILEPATH = DATA_DIR / "regionmappingH12.csv" class Geomap: def __init__(self): self.geo = self.get_IAM_geomatcher() @staticmethod def get_IAM_geomatcher(): d_image_regions = { "BRA": "Brazil", ...
true
true
1c37b83833807df30f1f7fed748b6fe7b6d22bf5
1,321
py
Python
plugins/explain.py
random-access7/corobo
5e517e3ca677e1465a1003307dfe0a755fc48cfb
[ "MIT" ]
null
null
null
plugins/explain.py
random-access7/corobo
5e517e3ca677e1465a1003307dfe0a755fc48cfb
[ "MIT" ]
null
null
null
plugins/explain.py
random-access7/corobo
5e517e3ca677e1465a1003307dfe0a755fc48cfb
[ "MIT" ]
null
null
null
import re import glob import os.path from errbot import BotPlugin, re_botcmd from errbot.templating import tenv class Explain(BotPlugin): """ Explain various terms """ files = glob.glob('plugins/templates/explain/*.jinja2.md') KNOWN_KEYS = [] for fname in files: KNOWN_KEYS.append(fna...
28.717391
72
0.557154
import re import glob import os.path from errbot import BotPlugin, re_botcmd from errbot.templating import tenv class Explain(BotPlugin): files = glob.glob('plugins/templates/explain/*.jinja2.md') KNOWN_KEYS = [] for fname in files: KNOWN_KEYS.append(fname.replace( 'plugins/templates...
true
true
1c37b83b83f4feed583f6c83a2af67c37998c475
1,350
py
Python
Cloud9.dev2/src/third_party/gyp/test/defines/gyptest-defines-env-regyp.py
twang15/BarrierFinder
c20ff99ffeeeabc1508682bc99ffb4c7659e7e9f
[ "MIT" ]
3
2019-02-12T04:14:39.000Z
2020-11-05T08:46:20.000Z
tools/gyp/test/defines/gyptest-defines-env-regyp.py
kans/birgo
d9aca7356933c4bb95f5649353acbc95e3083a57
[ "Apache-2.0" ]
null
null
null
tools/gyp/test/defines/gyptest-defines-env-regyp.py
kans/birgo
d9aca7356933c4bb95f5649353acbc95e3083a57
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # Copyright (c) 2011 Google Inc. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """ Verifies build of an executable with C++ define specified by a gyp define, and the use of the environment during regeneration when the g...
25.961538
80
0.737778
import os import TestGyp test = TestGyp.TestGyp(formats=['make']) try: os.environ['GYP_DEFINES'] = 'value=50' test.run_gyp('defines.gyp') finally: os.environ['GYP_DEFINES'] = '' del os.environ['GYP_DEFINES'] test.build('defines.gyp') expect = """\ FOO is defined VALUE is 1 2*PAREN_VALUE is...
true
true
1c37b842c09e88da94ae6e385ae5c966222a46f9
513
py
Python
src/test.py
kynmh69/cotoha_test
6c01ca0477399a2a07bc36a694850ad3c3c40228
[ "MIT" ]
1
2020-03-14T14:02:57.000Z
2020-03-14T14:02:57.000Z
src/test.py
kynmh69/cotoha_test
6c01ca0477399a2a07bc36a694850ad3c3c40228
[ "MIT" ]
null
null
null
src/test.py
kynmh69/cotoha_test
6c01ca0477399a2a07bc36a694850ad3c3c40228
[ "MIT" ]
null
null
null
import json from tkinter import Tk from gui.gui import Application from src.cotoha_api.cotoha_api import CotohaApi, CotohaApiResponse from src.logger.logger import logger_initialize, LoggerUtils EQUAL_STR = "=" * 20 if __name__ == "__main__": logger_initialize() logger = LoggerUtils.get_instance() logger...
27
66
0.738791
import json from tkinter import Tk from gui.gui import Application from src.cotoha_api.cotoha_api import CotohaApi, CotohaApiResponse from src.logger.logger import logger_initialize, LoggerUtils EQUAL_STR = "=" * 20 if __name__ == "__main__": logger_initialize() logger = LoggerUtils.get_instance() logger...
true
true
1c37b8c017e046ed568dd6da235c0bc53fc0dd6a
677
py
Python
trace_operator.py
6895mahfuzgit/Linear_Algebra_for_Machine_Learning
3f266391491d9ab99e53a3547900c6b1bd657af1
[ "Apache-2.0" ]
null
null
null
trace_operator.py
6895mahfuzgit/Linear_Algebra_for_Machine_Learning
3f266391491d9ab99e53a3547900c6b1bd657af1
[ "Apache-2.0" ]
null
null
null
trace_operator.py
6895mahfuzgit/Linear_Algebra_for_Machine_Learning
3f266391491d9ab99e53a3547900c6b1bd657af1
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Fri Sep 17 02:09:53 2021 @author: Mahfuz_Shazol """ import numpy as np import torch as th A=np.array([[25,2], [5,4]]) A_trace=np.trace(A) print(A_trace) # Tr(A)=Tr(A.T) result1=np.trace(A) print(result1) result2=np.trace(A.T) print(result2) print('Tr(A)=Tr(A.T) ...
13.54
89
0.635155
import numpy as np import torch as th A=np.array([[25,2], [5,4]]) A_trace=np.trace(A) print(A_trace) result1=np.trace(A) print(result1) result2=np.trace(A.T) print(result2) print('Tr(A)=Tr(A.T) Ans:',result1==result2) A_p=th.tensor([ [-1,2], [3,-2], [5,7], ]) calculated_frobeniu...
true
true
1c37b94b8d6ed6dc771e8357788977085e797788
2,143
py
Python
aliyun-python-sdk-mse/aliyunsdkmse/request/v20190531/DeleteNacosConfigRequest.py
jorsonzen/aliyun-openapi-python-sdk
0afbfa8e5f9e19455695aa799f7dcc1cd853d827
[ "Apache-2.0" ]
null
null
null
aliyun-python-sdk-mse/aliyunsdkmse/request/v20190531/DeleteNacosConfigRequest.py
jorsonzen/aliyun-openapi-python-sdk
0afbfa8e5f9e19455695aa799f7dcc1cd853d827
[ "Apache-2.0" ]
null
null
null
aliyun-python-sdk-mse/aliyunsdkmse/request/v20190531/DeleteNacosConfigRequest.py
jorsonzen/aliyun-openapi-python-sdk
0afbfa8e5f9e19455695aa799f7dcc1cd853d827
[ "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...
36.322034
74
0.74895
from aliyunsdkcore.request import RpcRequest from aliyunsdkmse.endpoint import endpoint_data class DeleteNacosConfigRequest(RpcRequest): def __init__(self): RpcRequest.__init__(self, 'mse', '2019-05-31', 'DeleteNacosConfig') self.set_method('POST') if hasattr(self, "endpoint_map"): set...
true
true
1c37bc1dc6d774ea34be94b34a72e489ac4ada8f
677
py
Python
scrapyd/scheduler.py
senohaha/jzSpiderNode
9ff725a00a25c74c4fc9b6096c7c4d8dd1de6ba4
[ "BSD-3-Clause" ]
null
null
null
scrapyd/scheduler.py
senohaha/jzSpiderNode
9ff725a00a25c74c4fc9b6096c7c4d8dd1de6ba4
[ "BSD-3-Clause" ]
null
null
null
scrapyd/scheduler.py
senohaha/jzSpiderNode
9ff725a00a25c74c4fc9b6096c7c4d8dd1de6ba4
[ "BSD-3-Clause" ]
null
null
null
# -*-coding: utf-8 -*- from zope.interface import implementer from .interfaces import ISpiderScheduler from .utils import get_spider_queues @implementer(ISpiderScheduler) class SpiderScheduler(object): def __init__(self, config): self.config = config self.update_projects() def schedule(self,...
28.208333
93
0.700148
from zope.interface import implementer from .interfaces import ISpiderScheduler from .utils import get_spider_queues @implementer(ISpiderScheduler) class SpiderScheduler(object): def __init__(self, config): self.config = config self.update_projects() def schedule(self, project, spider_name,...
true
true
1c37bc73f791a3975a6afa5c87788d3edc839815
692
py
Python
strategy/minimize.py
shimomura314/non-bit-reversi
587aaeea0476c5c6339b6c96f7525c66cbc5321f
[ "MIT" ]
null
null
null
strategy/minimize.py
shimomura314/non-bit-reversi
587aaeea0476c5c6339b6c96f7525c66cbc5321f
[ "MIT" ]
null
null
null
strategy/minimize.py
shimomura314/non-bit-reversi
587aaeea0476c5c6339b6c96f7525c66cbc5321f
[ "MIT" ]
null
null
null
"""Various strategies for othello. """ import random class Minimize: """Put disk to minimize number of one's disks.""" def __init__(self): return def put_disk(self, othello): """Put disk to minimize number of one's disks.""" min_strategy = [] min_merit = float('inf') ...
31.454545
65
0.614162
import random class Minimize: def __init__(self): return def put_disk(self, othello): min_strategy = [] min_merit = float('inf') for candidate in othello.reversible.keys(): if min_merit > len(othello.reversible[candidate]): min_strategy = [candidat...
true
true
1c37bc84fb69610331ac21e64650183042302f84
2,438
py
Python
Organise-Files-According-To-Their-Extensions/script_dirs.py
A-kriti/Amazing-Python-Scripts
ebf607fe39e6d9e61f30ec3439fc8d6ab1f736b9
[ "MIT" ]
930
2020-09-05T22:07:28.000Z
2022-03-30T07:56:18.000Z
Organise-Files-According-To-Their-Extensions/script_dirs.py
maheshdbabar9340/Amazing-Python-Scripts
e2272048cbe49b4bda5072bbdd8479739bb6c18d
[ "MIT" ]
893
2020-09-04T07:57:24.000Z
2022-02-08T02:12:26.000Z
Organise-Files-According-To-Their-Extensions/script_dirs.py
maheshdbabar9340/Amazing-Python-Scripts
e2272048cbe49b4bda5072bbdd8479739bb6c18d
[ "MIT" ]
497
2020-09-05T08:16:24.000Z
2022-03-31T00:55:57.000Z
import os from pathlib import Path import sys # Taking input print_string = """ Type Path of the directory OR Press enter for running the script on current directory: OR Type quit """ print(print_string + "\n\n") input_path = input("Input:") print("\n\n") # Script will terminate if input is 'quit' if input_path == "q...
31.25641
118
0.684988
import os from pathlib import Path import sys print_string = """ Type Path of the directory OR Press enter for running the script on current directory: OR Type quit """ print(print_string + "\n\n") input_path = input("Input:") print("\n\n") if input_path == "quit": sys.exit(1) if input_path == "": input_p...
true
true
1c37bcdaebfc6149a8029cccfbac3b7468196323
6,554
py
Python
awswrangler/s3/_write_dataset.py
isichei/aws-data-wrangler
0ce3836000bc5f4b5f7adffdb81392cdcf135b7a
[ "Apache-2.0" ]
2
2021-10-24T01:01:08.000Z
2022-01-12T13:23:44.000Z
awswrangler/s3/_write_dataset.py
isichei/aws-data-wrangler
0ce3836000bc5f4b5f7adffdb81392cdcf135b7a
[ "Apache-2.0" ]
67
2021-01-15T15:00:37.000Z
2022-03-21T09:27:42.000Z
awswrangler/s3/_write_dataset.py
isichei/aws-data-wrangler
0ce3836000bc5f4b5f7adffdb81392cdcf135b7a
[ "Apache-2.0" ]
3
2020-12-29T17:27:38.000Z
2021-01-15T13:47:25.000Z
"""Amazon S3 Write Dataset (PRIVATE).""" import logging from typing import Any, Callable, Dict, List, Optional, Tuple, Union import boto3 import numpy as np import pandas as pd from awswrangler import exceptions from awswrangler.s3._delete import delete_objects from awswrangler.s3._write_concurrent import _WriteProx...
32.606965
109
0.614434
import logging from typing import Any, Callable, Dict, List, Optional, Tuple, Union import boto3 import numpy as np import pandas as pd from awswrangler import exceptions from awswrangler.s3._delete import delete_objects from awswrangler.s3._write_concurrent import _WriteProxy _logger: logging.Logger = logging.getL...
true
true
1c37bd002df98cf406408b1b8384bf64c26f3e96
4,474
py
Python
tests/apps/info/memo/commands_test.py
item4/yui
8628d0d54b94ada3cbe7d1b0f624063258bad10a
[ "MIT" ]
36
2017-06-12T01:09:46.000Z
2021-01-31T17:57:41.000Z
tests/apps/info/memo/commands_test.py
item4/yui
8628d0d54b94ada3cbe7d1b0f624063258bad10a
[ "MIT" ]
145
2017-06-21T13:31:29.000Z
2021-06-20T01:01:30.000Z
tests/apps/info/memo/commands_test.py
item4/yui
8628d0d54b94ada3cbe7d1b0f624063258bad10a
[ "MIT" ]
21
2017-07-24T15:53:19.000Z
2021-12-23T04:18:31.000Z
import pytest from yui.apps.info.memo.commands import memo_add from yui.apps.info.memo.commands import memo_delete from yui.apps.info.memo.commands import memo_show from yui.apps.info.memo.models import Memo from yui.orm.utils import get_count @pytest.mark.asyncio async def test_memo_flow(bot, fx_sess): keyword1...
26.951807
71
0.602816
import pytest from yui.apps.info.memo.commands import memo_add from yui.apps.info.memo.commands import memo_delete from yui.apps.info.memo.commands import memo_show from yui.apps.info.memo.models import Memo from yui.orm.utils import get_count @pytest.mark.asyncio async def test_memo_flow(bot, fx_sess): keyword1...
true
true
1c37bd1b5ff673772f12755c5de44777390b17f0
2,664
py
Python
PythonClient/car/legacy_hello_car.py
whatseven/AirSim
fe7e4e7c782cf1077594c1ee6cc1bbfec3f66bd1
[ "MIT" ]
7
2020-05-22T18:00:19.000Z
2021-01-07T08:31:19.000Z
PythonClient/car/legacy_hello_car.py
whatseven/AirSim
fe7e4e7c782cf1077594c1ee6cc1bbfec3f66bd1
[ "MIT" ]
4
2020-08-21T07:48:06.000Z
2021-03-14T21:06:41.000Z
PythonClient/car/legacy_hello_car.py
whatseven/AirSim
fe7e4e7c782cf1077594c1ee6cc1bbfec3f66bd1
[ "MIT" ]
7
2020-05-22T20:08:22.000Z
2021-01-22T09:39:17.000Z
""" For connecting to the AirSim drone environment and testing API functionality """ import os import tempfile import pprint import setup_path import airsim # connect to the AirSim simulator client = airsim.MultirotorClient() client.confirmConnection() client.enableApiControl(True) client.armDisarm(True) state = ...
34.597403
117
0.737988
import os import tempfile import pprint import setup_path import airsim client = airsim.MultirotorClient() client.confirmConnection() client.enableApiControl(True) client.armDisarm(True) state = client.getMultirotorState() s = pprint.pformat(state) print("state: %s" % s) airsim.wait_key('Press any key to takeof...
true
true
1c37bdc53354937df90dffa8566038d87a1e44cb
16,065
py
Python
geopandas/tests/test_extension_array.py
standakozak/geopandas
9f5413f8e992472d89d312cc4853d74c76fbbdf1
[ "BSD-3-Clause" ]
2,914
2015-01-01T14:27:43.000Z
2022-03-31T22:26:39.000Z
geopandas/tests/test_extension_array.py
standakozak/geopandas
9f5413f8e992472d89d312cc4853d74c76fbbdf1
[ "BSD-3-Clause" ]
2,040
2015-01-16T11:34:26.000Z
2022-03-31T12:13:39.000Z
geopandas/tests/test_extension_array.py
standakozak/geopandas
9f5413f8e992472d89d312cc4853d74c76fbbdf1
[ "BSD-3-Clause" ]
758
2015-01-21T20:23:32.000Z
2022-03-31T17:22:53.000Z
""" This file contains a minimal set of tests for compliance with the extension array interface test suite (by inheriting the pandas test suite), and should contain no other tests. Other tests (eg related to the spatial functionality or integration with GeoSeries/GeoDataFrame) should be added to test_array.py and other...
27.414676
88
0.651292
import operator import numpy as np from numpy.testing import assert_array_equal import pandas as pd from pandas.tests.extension import base as extension_tests import shapely.geometry from geopandas.array import GeometryArray, GeometryDtype, from_shapely from geopandas._compat import ignore_shapely2_warnings import ...
true
true
1c37be98984ec7224180548ff6d1dbe3a33de59e
1,940
py
Python
receipts/receipts/admin.py
rolisz/receipt_budget
74f73e7f8bb8b0b4fa89bfebf4c3c2c930511308
[ "BSD-3-Clause" ]
15
2016-03-02T18:16:46.000Z
2022-03-05T10:55:58.000Z
receipts/receipts/admin.py
rolisz/receipt_budget
74f73e7f8bb8b0b4fa89bfebf4c3c2c930511308
[ "BSD-3-Clause" ]
1
2017-04-10T23:46:43.000Z
2017-04-10T23:46:43.000Z
receipts/receipts/admin.py
rolisz/receipt_budget
74f73e7f8bb8b0b4fa89bfebf4c3c2c930511308
[ "BSD-3-Clause" ]
11
2016-03-02T18:16:12.000Z
2020-07-19T11:57:27.000Z
from django.contrib import admin from receipts.models import Expense, ExpenseItem, Shop from django.core.urlresolvers import reverse from django.utils.safestring import mark_safe class ExpenseItemInline(admin.StackedInline): model = ExpenseItem extra = 2 template = 'admin/receipts/expense/item_stacked.ht...
31.803279
85
0.673711
from django.contrib import admin from receipts.models import Expense, ExpenseItem, Shop from django.core.urlresolvers import reverse from django.utils.safestring import mark_safe class ExpenseItemInline(admin.StackedInline): model = ExpenseItem extra = 2 template = 'admin/receipts/expense/item_stacked.ht...
true
true
1c37bf63892ff3c3dc3eea7b99f3a2fe1c154eb9
15,380
py
Python
tifresi/phase/modGabPhaseGrad.py
andimarafioti/tifresi
676db371d5c472a5f3199506bf3863367a2ecde4
[ "MIT" ]
12
2020-02-08T09:47:17.000Z
2021-07-31T09:22:41.000Z
tifresi/phase/modGabPhaseGrad.py
nperraud/stft4pghi
676db371d5c472a5f3199506bf3863367a2ecde4
[ "MIT" ]
1
2020-07-20T22:32:49.000Z
2020-07-21T15:20:11.000Z
tifresi/phase/modGabPhaseGrad.py
nperraud/stft4pghi
676db371d5c472a5f3199506bf3863367a2ecde4
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # ######### COPYRIGHT ######### # Credits # ####### # # Copyright(c) 2015-2018 # ---------------------- # # * `LabEx Archimède <http://labex-archimede.univ-amu.fr/>`_ # * `Laboratoire d'Informatique Fondamentale <http://www.lif.univ-mrs.fr/>`_ # (now `Laboratoire d'Informatique et Systèmes <ht...
34.954545
81
0.633745
t Jaillet <contact.dev_AT_lis-lab.fr> # # Description # ----------- # # ltfatpy is a partial Python port of the # `Large Time/Frequency Analysis Toolbox <http://ltfat.sourceforge.net/>`_, # a MATLAB®/Octave toolbox for working with time-frequency analysis and # synthesis. # # Version # ------- # # * ltfatpy version = ...
true
true
1c37bfd8ec65b02baae06a02cae28fc2283c52ec
971
py
Python
main/settings/stage.py
wuuuduu/django-notifications2
544502ec02bf34b4e0ff613500fd29766aecd229
[ "BSD-3-Clause" ]
1
2020-09-08T20:13:58.000Z
2020-09-08T20:13:58.000Z
main/settings/stage.py
wuuuduu/django-notifications2
544502ec02bf34b4e0ff613500fd29766aecd229
[ "BSD-3-Clause" ]
null
null
null
main/settings/stage.py
wuuuduu/django-notifications2
544502ec02bf34b4e0ff613500fd29766aecd229
[ "BSD-3-Clause" ]
null
null
null
from .base import * from .logging import ConfigureLogger LOGGING_LEVEL = 'INFO' ConfigureLogger(log_level=LOGGING_LEVEL, logging_dir=LOGGING_DIR, django_modules=PROJECT_APPS) REST_FRAMEWORK['DEFAULT_RENDERER_CLASSES'] = [ 'rest_framework.renderers.JSONRenderer', ] ALLOWED_HOSTS = [ 'api.stage.example.com' ]...
23.682927
94
0.649846
from .base import * from .logging import ConfigureLogger LOGGING_LEVEL = 'INFO' ConfigureLogger(log_level=LOGGING_LEVEL, logging_dir=LOGGING_DIR, django_modules=PROJECT_APPS) REST_FRAMEWORK['DEFAULT_RENDERER_CLASSES'] = [ 'rest_framework.renderers.JSONRenderer', ] ALLOWED_HOSTS = [ 'api.stage.example.com' ]...
true
true
1c37c0a9cb26e30c5fb60c8dbfd4c2ea7166eb2a
15,493
py
Python
daseki/common/__init__.py
cuthbertLab/daseki
48a16ab1351bd1128c06092065234ea1016a87ef
[ "BSD-3-Clause" ]
null
null
null
daseki/common/__init__.py
cuthbertLab/daseki
48a16ab1351bd1128c06092065234ea1016a87ef
[ "BSD-3-Clause" ]
null
null
null
daseki/common/__init__.py
cuthbertLab/daseki
48a16ab1351bd1128c06092065234ea1016a87ef
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- # ----------------------------------------------------------------------------- # Name: common.py # Purpose: Commonly used tools across Daseki # # Authors: Michael Scott Cuthbert # # Copyright: Copyright © 2014-16 Michael Scott Cuthbert / cuthbertLab # License: BSD, see...
28.117967
97
0.57981
from typing import Any from daseki.common.parallel import * import enum import inspect import re import os import sys import time import tempfile import weakref from daseki.exceptionsDS import DasekiException maxRetrosheetYear = 2015 class TeamNum(enum.IntEnum): VISITOR = 0 HOME = 1 def sou...
true
true
1c37c1f7bdcfbe9db8a303114887b9cbea05e3b6
4,260
py
Python
bot/utils.py
Alpha-Omega-United/discord-bot
d395c1e139de8b59773fb0a222d08f68105a811c
[ "MIT" ]
1
2021-09-21T07:50:39.000Z
2021-09-21T07:50:39.000Z
bot/utils.py
Alpha-Omega-United/discord-bot
d395c1e139de8b59773fb0a222d08f68105a811c
[ "MIT" ]
1
2021-07-30T20:31:49.000Z
2021-08-17T16:50:43.000Z
bot/utils.py
Alpha-Omega-United/discord-bot
d395c1e139de8b59773fb0a222d08f68105a811c
[ "MIT" ]
1
2021-08-10T16:41:39.000Z
2021-08-10T16:41:39.000Z
"""Helper functions.""" from __future__ import annotations from dataclasses import dataclass from typing import TYPE_CHECKING import hikari from bot import constants if TYPE_CHECKING: from typing import Awaitable import tanjun def is_admin(member: hikari.Member) -> bool: """ Check if a member is...
28.026316
82
0.661972
from __future__ import annotations from dataclasses import dataclass from typing import TYPE_CHECKING import hikari from bot import constants if TYPE_CHECKING: from typing import Awaitable import tanjun def is_admin(member: hikari.Member) -> bool: roles = member.get_roles() return any(role.id ==...
true
true
1c37c32f6b96cbaa4f9672e1a1276cb7d4d1aad4
5,702
py
Python
modules/event.py
TheApertureProject/Yume-Bot
9b1219958f1c43489c0fbc33825ae7656eeea02e
[ "MIT" ]
1
2020-06-04T17:26:13.000Z
2020-06-04T17:26:13.000Z
modules/event.py
TheApertureProject/Yume-Bot
9b1219958f1c43489c0fbc33825ae7656eeea02e
[ "MIT" ]
null
null
null
modules/event.py
TheApertureProject/Yume-Bot
9b1219958f1c43489c0fbc33825ae7656eeea02e
[ "MIT" ]
null
null
null
# Copyright (c) 2019. # MIT License # # Copyright (c) 2019 YumeNetwork # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # ...
38.789116
119
0.571554
import random import discord from discord.ext import commands from modules.sql.guilddb import GuildDB from modules.utils import lists class Event(commands.Cog): conf = {} def __init__(self, bot): self.bot = bot self.config = bot.config @commands.Cog.listener() ...
true
true
1c37c515ccfe0f90bc286e7c0bc33482d12a3037
7,574
py
Python
src/oci/data_safe/models/tls_config.py
Manny27nyc/oci-python-sdk
de60b04e07a99826254f7255e992f41772902df7
[ "Apache-2.0", "BSD-3-Clause" ]
249
2017-09-11T22:06:05.000Z
2022-03-04T17:09:29.000Z
src/oci/data_safe/models/tls_config.py
Manny27nyc/oci-python-sdk
de60b04e07a99826254f7255e992f41772902df7
[ "Apache-2.0", "BSD-3-Clause" ]
228
2017-09-11T23:07:26.000Z
2022-03-23T10:58:50.000Z
src/oci/data_safe/models/tls_config.py
Manny27nyc/oci-python-sdk
de60b04e07a99826254f7255e992f41772902df7
[ "Apache-2.0", "BSD-3-Clause" ]
224
2017-09-27T07:32:43.000Z
2022-03-25T16:55:42.000Z
# coding: utf-8 # Copyright (c) 2016, 2021, Oracle and/or its affiliates. All rights reserved. # This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may c...
33.964126
245
0.66319
from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel from oci.decorators import init_model_state_from_kwargs @init_model_state_from_kwargs class TlsConfig(object): STATUS_ENABLED = "ENABLED" STATUS_DISABLED = "DISABLED" CERTIF...
true
true
1c37c566dd1447eac08426f66222b65b38b12130
1,121
py
Python
examples/standalone_plan.py
dpcomp-org/ektelo
7629fbf106f9b9568c66a0b97f6005280022c3d8
[ "Apache-2.0" ]
null
null
null
examples/standalone_plan.py
dpcomp-org/ektelo
7629fbf106f9b9568c66a0b97f6005280022c3d8
[ "Apache-2.0" ]
1
2019-04-09T20:51:32.000Z
2019-04-09T20:51:32.000Z
examples/standalone_plan.py
dpcomp-org/ektelo
7629fbf106f9b9568c66a0b97f6005280022c3d8
[ "Apache-2.0" ]
null
null
null
""" Example of the invocation of a standalone plan """ from ektelo import data from ektelo import workload from ektelo.plans import standalone from ektelo.private import transformation import os import numpy as np import yaml CSV_PATH = os.environ['EKTELO_DATA'] CONFIG_PATH = os.path.join(os.environ['EKTELO_HOME'], '...
26.690476
96
0.742194
from ektelo import data from ektelo import workload from ektelo.plans import standalone from ektelo.private import transformation import os import numpy as np import yaml CSV_PATH = os.environ['EKTELO_DATA'] CONFIG_PATH = os.path.join(os.environ['EKTELO_HOME'], 'resources', 'config') filename = os.path.join(CSV_PAT...
true
true
1c37c5dec7c9b26fac370eb8d7e111002c09524a
171
py
Python
.history/calculator_factories_20210629130649.py
Aleff13/calculadora-tkinter
01e169d3c1d128976eb3a41ea1f53f11d6157e44
[ "MIT" ]
null
null
null
.history/calculator_factories_20210629130649.py
Aleff13/calculadora-tkinter
01e169d3c1d128976eb3a41ea1f53f11d6157e44
[ "MIT" ]
null
null
null
.history/calculator_factories_20210629130649.py
Aleff13/calculadora-tkinter
01e169d3c1d128976eb3a41ea1f53f11d6157e44
[ "MIT" ]
null
null
null
import tkinter as tk def make_root() -> tk.Tk: root = tk.Tk() root.title("Calculator") root.config(padx=10, pady=10, background="white") return root
21.375
53
0.625731
import tkinter as tk def make_root() -> tk.Tk: root = tk.Tk() root.title("Calculator") root.config(padx=10, pady=10, background="white") return root
true
true
1c37c69715879ce386b01293ebb811b4037e288a
6,823
py
Python
third_party/boto/manage/task.py
stdft112/depot_tools
52c7211807930272424213ff6127c209de790eca
[ "BSD-3-Clause" ]
2,151
2020-04-18T07:31:17.000Z
2022-03-31T08:39:18.000Z
third_party/boto/manage/task.py
stdft112/depot_tools
52c7211807930272424213ff6127c209de790eca
[ "BSD-3-Clause" ]
395
2020-04-18T08:22:18.000Z
2021-12-08T13:04:49.000Z
third_party/boto/manage/task.py
stdft112/depot_tools
52c7211807930272424213ff6127c209de790eca
[ "BSD-3-Clause" ]
338
2020-04-18T08:03:10.000Z
2022-03-29T12:33:22.000Z
# Copyright (c) 2006-2009 Mitch Garnaat http://garnaat.org/ # # Permission is hereby granted, free of charge, to any person obtaining a # copy of this software and associated documentation files (the # "Software"), to deal in the Software without restriction, including # without limitation the rights to use, copy, modi...
38.767045
104
0.597245
import boto from boto.sdb.db.property import StringProperty, DateTimeProperty, IntegerProperty from boto.sdb.db.model import Model import datetime, subprocess, StringIO, time def check_hour(val): if val == '*': return if int(val) < 0 or int(val) > 23: raise ValueError ...
true
true
1c37c6dbd9f5765f750aee5d81ab7b88235339b9
402
py
Python
litemark/__init__.py
pyrustic/litemark
49669865b7aa23f964eec0117b7ba1936658a0d2
[ "MIT" ]
4
2021-10-14T16:20:36.000Z
2022-01-18T08:44:12.000Z
litemark/__init__.py
pyrustic/litemark
49669865b7aa23f964eec0117b7ba1936658a0d2
[ "MIT" ]
null
null
null
litemark/__init__.py
pyrustic/litemark
49669865b7aa23f964eec0117b7ba1936658a0d2
[ "MIT" ]
null
null
null
from litemark.core import scanner from litemark.core.scanner import Element from litemark.core.viewer import Viewer, get_light_style from litemark.core.style import Style from litemark.core.util import center_window __all__ = ["scan", "Element", "Viewer", "get_light_style", "Style"] def scan(text): """Returns a...
28.714286
67
0.756219
from litemark.core import scanner from litemark.core.scanner import Element from litemark.core.viewer import Viewer, get_light_style from litemark.core.style import Style from litemark.core.util import center_window __all__ = ["scan", "Element", "Viewer", "get_light_style", "Style"] def scan(text): return scann...
true
true
1c37c9049f3188be7356e8c6011ee01171864c66
3,234
py
Python
tests/components/mqtt/test_server.py
logic/home-assistant
d3fed52254053a24e901cde8528c0e407d429311
[ "Apache-2.0" ]
7
2018-08-03T10:15:36.000Z
2019-03-25T13:31:55.000Z
tests/components/mqtt/test_server.py
sara0871/thepracticaldev
28de2d6f75656349de94dd897156d33fbadaa43a
[ "Apache-2.0" ]
3
2021-09-08T03:06:43.000Z
2022-03-12T00:56:04.000Z
tests/components/mqtt/test_server.py
sara0871/thepracticaldev
28de2d6f75656349de94dd897156d33fbadaa43a
[ "Apache-2.0" ]
3
2018-12-04T11:54:27.000Z
2019-08-31T14:41:32.000Z
"""The tests for the MQTT component embedded server.""" from unittest.mock import Mock, MagicMock, patch import sys import pytest from homeassistant.setup import setup_component import homeassistant.components.mqtt as mqtt from tests.common import get_test_home_assistant, mock_coro # Until https://github.com/beerf...
41.461538
77
0.693568
from unittest.mock import Mock, MagicMock, patch import sys import pytest from homeassistant.setup import setup_component import homeassistant.components.mqtt as mqtt from tests.common import get_test_home_assistant, mock_coro @pytest.mark.skipif(sys.version_info[:2] >= (3, 7), reason='Package...
true
true
1c37c95e39cda9c81e5ca97fe1bf80cd91fe316a
20,863
py
Python
conans/model/conf.py
Mu-L/conan
7c24ec4bbd6e8c16cdcd879403aae742689bc36a
[ "MIT" ]
1
2019-11-04T17:23:09.000Z
2019-11-04T17:23:09.000Z
conans/model/conf.py
Mu-L/conan
7c24ec4bbd6e8c16cdcd879403aae742689bc36a
[ "MIT" ]
1
2020-11-05T16:16:49.000Z
2020-11-05T16:16:49.000Z
conans/model/conf.py
Mattlk13/conan
005fc53485557b0a570bb71670f2ca9c66082165
[ "MIT" ]
null
null
null
import fnmatch from collections import OrderedDict import six from conans.errors import ConanException BUILT_IN_CONFS = { "core:required_conan_version": "Raise if current version does not match the defined range.", "core.package_id:msvc_visual_incompatible": "Allows opting-out the fallback from the new msvc ...
41.231225
169
0.629056
import fnmatch from collections import OrderedDict import six from conans.errors import ConanException BUILT_IN_CONFS = { "core:required_conan_version": "Raise if current version does not match the defined range.", "core.package_id:msvc_visual_incompatible": "Allows opting-out the fallback from the new msvc ...
true
true
1c37c9f2571d4f730113497bd724d86eecbeae20
4,454
py
Python
lecture_05/homework5/tasks/oop_1.py
RomanSafe/epam_python_training
3aac68062e1764af844cb3e96f9481791acffc9d
[ "MIT" ]
null
null
null
lecture_05/homework5/tasks/oop_1.py
RomanSafe/epam_python_training
3aac68062e1764af844cb3e96f9481791acffc9d
[ "MIT" ]
2
2020-12-30T19:39:36.000Z
2020-12-30T21:49:33.000Z
lecture_05/homework5/tasks/oop_1.py
RomanSafe/epam_python_training
3aac68062e1764af844cb3e96f9481791acffc9d
[ "MIT" ]
null
null
null
""" Необходимо создать 3 класса и взаимосвязь между ними (Student, Teacher, Homework) Наследование в этой задаче использовать не нужно. Для работы с временем использовать модуль datetime 1. Homework принимает на вход 2 атрибута: текст задания и количество дней на это задание Атрибуты: text - текст задания dead...
28.922078
86
0.680287
import datetime from typing import NewType, Union Timedelta = NewType("Timedelta", datetime.timedelta) class Homework: def __init__(self, text: str, deadline: int) -> None: self.text = text self.deadline = datetime.timedelta(days=deadline) self.created = datetime.datetime.now() def...
true
true
1c37cb5565ca95fa508b29ea62af0b67f57a39d8
550
py
Python
test_fizzbuzz.py
milton63/fizzbuzz
411bd9fc720c081da1ef5eab5d273abab31b8fc5
[ "MIT" ]
null
null
null
test_fizzbuzz.py
milton63/fizzbuzz
411bd9fc720c081da1ef5eab5d273abab31b8fc5
[ "MIT" ]
1
2020-05-27T15:38:47.000Z
2020-05-27T15:38:47.000Z
test_fizzbuzz.py
milton63/fizzbuzz
411bd9fc720c081da1ef5eab5d273abab31b8fc5
[ "MIT" ]
1
2020-05-27T13:51:15.000Z
2020-05-27T13:51:15.000Z
from fizzbuzz import fizzbuzz def test_number(): assert fizzbuzz(1) == 1 def test_div_3(): assert fizzbuzz(3) == 'Fizz' def test_div_5(): assert fizzbuzz(5) == 'Buzz' def test_div_3and5(): assert fizzbuzz(15) == 'Fizz Buzz' def test_range(): result = [fizzbuzz(x) for x in range(1, 16)] ...
13.75
48
0.469091
from fizzbuzz import fizzbuzz def test_number(): assert fizzbuzz(1) == 1 def test_div_3(): assert fizzbuzz(3) == 'Fizz' def test_div_5(): assert fizzbuzz(5) == 'Buzz' def test_div_3and5(): assert fizzbuzz(15) == 'Fizz Buzz' def test_range(): result = [fizzbuzz(x) for x in range(1, 16)] ...
true
true
1c37cc07ef8124bd64a11be641a95a2aad421fcc
2,000
py
Python
src/ops/inventory/caching.py
Asjidkalam/ops-cli
951b6e53452aef60cd7a67b95cb3bf227d81c02d
[ "Apache-2.0" ]
182
2019-02-02T22:57:41.000Z
2022-03-19T11:40:15.000Z
src/ops/inventory/caching.py
Asjidkalam/ops-cli
951b6e53452aef60cd7a67b95cb3bf227d81c02d
[ "Apache-2.0" ]
66
2019-02-04T14:43:53.000Z
2021-10-05T14:19:56.000Z
src/ops/inventory/caching.py
Asjidkalam/ops-cli
951b6e53452aef60cd7a67b95cb3bf227d81c02d
[ "Apache-2.0" ]
48
2019-02-05T14:22:10.000Z
2021-09-29T13:41:11.000Z
# Copyright 2019 Adobe. All rights reserved. # This file is licensed to you 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 ...
28.985507
88
0.7035
import hashlib import json import os import time from six import PY3 def cache_callback_result(directory, func, max_age, cache_key_args): directory = os.path.expanduser(directory) path = get_cache_path(directory, cache_key_args) if is_valid(path, max_age): return read(path) return ...
true
true
1c37cc8897a039705453174914ac87e0aa6dd676
6,216
py
Python
lib/googlecloudsdk/api_lib/transfer/operations_util.py
google-cloud-sdk-unofficial/google-cloud-sdk
2a48a04df14be46c8745050f98768e30474a1aac
[ "Apache-2.0" ]
2
2019-11-10T09:17:07.000Z
2019-12-18T13:44:08.000Z
lib/googlecloudsdk/api_lib/transfer/operations_util.py
google-cloud-sdk-unofficial/google-cloud-sdk
2a48a04df14be46c8745050f98768e30474a1aac
[ "Apache-2.0" ]
null
null
null
lib/googlecloudsdk/api_lib/transfer/operations_util.py
google-cloud-sdk-unofficial/google-cloud-sdk
2a48a04df14be46c8745050f98768e30474a1aac
[ "Apache-2.0" ]
1
2020-07-25T01:40:19.000Z
2020-07-25T01:40:19.000Z
# -*- coding: utf-8 -*- # # Copyright 2021 Google LLC. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless requir...
36.350877
80
0.741956
from __future__ import absolute_import from __future__ import division from __future__ import unicode_literals from apitools.base.py import encoding from googlecloudsdk.api_lib.transfer import jobs_util from googlecloudsdk.api_lib.util import apis from googlecloudsdk.command_lib.transfer import name_util...
true
true
1c37cc960048a6de7328e5484c890c05c68dd0cc
1,325
py
Python
Chapter05/virtualenvs/myproject_env/project/django-myproject/myproject/urls.py
PacktPublishing/Django-2-Web-Development-Cookbook-Third-Edition
f129613e2b1d00f5c76649025ae4d568f6286f2c
[ "MIT" ]
75
2018-12-03T02:35:29.000Z
2021-11-08T13:13:34.000Z
Chapter05/virtualenvs/myproject_env/project/django-myproject/myproject/urls.py
PacktPublishing/Django-2-Web-Development-Cookbook-Third-Edition
f129613e2b1d00f5c76649025ae4d568f6286f2c
[ "MIT" ]
3
2019-08-11T13:35:01.000Z
2020-09-29T06:52:36.000Z
Chapter04/virtualenvs/myproject_env/project/django-myproject/myproject/urls.py
PacktPublishing/Django-2-Web-Development-Cookbook-Third-Edition
f129613e2b1d00f5c76649025ae4d568f6286f2c
[ "MIT" ]
45
2018-11-03T14:03:22.000Z
2021-08-25T07:39:33.000Z
"""myproject URL Configuration The `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/2.1/topics/http/urls/ Examples: Function views 1. Add an import: from my_app import views 2. Add a URL to urlpatterns: path('', views.home, name='home') Class-bas...
35.810811
77
0.676981
from django.contrib import admin from django.conf.urls.i18n import i18n_patterns from django.urls import include, path urlpatterns = [ path('admin/', admin.site.urls), path('bulletins/', include('bulletin_board.urls')), path('cv/', include('cv.urls')), path('email/', include('email_messages.urls')), ...
true
true
1c37cce45e3f42c0c9228dc0917458e271696929
2,932
py
Python
src/sentry/lang/native/utils.py
learninto/sentry
4f9f564841498b3af49c1677d6b61f3e47b01923
[ "BSD-3-Clause" ]
null
null
null
src/sentry/lang/native/utils.py
learninto/sentry
4f9f564841498b3af49c1677d6b61f3e47b01923
[ "BSD-3-Clause" ]
null
null
null
src/sentry/lang/native/utils.py
learninto/sentry
4f9f564841498b3af49c1677d6b61f3e47b01923
[ "BSD-3-Clause" ]
null
null
null
from __future__ import absolute_import import re import six import logging from sentry.stacktraces.processing import find_stacktraces_in_data from sentry.utils.safe import get_path logger = logging.getLogger(__name__) # Regex to parse OS versions from a minidump OS string. VERSION_RE = re.compile(r"(\d+\.\d+\.\d+)\...
27.148148
87
0.658595
from __future__ import absolute_import import re import six import logging from sentry.stacktraces.processing import find_stacktraces_in_data from sentry.utils.safe import get_path logger = logging.getLogger(__name__) VERSION_RE = re.compile(r"(\d+\.\d+\.\d+)\s+(.*)") WINDOWS_PATH_RE = re.compile(r"^([a-z]:\\|\\...
true
true
1c37cd0577c3baf926e58ab3b3f22495cf34232b
31
py
Python
arranger/closest/__init__.py
dezimynona/icml2021submission
009eb6c6b617536bda7a247cbf5d6b7c0c131f19
[ "MIT" ]
1
2021-07-11T17:20:02.000Z
2021-07-11T17:20:02.000Z
arranger/closest/__init__.py
dezimynona/icml2021submission
009eb6c6b617536bda7a247cbf5d6b7c0c131f19
[ "MIT" ]
null
null
null
arranger/closest/__init__.py
dezimynona/icml2021submission
009eb6c6b617536bda7a247cbf5d6b7c0c131f19
[ "MIT" ]
1
2021-02-03T19:22:27.000Z
2021-02-03T19:22:27.000Z
"""Closest-pitch algorithm."""
15.5
30
0.677419
true
true
1c37cdca199ced6425daca6cc92bee848283a476
698
py
Python
sdk/python-sdk/setup.py
tw-bc-group/verity-sdk
e932209ab849f04a389bdda0718cd6227187e5cf
[ "Apache-2.0" ]
null
null
null
sdk/python-sdk/setup.py
tw-bc-group/verity-sdk
e932209ab849f04a389bdda0718cd6227187e5cf
[ "Apache-2.0" ]
2
2021-09-02T19:02:06.000Z
2021-09-02T19:02:24.000Z
sdk/python-sdk/setup.py
tw-bc-group/verity-sdk
e932209ab849f04a389bdda0718cd6227187e5cf
[ "Apache-2.0" ]
1
2021-01-13T10:43:14.000Z
2021-01-13T10:43:14.000Z
import setuptools from verity_sdk.version import VERSION with open('README.md', 'r') as fh: long_description = fh.read() setuptools.setup( name="verity-sdk", version=VERSION, # see verity_sdk/version.py author="Evernym, Inc.", author_email="dev@evernym.com", description='The official Python ...
25.851852
64
0.667622
import setuptools from verity_sdk.version import VERSION with open('README.md', 'r') as fh: long_description = fh.read() setuptools.setup( name="verity-sdk", version=VERSION, author="Evernym, Inc.", author_email="dev@evernym.com", description='The official Python SDK for Evernym\'s Verity',...
true
true
1c37ce6927cbfac725faaa0c541bb5f99388ebb2
1,428
py
Python
utils/average_plate.py
khainn/ALPR_System
73d8adc6bc7cb91507d1bf047ded20be844923ef
[ "Apache-2.0" ]
71
2019-01-04T03:42:04.000Z
2022-03-28T16:38:58.000Z
utils/average_plate.py
khainn/ALPR_System
73d8adc6bc7cb91507d1bf047ded20be844923ef
[ "Apache-2.0" ]
14
2019-11-05T18:20:05.000Z
2022-02-10T00:30:54.000Z
utils/average_plate.py
khainn/ALPR_System
73d8adc6bc7cb91507d1bf047ded20be844923ef
[ "Apache-2.0" ]
38
2019-03-26T09:05:20.000Z
2022-03-25T12:46:36.000Z
""" Gets the recognized plate in several frames and calculates the most possible plate value """ import math from collections import Counter def getDistance(pointA, pointB): """ calculates the distance between two points in the image """ return math.sqrt(math.pow((pointA[0] - pointB[0]), 2) + math.po...
34
105
0.691877
import math from collections import Counter def getDistance(pointA, pointB): return math.sqrt(math.pow((pointA[0] - pointB[0]), 2) + math.pow((pointA[1] - pointB[1]), 2)) def tracking(previous_coordinate, current_coordinate): distance = getDistance(previous_coordinate, current_coordinate) return distan...
true
true
1c37cf8f0e69896397ea2c6e841faf4fa2ce3678
7,883
py
Python
main.py
namansnghl/goblin-hunter-pygame
c740549ff70e4233d3c17558a5a6e62f0025a3cf
[ "MIT" ]
null
null
null
main.py
namansnghl/goblin-hunter-pygame
c740549ff70e4233d3c17558a5a6e62f0025a3cf
[ "MIT" ]
null
null
null
main.py
namansnghl/goblin-hunter-pygame
c740549ff70e4233d3c17558a5a6e62f0025a3cf
[ "MIT" ]
null
null
null
import pygame pygame.init() screen_width = 987 screen_height = 598 # setting window size. win = pygame.display.set_mode((screen_width, screen_height)) # game window title pygame.display.set_caption("Goblin Hunter") # loading character movements bg = pygame.image.load('img/bg.jpg') idle = pygame.image.load('img/standi...
32.709544
236
0.578714
import pygame pygame.init() screen_width = 987 screen_height = 598 win = pygame.display.set_mode((screen_width, screen_height)) pygame.display.set_caption("Goblin Hunter") bg = pygame.image.load('img/bg.jpg') idle = pygame.image.load('img/standing.png') class player: walkRight = list(map(pygame.image.load, ...
true
true
1c37cff4afe4b2afdd67d7d83fdde90f400a23b5
35,293
py
Python
python/lvmcam/araviscam/BlackflyCam.py
sdss/lvmcam
c5f421a546a0072a0dbb3d7b2ebc74316f339f64
[ "BSD-3-Clause" ]
3
2021-11-17T02:40:02.000Z
2022-03-22T08:30:45.000Z
python/lvmcam/araviscam/BlackflyCam.py
sdss/lvmcam
c5f421a546a0072a0dbb3d7b2ebc74316f339f64
[ "BSD-3-Clause" ]
8
2021-11-25T10:18:31.000Z
2021-12-17T13:04:52.000Z
python/lvmcam/araviscam/BlackflyCam.py
sdss/lvmcam
c5f421a546a0072a0dbb3d7b2ebc74316f339f64
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python3 """ Python3 class to work with Aravis/GenICam cameras, subclass of sdss-basecam. .. module:: araviscam .. moduleauthor:: Richard J. Mathar <mathar@mpia.de> """ import sys import math import asyncio import numpy import astropy from basecam.mixins import ImageAreaMixIn from basecam import ( ...
39.170921
157
0.572096
import sys import math import asyncio import numpy import astropy from basecam.mixins import ImageAreaMixIn from basecam import ( CameraSystem, BaseCamera, CameraEvent, CameraConnectionError, models, ExposureError, ) from lvmcam.actor import modules from lvmcam.araviscam.aravis import...
true
true
1c37d00a7158416e048e17ac299d114678c5fcb7
548
py
Python
is-prime/solution.py
astone648/CodeWars
13f0bf9108433909abd5cf7270515cc63a06ebd1
[ "MIT" ]
null
null
null
is-prime/solution.py
astone648/CodeWars
13f0bf9108433909abd5cf7270515cc63a06ebd1
[ "MIT" ]
null
null
null
is-prime/solution.py
astone648/CodeWars
13f0bf9108433909abd5cf7270515cc63a06ebd1
[ "MIT" ]
null
null
null
from random import * import math def is_prime(num): if num < 1: return False; elif num == 1: return False; elif num > 2 and num % 2 == 0: return False; else: for n in range(3,int(math.sqrt(num)//1)+1): if num % n == 0: return False return ...
21.076923
51
0.54562
from random import * import math def is_prime(num): if num < 1: return False; elif num == 1: return False; elif num > 2 and num % 2 == 0: return False; else: for n in range(3,int(math.sqrt(num)//1)+1): if num % n == 0: return False return ...
true
true
1c37d0215a8ae853b15095889bc7d195c9b05519
10,236
py
Python
homeassistant/components/emulated_hue/__init__.py
dzmitov/core
7697ef7f5ec357ae5ab76237dc52af55fc044c36
[ "Apache-2.0" ]
1
2021-01-14T11:42:12.000Z
2021-01-14T11:42:12.000Z
homeassistant/components/emulated_hue/__init__.py
dzmitov/core
7697ef7f5ec357ae5ab76237dc52af55fc044c36
[ "Apache-2.0" ]
null
null
null
homeassistant/components/emulated_hue/__init__.py
dzmitov/core
7697ef7f5ec357ae5ab76237dc52af55fc044c36
[ "Apache-2.0" ]
1
2020-09-23T16:41:16.000Z
2020-09-23T16:41:16.000Z
"""Support for local control of entities by emulating a Philips Hue bridge.""" import logging from aiohttp import web import voluptuous as vol from homeassistant import util from homeassistant.components.http import real_ip from homeassistant.const import EVENT_HOMEASSISTANT_START, EVENT_HOMEASSISTANT_STOP from homea...
33.126214
88
0.661293
import logging from aiohttp import web import voluptuous as vol from homeassistant import util from homeassistant.components.http import real_ip from homeassistant.const import EVENT_HOMEASSISTANT_START, EVENT_HOMEASSISTANT_STOP from homeassistant.exceptions import HomeAssistantError import homeassistant.helpers.conf...
true
true
1c37d11febd64d8252bc97e1eb9d9befd448a37b
531
py
Python
finpro/urls.py
aditya1702/FinPro
bd0b6a8abc0ad613b39f0e814e5d5dea746ded50
[ "MIT" ]
null
null
null
finpro/urls.py
aditya1702/FinPro
bd0b6a8abc0ad613b39f0e814e5d5dea746ded50
[ "MIT" ]
null
null
null
finpro/urls.py
aditya1702/FinPro
bd0b6a8abc0ad613b39f0e814e5d5dea746ded50
[ "MIT" ]
null
null
null
from django.conf.urls import url from FinPro import views from django.contrib.auth import views as auth_views from django.urls import path, include from django.contrib import admin urlpatterns = [ path('admin/', admin.site.urls), url(r'^dashboard', views.DashboardPageView.as_view(), name = 'dashboard'), ur...
37.928571
82
0.717514
from django.conf.urls import url from FinPro import views from django.contrib.auth import views as auth_views from django.urls import path, include from django.contrib import admin urlpatterns = [ path('admin/', admin.site.urls), url(r'^dashboard', views.DashboardPageView.as_view(), name = 'dashboard'), ur...
true
true