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
1332178f1063d191575dbabb00a6432c5253c8b8
801
py
Python
2017/11/solution.py
Artemigos/advent-of-code
0b2ae6af3788b9e6891219b2b64ce0d510b3e1aa
[ "MIT" ]
null
null
null
2017/11/solution.py
Artemigos/advent-of-code
0b2ae6af3788b9e6891219b2b64ce0d510b3e1aa
[ "MIT" ]
null
null
null
2017/11/solution.py
Artemigos/advent-of-code
0b2ae6af3788b9e6891219b2b64ce0d510b3e1aa
[ "MIT" ]
null
null
null
import common data = common.read_file('2017/11/data.txt').strip().split(',') offset_x = 0 offset_y = 0 max_dist = 0 # |nw|n # sw| |ne # s |se| for move in data: if move == 'sw' or move == 's': offset_x -= 1 elif move == 'n' or move == 'ne': offset_x += 1 if move == 'nw' or move == ...
18.204545
62
0.526841
import common data = common.read_file('2017/11/data.txt').strip().split(',') offset_x = 0 offset_y = 0 def dist(): def sign(x): if x > 0: return 1 if x < 0: return -1 return 0 if sign(offset_x) != sign(offset_y): return max([abs(offset_x), abs(offset_y...
236
0
23
54a9831344f4c0e3f5b036d8445596a4fd1bd19f
12,297
py
Python
backend/tests/test_vote.py
Davidw1339/GroceryBuddy
6e2fde00999b4b9e218a919d793ee10128212ea8
[ "Apache-2.0" ]
null
null
null
backend/tests/test_vote.py
Davidw1339/GroceryBuddy
6e2fde00999b4b9e218a919d793ee10128212ea8
[ "Apache-2.0" ]
18
2019-02-09T21:59:15.000Z
2019-03-10T19:13:19.000Z
backend/tests/test_vote.py
Davidw1339/GroceryBuddy
6e2fde00999b4b9e218a919d793ee10128212ea8
[ "Apache-2.0" ]
2
2019-02-12T17:12:22.000Z
2019-02-25T05:41:31.000Z
import json import model from utils import Error import test_data import validation def test_upvote(client, existing_item): ''' Tests upvoting. ''' upc = str(existing_item.upc) store = existing_item.stores[0] store_name = str(store.name) lat = float(store.location['lat']) long_arg = fl...
25.997886
75
0.582988
import json import model from utils import Error import test_data import validation def test_upvote(client, existing_item): ''' Tests upvoting. ''' upc = str(existing_item.upc) store = existing_item.stores[0] store_name = str(store.name) lat = float(store.location['lat']) long_arg = fl...
0
0
0
02404d9331a63bf8fa9b8c3262b1f0d51b0d7416
3,828
py
Python
openslides_backend/models/base.py
r-peschke/openslides-backend
83d0dab68bb914f06a0f50cffe23fc10ca45376f
[ "MIT" ]
null
null
null
openslides_backend/models/base.py
r-peschke/openslides-backend
83d0dab68bb914f06a0f50cffe23fc10ca45376f
[ "MIT" ]
null
null
null
openslides_backend/models/base.py
r-peschke/openslides-backend
83d0dab68bb914f06a0f50cffe23fc10ca45376f
[ "MIT" ]
null
null
null
import re from typing import Dict, Iterable, Optional, Type from ..shared.patterns import Collection from . import fields model_registry: Dict[Collection, Type["Model"]] = {} class ModelMetaClass(type): """ Metaclass for Model base class (see below). This metaclass ensures that all fields get attribute...
33.578947
88
0.613375
import re from typing import Dict, Iterable, Optional, Type from ..shared.patterns import Collection from . import fields model_registry: Dict[Collection, Type["Model"]] = {} class ModelMetaClass(type): """ Metaclass for Model base class (see below). This metaclass ensures that all fields get attribute...
1,415
0
108
dbd10b530e1efbdd7bfcde5fecee46c89eefe1da
276
py
Python
test/test_astrofunc.py
LBJ-Wade/astrofunc_lensing_profile
d2223705bc44d07575a5e93291375ab8e69ebfa8
[ "MIT" ]
null
null
null
test/test_astrofunc.py
LBJ-Wade/astrofunc_lensing_profile
d2223705bc44d07575a5e93291375ab8e69ebfa8
[ "MIT" ]
null
null
null
test/test_astrofunc.py
LBJ-Wade/astrofunc_lensing_profile
d2223705bc44d07575a5e93291375ab8e69ebfa8
[ "MIT" ]
null
null
null
""" Tests for `astrofunc` module. """ import pytest from astrofunc import astrofunc
13.8
31
0.648551
""" Tests for `astrofunc` module. """ import pytest from astrofunc import astrofunc class TestAstrofunc(object): @classmethod def setup_class(cls): pass def test_something(self): pass @classmethod def teardown_class(cls): pass
46
122
23
81aae42509bd7702c8b822a96cb63282f84f2cd2
275
py
Python
office365/graph/teams/teamFunSettings.py
stardust85/Office365-REST-Python-Client
cd369c607c7d137a000734e9c5e8f03ae3e3c603
[ "MIT" ]
null
null
null
office365/graph/teams/teamFunSettings.py
stardust85/Office365-REST-Python-Client
cd369c607c7d137a000734e9c5e8f03ae3e3c603
[ "MIT" ]
null
null
null
office365/graph/teams/teamFunSettings.py
stardust85/Office365-REST-Python-Client
cd369c607c7d137a000734e9c5e8f03ae3e3c603
[ "MIT" ]
null
null
null
from office365.runtime.client_value_object import ClientValueObject class TeamFunSettings(ClientValueObject): """Settings to configure use of Giphy, memes, and stickers in the team."""
25
78
0.723636
from office365.runtime.client_value_object import ClientValueObject class TeamFunSettings(ClientValueObject): """Settings to configure use of Giphy, memes, and stickers in the team.""" def __init__(self): super().__init__() self.allowGiphy = True
56
0
27
0a24d1d4f17820efe8895ed41e622db3e084accc
1,713
py
Python
AutoHTMLReload/__main__.py
jupiterbjy/ProjectIncubator
81ea87f927cda105ff55aa9504bd1d9ea7318bcd
[ "MIT" ]
1
2021-05-21T08:08:57.000Z
2021-05-21T08:08:57.000Z
AutoHTMLReload/__main__.py
jupiterbjy/ProjectIncubator
81ea87f927cda105ff55aa9504bd1d9ea7318bcd
[ "MIT" ]
null
null
null
AutoHTMLReload/__main__.py
jupiterbjy/ProjectIncubator
81ea87f927cda105ff55aa9504bd1d9ea7318bcd
[ "MIT" ]
null
null
null
import argparse import pathlib import time from watchdog.observers import Observer from watchdog.events import FileSystemEventHandler from selenium import webdriver try: from TinyTools.LoggingConfigurator import logger except ModuleNotFoundError: from sys import path from os.path import abspath path.a...
25.567164
109
0.697023
import argparse import pathlib import time from watchdog.observers import Observer from watchdog.events import FileSystemEventHandler from selenium import webdriver try: from TinyTools.LoggingConfigurator import logger except ModuleNotFoundError: from sys import path from os.path import abspath path.a...
667
77
69
12b1642a0f903292290653b06867eeab2de6d92b
2,016
py
Python
pilapse/interface.py
git-akihakune/pilapse
2e2cb99e074b5b234c3d8816d421e3d24909e2e6
[ "MIT" ]
null
null
null
pilapse/interface.py
git-akihakune/pilapse
2e2cb99e074b5b234c3d8816d421e3d24909e2e6
[ "MIT" ]
null
null
null
pilapse/interface.py
git-akihakune/pilapse
2e2cb99e074b5b234c3d8816d421e3d24909e2e6
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # Because it's better not to rely on external libraries def banner(): """Print the program's banner""" banner = """ ____ ____ __ __ ____ ___ ____ ( _ \(_ _)( ) /__\ ( _ \/ __)( ___) )___/ _)(_ )(__ /(__)\ )___/\__ \ )__) (__) (____)(____)(__)(__)(__) (___/(...
27.243243
86
0.573413
#!/usr/bin/env python3 # Because it's better not to rely on external libraries class logger: def __init__(self, verbose: bool) -> None: self.verbose = verbose def error(self, text): print("{} {}".format("\033[95m[error]\033[00m", text)) def critical(self, text): print("{} {}".form...
831
-8
233
69bd7542bf468a9b3b4f4930726f0a785514ea9f
23
py
Python
Python/Tests/TestData/DebuggerProject/DebugReplTest5.py
techkey/PTVS
8355e67eedd8e915ca49bd38a2f36172696fd903
[ "Apache-2.0" ]
404
2019-05-07T02:21:57.000Z
2022-03-31T17:03:04.000Z
Python/Tests/TestData/DebuggerProject/DebugReplTest5.py
techkey/PTVS
8355e67eedd8e915ca49bd38a2f36172696fd903
[ "Apache-2.0" ]
1,672
2019-05-06T21:09:38.000Z
2022-03-31T23:16:04.000Z
Python/Tests/TestData/DebuggerProject/DebugReplTest5.py
techkey/PTVS
8355e67eedd8e915ca49bd38a2f36172696fd903
[ "Apache-2.0" ]
186
2019-05-13T03:17:37.000Z
2022-03-31T16:24:05.000Z
import time print('')
5.75
11
0.652174
import time print('')
0
0
0
cf0656a44175ebff827492b59c164f6449521196
5,234
py
Python
banners.py
FingerLeakers/technowlogger
9b5dd3cf83521e6cacc5504114b930270fb1d414
[ "BSD-3-Clause" ]
153
2020-09-02T07:41:49.000Z
2022-03-24T11:57:46.000Z
banners.py
FingerLeakers/technowlogger
9b5dd3cf83521e6cacc5504114b930270fb1d414
[ "BSD-3-Clause" ]
25
2019-10-28T03:36:19.000Z
2020-08-31T11:51:42.000Z
banners.py
FingerLeakers/technowlogger
9b5dd3cf83521e6cacc5504114b930270fb1d414
[ "BSD-3-Clause" ]
34
2020-10-01T15:20:38.000Z
2022-03-28T20:42:07.000Z
import random figlet_ansi_shadow = """ ████████╗██╗ ██████╗ ██████╗ ██████╗ ███████╗██████╗ ╚══██╔══╝██║ ██╔═══██╗██╔════╝ ██╔════╝ ██╔════╝██╔══██╗ ██║ ██║ ██║ ██║██║ ███╗██║ ███╗█████╗ ██████╔╝ ██║ ██║ ██║ ██║██║ ██║██║ ██║██╔══╝ ██╔══██╗ ██║ ███████╗╚██████╔╝╚...
49.847619
162
0.2094
import random figlet_ansi_shadow = """ ████████╗██╗ ██████╗ ██████╗ ██████╗ ███████╗██████╗ ╚══██╔══╝██║ ██╔═══██╗██╔════╝ ██╔════╝ ██╔════╝██╔══██╗ ██║ ██║ ██║ ██║██║ ███╗██║ ███╗█████╗ ██████╔╝ ██║ ██║ ██║ ██║██║ ██║██║ ██║██╔══╝ ██╔══██╗ ██║ ███████╗╚██████╔╝╚...
160
0
24
d7f906859a056378a94b0694f7bb8266790d82ec
452
bzl
Python
rust/deps.bzl
justinwp/rules_proto
76e30bc0ad6c2f4150f40e593db83eedeb069f1e
[ "Apache-2.0" ]
null
null
null
rust/deps.bzl
justinwp/rules_proto
76e30bc0ad6c2f4150f40e593db83eedeb069f1e
[ "Apache-2.0" ]
null
null
null
rust/deps.bzl
justinwp/rules_proto
76e30bc0ad6c2f4150f40e593db83eedeb069f1e
[ "Apache-2.0" ]
null
null
null
load( "//:deps.bzl", "com_google_protobuf", "io_bazel_rules_rust", )
21.52381
33
0.719027
load( "//:deps.bzl", "com_google_protobuf", "io_bazel_rules_rust", ) def rust_proto_compile(**kwargs): com_google_protobuf(**kwargs) io_bazel_rules_rust(**kwargs) def rust_grpc_compile(**kwargs): rust_proto_compile(**kwargs) def rust_proto_library(**kwargs): rust_proto_compile(**kwargs) ...
279
0
92
95f681282c638cfe3b0e868377558b9e8a5cbe87
292
py
Python
wwwhisper_admin/__init__.py
wrr/wwwhisper
38a55dd9c828fbb1b5a8234ea3ddf2242e684983
[ "MIT" ]
54
2015-01-19T23:49:39.000Z
2021-02-18T01:14:51.000Z
wwwhisper_admin/__init__.py
wrr/wwwhisper
38a55dd9c828fbb1b5a8234ea3ddf2242e684983
[ "MIT" ]
13
2015-01-26T14:51:10.000Z
2020-11-10T04:15:36.000Z
wwwhisper_admin/__init__.py
wrr/wwwhisper
38a55dd9c828fbb1b5a8234ea3ddf2242e684983
[ "MIT" ]
11
2015-07-25T02:13:12.000Z
2021-07-10T14:11:46.000Z
# wwwhisper - web access control. # Copyright (C) 2012-2018 Jan Wrobel <jan@mixedbit.org> """wwwhisper admin API. The package exposes http API for specifying which users can access which locations and for other admin operations. """ default_app_config = 'wwwhisper_admin.appconfig.Config'
26.545455
66
0.777397
# wwwhisper - web access control. # Copyright (C) 2012-2018 Jan Wrobel <jan@mixedbit.org> """wwwhisper admin API. The package exposes http API for specifying which users can access which locations and for other admin operations. """ default_app_config = 'wwwhisper_admin.appconfig.Config'
0
0
0
487ec555e13c25fe91160533649b3523747000df
3,729
py
Python
tests/minionswarm.py
mika/salt
8430482c7177356964c894d161830c94d09f1cab
[ "Apache-2.0" ]
1
2016-09-16T17:12:11.000Z
2016-09-16T17:12:11.000Z
tests/minionswarm.py
mika/salt
8430482c7177356964c894d161830c94d09f1cab
[ "Apache-2.0" ]
null
null
null
tests/minionswarm.py
mika/salt
8430482c7177356964c894d161830c94d09f1cab
[ "Apache-2.0" ]
null
null
null
#/usr/bin/env python ''' The minionswarm script will start a group of salt minions with different ids on a single system to test scale capabilities ''' # Import Python Libs import os import optparse import subprocess import tempfile import shutil import random import hashlib # Import salt libs import salt # Import t...
26.260563
78
0.503888
#/usr/bin/env python ''' The minionswarm script will start a group of salt minions with different ids on a single system to test scale capabilities ''' # Import Python Libs import os import optparse import subprocess import tempfile import shutil import random import hashlib # Import salt libs import salt # Import t...
56
0
26
6a265cb064e17fd5725f7e3cb5bfe8927eb217f2
106
py
Python
tests/python.py
Doombite/python-cs50
9a384f6e24dfa2a666c4904a2a2021470792bfda
[ "MIT" ]
1
2022-02-26T13:50:06.000Z
2022-02-26T13:50:06.000Z
tests/python.py
Doombite/python-cs50
9a384f6e24dfa2a666c4904a2a2021470792bfda
[ "MIT" ]
null
null
null
tests/python.py
Doombite/python-cs50
9a384f6e24dfa2a666c4904a2a2021470792bfda
[ "MIT" ]
1
2022-03-05T09:06:50.000Z
2022-03-05T09:06:50.000Z
import sys sys.path.insert(0, "../src") import cs50 i = cs50.get_int("Input: ") print(f"Output: {i}")
11.777778
28
0.622642
import sys sys.path.insert(0, "../src") import cs50 i = cs50.get_int("Input: ") print(f"Output: {i}")
0
0
0
30602707207ab4110fd6f44ab1068a80c01efc53
709
py
Python
config.py
xiaosimao/ip_pool
5f074f7288ed4174f44096d8d982a1d7caa3460a
[ "Apache-2.0" ]
659
2017-09-22T09:30:43.000Z
2022-02-20T05:10:32.000Z
config.py
chengzhu-zc/IP_POOL
5f074f7288ed4174f44096d8d982a1d7caa3460a
[ "Apache-2.0" ]
3
2017-10-27T16:48:09.000Z
2018-03-07T00:52:41.000Z
config.py
chengzhu-zc/IP_POOL
5f074f7288ed4174f44096d8d982a1d7caa3460a
[ "Apache-2.0" ]
179
2017-09-22T09:30:43.000Z
2021-08-19T02:52:33.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- # Created by shimeng on 17-8-17 # 爬虫名称 spider_name = 'get_ip' # 日志设置 log_folder_name = '%s_logs' % spider_name delete_existed_logs = True # 请求参数设置 thread_num = 50 sleep_time = 0.5 retry_times = 10 time_out = 5 # 当use_proxy为True时,必须在请求的args中或者在配置文件中定义ip, eg: ip="120.52.7...
16.488372
77
0.732017
#!/usr/bin/env python # -*- coding: utf-8 -*- # Created by shimeng on 17-8-17 # 爬虫名称 spider_name = 'get_ip' # 日志设置 log_folder_name = '%s_logs' % spider_name delete_existed_logs = True # 请求参数设置 thread_num = 50 sleep_time = 0.5 retry_times = 10 time_out = 5 # 当use_proxy为True时,必须在请求的args中或者在配置文件中定义ip, eg: ip="120.52.7...
0
0
0
b17bd501de05aab10f4db56343dd9a372946a8ec
4,566
py
Python
Day 73/Model-1.py
vgaurav3011/100-Days-of-ML
ec302b03fd492c459cff2592b3a4f5e38f9c9d72
[ "MIT" ]
12
2020-03-30T15:10:48.000Z
2021-11-08T06:04:01.000Z
Day 73/Model-1.py
vgaurav3011/100-Days-of-ML
ec302b03fd492c459cff2592b3a4f5e38f9c9d72
[ "MIT" ]
3
2021-06-08T22:34:58.000Z
2022-01-13T03:25:23.000Z
Day 73/Model-1.py
vgaurav3011/100-Days-of-ML
ec302b03fd492c459cff2592b3a4f5e38f9c9d72
[ "MIT" ]
3
2020-04-13T09:51:28.000Z
2021-04-28T07:37:36.000Z
# -*- coding: utf-8 -*- """Working_Model.ipynb Automatically generated by Colaboratory. Original file is located at https://colab.research.google.com/drive/15vMWS3F0cKUYSGMFpdKrZkNjuDhfApRm """ from google.colab import drive drive.mount('/content/drive') import pandas as pd import numpy as np import matplotli...
31.708333
110
0.708717
# -*- coding: utf-8 -*- """Working_Model.ipynb Automatically generated by Colaboratory. Original file is located at https://colab.research.google.com/drive/15vMWS3F0cKUYSGMFpdKrZkNjuDhfApRm """ from google.colab import drive drive.mount('/content/drive') import pandas as pd import numpy as np import matplotli...
2,174
0
169
b49c14c806fd64585637af2b144dc9b99988dbfd
6,599
py
Python
HingeLoss.py
sujayv/LogisticRegression
729de3441b5e0ab6c59724b11ce0c21b70e8afd1
[ "MIT" ]
null
null
null
HingeLoss.py
sujayv/LogisticRegression
729de3441b5e0ab6c59724b11ce0c21b70e8afd1
[ "MIT" ]
null
null
null
HingeLoss.py
sujayv/LogisticRegression
729de3441b5e0ab6c59724b11ce0c21b70e8afd1
[ "MIT" ]
null
null
null
import numpy #Initialize the class variables #The variable names indicate what data is stored in them #Method to calculate the hinge loss value for the entire data set #Method to calculate the hinge loss value and gradient for a particular row (used for Stochastic Gradient) #Method to train classifier using Stocha...
44.587838
138
0.54781
import numpy class HingeLoss: #Initialize the class variables #The variable names indicate what data is stored in them def __init__(self,data,classes, tolerancearg): self.tolerance = tolerancearg self.features = numpy.array(data) self.labels = numpy.array(classes) self.weights = n...
6,132
-5
127
235921857a710d571fbd81b754a11f3d958d21d5
5,413
py
Python
bme280.py
rainerraul/pi-python
111a50b5fa23960f02c4a19740b40e6026b7741c
[ "MIT" ]
null
null
null
bme280.py
rainerraul/pi-python
111a50b5fa23960f02c4a19740b40e6026b7741c
[ "MIT" ]
null
null
null
bme280.py
rainerraul/pi-python
111a50b5fa23960f02c4a19740b40e6026b7741c
[ "MIT" ]
null
null
null
#!/usr/bin/python import smbus import os import time import math twowire = smbus.SMBus(1) cal0 = [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0] cal1 = [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0] dig_T = [0,0,0,0,0,0,0,0,0] dig_P = [0,0,0,0,0,0,0,0,0,0] dig_H = [0,0,0,0,0,0,0,0,0] raw_data = [0,0,0,0,0,0,0,0] raw_value...
28.946524
118
0.630334
#!/usr/bin/python import smbus import os import time import math twowire = smbus.SMBus(1) cal0 = [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0] cal1 = [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0] dig_T = [0,0,0,0,0,0,0,0,0] dig_P = [0,0,0,0,0,0,0,0,0,0] dig_H = [0,0,0,0,0,0,0,0,0] raw_data = [0,0,0,0,0,0,0,0] raw_value...
3,556
0
322
78f40af86a3d89230684b92793c6e5400b0559e6
2,170
py
Python
contacts/views.py
pedrohd21/Agenda-Django
c48a90d76094523fd2060ff735faefbf3c2f808d
[ "MIT" ]
1
2021-04-21T00:07:03.000Z
2021-04-21T00:07:03.000Z
contacts/views.py
pedrohd21/Agenda
c48a90d76094523fd2060ff735faefbf3c2f808d
[ "MIT" ]
null
null
null
contacts/views.py
pedrohd21/Agenda
c48a90d76094523fd2060ff735faefbf3c2f808d
[ "MIT" ]
null
null
null
from django.shortcuts import render, redirect from .models import Contact from django.shortcuts import get_object_or_404 from .forms import ContactForm from django.contrib import messages from django.core.paginator import Paginator from django.contrib.auth.decorators import login_required @login_required @login_req...
32.38806
99
0.677419
from django.shortcuts import render, redirect from .models import Contact from django.shortcuts import get_object_or_404 from .forms import ContactForm from django.contrib import messages from django.core.paginator import Paginator from django.contrib.auth.decorators import login_required @login_required def contacts...
1,681
0
110
0525ae0cc1e9c28f5fa78ac476f41fd42bef8553
2,298
py
Python
tests/share/search/test_indexer.py
felliott/SHARE
8fd60ff4749349c9b867f6188650d71f4f0a1a56
[ "Apache-2.0" ]
null
null
null
tests/share/search/test_indexer.py
felliott/SHARE
8fd60ff4749349c9b867f6188650d71f4f0a1a56
[ "Apache-2.0" ]
null
null
null
tests/share/search/test_indexer.py
felliott/SHARE
8fd60ff4749349c9b867f6188650d71f4f0a1a56
[ "Apache-2.0" ]
null
null
null
import pytest from share import models from share.search import SearchIndexer from tests import factories
35.353846
99
0.62228
import pytest from share import models from share.search import SearchIndexer from tests import factories class TestIdsToReindex: @pytest.mark.parametrize('model', [models.AbstractAgent, models.Tag, models.Source]) @pytest.mark.parametrize('pks', [set(), {1}, {1, 2, 3}]) def test_noops(self, model, pks...
1,933
233
23
908832a2def4f0eda1e748b9c14c553a6a6db9f4
1,476
py
Python
graph/Python/DSU-Kruskal.py
bakuryuthem0/al-go-rithms
8ad4b65a988740525585ecae2b6f0b815cdbcd66
[ "CC0-1.0" ]
4
2019-10-11T06:12:18.000Z
2021-08-01T14:24:18.000Z
graph/Python/DSU-Kruskal.py
bakuryuthem0/al-go-rithms
8ad4b65a988740525585ecae2b6f0b815cdbcd66
[ "CC0-1.0" ]
null
null
null
graph/Python/DSU-Kruskal.py
bakuryuthem0/al-go-rithms
8ad4b65a988740525585ecae2b6f0b815cdbcd66
[ "CC0-1.0" ]
8
2019-10-11T22:05:43.000Z
2021-12-23T23:18:12.000Z
n = int(input("Enter number of nodes:")) node = Node() node.makeset(n) edges = int(input("Enter number of edges:")) lis = [] mst = [] for i in range(edges): x, y, w = input().split(' ') lis.append((int(w), int(x), int(y))) lis.sort() print (lis) for j in range(edges): u = lis[j][1] v = lis[j][2] ...
24.196721
69
0.50813
class Node: def __init__(self): self.nodes = [] self.index = 0 self.rank = 0 self.parent = None def makeset(self, n): for i in range(0, n): node = Node() node.index = i node.rank = 0 node.parent = node self.nod...
609
-10
130
be270763ac97712ab39d7683d00404bf471ffdc0
9,476
py
Python
asyncpraw/exceptions.py
vikasbhatia/asyncpraw
8b9e1bd72945023f6eb4567ff69ba13aa428a2d2
[ "BSD-2-Clause" ]
null
null
null
asyncpraw/exceptions.py
vikasbhatia/asyncpraw
8b9e1bd72945023f6eb4567ff69ba13aa428a2d2
[ "BSD-2-Clause" ]
null
null
null
asyncpraw/exceptions.py
vikasbhatia/asyncpraw
8b9e1bd72945023f6eb4567ff69ba13aa428a2d2
[ "BSD-2-Clause" ]
1
2020-12-13T05:10:35.000Z
2020-12-13T05:10:35.000Z
"""PRAW exception classes. Includes two main exceptions: :class:`.RedditAPIException` for when something goes wrong on the server side, and :class:`.ClientException` when something goes wrong on the client side. Both of these classes extend :class:`.PRAWException`. All other exceptions are subclassed from :class:`.Cl...
34.209386
123
0.633917
"""PRAW exception classes. Includes two main exceptions: :class:`.RedditAPIException` for when something goes wrong on the server side, and :class:`.ClientException` when something goes wrong on the client side. Both of these classes extend :class:`.PRAWException`. All other exceptions are subclassed from :class:`.Cl...
565
0
79
89046272d87a83b82a67a3e619887f60e1f0fabc
1,927
py
Python
GC/Tareas/T3/manejoMatrices.py
BenchHPZ/UG-Compu
fa3551a862ee04b59a5ba97a791f39a77ce2df60
[ "MIT" ]
null
null
null
GC/Tareas/T3/manejoMatrices.py
BenchHPZ/UG-Compu
fa3551a862ee04b59a5ba97a791f39a77ce2df60
[ "MIT" ]
null
null
null
GC/Tareas/T3/manejoMatrices.py
BenchHPZ/UG-Compu
fa3551a862ee04b59a5ba97a791f39a77ce2df60
[ "MIT" ]
null
null
null
""" Modulo para manejo de matrices de transformadas. """ from OpenGL.GL import * from functools import wraps # Decorador para mantener orden en matriz def matriz_propia(fun): """ Funcion para manejar espacios de matriz de OpenGL. La funcion que sea recibida por el decorador espera manejar matrices de tr...
27.927536
61
0.631033
""" Modulo para manejo de matrices de transformadas. """ from OpenGL.GL import * from functools import wraps # Decorador para mantener orden en matriz def matriz_propia(fun): """ Funcion para manejar espacios de matriz de OpenGL. La funcion que sea recibida por el decorador espera manejar matrices de tr...
507
0
188
ced5ec306c4708726849d200dff4bf825420a0df
1,940
py
Python
blitzortung/dataimport/raw_signal.py
wuan/bo-python
86c90e437ff456092bf7c9eff8c85daffdd220f0
[ "Apache-2.0" ]
3
2015-04-09T22:33:59.000Z
2019-02-12T12:52:16.000Z
blitzortung/dataimport/raw_signal.py
wuan/bo-python
86c90e437ff456092bf7c9eff8c85daffdd220f0
[ "Apache-2.0" ]
7
2015-05-23T13:38:14.000Z
2019-12-13T20:43:12.000Z
blitzortung/dataimport/raw_signal.py
wuan/bo-python
86c90e437ff456092bf7c9eff8c85daffdd220f0
[ "Apache-2.0" ]
4
2015-12-13T12:40:40.000Z
2021-07-09T10:48:16.000Z
# -*- coding: utf8 -*- """ Copyright 2014-2016 Andreas Würl 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 ap...
34.642857
111
0.702062
# -*- coding: utf8 -*- """ Copyright 2014-2016 Andreas Würl 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 ap...
972
134
22
3127bd6e0651a7e8bc8ceca470600eca8782379d
1,914
py
Python
direct/src/distributed/StagedObject.py
cmarshall108/panda3d-python3
8bea2c0c120b03ec1c9fd179701fdeb7510bb97b
[ "PHP-3.0", "PHP-3.01" ]
3
2020-01-02T08:43:36.000Z
2020-07-05T08:59:02.000Z
direct/src/distributed/StagedObject.py
cmarshall108/panda3d-python3
8bea2c0c120b03ec1c9fd179701fdeb7510bb97b
[ "PHP-3.0", "PHP-3.01" ]
20
2021-05-03T18:02:23.000Z
2022-03-12T12:01:04.000Z
Lib/site-packages/direct/distributed/StagedObject.py
fochoao/cpython
3dc84b260e5bced65ebc2c45c40c8fa65f9b5aa9
[ "bzip2-1.0.6", "0BSD" ]
1
2021-04-09T00:02:59.000Z
2021-04-09T00:02:59.000Z
class StagedObject: """ Use this class as a mixin to provide an interface for onStage/offStage objects. The idea here is that a DistributedObject could be present and active due to simple visibility, but we want to hide or otherwise disable it for some reason. """ UNKNOWN = -1 OFF = 0...
29.446154
83
0.61024
class StagedObject: """ Use this class as a mixin to provide an interface for onStage/offStage objects. The idea here is that a DistributedObject could be present and active due to simple visibility, but we want to hide or otherwise disable it for some reason. """ UNKNOWN = -1 OFF = 0...
94
0
54
3645603ad6f0fd55309e78f9e8fef65537843d6a
1,344
py
Python
archiveur.py
leximpact/tweet-archiveur
5792862b632012be0517445c77b76b87c2720c5e
[ "Apache-2.0" ]
1
2021-03-19T15:36:48.000Z
2021-03-19T15:36:48.000Z
archiveur.py
leximpact/tweet-archiveur
5792862b632012be0517445c77b76b87c2720c5e
[ "Apache-2.0" ]
null
null
null
archiveur.py
leximpact/tweet-archiveur
5792862b632012be0517445c77b76b87c2720c5e
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/python from tweet_archiveur.scrapper import Scrapper from tweet_archiveur.database import Database import pandas as pd from os import getenv from dotenv import load_dotenv from pathlib import Path from sys import exit import logging import time import tweepy import random # Logging logger = logging.getLogg...
27.428571
90
0.756696
#!/usr/bin/python from tweet_archiveur.scrapper import Scrapper from tweet_archiveur.database import Database import pandas as pd from os import getenv from dotenv import load_dotenv from pathlib import Path from sys import exit import logging import time import tweepy import random # Logging logger = logging.getLogg...
0
0
0
ca5bbe1512658899deeca8004f0493770fe0bcd9
2,996
py
Python
lib/service/AthleteData.py
SportsToken/ae_dapp
8547a35d7d08bbef86483b170804f8961234642c
[ "MIT" ]
4
2021-08-17T02:25:42.000Z
2022-01-26T17:10:43.000Z
lib/service/AthleteData.py
SportsToken/ax_dapp
b99d923b698f25b2579b9a78dca18394ac9c238c
[ "MIT" ]
136
2021-08-12T19:33:03.000Z
2022-03-10T21:15:26.000Z
lib/service/AthleteData.py
SportsToken/ae_dapp
8547a35d7d08bbef86483b170804f8961234642c
[ "MIT" ]
null
null
null
import requests import json import re # from requests.sessions import _TextMapping ATHLETES = [] with open('../../assets/nflAthletes.json', 'r') as athFile: data = athFile.read() athJson = json.loads(data) # list of abbreviated names active_list = [] id_list = [] for ath in athJson: id_list.append(ath['id...
29.96
330
0.594793
import requests import json import re # from requests.sessions import _TextMapping ATHLETES = [] with open('../../assets/nflAthletes.json', 'r') as athFile: data = athFile.read() athJson = json.loads(data) # list of abbreviated names active_list = [] id_list = [] for ath in athJson: id_list.append(ath['id...
667
-5
76
d4fbf059031d5a37cd870c360fddc7dca01256be
3,278
py
Python
tests/security/test_image.py
xianfang-qian/docker_ci
0ff773d1e7d9420ef6a05a63bc56b32952b71192
[ "Apache-2.0" ]
35
2020-10-11T07:39:42.000Z
2022-03-20T06:17:08.000Z
tests/security/test_image.py
xianfang-qian/docker_ci
0ff773d1e7d9420ef6a05a63bc56b32952b71192
[ "Apache-2.0" ]
32
2020-10-13T06:58:20.000Z
2022-02-10T04:34:03.000Z
tests/security/test_image.py
xianfang-qian/docker_ci
0ff773d1e7d9420ef6a05a63bc56b32952b71192
[ "Apache-2.0" ]
39
2020-10-07T07:22:20.000Z
2022-03-14T18:21:56.000Z
# -*- coding: utf-8 -*- # Copyright (C) 2019-2021 Intel Corporation # SPDX-License-Identifier: Apache-2.0 import pathlib import subprocess # nosec import sys import pytest from setup import SNYK_API, SNYK_TOKEN from utils.loader import SNYK_URL from utils.utilities import download_file
51.21875
118
0.603722
# -*- coding: utf-8 -*- # Copyright (C) 2019-2021 Intel Corporation # SPDX-License-Identifier: Apache-2.0 import pathlib import subprocess # nosec import sys import pytest from setup import SNYK_API, SNYK_TOKEN from utils.loader import SNYK_URL from utils.utilities import download_file class TestSDLImage: @pyt...
2,153
811
23
a2721b26bb01173ae62233042661b3f309e05fe2
8,960
py
Python
py_proto/modules/prediction/proto/prediction_conf_pb2.py
yujianyi/fusion_localization
c0057e29cbf690d6260f021080fd951c1a6b6baa
[ "Apache-2.0" ]
2
2019-03-04T02:11:04.000Z
2019-04-18T11:19:45.000Z
py_proto/modules/prediction/proto/prediction_conf_pb2.py
yujianyi/fusion_localization
c0057e29cbf690d6260f021080fd951c1a6b6baa
[ "Apache-2.0" ]
1
2019-03-15T08:37:53.000Z
2019-03-15T08:37:53.000Z
py_proto/modules/prediction/proto/prediction_conf_pb2.py
yujianyi/fusion_localization
c0057e29cbf690d6260f021080fd951c1a6b6baa
[ "Apache-2.0" ]
1
2019-03-04T02:11:09.000Z
2019-03-04T02:11:09.000Z
# Generated by the protocol buffer compiler. DO NOT EDIT! # source: modules/prediction/proto/prediction_conf.proto import sys _b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.pro...
37.805907
1,217
0.766853
# Generated by the protocol buffer compiler. DO NOT EDIT! # source: modules/prediction/proto/prediction_conf.proto import sys _b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.pro...
0
0
0
75cd32ba7e2545516e050e308b4e8da06031672a
702
py
Python
scripts/console_commands.py
iamHarin17/Core
9ad22f97ae0dc2d9e0ae60528bd0c7b14999a306
[ "MIT" ]
null
null
null
scripts/console_commands.py
iamHarin17/Core
9ad22f97ae0dc2d9e0ae60528bd0c7b14999a306
[ "MIT" ]
null
null
null
scripts/console_commands.py
iamHarin17/Core
9ad22f97ae0dc2d9e0ae60528bd0c7b14999a306
[ "MIT" ]
null
null
null
import argparse from os import path from distutils.dir_util import copy_tree TEMPLATE_PATH = "core/conf/projct_template"
29.25
59
0.64245
import argparse from os import path from distutils.dir_util import copy_tree TEMPLATE_PATH = "core/conf/projct_template" def main(): parser = argparse.ArgumentParser() parser.add_argument('operation', type=str, nargs='+', help='project managment commands') args = parser.parse_args...
522
0
58
9d1eecec7500a32df6d5b5a44ca84f94d4f574d8
4,314
py
Python
models/cnnlstm.py
Keiku/PyTorch-Lightning-Video-Classification
72ed3c1606fe0657af267399fc32f1df59eca8ec
[ "MIT" ]
5
2021-05-03T09:14:28.000Z
2022-02-24T07:42:57.000Z
models/cnnlstm.py
Keiku/PyTorch-Lightning-Video-Classification
72ed3c1606fe0657af267399fc32f1df59eca8ec
[ "MIT" ]
1
2022-01-04T02:33:02.000Z
2022-01-05T03:58:13.000Z
models.py
Keiku/Action-Recognition-CNN-LSTM
004e4442d4a0e6a527396f279677c4d10cf92cbe
[ "MIT" ]
null
null
null
import numpy as np import torch import torch.nn as nn import torch.nn.functional as F from torch.autograd import Variable from torchvision.models import resnet152
33.184615
85
0.597357
import numpy as np import torch import torch.nn as nn import torch.nn.functional as F from torch.autograd import Variable from torchvision.models import resnet152 class Encoder(nn.Module): def __init__(self, latent_dim): super(Encoder, self).__init__() resnet = resnet152(pretrained=True) s...
3,713
26
407
bdc33f192eb9520c77c9ba2ada5a552209ec4fd1
871
py
Python
setup.py
dbeley/FIP_lastfm_mirror
9561c233c0733a77a1ad59994e5792b52df76966
[ "MIT" ]
null
null
null
setup.py
dbeley/FIP_lastfm_mirror
9561c233c0733a77a1ad59994e5792b52df76966
[ "MIT" ]
1
2021-06-02T00:02:42.000Z
2021-06-02T00:02:42.000Z
setup.py
dbeley/FIP_lastfm_mirror
9561c233c0733a77a1ad59994e5792b52df76966
[ "MIT" ]
null
null
null
import setuptools import FIP_mirror with open("README.md", "r") as fh: long_description = fh.read() setuptools.setup( name="FIP_mirror", version=FIP_mirror.__version__, author="dbeley", author_email="dbeley@protonmail.com", description="Mirror the FIP webradios on several services.", long_...
27.21875
78
0.65442
import setuptools import FIP_mirror with open("README.md", "r") as fh: long_description = fh.read() setuptools.setup( name="FIP_mirror", version=FIP_mirror.__version__, author="dbeley", author_email="dbeley@protonmail.com", description="Mirror the FIP webradios on several services.", long_...
0
0
0
f63d872765b825c67b81518415277301754d214c
109
py
Python
achievements/settings.example.py
seLain/MissAchieve
e65ecf46d3c35b79151d526d0b0abce7b55a6652
[ "MIT" ]
null
null
null
achievements/settings.example.py
seLain/MissAchieve
e65ecf46d3c35b79151d526d0b0abce7b55a6652
[ "MIT" ]
7
2018-03-29T05:38:46.000Z
2021-06-10T20:09:49.000Z
achievements/settings.example.py
seLain/MissAchieve
e65ecf46d3c35b79151d526d0b0abce7b55a6652
[ "MIT" ]
null
null
null
""" Settings for achievements app. """ DEFAULT_ADMIN = '' DEFAULT_ADMIN_PASSWORD = '' DEFAULT_ADMIN_MAIL = ''
18.166667
30
0.724771
""" Settings for achievements app. """ DEFAULT_ADMIN = '' DEFAULT_ADMIN_PASSWORD = '' DEFAULT_ADMIN_MAIL = ''
0
0
0
3612bd57a165c25e66b5ce2e5f7f7966a9f8d5db
17,209
py
Python
flexmeasures/data/migrations/versions/6cf5b241b85f_copy_attributes_from_old_data_models_to_GenericAsset.py
FlexMeasures/flexmeasures
a4367976d37ac5721b8eb3ce8a2414595e52c678
[ "Apache-2.0" ]
12
2021-12-18T10:41:10.000Z
2022-03-29T23:00:29.000Z
flexmeasures/data/migrations/versions/6cf5b241b85f_copy_attributes_from_old_data_models_to_GenericAsset.py
FlexMeasures/flexmeasures
a4367976d37ac5721b8eb3ce8a2414595e52c678
[ "Apache-2.0" ]
103
2021-12-07T08:51:15.000Z
2022-03-31T13:28:48.000Z
flexmeasures/data/migrations/versions/6cf5b241b85f_copy_attributes_from_old_data_models_to_GenericAsset.py
FlexMeasures/flexmeasures
a4367976d37ac5721b8eb3ce8a2414595e52c678
[ "Apache-2.0" ]
3
2022-01-18T04:45:48.000Z
2022-03-14T09:48:22.000Z
"""Copy attributes from old data models to GenericAsset Revision ID: 6cf5b241b85f Revises: 1ae32ffc8c3f Create Date: 2021-11-11 17:18:15.395915 """ import json from datetime import datetime from alembic import op import sqlalchemy as sa # revision identifiers, used by Alembic. revision = "6cf5b241b85f" down_revisi...
34.009881
154
0.590505
"""Copy attributes from old data models to GenericAsset Revision ID: 6cf5b241b85f Revises: 1ae32ffc8c3f Create Date: 2021-11-11 17:18:15.395915 """ import json from datetime import datetime from alembic import op import sqlalchemy as sa # revision identifiers, used by Alembic. revision = "6cf5b241b85f" down_revisi...
1,920
0
69
34baf8bbf78edbbaa51c950b55c38d254daf2326
1,817
py
Python
models/network.py
cristyioan2000/mask_classification
f5451c18864eb60c7642614df62dcae9f0983910
[ "MIT" ]
null
null
null
models/network.py
cristyioan2000/mask_classification
f5451c18864eb60c7642614df62dcae9f0983910
[ "MIT" ]
null
null
null
models/network.py
cristyioan2000/mask_classification
f5451c18864eb60c7642614df62dcae9f0983910
[ "MIT" ]
null
null
null
import torch.nn as nn import torch from utils.model_utils import init_model from torchsummary import summary if __name__ == "__main___": __main__()
27.530303
97
0.606494
import torch.nn as nn import torch from utils.model_utils import init_model from torchsummary import summary class Network_v1(nn.Module): def __init__(self): super(Network_v1,self).__init__() # Define layers self.conv1 = nn.Conv2d(in_channels=3,out_channels=64,kernel_size=5,stride=1,paddin...
1,559
7
98
753cdda1822c89409e246fde61a373b297af8a46
716
py
Python
setup.py
yangjiaronga/acmclient
d0e35cb2f711276df965bb8bf6e27b8ee33af729
[ "MIT" ]
2
2018-08-22T03:38:47.000Z
2018-08-30T07:56:56.000Z
setup.py
yangjiaronga/acmclient
d0e35cb2f711276df965bb8bf6e27b8ee33af729
[ "MIT" ]
null
null
null
setup.py
yangjiaronga/acmclient
d0e35cb2f711276df965bb8bf6e27b8ee33af729
[ "MIT" ]
2
2018-08-22T02:54:10.000Z
2018-08-30T03:59:35.000Z
from setuptools import find_packages, setup setup( name='acmclient', version="0.2", url='https://github.com/yangjiaronga/acmclient/', license='MIT', author='yangjiaronga', author_email='yangjiaronga@gmail.com', description='Aliyun acm client for Python', packages=find_packages(), i...
28.64
53
0.614525
from setuptools import find_packages, setup setup( name='acmclient', version="0.2", url='https://github.com/yangjiaronga/acmclient/', license='MIT', author='yangjiaronga', author_email='yangjiaronga@gmail.com', description='Aliyun acm client for Python', packages=find_packages(), i...
0
0
0
3d3ab17c34f53c838d4829ba2f2b0e468547c454
1,439
py
Python
test/iter_test.py
TomNicholas/experi
5d1c1a76fff9cca3009052093ed66dccd675ba7d
[ "MIT" ]
4
2018-06-26T07:31:46.000Z
2020-05-09T20:22:32.000Z
test/iter_test.py
TomNicholas/experi
5d1c1a76fff9cca3009052093ed66dccd675ba7d
[ "MIT" ]
131
2018-02-01T23:41:13.000Z
2021-07-01T19:24:59.000Z
test/iter_test.py
TomNicholas/experi
5d1c1a76fff9cca3009052093ed66dccd675ba7d
[ "MIT" ]
1
2018-11-11T16:11:35.000Z
2018-11-11T16:11:35.000Z
#! /usr/bin/env python # -*- coding: utf-8 -*- # vim:fenc=utf-8 # # Copyright © 2018 Malcolm Ramsay <malramsay64@gmail.com> # # Distributed under terms of the MIT license. """Test the behaviour of the looping through variables. This is a series of tests that are defining the interface of the module, primarily the ite...
29.367347
85
0.694927
#! /usr/bin/env python # -*- coding: utf-8 -*- # vim:fenc=utf-8 # # Copyright © 2018 Malcolm Ramsay <malramsay64@gmail.com> # # Distributed under terms of the MIT license. """Test the behaviour of the looping through variables. This is a series of tests that are defining the interface of the module, primarily the ite...
682
0
22
33803abf582abfd6fde5759fb4893b79e81960e2
1,067
py
Python
color.py
roukaour/sudoku
f405f627b49b7400c8b41c36194d99ef4b6b179e
[ "MIT" ]
7
2015-09-30T19:09:29.000Z
2022-03-26T05:51:18.000Z
color.py
roukaour/sudoku
f405f627b49b7400c8b41c36194d99ef4b6b179e
[ "MIT" ]
1
2018-07-10T18:31:45.000Z
2018-07-11T01:32:11.000Z
color.py
roukaour/sudoku
f405f627b49b7400c8b41c36194d99ef4b6b179e
[ "MIT" ]
2
2019-06-26T11:37:31.000Z
2020-06-27T07:55:08.000Z
from __future__ import print_function import sys class Color(object): """A printable and mixable color.""" # A dictionary of all colors, keyed by their numeric value colors = {} Color.NEITHER = Color(0, 'neither', '0') Color.RED = Color(1, 'red', '31;1') Color.BLUE = Color(~1, 'blue', '44') Color.PURPLE = Color(...
21.77551
65
0.661668
from __future__ import print_function import sys class Color(object): """A printable and mixable color.""" # A dictionary of all colors, keyed by their numeric value colors = {} def __init__(self, value, name, code): self.value = value self.name = name self.code = code Color.colors[value] = self def _...
452
0
192
75d811438e14d3516cdf78eb9221e1f32cc3f8f3
9,326
py
Python
powerlibs/gdal/utils/gdal2tiles/gdal2tiles.py
DroneMapp/powerlibs-gdal-utils
eb1714c240c995868d0ac4d3dbe8ae20bdf401b7
[ "MIT" ]
null
null
null
powerlibs/gdal/utils/gdal2tiles/gdal2tiles.py
DroneMapp/powerlibs-gdal-utils
eb1714c240c995868d0ac4d3dbe8ae20bdf401b7
[ "MIT" ]
null
null
null
powerlibs/gdal/utils/gdal2tiles/gdal2tiles.py
DroneMapp/powerlibs-gdal-utils
eb1714c240c995868d0ac4d3dbe8ae20bdf401b7
[ "MIT" ]
1
2021-05-24T14:34:40.000Z
2021-05-24T14:34:40.000Z
from pathlib import PosixPath import numpy from osgeo import gdal from osgeo import osr from .image_output import SimpleImageOutput from .resampler import get_resampler from .utils import ensure_dir_exists, gdal_write
35.460076
89
0.581064
from pathlib import PosixPath import numpy from osgeo import gdal from osgeo import osr from .image_output import SimpleImageOutput from .resampler import get_resampler from .utils import ensure_dir_exists, gdal_write class GDAL2Tiles: def __init__( self, source_path, output_dir, ...
6,323
2,759
23
58d7874e2071ed69f4f866554b981b6b71c80653
15,976
py
Python
xlsxwriter/test/styles/test_write_xf_methods.py
DeltaEpsilon7787/XlsxWriter
550b9c5bd678c861dcc9f6f4072b33a69566e065
[ "BSD-2-Clause-FreeBSD" ]
2,766
2015-01-02T17:36:42.000Z
2022-03-31T09:23:30.000Z
xlsxwriter/test/styles/test_write_xf_methods.py
DeltaEpsilon7787/XlsxWriter
550b9c5bd678c861dcc9f6f4072b33a69566e065
[ "BSD-2-Clause-FreeBSD" ]
683
2015-01-03T09:55:02.000Z
2022-03-31T07:18:15.000Z
xlsxwriter/test/styles/test_write_xf_methods.py
jmcnamara/test_py_github_actions
d445d5d98b038b63453dd70c9c1a9ca1b325cb47
[ "BSD-2-Clause-FreeBSD" ]
636
2015-01-05T01:57:08.000Z
2022-03-25T18:42:41.000Z
############################################################################### # # Tests for XlsxWriter. # # Copyright (c), 2013-2021, John McNamara, jmcnamara@cpan.org # import unittest from io import StringIO from ...styles import Styles from ...format import Format class TestWriteXf(unittest.TestCase): """ ...
31.824701
191
0.607223
############################################################################### # # Tests for XlsxWriter. # # Copyright (c), 2013-2021, John McNamara, jmcnamara@cpan.org # import unittest from io import StringIO from ...styles import Styles from ...format import Format class TestWriteXf(unittest.TestCase): """ ...
100
0
27
0ae883536fe83d78c8c4581559039a3ac14f939f
10,202
py
Python
auscophub/saraclient.py
CopernicusAustralasia/auscophub
d7e2974898bb3ee9b262281fbd663326c1c48d05
[ "MIT" ]
4
2020-01-25T02:01:49.000Z
2021-06-21T08:38:18.000Z
auscophub/saraclient.py
CopernicusAustralasia/auscophub
d7e2974898bb3ee9b262281fbd663326c1c48d05
[ "MIT" ]
null
null
null
auscophub/saraclient.py
CopernicusAustralasia/auscophub
d7e2974898bb3ee9b262281fbd663326c1c48d05
[ "MIT" ]
null
null
null
""" Functions for interface to the SARA client API. These routines can be used to build client-side applications for searching and downloading data. The most obvious way to use these routines is as follows:: urlOpener = saraclient.makeUrlOpener() sentinel = 2 paramList = ['startDate=2017-05-01', 'comp...
38.790875
97
0.685846
""" Functions for interface to the SARA client API. These routines can be used to build client-side applications for searching and downloading data. The most obvious way to use these routines is as follows:: urlOpener = saraclient.makeUrlOpener() sentinel = 2 paramList = ['startDate=2017-05-01', 'comp...
0
17
23
2ba1a6712dd4c0afededa3165d1286b86bf017a5
87,967
py
Python
dynamo/preprocessing/preprocess.py
aristoteleo/dynamo-release
841b5f1ba0d0e9d0ae75ff71e764828a7051d462
[ "BSD-3-Clause" ]
236
2019-07-09T22:06:21.000Z
2022-03-31T17:56:07.000Z
dynamo/preprocessing/preprocess.py
crsky1023/dynamo-release
793ea493b5fbcfece00c249493ee222fa128c774
[ "BSD-3-Clause" ]
115
2019-07-12T19:06:21.000Z
2022-03-31T17:34:18.000Z
dynamo/preprocessing/preprocess.py
crsky1023/dynamo-release
793ea493b5fbcfece00c249493ee222fa128c774
[ "BSD-3-Clause" ]
34
2019-07-10T03:34:04.000Z
2022-03-22T12:44:22.000Z
from collections.abc import Iterable import numpy as np import pandas as pd import warnings from scipy.sparse import issparse, csr_matrix from sklearn.decomposition import FastICA from sklearn.utils import sparsefuncs import anndata from anndata import AnnData from typing import Optional, Union, Callable from .cell_cy...
41.260319
136
0.608103
from collections.abc import Iterable import numpy as np import pandas as pd import warnings from scipy.sparse import issparse, csr_matrix from sklearn.decomposition import FastICA from sklearn.utils import sparsefuncs import anndata from anndata import AnnData from typing import Optional, Union, Callable from .cell_cy...
1,248
0
85
3b17915f53675b5765c797b62c7412f0773696a8
2,124
py
Python
equations/CO2_fluxes.py
Trung-Hieu-Tran/CEAOS
916c0d186fed0ac827ed3f5dc8ad50fe056154bb
[ "MIT" ]
null
null
null
equations/CO2_fluxes.py
Trung-Hieu-Tran/CEAOS
916c0d186fed0ac827ed3f5dc8ad50fe056154bb
[ "MIT" ]
null
null
null
equations/CO2_fluxes.py
Trung-Hieu-Tran/CEAOS
916c0d186fed0ac827ed3f5dc8ad50fe056154bb
[ "MIT" ]
null
null
null
from coefficients import Coefficients, Constants from data_models import States, Setpoints, Weather from equations.utils import total_side_vents_ventilation_rates, total_roof_ventilation_rates, \ thermal_screen_air_flux_rate from equations.heat_fluxes import sensible_heat_flux_between_direct_air_heater_and_greenhou...
41.647059
109
0.80791
from coefficients import Coefficients, Constants from data_models import States, Setpoints, Weather from equations.utils import total_side_vents_ventilation_rates, total_roof_ventilation_rates, \ thermal_screen_air_flux_rate from equations.heat_fluxes import sensible_heat_flux_between_direct_air_heater_and_greenhou...
1,653
0
138
bfdd1b0704c3900d4fdd972910d23989016b822e
9,020
py
Python
cosmos/construct_caption_tables/construct.py
hadarohana/myCosmos
6e4682a2af822eb828180658aaa6d3e304cc85bf
[ "Apache-2.0" ]
null
null
null
cosmos/construct_caption_tables/construct.py
hadarohana/myCosmos
6e4682a2af822eb828180658aaa6d3e304cc85bf
[ "Apache-2.0" ]
5
2020-01-28T23:13:10.000Z
2022-02-10T00:28:15.000Z
cosmos/construct_caption_tables/construct.py
hadarohana/myCosmos
6e4682a2af822eb828180658aaa6d3e304cc85bf
[ "Apache-2.0" ]
1
2021-03-10T19:25:44.000Z
2021-03-10T19:25:44.000Z
""" Construct csvs for Figure--Figure Captions/ Tables -- Table Captions """ from lxml import etree import os from Parser.parse_preprocess import get_words_from_child as get_words from converters.html2xml import htmlfile2xml from converters.xml2list import xml2list import pandas as pd import multiprocessing as mp impo...
40.267857
153
0.611197
""" Construct csvs for Figure--Figure Captions/ Tables -- Table Captions """ from lxml import etree import os from Parser.parse_preprocess import get_words_from_child as get_words from converters.html2xml import htmlfile2xml from converters.xml2list import xml2list import pandas as pd import multiprocessing as mp impo...
382
0
83
4b5f6671ad6ba6bc14117e33a89d780d24c6e735
629
py
Python
exasol_integration_test_docker_environment/test/test_find_free_port.py
exasol/integration-test-docker-environment
35850f67cd4cde010f03dd556d1a0f74b3291eb8
[ "MIT" ]
4
2020-06-25T20:47:31.000Z
2021-09-10T15:22:51.000Z
exasol_integration_test_docker_environment/test/test_find_free_port.py
exasol/integration-test-docker-environment
35850f67cd4cde010f03dd556d1a0f74b3291eb8
[ "MIT" ]
113
2020-06-02T08:51:08.000Z
2022-03-31T08:47:41.000Z
exasol_integration_test_docker_environment/test/test_find_free_port.py
exasol/integration-test-docker-environment
35850f67cd4cde010f03dd556d1a0f74b3291eb8
[ "MIT" ]
2
2020-05-19T10:57:47.000Z
2020-06-22T13:32:20.000Z
import unittest from exasol_integration_test_docker_environment.testing.utils import find_free_ports if __name__ == '__main__': unittest.main()
26.208333
84
0.680445
import unittest from exasol_integration_test_docker_environment.testing.utils import find_free_ports class FindFreePortTest(unittest.TestCase): def run_it(self, num_ports: int): ports = find_free_ports(num_ports) self.assertNotIn(0, ports) self.assertEqual(len(ports), num_ports) ...
379
21
77
37e7b4a58f2b5753a7f59640dc32a76aa6573b75
5,335
py
Python
contrib/android/tests/python/pants_test/contrib/android/test_android_base.py
lahosken/pants
1b0340987c9b2eab9411416803c75b80736716e4
[ "Apache-2.0" ]
1
2021-11-11T14:04:24.000Z
2021-11-11T14:04:24.000Z
contrib/android/tests/python/pants_test/contrib/android/test_android_base.py
lahosken/pants
1b0340987c9b2eab9411416803c75b80736716e4
[ "Apache-2.0" ]
null
null
null
contrib/android/tests/python/pants_test/contrib/android/test_android_base.py
lahosken/pants
1b0340987c9b2eab9411416803c75b80736716e4
[ "Apache-2.0" ]
1
2021-11-11T14:04:12.000Z
2021-11-11T14:04:12.000Z
# coding=utf-8 # Copyright 2014 Pants project contributors (see CONTRIBUTORS.md). # Licensed under the Apache License, Version 2.0 (see LICENSE). from __future__ import (absolute_import, division, generators, nested_scopes, print_function, unicode_literals, with_statement) import os import tex...
38.65942
100
0.652296
# coding=utf-8 # Copyright 2014 Pants project contributors (see CONTRIBUTORS.md). # Licensed under the Apache License, Version 2.0 (see LICENSE). from __future__ import (absolute_import, division, generators, nested_scopes, print_function, unicode_literals, with_statement) import os import tex...
0
0
0
ac71c80abca4e11319ef2d6387bdf0e57e982db3
3,539
py
Python
src/SmallNet.py
aponamarev/FootBallTracking
a1907164aa35fe925b2a11a1c596c1a489b90231
[ "MIT" ]
null
null
null
src/SmallNet.py
aponamarev/FootBallTracking
a1907164aa35fe925b2a11a1c596c1a489b90231
[ "MIT" ]
null
null
null
src/SmallNet.py
aponamarev/FootBallTracking
a1907164aa35fe925b2a11a1c596c1a489b90231
[ "MIT" ]
null
null
null
#!/usr/bin/env python """ SmallNet.py is a class that provides a network for Person localization Created 6/13/17. """ __author__ = "Alexander Ponamarev" __email__ = "alex.ponamaryov@gmail.com" import tensorflow as tf from collections import namedtuple from tensorflow import name_scope, variable_scope, stop_gradient ...
38.053763
100
0.60356
#!/usr/bin/env python """ SmallNet.py is a class that provides a network for Person localization Created 6/13/17. """ __author__ = "Alexander Ponamarev" __email__ = "alex.ponamaryov@gmail.com" import tensorflow as tf from collections import namedtuple from tensorflow import name_scope, variable_scope, stop_gradient ...
3,038
14
77
3a3bfbf477153a99bd4a220d6c47d81694221478
22,557
py
Python
SRC/common/IO/GUI/gtklogger/gtklogger/replay.py
usnistgov/OOF3D
4fd423a48aea9c5dc207520f02de53ae184be74c
[ "X11" ]
31
2015-04-01T15:59:36.000Z
2022-03-18T20:21:47.000Z
SRC/common/IO/GUI/gtklogger/gtklogger/replay.py
usnistgov/OOF3D
4fd423a48aea9c5dc207520f02de53ae184be74c
[ "X11" ]
3
2015-02-06T19:30:24.000Z
2017-05-25T14:14:31.000Z
SRC/common/IO/GUI/gtklogger/gtklogger/replay.py
usnistgov/OOF3D
4fd423a48aea9c5dc207520f02de53ae184be74c
[ "X11" ]
7
2015-01-23T15:19:22.000Z
2021-06-09T09:03:59.000Z
# -*- python -*- # This software was produced by NIST, an agency of the U.S. government, # and by statute is not subject to copyright in the United States. # Recipients of this software assume all responsibilities associated # with its operation, modification and maintenance. However, to # facilitate maintenance we as...
43.130019
80
0.563461
# -*- python -*- # This software was produced by NIST, an agency of the U.S. government, # and by statute is not subject to copyright in the United States. # Recipients of this software assume all responsibilities associated # with its operation, modification and maintenance. However, to # facilitate maintenance we as...
18,413
320
1,006
ac9117f13e5f54a1cd8344368a45765ed96330b8
3,600
py
Python
tests/test_inventory/test_add_image_to_inventory_item.py
stcstores/linnapi
88cc1d73444f44b7d901dc1086790a300066ea6e
[ "MIT" ]
null
null
null
tests/test_inventory/test_add_image_to_inventory_item.py
stcstores/linnapi
88cc1d73444f44b7d901dc1086790a300066ea6e
[ "MIT" ]
null
null
null
tests/test_inventory/test_add_image_to_inventory_item.py
stcstores/linnapi
88cc1d73444f44b7d901dc1086790a300066ea6e
[ "MIT" ]
null
null
null
from unittest.mock import patch import pytest from linnapi import exceptions, inventory from linnapi.models import InventoryItemImage from linnapi.requests.inventory import AddImageToInventoryItem @pytest.fixture @pytest.fixture @pytest.fixture @pytest.fixture @pytest.fixture @pytest.fixture
28.346457
85
0.750278
from unittest.mock import patch import pytest from linnapi import exceptions, inventory from linnapi.models import InventoryItemImage from linnapi.requests.inventory import AddImageToInventoryItem @pytest.fixture def sku(): return "E32-99X-8G2" @pytest.fixture def stock_item_id(): return "972af264-d768-4c...
3,017
0
270
d8199a578b11aa9d10481a36e6942b751c2361cb
7,977
py
Python
qa/rpc-tests/electrum_transaction_get.py
gandrewstone/bitcoin
05de381c02eb4bfca94957733acadfa217527f25
[ "MIT" ]
535
2015-09-04T15:10:08.000Z
2022-03-17T20:51:05.000Z
qa/rpc-tests/electrum_transaction_get.py
gandrewstone/bitcoin
05de381c02eb4bfca94957733acadfa217527f25
[ "MIT" ]
1,269
2016-01-31T20:21:24.000Z
2022-03-16T01:20:08.000Z
qa/rpc-tests/electrum_transaction_get.py
gandrewstone/bitcoin
05de381c02eb4bfca94957733acadfa217527f25
[ "MIT" ]
295
2015-10-19T16:12:29.000Z
2021-08-02T20:05:17.000Z
#!/usr/bin/env python3 # Copyright (c) 2020 The Bitcoin Unlimited developers """ Tests the electrum call 'blockchain.transaction.get' """ import asyncio from test_framework.util import assert_equal, p2p_port from test_framework.electrumutil import ElectrumTestFramework, ElectrumConnection from test_framework.nodemessag...
38.912195
113
0.55121
#!/usr/bin/env python3 # Copyright (c) 2020 The Bitcoin Unlimited developers """ Tests the electrum call 'blockchain.transaction.get' """ import asyncio from test_framework.util import assert_equal, p2p_port from test_framework.electrumutil import ElectrumTestFramework, ElectrumConnection from test_framework.nodemessag...
6,129
1,013
23
8915b50a760df688402b47cae324268e702315b6
1,062
py
Python
233-Number-of-Digit-One/Python/Solution02.py
Eroica-cpp/LeetCode
07276bd11558f3d0e32bec768b09e886de145f9e
[ "CC-BY-3.0", "MIT" ]
7
2015-05-05T22:21:30.000Z
2021-03-13T04:04:15.000Z
233-Number-of-Digit-One/Python/Solution02.py
Eroica-cpp/LeetCode
07276bd11558f3d0e32bec768b09e886de145f9e
[ "CC-BY-3.0", "MIT" ]
null
null
null
233-Number-of-Digit-One/Python/Solution02.py
Eroica-cpp/LeetCode
07276bd11558f3d0e32bec768b09e886de145f9e
[ "CC-BY-3.0", "MIT" ]
2
2018-12-26T08:13:25.000Z
2020-07-18T20:18:24.000Z
#!/usr/bin/python """ ============================================================================== Author: Tao Li (taoli@ucsd.edu) Date: Jul 8, 2015 Question: 233-Number-of-Digit-One Link: https://leetcode.com/problems/number-of-digit-one/ ====================================================================...
33.1875
79
0.433145
#!/usr/bin/python """ ============================================================================== Author: Tao Li (taoli@ucsd.edu) Date: Jul 8, 2015 Question: 233-Number-of-Digit-One Link: https://leetcode.com/problems/number-of-digit-one/ ====================================================================...
180
-6
49
7d692475de01f8e179c2db79fa3131cc57a9d957
6,591
py
Python
mistraldashboard/actions/forms.py
openstack/mistral-dashboard
2980dfc44f11400c75a1113e468f50e7c6d6396c
[ "Apache-2.0" ]
18
2015-06-23T08:06:12.000Z
2019-07-18T10:32:17.000Z
mistraldashboard/actions/forms.py
stackforge/mistral-dashboard
2980dfc44f11400c75a1113e468f50e7c6d6396c
[ "Apache-2.0" ]
2
2016-06-03T15:20:20.000Z
2016-08-09T04:57:38.000Z
mistraldashboard/actions/forms.py
stackforge/mistral-dashboard
2980dfc44f11400c75a1113e468f50e7c6d6396c
[ "Apache-2.0" ]
9
2015-07-09T02:15:05.000Z
2021-06-14T09:25:15.000Z
# Copyright 2015 Huawei Technologies Co., Ltd. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed t...
33.8
75
0.573206
# Copyright 2015 Huawei Technologies Co., Ltd. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed t...
2,810
2,897
69
19f278dd7535c00bc9ebe8e0e1741188feae5439
6,695
py
Python
build_dataset.py
asyrovprog/cs230project
cc9aebe256393b39140f69a2f31d1e9688c1e3d4
[ "MIT" ]
1
2021-04-28T08:29:28.000Z
2021-04-28T08:29:28.000Z
build_dataset.py
asyrovprog/cs230project
cc9aebe256393b39140f69a2f31d1e9688c1e3d4
[ "MIT" ]
null
null
null
build_dataset.py
asyrovprog/cs230project
cc9aebe256393b39140f69a2f31d1e9688c1e3d4
[ "MIT" ]
1
2021-01-27T21:52:07.000Z
2021-01-27T21:52:07.000Z
"""Split the Urban 3D dataset into train/dev/test and splits each image to 256x256 sub-tiles. Original images have size (2048, 2048). We do not resize images, but split them into smaller images i.e. each input image divided into 64 256x256 images """ import argparse import os from pathlib import Path import skimage....
37.824859
167
0.6823
"""Split the Urban 3D dataset into train/dev/test and splits each image to 256x256 sub-tiles. Original images have size (2048, 2048). We do not resize images, but split them into smaller images i.e. each input image divided into 64 256x256 images """ import argparse import os from pathlib import Path import skimage....
2,910
0
184
2054415a49aef01461c7d34aa9921526cd007ccf
1,767
py
Python
Applications/RussianAlphabet/russian.py
abefrandsen/numerical_computing
90559f7c4f387885eb44ea7b1fa19bb602f496cb
[ "CC-BY-3.0" ]
null
null
null
Applications/RussianAlphabet/russian.py
abefrandsen/numerical_computing
90559f7c4f387885eb44ea7b1fa19bb602f496cb
[ "CC-BY-3.0" ]
null
null
null
Applications/RussianAlphabet/russian.py
abefrandsen/numerical_computing
90559f7c4f387885eb44ea7b1fa19bb602f496cb
[ "CC-BY-3.0" ]
1
2020-12-08T01:19:23.000Z
2020-12-08T01:19:23.000Z
import unicodedata import codecs import sys import scipy as sp import hmm tbl = dict.fromkeys(i for i in xrange(sys.maxunicode) if unicodedata.category(unichr(i)).startswith('P')) def uniq(listinput): """ This finds the unique elements of the list listinput. """ """ This will be provided for t...
28.967213
88
0.722694
import unicodedata import codecs import sys import scipy as sp import hmm tbl = dict.fromkeys(i for i in xrange(sys.maxunicode) if unicodedata.category(unichr(i)).startswith('P')) def uniq(listinput): """ This finds the unique elements of the list listinput. """ """ This will be provided for t...
1,202
0
138
e8c31869fab6d27bcdc5c8f62d3992e1c767f425
1,052
py
Python
song_classifier/reflection.py
tonywu7/nyu-nlp-spring21-final
1ace33dc2b9b6deef7f73c0d347dc6b5c74bd304
[ "Apache-2.0" ]
null
null
null
song_classifier/reflection.py
tonywu7/nyu-nlp-spring21-final
1ace33dc2b9b6deef7f73c0d347dc6b5c74bd304
[ "Apache-2.0" ]
null
null
null
song_classifier/reflection.py
tonywu7/nyu-nlp-spring21-final
1ace33dc2b9b6deef7f73c0d347dc6b5c74bd304
[ "Apache-2.0" ]
null
null
null
# Copyright 2021 Tony Wu +https://github.com/tonywu7/ # # 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 ...
36.275862
87
0.739544
# Copyright 2021 Tony Wu +https://github.com/tonywu7/ # # 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 ...
323
0
23
0fbd334600607aabad74ee93b3e4426a3cb8ef45
8,344
py
Python
mro/stages/analyzer/run_graph_clustering/__init__.py
qiangli/cellranger
046e24c3275cfbd4516a6ebc064594513a5c45b7
[ "MIT" ]
1
2019-03-29T04:05:58.000Z
2019-03-29T04:05:58.000Z
mro/stages/analyzer/run_graph_clustering/__init__.py
qiangli/cellranger
046e24c3275cfbd4516a6ebc064594513a5c45b7
[ "MIT" ]
null
null
null
mro/stages/analyzer/run_graph_clustering/__init__.py
qiangli/cellranger
046e24c3275cfbd4516a6ebc064594513a5c45b7
[ "MIT" ]
null
null
null
#!/usr/bin/env python # # Copyright (c) 2017 10X Genomics, Inc. All rights reserved. # import martian import numpy as np import sys import cellranger.analysis.clustering as cr_clustering import cellranger.analysis.graphclust as cr_graphclust import cellranger.analysis.io as analysis_io from cellranger.analysis.singlege...
38.275229
131
0.691275
#!/usr/bin/env python # # Copyright (c) 2017 10X Genomics, Inc. All rights reserved. # import martian import numpy as np import sys import cellranger.analysis.clustering as cr_clustering import cellranger.analysis.graphclust as cr_graphclust import cellranger.analysis.io as analysis_io from cellranger.analysis.singlege...
6,320
0
68
f5aeb1ef93a80b4d2f5780d60d6e9d527455fa80
475
py
Python
dimetric.py
BastiHz/dimetric
98feaca01bae8ca3e5019fc3722963843584b8c9
[ "Apache-2.0" ]
null
null
null
dimetric.py
BastiHz/dimetric
98feaca01bae8ca3e5019fc3722963843584b8c9
[ "Apache-2.0" ]
5
2020-08-17T17:39:40.000Z
2020-10-03T12:00:04.000Z
dimetric.py
BastiHz/dimetric
98feaca01bae8ca3e5019fc3722963843584b8c9
[ "Apache-2.0" ]
null
null
null
import os import logging logging.basicConfig( filename=".last_run.log", filemode="w", format="%(asctime)s %(levelname)s: %(message)s", level=logging.DEBUG ) # Must be done before importing Pygame: os.environ["PYGAME_HIDE_SUPPORT_PROMPT"] = "1" os.environ["SDL_VIDEO_CENTERED"] = "1" from src.game imp...
19.791667
52
0.675789
import os import logging logging.basicConfig( filename=".last_run.log", filemode="w", format="%(asctime)s %(levelname)s: %(message)s", level=logging.DEBUG ) # Must be done before importing Pygame: os.environ["PYGAME_HIDE_SUPPORT_PROMPT"] = "1" os.environ["SDL_VIDEO_CENTERED"] = "1" from src.game imp...
0
0
0
db3f35a2d1974ac6742727acfccf74a1839e665d
600
py
Python
apyce/io/__init__.py
mateustosta/apyce-project
5e2b82f3e74eb5a922146b796a12994d08a0f744
[ "BSD-3-Clause" ]
4
2021-04-02T04:12:27.000Z
2021-08-21T01:50:32.000Z
apyce/io/__init__.py
mateustosta/apyce-repo
5e2b82f3e74eb5a922146b796a12994d08a0f744
[ "BSD-3-Clause" ]
null
null
null
apyce/io/__init__.py
mateustosta/apyce-repo
5e2b82f3e74eb5a922146b796a12994d08a0f744
[ "BSD-3-Clause" ]
null
null
null
r""" **apyce.io** ---- This module contains functionality for exporting data to VTK ---- +----------------+------------------------------------------------------------+ | Format | Description | +================+================================================...
30
79
0.268333
r""" **apyce.io** ---- This module contains functionality for exporting data to VTK ---- +----------------+------------------------------------------------------------+ | Format | Description | +================+================================================...
0
0
0
6338a78c2ff7247add47ab1601fb205039c84418
502
py
Python
classes/Button.py
darssites/dars
f9f9322e65fdae53ddb98bf7ede5963c6f216d32
[ "Apache-2.0" ]
1
2017-02-04T18:29:16.000Z
2017-02-04T18:29:16.000Z
classes/Button.py
darssites/dars
f9f9322e65fdae53ddb98bf7ede5963c6f216d32
[ "Apache-2.0" ]
null
null
null
classes/Button.py
darssites/dars
f9f9322e65fdae53ddb98bf7ede5963c6f216d32
[ "Apache-2.0" ]
null
null
null
from utils import filter
22.818182
109
0.601594
from utils import filter class Button: text = "" onclick = "" href = "" def __init__(self, text, onclick="", href=""): self.text = filter.filter(text) self.onclick = onclick self.href = href def reparse(self): self.text = filter.filter(self.text) def getRaw(self): if self.href == "": return "<bu...
353
101
23
99463c982945df97a5194918e45b17a17224a910
4,184
py
Python
docx_to_json.py
CamzBarber/CameronBarber.com
0c07643e249a9d3361eede5c45a9dc5b008b6f8e
[ "MIT" ]
1
2018-09-23T15:59:58.000Z
2018-09-23T15:59:58.000Z
docx_to_json.py
CamzBarber/CameronBarber.com
0c07643e249a9d3361eede5c45a9dc5b008b6f8e
[ "MIT" ]
null
null
null
docx_to_json.py
CamzBarber/CameronBarber.com
0c07643e249a9d3361eede5c45a9dc5b008b6f8e
[ "MIT" ]
null
null
null
import docx import json import pyperclip # Concatenate role/company for keys below. # Order: URL, img, skills list # Read bullet points to check for skills. extra_info = { "IT Associate [Placement]PwC": [ "http://www.pwc.com/", "img/experience/pwc.jpeg", ["Python", "HTML5", "CSS3", "Bootst...
30.540146
284
0.508365
import docx import json import pyperclip # Concatenate role/company for keys below. # Order: URL, img, skills list # Read bullet points to check for skills. extra_info = { "IT Associate [Placement]PwC": [ "http://www.pwc.com/", "img/experience/pwc.jpeg", ["Python", "HTML5", "CSS3", "Bootst...
2,359
0
69
1448618a7b232dc43f18763973df4b308abeedc0
457
py
Python
users/migrations/0002_auto_20190704_1433.py
juliolugo96/projex-api
4bf12ce3ab228e43e7aa1b3d2d8972c1e4733a89
[ "MIT" ]
1
2019-05-31T04:40:09.000Z
2019-05-31T04:40:09.000Z
users/migrations/0002_auto_20190704_1433.py
juliolugo96/projex-api
4bf12ce3ab228e43e7aa1b3d2d8972c1e4733a89
[ "MIT" ]
4
2020-06-05T20:41:34.000Z
2021-09-08T00:58:10.000Z
users/migrations/0002_auto_20190704_1433.py
juliolugo96/projex-api
4bf12ce3ab228e43e7aa1b3d2d8972c1e4733a89
[ "MIT" ]
3
2019-05-31T04:40:04.000Z
2020-02-08T21:54:23.000Z
# Generated by Django 2.1.7 on 2019-07-04 14:33 from django.db import migrations, models import users.models
22.85
103
0.636761
# Generated by Django 2.1.7 on 2019-07-04 14:33 from django.db import migrations, models import users.models class Migration(migrations.Migration): dependencies = [ ('users', '0001_initial'), ] operations = [ migrations.AlterField( model_name='customuser', name='...
0
323
23
09c25006b2356a0bb3a734a4cfedff8c76091d67
411
py
Python
tests/test_menu_initialization.py
n4tm/PyAsteroids
88b6f277ea13f442960121e4d45bb4138ee49974
[ "MIT" ]
2
2021-10-15T19:02:27.000Z
2021-12-10T02:04:12.000Z
tests/test_menu_initialization.py
n4tm/PyAsteroids
88b6f277ea13f442960121e4d45bb4138ee49974
[ "MIT" ]
null
null
null
tests/test_menu_initialization.py
n4tm/PyAsteroids
88b6f277ea13f442960121e4d45bb4138ee49974
[ "MIT" ]
3
2021-01-26T21:35:43.000Z
2021-05-06T16:06:47.000Z
from os import path import pytest import menu import ufo import pygame @pytest.fixture
21.631579
52
0.76399
from os import path import pytest import menu import ufo import pygame @pytest.fixture def the_menu(): return menu.Menu() def test_ufo_image_path_finded(the_menu): the_menu.ufo = ufo.UFO(pygame.Vector2(0, 40), 2) assert path.exists(the_menu.ufo.sprite_path) def test_asteroids_image_path_finded(the_menu)...
254
0
68
59b9f49183c63c134b13f3ab197d7d519a61f8a6
695
py
Python
build/lib/vassal/scheduler.py
Shawn-Shan/vassal
dcb46bd8b36136e9b002d846f7a3464107a04f8d
[ "MIT" ]
4
2019-02-15T01:36:02.000Z
2021-06-11T15:38:58.000Z
build/lib/vassal/scheduler.py
Shawn-Shan/vassal
dcb46bd8b36136e9b002d846f7a3464107a04f8d
[ "MIT" ]
null
null
null
build/lib/vassal/scheduler.py
Shawn-Shan/vassal
dcb46bd8b36136e9b002d846f7a3464107a04f8d
[ "MIT" ]
1
2019-02-14T05:56:07.000Z
2019-02-14T05:56:07.000Z
import time
31.590909
108
0.548201
import time class Scheduler(object): def __init__(self, terminal, time_to_run=None, day=0, hour=0, min=0, sec=0): self.terminal = terminal self.day = day self.hour = hour self.min = min self.sec = sec self.time_to_run = time_to_run self.total_time = max(0.1,...
604
3
76
fe4976fec9b26ca0009bde09fe3e99f18fe048ee
1,169
py
Python
src/artifactcli/operation/__init__.py
arcizan/artifact-cli
1b4ddcd8bb3c32899fa385eefd128829c8cdd6e5
[ "Apache-2.0" ]
10
2015-01-11T14:43:57.000Z
2020-05-08T06:18:30.000Z
src/artifactcli/operation/__init__.py
arcizan/artifact-cli
1b4ddcd8bb3c32899fa385eefd128829c8cdd6e5
[ "Apache-2.0" ]
34
2015-01-04T17:37:54.000Z
2019-11-11T17:11:24.000Z
src/artifactcli/operation/__init__.py
arcizan/artifact-cli
1b4ddcd8bb3c32899fa385eefd128829c8cdd6e5
[ "Apache-2.0" ]
4
2015-01-11T07:05:33.000Z
2021-11-17T04:26:32.000Z
__all__ = [ 'HelpOperation', 'ListOperation', 'UploadOperation', 'DownloadOperation', 'InfoOperation', 'DeleteOperation', ] from .help import HelpOperation from .list import ListOperation from .upload import UploadOperation from .download import DownloadOperation from .info import InfoOperation ...
32.472222
87
0.696322
__all__ = [ 'HelpOperation', 'ListOperation', 'UploadOperation', 'DownloadOperation', 'InfoOperation', 'DeleteOperation', ] from .help import HelpOperation from .list import ListOperation from .upload import UploadOperation from .download import DownloadOperation from .info import InfoOperation ...
0
0
0
d94ac4c6a13dd5a87253bfb2d54a02964371911a
3,169
py
Python
torchlib/generative_model/autoencoder/aae/utils.py
vermouth1992/torchlib
63b2bedb40f670b2d9fbfc0daeab4a8d44623095
[ "MIT" ]
3
2019-07-23T21:32:36.000Z
2022-02-04T23:13:30.000Z
torchlib/generative_model/autoencoder/aae/utils.py
vermouth1992/torchlib
63b2bedb40f670b2d9fbfc0daeab4a8d44623095
[ "MIT" ]
null
null
null
torchlib/generative_model/autoencoder/aae/utils.py
vermouth1992/torchlib
63b2bedb40f670b2d9fbfc0daeab4a8d44623095
[ "MIT" ]
1
2019-07-23T21:32:23.000Z
2019-07-23T21:32:23.000Z
""" Utilities for AAE """ import torch from sklearn.manifold import TSNE from sklearn.decomposition import PCA from visdom import Visdom from ....common import FloatTensor class SampleImage(object): """ Make a grid and plot a class of image on one row """
32.670103
84
0.584727
""" Utilities for AAE """ import torch from sklearn.manifold import TSNE from sklearn.decomposition import PCA from visdom import Visdom from ....common import FloatTensor class SampleImage(object): """ Make a grid and plot a class of image on one row """ def __init__(self, n_row, n_col): self.n_row...
2,681
17
206
e3e29ab1ac785703839dbf6155470f174571a37d
7,740
py
Python
configs/fisheye_pig/mask_rcnn_r50_caffe_fpn_mstrain-poly_1x_all_pig_head_and_hip.py
leemengwei/my_mmdetection
be90a1da8b16154db5ad6847c2bc4b0545feece0
[ "Apache-2.0" ]
1
2021-09-07T13:05:38.000Z
2021-09-07T13:05:38.000Z
configs/fisheye_pig/mask_rcnn_r50_caffe_fpn_mstrain-poly_1x_all_pig_head_and_hip.py
leemengwei/my_mmdetection
be90a1da8b16154db5ad6847c2bc4b0545feece0
[ "Apache-2.0" ]
null
null
null
configs/fisheye_pig/mask_rcnn_r50_caffe_fpn_mstrain-poly_1x_all_pig_head_and_hip.py
leemengwei/my_mmdetection
be90a1da8b16154db5ad6847c2bc4b0545feece0
[ "Apache-2.0" ]
null
null
null
_base_ = '../mask_rcnn/mask_rcnn_r50_caffe_fpn_mstrain-poly_1x_coco.py' # We also need to change the num_classes in head to match the dataset's annotation classes=('pig', 'person', 'pig_head', 'pig_hip') # pig person 类分了也没法用,肯定不如专门分pig的分的准,所以不用这个的pig (目前pig类不能用,因为dorm中的pig在mask里) model = dict( roi_head=di...
36.857143
130
0.528295
_base_ = '../mask_rcnn/mask_rcnn_r50_caffe_fpn_mstrain-poly_1x_coco.py' # We also need to change the num_classes in head to match the dataset's annotation classes=('pig', 'person', 'pig_head', 'pig_hip') # pig person 类分了也没法用,肯定不如专门分pig的分的准,所以不用这个的pig (目前pig类不能用,因为dorm中的pig在mask里) model = dict( roi_head=di...
0
0
0
462351cf8874c79566eacf27e49fc93d3ee8cb1c
2,198
py
Python
src/code_submission/2_pasanju/models/nas_autograph_b.py
NehzUx/AutoGraph-KDDCup2020
d2fc228f4ccc5785db3129cca0445a80b6fef11d
[ "MIT" ]
1
2021-12-06T14:59:55.000Z
2021-12-06T14:59:55.000Z
src/code_submission/2_pasanju/models/nas_autograph_b.py
NehzUx/AutoGraph-Benchmark
d2fc228f4ccc5785db3129cca0445a80b6fef11d
[ "MIT" ]
null
null
null
src/code_submission/2_pasanju/models/nas_autograph_b.py
NehzUx/AutoGraph-Benchmark
d2fc228f4ccc5785db3129cca0445a80b6fef11d
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- # Created by HazzaCheng on 2020-05-11 import torch import torch.nn.functional as F from torch import nn from torch_geometric.nn import GATConv, ARMAConv, SAGEConv
37.896552
111
0.656961
#!/usr/bin/env python # -*- coding: utf-8 -*- # Created by HazzaCheng on 2020-05-11 import torch import torch.nn.functional as F from torch import nn from torch_geometric.nn import GATConv, ARMAConv, SAGEConv class NasAutoGraphB(nn.Module): def __init__(self, features_num, num_class, num_layers=2, dropout=0.5, h...
1,662
225
99
28f56cb5dd780d727233f51d0d8f8de5faa26db8
2,838
py
Python
blockchain/Blockchain.py
Adasumizox/crypto
45cb3cd19007a1b319efea20137a04a83afcf975
[ "MIT" ]
null
null
null
blockchain/Blockchain.py
Adasumizox/crypto
45cb3cd19007a1b319efea20137a04a83afcf975
[ "MIT" ]
null
null
null
blockchain/Blockchain.py
Adasumizox/crypto
45cb3cd19007a1b319efea20137a04a83afcf975
[ "MIT" ]
null
null
null
import time import blockchain.Transaction from blockchain.Block import Block
32.62069
104
0.614165
import time import blockchain.Transaction from blockchain.Block import Block class Blockchain: def __init__(self): self.unconfirmed_transactions = [] self.chain = [] self.create_genesis_block() def create_genesis_block(self) -> None: """ Method for creating first bloc...
594
2,143
23
ccae83714ad7cc962eb063c91b0e06cccee3c2c9
1,230
py
Python
predict.py
schuangs/Satellite-Orbit-Prediction
48df4814802a481fc54a3691c4a756ec1c224477
[ "MIT" ]
1
2022-03-17T08:16:29.000Z
2022-03-17T08:16:29.000Z
predict.py
schuangs/Satellite-Orbit-Prediction
48df4814802a481fc54a3691c4a756ec1c224477
[ "MIT" ]
null
null
null
predict.py
schuangs/Satellite-Orbit-Prediction
48df4814802a481fc54a3691c4a756ec1c224477
[ "MIT" ]
null
null
null
# Functions for orbit prediction import model import perturbation import transform import numpy as np from scipy.integrate import solve_ivp # # function predict: # input: # elements - elements of satellite orbit, defined in model.py # ts - array of time points # ...
28.604651
146
0.617886
# Functions for orbit prediction import model import perturbation import transform import numpy as np from scipy.integrate import solve_ivp # # function predict: # input: # elements - elements of satellite orbit, defined in model.py # ts - array of time points # ...
527
0
45
8199649f46973979751ba0334875b0faa2f586ef
2,614
py
Python
labs/ai-edge/vision/ocr/code/ocr.py
chagen24/iot-curriculum
32c4cfe6a24d63e10d2f3f8ca5bcd32d6d84652d
[ "CC-BY-4.0", "MIT" ]
126
2020-07-15T02:46:53.000Z
2022-03-20T06:11:47.000Z
labs/ai-edge/vision/ocr/code/ocr.py
toolboc/iot-curriculum
ca7e6a62f8d5367708b9b397bb8a3f87e7562f50
[ "CC-BY-4.0", "MIT" ]
33
2020-08-31T21:59:16.000Z
2021-06-27T15:42:59.000Z
labs/ai-edge/vision/ocr/code/ocr.py
toolboc/iot-curriculum
ca7e6a62f8d5367708b9b397bb8a3f87e7562f50
[ "CC-BY-4.0", "MIT" ]
48
2020-07-14T19:13:06.000Z
2022-03-01T08:55:49.000Z
# Copyright (c) Microsoft Corporation. # Licensed under the MIT license. import os from azure.cognitiveservices.vision import computervision from msrest import authentication from dotenv import load_dotenv # Load the API key and endpoint from the .env file load_dotenv() API_KEY = os.getenv('API_KEY') ENDPOINT = os.ge...
33.512821
82
0.734124
# Copyright (c) Microsoft Corporation. # Licensed under the MIT license. import os from azure.cognitiveservices.vision import computervision from msrest import authentication from dotenv import load_dotenv # Load the API key and endpoint from the .env file load_dotenv() API_KEY = os.getenv('API_KEY') ENDPOINT = os.ge...
616
0
48
c8028064d6ca70da5a988c29c3b6250c204abb83
722
py
Python
skylantern/utils/util.py
chzhong25346/Skylantern
b199d9fa890c3a4a35e28b0e8089e1d97a351500
[ "Apache-2.0" ]
null
null
null
skylantern/utils/util.py
chzhong25346/Skylantern
b199d9fa890c3a4a35e28b0e8089e1d97a351500
[ "Apache-2.0" ]
2
2021-03-31T20:03:41.000Z
2021-12-13T20:45:29.000Z
skylantern/utils/util.py
chzhong25346/Skylantern
b199d9fa890c3a4a35e28b0e8089e1d97a351500
[ "Apache-2.0" ]
null
null
null
import hashlib import logging import re logger = logging.getLogger('main.util')
23.290323
72
0.608033
import hashlib import logging import re logger = logging.getLogger('main.util') def gen_id(string): return int(hashlib.md5(str.encode(string)).hexdigest(), 16) def groupby_na_to_zero(df, ticker): df = df.groupby(ticker).first() df.fillna(0, inplace=True) return df def missing_ticker(index): ...
568
0
69
868cdbc6cc7cf0c2b01886ee5ef1a5f76118b107
5,447
py
Python
IoT course/addition/algorithms/data_generator.py
SunnyientDev/kaggle_contests
f682bf33c0155d872913d9a0db99ba819745bc11
[ "MIT" ]
1
2021-08-19T18:55:07.000Z
2021-08-19T18:55:07.000Z
IoT course/addition/algorithms/data_generator.py
SunnyientDev/kaggle_contests
f682bf33c0155d872913d9a0db99ba819745bc11
[ "MIT" ]
null
null
null
IoT course/addition/algorithms/data_generator.py
SunnyientDev/kaggle_contests
f682bf33c0155d872913d9a0db99ba819745bc11
[ "MIT" ]
null
null
null
''' This code works as simulator. Main values: brightness, time, date, temperature, humidity. Users values: message. ''' import datetime from datetime import datetime import random ################################## PLANT SETTINGS ################################## plant_last_watering_day = "2021-01-12" plant_waterin...
40.051471
201
0.631173
''' This code works as simulator. Main values: brightness, time, date, temperature, humidity. Users values: message. ''' import datetime from datetime import datetime import random ################################## PLANT SETTINGS ################################## plant_last_watering_day = "2021-01-12" plant_waterin...
4,300
0
180
13b66fc7309a1607362996695589538dbea15b3d
10,654
py
Python
tests/conftest.py
elastic-coders/aiopg
1e1a06eb63d093b14125d51e3444c135aaf15679
[ "BSD-2-Clause" ]
null
null
null
tests/conftest.py
elastic-coders/aiopg
1e1a06eb63d093b14125d51e3444c135aaf15679
[ "BSD-2-Clause" ]
null
null
null
tests/conftest.py
elastic-coders/aiopg
1e1a06eb63d093b14125d51e3444c135aaf15679
[ "BSD-2-Clause" ]
1
2021-02-09T10:08:33.000Z
2021-02-09T10:08:33.000Z
import asyncio import collections import gc import logging import psycopg2 import pytest import re import socket import sys import time import uuid import warnings from docker import Client as DockerClient import aiopg from aiopg import sa @pytest.fixture(scope='session') @pytest.yield_fixture @pytest.mark.tryf...
28.872629
76
0.612915
import asyncio import collections import gc import logging import psycopg2 import pytest import re import socket import sys import time import uuid import warnings from docker import Client as DockerClient import aiopg from aiopg import sa @pytest.fixture(scope='session') def unused_port(): def f(): wit...
8,361
0
599
43340ac9c7d8fb69d09e87e74ad1fc74fff12978
705
py
Python
employee_portal/vacation_schedule/forms.py
Dmitriy200123/employee_portal
e06c2cfc03a5d046d5846186249c2140e7ba7814
[ "MIT" ]
null
null
null
employee_portal/vacation_schedule/forms.py
Dmitriy200123/employee_portal
e06c2cfc03a5d046d5846186249c2140e7ba7814
[ "MIT" ]
null
null
null
employee_portal/vacation_schedule/forms.py
Dmitriy200123/employee_portal
e06c2cfc03a5d046d5846186249c2140e7ba7814
[ "MIT" ]
1
2021-07-28T14:48:40.000Z
2021-07-28T14:48:40.000Z
from django import forms from django.utils.datetime_safe import datetime from vacation_schedule.models import EmployeeVacationPeriod
37.105263
110
0.679433
from django import forms from django.utils.datetime_safe import datetime from vacation_schedule.models import EmployeeVacationPeriod class VacationPeriodForm(forms.ModelForm): class Meta: model = EmployeeVacationPeriod fields = ['employeeId', 'startDateVacation', 'endDateVacation', 'vacationDays']...
0
548
23
7b6bde1e004368c2c31024dd5f4761b9e5b438c4
139
py
Python
airbyte-integrations/connectors/destination-hadoop/destination_hadoop/__init__.py
jaynyoni/localAirbyte
efd7a52d6c5b1cdbac9801cf8a4e20b4f07aa3b6
[ "MIT" ]
null
null
null
airbyte-integrations/connectors/destination-hadoop/destination_hadoop/__init__.py
jaynyoni/localAirbyte
efd7a52d6c5b1cdbac9801cf8a4e20b4f07aa3b6
[ "MIT" ]
null
null
null
airbyte-integrations/connectors/destination-hadoop/destination_hadoop/__init__.py
jaynyoni/localAirbyte
efd7a52d6c5b1cdbac9801cf8a4e20b4f07aa3b6
[ "MIT" ]
null
null
null
# # Copyright (c) 2021 Airbyte, Inc., all rights reserved. # from .destination import DestinationHadoop __all__ = ["DestinationHadoop"]
15.444444
56
0.741007
# # Copyright (c) 2021 Airbyte, Inc., all rights reserved. # from .destination import DestinationHadoop __all__ = ["DestinationHadoop"]
0
0
0
602253f90741cbb64b075a23d837cda11ae2925e
1,492
py
Python
6_3_InceptionNet_Visualization.py
matiji66/car_light_dection
75effbe7835473700d6617b3a407edee0a011135
[ "Apache-2.0" ]
null
null
null
6_3_InceptionNet_Visualization.py
matiji66/car_light_dection
75effbe7835473700d6617b3a407edee0a011135
[ "Apache-2.0" ]
null
null
null
6_3_InceptionNet_Visualization.py
matiji66/car_light_dection
75effbe7835473700d6617b3a407edee0a011135
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # -*- coding:utf-8 -*- # @author:Spring import tensorflow as tf import os import tarfile import requests inception_pretrain_model_url = 'http://download.tensorflow.org/models/image/imagenet/inception-2015-12-05.tgz' # 下载inception pretrain模型 inception_pretrain_model_dir = "inception_pretrain" if...
32.434783
110
0.737936
#!/usr/bin/env python # -*- coding:utf-8 -*- # @author:Spring import tensorflow as tf import os import tarfile import requests inception_pretrain_model_url = 'http://download.tensorflow.org/models/image/imagenet/inception-2015-12-05.tgz' # 下载inception pretrain模型 inception_pretrain_model_dir = "inception_pretrain" if...
0
0
0
5b645ed91fdb69e6e8458c66f65224088dca4981
7,311
py
Python
src/auth/auth_ldap.py
kbza/script-server
ad37a5c7e904ba1c466edebf8e409c6ae2710135
[ "Apache-2.0", "CC0-1.0" ]
null
null
null
src/auth/auth_ldap.py
kbza/script-server
ad37a5c7e904ba1c466edebf8e409c6ae2710135
[ "Apache-2.0", "CC0-1.0" ]
null
null
null
src/auth/auth_ldap.py
kbza/script-server
ad37a5c7e904ba1c466edebf8e409c6ae2710135
[ "Apache-2.0", "CC0-1.0" ]
1
2020-04-28T14:50:28.000Z
2020-04-28T14:50:28.000Z
import json import logging import os from string import Template from ldap3 import Connection, SIMPLE from ldap3.core.exceptions import LDAPAttributeError from auth import auth_base from model import model_helper from utils import file_utils from utils.string_utils import strip KNOWN_REJECTIONS = [ "invalidCrede...
32.065789
111
0.623444
import json import logging import os from string import Template from ldap3 import Connection, SIMPLE from ldap3.core.exceptions import LDAPAttributeError from auth import auth_base from model import model_helper from utils import file_utils from utils.string_utils import strip KNOWN_REJECTIONS = [ "invalidCrede...
6,443
28
357
40fba5dd1ae1fa1b00d0691b5cde9877a3930d93
2,449
py
Python
features/tests/features/generators/test_one_hot_encoder.py
daobook/autogluon
7309118f2ab1c9519f25acf61a283a95af95842b
[ "Apache-2.0" ]
1
2022-02-04T10:45:27.000Z
2022-02-04T10:45:27.000Z
features/tests/features/generators/test_one_hot_encoder.py
daobook/autogluon
7309118f2ab1c9519f25acf61a283a95af95842b
[ "Apache-2.0" ]
3
2021-12-30T20:28:01.000Z
2022-02-09T20:19:21.000Z
features/tests/features/generators/test_one_hot_encoder.py
daobook/autogluon
7309118f2ab1c9519f25acf61a283a95af95842b
[ "Apache-2.0" ]
null
null
null
import numpy as np from autogluon.features.generators import OneHotEncoderFeatureGenerator
28.811765
90
0.636178
import numpy as np from autogluon.features.generators import OneHotEncoderFeatureGenerator def test_one_hot_encoder_feature_generator(generator_helper, data_helper): # Given input_data = data_helper.generate_multi_feature_standard() generator = OneHotEncoderFeatureGenerator() expected_feature_meta...
2,308
0
46
0787203a3df45e02ff149e475813576a32ca9ab2
796
py
Python
v1/validators/migrations/0002_auto_20201126_0016.py
nishp77/Validator
77888fc95db1c69a8a734a6d4eded5fe539ac0b6
[ "MIT" ]
43
2020-07-12T23:08:35.000Z
2021-11-28T00:50:49.000Z
v1/validators/migrations/0002_auto_20201126_0016.py
nishp77/Validator
77888fc95db1c69a8a734a6d4eded5fe539ac0b6
[ "MIT" ]
72
2020-07-15T02:33:15.000Z
2021-10-04T20:52:13.000Z
v1/validators/migrations/0002_auto_20201126_0016.py
nishp77/Validator
77888fc95db1c69a8a734a6d4eded5fe539ac0b6
[ "MIT" ]
43
2020-07-13T08:14:24.000Z
2021-10-04T17:33:26.000Z
# Generated by Django 3.1.3 on 2020-11-26 00:16 from django.db import migrations, models
29.481481
140
0.61809
# Generated by Django 3.1.3 on 2020-11-26 00:16 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('validators', '0001_initial'), ] operations = [ migrations.AlterField( model_name='validator', name='ip_address', ...
0
682
23
8fb522f92d1c45c0f54616c4dafb7b45a145a79d
317
py
Python
old-stuff/python-exercises/country_test2.py
bleekere/eScience2022
be58ab45a75e26551f5409d5afe407e60b1989b1
[ "CC0-1.0" ]
null
null
null
old-stuff/python-exercises/country_test2.py
bleekere/eScience2022
be58ab45a75e26551f5409d5afe407e60b1989b1
[ "CC0-1.0" ]
null
null
null
old-stuff/python-exercises/country_test2.py
bleekere/eScience2022
be58ab45a75e26551f5409d5afe407e60b1989b1
[ "CC0-1.0" ]
null
null
null
from finding_parents_method import finding_parents # import lxml library from lxml import etree as ElementTree # genereer data voor input later file = open('country_data.xml') data = file.read() tree = ElementTree.fromstring(data) rank = tree.xpath('.//rank')[0] parents = finding_parents(rank) print(parents)
17.611111
50
0.763407
from finding_parents_method import finding_parents # import lxml library from lxml import etree as ElementTree # genereer data voor input later file = open('country_data.xml') data = file.read() tree = ElementTree.fromstring(data) rank = tree.xpath('.//rank')[0] parents = finding_parents(rank) print(parents)
0
0
0
6fbe1cdf00e8e7a71160e04af88c39b38e6791f0
69,336
py
Python
sdk/python/pulumi_keycloak/oidc/google_identity_provider.py
davide-talesco/pulumi-keycloak
08d66be6f2bf578d4292e29eb6181794375bc4e5
[ "ECL-2.0", "Apache-2.0" ]
13
2020-04-28T15:20:56.000Z
2022-03-24T18:00:17.000Z
sdk/python/pulumi_keycloak/oidc/google_identity_provider.py
davide-talesco/pulumi-keycloak
08d66be6f2bf578d4292e29eb6181794375bc4e5
[ "ECL-2.0", "Apache-2.0" ]
49
2020-02-06T17:53:35.000Z
2022-03-25T19:36:08.000Z
sdk/python/pulumi_keycloak/oidc/google_identity_provider.py
davide-talesco/pulumi-keycloak
08d66be6f2bf578d4292e29eb6181794375bc4e5
[ "ECL-2.0", "Apache-2.0" ]
2
2020-06-09T01:08:56.000Z
2021-12-07T15:30:37.000Z
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union, overload from .. import...
54.897862
302
0.685041
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union, overload from .. import...
9,659
59,167
67
cc5569a8a9c9037e5b3728e213e2d0c80c4e873e
25
py
Python
src/lib/__init__.py
ueffel/keypirinha-allmygames
3ef8f641cec9d2165fbafcc7224f65d3fab1089a
[ "MIT" ]
9
2020-05-31T11:13:52.000Z
2021-09-23T14:26:42.000Z
src/lib/__init__.py
ueffel/keypirinha-allmygames
3ef8f641cec9d2165fbafcc7224f65d3fab1089a
[ "MIT" ]
9
2020-05-31T11:55:10.000Z
2022-01-22T11:22:55.000Z
src/lib/__init__.py
ueffel/keypirinha-allmygames
3ef8f641cec9d2165fbafcc7224f65d3fab1089a
[ "MIT" ]
1
2020-09-11T17:40:51.000Z
2020-09-11T17:40:51.000Z
from .steam import Steam
12.5
24
0.8
from .steam import Steam
0
0
0
75d30d6a94aff4ecbd33f63600c4eb532eb07885
1,751
py
Python
detectron2/distiller_zoo/test.py
lijingyao20010602/Dilation-FasterRCNN
fb1f2f0ab336a65604c4d520cca61995b42fb1a6
[ "Apache-2.0" ]
1
2021-11-07T11:30:57.000Z
2021-11-07T11:30:57.000Z
detectron2/distiller_zoo/test.py
lijingyao20010602/Dilation-FasterRCNN
fb1f2f0ab336a65604c4d520cca61995b42fb1a6
[ "Apache-2.0" ]
null
null
null
detectron2/distiller_zoo/test.py
lijingyao20010602/Dilation-FasterRCNN
fb1f2f0ab336a65604c4d520cca61995b42fb1a6
[ "Apache-2.0" ]
null
null
null
from __future__ import print_function import torch import torch.nn as nn import torch.nn.functional as F import pdb student = torch.tensor([[0,1,2],[2,3,4],[2,3,5]], dtype=torch.float) teacher = torch.tensor([[1,2,2],[3,4,5],[3,4,0]], dtype=torch.float) student2 = torch.tensor([[[0,1],[0,3]]], dtype=torch.float) tea...
39.795455
106
0.714449
from __future__ import print_function import torch import torch.nn as nn import torch.nn.functional as F import pdb def cosine_similarity_loss(output_net, target_net, eps=0.0000001): # Normalize each vector by its norm output_net_norm = torch.sqrt(torch.sum(output_net ** 2, dim=1, keepdim=True)) output_n...
1,221
0
23
628cd1cf84b9aa86b82bce5441be277aeb25b435
2,191
py
Python
src/smart_compose/run_smart_compose.py
StarWang/detext
66f071ec2cebf5e54e7d1de40936b5f281c2a69b
[ "BSD-2-Clause" ]
1,229
2020-02-07T22:17:47.000Z
2022-03-26T06:56:52.000Z
src/smart_compose/run_smart_compose.py
StarWang/detext
66f071ec2cebf5e54e7d1de40936b5f281c2a69b
[ "BSD-2-Clause" ]
36
2020-04-10T02:00:20.000Z
2022-02-09T06:52:35.000Z
src/smart_compose/run_smart_compose.py
StarWang/detext
66f071ec2cebf5e54e7d1de40936b5f281c2a69b
[ "BSD-2-Clause" ]
142
2020-04-07T01:04:07.000Z
2022-03-31T16:22:20.000Z
import sys import tempfile from dataclasses import asdict import tensorflow as tf from absl import logging from official.utils.misc import distribution_utils from smart_compose.args import SmartComposeArg from smart_compose.train import train from smart_compose.utils import distributed_utils, parsing_utils def main...
31.3
155
0.721132
import sys import tempfile from dataclasses import asdict import tensorflow as tf from absl import logging from official.utils.misc import distribution_utils from smart_compose.args import SmartComposeArg from smart_compose.train import train from smart_compose.utils import distributed_utils, parsing_utils def main...
0
0
0
da7d73888f2d1d5596bff3cb443d6daa490ff550
1,301
py
Python
ctxdec/ctx.py
tebeka/pythonwise
56f8cb7aa792c3ad6a3dc754e15f6a04890d694a
[ "BSD-3-Clause" ]
21
2016-11-16T20:08:56.000Z
2021-12-11T23:13:05.000Z
ctxdec/ctx.py
tebeka/pythonwise
56f8cb7aa792c3ad6a3dc754e15f6a04890d694a
[ "BSD-3-Clause" ]
1
2020-10-05T08:35:31.000Z
2020-10-05T08:35:31.000Z
ctxdec/ctx.py
tebeka/pythonwise
56f8cb7aa792c3ad6a3dc754e15f6a04890d694a
[ "BSD-3-Clause" ]
8
2016-11-12T22:54:55.000Z
2021-02-10T10:46:23.000Z
## Greeter ## timed_block from time import time ## Closer ## Database ## contextlib from contextlib import contextmanager @contextmanager
19.41791
63
0.599539
## Greeter class greeter(object): def __enter__(self): print('Hai') def __exit__(self, exc_type, exc_value, traceback): print('Bai') ## timed_block from time import time class timed_block(object): def __init__(self, name): self.name = name def __enter__(self): self....
742
6
404
8acd0b665b53712ee677bc1809daea30359ef3c9
1,905
py
Python
utils/nn_utils.py
fpthink/PDGN
e2f7c26a74069868231b4fefdb90db1386590809
[ "MIT" ]
21
2020-07-13T03:14:21.000Z
2022-03-15T20:14:42.000Z
utils/nn_utils.py
fpthink/PDGN
e2f7c26a74069868231b4fefdb90db1386590809
[ "MIT" ]
2
2020-08-08T12:18:14.000Z
2022-03-21T12:59:10.000Z
utils/nn_utils.py
fpthink/PDGN
e2f7c26a74069868231b4fefdb90db1386590809
[ "MIT" ]
5
2020-09-14T09:37:04.000Z
2021-09-15T08:35:54.000Z
import math import sklearn import torch import torch.nn as nn from torch.nn.parameter import Parameter from torch.autograd import Variable import torch.nn.functional as F import sklearn.metrics class fcbr(nn.Module): """ fc-bn-relu [B, Fin] -> [B, Fout] """ class fcdbr(nn.Module): """ fc-dp-bn-relu ...
25.4
61
0.543832
import math import sklearn import torch import torch.nn as nn from torch.nn.parameter import Parameter from torch.autograd import Variable import torch.nn.functional as F import sklearn.metrics class fcbr(nn.Module): """ fc-bn-relu [B, Fin] -> [B, Fout] """ def __init__(self, Fin, Fout): super...
1,152
0
212
29cba6f36a73c1084ee342ce8960ff548cee2cc2
5,178
py
Python
scripts/eval_cityscapes.py
dr-benway/RevGAN
fcaf4f837a58f20f787e442914d68194325c2ca6
[ "BSD-3-Clause" ]
1
2019-03-20T10:37:24.000Z
2019-03-20T10:37:24.000Z
scripts/eval_cityscapes.py
dr-benway/RevGAN
fcaf4f837a58f20f787e442914d68194325c2ca6
[ "BSD-3-Clause" ]
null
null
null
scripts/eval_cityscapes.py
dr-benway/RevGAN
fcaf4f837a58f20f787e442914d68194325c2ca6
[ "BSD-3-Clause" ]
null
null
null
import numpy as np from PIL import Image import os, sys import argparse from sklearn.metrics import mean_absolute_error as compare_mae from skimage.measure import compare_psnr from skimage.measure import compare_ssim from labels import labels import scipy, skimage from scipy.spatial import KDTree from sklearn.metric...
36.20979
127
0.645616
import numpy as np from PIL import Image import os, sys import argparse from sklearn.metrics import mean_absolute_error as compare_mae from skimage.measure import compare_psnr from skimage.measure import compare_ssim from labels import labels import scipy, skimage from scipy.spatial import KDTree from sklearn.metric...
1,145
0
123
e8f34adf12d491826259e2222f4c1bc90ac0f315
5,336
py
Python
cafe/drivers/unittest/suite_builder.py
rcbops-qa/opencafe
4e6d99ce763fd28289cd35cbd56ca5722824f89e
[ "Apache-2.0" ]
null
null
null
cafe/drivers/unittest/suite_builder.py
rcbops-qa/opencafe
4e6d99ce763fd28289cd35cbd56ca5722824f89e
[ "Apache-2.0" ]
null
null
null
cafe/drivers/unittest/suite_builder.py
rcbops-qa/opencafe
4e6d99ce763fd28289cd35cbd56ca5722824f89e
[ "Apache-2.0" ]
null
null
null
# Copyright 2015 Rackspace # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, sof...
38.388489
79
0.605697
# Copyright 2015 Rackspace # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, sof...
454
0
26
6893dd14fd692112798e40d198652cfd76d734e0
3,626
py
Python
scripts/self_intersections.py
fscottfoti/cutting_board
fda64472fa434d217334f5aaead0c799870672ce
[ "BSD-3-Clause" ]
null
null
null
scripts/self_intersections.py
fscottfoti/cutting_board
fda64472fa434d217334f5aaead0c799870672ce
[ "BSD-3-Clause" ]
null
null
null
scripts/self_intersections.py
fscottfoti/cutting_board
fda64472fa434d217334f5aaead0c799870672ce
[ "BSD-3-Clause" ]
1
2019-12-27T15:28:17.000Z
2019-12-27T15:28:17.000Z
import geopandas as gpd import pandas as pd import numpy as np import shared import sys from shapely.geometry import Polygon args = sys.argv[1:] prefix = args[0] + "_" if len(args) else "" parcels = gpd.read_geocsv("parcels/%sparcels.csv" % prefix, low_memory=False) mazs = gpd.read_geocsv("data/mazs.csv") parcels_ce...
32.666667
77
0.707943
import geopandas as gpd import pandas as pd import numpy as np import shared import sys from shapely.geometry import Polygon args = sys.argv[1:] prefix = args[0] + "_" if len(args) else "" parcels = gpd.read_geocsv("parcels/%sparcels.csv" % prefix, low_memory=False) mazs = gpd.read_geocsv("data/mazs.csv") parcels_ce...
2,061
0
91
c75feb0738ced069d8a492125c42e855fa621a17
1,238
py
Python
test/test_baseOT.py
marksibrahim/CrypTen
4e5b13487d7f6ceaa4f06e86f0b260e0761960fd
[ "MIT" ]
null
null
null
test/test_baseOT.py
marksibrahim/CrypTen
4e5b13487d7f6ceaa4f06e86f0b260e0761960fd
[ "MIT" ]
null
null
null
test/test_baseOT.py
marksibrahim/CrypTen
4e5b13487d7f6ceaa4f06e86f0b260e0761960fd
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # Copyright (c) Facebook, Inc. and its affiliates. # # This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. import unittest from test.multiprocess_test_case import MultiProcessTestCase import crypten.mpc.primitives.baseOT as ...
30.195122
69
0.584814
#!/usr/bin/env python3 # Copyright (c) Facebook, Inc. and its affiliates. # # This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. import unittest from test.multiprocess_test_case import MultiProcessTestCase import crypten.mpc.primitives.baseOT as ...
783
29
49
07d75022dbbab4c52ed216c2d2990515b7f8948b
5,591
py
Python
MonkeyParser.py
ideaworld/Monkey
4867598bddb142a82adb7460e35fb5836be2e219
[ "MIT" ]
1
2017-08-01T03:30:08.000Z
2017-08-01T03:30:08.000Z
MonkeyParser.py
ideaworld/Monkey
4867598bddb142a82adb7460e35fb5836be2e219
[ "MIT" ]
null
null
null
MonkeyParser.py
ideaworld/Monkey
4867598bddb142a82adb7460e35fb5836be2e219
[ "MIT" ]
null
null
null
from ply import * import MonkeyLex tokens = MonkeyLex.tokens def p_program(p): '''program : program compound_action actions | compound_action actions | program actions | actions ''' if len(p) == 4: p[0] = p[1] if not p[0]: p[0] = [] ...
24.414847
71
0.434806
from ply import * import MonkeyLex tokens = MonkeyLex.tokens def p_program(p): '''program : program compound_action actions | compound_action actions | program actions | actions ''' if len(p) == 4: p[0] = p[1] if not p[0]: p[0] = [] ...
112
0
23
22d2dfbafd6a895d5a6dbebc3ac79776ba03c8a8
8,824
py
Python
src-py/resistance/bayes.py
jasperpato/resistanceAI
e9378c018ce4fe98ecf29f5fcee05765342fb314
[ "MIT" ]
null
null
null
src-py/resistance/bayes.py
jasperpato/resistanceAI
e9378c018ce4fe98ecf29f5fcee05765342fb314
[ "MIT" ]
null
null
null
src-py/resistance/bayes.py
jasperpato/resistanceAI
e9378c018ce4fe98ecf29f5fcee05765342fb314
[ "MIT" ]
1
2021-10-18T14:20:05.000Z
2021-10-18T14:20:05.000Z
from agent import Agent from random import random, sample from itertools import combinations from math import comb from mission import Mission class Bayes(Agent): ''' Maintains probabilities of all possible worlds. Calculates the probabilty of each player being a spy from set of worlds. Worlds prob...
39.392857
122
0.604148
from agent import Agent from random import random, sample from itertools import combinations from math import comb from mission import Mission class Bayes(Agent): ''' Maintains probabilities of all possible worlds. Calculates the probabilty of each player being a spy from set of worlds. Worlds prob...
2,007
0
355
eea67e103d4c54a433a7d16617019736c435f6fb
24,214
py
Python
generate_testcase.py
EmbSys-WWU/SLAMtesting
8b92531b32d57a915b00027d985d030707b90086
[ "MIT" ]
1
2022-03-23T07:13:58.000Z
2022-03-23T07:13:58.000Z
generate_testcase.py
EmbSys-WWU/SLAMtesting
8b92531b32d57a915b00027d985d030707b90086
[ "MIT" ]
null
null
null
generate_testcase.py
EmbSys-WWU/SLAMtesting
8b92531b32d57a915b00027d985d030707b90086
[ "MIT" ]
null
null
null
from math import sqrt, atan2, hypot, sin, cos, pi from random import uniform, gauss from typing import Optional, Tuple import numpy as np from map import Map from motion import Velocity, Odometry from obstacle import Obstacle, ObstacleID from robot import Robot from sensor_trace import SensorTrace, TimeStep from simu...
45.175373
120
0.609234
from math import sqrt, atan2, hypot, sin, cos, pi from random import uniform, gauss from typing import Optional, Tuple import numpy as np from map import Map from motion import Velocity, Odometry from obstacle import Obstacle, ObstacleID from robot import Robot from sensor_trace import SensorTrace, TimeStep from simu...
0
0
0
0690a08b7836518ef0ef2d115bea957b10f98759
2,342
py
Python
src/bot.py
gilz688/gbot
b0e159c0a86240f5b1a4f64cfc3c4e7eded33120
[ "MIT" ]
null
null
null
src/bot.py
gilz688/gbot
b0e159c0a86240f5b1a4f64cfc3c4e7eded33120
[ "MIT" ]
null
null
null
src/bot.py
gilz688/gbot
b0e159c0a86240f5b1a4f64cfc3c4e7eded33120
[ "MIT" ]
null
null
null
# Android environment import time from appium import webdriver from appium.webdriver.common.touch_action import TouchAction from eyes import Eyes DESIRED_CAPS = dict( avd='Pixel_4_API_31', platformName='Android', deviceName='Pixel_2_API_31', appPackage='com.globe.gcash.android', appActivity='gcash....
35.484848
158
0.69257
# Android environment import time from appium import webdriver from appium.webdriver.common.touch_action import TouchAction from eyes import Eyes DESIRED_CAPS = dict( avd='Pixel_4_API_31', platformName='Android', deviceName='Pixel_2_API_31', appPackage='com.globe.gcash.android', appActivity='gcash....
1,461
-11
347
9db66e468ae7b1894fefc1c98486640202e9f671
5,786
py
Python
pysnmp/CISCO-IF-LOOPBACK-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
11
2021-02-02T16:27:16.000Z
2021-08-31T06:22:49.000Z
pysnmp/CISCO-IF-LOOPBACK-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
75
2021-02-24T17:30:31.000Z
2021-12-08T00:01:18.000Z
pysnmp/CISCO-IF-LOOPBACK-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 CISCO-IF-LOOPBACK-MIB (http://snmplabs.com/pysmi) # ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/CISCO-IF-LOOPBACK-MIB # Produced by pysmi-0.3.4 at Mon Apr 29 17:44:15 2019 # On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4 # Using Python version 3.7.3 (def...
128.577778
708
0.754234
# # PySNMP MIB module CISCO-IF-LOOPBACK-MIB (http://snmplabs.com/pysmi) # ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/CISCO-IF-LOOPBACK-MIB # Produced by pysmi-0.3.4 at Mon Apr 29 17:44:15 2019 # On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4 # Using Python version 3.7.3 (def...
0
0
0
4fa4e05d50362b601a973859e812f33d282edfeb
1,766
py
Python
tests/test_fixes.py
fcurella/json-spec
4604286e336feb5a0056b08f80d5470a2db3fc8f
[ "BSD-3-Clause" ]
30
2015-04-23T22:37:31.000Z
2021-02-18T11:47:40.000Z
tests/test_fixes.py
fcurella/json-spec
4604286e336feb5a0056b08f80d5470a2db3fc8f
[ "BSD-3-Clause" ]
19
2015-05-27T16:58:58.000Z
2022-01-14T15:09:23.000Z
tests/test_fixes.py
fcurella/json-spec
4604286e336feb5a0056b08f80d5470a2db3fc8f
[ "BSD-3-Clause" ]
16
2015-03-07T15:29:10.000Z
2022-01-14T20:49:26.000Z
from jsonspec.validators import load
28.95082
65
0.243488
from jsonspec.validators import load def test_tuple(): doc = { 'default': { 'ipv4': ('10.140.65.1', 'en4') }, 'ipv4': [ ('10.140.65.1', 'en4', True), ('10.140.66.1', 'en0', False) ] } assert load({ 'type': 'object', 'prope...
1,705
0
23
f29a3396565b790e8efdf58603b05f0f1d71ac71
1,330
py
Python
flod_sak/alembic/versions/20141219-1222-2a2a61dd26dc_til_446_ny_tabell_for_de_dataene_som_.py
Trondheim-kommune/Tilskuddsbasen
4f8ce270ef7296069f8e43bfb4bf6a570a7a35d4
[ "BSD-2-Clause-FreeBSD" ]
null
null
null
flod_sak/alembic/versions/20141219-1222-2a2a61dd26dc_til_446_ny_tabell_for_de_dataene_som_.py
Trondheim-kommune/Tilskuddsbasen
4f8ce270ef7296069f8e43bfb4bf6a570a7a35d4
[ "BSD-2-Clause-FreeBSD" ]
3
2021-03-31T18:23:12.000Z
2021-12-13T19:43:12.000Z
flod_sak/alembic/versions/20141219-1222-2a2a61dd26dc_til_446_ny_tabell_for_de_dataene_som_.py
Trondheim-kommune/Tilskuddsbasen
4f8ce270ef7296069f8e43bfb4bf6a570a7a35d4
[ "BSD-2-Clause-FreeBSD" ]
null
null
null
"""TIL-446 Ny tabell for de dataene som skal arkiveres Revision ID: 2a2a61dd26dc Revises: 31c82e4a3348 Create Date: 2014-12-19 12:22:28.513372 """ # revision identifiers, used by Alembic. from sqlalchemy.dialects.postgresql import JSON, ENUM revision = '2a2a61dd26dc' down_revision = '31c82e4a3348' from alembic im...
34.102564
96
0.613534
"""TIL-446 Ny tabell for de dataene som skal arkiveres Revision ID: 2a2a61dd26dc Revises: 31c82e4a3348 Create Date: 2014-12-19 12:22:28.513372 """ # revision identifiers, used by Alembic. from sqlalchemy.dialects.postgresql import JSON, ENUM revision = '2a2a61dd26dc' down_revision = '31c82e4a3348' from alembic im...
930
0
46
91135ad37e819ac8f5be88b4d603a5483e4a349b
348
py
Python
lib/getlocaladdress/getlocaladdress.py
anandtiwarics/udp-hunter
c00c20f30582cbb4bee2d9e51b92774ad4325188
[ "Apache-2.0" ]
null
null
null
lib/getlocaladdress/getlocaladdress.py
anandtiwarics/udp-hunter
c00c20f30582cbb4bee2d9e51b92774ad4325188
[ "Apache-2.0" ]
null
null
null
lib/getlocaladdress/getlocaladdress.py
anandtiwarics/udp-hunter
c00c20f30582cbb4bee2d9e51b92774ad4325188
[ "Apache-2.0" ]
null
null
null
import ifaddr localips = []
24.857143
100
0.609195
import ifaddr localips = [] def getlocaladdress(): adapters = ifaddr.get_adapters() i = 1 for adapter in adapters: localips.append((str(adapter.nice_name), str(adapter.ips[0].ip[0]), str(adapter.ips[1].ip))) for localip in localips: print(i, localip[0], ": IPv6", localip[1], ": IPv4",...
295
0
23
d8bd711a7f9fd572e1556f921db1b2014219e04d
611
py
Python
src/framework/migrations/0005_auto_20200705_1845.py
rooneyrulz/polls_pro
11409d5e80ee7b582277a22bdf8f8e196965368e
[ "MIT" ]
1
2020-06-22T06:41:40.000Z
2020-06-22T06:41:40.000Z
src/framework/migrations/0005_auto_20200705_1845.py
rooneyrulz/polls_pro
11409d5e80ee7b582277a22bdf8f8e196965368e
[ "MIT" ]
6
2020-07-24T14:41:32.000Z
2021-09-22T19:06:21.000Z
src/framework/migrations/0005_auto_20200705_1845.py
rooneyrulz/polls_pro
11409d5e80ee7b582277a22bdf8f8e196965368e
[ "MIT" ]
null
null
null
# Generated by Django 3.0.6 on 2020-07-05 13:15 from django.conf import settings from django.db import migrations, models
24.44
70
0.621931
# Generated by Django 3.0.6 on 2020-07-05 13:15 from django.conf import settings from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ migrations.swappable_dependency(settings.AUTH_USER_MODEL), ('framework', '0004_auto_20200705_1818'), ] operat...
0
464
23
862f0f30b1b371e15c644721c089726d54135dcb
4,018
py
Python
tests/host/test_graph.py
haydnv/tinychain
3ce912677c8359ee3050cd084c29b3c855d7f461
[ "Apache-2.0" ]
39
2021-03-04T07:43:33.000Z
2021-12-31T06:41:59.000Z
tests/host/test_graph.py
haydnv/tinychain
3ce912677c8359ee3050cd084c29b3c855d7f461
[ "Apache-2.0" ]
56
2021-06-23T16:02:44.000Z
2022-03-30T11:40:20.000Z
tests/host/test_graph.py
haydnv/tinychain
0b6ab0c749a7e0fa1becf11352e39fdf48e06020
[ "Apache-2.0" ]
10
2021-03-05T22:48:32.000Z
2022-02-11T20:02:29.000Z
import tinychain as tc import unittest from testutils import start_host if __name__ == "__main__": unittest.main()
37.203704
111
0.61324
import tinychain as tc import unittest from testutils import start_host class TestGraph(tc.graph.Graph): __uri__ = tc.URI(f"/test/graph") @classmethod def create(cls): users = tc.table.Schema( [tc.Column("user_id", tc.U64)], [tc.Column("email", tc.String, 320), tc.Column(...
3,305
519
69
c7dd3bc2f99d8b0b9e95c45bb63eac1e8644ef66
664
py
Python
python/interviewbit/rotate-matrix.py
fizzoo/kod
79a4b415729e7cadbe9466fbdea9fe73a44485d8
[ "MIT" ]
null
null
null
python/interviewbit/rotate-matrix.py
fizzoo/kod
79a4b415729e7cadbe9466fbdea9fe73a44485d8
[ "MIT" ]
null
null
null
python/interviewbit/rotate-matrix.py
fizzoo/kod
79a4b415729e7cadbe9466fbdea9fe73a44485d8
[ "MIT" ]
null
null
null
# @param A : list of list of integers # @return the same list modified
30.181818
120
0.343373
class Solution: # @param A : list of list of integers # @return the same list modified def rotate(self, A): n = len(A) if len(A) <= 1: return A for i in range(n//2): for j in range(i, n-1-i): tli = i tlj ...
541
-6
49