hexsha
stringlengths
40
40
size
int64
7
1.04M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
247
max_stars_repo_name
stringlengths
4
125
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
368k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
4
247
max_issues_repo_name
stringlengths
4
125
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
116k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
4
247
max_forks_repo_name
stringlengths
4
125
max_forks_repo_head_hexsha
stringlengths
40
78
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
1
1.04M
avg_line_length
float64
1.77
618k
max_line_length
int64
1
1.02M
alphanum_fraction
float64
0
1
original_content
stringlengths
7
1.04M
filtered:remove_function_no_docstring
int64
-102
942k
filtered:remove_class_no_docstring
int64
-354
977k
filtered:remove_delete_markers
int64
0
60.1k
171b35e459d4df2ef610ce1e9bf98a196e7313aa
2,475
py
Python
out1.py
LAKSHMI-PANNEER/Project-works
229b92c89fe5ef133759e4bd5140b23d823fd317
[ "bzip2-1.0.6" ]
null
null
null
out1.py
LAKSHMI-PANNEER/Project-works
229b92c89fe5ef133759e4bd5140b23d823fd317
[ "bzip2-1.0.6" ]
null
null
null
out1.py
LAKSHMI-PANNEER/Project-works
229b92c89fe5ef133759e4bd5140b23d823fd317
[ "bzip2-1.0.6" ]
null
null
null
from bs4 import BeautifulSoup import requests import nltk from nltk import sent_tokenize from nltk.tokenize import word_tokenize from nltk.corpus import stopwords from nltk.probability import FreqDist from collections import Counter from nltk import Tree import re ''' url = 'https://www.lifewire.com/how-to-edit-videos-...
23.798077
70
0.57899
from bs4 import BeautifulSoup import requests import nltk from nltk import sent_tokenize from nltk.tokenize import word_tokenize from nltk.corpus import stopwords from nltk.probability import FreqDist from collections import Counter from nltk import Tree import re ''' url = 'https://www.lifewire.com/how-to-edit-videos-...
0
0
0
3523d1b5d4da641b8090fabe844b4d1c32886c0b
729
py
Python
{{cookiecutter.site_dir}}/tests/fixtures/user.py
StuartMacKay/cookiecutter-django-site
bae97e0e872c2244f488dfec57d65a5d82ed1123
[ "BSD-3-Clause" ]
null
null
null
{{cookiecutter.site_dir}}/tests/fixtures/user.py
StuartMacKay/cookiecutter-django-site
bae97e0e872c2244f488dfec57d65a5d82ed1123
[ "BSD-3-Clause" ]
null
null
null
{{cookiecutter.site_dir}}/tests/fixtures/user.py
StuartMacKay/cookiecutter-django-site
bae97e0e872c2244f488dfec57d65a5d82ed1123
[ "BSD-3-Clause" ]
null
null
null
import pytest @pytest.fixture @pytest.fixture
27
82
0.647462
import pytest @pytest.fixture def create_user(db, django_user_model, faker): def make_user(**kwargs): if "password" not in kwargs: kwargs["password"] = faker.password() if "username" not in kwargs: kwargs["username"] = faker.user_name() return django_user_model.obje...
635
0
44
8d0baee078c877d889b6857d37c69ce3368c900a
266
py
Python
03-loops/l2.py
philiphinton/learn_python
6ddfe3c7818d6c919bfa49bd6302c75ee761b6a4
[ "MIT" ]
null
null
null
03-loops/l2.py
philiphinton/learn_python
6ddfe3c7818d6c919bfa49bd6302c75ee761b6a4
[ "MIT" ]
3
2022-01-17T22:55:09.000Z
2022-01-26T07:26:13.000Z
03-loops/l2.py
philiphinton/learn_python
6ddfe3c7818d6c919bfa49bd6302c75ee761b6a4
[ "MIT" ]
1
2021-12-14T01:33:21.000Z
2021-12-14T01:33:21.000Z
# Getting all the elements in a list — a better way, using a "for" loop shopping_list = ["Tomatoes", "Bananas", "Crackers", "Sugar", "Icecream", "Bread", "Bananas", "Chocolate"] print("Shopping list:") for item in shopping_list: print(item)
24.181818
71
0.635338
# Getting all the elements in a list — a better way, using a "for" loop shopping_list = ["Tomatoes", "Bananas", "Crackers", "Sugar", "Icecream", "Bread", "Bananas", "Chocolate"] print("Shopping list:") for item in shopping_list: print(item)
0
0
0
6ae222686adf7be738f54c0e87c2c1ae9fbf0804
22,835
py
Python
pysnmp-with-texts/A3COM-SWITCHING-SYSTEMS-POLL-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
8
2019-05-09T17:04:00.000Z
2021-06-09T06:50:51.000Z
pysnmp-with-texts/A3COM-SWITCHING-SYSTEMS-POLL-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
4
2019-05-31T16:42:59.000Z
2020-01-31T21:57:17.000Z
pysnmp-with-texts/A3COM-SWITCHING-SYSTEMS-POLL-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
10
2019-04-30T05:51:36.000Z
2022-02-16T03:33:41.000Z
# # PySNMP MIB module A3COM-SWITCHING-SYSTEMS-POLL-MIB (http://snmplabs.com/pysmi) # ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/A3COM-SWITCHING-SYSTEMS-POLL-MIB # Produced by pysmi-0.3.4 at Wed May 1 11:08:25 2019 # On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4 # Using Pyt...
248.206522
1,468
0.790891
# # PySNMP MIB module A3COM-SWITCHING-SYSTEMS-POLL-MIB (http://snmplabs.com/pysmi) # ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/A3COM-SWITCHING-SYSTEMS-POLL-MIB # Produced by pysmi-0.3.4 at Wed May 1 11:08:25 2019 # On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4 # Using Pyt...
0
0
0
04f724f65cf3f46e8fc88c0677143aa5fee28059
4,150
py
Python
model/hyparameter.py
zouguojian/FDN-Learning
ef89cb7d6654d5ac2425621ec6b330652a281f16
[ "MIT" ]
1
2021-03-24T10:59:27.000Z
2021-03-24T10:59:27.000Z
model/hyparameter.py
zouguojian/FDN-Learning
ef89cb7d6654d5ac2425621ec6b330652a281f16
[ "MIT" ]
null
null
null
model/hyparameter.py
zouguojian/FDN-Learning
ef89cb7d6654d5ac2425621ec6b330652a281f16
[ "MIT" ]
null
null
null
# -- coding: utf-8 -- import argparse if __name__=='__main__': para=parameter(argparse.ArgumentParser()) print(para.get_para().batch_size)
68.032787
126
0.567229
# -- coding: utf-8 -- import argparse class parameter(object): def __init__(self,parser): self.parser=parser self.parser.add_argument('--city_list',type=list,default=['ShangHai','NanJing','SuZhou', 'NanTong','WuXi','ChangZhou', ...
3,924
3
75
dc6e63994bdd8c75d62673f03d9f9ae50a89c924
433
py
Python
plugins/bot_Setu/model/getSetuConfig.py
A-Soul-GameMaker-Project/ACBot
120a8cff9bf3727e9e0a5510743c1a4713853d3c
[ "MIT" ]
null
null
null
plugins/bot_Setu/model/getSetuConfig.py
A-Soul-GameMaker-Project/ACBot
120a8cff9bf3727e9e0a5510743c1a4713853d3c
[ "MIT" ]
null
null
null
plugins/bot_Setu/model/getSetuConfig.py
A-Soul-GameMaker-Project/ACBot
120a8cff9bf3727e9e0a5510743c1a4713853d3c
[ "MIT" ]
null
null
null
from typing import List, Literal, Union from botoy import FriendMsg, GroupMsg from pydantic import BaseModel, Field
27.0625
63
0.644342
from typing import List, Literal, Union from botoy import FriendMsg, GroupMsg from pydantic import BaseModel, Field class GetSetuConfig(BaseModel): level: int = Field(0, ge=0, le=2) # 0:非r18 1:r18 2:混合 toGetNum: int = Field(1, ge=1) doneNum: int = 0 # flagID: int = 0 # ctx: Union[GroupMsg, Frien...
0
298
23
fe83a5394b3cbe242d6b40a15246fd3899d81d70
6,860
py
Python
deeplearning/datagenerator.py
wadpac/SleepStageClassification
5b288995e62bbd66faa66bd932b06af8a65f8445
[ "Apache-2.0" ]
24
2019-04-15T09:18:51.000Z
2022-03-05T14:09:34.000Z
deeplearning/datagenerator.py
wadpac/SleepStageClassification
5b288995e62bbd66faa66bd932b06af8a65f8445
[ "Apache-2.0" ]
2
2021-01-28T01:02:06.000Z
2021-04-02T06:34:04.000Z
deeplearning/datagenerator.py
wadpac/SleepStageClassification
5b288995e62bbd66faa66bd932b06af8a65f8445
[ "Apache-2.0" ]
11
2019-05-30T19:27:39.000Z
2021-06-19T02:41:53.000Z
import numpy as np from tensorflow.keras.utils import Sequence, to_categorical import random from tqdm import tqdm from transforms import jitter, time_warp, rotation, rand_sampling from transforms import get_ENMO, get_angle_z, get_LIDS from collections import Counter
40.116959
109
0.638047
import numpy as np from tensorflow.keras.utils import Sequence, to_categorical import random from tqdm import tqdm from transforms import jitter, time_warp, rotation, rand_sampling from transforms import get_ENMO, get_angle_z, get_LIDS from collections import Counter class DataGenerator(Sequence): def __init__(self,...
0
6,569
23
46d4f1dd50ef6402432da80f3c3bdcae3c08f7f3
1,856
py
Python
scripts/swarm_mon.py
khromiumos/chromiumos-chromite
a42a85481cdd9d635dc40a04585e427f89f3bb3f
[ "BSD-3-Clause" ]
null
null
null
scripts/swarm_mon.py
khromiumos/chromiumos-chromite
a42a85481cdd9d635dc40a04585e427f89f3bb3f
[ "BSD-3-Clause" ]
2
2021-03-26T00:29:32.000Z
2021-04-30T21:29:33.000Z
scripts/swarm_mon.py
khromiumos/chromiumos-chromite
a42a85481cdd9d635dc40a04585e427f89f3bb3f
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright 2017 The Chromium OS Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Send swarming-proxy latency monitoring data to ts_mon.""" from __future__ import absolute_import from __future__ import print_...
34.37037
77
0.689655
# -*- coding: utf-8 -*- # Copyright 2017 The Chromium OS Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Send swarming-proxy latency monitoring data to ts_mon.""" from __future__ import absolute_import from __future__ import print_...
1,088
0
23
9033ef6254220337e98d6c41b45cfd91eef6907e
181
py
Python
touchtechnology/common/__init__.py
goodtune/vitriolic
d135eecf7acbc229a872585ebafb8bbefca52df4
[ "BSD-3-Clause" ]
null
null
null
touchtechnology/common/__init__.py
goodtune/vitriolic
d135eecf7acbc229a872585ebafb8bbefca52df4
[ "BSD-3-Clause" ]
28
2016-12-09T21:14:19.000Z
2022-01-11T07:17:16.000Z
touchtechnology/common/__init__.py
goodtune/vitriolic
d135eecf7acbc229a872585ebafb8bbefca52df4
[ "BSD-3-Clause" ]
null
null
null
import logging logger = logging.getLogger(__name__) NAME = 'Common Components' INSTALL = ('AccountsSite',) __version__ = '3.5.5' logger.debug('"%s"/"%s"' % (NAME, __version__))
16.454545
47
0.685083
import logging logger = logging.getLogger(__name__) NAME = 'Common Components' INSTALL = ('AccountsSite',) __version__ = '3.5.5' logger.debug('"%s"/"%s"' % (NAME, __version__))
0
0
0
30b13541657f8048f09881d6c5d930cc12bd4dfe
2,893
py
Python
PythonAPI/examples/plot_avg_speed.py
AdaCompNUS/summ
a91f0c06202fb6a4100249882eec69ddf5bc7656
[ "MIT" ]
103
2020-03-10T04:21:50.000Z
2022-03-29T13:26:57.000Z
PythonAPI/examples/plot_avg_speed.py
AdaCompNUS/summ
a91f0c06202fb6a4100249882eec69ddf5bc7656
[ "MIT" ]
12
2020-04-11T11:36:01.000Z
2021-12-09T11:35:56.000Z
PythonAPI/examples/plot_avg_speed.py
AdaCompNUS/summ
a91f0c06202fb6a4100249882eec69ddf5bc7656
[ "MIT" ]
8
2020-11-21T07:47:12.000Z
2022-03-25T13:41:05.000Z
import numpy as np import matplotlib.pyplot as plt INTERVAL = 30 WINDOW = 5 data_gamma = read_avg_speed('statistics.gamma.log') data_simple = read_avg_speed('statistics.ttc.log') fig, axs = plt.subplots(figsize=(17.5, 8)) axs.set_xlabel('Simulation Time (s)', fontsize=34) axs.set_ylabel('Average Speed (m/s)', fontsi...
25.830357
98
0.529554
import numpy as np import matplotlib.pyplot as plt INTERVAL = 30 WINDOW = 5 def read_avg_speed(path): data = [] with open(path) as f: last_time = 0 line = f.readline() window_total_speed = [0, 0, 0] window_num = 0 global_total_speed = 0 global_num = 0 ...
1,110
0
23
25661dcea64c2d32d43027c7a16476ed57b60ea4
1,579
py
Python
ipyparallel/client/_joblib.py
EnjoyLifeFund/macHighSierra-py36-pkgs
5668b5785296b314ea1321057420bcd077dba9ea
[ "BSD-3-Clause", "BSD-2-Clause", "MIT" ]
1
2022-01-25T22:52:58.000Z
2022-01-25T22:52:58.000Z
ipyparallel/client/_joblib.py
EnjoyLifeFund/Debian_py36_packages
1985d4c73fabd5f08f54b922e73a9306e09c77a5
[ "BSD-3-Clause", "BSD-2-Clause", "MIT" ]
null
null
null
ipyparallel/client/_joblib.py
EnjoyLifeFund/Debian_py36_packages
1985d4c73fabd5f08f54b922e73a9306e09c77a5
[ "BSD-3-Clause", "BSD-2-Clause", "MIT" ]
null
null
null
"""joblib parallel backend for IPython Parallel""" # Copyright (c) IPython Development Team. # Distributed under the terms of the Modified BSD License. from __future__ import absolute_import import ipyparallel as ipp from joblib.parallel import ParallelBackendBase, AutoBatchingMixin
30.960784
74
0.58898
"""joblib parallel backend for IPython Parallel""" # Copyright (c) IPython Development Team. # Distributed under the terms of the Modified BSD License. from __future__ import absolute_import import ipyparallel as ipp from joblib.parallel import ParallelBackendBase, AutoBatchingMixin class IPythonParallelBackend(Auto...
684
584
23
7830fe6d98011992769e06dc7494488567f6b328
2,138
py
Python
video-streaming/video_streaming/ffmpeg/tasks/mixins/check_output_key.py
mojtaba-arvin/video-service
d75bd59d8203277fc6a50440d3f0b34693958ee1
[ "MIT" ]
9
2021-02-21T21:42:19.000Z
2022-03-10T02:42:47.000Z
video-streaming/video_streaming/ffmpeg/tasks/mixins/check_output_key.py
mojtaba-arvin/video-service
d75bd59d8203277fc6a50440d3f0b34693958ee1
[ "MIT" ]
null
null
null
video-streaming/video_streaming/ffmpeg/tasks/mixins/check_output_key.py
mojtaba-arvin/video-service
d75bd59d8203277fc6a50440d3f0b34693958ee1
[ "MIT" ]
1
2021-08-12T20:32:26.000Z
2021-08-12T20:32:26.000Z
from celery import Task from video_streaming.core.tasks import BaseTask from video_streaming.ffmpeg.tasks.base import BaseStreamingTask from .check import BaseCheckMixin
35.633333
73
0.656688
from celery import Task from video_streaming.core.tasks import BaseTask from video_streaming.ffmpeg.tasks.base import BaseStreamingTask from .check import BaseCheckMixin class CheckOutputKeyMixin(BaseCheckMixin): primary_status: BaseStreamingTask.primary_status stop_reason: BaseStreamingTask.stop_reason ...
1,073
871
23
d8d78f589fecd38330fac246db9e695fca3359d5
42
py
Python
Autokey/CapsKeybinds/shift alt/left.py
MisaghM/Capslock-Keybindings
00332c7d39cf776c43fe13aa08e1c2969747425d
[ "MIT" ]
1
2021-11-05T19:39:36.000Z
2021-11-05T19:39:36.000Z
Autokey/CapsKeybinds/shift alt/left.py
MisaghM/Capslock-Keybindings
00332c7d39cf776c43fe13aa08e1c2969747425d
[ "MIT" ]
null
null
null
Autokey/CapsKeybinds/shift alt/left.py
MisaghM/Capslock-Keybindings
00332c7d39cf776c43fe13aa08e1c2969747425d
[ "MIT" ]
null
null
null
keyboard.send_keys("<shift>+<alt>+<left>")
42
42
0.690476
keyboard.send_keys("<shift>+<alt>+<left>")
0
0
0
9c32dd67d59654f7d35162c52dc0a458bdcd6fc5
242
py
Python
tests/test_multiple_lines_489.py
themiwi/ggplot
b6d23c22d52557b983da8ce7a3a6992501dadcd6
[ "BSD-2-Clause" ]
1,133
2017-01-10T16:58:15.000Z
2022-03-31T14:40:29.000Z
tests/test_multiple_lines_489.py
themiwi/ggplot
b6d23c22d52557b983da8ce7a3a6992501dadcd6
[ "BSD-2-Clause" ]
287
2015-01-02T18:54:17.000Z
2017-01-10T14:48:14.000Z
tests/test_multiple_lines_489.py
themiwi/ggplot
b6d23c22d52557b983da8ce7a3a6992501dadcd6
[ "BSD-2-Clause" ]
295
2017-01-16T19:16:49.000Z
2022-02-18T14:10:58.000Z
from ggplot import * import pandas as pd df = pd.DataFrame({'a': range(0,3), 'b': range(1,4)}) df['x'] = df.index df = pd.melt(df, id_vars='x') print df print ggplot(aes(x='x', y='value', color='variable'), df) + geom_line() + geom_point()
24.2
86
0.628099
from ggplot import * import pandas as pd df = pd.DataFrame({'a': range(0,3), 'b': range(1,4)}) df['x'] = df.index df = pd.melt(df, id_vars='x') print df print ggplot(aes(x='x', y='value', color='variable'), df) + geom_line() + geom_point()
0
0
0
818cc9a0b2358625ff1d16add3562b5576b86eb8
838
py
Python
modules/src/fact.py
anamayagarodia/JARVIS-on-Messenger
d7198db0afe99cf3c0f7aacd5d5a16641deba809
[ "MIT" ]
6
2017-05-17T23:46:16.000Z
2017-05-18T19:50:15.000Z
modules/src/fact.py
anamayagarodia/JARVIS-on-Messenger
d7198db0afe99cf3c0f7aacd5d5a16641deba809
[ "MIT" ]
null
null
null
modules/src/fact.py
anamayagarodia/JARVIS-on-Messenger
d7198db0afe99cf3c0f7aacd5d5a16641deba809
[ "MIT" ]
2
2018-08-06T06:03:58.000Z
2020-01-08T07:57:37.000Z
import requests from templates.text import TextTemplate from random import choice import json import config
29.928571
77
0.589499
import requests from templates.text import TextTemplate from random import choice import json import config def process(input, entities=None): output = {} try: ''' r = requests.get('http://numbersapi.com/random/trivia', headers={ 'Content-Type': 'application/json' }) ...
707
0
23
a91506587a48276be47e00254986ca05fb660424
17,256
py
Python
hpx/general.py
flowmatters/py-hpx
43408da4235dd22d17dd7189bf485eb5682ed944
[ "0BSD" ]
null
null
null
hpx/general.py
flowmatters/py-hpx
43408da4235dd22d17dd7189bf485eb5682ed944
[ "0BSD" ]
null
null
null
hpx/general.py
flowmatters/py-hpx
43408da4235dd22d17dd7189bf485eb5682ed944
[ "0BSD" ]
null
null
null
import pandas as pd import numpy as np import xarray as xr import sys import os from glob import glob import re from datetime import datetime import tempfile import shutil from .gw import set_gw_depth HP1_DIR=os.path.join(os.getcwd(),'HP1') HP1_EXE=os.path.join(HP1_DIR,'hp1.exe') DEFAULT_OUTPUTS={ ...
32.806084
577
0.511242
import pandas as pd import numpy as np import xarray as xr import sys import os from glob import glob import re from datetime import datetime import tempfile import shutil from .gw import set_gw_depth HP1_DIR=os.path.join(os.getcwd(),'HP1') HP1_EXE=os.path.join(HP1_DIR,'hp1.exe') DEFAULT_OUTPUTS={ ...
12,662
7
637
5867f6c9c7c4def1e9b0a718d6d1eb06ea352cdf
7,931
py
Python
neutron/db/migration/alembic_migrations/versions/4dbe243cd84d_nsxv.py
gampel/neutron
51a6260266dc59c066072ca890ad9c40b1aad6cf
[ "Apache-2.0" ]
null
null
null
neutron/db/migration/alembic_migrations/versions/4dbe243cd84d_nsxv.py
gampel/neutron
51a6260266dc59c066072ca890ad9c40b1aad6cf
[ "Apache-2.0" ]
null
null
null
neutron/db/migration/alembic_migrations/versions/4dbe243cd84d_nsxv.py
gampel/neutron
51a6260266dc59c066072ca890ad9c40b1aad6cf
[ "Apache-2.0" ]
null
null
null
# Copyright 2015 OpenStack Foundation # # 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 ...
47.777108
79
0.655403
# Copyright 2015 OpenStack Foundation # # 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 ...
6,359
0
46
96d3efe51661176d3dd9d946b37fd31750778e9c
6,954
py
Python
ismo/ensemble/run_all_configurations.py
kjetil-lye/iterative_surrogate_optimization
f5de412daab1180612837f4c950203ad87d62f7e
[ "MIT" ]
6
2020-10-20T14:03:50.000Z
2021-11-02T15:08:55.000Z
ismo/ensemble/run_all_configurations.py
kjetil-lye/iterative_surrogate_optimization
f5de412daab1180612837f4c950203ad87d62f7e
[ "MIT" ]
3
2020-11-13T19:04:10.000Z
2022-02-10T02:12:18.000Z
ismo/ensemble/run_all_configurations.py
kjetil-lye/iterative_surrogate_optimization
f5de412daab1180612837f4c950203ad87d62f7e
[ "MIT" ]
3
2020-10-20T14:03:53.000Z
2021-03-19T23:11:34.000Z
import os import shutil import git import copy import sys import subprocess import glob import json from ismo.ensemble import ChangeFolder from ismo.submit import get_current_repository
43.192547
125
0.564423
import os import shutil import git import copy import sys import subprocess import glob import json from ismo.ensemble import ChangeFolder from ismo.submit import get_current_repository def all_successfully_completed(): lsf_files = glob.glob('lsf.o*') for lsf_filename in lsf_files: with open(lsf_file...
6,624
0
138
1d1ff3b7b618564e23192fb672b17c4db4eaae46
3,048
py
Python
byslib/numeric/modint.py
bayashi-cl/byslib-python
d7cbb1cb75904e85c353227def7c99a2bceea12c
[ "CC0-1.0" ]
null
null
null
byslib/numeric/modint.py
bayashi-cl/byslib-python
d7cbb1cb75904e85c353227def7c99a2bceea12c
[ "CC0-1.0" ]
null
null
null
byslib/numeric/modint.py
bayashi-cl/byslib-python
d7cbb1cb75904e85c353227def7c99a2bceea12c
[ "CC0-1.0" ]
null
null
null
# @title Modint from typing import Union class modint: """Modint Not so fast. """ __slots__ = ("v",) mod: int = 0 def using_modint(modulo: int): """using modint set modulo to modint class Parameters ---------- modulo Returns ------- modint class mod = modu...
22.746269
69
0.533793
# @title Modint from typing import Union class modint: """Modint Not so fast. """ __slots__ = ("v",) mod: int = 0 def __init__(self, v: int = 0) -> None: self.v = v % self.mod def __repr__(self): return str(self.v) def __index__(self): return self.v def...
2,052
47
513
e711fda17d492f313f05f767c5be9fe3233b6f52
170
py
Python
tests/test_version.py
LucaCappelletti94/random_dict
a7ec7081b0c28e160e7bdd4a47cfc9cae324618b
[ "MIT" ]
2
2020-06-10T03:36:14.000Z
2021-04-29T09:33:26.000Z
tests/test_version.py
LucaCappelletti94/random_dict
a7ec7081b0c28e160e7bdd4a47cfc9cae324618b
[ "MIT" ]
null
null
null
tests/test_version.py
LucaCappelletti94/random_dict
a7ec7081b0c28e160e7bdd4a47cfc9cae324618b
[ "MIT" ]
null
null
null
from validate_version_code import validate_version_code from random_dict.__version__ import __version__
34
55
0.870588
from validate_version_code import validate_version_code from random_dict.__version__ import __version__ def test_version(): assert validate_version_code(__version__)
44
0
23
330c6cd521c0e8dc1c51433c261e757448a9210d
2,187
py
Python
FilmTools/FilmCurve/FilmCurve.py
filmtools/filmcurve
6c2b5e3eae169c12596771b2c13b38ac05500fe4
[ "MIT" ]
null
null
null
FilmTools/FilmCurve/FilmCurve.py
filmtools/filmcurve
6c2b5e3eae169c12596771b2c13b38ac05500fe4
[ "MIT" ]
3
2018-01-02T08:32:42.000Z
2018-01-09T09:46:33.000Z
FilmTools/FilmCurve/FilmCurve.py
filmtools/filmcurve
6c2b5e3eae169c12596771b2c13b38ac05500fe4
[ "MIT" ]
null
null
null
import numpy as np import time # # OK, thats simple # # # Kind of goal seek: # Find x where interpolator(x) first meets (and firstly equals) # the given density y. # # Find the in-fact zone for the given density # and return the numeric difference to given zone # as *ne...
26.670732
85
0.570187
import numpy as np import time class FilmCurve: def __init__(self, zones, densities, x_precision = 12): # Store for later use self.zones = zones self.densities = densities self.x_precision = x_precision # # Determine the 5th grade polynomial coefficients #...
1,657
-5
128
928a14e1e4f5cac0d3d38f78e49c4d2dd80ed97b
2,655
py
Python
tests/filters/test_uuid_field_filtering.py
BBooijLiewes/django-binder
b5bf0aad14657fd57d575f9a0ef21468533f64a7
[ "MIT" ]
null
null
null
tests/filters/test_uuid_field_filtering.py
BBooijLiewes/django-binder
b5bf0aad14657fd57d575f9a0ef21468533f64a7
[ "MIT" ]
null
null
null
tests/filters/test_uuid_field_filtering.py
BBooijLiewes/django-binder
b5bf0aad14657fd57d575f9a0ef21468533f64a7
[ "MIT" ]
null
null
null
from django.test import TestCase, Client from binder.json import jsonloads from django.contrib.auth.models import User from ..testapp.models import Zoo, Caretaker, Gate
31.987952
109
0.717514
from django.test import TestCase, Client from binder.json import jsonloads from django.contrib.auth.models import User from ..testapp.models import Zoo, Caretaker, Gate class UUIDFieldFilteringTest(TestCase): def setUp(self): super().setUp() u = User(username='testuser', is_active=True, is_superuser=True) u.s...
2,370
18
94
8ef7506f7bb587683b0b006d526ff934d98c696d
264
py
Python
python challenges/level03.py
Vinay26k/python
9acfb8b6a2ba2dbe0621edf2260d29cc0e3b087d
[ "MIT" ]
3
2019-02-22T12:57:15.000Z
2021-08-07T16:27:47.000Z
python challenges/level03.py
Vinay26k/python
9acfb8b6a2ba2dbe0621edf2260d29cc0e3b087d
[ "MIT" ]
null
null
null
python challenges/level03.py
Vinay26k/python
9acfb8b6a2ba2dbe0621edf2260d29cc0e3b087d
[ "MIT" ]
2
2019-04-27T06:02:12.000Z
2020-12-16T14:50:41.000Z
'Hint: Page Source' #https://github.com/Vinay26k/pythonchallenge import requests url = r'http://www.pythonchallenge.com/pc/def/equality.html' r = requests.get(url).text import re print(''.join((re.findall("[^A-Z]+[A-Z]{3}([a-z])[A-Z]{3}[^A-Z]+",r))))
24
72
0.640152
'Hint: Page Source' #https://github.com/Vinay26k/pythonchallenge import requests url = r'http://www.pythonchallenge.com/pc/def/equality.html' r = requests.get(url).text import re print(''.join((re.findall("[^A-Z]+[A-Z]{3}([a-z])[A-Z]{3}[^A-Z]+",r))))
0
0
0
537ff890bff13836e5f5623a2d74fb5146db0955
58
py
Python
QiskitEducation/__init__.py
veenaiyuri/qiskit-education
0b58c8985b9377b4bc3404d205ea6235877a9778
[ "Apache-2.0" ]
6
2019-02-03T10:03:12.000Z
2020-11-05T18:13:08.000Z
QiskitEducation/__init__.py
quantumjim/qiskit-education
285074042a5d595436e4c84395d8205ba668f43c
[ "Apache-2.0" ]
null
null
null
QiskitEducation/__init__.py
quantumjim/qiskit-education
285074042a5d595436e4c84395d8205ba668f43c
[ "Apache-2.0" ]
2
2019-01-31T16:48:17.000Z
2019-01-31T17:00:59.000Z
from .QiskitEducation import * from .__version__ import *
19.333333
30
0.793103
from .QiskitEducation import * from .__version__ import *
0
0
0
f2c9cb1a9f3e4af8d25f8ecf6c9552ba003f742e
1,979
py
Python
setup.py
JMarkin/afbmq
8491abfdd17e2ab745b5150eafdaf68a0f3cd1d0
[ "MIT" ]
null
null
null
setup.py
JMarkin/afbmq
8491abfdd17e2ab745b5150eafdaf68a0f3cd1d0
[ "MIT" ]
null
null
null
setup.py
JMarkin/afbmq
8491abfdd17e2ab745b5150eafdaf68a0f3cd1d0
[ "MIT" ]
null
null
null
import os import re import setuptools from pkg_resources import parse_requirements from setuptools import find_packages base_path = os.path.dirname(__file__) with open(os.path.join(base_path, 'README.md')) as readme: README = readme.read() os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.par...
29.984848
94
0.640222
import os import re import setuptools from pkg_resources import parse_requirements from setuptools import find_packages base_path = os.path.dirname(__file__) with open(os.path.join(base_path, 'README.md')) as readme: README = readme.read() os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.par...
832
0
46
6efc3b28633381c436d432be8ec27980b701a080
820
py
Python
main.py
kodi1/hts.tivi.bridge
428da95c5d28b11a3292597205d78961064fe130
[ "MIT" ]
1
2018-12-01T05:59:38.000Z
2018-12-01T05:59:38.000Z
main.py
kodi1/hts.tivi.bridge
428da95c5d28b11a3292597205d78961064fe130
[ "MIT" ]
null
null
null
main.py
kodi1/hts.tivi.bridge
428da95c5d28b11a3292597205d78961064fe130
[ "MIT" ]
null
null
null
#!/usr/bin/python # -*- coding: utf-8 -*- import sys import os if __name__ == "__main__": mac = os.getenv('TIVIBG_MAC', False) if not mac: sys.exit('TIVIBG_MAC is not set\nTIVIBG_MAC=aa:bb:cc:dd:ee:ff %s' % (sys.argv[0])) import server server.log_cb = __log server.my_serv = server.serv(host=os.uname()[1...
21.025641
86
0.557317
#!/usr/bin/python # -*- coding: utf-8 -*- import sys import os def cmd_get_dbg(): return raw_input("q - quit\nr - restart\n") def main(): server.my_serv.start() try: while True: c = raw_input("q - quit\nr - restart\n") if c: print c if c == "q": ...
396
0
69
a04975a1d1e192e5e6724d0b2152e08ff387b8e7
2,438
py
Python
searchAssetsTest.py
cldcvr/CCSimpleMonitor
6591470b9a97930aab27f330fbc3dc62a950276a
[ "BSD-3-Clause" ]
null
null
null
searchAssetsTest.py
cldcvr/CCSimpleMonitor
6591470b9a97930aab27f330fbc3dc62a950276a
[ "BSD-3-Clause" ]
null
null
null
searchAssetsTest.py
cldcvr/CCSimpleMonitor
6591470b9a97930aab27f330fbc3dc62a950276a
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python import requests, json, random, string, time, sys try: response_time_threshold = int(sys.argv[1]) except IndexError: response_time_threshold = 500 #default value of response_time_threshold url = "http://tvpapi.as.tvinci.com/v3_4/gateways/jsonpostgw.aspx" querystring = {"m":"SearchAsset...
46.884615
624
0.633306
#!/usr/bin/env python import requests, json, random, string, time, sys try: response_time_threshold = int(sys.argv[1]) except IndexError: response_time_threshold = 500 #default value of response_time_threshold url = "http://tvpapi.as.tvinci.com/v3_4/gateways/jsonpostgw.aspx" querystring = {"m":"SearchAsset...
0
0
0
9b2b51cceff01f31b74be47de73dfe6a6723b5e0
1,733
py
Python
Python3/61.py
rakhi2001/ecom7
73790d44605fbd51e8f7e804b9808e364fcfc680
[ "MIT" ]
854
2018-11-09T08:06:16.000Z
2022-03-31T06:05:53.000Z
Python3/61.py
rakhi2001/ecom7
73790d44605fbd51e8f7e804b9808e364fcfc680
[ "MIT" ]
29
2019-06-02T05:02:25.000Z
2021-11-15T04:09:37.000Z
Python3/61.py
rakhi2001/ecom7
73790d44605fbd51e8f7e804b9808e364fcfc680
[ "MIT" ]
347
2018-12-23T01:57:37.000Z
2022-03-12T14:51:21.000Z
__________________________________________________________________________________________________ sample 28 ms submission # Definition for singly-linked list. # class ListNode: # def __init__(self, x): # self.val = x # self.next = None _______________________________________________________________...
28.883333
98
0.594345
__________________________________________________________________________________________________ sample 28 ms submission # Definition for singly-linked list. # class ListNode: # def __init__(self, x): # self.val = x # self.next = None class Solution: def rotateRight(self, head: ListNode, k: i...
1,031
-12
98
89003caf5fec2469679ebee46daf640b60326a87
3,167
py
Python
services/DiscordRpcService.py
phineas05/discord-rich-presence-plex
bdb39e44d4a1b4773ba502f0cfd12202017d9bea
[ "MIT" ]
9
2022-01-06T18:00:53.000Z
2022-03-27T07:53:48.000Z
services/DiscordRpcService.py
phineas05/discord-rich-presence-plex
bdb39e44d4a1b4773ba502f0cfd12202017d9bea
[ "MIT" ]
2
2022-01-09T19:41:52.000Z
2022-03-12T15:14:07.000Z
services/DiscordRpcService.py
phineas05/discord-rich-presence-plex
bdb39e44d4a1b4773ba502f0cfd12202017d9bea
[ "MIT" ]
2
2022-01-09T20:22:31.000Z
2022-03-05T13:37:03.000Z
# pyright: reportOptionalMemberAccess=none from store.constants import discordClientID, isUnix, processID from typing import Any, Optional from utils.logging import logger import asyncio import json import models.discord import os import struct import time
33.691489
221
0.719608
# pyright: reportOptionalMemberAccess=none from store.constants import discordClientID, isUnix, processID from typing import Any, Optional from utils.logging import logger import asyncio import json import models.discord import os import struct import time class DiscordRpcService: ipcPipe = ((os.environ.get("XDG_RU...
2,492
394
23
d35d8d0a446de0c957a1295bd285b4b186d8e4d6
1,560
py
Python
tests/unit/decisions/test_start_child_workflow_execution.py
EpicWink/floto
eb0d93d032b5e14e304e350cee28f27cfe735b73
[ "MIT" ]
43
2016-02-29T17:44:57.000Z
2021-12-28T00:41:47.000Z
tests/unit/decisions/test_start_child_workflow_execution.py
EpicWink/floto
eb0d93d032b5e14e304e350cee28f27cfe735b73
[ "MIT" ]
9
2016-02-29T23:38:36.000Z
2016-09-02T21:48:00.000Z
tests/unit/decisions/test_start_child_workflow_execution.py
EpicWink/floto
eb0d93d032b5e14e304e350cee28f27cfe735b73
[ "MIT" ]
10
2016-02-29T16:53:09.000Z
2018-12-12T00:06:08.000Z
import pytest import floto.decisions import floto.api import json
38.04878
98
0.667949
import pytest import floto.decisions import floto.api import json class TestStartChildWorkflowExecution(): def test_init_workflow_id(self): w = floto.decisions.StartChildWorkflowExecution(workflow_id='id') assert w.get_attributes()['workflowId'] == 'id' def test_init_workflow_type(se...
1,235
19
237
8c640c909303fd9482442a51b360dde5e01bfdd5
2,394
py
Python
ytGhostBuster.py
carneeki/ytGhostBuster
caa0022ea41a2eb8a84ad17666c97f5a4093c0dc
[ "MIT" ]
null
null
null
ytGhostBuster.py
carneeki/ytGhostBuster
caa0022ea41a2eb8a84ad17666c97f5a4093c0dc
[ "MIT" ]
null
null
null
ytGhostBuster.py
carneeki/ytGhostBuster
caa0022ea41a2eb8a84ad17666c97f5a4093c0dc
[ "MIT" ]
null
null
null
#!/usr/bin/python import urllib.request import json import os import itertools import re API_KEY="" # TODO: get from console.google.com VIDSBASE='{}/Videos/YouTubes/'.format(os.path.expanduser("~")) # TODO: set where all vids will be saved channels=[ "UC7SeFWZYFmsm1tqWxfuOTPQ", # dankula "UCwW_vaMPlq8J4weKDs...
32.794521
133
0.586466
#!/usr/bin/python import urllib.request import json import os import itertools import re API_KEY="" # TODO: get from console.google.com VIDSBASE='{}/Videos/YouTubes/'.format(os.path.expanduser("~")) # TODO: set where all vids will be saved channels=[ "UC7SeFWZYFmsm1tqWxfuOTPQ", # dankula "UCwW_vaMPlq8J4weKDs...
740
0
69
40d2c44e01333ae9a14e5570c9447ecdd991c725
3,192
py
Python
tests/models/test_array_transformer.py
mschulzie/xeofs
a446135962c1a5a3f3588a08c2e572cf8d19ac2f
[ "MIT" ]
null
null
null
tests/models/test_array_transformer.py
mschulzie/xeofs
a446135962c1a5a3f3588a08c2e572cf8d19ac2f
[ "MIT" ]
null
null
null
tests/models/test_array_transformer.py
mschulzie/xeofs
a446135962c1a5a3f3588a08c2e572cf8d19ac2f
[ "MIT" ]
null
null
null
import numpy as np import pytest import warnings from numpy.testing import assert_array_equal from xeofs.models._array_transformer import _ArrayTransformer warnings.filterwarnings("ignore", message="numpy.dtype size changed") warnings.filterwarnings("ignore", message="numpy.ufunc size changed") @pytest.mark.parametr...
29.018182
69
0.657895
import numpy as np import pytest import warnings from numpy.testing import assert_array_equal from xeofs.models._array_transformer import _ArrayTransformer warnings.filterwarnings("ignore", message="numpy.dtype size changed") warnings.filterwarnings("ignore", message="numpy.ufunc size changed") @pytest.mark.parametr...
2,195
0
156
03e4a6403ff733a6619d5698321edaf7d9d6b421
171
py
Python
src/deepend/layers/input.py
Letsmoe/deepend
3e31ec2737f5abd94fa0b1a68e9fa9a87e4c5e5c
[ "MIT" ]
1
2021-11-14T13:57:19.000Z
2021-11-14T13:57:19.000Z
src/deepend/layers/input.py
Letsmoe/deepend
3e31ec2737f5abd94fa0b1a68e9fa9a87e4c5e5c
[ "MIT" ]
null
null
null
src/deepend/layers/input.py
Letsmoe/deepend
3e31ec2737f5abd94fa0b1a68e9fa9a87e4c5e5c
[ "MIT" ]
null
null
null
from deepend.layers import *
21.375
37
0.71345
from deepend.layers import * class Input(Layer): def __init__(self, **kwargs): super().__init__(**kwargs) def forward(self, inputs, training): self.output = inputs
75
-2
70
a739fbedc96013ef7b3b5bed5b53ceca7aa8cf0b
375
py
Python
d2_total_checker.py
DK2K00/100DaysOfCode
68a9422b8b0b3aa233b1e11e310a6a58453e35c1
[ "MIT" ]
null
null
null
d2_total_checker.py
DK2K00/100DaysOfCode
68a9422b8b0b3aa233b1e11e310a6a58453e35c1
[ "MIT" ]
null
null
null
d2_total_checker.py
DK2K00/100DaysOfCode
68a9422b8b0b3aa233b1e11e310a6a58453e35c1
[ "MIT" ]
null
null
null
total_checker_all([0, 1, 2, 2, 3, 4], 4)
18.75
40
0.386667
def total_checker_all(arr, tot): n = 0 pairs = set() for i in arr: for j in arr: if(i + j == tot): if(i - j >= 0): tut = (i, j) pairs.add(tut) n += 1 print("Number pf pairs: ", n) print("Pairs are: ...
308
0
22
d3d379251f1cbea4fb9320f8d52695b92b82a5d8
1,252
py
Python
magnum/common/nova.py
ajmadsen/magnum
042d2ad14489afcecf0a3bc4038e2333e2acb3fb
[ "Apache-2.0" ]
319
2015-04-01T01:36:14.000Z
2022-01-18T13:21:46.000Z
magnum/common/nova.py
ajmadsen/magnum
042d2ad14489afcecf0a3bc4038e2333e2acb3fb
[ "Apache-2.0" ]
10
2015-06-05T20:12:46.000Z
2018-10-17T09:14:22.000Z
magnum/common/nova.py
ajmadsen/magnum
042d2ad14489afcecf0a3bc4038e2333e2acb3fb
[ "Apache-2.0" ]
254
2015-03-30T13:56:06.000Z
2022-03-26T03:40:22.000Z
# Copyright 2019 Catalyst Cloud 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...
35.771429
77
0.723642
# Copyright 2019 Catalyst Cloud 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...
415
0
23
6ad87f45efcf6c3e5326ac7bc79bca2462043553
14,158
py
Python
code/train.py
kensakurada/SceneChangeDet
0530e0162863fec0c5296188526f0d27e0109814
[ "MIT" ]
null
null
null
code/train.py
kensakurada/SceneChangeDet
0530e0162863fec0c5296188526f0d27e0109814
[ "MIT" ]
null
null
null
code/train.py
kensakurada/SceneChangeDet
0530e0162863fec0c5296188526f0d27e0109814
[ "MIT" ]
null
null
null
import numpy as np import os import torch import torch.nn as nn import torchvision import torch.utils.data as Data import torchvision.datasets as dates from torch.autograd import Variable from torch.nn import functional as F import utils.transforms as trans import utils.utils as util import layer.loss as ls import util...
50.028269
189
0.680887
import numpy as np import os import torch import torch.nn as nn import torchvision import torch.utils.data as Data import torchvision.datasets as dates from torch.autograd import Variable from torch.nn import functional as F import utils.transforms as trans import utils.utils as util import layer.loss as ls import util...
13,080
0
230
7c88a39a0373fdf4993468230d1a7f437b9fb756
5,868
py
Python
examples/workflow_steps/async_steps_from_apps_decorator.py
hirosassa/bolt-python
befc3a1463f3ac8dbb780d66decc304e2bdf3e7a
[ "MIT" ]
504
2020-08-07T05:02:57.000Z
2022-03-31T14:32:46.000Z
examples/workflow_steps/async_steps_from_apps_decorator.py
hirosassa/bolt-python
befc3a1463f3ac8dbb780d66decc304e2bdf3e7a
[ "MIT" ]
560
2020-08-07T01:16:06.000Z
2022-03-30T00:40:56.000Z
examples/workflow_steps/async_steps_from_apps_decorator.py
hirosassa/bolt-python
befc3a1463f3ac8dbb780d66decc304e2bdf3e7a
[ "MIT" ]
150
2020-08-07T09:41:14.000Z
2022-03-30T04:54:51.000Z
import asyncio import logging from slack_sdk.web.async_client import AsyncSlackResponse, AsyncWebClient from slack_bolt.async_app import AsyncApp, AsyncAck from slack_bolt.workflows.step.async_step import ( AsyncConfigure, AsyncUpdate, AsyncComplete, AsyncFail, AsyncWorkflowStep, ) logging.basicCo...
30.092308
165
0.488412
import asyncio import logging from slack_sdk.web.async_client import AsyncSlackResponse, AsyncWebClient from slack_bolt.async_app import AsyncApp, AsyncAck from slack_bolt.workflows.step.async_step import ( AsyncConfigure, AsyncUpdate, AsyncComplete, AsyncFail, AsyncWorkflowStep, ) logging.basicCo...
4,856
0
135
53f01f135edde500f7cc4d318c0c16eb690dafed
4,559
py
Python
src/core.py
t-ntran/vscode
79488e9971073b6a065744ae5eca7146f4e10257
[ "MIT" ]
null
null
null
src/core.py
t-ntran/vscode
79488e9971073b6a065744ae5eca7146f4e10257
[ "MIT" ]
null
null
null
src/core.py
t-ntran/vscode
79488e9971073b6a065744ae5eca7146f4e10257
[ "MIT" ]
1
2021-11-29T16:51:54.000Z
2021-11-29T16:51:54.000Z
import re import io import base64 # import numpy as np import tokenize # from PIL import Image # Code manipulation magic_var_name = "__run_py__" ''' Reference: https://stackoverflow.com/questions/1769332/script-to-remove-python-comments-docstrings ''' #Getting test comment lines # Image Processing # Convert PIL....
27.969325
171
0.694012
import re import io import base64 # import numpy as np import tokenize # from PIL import Image # Code manipulation magic_var_name = "__run_py__" ''' Reference: https://stackoverflow.com/questions/1769332/script-to-remove-python-comments-docstrings ''' def remove_comments_and_docstrings(source): io_obj = io.StringIO...
3,886
0
271
5cd06a6e171653ae9a38c5507965ef87661c0d81
1,570
py
Python
tests/DummyEngine.py
TonyFlury/pyorm
6d811fa32d3ba4c4a013fbb8f627277fa9d20b64
[ "MIT" ]
null
null
null
tests/DummyEngine.py
TonyFlury/pyorm
6d811fa32d3ba4c4a013fbb8f627277fa9d20b64
[ "MIT" ]
null
null
null
tests/DummyEngine.py
TonyFlury/pyorm
6d811fa32d3ba4c4a013fbb8f627277fa9d20b64
[ "MIT" ]
null
null
null
#!/usr/bin/env python # coding=utf-8 """ # pyORM : Implementation of DummyEngine Summary : <summary of module/class being implemented> Use Case : As a <actor> I want <outcome> So that <justification> Testable Statements : Can I <Boolean statement> .... """ from unittest.mock import MagicMock from p...
24.920635
85
0.680892
#!/usr/bin/env python # coding=utf-8 """ # pyORM : Implementation of DummyEngine Summary : <summary of module/class being implemented> Use Case : As a <actor> I want <outcome> So that <justification> Testable Statements : Can I <Boolean statement> .... """ from unittest.mock import MagicMock from p...
519
0
213
f8f23887f0d0074ba36e4792c44de2f2b901d252
3,171
py
Python
core/wagtail_hooks.py
methods/phe-cv19-site
fd5f877b8a0725a9893fa3c24a54e9495e749744
[ "MIT" ]
1
2020-09-21T16:35:16.000Z
2020-09-21T16:35:16.000Z
core/wagtail_hooks.py
methods/phe-cv19-site
fd5f877b8a0725a9893fa3c24a54e9495e749744
[ "MIT" ]
14
2020-03-25T10:29:26.000Z
2022-01-13T03:45:38.000Z
core/wagtail_hooks.py
methods/phe-cv19-site
fd5f877b8a0725a9893fa3c24a54e9495e749744
[ "MIT" ]
null
null
null
from axes.models import AccessAttempt from wagtail.contrib.modeladmin.options import (ModelAdmin, modeladmin_register) from wagtail.core import hooks from wagtail.admin import widgets as wagtailadmin_widgets from .models.nav import Menu, Footer from contentPages.models import HomePage, CreateNewResourceType from .mod...
31.39604
103
0.737307
from axes.models import AccessAttempt from wagtail.contrib.modeladmin.options import (ModelAdmin, modeladmin_register) from wagtail.core import hooks from wagtail.admin import widgets as wagtailadmin_widgets from .models.nav import Menu, Footer from contentPages.models import HomePage, CreateNewResourceType from .mod...
445
1,609
181
1201c64cfbfc13d30456c47727cabb0fec523874
4,411
py
Python
tools/lint/usort_linter.py
samiwilf/torchrec
50ff0973d5d01ec80fe36ba5f1d524c92c799836
[ "BSD-3-Clause" ]
1
2022-03-07T09:06:11.000Z
2022-03-07T09:06:11.000Z
tools/lint/usort_linter.py
samiwilf/torchrec
50ff0973d5d01ec80fe36ba5f1d524c92c799836
[ "BSD-3-Clause" ]
null
null
null
tools/lint/usort_linter.py
samiwilf/torchrec
50ff0973d5d01ec80fe36ba5f1d524c92c799836
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python3 # Copyright (c) Meta Platforms, Inc. and affiliates. # All rights reserved. # # This source code is licensed under the BSD-style license found in the # LICENSE file in the root directory of this source tree. import argparse import concurrent.futures import json import os import subprocess from t...
30.631944
79
0.52029
#!/usr/bin/env python3 # Copyright (c) Meta Platforms, Inc. and affiliates. # All rights reserved. # # This source code is licensed under the BSD-style license found in the # LICENSE file in the root directory of this source tree. import argparse import concurrent.futures import json import os import subprocess from t...
3,881
0
46
0e742138560ef22f1f33a7b6f136527baba2d4c2
4,030
py
Python
src/pred/LinearSVC_L2/RUNME_pred.py
WojciechMigda/TCO-CDC-OIICS
f6f8da2c09d0c77b10fddeadb1d9b30e6764c895
[ "MIT" ]
null
null
null
src/pred/LinearSVC_L2/RUNME_pred.py
WojciechMigda/TCO-CDC-OIICS
f6f8da2c09d0c77b10fddeadb1d9b30e6764c895
[ "MIT" ]
null
null
null
src/pred/LinearSVC_L2/RUNME_pred.py
WojciechMigda/TCO-CDC-OIICS
f6f8da2c09d0c77b10fddeadb1d9b30e6764c895
[ "MIT" ]
null
null
null
#!/usr/bin/python3 from ReadData import read_train, read_test from sklearn.base import BaseEstimator, TransformerMixin from sklearn.pipeline import FeatureUnion from sklearn.compose import ColumnTransformer from sklearn.feature_extraction.text import CountVectorizer from sklearn.preprocessing import FunctionTransform...
32.24
155
0.617866
#!/usr/bin/python3 from ReadData import read_train, read_test from sklearn.base import BaseEstimator, TransformerMixin from sklearn.pipeline import FeatureUnion from sklearn.compose import ColumnTransformer from sklearn.feature_extraction.text import CountVectorizer from sklearn.preprocessing import FunctionTransform...
1,937
0
102
6d109095e9afb8150a4c94949a54ec2aef660e7e
1,042
py
Python
ha-sip/src/command_client.py
arnonym/ha-plugins
cd1badbcee0122e6e9fe3e53df9efe57a033fa8c
[ "Apache-2.0" ]
15
2021-09-02T04:35:16.000Z
2022-02-23T13:35:50.000Z
ha-sip/src/command_client.py
arnonym/ha-plugins
cd1badbcee0122e6e9fe3e53df9efe57a033fa8c
[ "Apache-2.0" ]
3
2021-09-02T14:38:49.000Z
2021-12-03T18:56:19.000Z
ha-sip/src/command_client.py
arnonym/ha-plugins
cd1badbcee0122e6e9fe3e53df9efe57a033fa8c
[ "Apache-2.0" ]
3
2022-03-02T16:26:20.000Z
2022-03-25T23:09:51.000Z
import json import os import fcntl import sys
28.944444
76
0.566219
import json import os import fcntl import sys class CommandClient(object): def __init__(self): self.buffer = "" self.stdin_fd = fcntl.fcntl(sys.stdin, fcntl.F_GETFL) fcntl.fcntl(sys.stdin, fcntl.F_SETFL, self.stdin_fd | os.O_NONBLOCK) def get_command_list(self) -> [str]: try: ...
867
105
23
722913a99c98b289366edfe8f69fda2d1b33fc18
1,186
py
Python
Algorithms/Sorting/MergeSort.py
Yarintop/Data-Structures-And-Algorithms-In-Python
55db9e7f39211c42988171d51ef2659041df1aa1
[ "MIT" ]
null
null
null
Algorithms/Sorting/MergeSort.py
Yarintop/Data-Structures-And-Algorithms-In-Python
55db9e7f39211c42988171d51ef2659041df1aa1
[ "MIT" ]
null
null
null
Algorithms/Sorting/MergeSort.py
Yarintop/Data-Structures-And-Algorithms-In-Python
55db9e7f39211c42988171d51ef2659041df1aa1
[ "MIT" ]
null
null
null
import random if __name__ == "__main__": arr = [] for i in range(10): arr.append(random.randint(-20, 20)) print(arr) MergeSort.mergeSort(arr) print(arr)
21.962963
72
0.369309
import random class MergeSort: @staticmethod def mergeSort(arr): """Sort an array using the Merge Sort algorithm. Args: arr ((Comparable) objects array): The array we wish to sort. Time Complexity: Worst-Case: T(n) = 2T(n/2) + θ(n) || θ(nLog(n)) ...
0
954
23
1a6a4976a069bdb461e9c492db9b0df3067479e6
1,906
py
Python
downloadutil/checksum_util.py
yugabyte/downloadutil
231c472b60e78ef3033b9e90d5e7b4231f64e228
[ "Apache-2.0" ]
2
2021-04-06T00:49:03.000Z
2021-04-06T17:44:04.000Z
downloadutil/checksum_util.py
mbautin/downloadutil
19995e08c03ac267ba0e6f9b4724a12df247f79a
[ "Apache-2.0" ]
null
null
null
downloadutil/checksum_util.py
mbautin/downloadutil
19995e08c03ac267ba0e6f9b4724a12df247f79a
[ "Apache-2.0" ]
1
2021-04-19T20:16:42.000Z
2021-04-19T20:16:42.000Z
import os from downloadutil.util import BUFFER_SIZE_BYTES from typing import Any import re import hashlib SHA256_CHECKSUM_RE = re.compile(r'^[0-9a-f]{64}$') SHA256_CHECKSUM_FILE_SUFFIX = '.sha256' def validate_sha256sum(checksum_str: str) -> None: """ Validtes the given SHA256 checksum. Raises an exception...
31.766667
96
0.721406
import os from downloadutil.util import BUFFER_SIZE_BYTES from typing import Any import re import hashlib SHA256_CHECKSUM_RE = re.compile(r'^[0-9a-f]{64}$') SHA256_CHECKSUM_FILE_SUFFIX = '.sha256' def validate_sha256sum(checksum_str: str) -> None: """ Validtes the given SHA256 checksum. Raises an exception...
876
0
115
d8d4205d758aefb9175a8fe50596bd93757be97c
2,858
py
Python
d18.py
sclarke/adventofcode2017
9994d613f26879c6e6dccc7962e3191407214fa3
[ "BSD-3-Clause" ]
2
2017-12-02T18:52:33.000Z
2017-12-08T09:49:41.000Z
d18.py
sclarke/adventofcode2017
9994d613f26879c6e6dccc7962e3191407214fa3
[ "BSD-3-Clause" ]
null
null
null
d18.py
sclarke/adventofcode2017
9994d613f26879c6e6dccc7962e3191407214fa3
[ "BSD-3-Clause" ]
null
null
null
from collections import defaultdict from queue import Queue, Empty from threading import Thread test_input = [line.split() for line in """ set a 1 add a 2 mul a a mod a 5 snd a set a 0 rcv a jgz a -1 set a 1 jgz a -2 """.strip().splitlines()] test_input2 = [line.split() for line in """ snd 1 snd 2 snd p rcv a rcv b r...
21.984615
88
0.59972
from collections import defaultdict from queue import Queue, Empty from threading import Thread test_input = [line.split() for line in """ set a 1 add a 2 mul a a mod a 5 snd a set a 0 rcv a jgz a -1 set a 1 jgz a -2 """.strip().splitlines()] test_input2 = [line.split() for line in """ snd 1 snd 2 snd p rcv a rcv b r...
2,208
0
46
0aba810decb5a5f50b912d603dfe077ffa97d0df
5,888
py
Python
scripts/core/io.py
whackashoe/entwinement
4acff2147b86e08e267fc50c327917a338c7bf36
[ "Unlicense" ]
1
2020-03-10T10:52:13.000Z
2020-03-10T10:52:13.000Z
scripts/core/io.py
whackashoe/entwinement
4acff2147b86e08e267fc50c327917a338c7bf36
[ "Unlicense" ]
null
null
null
scripts/core/io.py
whackashoe/entwinement
4acff2147b86e08e267fc50c327917a338c7bf36
[ "Unlicense" ]
null
null
null
#TODO #def addPhysObjBox(id, x, y, w, h, d, r, f): pass #def addCirc(id, x, y, r, d, r, f): pass #def addTri(id, x1, y1, x2, y2, x3, y3): pass #def addDJoint(id, b1_id, b2_id, x1, y1, x2, y2, dist, freq): pass # DEATH/REMOVAL # TODO # def rm_Object(id): pass # def rm_Joint(id): pass # world shit """ all of the ...
26.053097
289
0.574049
def createPhysicalCircle(id, x, y, radius, d, r, f): global com com += 'a fo '+str(id)+' '+str(x)+' '+str(y)+' '+str(radius)+' '+str(d)+' '+str(r)+' '+str(f)+';' def createPhysicalRect(id, x, y, w, h, d, r, f): global com com += 'a fo '+str(id)+' '+str(x)+' '+str(y)+' '+str(w)+' '+str(h)+' '+str(d)+' '+str(r)+' '...
3,945
0
1,140
f496cfe7ddd043e31b8309491379e83806b4dc94
5,523
py
Python
utils/mqtt/mqtt-test-node.py
fjmolinas/pyaiot
7b8ae503c13289380fd42584e33d6585b1790c75
[ "BSD-3-Clause" ]
33
2017-05-02T13:54:29.000Z
2022-01-31T13:52:59.000Z
utils/mqtt/mqtt-test-node.py
fjmolinas/pyaiot
7b8ae503c13289380fd42584e33d6585b1790c75
[ "BSD-3-Clause" ]
20
2017-04-28T07:45:32.000Z
2021-06-14T06:55:07.000Z
utils/mqtt/mqtt-test-node.py
fjmolinas/pyaiot
7b8ae503c13289380fd42584e33d6585b1790c75
[ "BSD-3-Clause" ]
12
2017-04-24T14:21:23.000Z
2021-11-25T13:47:46.000Z
import json import logging import asyncio import random import socket from hbmqtt.client import MQTTClient, ClientException from hbmqtt.mqtt.constants import QOS_1 logging.basicConfig(format='%(asctime)s - %(name)14s - ' '%(levelname)5s - %(message)s') logger = logging.getLogger("mqtt_test_...
39.45
78
0.543907
import json import logging import asyncio import random import socket from hbmqtt.client import MQTTClient, ClientException from hbmqtt.mqtt.constants import QOS_1 logging.basicConfig(format='%(asctime)s - %(name)14s - ' '%(levelname)5s - %(message)s') logger = logging.getLogger("mqtt_test_...
1,167
0
115
5ce67e748396b114b331d39df035b0a4adf76d7b
4,171
py
Python
sportsdataverse/mbb/mbb_loaders.py
saiemgilani/sportsdataverse-py
77ae3accbb071b5308335b931e4e55a65e1500cd
[ "MIT" ]
12
2021-10-15T01:24:18.000Z
2022-03-15T17:00:22.000Z
sportsdataverse/mbb/mbb_loaders.py
saiemgilani/sportsdataverse-py
77ae3accbb071b5308335b931e4e55a65e1500cd
[ "MIT" ]
19
2021-11-02T05:53:41.000Z
2022-03-16T14:16:51.000Z
sportsdataverse/mbb/mbb_loaders.py
saiemgilani/sportsdataverse-py
77ae3accbb071b5308335b931e4e55a65e1500cd
[ "MIT" ]
1
2021-12-21T14:49:25.000Z
2021-12-21T14:49:25.000Z
import pyarrow.parquet as pq import pandas as pd import json from typing import List, Callable, Iterator, Union, Optional from sportsdataverse.config import MBB_BASE_URL, MBB_TEAM_BOX_URL, MBB_PLAYER_BOX_URL, MBB_TEAM_SCHEDULE_URL from sportsdataverse.errors import SeasonNotFoundError from sportsdataverse.dl_utils impo...
33.910569
108
0.680412
import pyarrow.parquet as pq import pandas as pd import json from typing import List, Callable, Iterator, Union, Optional from sportsdataverse.config import MBB_BASE_URL, MBB_TEAM_BOX_URL, MBB_PLAYER_BOX_URL, MBB_TEAM_SCHEDULE_URL from sportsdataverse.errors import SeasonNotFoundError from sportsdataverse.dl_utils impo...
0
0
0
f3d34ad446846e57b5983143666ed1d5baa5928b
1,710
py
Python
provided_client.py
DTMcNamara/CS4980-AdvancedOperatingSystems-HW3
53c22df0ef821de7700d6223ff02738aa3e836f1
[ "MIT" ]
null
null
null
provided_client.py
DTMcNamara/CS4980-AdvancedOperatingSystems-HW3
53c22df0ef821de7700d6223ff02738aa3e836f1
[ "MIT" ]
null
null
null
provided_client.py
DTMcNamara/CS4980-AdvancedOperatingSystems-HW3
53c22df0ef821de7700d6223ff02738aa3e836f1
[ "MIT" ]
null
null
null
import json import socket # UDP IP address and port UDP_IP = "127.0.0.1" UDP_PORT = 5005 # Press the green button in the gutter to run the script. if __name__ == '__main__': # Import functions from mycode import abc, double_int, say_hello, rpc_test, doggo_test, favorite_number, half_float, bye_professor ...
30.535714
115
0.7
import json import socket # UDP IP address and port UDP_IP = "127.0.0.1" UDP_PORT = 5005 class RPCClient: def __init__(self, func): # wrap the function self.sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM) self.tempFunc = func def __call__(self, *args, **kwargs): # For...
578
-5
76
257d86c3b69895742293526c0de123075b71b899
4,629
py
Python
tests/test_types/test_float.py
RobertCraigie/prisma-client-py
0539d9b1ed3581acbaf151124d5cd35cfd38e828
[ "Apache-2.0" ]
518
2021-08-28T01:57:06.000Z
2022-03-30T15:44:45.000Z
tests/test_types/test_float.py
iiian/prisma-client-py
b7360822e6855193fbdb5a6deb8309c081808051
[ "Apache-2.0" ]
288
2021-08-28T04:15:27.000Z
2022-03-29T16:54:51.000Z
tests/test_types/test_float.py
iiian/prisma-client-py
b7360822e6855193fbdb5a6deb8309c081808051
[ "Apache-2.0" ]
19
2021-11-16T15:16:19.000Z
2022-03-14T09:59:34.000Z
import pytest from prisma import Client from prisma.errors import DataError @pytest.mark.asyncio async def test_filtering(client: Client) -> None: """Finding records by a a float value""" async with client.batch_() as batcher: for i in range(10): batcher.types.create({'float_': i + 1}) ...
22.254808
71
0.453878
import pytest from prisma import Client from prisma.errors import DataError @pytest.mark.asyncio async def test_filtering(client: Client) -> None: """Finding records by a a float value""" async with client.batch_() as batcher: for i in range(10): batcher.types.create({'float_': i + 1}) ...
0
0
0
7832e1262d582130c97ac85b4ffb13a5e6c3f6ac
1,084
py
Python
pyapi/addins-api/localapi/logger.py
dockerian/py-api
777db7d5dacf3ecf29a991f50d2ac78bb5bef66a
[ "Apache-2.0" ]
null
null
null
pyapi/addins-api/localapi/logger.py
dockerian/py-api
777db7d5dacf3ecf29a991f50d2ac78bb5bef66a
[ "Apache-2.0" ]
6
2019-12-26T16:51:55.000Z
2022-03-21T22:16:45.000Z
pyapi/addins-api/localapi/logger.py
dockerian/pyapi
777db7d5dacf3ecf29a991f50d2ac78bb5bef66a
[ "Apache-2.0" ]
null
null
null
import os import logging import logging.config import logger_formatter import yaml
29.297297
77
0.699262
import os import logging import logging.config import logger_formatter import yaml def getLogger(name): # Get the path to the logging config yaml path = "{0}{1}".format(os.getcwd(), '/logging.yaml') # Set a basic level of logging logger = logging.basicConfig(level=logging.DEBUG) # Load up the l...
919
8
72
a0b9e0506ca742b0ca28a4187fe2309ec0620777
342
py
Python
hw4/tcontrol/scripts/detekcijaPozicije.py
Daria2002/ROS_hw
fd9fccb5ec2e38a4c8887d26e9fa10d54c6ea7ca
[ "MIT" ]
null
null
null
hw4/tcontrol/scripts/detekcijaPozicije.py
Daria2002/ROS_hw
fd9fccb5ec2e38a4c8887d26e9fa10d54c6ea7ca
[ "MIT" ]
null
null
null
hw4/tcontrol/scripts/detekcijaPozicije.py
Daria2002/ROS_hw
fd9fccb5ec2e38a4c8887d26e9fa10d54c6ea7ca
[ "MIT" ]
null
null
null
#!/usr/bin/env python import rospy from turtlesim.msg import Pose if __name__ == '__main__': rospy.init_node('subscriber', anonymous=True) rospy.Subscriber("pose", Pose, detekcija) rospy.spin()
24.428571
64
0.678363
#!/usr/bin/env python import rospy from turtlesim.msg import Pose def detekcija(data): if(data.x<5.5 and data.x>4.5 and data.y<5.5 and data.y>4.5): rospy.loginfo("Turtle in the middle!") if __name__ == '__main__': rospy.init_node('subscriber', anonymous=True) rospy.Subscriber("pose", Pose, detekci...
111
0
23
5719acd97e21d17564c512cad64a18d6762575d2
1,214
py
Python
test/test_config.py
sarnold/nanoservice
fdaf6cdcc93fbd4259a005f832a5666356307a12
[ "MIT" ]
28
2015-03-26T10:25:31.000Z
2022-01-31T21:59:11.000Z
test/test_config.py
sarnold/nanoservice
fdaf6cdcc93fbd4259a005f832a5666356307a12
[ "MIT" ]
3
2015-09-14T04:10:04.000Z
2020-01-29T03:52:05.000Z
test/test_config.py
freepn/nanoservice
fdaf6cdcc93fbd4259a005f832a5666356307a12
[ "MIT" ]
9
2015-09-10T08:11:37.000Z
2020-11-08T10:41:51.000Z
import json import unittest from nanoservice import * from nanoservice import config if __name__ == '__main__': unittest.main()
27.590909
59
0.593081
import json import unittest from nanoservice import * from nanoservice import config class TestConfig(unittest.TestCase): def setUp(self): self.addr = 'ipc:///whatever' self.expected = { 'db.name': 'test', 'rq.requester': 'ipc:///whatever', 'rs.responder': 'ip...
905
15
158
113c71ad709293c4626d76c2d255727b03c76461
1,506
py
Python
getPlugins.py
quinnjr/PluMA
a62c83fac9989cea5bcab607ef209ce3b8ba15f0
[ "MIT" ]
9
2018-11-20T07:48:18.000Z
2022-01-23T08:57:33.000Z
getPlugins.py
quinnjr/PluMA
a62c83fac9989cea5bcab607ef209ce3b8ba15f0
[ "MIT" ]
null
null
null
getPlugins.py
quinnjr/PluMA
a62c83fac9989cea5bcab607ef209ce3b8ba15f0
[ "MIT" ]
7
2018-06-06T14:57:49.000Z
2022-01-23T09:04:03.000Z
# Note this requires an internet connection import os import urllib.request import sys thepipelines = set() theplugins = set() thepipelines.add(sys.argv[1]+"/config.txt") while (len(thepipelines) != 0): configfile = open(thepipelines.pop(), 'r') for line in configfile: contents = line.strip().split(" ") ...
30.734694
85
0.629482
# Note this requires an internet connection import os import urllib.request import sys thepipelines = set() theplugins = set() thepipelines.add(sys.argv[1]+"/config.txt") while (len(thepipelines) != 0): configfile = open(thepipelines.pop(), 'r') for line in configfile: contents = line.strip().split(" ") ...
0
0
0
ea0fd79752795e3b3aceba1dff0fa03780d38c00
34
py
Python
authz/controller/__init__.py
mehrdadnasiri/Flask
6ffebc43e79c0122188c8ace69c67b3bb07112e5
[ "Apache-2.0" ]
1
2022-03-02T06:11:28.000Z
2022-03-02T06:11:28.000Z
authz/controller/__init__.py
mehrdadnasiri/Flask
6ffebc43e79c0122188c8ace69c67b3bb07112e5
[ "Apache-2.0" ]
1
2022-01-21T16:47:50.000Z
2022-01-21T17:56:28.000Z
authz/controller/__init__.py
vashian/techland-microservice
2d364afc4da83ea04f50c4d1e7ce6dcbde7e92cc
[ "MIT" ]
null
null
null
from authz.controller import apiv1
34
34
0.882353
from authz.controller import apiv1
0
0
0
de25ff3e019358cbd8b18e033a39fd90ee1ff202
846
py
Python
intro_to_shelves.py
carlosmertens/Python-Masterclass
2bc514baf2173ab4c55baa2531f13841495371a6
[ "MIT" ]
null
null
null
intro_to_shelves.py
carlosmertens/Python-Masterclass
2bc514baf2173ab4c55baa2531f13841495371a6
[ "MIT" ]
null
null
null
intro_to_shelves.py
carlosmertens/Python-Masterclass
2bc514baf2173ab4c55baa2531f13841495371a6
[ "MIT" ]
null
null
null
import shelve blt = ["bacon", "lettuce", "tomato", "bread"] beans_on_toast = ["beans", "bread"] scrambled_eggs = ["eggs", "butter", "milk"] soup = ["tin of soup"] pasta = ["pasta", "cheese"] with shelve.open("recipes") as recipes: recipes["blt"] = blt recipes["beans on toast"] = beans_on_toast recipes["sc...
31.333333
68
0.529551
import shelve blt = ["bacon", "lettuce", "tomato", "bread"] beans_on_toast = ["beans", "bread"] scrambled_eggs = ["eggs", "butter", "milk"] soup = ["tin of soup"] pasta = ["pasta", "cheese"] with shelve.open("recipes") as recipes: recipes["blt"] = blt recipes["beans on toast"] = beans_on_toast recipes["sc...
0
0
0
8cfe71d1eadc1209619ad24ce11cd97cc4082983
912
py
Python
test.py
rodneyspark/pass_locker
385fe8359219a771ff26a7e47a49839ad22ee54f
[ "MIT" ]
null
null
null
test.py
rodneyspark/pass_locker
385fe8359219a771ff26a7e47a49839ad22ee54f
[ "MIT" ]
null
null
null
test.py
rodneyspark/pass_locker
385fe8359219a771ff26a7e47a49839ad22ee54f
[ "MIT" ]
null
null
null
import unittest from user import User from info import Info if __name__ == '__main__': unittest.main()
30.4
68
0.64693
import unittest from user import User from info import Info class TestUser(unittest.TestCase): def setUp(self): self.new_user = User('john','mwangi','johnmwagi@gmail.com') def test1(self): self.assertEqual(self.new_user.fname,'john') self.assertEqual(self.new_user.lname, 'mwang...
568
13
216
71f450d4476107bea84cf2ae5b5d4ae206a76948
1,592
py
Python
tests/pytests/test_wideschema.py
rueian/RediSearch
d3a9df4c5d0e98ef0f3d3be9f181b0b64bec5c20
[ "MIT", "Ruby", "Apache-2.0", "BSD-3-Clause" ]
null
null
null
tests/pytests/test_wideschema.py
rueian/RediSearch
d3a9df4c5d0e98ef0f3d3be9f181b0b64bec5c20
[ "MIT", "Ruby", "Apache-2.0", "BSD-3-Clause" ]
null
null
null
tests/pytests/test_wideschema.py
rueian/RediSearch
d3a9df4c5d0e98ef0f3d3be9f181b0b64bec5c20
[ "MIT", "Ruby", "Apache-2.0", "BSD-3-Clause" ]
null
null
null
import platform from includes import * from common import waitForIndex, arch_int_bits
35.377778
95
0.535176
import platform from includes import * from common import waitForIndex, arch_int_bits def testWideSchema(env): r = env schema = [] FIELDS = arch_int_bits() for i in range(FIELDS): schema.extend(('field_%d' % i, 'TEXT')) env.assertOk(env.cmd('ft.create', 'idx', 'ON', 'HASH', 'schema', *sche...
1,482
0
23
82c6296aad6d623ae03de902815437af383c7d5c
3,126
py
Python
ez_repo/main.py
jpigree/ez-repo
ad1f829151b60a9b035802f7e93d2147e35d1761
[ "MIT" ]
2
2018-01-10T18:18:25.000Z
2018-11-21T09:04:48.000Z
ez_repo/main.py
jpigree/ez-repo
ad1f829151b60a9b035802f7e93d2147e35d1761
[ "MIT" ]
null
null
null
ez_repo/main.py
jpigree/ez-repo
ad1f829151b60a9b035802f7e93d2147e35d1761
[ "MIT" ]
2
2017-12-20T15:20:41.000Z
2019-08-13T17:07:03.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- """ Main entry. Setup the command line interface then run the main function.""" from logging import INFO, DEBUG from sys import argv import argparse import botocore.exceptions from . import __version__ import ez_repo.command as command import ez_repo.error as error imp...
25.622951
79
0.632438
#!/usr/bin/env python # -*- coding: utf-8 -*- """ Main entry. Setup the command line interface then run the main function.""" from logging import INFO, DEBUG from sys import argv import argparse import botocore.exceptions from . import __version__ import ez_repo.command as command import ez_repo.error as error imp...
0
0
0
4581097a8901abe555695274c6dfdcca8df1d4ca
2,665
py
Python
DataStructure/U5/U5_43.py
qiaw99/Data-Structure
3b1cdce96d4f35329ccfec29c03de57378ef0552
[ "MIT" ]
1
2019-10-29T08:21:41.000Z
2019-10-29T08:21:41.000Z
DataStructure/U5/U5_43.py
qiaw99/Data-Structure
3b1cdce96d4f35329ccfec29c03de57378ef0552
[ "MIT" ]
null
null
null
DataStructure/U5/U5_43.py
qiaw99/Data-Structure
3b1cdce96d4f35329ccfec29c03de57378ef0552
[ "MIT" ]
null
null
null
__author__ = "Qianli Wang and Nazar Sopiha" __copyright__ = "Copyright (c) 2019 qiaw99" # https://github.com/qiaw99/WS2019-20/blob/master/LICENSE from matplotlib import pyplot as plt if __name__ == '__main__': main()
25.380952
118
0.547467
__author__ = "Qianli Wang and Nazar Sopiha" __copyright__ = "Copyright (c) 2019 qiaw99" # https://github.com/qiaw99/WS2019-20/blob/master/LICENSE from matplotlib import pyplot as plt def berechnen(g): # g = (a, value, b) # f(x) = g(x) * x + c ls = [] # Erste Konstant temp_k = g[1] # Der erste Punkt ist: (...
2,357
0
94
45bc48f698eb6ce1171d8583f196fc7e1716eea2
4,523
py
Python
tests/unit/test_secrets_writer.py
Kami/python-dcsm
5afcbad355c31836343e7e9445f72271b9458446
[ "Apache-2.0" ]
null
null
null
tests/unit/test_secrets_writer.py
Kami/python-dcsm
5afcbad355c31836343e7e9445f72271b9458446
[ "Apache-2.0" ]
null
null
null
tests/unit/test_secrets_writer.py
Kami/python-dcsm
5afcbad355c31836343e7e9445f72271b9458446
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # Copyright 2020 Tomaz Muraus # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless requ...
38.991379
99
0.719213
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # Copyright 2020 Tomaz Muraus # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless requ...
3,046
26
103
b0a2a0b066f7cad6eaa28cd08629ac502da0c12d
10,507
py
Python
tests/test_iqn.py
carljohanhoel/EnsembleQuantileNetworks
7dfbed562f3e0c7552fa98a821db502ea565618c
[ "MIT" ]
9
2021-05-29T14:55:27.000Z
2022-03-08T11:19:44.000Z
tests/test_iqn.py
carljohanhoel/EnsembleQuantileNetworks
7dfbed562f3e0c7552fa98a821db502ea565618c
[ "MIT" ]
1
2021-09-27T08:59:43.000Z
2022-01-13T14:13:03.000Z
tests/test_iqn.py
carljohanhoel/EnsembleQuantileNetworks
7dfbed562f3e0c7552fa98a821db502ea565618c
[ "MIT" ]
1
2022-02-03T14:17:36.000Z
2022-02-03T14:17:36.000Z
import unittest import numpy as np from keras.optimizers import Adam from keras.utils import plot_model from rl.policy import EpsGreedyQPolicy, LinearAnnealedPolicy, GreedyQPolicy from rl.memory import SequentialMemory import sys sys.path.append('../src') from iqn import IQNAgent from network_architecture_distribution...
45.288793
116
0.587323
import unittest import numpy as np from keras.optimizers import Adam from keras.utils import plot_model from rl.policy import EpsGreedyQPolicy, LinearAnnealedPolicy, GreedyQPolicy from rl.memory import SequentialMemory import sys sys.path.append('../src') from iqn import IQNAgent from network_architecture_distribution...
9,724
11
292
b9dbe476120ad757392fc6e5b6384fc15aa0bac6
6,599
py
Python
tests/test_main.py
sgibson91/bump-jhub-image-action
4da67a8e2f9586da26021c1183a2f64bd24a5573
[ "MIT" ]
null
null
null
tests/test_main.py
sgibson91/bump-jhub-image-action
4da67a8e2f9586da26021c1183a2f64bd24a5573
[ "MIT" ]
4
2022-02-01T17:53:28.000Z
2022-03-30T22:41:15.000Z
tests/test_main.py
sgibson91/bump-jhub-image-action
4da67a8e2f9586da26021c1183a2f64bd24a5573
[ "MIT" ]
null
null
null
import base64 import unittest import pytest from tag_bot.main import UpdateImageTags, assert_images_info_input, split_str_to_list from tag_bot.yaml_parser import YamlParser yaml = YamlParser() if __name__ == "__main__": unittest.main()
30.981221
86
0.558721
import base64 import unittest import pytest from tag_bot.main import UpdateImageTags, assert_images_info_input, split_str_to_list from tag_bot.yaml_parser import YamlParser yaml = YamlParser() class TestUpdateImageTags(unittest.TestCase): def test_update_config_singleuser(self): update_images = UpdateI...
6,058
24
264
92c544b6062d9040c1bae598fb594a425b63e9b4
9,316
py
Python
python-scripts/generatePseudo.py
Siddhant-K-code/Code-Kindle
e5dc3bdcb206baf7e8a1c7e27fc952710c552250
[ "Apache-2.0" ]
6
2021-02-28T09:14:04.000Z
2021-03-25T12:36:49.000Z
python-scripts/generatePseudo.py
Siddhant-K-code/Code-Kindle
e5dc3bdcb206baf7e8a1c7e27fc952710c552250
[ "Apache-2.0" ]
23
2021-04-13T08:44:13.000Z
2021-04-18T18:12:40.000Z
python-scripts/generatePseudo.py
Siddhant-K-code/Code-Kindle
e5dc3bdcb206baf7e8a1c7e27fc952710c552250
[ "Apache-2.0" ]
8
2021-04-16T14:37:28.000Z
2022-03-03T01:02:30.000Z
TestFile = "hello.py" import logging from logging import debug, info, warning, basicConfig, INFO, DEBUG, WARNING basicConfig(level = WARNING) main(TestFile) print("") print("") print("----------------") print("Process complete") print("----------------")
38.655602
380
0.487226
TestFile = "hello.py" import logging from logging import debug, info, warning, basicConfig, INFO, DEBUG, WARNING basicConfig(level = WARNING) def getTextFile(filep): file = open(filep) listFile = [] while 1: line = file.readline() if not line: break listFile.append(line)...
8,759
0
299
f501b065741f8b6935586e8dfcc2180e5d2cfb8e
1,929
py
Python
sphinx_json_schema/directive.py
tkhyn/sphinx-json-schema
df5e10bad62cf9a13cc8f50a21183f8590bcd888
[ "MIT" ]
1
2020-02-07T08:23:25.000Z
2020-02-07T08:23:25.000Z
sphinx_json_schema/directive.py
tkhyn/sphinx-json-schema
df5e10bad62cf9a13cc8f50a21183f8590bcd888
[ "MIT" ]
1
2022-02-21T14:35:02.000Z
2022-02-21T14:35:02.000Z
sphinx_json_schema/directive.py
tkhyn/sphinx-json-schema
df5e10bad62cf9a13cc8f50a21183f8590bcd888
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- import os.path from docutils import nodes from docutils.parsers.rst import Directive from sphinx.directives.code import container_wrapper from .loader import JsonSchemaLoader
33.258621
98
0.590461
# -*- coding: utf-8 -*- import os.path from docutils import nodes from docutils.parsers.rst import Directive from sphinx.directives.code import container_wrapper from .loader import JsonSchemaLoader class JsonSchema(Directive): optional_arguments = 1 has_content = True def __init__(self, *args, **kwa...
1,591
111
23
8073238ca13ec013848a229a5f6378da1d42fad7
4,405
py
Python
code/experiments/experiments.py
juvian/Manga-Text-Segmentation
de8f148c78978d70ad0e0ae3242566da6d70f3a5
[ "MIT" ]
37
2020-09-10T03:15:51.000Z
2022-03-24T06:11:21.000Z
code/experiments/experiments.py
KUR-creative/Manga-Text-Segmentation
de8f148c78978d70ad0e0ae3242566da6d70f3a5
[ "MIT" ]
2
2020-10-17T16:13:19.000Z
2021-02-06T22:52:02.000Z
code/experiments/experiments.py
juvian/Manga-Text-Segmentation
de8f148c78978d70ad0e0ae3242566da6d70f3a5
[ "MIT" ]
6
2021-02-27T23:13:46.000Z
2022-03-13T06:07:46.000Z
import numpy as np import torch import random import os from pathlib import Path from sklearn.model_selection import KFold import sys sys.path.append('..') from dataset import get_segmentation, random_crop, SegItemListCustom from config import * trainFolders = [ 'ARMS', 'AisazuNihaIrarenai', 'Akkera...
30.804196
141
0.650851
import numpy as np import torch import random import os from pathlib import Path from sklearn.model_selection import KFold import sys sys.path.append('..') from dataset import get_segmentation, random_crop, SegItemListCustom from config import * def random_seed(seed_value, use_cuda = True): np.random.seed(seed...
2,366
0
157
6f0fc1e0b91dc2dc9f56afba63e9c156e278166f
8,858
py
Python
froide/publicbody/views.py
xenein/froide
59bd3eeded3c3ed00fbc858fe20bfea99c8dbefa
[ "MIT" ]
198
2016-12-03T22:42:55.000Z
2022-03-25T15:08:36.000Z
froide/publicbody/views.py
xenein/froide
59bd3eeded3c3ed00fbc858fe20bfea99c8dbefa
[ "MIT" ]
264
2016-11-30T18:53:17.000Z
2022-03-17T11:34:18.000Z
froide/publicbody/views.py
xenein/froide
59bd3eeded3c3ed00fbc858fe20bfea99c8dbefa
[ "MIT" ]
42
2016-12-22T04:08:27.000Z
2022-02-26T08:30:38.000Z
from django.shortcuts import render, redirect, get_object_or_404, Http404 from django.utils.translation import gettext_lazy as _ from django.contrib import messages from django.conf import settings from django.contrib.sitemaps import Sitemap from django.contrib.auth.mixins import LoginRequiredMixin from django.views.ge...
31.411348
99
0.650824
from django.shortcuts import render, redirect, get_object_or_404, Http404 from django.utils.translation import gettext_lazy as _ from django.contrib import messages from django.conf import settings from django.contrib.sitemaps import Sitemap from django.contrib.auth.mixins import LoginRequiredMixin from django.views.ge...
5,350
2,113
298
6cae922e3ba0b9cc34cb7080a3bf10d097a55b2f
4,732
py
Python
server/server.py
BlueKnek/Wheere2
d19374e720f4de36607ad421434be85f52f24052
[ "MIT" ]
null
null
null
server/server.py
BlueKnek/Wheere2
d19374e720f4de36607ad421434be85f52f24052
[ "MIT" ]
null
null
null
server/server.py
BlueKnek/Wheere2
d19374e720f4de36607ad421434be85f52f24052
[ "MIT" ]
null
null
null
from flask import Flask, jsonify, request, send_from_directory from tinydb import TinyDB, Query from werkzeug.utils import secure_filename import socketio import eventlet import os UPLOADED_IMAGES = 'uploaded_images' app = Flask(__name__) sio = socketio.Server() db = TinyDB('db.json') items = db.table('items') @...
23.778894
84
0.632925
from flask import Flask, jsonify, request, send_from_directory from tinydb import TinyDB, Query from werkzeug.utils import secure_filename import socketio import eventlet import os UPLOADED_IMAGES = 'uploaded_images' app = Flask(__name__) sio = socketio.Server() db = TinyDB('db.json') items = db.table('items') def ...
3,249
0
560
ef81c44825192700d24b6b8b4230b37a226d052d
206
py
Python
birdie_stress/birdie_stress/__init__.py
gr-/birdie
ddfaa8d9e067d533605052214b04e944e0659c26
[ "MIT" ]
1
2015-08-26T14:00:15.000Z
2015-08-26T14:00:15.000Z
birdie_stress/birdie_stress/__init__.py
gr-/birdie
ddfaa8d9e067d533605052214b04e944e0659c26
[ "MIT" ]
1
2015-11-27T16:34:54.000Z
2015-11-27T16:34:54.000Z
birdie_stress/birdie_stress/__init__.py
gr-/birdie
ddfaa8d9e067d533605052214b04e944e0659c26
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- """ This app provides a basic stress test suite for the birdie app with locust.io library. """ __version__ = "0.1" #from birdie-stress import xxx
18.727273
90
0.645631
#!/usr/bin/env python # -*- coding: utf-8 -*- """ This app provides a basic stress test suite for the birdie app with locust.io library. """ __version__ = "0.1" #from birdie-stress import xxx
0
0
0
e1f75c251400bbf6a5e60f208f49d31366299240
1,435
py
Python
src/zconfig_watchedfile/tests/test_handler.py
gocept/zconfig_watchedfile
f82c1b2e027ad245cb9be35044a0497d3b1a07f5
[ "ZPL-2.1" ]
null
null
null
src/zconfig_watchedfile/tests/test_handler.py
gocept/zconfig_watchedfile
f82c1b2e027ad245cb9be35044a0497d3b1a07f5
[ "ZPL-2.1" ]
null
null
null
src/zconfig_watchedfile/tests/test_handler.py
gocept/zconfig_watchedfile
f82c1b2e027ad245cb9be35044a0497d3b1a07f5
[ "ZPL-2.1" ]
null
null
null
from io import StringIO import ZConfig import logging import logging.handlers import pkg_resources import pytest @pytest.fixture(autouse=True) def logger(request): """Logger for tests.""" request.addfinalizer(reset_handler) def load_config(config): """Help to load config.""" schema = ZConfig.loadSch...
23.145161
78
0.689895
from io import StringIO import ZConfig import logging import logging.handlers import pkg_resources import pytest @pytest.fixture(autouse=True) def logger(request): """Logger for tests.""" def reset_handler(): logging.getLogger('foo').handlers[:] = [] request.addfinalizer(reset_handler) def load_...
49
0
26
1b10957d24b48c435f29370c20228448c73ec4b4
10,200
py
Python
make_test_data.py
jddixon/xlreg_py
c3e8461b5d046c7a3d351ab9f84f2581668560ad
[ "MIT" ]
null
null
null
make_test_data.py
jddixon/xlreg_py
c3e8461b5d046c7a3d351ab9f84f2581668560ad
[ "MIT" ]
null
null
null
make_test_data.py
jddixon/xlreg_py
c3e8461b5d046c7a3d351ab9f84f2581668560ad
[ "MIT" ]
null
null
null
#!/usr/bin/python # ~/dev/py/xlreg_py/makeTestData """ Make data for test scripts. """ import os import subprocess import sys import time from Crypto.Cipher import AES from xlutil import DecimalVersion as dv from xlReg import reg_cred import rnglib OPENSSL = '/usr/bin/openssl' SSH_KEYGEN = '/usr/bin/ssh-keygen' KEY_...
35.416667
76
0.574314
#!/usr/bin/python # ~/dev/py/xlreg_py/makeTestData """ Make data for test scripts. """ import os import subprocess import sys import time from Crypto.Cipher import AES from xlutil import DecimalVersion as dv from xlReg import reg_cred import rnglib OPENSSL = '/usr/bin/openssl' SSH_KEYGEN = '/usr/bin/ssh-keygen' KEY_...
2,266
0
69
c40d3e0ebeb841550fa0469185d5a7ab85d43874
7,454
py
Python
tests/test_football_badges.py
domdfcoding/football_badges
4d282b407ad8c0e9fbe50bf06f29226ab8edda46
[ "Apache-2.0" ]
null
null
null
tests/test_football_badges.py
domdfcoding/football_badges
4d282b407ad8c0e9fbe50bf06f29226ab8edda46
[ "Apache-2.0" ]
13
2020-12-23T08:26:57.000Z
2021-04-03T17:28:12.000Z
tests/test_football_badges.py
domdfcoding/football_badges
4d282b407ad8c0e9fbe50bf06f29226ab8edda46
[ "Apache-2.0" ]
1
2021-03-23T17:05:54.000Z
2021-03-23T17:05:54.000Z
# stdlib import webbrowser from typing import Tuple # 3rd party import pytest from coincidence.regressions import AdvancedFileRegressionFixture from consolekit.testing import CliRunner, Result from domdf_python_tools.iterative import permutations from domdf_python_tools.paths import PathPlus # this package from footb...
23.366771
94
0.627448
# stdlib import webbrowser from typing import Tuple # 3rd party import pytest from coincidence.regressions import AdvancedFileRegressionFixture from consolekit.testing import CliRunner, Result from domdf_python_tools.iterative import permutations from domdf_python_tools.paths import PathPlus # this package from footb...
4,907
302
69
4ec2bdb5d7af18579e0b5ae24d97410bc75be9a3
1,250
py
Python
tests/unit/proxy/cp/atomic_long_test.py
tonytheonlypony/hazelcast-python-client
3aafeaf2ebc05aee4f2386c62c079db496a7c81f
[ "Apache-2.0" ]
98
2015-12-08T14:26:27.000Z
2022-03-23T17:44:11.000Z
tests/unit/proxy/cp/atomic_long_test.py
tonytheonlypony/hazelcast-python-client
3aafeaf2ebc05aee4f2386c62c079db496a7c81f
[ "Apache-2.0" ]
396
2016-02-23T11:07:55.000Z
2022-03-31T14:26:34.000Z
tests/unit/proxy/cp/atomic_long_test.py
tonytheonlypony/hazelcast-python-client
3aafeaf2ebc05aee4f2386c62c079db496a7c81f
[ "Apache-2.0" ]
62
2015-12-09T11:20:53.000Z
2022-01-28T01:30:54.000Z
import unittest from mock import MagicMock from hazelcast.proxy.cp.atomic_long import AtomicLong
27.173913
74
0.6552
import unittest from mock import MagicMock from hazelcast.proxy.cp.atomic_long import AtomicLong class AtomicLongInvalidInputTest(unittest.TestCase): def setUp(self): self.atomic_long = AtomicLong(MagicMock(), None, None, None, None) def test_add_and_get(self): self._check_error("add_and_ge...
800
31
319
778019ef6d5bd09c9629d7b2553ea5c3626116e1
2,867
py
Python
Empzxy Projects/Data Science/Probability Simulations/Stocks and Shares Predcition Bot/main.py
Empzxy/Empzxy-2022-Projects-Overview
223fa3e2bf3a3dd39a72ebe2f4dfb08c180ebf48
[ "MIT" ]
null
null
null
Empzxy Projects/Data Science/Probability Simulations/Stocks and Shares Predcition Bot/main.py
Empzxy/Empzxy-2022-Projects-Overview
223fa3e2bf3a3dd39a72ebe2f4dfb08c180ebf48
[ "MIT" ]
null
null
null
Empzxy Projects/Data Science/Probability Simulations/Stocks and Shares Predcition Bot/main.py
Empzxy/Empzxy-2022-Projects-Overview
223fa3e2bf3a3dd39a72ebe2f4dfb08c180ebf48
[ "MIT" ]
null
null
null
import numpy as np import matplotlib.pyplot as plt import pandas as pd import pandas_datareader as web import datetime as dt from sklearn.preprocessing import MinMaxScaler from tensorflow.keras.models import Sequential from tensorflow.keras.layers import Dense, Dropout, LSTM #loading data compa...
31.505495
92
0.732822
import numpy as np import matplotlib.pyplot as plt import pandas as pd import pandas_datareader as web import datetime as dt from sklearn.preprocessing import MinMaxScaler from tensorflow.keras.models import Sequential from tensorflow.keras.layers import Dense, Dropout, LSTM #loading data compa...
0
0
0
ade1a9c73e1795d1262425fbd57c7f6bc8ef549a
3,317
py
Python
data_loader/my_criteo_dataset.py
Holldean/pytorch-models
9509d0d462b1a98164b266d49ada199071a855ac
[ "MIT" ]
null
null
null
data_loader/my_criteo_dataset.py
Holldean/pytorch-models
9509d0d462b1a98164b266d49ada199071a855ac
[ "MIT" ]
null
null
null
data_loader/my_criteo_dataset.py
Holldean/pytorch-models
9509d0d462b1a98164b266d49ada199071a855ac
[ "MIT" ]
null
null
null
from sklearn.preprocessing import LabelEncoder, MinMaxScaler from utils.util import ensure_dir from base import BaseDataLoader import pandas as pd import numpy as np import torch import time import os
44.226667
129
0.618028
from sklearn.preprocessing import LabelEncoder, MinMaxScaler from utils.util import ensure_dir from base import BaseDataLoader import pandas as pd import numpy as np import torch import time import os class MyCriteo(torch.utils.data.Dataset): def __init__(self, data_dir, sparse_...
2,991
20
103
9f4476b20b290a64c50594da43f4376c01b504f5
2,297
py
Python
typeform/question_ids_colnames.py
rjcnrd/gender_inequality_covid-19
464b7326746577a8d1e942c6d6903864d242128c
[ "MIT" ]
1
2020-04-29T12:11:40.000Z
2020-04-29T12:11:40.000Z
typeform/question_ids_colnames.py
rjcnrd/domestic_violence_covid-19
7bbf3aa3a7303d629013198bba8dc9822313d113
[ "MIT" ]
2
2020-05-05T20:10:32.000Z
2020-05-15T14:27:39.000Z
typeform/question_ids_colnames.py
rjcnrd/domestic_violence_covid-19
7bbf3aa3a7303d629013198bba8dc9822313d113
[ "MIT" ]
null
null
null
#OVERVIEW OF ALL QUESTION IDS "id": "Xa2T0bcZ5VnY", "title": "Do you identify as a:", "id": "QUtA6k0gcrZf", "title": "How old are you? ", "id": "ZNZyNVwMtwID", "title": "How would you identify your ethnicity" "id": "azlKRkvdcc7O", "title": "Who are you in lockdown with" "id": "Vrzj2uv0i29C", "title": "Where are y...
22.742574
80
0.681759
#OVERVIEW OF ALL QUESTION IDS "id": "Xa2T0bcZ5VnY", "title": "Do you identify as a:", "id": "QUtA6k0gcrZf", "title": "How old are you? ", "id": "ZNZyNVwMtwID", "title": "How would you identify your ethnicity" "id": "azlKRkvdcc7O", "title": "Who are you in lockdown with" "id": "Vrzj2uv0i29C", "title": "Where are y...
0
0
0
b1d51c1c49740f2744512bd66b5e67179410cd29
2,800
py
Python
tensorflow_version/input_fn.py
DeepDarkOdyssey/NamedEntityRecognition
08785004e00f2010b488d041b0b76f8aa9dad59c
[ "MIT" ]
null
null
null
tensorflow_version/input_fn.py
DeepDarkOdyssey/NamedEntityRecognition
08785004e00f2010b488d041b0b76f8aa9dad59c
[ "MIT" ]
null
null
null
tensorflow_version/input_fn.py
DeepDarkOdyssey/NamedEntityRecognition
08785004e00f2010b488d041b0b76f8aa9dad59c
[ "MIT" ]
null
null
null
"""Create the input data pipeline using `tf.data`""" import tensorflow as tf import tensorflow.contrib as tc import os from collections import namedtuple BatchInput = namedtuple('BatchInput', ['iterator', 'word_ids', 'label_ids', 'sentence_lengths'])
50
117
0.658929
"""Create the input data pipeline using `tf.data`""" import tensorflow as tf import tensorflow.contrib as tc import os from collections import namedtuple BatchInput = namedtuple('BatchInput', ['iterator', 'word_ids', 'label_ids', 'sentence_lengths']) def build_dataset(config, mode, word_voca...
2,474
0
46
ac1330d14ab3e4a5b50a4a7d6d529fcf0f653df1
931
py
Python
src/api/utils.py
cuappdev/scoop-backend
4bfb2494598831e10bdeede2243061f7ddee1b43
[ "MIT" ]
null
null
null
src/api/utils.py
cuappdev/scoop-backend
4bfb2494598831e10bdeede2243061f7ddee1b43
[ "MIT" ]
2
2022-03-14T22:55:22.000Z
2022-03-21T18:13:55.000Z
src/api/utils.py
cuappdev/rideshare-backend
4bfb2494598831e10bdeede2243061f7ddee1b43
[ "MIT" ]
null
null
null
from rest_framework import status from rest_framework.response import Response def success_response(data=None, status=status.HTTP_200_OK): """Returns a response with `status` (200 default) and `data` if provided.""" if data is None: return Response(status=status) return Response(data, status=statu...
34.481481
111
0.706767
from rest_framework import status from rest_framework.response import Response def success_response(data=None, status=status.HTTP_200_OK): """Returns a response with `status` (200 default) and `data` if provided.""" if data is None: return Response(status=status) return Response(data, status=statu...
0
0
0
2e2ba9ddb217a3aa4a31310162450b4d6349892a
333
py
Python
rxnebm/proposer/retroxpert/copy_files.py
coleygroup/rxn-ebm
8480822d0d8ad74e46edf693ad1cdc787291f422
[ "MIT" ]
5
2021-12-18T23:03:41.000Z
2022-03-29T15:31:57.000Z
rxnebm/proposer/retroxpert/copy_files.py
coleygroup/rxn-ebm
8480822d0d8ad74e46edf693ad1cdc787291f422
[ "MIT" ]
null
null
null
rxnebm/proposer/retroxpert/copy_files.py
coleygroup/rxn-ebm
8480822d0d8ad74e46edf693ad1cdc787291f422
[ "MIT" ]
1
2021-12-18T23:03:42.000Z
2021-12-18T23:03:42.000Z
times = 10 with open('src-train-aug-err-old.txt') as f: srcs = f.readlines() with open('tgt-train-aug-err-old.txt') as f: tgts = f.readlines() with open('src-train-aug-err.txt', 'w') as f: for t in range(times): f.writelines(srcs) with open('tgt-train-aug-err.txt', 'w') as f: for t in range(times): f.writ...
18.5
45
0.651652
times = 10 with open('src-train-aug-err-old.txt') as f: srcs = f.readlines() with open('tgt-train-aug-err-old.txt') as f: tgts = f.readlines() with open('src-train-aug-err.txt', 'w') as f: for t in range(times): f.writelines(srcs) with open('tgt-train-aug-err.txt', 'w') as f: for t in range(times): f.writ...
0
0
0
b85a99b298abdf22116a3e6648b4373d299d9331
10,462
py
Python
Code_Python/ch9_2_2.py
anemptyarchive/PRML
58cbb35ae65d66b6faf436c70a6cbc9d54d4589f
[ "MIT" ]
null
null
null
Code_Python/ch9_2_2.py
anemptyarchive/PRML
58cbb35ae65d66b6faf436c70a6cbc9d54d4589f
[ "MIT" ]
null
null
null
Code_Python/ch9_2_2.py
anemptyarchive/PRML
58cbb35ae65d66b6faf436c70a6cbc9d54d4589f
[ "MIT" ]
null
null
null
# 9.2.2 多次元ガウス分布のEMアルゴリズム #%% # 9.2.2項で利用するライブラリ import numpy as np from scipy.stats import multivariate_normal # 多次元ガウス分布 import matplotlib.pyplot as plt #%% ## 真の分布の設定 # 次元数を設定:(固定) D = 2 # クラスタ数を指定 K = 3 # K個の真の平均を指定 mu_truth_kd = np.array( [[5.0, 35.0], [-20.0, -10.0], [30.0, -20.0]] ) # K個の...
25.642157
104
0.615943
# 9.2.2 多次元ガウス分布のEMアルゴリズム #%% # 9.2.2項で利用するライブラリ import numpy as np from scipy.stats import multivariate_normal # 多次元ガウス分布 import matplotlib.pyplot as plt #%% ## 真の分布の設定 # 次元数を設定:(固定) D = 2 # クラスタ数を指定 K = 3 # K個の真の平均を指定 mu_truth_kd = np.array( [[5.0, 35.0], [-20.0, -10.0], [30.0, -20.0]] ) # K個の...
1,788
0
22
38e85acf434355c526a550d3fb21fad143d4d44e
853
py
Python
scripts/test_tags.py
pman06/recipe-project
3f9c9c47cbbce49363e0770a4f333232fb2f59a7
[ "MIT" ]
null
null
null
scripts/test_tags.py
pman06/recipe-project
3f9c9c47cbbce49363e0770a4f333232fb2f59a7
[ "MIT" ]
null
null
null
scripts/test_tags.py
pman06/recipe-project
3f9c9c47cbbce49363e0770a4f333232fb2f59a7
[ "MIT" ]
null
null
null
import requests TAG_LIST_ENDPOINT = 'http://127.0.0.1:8000/api/recipe/tags/' TOKEN_ENDPOINT = 'http://127.0.0.1:8000/api/user/token/' def authenticate_user(payload): """First authenticate user""" res = requests.post(TOKEN_ENDPOINT, payload) return res.json()['token'] def create_tag(data, headers): ...
21.871795
70
0.675264
import requests TAG_LIST_ENDPOINT = 'http://127.0.0.1:8000/api/recipe/tags/' TOKEN_ENDPOINT = 'http://127.0.0.1:8000/api/user/token/' def authenticate_user(payload): """First authenticate user""" res = requests.post(TOKEN_ENDPOINT, payload) return res.json()['token'] def create_tag(data, headers): ...
0
0
0
c1252760e77c2465f5c84d78985a856a579fcb66
2,025
py
Python
python-scripts/data/loader.py
antonior92/sysid-neuralnet
4ab4be97d37345e858807d9ff37c94a148530ba6
[ "MIT" ]
5
2019-10-23T16:56:37.000Z
2021-06-23T13:23:37.000Z
python-scripts/data/loader.py
tenpha/sysid-neuralnet
4ab4be97d37345e858807d9ff37c94a148530ba6
[ "MIT" ]
1
2019-12-25T11:15:09.000Z
2019-12-27T11:09:32.000Z
python-scripts/data/loader.py
tenpha/sysid-neuralnet
4ab4be97d37345e858807d9ff37c94a148530ba6
[ "MIT" ]
4
2020-08-25T12:47:08.000Z
2022-01-25T13:02:09.000Z
from data.base import DataLoaderExt from data.chen_example import ChenDataset from data.silverbox import create_silverbox_datasets from data.f16gvt import create_f16gvt_datasets
63.28125
113
0.727901
from data.base import DataLoaderExt from data.chen_example import ChenDataset from data.silverbox import create_silverbox_datasets from data.f16gvt import create_f16gvt_datasets def load_dataset(dataset, dataset_options, train_batch_size, test_batch_size): if dataset == 'chen': loader_train = DataLoaderEx...
1,823
0
23
e514a1bfa39f53b47ae133b8de275f70ca082339
2,595
py
Python
1._metis_models_and_data_2019-12-16b/METIS source code/Indicators/zones/kpis/Supply pie chart.py
tamas-borbath/METIS
cf3dc0f0f96ccb6ad72ddf15ba7e31ddc6339036
[ "CC-BY-4.0" ]
1
2021-12-07T09:05:48.000Z
2021-12-07T09:05:48.000Z
1._metis_models_and_data_2019-12-16b/METIS source code/Indicators/zones/kpis/Supply pie chart.py
tamas-borbath/METIS_data_and_scripts
cf3dc0f0f96ccb6ad72ddf15ba7e31ddc6339036
[ "CC-BY-4.0" ]
null
null
null
1._metis_models_and_data_2019-12-16b/METIS source code/Indicators/zones/kpis/Supply pie chart.py
tamas-borbath/METIS_data_and_scripts
cf3dc0f0f96ccb6ad72ddf15ba7e31ddc6339036
[ "CC-BY-4.0" ]
null
null
null
######################################################## # Copyright (c) 2015-2017 by European Commission. # # All Rights Reserved. # ######################################################## """ This view shows, for each energy, a pie chart of the different supply types in the con...
48.055556
164
0.761464
######################################################## # Copyright (c) 2015-2017 by European Commission. # # All Rights Reserved. # ######################################################## """ This view shows, for each energy, a pie chart of the different supply types in the con...
1,760
0
46
58809e44b64c5d1462587b932c1269391300b7d2
2,040
py
Python
blogapp/posts/routes.py
Carshy/blogApplication
a471cd8627510ebc2bd3ba213fe2dbe6e4eca60f
[ "bzip2-1.0.6" ]
null
null
null
blogapp/posts/routes.py
Carshy/blogApplication
a471cd8627510ebc2bd3ba213fe2dbe6e4eca60f
[ "bzip2-1.0.6" ]
null
null
null
blogapp/posts/routes.py
Carshy/blogApplication
a471cd8627510ebc2bd3ba213fe2dbe6e4eca60f
[ "bzip2-1.0.6" ]
null
null
null
from flask import render_template, url_for, redirect, flash, request, abort, Blueprint from flask_login import current_user, login_required from blogapp import db from blogapp.models import Post from blogapp.posts.forms import PostForm posts = Blueprint ('posts', __name__) @posts.route ("/post/new", methods = ['GET',...
38.490566
103
0.673039
from flask import render_template, url_for, redirect, flash, request, abort, Blueprint from flask_login import current_user, login_required from blogapp import db from blogapp.models import Post from blogapp.posts.forms import PostForm posts = Blueprint ('posts', __name__) @posts.route ("/post/new", methods = ['GET',...
1,400
0
88
db9246a1a75f987e619d19afc4b89628c564421d
333
py
Python
all/approximation/target/trivial.py
ezelikman/autonomous-learning-library
b32d059ca8b191afe0b310102d0754796f391aff
[ "MIT" ]
1
2021-01-08T01:41:34.000Z
2021-01-08T01:41:34.000Z
all/approximation/target/trivial.py
sadiakhaf/autonomous-learning-library
9c44d41826aec49f9ecba43093551219f9f39408
[ "MIT" ]
1
2020-02-26T08:53:10.000Z
2020-02-26T08:53:10.000Z
all/approximation/target/trivial.py
sadiakhaf/autonomous-learning-library
9c44d41826aec49f9ecba43093551219f9f39408
[ "MIT" ]
1
2020-04-11T23:45:14.000Z
2020-04-11T23:45:14.000Z
import torch from .abstract import TargetNetwork
19.588235
39
0.627628
import torch from .abstract import TargetNetwork class TrivialTarget(TargetNetwork): def __init__(self): self._model = None def __call__(self, *inputs): with torch.no_grad(): return self._model(*inputs) def init(self, model): self._model = model def update(self): ...
140
14
130
0e5f38a2e815ae2a4d1d0fd586989887041c2d73
5,285
py
Python
src/model/keywords.py
J-CITY/METADATA-EXTRACTOR
6bc01a7e4b74a3156c07efc2c80d5519c325dd53
[ "Apache-2.0" ]
null
null
null
src/model/keywords.py
J-CITY/METADATA-EXTRACTOR
6bc01a7e4b74a3156c07efc2c80d5519c325dd53
[ "Apache-2.0" ]
null
null
null
src/model/keywords.py
J-CITY/METADATA-EXTRACTOR
6bc01a7e4b74a3156c07efc2c80d5519c325dd53
[ "Apache-2.0" ]
null
null
null
import os, sys parentPath = os.path.abspath("..") if parentPath not in sys.path: sys.path.insert(0, parentPath) import string from collections import Counter, defaultdict from itertools import chain, groupby, product from config.dictionary import supportWords import nltk from enum import Enum from nltk.tokenize impor...
34.096774
562
0.622517
import os, sys parentPath = os.path.abspath("..") if parentPath not in sys.path: sys.path.insert(0, parentPath) import string from collections import Counter, defaultdict from itertools import chain, groupby, product from config.dictionary import supportWords import nltk from enum import Enum from nltk.tokenize impor...
3,188
2
404
c0ad7051a52d055cb87e64227585bbbd9f1447a4
251
py
Python
v1/accounts/jwt_handler.py
akkord64/openeats-api
011465123b6e471fc6e4ec3d715d99bc2a8dcfcc
[ "MIT" ]
11
2018-03-04T18:03:30.000Z
2021-09-04T17:03:24.000Z
v1/accounts/jwt_handler.py
akkord64/openeats-api
011465123b6e471fc6e4ec3d715d99bc2a8dcfcc
[ "MIT" ]
42
2020-06-05T14:55:57.000Z
2021-07-14T05:58:09.000Z
v1/accounts/jwt_handler.py
akkord64/openeats-api
011465123b6e471fc6e4ec3d715d99bc2a8dcfcc
[ "MIT" ]
40
2018-06-22T18:58:19.000Z
2022-01-31T08:34:05.000Z
#!/usr/bin/env python # encoding: utf-8 from .serializers import UserSerializer
20.916667
79
0.645418
#!/usr/bin/env python # encoding: utf-8 from .serializers import UserSerializer def handler(token, user=None, request=None): return { 'token': token, 'id': UserSerializer(user, context={'request': request}).data.get('id') }
146
0
23
d2b0a7fad4772a1783262d6d582bae1074a2d524
67
py
Python
open_cp/gui/tk/__init__.py
sumau/PredictCode
e2a2d5a8fa5d83f011c33e18d4ce6ac7e1429aa8
[ "Artistic-2.0" ]
18
2017-04-19T09:17:19.000Z
2021-05-24T08:53:28.000Z
open_cp/gui/tk/__init__.py
sumau/PredictCode
e2a2d5a8fa5d83f011c33e18d4ce6ac7e1429aa8
[ "Artistic-2.0" ]
8
2017-06-11T17:46:35.000Z
2021-06-07T10:49:10.000Z
open_cp/gui/tk/__init__.py
sumau/PredictCode
e2a2d5a8fa5d83f011c33e18d4ce6ac7e1429aa8
[ "Artistic-2.0" ]
10
2017-07-19T18:29:37.000Z
2020-11-12T22:06:45.000Z
import tkinter as tk import tkinter.ttk as ttk from .util import *
16.75
25
0.776119
import tkinter as tk import tkinter.ttk as ttk from .util import *
0
0
0
02fc7d3756c5a1a20f700d64cd48f08f01198c29
81
py
Python
main.py
HectorFranc/tweet-analysis
8c9b59826ad3ea1b61af66f56e593234eb0f0a79
[ "MIT" ]
null
null
null
main.py
HectorFranc/tweet-analysis
8c9b59826ad3ea1b61af66f56e593234eb0f0a79
[ "MIT" ]
null
null
null
main.py
HectorFranc/tweet-analysis
8c9b59826ad3ea1b61af66f56e593234eb0f0a79
[ "MIT" ]
null
null
null
from dotenv import load_dotenv load_dotenv() if __name__ == "__main__": pass
16.2
30
0.740741
from dotenv import load_dotenv load_dotenv() if __name__ == "__main__": pass
0
0
0
e435d396a139f60c30454563041d5e92e815a5bb
619
py
Python
esimport/utils.py
thorwhalen/esimport
ec96d894b50a87f704ad9a24563b6a6c505be911
[ "MIT" ]
1
2019-08-29T01:35:29.000Z
2019-08-29T01:35:29.000Z
esimport/utils.py
thorwhalen/esimport
ec96d894b50a87f704ad9a24563b6a6c505be911
[ "MIT" ]
null
null
null
esimport/utils.py
thorwhalen/esimport
ec96d894b50a87f704ad9a24563b6a6c505be911
[ "MIT" ]
null
null
null
import sys def retrieve_file(filename): """ Opens a file and returns its contents as a string after encoding to UTF-8 :param filename: :return: """ with open(filename, 'rb') as f: original_contents = f.read() decoded_contents = original_contents.decode('utf-8-sig').encode('utf...
22.107143
76
0.670436
import sys def retrieve_file(filename): """ Opens a file and returns its contents as a string after encoding to UTF-8 :param filename: :return: """ with open(filename, 'rb') as f: original_contents = f.read() decoded_contents = original_contents.decode('utf-8-sig').encode('utf...
0
0
0
d1062af00fbdda2f14ddd536cca6e078dea73aa3
3,754
py
Python
ummon/modules/linear.py
matherm/ummon3
08476d21ce17cc95180525d48202a1690dfc8a08
[ "BSD-3-Clause" ]
1
2022-02-10T06:47:13.000Z
2022-02-10T06:47:13.000Z
ummon/modules/linear.py
matherm/ummon3
08476d21ce17cc95180525d48202a1690dfc8a08
[ "BSD-3-Clause" ]
null
null
null
ummon/modules/linear.py
matherm/ummon3
08476d21ce17cc95180525d48202a1690dfc8a08
[ "BSD-3-Clause" ]
null
null
null
import numpy as np import torch import torch.nn as nn __all__ = [ 'Linear' ] class Linear(nn.Linear): ''' Fully connected linear layer class:: line0 = Linear([n], num_neurons, init, bias) creates a fully connected linear layer with 'n' input neurons and 'num_neurons' output neurons...
32.929825
95
0.603356
import numpy as np import torch import torch.nn as nn __all__ = [ 'Linear' ] class Linear(nn.Linear): ''' Fully connected linear layer class:: line0 = Linear([n], num_neurons, init, bias) creates a fully connected linear layer with 'n' input neurons and 'num_neurons' output neurons...
1,852
0
157
81010470e15f16dd6f24b190e28dabbb3e11fdfe
18,455
py
Python
sources/viewgui/form_new_device/ui_table_new_device_.py
Groomsha/lan-map
1c30819470f43f8521e98eb75c70da23939f8f06
[ "Apache-2.0" ]
null
null
null
sources/viewgui/form_new_device/ui_table_new_device_.py
Groomsha/lan-map
1c30819470f43f8521e98eb75c70da23939f8f06
[ "Apache-2.0" ]
null
null
null
sources/viewgui/form_new_device/ui_table_new_device_.py
Groomsha/lan-map
1c30819470f43f8521e98eb75c70da23939f8f06
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Form implementation generated from reading ui file '/mnt/c/Documents and Settings/icheberiak/Sources/Python/lan-map/viewgui/gui_windows/gui_form_new_device.ui' # # Created by: PyQt5 UI code generator 5.15.4 # # WARNING: Any manual changes made to this file will be lost when pyuic5 is # run ag...
62.138047
161
0.721268
# -*- coding: utf-8 -*- # Form implementation generated from reading ui file '/mnt/c/Documents and Settings/icheberiak/Sources/Python/lan-map/viewgui/gui_windows/gui_form_new_device.ui' # # Created by: PyQt5 UI code generator 5.15.4 # # WARNING: Any manual changes made to this file will be lost when pyuic5 is # run ag...
17,702
11
76
f449c1849bc6a54d8bd1cc5fe22c571068387e52
9,947
py
Python
M5StackCore2AWS/WiFi_provisioning/utilities/AWS_IoT_registration_helper/registration_helper.py
DarkSector/ESP32
0af7f75e3e9e23ba9d6e2c22ef61e7f74c00a606
[ "MIT" ]
78
2020-12-16T01:04:28.000Z
2022-03-29T02:07:38.000Z
M5StackCore2AWS/WiFi_provisioning/utilities/AWS_IoT_registration_helper/registration_helper.py
DarkSector/ESP32
0af7f75e3e9e23ba9d6e2c22ef61e7f74c00a606
[ "MIT" ]
88
2020-12-19T02:39:12.000Z
2022-03-15T18:00:00.000Z
M5StackCore2AWS/WiFi_provisioning/utilities/AWS_IoT_registration_helper/registration_helper.py
DarkSector/ESP32
0af7f75e3e9e23ba9d6e2c22ef61e7f74c00a606
[ "MIT" ]
47
2020-12-18T16:55:10.000Z
2022-02-11T02:04:16.000Z
# AWS IoT EduKit Pre-Provisioned MCU Device Registration Helper # v1.1.0 # # Copyright (C) 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved. # # 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 #...
44.806306
228
0.7359
# AWS IoT EduKit Pre-Provisioned MCU Device Registration Helper # v1.1.0 # # Copyright (C) 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved. # # 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 #...
240
0
23
6525fa4778c34ac61425f701203c480566f6f072
1,849
py
Python
sdk/python/bouncerapi/bouncerapi_client.py
nmfta-repo/nmfta-bouncer
a178244dbf0b8a165aabc02a5d1ba05006f9ec22
[ "Apache-2.0" ]
1
2021-04-09T20:29:39.000Z
2021-04-09T20:29:39.000Z
sdk/python/bouncerapi/bouncerapi_client.py
nmfta-repo/nmfta-bouncer
a178244dbf0b8a165aabc02a5d1ba05006f9ec22
[ "Apache-2.0" ]
21
2019-02-28T14:23:11.000Z
2020-07-07T20:46:37.000Z
sdk/python/bouncerapi/bouncerapi_client.py
nmfta-repo/nmfta-bouncer
a178244dbf0b8a165aabc02a5d1ba05006f9ec22
[ "Apache-2.0" ]
2
2019-05-07T13:16:49.000Z
2020-06-23T13:49:01.000Z
# -*- coding: utf-8 -*- """ bouncerapi This file was automatically generated by APIMATIC v2.0 ( https://apimatic.io ). """ from bouncerapi.decorators import lazy_property from bouncerapi.configuration import Configuration from bouncerapi.controllers.blacklist_controller import BlacklistController from bounce...
31.87931
103
0.809086
# -*- coding: utf-8 -*- """ bouncerapi This file was automatically generated by APIMATIC v2.0 ( https://apimatic.io ). """ from bouncerapi.decorators import lazy_property from bouncerapi.configuration import Configuration from bouncerapi.controllers.blacklist_controller import BlacklistController from bounce...
432
406
23
e956d86cb31ffa11c50885dab398eb8cb6cc3347
1,145
py
Python
src/osyris/io/units.py
nvaytet/osyris
7deb57d2e6e6635fd4f065a196466d1db02644fc
[ "BSD-3-Clause" ]
10
2019-08-28T18:18:31.000Z
2021-12-21T00:07:04.000Z
src/osyris/io/units.py
nvaytet/osyris
7deb57d2e6e6635fd4f065a196466d1db02644fc
[ "BSD-3-Clause" ]
20
2019-08-20T13:02:33.000Z
2022-01-22T00:38:17.000Z
src/osyris/io/units.py
nvaytet/osyris
7deb57d2e6e6635fd4f065a196466d1db02644fc
[ "BSD-3-Clause" ]
5
2020-12-07T23:36:50.000Z
2021-12-20T23:05:13.000Z
import numpy as np from .. import units
34.69697
78
0.527511
import numpy as np from .. import units def get_unit(string, ud, ul, ut): ramses_units = { "density": ud * (units.g / (units.cm**3)), "velocity": (ul / ut) * (units.cm / units.s), "part_velocity": (ul / ut) * (units.cm / units.s), "momentum": (ud * ul / ut) * (units.g / (units.cm**...
1,081
0
23
017bcee435cacb4f38c650285e22560a2a3275a7
2,472
py
Python
processor/process.py
paulscottrobson/rca-16-bit-computer
fd185541dfd5e6a671626c27dc51a4cd6e633de8
[ "MIT" ]
null
null
null
processor/process.py
paulscottrobson/rca-16-bit-computer
fd185541dfd5e6a671626c27dc51a4cd6e633de8
[ "MIT" ]
null
null
null
processor/process.py
paulscottrobson/rca-16-bit-computer
fd185541dfd5e6a671626c27dc51a4cd6e633de8
[ "MIT" ]
null
null
null
# ******************************************************************************** # # Convert 18016.def to compileable code # # ******************************************************************************** import os,re target = "../emulator/generated/".replace("/",os.sep) # output directory. # # ...
33.405405
92
0.554207
# ******************************************************************************** # # Convert 18016.def to compileable code # # ******************************************************************************** import os,re def process(s,opcode): s = s.replace("@P",str(opcode & 7)) s = s.replace("@R","{0:X}".fo...
138
0
23
f6f531ba779d05b5a707ec418483c4c355b22d21
106
py
Python
configuration/__init__.py
jameshi16/TypeSound
238d019ed22ed5b41df533ac5ec43cbf28428fa6
[ "MIT" ]
null
null
null
configuration/__init__.py
jameshi16/TypeSound
238d019ed22ed5b41df533ac5ec43cbf28428fa6
[ "MIT" ]
null
null
null
configuration/__init__.py
jameshi16/TypeSound
238d019ed22ed5b41df533ac5ec43cbf28428fa6
[ "MIT" ]
null
null
null
from .JSONConfiguration import JSONConfiguration from .ConfigurationSchemeV1 import ConfigurationSchemeV1
35.333333
56
0.90566
from .JSONConfiguration import JSONConfiguration from .ConfigurationSchemeV1 import ConfigurationSchemeV1
0
0
0
65a9e4ef1fc4a6d9d1ff52bfbf798fa781259ff0
97
py
Python
app/scoring/__init__.py
ThembiNsele/ClimateMind-Backend
0e418000b2a0141a1e4a7c11dbe3564082a3f4bb
[ "MIT" ]
6
2020-08-20T10:49:59.000Z
2022-01-24T16:49:46.000Z
app/scoring/__init__.py
ThembiNsele/ClimateMind-Backend
0e418000b2a0141a1e4a7c11dbe3564082a3f4bb
[ "MIT" ]
95
2020-07-24T22:32:34.000Z
2022-03-05T15:01:16.000Z
app/scoring/__init__.py
ThembiNsele/ClimateMind-Backend
0e418000b2a0141a1e4a7c11dbe3564082a3f4bb
[ "MIT" ]
5
2020-07-30T17:29:09.000Z
2021-01-10T19:46:15.000Z
from flask import Blueprint bp = Blueprint("scoring", __name__) from app.scoring import routes
16.166667
35
0.783505
from flask import Blueprint bp = Blueprint("scoring", __name__) from app.scoring import routes
0
0
0
863962eac17e78dead443b5bc34f6501870d40e4
1,251
py
Python
taskmanager/src/modules/tasks/application/create/create_task.py
alice-biometrics/petisco-task-manager
2bad52013ab122f8c3e5dce740dcd154883e6940
[ "MIT" ]
1
2020-04-14T18:12:11.000Z
2020-04-14T18:12:11.000Z
taskmanager/src/modules/tasks/application/create/create_task.py
alice-biometrics/petisco-task-manager
2bad52013ab122f8c3e5dce740dcd154883e6940
[ "MIT" ]
3
2020-04-20T10:35:26.000Z
2020-06-15T07:45:59.000Z
taskmanager/src/modules/tasks/application/create/create_task.py
alice-biometrics/petisco-task-manager
2bad52013ab122f8c3e5dce740dcd154883e6940
[ "MIT" ]
1
2021-03-12T13:48:01.000Z
2021-03-12T13:48:01.000Z
from petisco import use_case_handler, UseCase, Petisco from meiga import Result, Error, Success from petisco.event.bus.domain.interface_event_bus import IEventBus from taskmanager.src.modules.tasks.domain.description import Description from taskmanager.src.modules.tasks.domain.title import Title from taskmanager.src...
35.742857
83
0.745004
from petisco import use_case_handler, UseCase, Petisco from meiga import Result, Error, Success from petisco.event.bus.domain.interface_event_bus import IEventBus from taskmanager.src.modules.tasks.domain.description import Description from taskmanager.src.modules.tasks.domain.title import Title from taskmanager.src...
517
103
22