hexsha
stringlengths
40
40
size
int64
1
1.03M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
3
239
max_stars_repo_name
stringlengths
5
130
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
⌀
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
⌀
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
⌀
max_issues_repo_path
stringlengths
3
239
max_issues_repo_name
stringlengths
5
130
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
67k
⌀
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
⌀
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
⌀
max_forks_repo_path
stringlengths
3
239
max_forks_repo_name
stringlengths
5
130
max_forks_repo_head_hexsha
stringlengths
40
78
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
⌀
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
⌀
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
⌀
content
stringlengths
1
1.03M
avg_line_length
float64
1
958k
max_line_length
int64
1
1.03M
alphanum_fraction
float64
0
1
79812cb4168804aaadaa27f519791b653d80ba96
4,741
py
Python
settings/defaults.py
sysvii/fetch-django
948e70a46cf1b0138a5a3b53cf92349ee22640fc
[ "MIT" ]
null
null
null
settings/defaults.py
sysvii/fetch-django
948e70a46cf1b0138a5a3b53cf92349ee22640fc
[ "MIT" ]
3
2016-03-26T00:42:51.000Z
2016-04-29T11:33:18.000Z
settings/defaults.py
sysvii/fetch-django
948e70a46cf1b0138a5a3b53cf92349ee22640fc
[ "MIT" ]
null
null
null
""" Django settings for fetch project. For more information on this file, see https://docs.djangoproject.com/en/1.7/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/1.7/ref/settings/ """ # Build paths inside the project like this: os.path.join(BASE_DIR, ...) impo...
27.404624
83
0.681713
79812d4f8f347a31e94196f62f98ec647be972d6
893
py
Python
INTRO_TO_DS/code.py
NH-24/intro-to-ds
3bc5f5c9b971ccf99b016cda8853a9cee13a789c
[ "MIT" ]
null
null
null
INTRO_TO_DS/code.py
NH-24/intro-to-ds
3bc5f5c9b971ccf99b016cda8853a9cee13a789c
[ "MIT" ]
null
null
null
INTRO_TO_DS/code.py
NH-24/intro-to-ds
3bc5f5c9b971ccf99b016cda8853a9cee13a789c
[ "MIT" ]
null
null
null
# -------------- import pandas as pd from sklearn.model_selection import train_test_split # Read the data data = pd.read_csv(path) # print the first 5 rows of the dataset print(data.head()) # Split the data into independent and target variable X = data.drop(['G3'],1) y = data.G3 # Split the data into train and test...
19.413043
69
0.735722
79812e2a15592f6f1e0d68b3551ea3cb28b95cbe
6,015
py
Python
build/PureCloudPlatformClientV2/models/patch_predictor_request.py
cjohnson-ctl/platform-client-sdk-python
38ce53bb8012b66e8a43cc8bd6ff00cf6cc99100
[ "MIT" ]
10
2019-02-22T00:27:08.000Z
2021-09-12T23:23:44.000Z
build/PureCloudPlatformClientV2/models/patch_predictor_request.py
cjohnson-ctl/platform-client-sdk-python
38ce53bb8012b66e8a43cc8bd6ff00cf6cc99100
[ "MIT" ]
5
2018-06-07T08:32:00.000Z
2021-07-28T17:37:26.000Z
build/PureCloudPlatformClientV2/models/patch_predictor_request.py
cjohnson-ctl/platform-client-sdk-python
38ce53bb8012b66e8a43cc8bd6ff00cf6cc99100
[ "MIT" ]
6
2020-04-09T17:43:07.000Z
2022-02-17T08:48:05.000Z
# coding: utf-8 """ Copyright 2016 SmartBear Software 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 applica...
32.868852
147
0.636409
79812e60afacf39028c4a4919b6ca8dd8089fb3b
2,574
py
Python
flapp/test/testWindowPlacement.py
rpwagner/tiled-display
52d135bc163360fe55ce5521784b0ef48a8c82c9
[ "Apache-2.0" ]
1
2020-12-11T17:11:45.000Z
2020-12-11T17:11:45.000Z
flapp/test/testWindowPlacement.py
rpwagner/tiled-display
52d135bc163360fe55ce5521784b0ef48a8c82c9
[ "Apache-2.0" ]
null
null
null
flapp/test/testWindowPlacement.py
rpwagner/tiled-display
52d135bc163360fe55ce5521784b0ef48a8c82c9
[ "Apache-2.0" ]
null
null
null
import sys, os sys.path = [os.path.join(os.getcwd(), "..", "..") ] + sys.path from flapp.app import App from flapp.glRenderer2D import glRenderer2D from flapp.texture import Texture, EasyTexture from flapp.pmath.rect import Rect from flapp.pmath.vec2 import Vec2 from OpenGL.GL import * from OpenGL.GLU import * impor...
29.586207
125
0.599845
79812ecc0d0ab14db59dee93fb572c69f6f6b8f2
4,668
py
Python
featuretools/utils/gen_utils.py
Featuretools/featuretools
365abd9519d2eec8eec75936644a7b865d4ef40a
[ "BSD-3-Clause" ]
4,299
2017-09-09T02:41:29.000Z
2019-10-10T05:41:11.000Z
featuretools/utils/gen_utils.py
Featuretools/featuretools
365abd9519d2eec8eec75936644a7b865d4ef40a
[ "BSD-3-Clause" ]
729
2017-09-22T01:54:48.000Z
2019-10-09T15:36:17.000Z
featuretools/utils/gen_utils.py
Featuretools/featuretools
365abd9519d2eec8eec75936644a7b865d4ef40a
[ "BSD-3-Clause" ]
532
2017-09-13T14:18:22.000Z
2019-10-08T06:13:46.000Z
import importlib import logging import re import sys import warnings from enum import Enum from itertools import zip_longest from tqdm import tqdm logger = logging.getLogger("featuretools.utils") def make_tqdm_iterator(**kwargs): options = {"file": sys.stdout, "leave": True} options.update(kwargs) itera...
31.12
100
0.627678
79812f229af0bf25a1fb33fecd317217b2118bf5
2,742
py
Python
nereid/nereid/api/api_v1/endpoints/land_surface_loading.py
phobson/nereid
d46a7fbda9682a244955ae04ebcef1472ad328b1
[ "BSD-3-Clause" ]
null
null
null
nereid/nereid/api/api_v1/endpoints/land_surface_loading.py
phobson/nereid
d46a7fbda9682a244955ae04ebcef1472ad328b1
[ "BSD-3-Clause" ]
null
null
null
nereid/nereid/api/api_v1/endpoints/land_surface_loading.py
phobson/nereid
d46a7fbda9682a244955ae04ebcef1472ad328b1
[ "BSD-3-Clause" ]
null
null
null
from typing import Dict, Any from fastapi import APIRouter, Body, Depends from fastapi.encoders import jsonable_encoder from fastapi.responses import ORJSONResponse import nereid.bg_worker as bg from nereid.api.api_v1.utils import standard_json_response, run_task, get_valid_context from nereid.api.api_v1.models.land_...
31.883721
87
0.574034
79812f95d64d136114f3156e07652cda3fc82ada
3,923
py
Python
nlp/ResultGenerator.py
huntertran/ptidej-wordcloud
3caac1eb79463933622c22da967ed16d1a4c8ba3
[ "MIT" ]
null
null
null
nlp/ResultGenerator.py
huntertran/ptidej-wordcloud
3caac1eb79463933622c22da967ed16d1a4c8ba3
[ "MIT" ]
1
2020-12-15T07:55:34.000Z
2020-12-16T14:57:31.000Z
nlp/ResultGenerator.py
huntertran/ptidej-wordcloud
3caac1eb79463933622c22da967ed16d1a4c8ba3
[ "MIT" ]
null
null
null
# generate word-cloud image from helpers.ProjectHelper import ProjectHelper import numpy as np from PIL import Image, ImageFont, ImageDraw from wordcloud import WordCloud class ResultGenerator: result_dir = './data/nlp/result/' web_result_dir = './docs/images/shapes/fullsize/' web_result_dir...
33.245763
85
0.572776
79813054f4ff77329d84b3762ffe677445292a65
1,041
py
Python
threading/threading_condition.py
all3g/pieces
bc378fd22ddc700891fe7f34ab0d5b341141e434
[ "CNRI-Python" ]
34
2016-10-31T02:05:24.000Z
2018-11-08T14:33:13.000Z
threading/threading_condition.py
join-us/python-programming
bc378fd22ddc700891fe7f34ab0d5b341141e434
[ "CNRI-Python" ]
2
2017-05-11T03:00:31.000Z
2017-11-01T23:37:37.000Z
threading/threading_condition.py
join-us/python-programming
bc378fd22ddc700891fe7f34ab0d5b341141e434
[ "CNRI-Python" ]
21
2016-08-19T09:05:45.000Z
2018-11-08T14:33:16.000Z
#!/usr/bin/env python # -*- coding: utf8 -*- import logging import threading import time logging.basicConfig(level=logging.DEBUG, format='%(asctime)s (%(threadName)-2s) %(message)s') def consumer(cond): """Wait for the condition and use the resource""" logging.debug('Starting consumer t...
22.630435
72
0.629203
798130a6c2912ff592a4e85f2e6d7af2e393ec48
5,133
py
Python
tool/create_dataset_copy.py
zuoyuwei/crnn_torch_trt
ba1f7e8d113a25325389ba2435cef9a548e55210
[ "MIT" ]
null
null
null
tool/create_dataset_copy.py
zuoyuwei/crnn_torch_trt
ba1f7e8d113a25325389ba2435cef9a548e55210
[ "MIT" ]
null
null
null
tool/create_dataset_copy.py
zuoyuwei/crnn_torch_trt
ba1f7e8d113a25325389ba2435cef9a548e55210
[ "MIT" ]
1
2020-07-29T05:20:04.000Z
2020-07-29T05:20:04.000Z
import os import lmdb import cv2 import numpy as np import argparse import shutil import sys def checkImageIsValid(imageBin): if imageBin is None: return False try: imageBuf = np.fromstring(imageBin, dtype=np.uint8) img = cv2.imdecode(imageBuf, cv2.IMREAD_GRAYSCALE) imgH, i...
34.449664
158
0.608026
79813174b58f83d8503fa9f6454043d6c20bc75e
287
py
Python
flask_app/scripts/manage.py
DanishKhakwani/flask_rest_example
2834b71f045593b947e799d8538bbf4665cd3b76
[ "MIT" ]
null
null
null
flask_app/scripts/manage.py
DanishKhakwani/flask_rest_example
2834b71f045593b947e799d8538bbf4665cd3b76
[ "MIT" ]
null
null
null
flask_app/scripts/manage.py
DanishKhakwani/flask_rest_example
2834b71f045593b947e799d8538bbf4665cd3b76
[ "MIT" ]
null
null
null
from flask import Flask from flask_script import Manager from flask_migrate import Migrate, MigrateCommand from flask_app.app import app, db migrate = Migrate(app, db) manager = Manager(app) manager.add_command('migrate', MigrateCommand) if __name__ == "__main__": manager.run()
20.5
49
0.777003
798131c2248d8aaf1fb686681421ad25bfd5c51e
1,703
py
Python
libtiff/tests/test_tiff_array.py
IanZhao/pylibtiff
70be6773de883185b7ef0322b7bada4e28e7ac22
[ "BSD-3-Clause" ]
4
2015-03-10T18:17:48.000Z
2017-08-30T12:26:13.000Z
libtiff/tests/test_tiff_array.py
IanZhao/pylibtiff
70be6773de883185b7ef0322b7bada4e28e7ac22
[ "BSD-3-Clause" ]
1
2015-10-06T19:24:13.000Z
2017-05-02T10:26:53.000Z
libtiff/tests/test_tiff_array.py
IanZhao/pylibtiff
70be6773de883185b7ef0322b7bada4e28e7ac22
[ "BSD-3-Clause" ]
null
null
null
import os import atexit from tempfile import mktemp from numpy import * from libtiff import TIFF from libtiff import TIFFfile, TIFFimage def test_simple_slicing(): for planar_config in [1,2]: for compression in [None, 'lzw']: for itype in [uint8, uint16, uint32, uint64, ...
37.021739
92
0.464474
7981346cffe6d8df31713887c702b6c317443c75
7,242
py
Python
tests/deepface-tests/Ensemble-Face-Recognition.py
palmtrey/nearface
9274f13b2924a3ad9f97446772eb63bc7c482bff
[ "MIT" ]
null
null
null
tests/deepface-tests/Ensemble-Face-Recognition.py
palmtrey/nearface
9274f13b2924a3ad9f97446772eb63bc7c482bff
[ "MIT" ]
null
null
null
tests/deepface-tests/Ensemble-Face-Recognition.py
palmtrey/nearface
9274f13b2924a3ad9f97446772eb63bc7c482bff
[ "MIT" ]
null
null
null
import pandas as pd import numpy as np import itertools from sklearn import metrics from sklearn.metrics import confusion_matrix,accuracy_score, roc_curve, auc import matplotlib.pyplot as plt from tqdm import tqdm tqdm.pandas() #-------------------------- #Data set # Ref: https://github.com/serengil/deepface/tree/mas...
29.084337
117
0.607291
798134bcdc40d44ad2f9c3cc5b60b4230297b0e5
2,796
py
Python
lightcontrol.py
simulatedsimian/iot_light
068a2201b782f0d62a31da18aaeaed17469911f4
[ "MIT" ]
null
null
null
lightcontrol.py
simulatedsimian/iot_light
068a2201b782f0d62a31da18aaeaed17469911f4
[ "MIT" ]
null
null
null
lightcontrol.py
simulatedsimian/iot_light
068a2201b782f0d62a31da18aaeaed17469911f4
[ "MIT" ]
null
null
null
import machine import neopixel import utime import math from timetools import CountdownTimer import urandom def lerp(a, b, control): return a + control * (b - a) def lerpRGB(rgb1, rgb2, control): return (int(lerp(rgb1[0], rgb2[0], control)), int(lerp(rgb1[1], rgb2[1], control)), int(...
27.145631
73
0.561159
798134f3a45873ad360cc7deb7ebc06fa2054cf3
6,752
py
Python
bindings/python/ensmallen_graph/datasets/string/vibriogenomosp.py
caufieldjh/ensmallen_graph
14e98b1cdbc73193a84a913d7d4f2b2b3eb2c43a
[ "MIT" ]
null
null
null
bindings/python/ensmallen_graph/datasets/string/vibriogenomosp.py
caufieldjh/ensmallen_graph
14e98b1cdbc73193a84a913d7d4f2b2b3eb2c43a
[ "MIT" ]
null
null
null
bindings/python/ensmallen_graph/datasets/string/vibriogenomosp.py
caufieldjh/ensmallen_graph
14e98b1cdbc73193a84a913d7d4f2b2b3eb2c43a
[ "MIT" ]
null
null
null
""" This file offers the methods to automatically retrieve the graph Vibrio genomosp.. The graph is automatically retrieved from the STRING repository. Report --------------------- At the time of rendering these methods (please see datetime below), the graph had the following characteristics: Datetime: 2021-02-02...
35.350785
223
0.705717
798135fffc2bfa23db487eac6f5cdc2b7c13aabf
91
py
Python
auth_public.py
tjasabajc/Recepti
41b4950125d542703b23553c045569361a03cbe6
[ "MIT" ]
null
null
null
auth_public.py
tjasabajc/Recepti
41b4950125d542703b23553c045569361a03cbe6
[ "MIT" ]
6
2018-05-31T15:19:17.000Z
2018-09-05T10:44:59.000Z
auth_public.py
tjasabajc/Recepti
41b4950125d542703b23553c045569361a03cbe6
[ "MIT" ]
null
null
null
db = 'sem2018_tjasab' host = 'baza.fmf.uni-lj.si' user = 'javnost' password = 'javnogeslo'
18.2
27
0.692308
79813727c15a35ee5ec86b829ec34b65d4403ec1
20,525
py
Python
tests/components/sensibo/test_climate.py
stuart-c/core
a28fa5377ac8f8291b6c80803491737438175358
[ "Apache-2.0" ]
null
null
null
tests/components/sensibo/test_climate.py
stuart-c/core
a28fa5377ac8f8291b6c80803491737438175358
[ "Apache-2.0" ]
20
2021-11-03T06:21:56.000Z
2022-03-31T06:21:24.000Z
tests/components/sensibo/test_climate.py
fblondeau/home-assistant
a8da0eedd32ac8198f06d4e32622d0f8b40b4a41
[ "Apache-2.0" ]
null
null
null
"""The test for the sensibo binary sensor platform.""" from __future__ import annotations from datetime import timedelta from unittest.mock import patch from pysensibo.model import SensiboData import pytest from voluptuous import MultipleInvalid from homeassistant.components.climate.const import ( ATTR_FAN_MODE,...
31.051437
92
0.629038
79813757233743f26c579fa95ec121acc5f9ff67
261
py
Python
pyvisdk/enums/host_unresolved_vmfs_resolution_spec_vmfs_uuid_resolution.py
Infinidat/pyvisdk
f2f4e5f50da16f659ccc1d84b6a00f397fa997f8
[ "MIT" ]
null
null
null
pyvisdk/enums/host_unresolved_vmfs_resolution_spec_vmfs_uuid_resolution.py
Infinidat/pyvisdk
f2f4e5f50da16f659ccc1d84b6a00f397fa997f8
[ "MIT" ]
null
null
null
pyvisdk/enums/host_unresolved_vmfs_resolution_spec_vmfs_uuid_resolution.py
Infinidat/pyvisdk
f2f4e5f50da16f659ccc1d84b6a00f397fa997f8
[ "MIT" ]
null
null
null
######################################## # Automatically generated, do not edit. ######################################## from pyvisdk.thirdparty import Enum HostUnresolvedVmfsResolutionSpecVmfsUuidResolution = Enum( 'forceMount', 'resignature', )
18.642857
58
0.524904
7981382d0674befe37c419a19b6a62f83466fb12
11,745
py
Python
src/prefect/cli/agent.py
znicholasbrown/prefect
a91d039e7885185a6b4e62d20d44f85d8ff680ac
[ "Apache-2.0" ]
null
null
null
src/prefect/cli/agent.py
znicholasbrown/prefect
a91d039e7885185a6b4e62d20d44f85d8ff680ac
[ "Apache-2.0" ]
null
null
null
src/prefect/cli/agent.py
znicholasbrown/prefect
a91d039e7885185a6b4e62d20d44f85d8ff680ac
[ "Apache-2.0" ]
null
null
null
import click from prefect import config from prefect.utilities.configuration import set_temporary_config from prefect.utilities.serialization import from_qualified_name _agents = { "fargate": "prefect.agent.fargate.FargateAgent", "docker": "prefect.agent.docker.DockerAgent", "kubernetes": "prefect.agent.k...
30.826772
126
0.589017
7981389a46e93c562d0b7bb809c34ba075f187e2
3,724
py
Python
google/ads/google_ads/v6/proto/errors/null_error_pb2.py
arammaliachi/google-ads-python
a4fe89567bd43eb784410523a6306b5d1dd9ee67
[ "Apache-2.0" ]
null
null
null
google/ads/google_ads/v6/proto/errors/null_error_pb2.py
arammaliachi/google-ads-python
a4fe89567bd43eb784410523a6306b5d1dd9ee67
[ "Apache-2.0" ]
null
null
null
google/ads/google_ads/v6/proto/errors/null_error_pb2.py
arammaliachi/google-ads-python
a4fe89567bd43eb784410523a6306b5d1dd9ee67
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by the protocol buffer compiler. DO NOT EDIT! # source: google/ads/googleads/v6/errors/null_error.proto """Generated protocol buffer code.""" from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf import reflection ...
37.616162
577
0.784372
798138a9f54231f4a44e7a87d243ba3ef0998403
6,711
py
Python
fairseq/tasks/cross_lingual_lm.py
ghchen18/acl22_sixtp
445f1711f0ca7fff1abace00bdca3151b56dc769
[ "MIT" ]
null
null
null
fairseq/tasks/cross_lingual_lm.py
ghchen18/acl22_sixtp
445f1711f0ca7fff1abace00bdca3151b56dc769
[ "MIT" ]
null
null
null
fairseq/tasks/cross_lingual_lm.py
ghchen18/acl22_sixtp
445f1711f0ca7fff1abace00bdca3151b56dc769
[ "MIT" ]
null
null
null
# 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 itertools import logging import os from collections import OrderedDict import numpy as np from fairseq import tokenizer, utils from fa...
34.239796
97
0.588288
798138f65beeac39093b379d67d7a32f22f9d52d
4,824
py
Python
scripts/remote_script_test.py
onzehub/onzecurrency
08f82126be349a639a6421463a3d9038761b661f
[ "MIT" ]
null
null
null
scripts/remote_script_test.py
onzehub/onzecurrency
08f82126be349a639a6421463a3d9038761b661f
[ "MIT" ]
null
null
null
scripts/remote_script_test.py
onzehub/onzecurrency
08f82126be349a639a6421463a3d9038761b661f
[ "MIT" ]
null
null
null
import sys import os, glob import subprocess import argparse import time from tokenize import String import psutil import pexpect import threading import json from datetime import datetime def main(): # Cd to scripts directory #os.chdir(os.path.dirname(__file__)) # Initialize parser parser = argparse...
34.457143
191
0.649668
7981390ae3906a1cc7cbc5ba4cabae05c8fd6654
4,346
py
Python
data.py
jerryyeezus/nlp-summarization
6121975351bf6a69f3ac8000e6e8e3112e693359
[ "MIT" ]
null
null
null
data.py
jerryyeezus/nlp-summarization
6121975351bf6a69f3ac8000e6e8e3112e693359
[ "MIT" ]
null
null
null
data.py
jerryyeezus/nlp-summarization
6121975351bf6a69f3ac8000e6e8e3112e693359
[ "MIT" ]
null
null
null
## data.py ## Author: Yangfeng Ji ## Date: 09-13-2014 ## Time-stamp: <yangfeng 09/16/2014 13:07:10> """ Construct data for training/dev/test data. Following three steps: 1, build data 2, build vocab (optional, not necessary if vocabs are given) 3, build matrix 4, save/get matrix 5, save/get vocabs (optional, necessary...
26.662577
99
0.564657
79813941c2b24bc9fb312190918765646a21fd60
122
py
Python
neural/util/__init__.py
Hengle/face-nn
edc4ae1e3aedac88b99d3216693aa81406a519b1
[ "MIT" ]
319
2019-10-09T05:34:22.000Z
2022-03-31T07:52:28.000Z
neural/util/__init__.py
CFengFeng/face-nn
a76a689774b5101959d3c5b8a04898ae82c7bfc2
[ "MIT" ]
19
2019-11-08T01:41:02.000Z
2022-03-24T11:46:05.000Z
neural/util/__init__.py
CFengFeng/face-nn
a76a689774b5101959d3c5b8a04898ae82c7bfc2
[ "MIT" ]
103
2019-10-05T08:33:56.000Z
2022-03-29T13:38:20.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- # @Author: penghuailiang # @Date : 2019-10-04 """ util 一些通用的解析公用的模块 """
10.166667
24
0.590164
79813a429dd052b4099eee0ce808479e57db43d4
2,353
py
Python
xfClock/modules/Gesture/Gesture.py
fhansa/xfClock
4f52be03fec90bfdcd00db0c7492627f1be33bcf
[ "MIT" ]
null
null
null
xfClock/modules/Gesture/Gesture.py
fhansa/xfClock
4f52be03fec90bfdcd00db0c7492627f1be33bcf
[ "MIT" ]
2
2021-02-08T20:41:13.000Z
2021-04-30T21:12:52.000Z
xfClock/modules/Gesture/Gesture.py
fhansa/xfClock
4f52be03fec90bfdcd00db0c7492627f1be33bcf
[ "MIT" ]
null
null
null
# # Module for xfClock - GestureRecognizer # import xfClock.module import config import xfClock.hassDevice from threading import Thread import apds9960 import smbus from time import sleep class Gesture(xfClock.module.moduleBase): def __init__(self, app): super().__init__(app) self.deviceUD = h...
28.011905
123
0.543136
79813a43566b49d4b6425495102100f312f9d033
3,954
py
Python
torchsparse/nn/modules/norm.py
victoryc/torchsparse
cca1d339b33f0151b07a83e66a8c99c9bfd0b1a9
[ "MIT" ]
null
null
null
torchsparse/nn/modules/norm.py
victoryc/torchsparse
cca1d339b33f0151b07a83e66a8c99c9bfd0b1a9
[ "MIT" ]
null
null
null
torchsparse/nn/modules/norm.py
victoryc/torchsparse
cca1d339b33f0151b07a83e66a8c99c9bfd0b1a9
[ "MIT" ]
null
null
null
import torch from torch import nn from torchsparse.sparse_tensor import * _all__ = ['BatchNorm', 'GroupNorm'] class BatchNorm(nn.BatchNorm1d): def __init__(self, num_features: int, *, eps: float = 1e-5, momentum: float = 0.1) -> None: sup...
42.978261
110
0.621143
79813a47d4a0a8d107c7eb72e5937dafda6664f0
1,952
py
Python
nmsprime_get_env.py
xee8ai/xee-helpers-nmsprime
0222aa657b642f5f0a5f3a46604d3bc256e92f3b
[ "MIT" ]
1
2020-01-20T08:19:49.000Z
2020-01-20T08:19:49.000Z
nmsprime_get_env.py
xee8ai/xee-helpers-nmsprime
0222aa657b642f5f0a5f3a46604d3bc256e92f3b
[ "MIT" ]
null
null
null
nmsprime_get_env.py
xee8ai/xee-helpers-nmsprime
0222aa657b642f5f0a5f3a46604d3bc256e92f3b
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 import os import os.path from pprint import pprint import sys nmsprime_path = '/var/www/nmsprime' tasks = { 'db' : 'DB_DATABASE', 'host' : 'DB_HOST', 'password' : 'DB_PASSWORD', 'user' : 'DB_USERNAME', 'db_ccc' : 'CCC_DB_DATABASE', 'host_ccc' : ...
22.697674
92
0.578893
79813a58707a44886a8fda5a444fba73ac8027cb
383
py
Python
rplugin/python3/symfony/sf28/parseEntities.py
NeverI/symfony.nvim
70d02b75064e345e6abbc0b06a1a992dc77804cd
[ "MIT" ]
null
null
null
rplugin/python3/symfony/sf28/parseEntities.py
NeverI/symfony.nvim
70d02b75064e345e6abbc0b06a1a992dc77804cd
[ "MIT" ]
6
2020-01-10T07:48:10.000Z
2020-01-11T10:04:26.000Z
rplugin/python3/symfony/sf28/parseEntities.py
NeverI/symfony.nvim
70d02b75064e345e6abbc0b06a1a992dc77804cd
[ "MIT" ]
null
null
null
import re class EntityParser: def __init__(self): self.entities = [] def parse(self, lines): for line in lines: self._parseLine(line) return self.entities def _parseLine(self, line): match = re.match(r'^\[OK\]\s+([\w\\]+)$', line) if not match: ...
20.157895
55
0.548303
79813a9b33b8f093e7e94a565d4b3d2677be5c82
814
py
Python
dis_sdk_python_demo/describeStream_sample.py
leishanlin/huaweicloud-sdk-python-dis
900317432b9e9b3fea331d2cb9aa402594f9992b
[ "Apache-2.0" ]
null
null
null
dis_sdk_python_demo/describeStream_sample.py
leishanlin/huaweicloud-sdk-python-dis
900317432b9e9b3fea331d2cb9aa402594f9992b
[ "Apache-2.0" ]
null
null
null
dis_sdk_python_demo/describeStream_sample.py
leishanlin/huaweicloud-sdk-python-dis
900317432b9e9b3fea331d2cb9aa402594f9992b
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/python # -*- coding:utf-8 -*- from dis_sdk_python import * streamname = "dis-oeYF" def describeStream_test(): cli = disclient(endpoint='', ak='', sk='', projectid='', region='') try: hasMorePartitions = True startPartitionId = "" partitions = [] while hasMorePartitio...
23.257143
71
0.588452
79813aa6d0d47bbc3136fe0b22437fcb458e6612
2,691
py
Python
exegis/main.py
gruel/AphorismToTEI
6d33a353c4b4f159af62e061618ff03a1f09fb7f
[ "BSD-3-Clause" ]
null
null
null
exegis/main.py
gruel/AphorismToTEI
6d33a353c4b4f159af62e061618ff03a1f09fb7f
[ "BSD-3-Clause" ]
null
null
null
exegis/main.py
gruel/AphorismToTEI
6d33a353c4b4f159af62e061618ff03a1f09fb7f
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- """Main module to treat aphorisms and convert them in XML files. :Authors: Jonathan Boyle, Nicolas Gruel <nicolas.gruel@manchester.ac.uk> :Copyright: IT Services, The University of Manchester """ import sys import os try: from docopt import docopt except ImportError: print("Install do...
28.935484
98
0.597919
79813ad9976e4b29fa715b95eb43895f97b392f4
33,121
py
Python
tests/python_package_test/test_sklearn.py
bumplzz69/LightGBM
b1e5a843ab57c64b01c8896ef3cda6fdf907d417
[ "MIT" ]
null
null
null
tests/python_package_test/test_sklearn.py
bumplzz69/LightGBM
b1e5a843ab57c64b01c8896ef3cda6fdf907d417
[ "MIT" ]
null
null
null
tests/python_package_test/test_sklearn.py
bumplzz69/LightGBM
b1e5a843ab57c64b01c8896ef3cda6fdf907d417
[ "MIT" ]
null
null
null
# coding: utf-8 # pylint: skip-file import math import os import unittest import lightgbm as lgb import numpy as np from sklearn import __version__ as sk_version from sklearn.base import clone from sklearn.datasets import (load_boston, load_breast_cancer, load_digits, load_iris, load_svml...
53.593851
118
0.634462
79813b18d6f1a917a535a81c552dd148ced19141
3,276
py
Python
src/rascunho.py
acmlia/ann_training
8cb39123203445cf79c4bd65350fa4063705a518
[ "MIT" ]
null
null
null
src/rascunho.py
acmlia/ann_training
8cb39123203445cf79c4bd65350fa4063705a518
[ "MIT" ]
null
null
null
src/rascunho.py
acmlia/ann_training
8cb39123203445cf79c4bd65350fa4063705a518
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Wed Apr 17 06:22:35 2019 @author: rainfall """ ## load YAML and create model yaml_file = open(ymlp+'final_screening_'+ymlv+'.yaml', 'r') loaded_model_yaml = yaml_file.read() yaml_file.close() loaded_model = model_from_yaml(...
43.105263
151
0.46917
79813c2e9c7074ae33064fca31b8babd74b90e82
423
py
Python
tests/integration/test_executable_table_function/user_scripts/input_signalled_pool.py
chalice19/ClickHouse
2f38e7bc5c2113935ab86260439bb543a1737291
[ "Apache-2.0" ]
8,629
2016-06-14T21:03:01.000Z
2019-09-23T07:46:38.000Z
tests/integration/test_executable_table_function/user_scripts/input_signalled_pool.py
chalice19/ClickHouse
2f38e7bc5c2113935ab86260439bb543a1737291
[ "Apache-2.0" ]
4,335
2016-06-15T12:58:31.000Z
2019-09-23T11:18:43.000Z
tests/integration/test_executable_table_function/user_scripts/input_signalled_pool.py
chalice19/ClickHouse
2f38e7bc5c2113935ab86260439bb543a1737291
[ "Apache-2.0" ]
1,700
2016-06-15T09:25:11.000Z
2019-09-23T11:16:38.000Z
#!/usr/bin/python3 import sys import os import signal if __name__ == "__main__": for chunk_header in sys.stdin: os.signal(os.getpid(), signal.SIGTERM) chunk_length = int(chunk_header) print(str(chunk_length), end="\n") while chunk_length != 0: line = sys.stdin.readlin...
21.15
46
0.579196
79813c4d6a4270967279db65b518faee820940f4
1,323
py
Python
tests/core/util/test_significant_bits.py
petrus-hanks/flax-blockchain
6e180dc84ca24c757555c9947f44bd724b1af3eb
[ "Apache-2.0" ]
8
2021-07-08T00:11:49.000Z
2022-02-09T04:28:40.000Z
tests/core/util/test_significant_bits.py
petrus-hanks/flax-blockchain
6e180dc84ca24c757555c9947f44bd724b1af3eb
[ "Apache-2.0" ]
15
2021-07-29T06:37:42.000Z
2021-08-29T17:26:08.000Z
tests/core/util/test_significant_bits.py
petrus-hanks/flax-blockchain
6e180dc84ca24c757555c9947f44bd724b1af3eb
[ "Apache-2.0" ]
3
2021-10-04T17:51:04.000Z
2022-03-01T04:23:01.000Z
import unittest from beer.util.significant_bits import count_significant_bits, truncate_to_significant_bits class TestSignificantBits(unittest.TestCase): def test_truncate_to_significant_bits(self): a = -0b001101 assert truncate_to_significant_bits(a, 2) == -0b1100 a = -0b001111 a...
35.756757
91
0.687075
79813c869ffc788b0df6f0147b8056ed826160bf
14,051
py
Python
truffe2/main/models.py
TeoGoddet/truffe2
23a963d404e5f719c0eeb273f52223ff5e3e5263
[ "BSD-2-Clause" ]
null
null
null
truffe2/main/models.py
TeoGoddet/truffe2
23a963d404e5f719c0eeb273f52223ff5e3e5263
[ "BSD-2-Clause" ]
null
null
null
truffe2/main/models.py
TeoGoddet/truffe2
23a963d404e5f719c0eeb273f52223ff5e3e5263
[ "BSD-2-Clause" ]
null
null
null
# -*- coding: utf-8 -*- from django.db import models from django.db.models.deletion import CASCADE from django.utils.translation import gettext_lazy as _ from django.urls import reverse from generic.models import GenericModel, GenericStateModel, FalseFK, SearchableModel from rights.utils import AgepolyEditableModel, ...
32.600928
259
0.604014
79813cad88f623b5c839191fb874ff026b0b28d6
84
py
Python
api/data_access/dynamo_errors.py
firminsa/quiz-me-api
80ed1dec56d72227b18c5d587655f6841a4f991a
[ "MIT" ]
null
null
null
api/data_access/dynamo_errors.py
firminsa/quiz-me-api
80ed1dec56d72227b18c5d587655f6841a4f991a
[ "MIT" ]
null
null
null
api/data_access/dynamo_errors.py
firminsa/quiz-me-api
80ed1dec56d72227b18c5d587655f6841a4f991a
[ "MIT" ]
null
null
null
entity_already_exists = 'EntityAlreadyExists' validation_error = 'ValidationError'
21
45
0.845238
79813cd7c100494259f7568211da41b878d4d689
10,650
py
Python
octotribble/extraction/dracs_quicklooks2017.py
jason-neal/equanimous-octo-tribble
a8788909331034725afe38ae96c83584b17c9fbd
[ "MIT" ]
1
2017-05-10T20:24:02.000Z
2017-05-10T20:24:02.000Z
octotribble/extraction/dracs_quicklooks2017.py
jason-neal/equanimous-octo-tribble
a8788909331034725afe38ae96c83584b17c9fbd
[ "MIT" ]
1
2016-04-11T17:35:35.000Z
2016-04-11T17:35:35.000Z
octotribble/extraction/dracs_quicklooks2017.py
jason-neal/equanimous-octo-tribble
a8788909331034725afe38ae96c83584b17c9fbd
[ "MIT" ]
1
2017-08-18T11:00:56.000Z
2017-08-18T11:00:56.000Z
# DRACS Output quicklook/status. # Plot all 8 reduced spectra # Plot all 8 normalized reduced spectra # plot mean combined and median combined spectra. from __future__ import division, print_function import argparse import os import sys from os.path import join import matplotlib.pyplot as plt import numpy as np fro...
37.237762
119
0.518498
79813daaf1e4b84abd1169f9fb0e87e6babc557d
9,775
py
Python
test/functional/p2p_blockfilters.py
joynicoferna/carpinchocoin
987284642d94e26c2b3b884c14846068d124a24a
[ "MIT" ]
null
null
null
test/functional/p2p_blockfilters.py
joynicoferna/carpinchocoin
987284642d94e26c2b3b884c14846068d124a24a
[ "MIT" ]
null
null
null
test/functional/p2p_blockfilters.py
joynicoferna/carpinchocoin
987284642d94e26c2b3b884c14846068d124a24a
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # Copyright (c) 2019 The Bitcoin Core developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. """Tests NODE_COMPACT_FILTERS (BIP 157/158). Tests that a node configured with -blockfilterindex and -peerbloc...
38.035019
99
0.641739
79813efa9a1101518d0dd46d710a9ef3944b0c40
2,914
py
Python
code/examples/create-data-object.py
nuvla/python-api
7b530aa049eee8c8cd654c27d749d46bf0d19e87
[ "Apache-2.0" ]
4
2019-04-27T10:35:44.000Z
2019-05-05T13:04:28.000Z
code/examples/create-data-object.py
nuvla/python-library
421abe6f583e1ce6a48670131faefe16b7e0bc12
[ "Apache-2.0" ]
21
2019-02-22T07:30:41.000Z
2022-03-30T13:27:55.000Z
code/examples/create-data-object.py
nuvla/python-library
421abe6f583e1ce6a48670131faefe16b7e0bc12
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python3 import os import hashlib from pprint import pp from nuvla.api import Api as Nuvla from nuvla.api.resources.data import DataObjectS3 from nuvla.api.resources.user import User from utils import nuvla_conf_user_pass # Set to True to print Nuvla request / response messages to stdout. debug = Fals...
26.490909
77
0.712766
79813fe8738070c6f4fa92caa7b0da680312e7eb
1,017
py
Python
Python Parallel Programming Cookbook_Code/Chapter 2/Thread_in_a_subclass.py
IdiosyncraticDragon/Reading-Notes
6412c327d337a88ae15c7d07acfb6a5ab955895e
[ "Apache-2.0" ]
6
2018-03-22T10:23:27.000Z
2021-12-10T03:45:50.000Z
Python Parallel Programming Cookbook_Code/Chapter 2/Thread_in_a_subclass.py
IdiosyncraticDragon/Reading-Notes
6412c327d337a88ae15c7d07acfb6a5ab955895e
[ "Apache-2.0" ]
null
null
null
Python Parallel Programming Cookbook_Code/Chapter 2/Thread_in_a_subclass.py
IdiosyncraticDragon/Reading-Notes
6412c327d337a88ae15c7d07acfb6a5ab955895e
[ "Apache-2.0" ]
1
2020-08-25T14:26:27.000Z
2020-08-25T14:26:27.000Z
import threading import time exit_Flag = 0 class myThread (threading.Thread): def _init__(self, threadID, name, counter): threading.Thread._init__(self) self.threadID = threadID self.name = name self.counter = counter def run(self): print ("Starting " + self...
24.214286
65
0.578171
7981406de1c06e034bbf2c79bc76be1d5fa823c7
24,961
py
Python
resources/api/reservation.py
HotStew/respa
04f39efb15b4f4206a122e665f8377c7198e1f25
[ "MIT" ]
null
null
null
resources/api/reservation.py
HotStew/respa
04f39efb15b4f4206a122e665f8377c7198e1f25
[ "MIT" ]
33
2018-10-19T13:55:40.000Z
2022-03-25T11:46:49.000Z
resources/api/reservation.py
HotStew/respa
04f39efb15b4f4206a122e665f8377c7198e1f25
[ "MIT" ]
3
2019-06-03T10:52:48.000Z
2022-02-28T08:09:49.000Z
import uuid import arrow import django_filters from arrow.parser import ParserError from guardian.core import ObjectPermissionChecker from django.contrib.auth import get_user_model from django.utils.translation import ugettext_lazy as _ from django.core.exceptions import ( PermissionDenied, ValidationError as Djang...
42.30678
141
0.668122
798140c44be86e1d3297704fde9aeb00f997d8d4
4,849
py
Python
CreateImages.py
aws-samples/bulk-aws-migration-using-cloudendure-automation
7d96c8c14187db97355e3552536d0291c768ddc2
[ "MIT-0" ]
5
2020-11-03T06:30:33.000Z
2022-02-16T09:30:36.000Z
CreateImages.py
aws-samples/bulk-aws-migration-using-cloudendure-automation
7d96c8c14187db97355e3552536d0291c768ddc2
[ "MIT-0" ]
null
null
null
CreateImages.py
aws-samples/bulk-aws-migration-using-cloudendure-automation
7d96c8c14187db97355e3552536d0291c768ddc2
[ "MIT-0" ]
5
2021-01-21T20:00:03.000Z
2021-10-05T01:19:09.000Z
#Copyright 2008-2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. #Permission is hereby granted, free of charge, to any person obtaining a copy of this #software and associated documentation files (the "Software"), to deal in the Software #without restriction, including without limitation the rights to use...
46.625
167
0.521551
798140d8ff9661fe92442904be53ba452a2b9234
663
py
Python
booking/migrations/0013_auto_20200124_0713.py
gafderks/dbase
4089cf220740afd7fcc0ae68fcd6185829a60eae
[ "Apache-2.0" ]
null
null
null
booking/migrations/0013_auto_20200124_0713.py
gafderks/dbase
4089cf220740afd7fcc0ae68fcd6185829a60eae
[ "Apache-2.0" ]
281
2020-04-03T15:22:46.000Z
2022-03-31T20:53:28.000Z
booking/migrations/0013_auto_20200124_0713.py
gafderks/dbase
4089cf220740afd7fcc0ae68fcd6185829a60eae
[ "Apache-2.0" ]
null
null
null
# Generated by Django 3.0.1 on 2020-01-24 06:13 from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ("booking", "0012_auto_20200119_1555"), ] operations = [ migrations.AlterField( model_name="booki...
24.555556
63
0.552036
7981412dd380a3e69ce1d5958a0a63f222150447
843
py
Python
leetcode/118_pascals_triangle.py
coocos/leetcode
007bbeb46fa4b32e1c92fc894edeb2100eb6ba21
[ "MIT" ]
null
null
null
leetcode/118_pascals_triangle.py
coocos/leetcode
007bbeb46fa4b32e1c92fc894edeb2100eb6ba21
[ "MIT" ]
null
null
null
leetcode/118_pascals_triangle.py
coocos/leetcode
007bbeb46fa4b32e1c92fc894edeb2100eb6ba21
[ "MIT" ]
null
null
null
import unittest from typing import List class Solution: """This is a simple iterative solution to Pascal's triangle""" def generate(self, numRows: int) -> List[List[int]]: rows: List[List[int]] = [] for i in range(numRows): row = [1] for j in range(1, i): ...
22.184211
66
0.516014
798141bc8325885e7ff724d880b0b667f9cc9528
192
py
Python
vseros/2016-17/okr/archive/3/solution.py
dluschan/olymp
dfbf4352dbc7f6fd7563e7bd19aff6fd67fb50b7
[ "MIT" ]
null
null
null
vseros/2016-17/okr/archive/3/solution.py
dluschan/olymp
dfbf4352dbc7f6fd7563e7bd19aff6fd67fb50b7
[ "MIT" ]
null
null
null
vseros/2016-17/okr/archive/3/solution.py
dluschan/olymp
dfbf4352dbc7f6fd7563e7bd19aff6fd67fb50b7
[ "MIT" ]
1
2018-09-14T18:50:48.000Z
2018-09-14T18:50:48.000Z
s1 = input() s2 = input() pairs = set() for i in range(len(s2) - 1): pairs.add(s2[i:i + 2]) ans = 0 for i in range(len(s1) - 1): if s1[i: i + 2] in pairs: ans += 1 print(ans)
16
29
0.515625
798141def4e43752abb4a8eb277573eeac9ef255
6,105
py
Python
experiment_server/_process_config.py
ahmed-shariff/experiment_server
49e9293da23daf5625d66833cfb9eff8d962f682
[ "MIT" ]
null
null
null
experiment_server/_process_config.py
ahmed-shariff/experiment_server
49e9293da23daf5625d66833cfb9eff8d962f682
[ "MIT" ]
null
null
null
experiment_server/_process_config.py
ahmed-shariff/experiment_server
49e9293da23daf5625d66833cfb9eff8d962f682
[ "MIT" ]
null
null
null
from pathlib import Path from shutil import ExecError from typing import Any, Callable, Dict, List, Tuple, Union from experiment_server._participant_ordering import construct_participant_condition, ORDERING_BEHAVIOUR from experiment_server.utils import ExperimentServerConfigurationExcetion from loguru import logger fro...
46.25
130
0.671908
7981431b310d2a1a4ea52cbe3a97d63570de7c01
6,949
py
Python
exec/exec_pb2.py
mickep76/grpc-exec-example
fd6794a634bdbb6b5f12e173017729bdeb3ba2b8
[ "Apache-2.0" ]
3
2018-07-07T16:52:43.000Z
2018-10-15T14:00:00.000Z
exec/exec_pb2.py
mickep76/grpc-exec-example
fd6794a634bdbb6b5f12e173017729bdeb3ba2b8
[ "Apache-2.0" ]
null
null
null
exec/exec_pb2.py
mickep76/grpc-exec-example
fd6794a634bdbb6b5f12e173017729bdeb3ba2b8
[ "Apache-2.0" ]
null
null
null
# Generated by the protocol buffer compiler. DO NOT EDIT! # source: exec.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.protobuf import reflection as _reflecti...
36.192708
638
0.729745
7981448d7498b4877cbe7f3ea787232428e4841c
13,530
py
Python
constitutive.py
bmullet/neural_conduit
06a9976d8ad69be154907f208dae05d36be0d5ac
[ "MIT" ]
null
null
null
constitutive.py
bmullet/neural_conduit
06a9976d8ad69be154907f208dae05d36be0d5ac
[ "MIT" ]
null
null
null
constitutive.py
bmullet/neural_conduit
06a9976d8ad69be154907f208dae05d36be0d5ac
[ "MIT" ]
null
null
null
import numpy as np from scipy import special as sp from scipy.optimize import fsolve import utils import copy import tensorflow as tf def reformat_params (m): """ output m dictionary from smf or tdc is a bit tedious for what we want here. Need to clean up a few things to make sure that m is suitable fo...
30.066667
135
0.553585
798145bcd2818809abcdf14f89f8a1c037798f49
16,177
py
Python
core/policy/lbc_policy.py
timothijoe/DI-drive
3cddefc85bbbca6bcdd8a4d796decacaf8d81778
[ "Apache-2.0" ]
null
null
null
core/policy/lbc_policy.py
timothijoe/DI-drive
3cddefc85bbbca6bcdd8a4d796decacaf8d81778
[ "Apache-2.0" ]
null
null
null
core/policy/lbc_policy.py
timothijoe/DI-drive
3cddefc85bbbca6bcdd8a4d796decacaf8d81778
[ "Apache-2.0" ]
null
null
null
from collections import namedtuple import os from ding.torch_utils.data_helper import to_device, to_dtype, to_tensor import torch from torchvision import transforms import numpy as np from typing import Dict, List, Any, Optional from .base_carla_policy import BaseCarlaPolicy from core.models import PIDController, Cust...
32.614919
109
0.542313
7981475addbd901664795d7832e8933abc7a17a7
7,024
py
Python
yt/data_objects/index_subobjects/unstructured_mesh.py
tukss/yt
8bf6fce609cad3d4b291ebd94667019ab2e18377
[ "BSD-3-Clause-Clear" ]
null
null
null
yt/data_objects/index_subobjects/unstructured_mesh.py
tukss/yt
8bf6fce609cad3d4b291ebd94667019ab2e18377
[ "BSD-3-Clause-Clear" ]
8
2020-04-02T16:51:49.000Z
2022-01-11T14:12:44.000Z
yt/data_objects/index_subobjects/unstructured_mesh.py
tukss/yt
8bf6fce609cad3d4b291ebd94667019ab2e18377
[ "BSD-3-Clause-Clear" ]
2
2020-08-12T15:46:11.000Z
2021-02-09T13:09:17.000Z
import numpy as np from yt.data_objects.selection_objects.data_selection_objects import ( YTSelectionContainer, ) from yt.funcs import mylog from yt.utilities.lib.mesh_utilities import fill_fcoords, fill_fwidths class UnstructuredMesh(YTSelectionContainer): # This is a base class, not meant to be used direct...
33.607656
86
0.630979
79814859bc52e8f483d0c137b1503ad5177b2c02
2,896
py
Python
steamcalc/calc.py
Simon-Chenzw/steamcalc
4e1e9bd41960aee953b725460ab18520709be1f5
[ "MIT" ]
null
null
null
steamcalc/calc.py
Simon-Chenzw/steamcalc
4e1e9bd41960aee953b725460ab18520709be1f5
[ "MIT" ]
null
null
null
steamcalc/calc.py
Simon-Chenzw/steamcalc
4e1e9bd41960aee953b725460ab18520709be1f5
[ "MIT" ]
null
null
null
import sqlite3 import time from decimal import Decimal from functools import cached_property from typing import List from pydantic import BaseModel, parse_obj_as from rich.table import Column, Table from .cfg import cfg from .db import db class Result(BaseModel): name: str # steam related sell: Decimal...
26.814815
60
0.498964
798148825368de743e5ff6c2dc3e841e88993081
8,582
py
Python
src/thumbs_up/thumbs_up_firmware.py
CrackerCat/Karta
b845928487b50a5b41acd532ae0399177a4356aa
[ "MIT" ]
716
2019-03-20T23:01:52.000Z
2022-03-30T13:11:17.000Z
src/thumbs_up/thumbs_up_firmware.py
CrackerCat/Karta
b845928487b50a5b41acd532ae0399177a4356aa
[ "MIT" ]
29
2019-03-21T13:01:34.000Z
2021-12-19T05:07:42.000Z
src/thumbs_up/thumbs_up_firmware.py
CrackerCat/Karta
b845928487b50a5b41acd532ae0399177a4356aa
[ "MIT" ]
97
2019-03-21T23:40:59.000Z
2022-03-23T23:15:35.000Z
import sark import idc import logging from elementals import Logger from analyzer_utils import * from analyzers.analyzer_factory import createAnalyzer ## # Taken from Karta :) ## class IdaLogHandler(logging.Handler): """Integrate the log messages with IDA's output window.""" def em...
36.991379
125
0.617222
798148b92c0012cc9d3e9c1aceba0adaa12182fd
944
py
Python
homeassistant/components/hue/const.py
MrDelik/core
93a66cc357b226389967668441000498a10453bb
[ "Apache-2.0" ]
30,023
2016-04-13T10:17:53.000Z
2020-03-02T12:56:31.000Z
homeassistant/components/hue/const.py
MrDelik/core
93a66cc357b226389967668441000498a10453bb
[ "Apache-2.0" ]
24,710
2016-04-13T08:27:26.000Z
2020-03-02T12:59:13.000Z
homeassistant/components/hue/const.py
MrDelik/core
93a66cc357b226389967668441000498a10453bb
[ "Apache-2.0" ]
11,956
2016-04-13T18:42:31.000Z
2020-03-02T09:32:12.000Z
"""Constants for the Hue component.""" DOMAIN = "hue" CONF_API_VERSION = "api_version" CONF_IGNORE_AVAILABILITY = "ignore_availability" CONF_SUBTYPE = "subtype" ATTR_HUE_EVENT = "hue_event" SERVICE_HUE_ACTIVATE_SCENE = "hue_activate_scene" ATTR_GROUP_NAME = "group_name" ATTR_SCENE_NAME = "scene_name" ATTR_TRANSITIO...
26.222222
72
0.788136
798149a82067070a3d49fb35dc422ebbfd6378d8
8,462
py
Python
FileWaveAPI.py
peshay/filewave
7c69f9d8d6583e4d79e5243809851181802b6086
[ "MIT" ]
2
2017-04-24T17:32:10.000Z
2018-01-22T20:01:50.000Z
FileWaveAPI.py
peshay/filewave
7c69f9d8d6583e4d79e5243809851181802b6086
[ "MIT" ]
1
2018-12-15T13:03:36.000Z
2018-12-15T13:03:36.000Z
FileWaveAPI.py
peshay/filewave
7c69f9d8d6583e4d79e5243809851181802b6086
[ "MIT" ]
null
null
null
#! /usr/bin/env python """FileWave API Module To simplify usage of FileWave API. https://www.filewave.com Authentication: For Authentication, you need the Shared Key from FileWave. You can get it from FileWave Admin - Preferences - Inventory - Inventory Server - Shared Key If there is no shared key in this secti...
40.104265
314
0.613448
79814aa630a7cde9d5e50f95fe5caa573622f9bb
55
py
Python
twitoff/__init__.py
kvinne-anc/TwittOff
f734323edc9f271f81c217f2cf6e9afdccf964dc
[ "MIT" ]
null
null
null
twitoff/__init__.py
kvinne-anc/TwittOff
f734323edc9f271f81c217f2cf6e9afdccf964dc
[ "MIT" ]
null
null
null
twitoff/__init__.py
kvinne-anc/TwittOff
f734323edc9f271f81c217f2cf6e9afdccf964dc
[ "MIT" ]
null
null
null
from twitoff.app import create_app app = create_app()
13.75
34
0.781818
79814b9e556925cf7273d2bcc6d71ad297c3f89a
2,313
py
Python
assignment1.py
punch2177-cmis/punch2177-cmis-cs2
0cc08fadd53366755de64b7dd2eebbaad7dd6fe8
[ "CC0-1.0" ]
null
null
null
assignment1.py
punch2177-cmis/punch2177-cmis-cs2
0cc08fadd53366755de64b7dd2eebbaad7dd6fe8
[ "CC0-1.0" ]
null
null
null
assignment1.py
punch2177-cmis/punch2177-cmis-cs2
0cc08fadd53366755de64b7dd2eebbaad7dd6fe8
[ "CC0-1.0" ]
null
null
null
myName = "Punch" #defined my name variable myAge = 14.4 #defined my age variable myHeight = 1.59 #defined my height variable sideOfSquare = 4 #define the side of my square lengthOfRectangle = 6 #defined the length of the rectangle heightOfRectangle = 4 #define the height of my rectangle theMonths = 12 #defined the numb...
77.1
178
0.751837
79814bbb0d478525a00a87f8f09884eb41001f19
2,925
py
Python
app/awsc/s3/s3.py
huongdo108/ETL-pipeline-US-immigration-Pyspark-Airflow-AWS
2a31f6810620437b67dcbacc37b97bb88c5f5202
[ "MIT" ]
null
null
null
app/awsc/s3/s3.py
huongdo108/ETL-pipeline-US-immigration-Pyspark-Airflow-AWS
2a31f6810620437b67dcbacc37b97bb88c5f5202
[ "MIT" ]
null
null
null
app/awsc/s3/s3.py
huongdo108/ETL-pipeline-US-immigration-Pyspark-Airflow-AWS
2a31f6810620437b67dcbacc37b97bb88c5f5202
[ "MIT" ]
null
null
null
import boto3 import configparser import logging from pathlib import Path from botocore.exceptions import ClientError import os class S3Resource: def __init__(self, input_bucket, processing_bucket, processed_bucket, KEY, SECRET): self._s3 = boto3.resource("s3", region_name="eu-west-1", aws_access_key_id=KE...
36.5625
117
0.649915
79814c386640d9ec25085c1526e479097491f2a7
1,224
py
Python
catkit/hardware/pyvisa_instrument.py
spacetelescope/instrument-interface-library
c89dfbd87533b7a402d0ce8217daef5be25389c8
[ "BSD-3-Clause" ]
1
2020-09-04T22:50:21.000Z
2020-09-04T22:50:21.000Z
catkit/hardware/pyvisa_instrument.py
spacetelescope/instrument-interface-library
c89dfbd87533b7a402d0ce8217daef5be25389c8
[ "BSD-3-Clause" ]
2
2020-09-08T20:50:39.000Z
2020-09-14T17:52:27.000Z
catkit/hardware/pyvisa_instrument.py
spacetelescope/instrument-interface-library
c89dfbd87533b7a402d0ce8217daef5be25389c8
[ "BSD-3-Clause" ]
null
null
null
import pyvisa from catkit.interfaces.Instrument import Instrument DEFAULT_POLL_TIMEOUT = 60 # This is not the comms timeout but that allowed for total polling duration (seconds). class CommandEchoError(IOError): def __init__(self, cmd, echo): msg = f"The device responded with a command different from ...
27.818182
113
0.619281
79814d6c958436e5a2d9a592e03a1d8e7b4cf810
4,336
py
Python
build/lib/datacube/ui/expression.py
sharat910/datacube-iirs
1b7e2d192d969609756def8923c20899733e695d
[ "Apache-2.0" ]
7
2016-06-29T09:11:46.000Z
2017-08-19T09:54:09.000Z
datacube/ui/expression.py
HarshvardhanM/datacube-iirs
1b7e2d192d969609756def8923c20899733e695d
[ "Apache-2.0" ]
null
null
null
datacube/ui/expression.py
HarshvardhanM/datacube-iirs
1b7e2d192d969609756def8923c20899733e695d
[ "Apache-2.0" ]
5
2016-07-14T17:16:05.000Z
2021-02-13T18:30:03.000Z
# Copyright 2015 Geoscience Australia # # 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 la...
27.617834
102
0.66167
79814eebfda78d20189de41a3f2093b273ca40e2
902
py
Python
jp.atcoder/abc244/abc244_e/30280868.py
kagemeka/atcoder-submissions
91d8ad37411ea2ec582b10ba41b1e3cae01d4d6e
[ "MIT" ]
1
2022-02-09T03:06:25.000Z
2022-02-09T03:06:25.000Z
jp.atcoder/abc244/abc244_e/30280868.py
kagemeka/atcoder-submissions
91d8ad37411ea2ec582b10ba41b1e3cae01d4d6e
[ "MIT" ]
1
2022-02-05T22:53:18.000Z
2022-02-09T01:29:30.000Z
jp.atcoder/abc244/abc244_e/30280868.py
kagemeka/atcoder-submissions
91d8ad37411ea2ec582b10ba41b1e3cae01d4d6e
[ "MIT" ]
null
null
null
def main() -> None: n, m, k, s, t, x = map(int, input().split()) uv = [tuple(map(lambda x: int(x) - 1, input().split())) for _ in range(m)] g = [[] for _ in range(n)] for u, v in uv: g[u].append(v) g[v].append(u) s -= 1 t -= 1 x -= 1 dp = [[0] * 2 for _ in r...
25.055556
79
0.356984
79814eed1692f46758aa55f713c276d306dbc9da
1,350
py
Python
db_tools/import_category_data.py
LauZyHou/MxShop_Back
4e1be205ec88960b26262a51440fd91d952db37d
[ "MIT" ]
1
2021-09-17T02:52:23.000Z
2021-09-17T02:52:23.000Z
db_tools/import_category_data.py
LauZyHou/MxShop_Back
4e1be205ec88960b26262a51440fd91d952db37d
[ "MIT" ]
null
null
null
db_tools/import_category_data.py
LauZyHou/MxShop_Back
4e1be205ec88960b26262a51440fd91d952db37d
[ "MIT" ]
null
null
null
# encoding: utf-8 __author__ = 'mtianyan' __date__ = '2018/2/14 0014 03:31' # 独立使用django的model import sys import os # 获取当前文件的路径,以及路径的父级文件夹名 pwd = os.path.dirname(os.path.realpath(__file__)) # 将项目目录加入setting sys.path.append(pwd + "../") # manage.py中 os.environ.setdefault("DJANGO_SETTINGS_MODULE", "MxShop_Back.settings...
27.55102
71
0.694074
79814f0cd5427faed4196258075a22db36198cbd
1,401
py
Python
setup.py
Spferical/visram
efc70125c06714643c4ea3c4df394e8ddabb5118
[ "MIT" ]
2
2017-12-16T23:58:50.000Z
2018-01-15T11:00:00.000Z
setup.py
Spferical/visram
efc70125c06714643c4ea3c4df394e8ddabb5118
[ "MIT" ]
null
null
null
setup.py
Spferical/visram
efc70125c06714643c4ea3c4df394e8ddabb5118
[ "MIT" ]
null
null
null
#!/usr/bin/env python2 """Setup file for Visram""" from setuptools import setup import visram setup( name='visram', version=visram.__version__, description='Graphical RAM/CPU Visualizer', license='MIT', author='Matthew Pfeiffer', author_email='spferical@gmail.com', url='http://github.com/S...
33.357143
79
0.610992
79814f6f599b9208862db1817515ffc0be569b03
11,789
py
Python
python/bone_armik_addremove.py
VelionaVollerei/PMX-VMD-Scripting-Tools
f935669e3bbc14f4a9b47803a1ccea1464b538b2
[ "MIT" ]
null
null
null
python/bone_armik_addremove.py
VelionaVollerei/PMX-VMD-Scripting-Tools
f935669e3bbc14f4a9b47803a1ccea1464b538b2
[ "MIT" ]
null
null
null
python/bone_armik_addremove.py
VelionaVollerei/PMX-VMD-Scripting-Tools
f935669e3bbc14f4a9b47803a1ccea1464b538b2
[ "MIT" ]
null
null
null
_SCRIPT_VERSION = "Script version: Nuthouse01 - 6/10/2021 - v6.00" # This code is free to use and re-distribute, but I cannot be held responsible for damages that it may or may not cause. ##################### # first import system stuff from typing import List # second, wrap custom imports with a try-except to catc...
43.662963
131
0.724998
79814fb3b85b60d47cd0ddaaf01f91e6f6bf7081
27,628
py
Python
modules/dashboard/analytics.py
haoyuchen1992/CourseBuilder
ba8f0e05c53cc74bb4e46235a7855fdfbd63dff7
[ "Apache-2.0" ]
null
null
null
modules/dashboard/analytics.py
haoyuchen1992/CourseBuilder
ba8f0e05c53cc74bb4e46235a7855fdfbd63dff7
[ "Apache-2.0" ]
null
null
null
modules/dashboard/analytics.py
haoyuchen1992/CourseBuilder
ba8f0e05c53cc74bb4e46235a7855fdfbd63dff7
[ "Apache-2.0" ]
null
null
null
# Copyright 2012 Google Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or ...
40.809453
80
0.589728
7981505924ee78cd968565fded9ad87989a28f63
5,128
py
Python
src/retrieval/bing_search.py
phongnt570/ascent
e26309f69c9688b1db3a9545b71c874a7fb7a74e
[ "Apache-2.0" ]
17
2021-01-29T11:21:09.000Z
2022-01-12T15:30:07.000Z
src/retrieval/bing_search.py
phongnt570/ascent
e26309f69c9688b1db3a9545b71c874a7fb7a74e
[ "Apache-2.0" ]
3
2021-04-23T08:29:16.000Z
2021-07-19T13:25:46.000Z
src/retrieval/bing_search.py
phongnt570/ascent
e26309f69c9688b1db3a9545b71c874a7fb7a74e
[ "Apache-2.0" ]
3
2021-07-09T15:32:18.000Z
2021-10-02T13:24:21.000Z
"""Contains functions to search for relevant documents using the Bing API.""" import http.client import json import logging from typing import List, Tuple, Set from urllib.parse import quote_plus, unquote_plus from nltk.corpus.reader.wordnet import Synset from helper.constants import MANUAL_WN2WP, EN_WIKIPEDIA_PREFI...
36.368794
113
0.572153
79815092e4dba8c11e777566314054b933100bd6
223
py
Python
setup.py
danial29rus/matrixg
3427776a8a491fe7c08abce34b341d1c345a40cf
[ "MIT" ]
null
null
null
setup.py
danial29rus/matrixg
3427776a8a491fe7c08abce34b341d1c345a40cf
[ "MIT" ]
null
null
null
setup.py
danial29rus/matrixg
3427776a8a491fe7c08abce34b341d1c345a40cf
[ "MIT" ]
null
null
null
from setuptools import setup setup(name='matrixg', version='5.2', description='Solve matrix by Gaussian and Jacoby', packages=['matrixg'], author_email='shpeka4kaps4@mail.ru', zip_safe=False)
24.777778
56
0.668161
798150ab4131bb5af7a21fbda8f69bd557458f0b
1,708
py
Python
tests/plugins/test_html.py
Grandient/frictionless-py
8c41b96f2047d573702fe7b34ff7ffbd32c3d815
[ "MIT" ]
247
2020-08-04T16:42:09.000Z
2022-03-30T11:54:54.000Z
tests/plugins/test_html.py
Grandient/frictionless-py
8c41b96f2047d573702fe7b34ff7ffbd32c3d815
[ "MIT" ]
444
2020-07-29T09:13:59.000Z
2022-03-31T14:54:57.000Z
tests/plugins/test_html.py
Grandient/frictionless-py
8c41b96f2047d573702fe7b34ff7ffbd32c3d815
[ "MIT" ]
60
2020-09-04T11:39:34.000Z
2022-03-23T18:59:51.000Z
import pytest from frictionless import Resource from frictionless.plugins.html import HtmlDialect # Parser @pytest.mark.parametrize( "source, selector", [ ("data/table1.html", "table"), ("data/table2.html", "table"), ("data/table3.html", ".mememe"), ], ) def test_html_parser(sour...
29.964912
73
0.589578
798150e032c38fc035ca3ff4694dc09bde7b6ee8
2,522
py
Python
hit_analysis/io/io_utils.py
credo-science/credo-classify
1cc5e00a4df36c4069c0d0fbc19f579780b79ca5
[ "MIT" ]
null
null
null
hit_analysis/io/io_utils.py
credo-science/credo-classify
1cc5e00a4df36c4069c0d0fbc19f579780b79ca5
[ "MIT" ]
8
2021-03-30T12:52:01.000Z
2022-03-12T00:19:45.000Z
hit_analysis/io/io_utils.py
credo-science/credo-classify
1cc5e00a4df36c4069c0d0fbc19f579780b79ca5
[ "MIT" ]
1
2020-06-12T13:29:34.000Z
2020-06-12T13:29:34.000Z
import sys from base64 import decodebytes from pathlib import Path from typing import List, Optional from PIL import Image from hit_analysis.commons.consts import FRAME_CONTENT, ID, FRAME_DECODED def decode_base64(frame_content: str) -> bytes: """ Convert bytes encoded in base64 to array of bytes. :para...
31.525
109
0.665741
7981512dfc9e1e0faeafb0898ffbbda03652e6fb
10,349
py
Python
py/vtdb/vtgatev3.py
kmiku7/vitess-annotated
ca10b6aa42e57ac78ef8b315b93525263ecafc12
[ "BSD-3-Clause" ]
null
null
null
py/vtdb/vtgatev3.py
kmiku7/vitess-annotated
ca10b6aa42e57ac78ef8b315b93525263ecafc12
[ "BSD-3-Clause" ]
null
null
null
py/vtdb/vtgatev3.py
kmiku7/vitess-annotated
ca10b6aa42e57ac78ef8b315b93525263ecafc12
[ "BSD-3-Clause" ]
null
null
null
# Copyright 2013 Google Inc. All Rights Reserved. # Use of this source code is governed by a BSD-style license that can # be found in the LICENSE file. from itertools import izip import logging import random import re from net import bsonrpc from net import gorpc from vtdb import dbexceptions from vtdb import field_t...
31.455927
124
0.682095
7981518847b1252ff845cbfb2b6f9b3b0dd21cc3
5,972
py
Python
skyroute.py
kivaimuinde/SkyRoute
04fa8ecd3575bcbc2db1da32cd50132dfa29436e
[ "MIT" ]
null
null
null
skyroute.py
kivaimuinde/SkyRoute
04fa8ecd3575bcbc2db1da32cd50132dfa29436e
[ "MIT" ]
null
null
null
skyroute.py
kivaimuinde/SkyRoute
04fa8ecd3575bcbc2db1da32cd50132dfa29436e
[ "MIT" ]
null
null
null
from graph_search import bfs, dfs from vc_metro import vc_metro from vc_landmarks import vc_landmarks from landmark_choices import landmark_choices #String which joins all of the landmarks together landmark_string = "" #list below accounts for stations which are closed stations_under_construction = ['Templeton', 'King...
41.472222
137
0.691393
79815251941139e005cf5379980d732ac6364f16
319
py
Python
plot_matrix.py
maurendeviia/pythoncharmers
b5775d0f51a6f2e5dc0365345e0436dea4c72c14
[ "MIT" ]
37
2020-10-01T15:20:12.000Z
2021-10-04T14:17:06.000Z
plot_matrix.py
maurendeviia/pythoncharmers
b5775d0f51a6f2e5dc0365345e0436dea4c72c14
[ "MIT" ]
27
2020-10-01T12:32:41.000Z
2021-10-04T11:05:34.000Z
plot_matrix.py
maurendeviia/pythoncharmers
b5775d0f51a6f2e5dc0365345e0436dea4c72c14
[ "MIT" ]
57
2020-10-01T11:24:26.000Z
2022-02-16T05:09:50.000Z
# Importing necessary libraries import numpy as np from matplotlib import pyplot as plt # Initialising arrays x = np.array([1, 4, 16, 32]) # Plotting to our canvas plt.plot(x) # Display plotted def funcname(parameter_list): """ docstring """ pass print() for target_list in expression_list: pass
15.95
36
0.702194
798152a21d0084126235c34a6bada661f5af6a43
1,984
py
Python
symmetricom_raspberrypi_clock.py
wkumari/symmetricom-nd4-python
08ff7dc56f52667ad885817a3afbb97c879d5f48
[ "Apache-2.0" ]
null
null
null
symmetricom_raspberrypi_clock.py
wkumari/symmetricom-nd4-python
08ff7dc56f52667ad885817a3afbb97c879d5f48
[ "Apache-2.0" ]
null
null
null
symmetricom_raspberrypi_clock.py
wkumari/symmetricom-nd4-python
08ff7dc56f52667ad885817a3afbb97c879d5f48
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # Copyright (c) 2017 Warren Kumari """ This small program uses a Raspberry Pi Zero W to drive the display portion of a Symmetricom ND-4 display. This replaces the processor board of the ND-4, and powers the Pi from the internal ND-4 power supply. The original processor board simply drives a MAX7...
32
116
0.697077
79815313f65271d8d287cda5840876b65bdcd1bf
502
py
Python
codes/Python/MaxSumSubarray.py
zikrullah79/code-examples
44fad795aa6c6bc900ed3a53a6cb4604a8edfd6d
[ "MIT" ]
47
2021-10-01T04:28:03.000Z
2021-10-06T00:09:30.000Z
codes/Python/MaxSumSubarray.py
zikrullah79/code-examples
44fad795aa6c6bc900ed3a53a6cb4604a8edfd6d
[ "MIT" ]
93
2021-10-06T10:53:58.000Z
2021-12-28T01:37:32.000Z
codes/Python/MaxSumSubarray.py
zikrullah79/code-examples
44fad795aa6c6bc900ed3a53a6cb4604a8edfd6d
[ "MIT" ]
185
2021-10-01T04:28:33.000Z
2021-10-06T08:06:10.000Z
def maxSubArraySum(arr,N): maxm_sum=arr[0] curr_sum=0 for ele in arr: curr_sum+=ele if curr_sum>0: if curr_sum>maxm_sum: maxm_sum=curr_sum else: if curr_sum>maxm_sum: maxm_sum=curr_sum curr...
23.904762
40
0.571713
7981531b0d4b5a410ac012c12109cc8adf356a59
7,992
py
Python
xpublish/rest.py
rsignell-usgs/xpublish
3b94a58ee3dbdd5c830c10a58f6b50664ce86d15
[ "MIT" ]
57
2020-06-24T06:42:36.000Z
2022-03-05T21:48:38.000Z
xpublish/rest.py
rsignell-usgs/xpublish
3b94a58ee3dbdd5c830c10a58f6b50664ce86d15
[ "MIT" ]
45
2020-06-23T20:43:50.000Z
2022-03-04T18:31:43.000Z
xpublish/rest.py
davidbrochart/xpublish
9bbaac73413d952dd869dd1cd6ad6b35a9ff4ec6
[ "MIT" ]
12
2020-06-23T20:43:30.000Z
2021-08-07T05:18:34.000Z
import cachey import uvicorn import xarray as xr from fastapi import FastAPI, HTTPException from .dependencies import get_cache, get_dataset, get_dataset_ids from .routers import base_router, common_router, dataset_collection_router, zarr_router from .utils.api import ( SingleDatasetOpenAPIOverrider, check_rou...
31.21875
92
0.645395
7981534b243cc1748cb1eb9b63bc4e6670d75cbf
3,705
py
Python
coremltools/converters/nnssa/commons/builtins/type_int.py
Gerzer/coremltools
47e2010a68668bd1960dca040f5f87c0e66a0cbd
[ "BSD-3-Clause" ]
65
2019-10-02T09:56:22.000Z
2022-03-16T22:41:14.000Z
coremltools/converters/nnssa/commons/builtins/type_int.py
Gerzer/coremltools
47e2010a68668bd1960dca040f5f87c0e66a0cbd
[ "BSD-3-Clause" ]
51
2020-01-13T07:54:13.000Z
2022-03-17T09:11:56.000Z
coremltools/converters/nnssa/commons/builtins/type_int.py
Gerzer/coremltools
47e2010a68668bd1960dca040f5f87c0e66a0cbd
[ "BSD-3-Clause" ]
16
2020-03-06T09:26:03.000Z
2022-02-05T05:35:05.000Z
# -*- coding: utf-8 -*- from __future__ import print_function as _ from __future__ import division as _ from __future__ import absolute_import as _ from .annotate import class_annotate, annotate, delay_type from .get_type_info import get_type_info from .type_bool import bool from .type_spec import * import math def m...
28.5
109
0.609177
7981534d8321e8d920944908d1cc0e5f77ee485d
653
py
Python
solana_nfts/src/connection.py
coherenceNFT/solana-nfts-python
1f89410056f5812e9f55785f0fc8a84afbcb0f5c
[ "MIT" ]
2
2021-12-30T10:59:32.000Z
2022-01-02T09:43:16.000Z
solana_nfts/src/connection.py
coherenceNFT/solana-nfts-python
1f89410056f5812e9f55785f0fc8a84afbcb0f5c
[ "MIT" ]
null
null
null
solana_nfts/src/connection.py
coherenceNFT/solana-nfts-python
1f89410056f5812e9f55785f0fc8a84afbcb0f5c
[ "MIT" ]
2
2021-12-30T10:30:47.000Z
2022-01-29T06:24:26.000Z
import requests from solana_nfts.src.constants import ( TOKEN_VIEWER_BASE_URL ) class SplTokenViewerApiClient(object): def __init__(self): self.base_url = TOKEN_VIEWER_BASE_URL def fetch_nfts_from_wallet_addresses(self, addresses): responses = [] for address in addresses: ...
28.391304
75
0.696784
7981545dcce0892dcc72c22a4ee271eb5a3e6e7a
257
py
Python
GFG/radix_sort.py
Navya-tec/100daysofDSA
fa3338122099afdcf01b0f1725d7c5613b53bed8
[ "MIT" ]
13
2021-02-27T10:27:22.000Z
2021-10-05T13:56:28.000Z
GFG/radix_sort.py
Navya-tec/100daysofDSA
fa3338122099afdcf01b0f1725d7c5613b53bed8
[ "MIT" ]
15
2021-03-06T14:23:49.000Z
2022-01-29T07:10:21.000Z
GFG/radix_sort.py
Navya-tec/100daysofDSA
fa3338122099afdcf01b0f1725d7c5613b53bed8
[ "MIT" ]
24
2021-03-04T06:15:12.000Z
2021-11-14T22:15:13.000Z
arr = [170, 45, 75, 90, 802, 24, 2, 66] n= len(arr) max1 = max(arr) index = 1 while max1//index>0: ## write code here temp = [] for i in range(n): temp.append() index*=10 for i in range(n):
13.526316
39
0.451362
798154a024ce80c11b097d080ae568dd926d2d80
7,458
py
Python
mycroft/client/speech/__main__.py
assistent-cat/mycroft-core
6f8bae6ba136c9dd66ca47aaadd75e214d006190
[ "Apache-2.0" ]
1
2021-01-13T06:56:58.000Z
2021-01-13T06:56:58.000Z
mycroft/client/speech/__main__.py
assistent-cat/mycroft-core
6f8bae6ba136c9dd66ca47aaadd75e214d006190
[ "Apache-2.0" ]
4
2021-06-08T22:45:08.000Z
2022-03-12T00:51:26.000Z
mycroft/client/speech/__main__.py
assistent-cat/mycroft-core
6f8bae6ba136c9dd66ca47aaadd75e214d006190
[ "Apache-2.0" ]
2
2020-09-28T01:38:34.000Z
2020-12-03T03:14:32.000Z
# Copyright 2017 Mycroft AI Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writin...
30.818182
78
0.697506
798154a16f0c538678f2d60085faef08188c643e
271
py
Python
tests/config.py
carlosefr/python-kyototycoon-ng
3d1b5d974b50ea44ed95bee0c08bf00d93ac4834
[ "BSD-3-Clause" ]
7
2016-11-06T05:49:57.000Z
2020-11-23T07:10:35.000Z
tests/config.py
carlosefr/python-kyototycoon-ng
3d1b5d974b50ea44ed95bee0c08bf00d93ac4834
[ "BSD-3-Clause" ]
null
null
null
tests/config.py
carlosefr/python-kyototycoon-ng
3d1b5d974b50ea44ed95bee0c08bf00d93ac4834
[ "BSD-3-Clause" ]
2
2015-10-17T14:27:53.000Z
2015-10-27T19:40:30.000Z
#!/usr/bin/env python # # Copyright 2011, Toru Maesaka # # Redistribution and use of this source code is licensed under # the BSD license. See COPYING file for license description. import os import sys sys.path.insert(0, os.path.join(os.path.split(__file__)[0], '..'))
22.583333
66
0.734317
798156b7411042c6a1b51b1889401989ce62eb79
10,941
py
Python
homeassistant/components/netatmo/camera.py
dummys/home-assistant
dd908caebade15adf061fade686355b94ed2f43a
[ "Apache-2.0" ]
11
2018-02-16T15:35:47.000Z
2020-01-14T15:20:00.000Z
homeassistant/components/netatmo/camera.py
dummys/home-assistant
dd908caebade15adf061fade686355b94ed2f43a
[ "Apache-2.0" ]
51
2020-12-18T07:14:56.000Z
2022-03-31T06:04:05.000Z
homeassistant/components/netatmo/camera.py
dummys/home-assistant
dd908caebade15adf061fade686355b94ed2f43a
[ "Apache-2.0" ]
6
2018-02-04T03:48:55.000Z
2022-01-24T20:37:04.000Z
"""Support for the Netatmo cameras.""" import logging import aiohttp import pyatmo import voluptuous as vol from homeassistant.components.camera import SUPPORT_STREAM, Camera from homeassistant.core import callback from homeassistant.exceptions import PlatformNotReady from homeassistant.helpers import config_validati...
32.274336
96
0.606892
798159f6d7bbb154ae662415afe8ac7d02677a92
71,682
py
Python
Cartwheel/lib/Python26/Lib/site-packages/OpenGL/raw/_WGL_NV.py
MontyThibault/centre-of-mass-awareness
58778f148e65749e1dfc443043e9fc054ca3ff4d
[ "MIT" ]
null
null
null
Cartwheel/lib/Python26/Lib/site-packages/OpenGL/raw/_WGL_NV.py
MontyThibault/centre-of-mass-awareness
58778f148e65749e1dfc443043e9fc054ca3ff4d
[ "MIT" ]
null
null
null
Cartwheel/lib/Python26/Lib/site-packages/OpenGL/raw/_WGL_NV.py
MontyThibault/centre-of-mass-awareness
58778f148e65749e1dfc443043e9fc054ca3ff4d
[ "MIT" ]
null
null
null
# BEGIN GENERATED CONTENT (do not edit below this line) # This content is generated by gengl.py. # Wrapper for http://developer.download.nvidia.com/opengl/includes/wglext.h from OpenGL import platform, constant from ctypes import * c_void = None # H (/home/mcfletch/pylive/OpenGL-ctypes/src/wgl.h:9) # H (/home/mcflet...
59.635607
191
0.794621
79815a748b49509c02d82fb89c184c72b844e7dc
1,656
py
Python
Source/RenderPasses/WhittedRayTracer/Data/WhittedRayTracer.py
gonsolo/Falcor
db27e6fa0efb1c04a51333c14ddfeac309995145
[ "BSD-3-Clause" ]
1,615
2017-07-28T05:41:39.000Z
2022-03-31T16:31:57.000Z
Source/RenderPasses/WhittedRayTracer/Data/WhittedRayTracer.py
gonsolo/Falcor
db27e6fa0efb1c04a51333c14ddfeac309995145
[ "BSD-3-Clause" ]
232
2017-08-03T10:58:41.000Z
2022-03-31T16:17:46.000Z
Source/RenderPasses/WhittedRayTracer/Data/WhittedRayTracer.py
gonsolo/Falcor
db27e6fa0efb1c04a51333c14ddfeac309995145
[ "BSD-3-Clause" ]
383
2017-07-30T04:28:34.000Z
2022-03-30T05:12:13.000Z
from falcor import * def render_graph_WhittedRayTracer(): g = RenderGraph("WhittedRayTracer") loadRenderPassLibrary("GBuffer.dll") loadRenderPassLibrary("WhittedRayTracer.dll") loadRenderPassLibrary("ToneMapper.dll") WhittedRayTracer = createPass("WhittedRayTracer", {'maxBounces': 7, 'texLODMode': ...
57.103448
317
0.7657
79815a8934593579efe04332f983351b8c42821a
1,257
py
Python
setup.py
raphiz/warrant-lite
45d8a856e52bd2b7cf9db71c528eee8ea55c0998
[ "Apache-2.0" ]
9
2018-05-09T03:49:09.000Z
2021-12-23T20:17:06.000Z
setup.py
raphiz/warrant-lite
45d8a856e52bd2b7cf9db71c528eee8ea55c0998
[ "Apache-2.0" ]
7
2018-05-19T18:02:31.000Z
2022-02-03T10:38:03.000Z
setup.py
raphiz/warrant-lite
45d8a856e52bd2b7cf9db71c528eee8ea55c0998
[ "Apache-2.0" ]
9
2018-09-21T05:18:54.000Z
2021-04-30T19:02:09.000Z
from setuptools import setup, find_packages def parse_requirements(filename): """ load requirements from a pip requirements file """ lineiter = (line.strip() for line in open(filename)) return [line for line in lineiter if line and not line.startswith("#")] version = '1.0.3' README="""Small Python libr...
34.916667
298
0.707239
79815b86cda083511259fda5dadc5934b602f903
6,506
py
Python
mess_io/reader/rates.py
mobergd/interfaces
82705d2173b9d213684da80913ec0593d30cdbe1
[ "Apache-2.0" ]
null
null
null
mess_io/reader/rates.py
mobergd/interfaces
82705d2173b9d213684da80913ec0593d30cdbe1
[ "Apache-2.0" ]
null
null
null
mess_io/reader/rates.py
mobergd/interfaces
82705d2173b9d213684da80913ec0593d30cdbe1
[ "Apache-2.0" ]
null
null
null
""" Reads the output of a MESS calculation for the high-pressure and pressure-dependent rate constants corresponding to a given reaction """ def highp_ks(output_string, reactant, product): """ Reads rate constants for a reaction at the high-pressure limit :param str output_string: string of lines fo...
36.144444
77
0.63941
79815b8b536eac9bb0145eb2752cae3c356e9d4a
2,672
py
Python
mergify_engine/tests/unit/test_duplicate.py
mauricedb/mergify-engine
b7c9c66e830a4c0c1ab54459a265c90cc67c968d
[ "Apache-2.0" ]
null
null
null
mergify_engine/tests/unit/test_duplicate.py
mauricedb/mergify-engine
b7c9c66e830a4c0c1ab54459a265c90cc67c968d
[ "Apache-2.0" ]
null
null
null
mergify_engine/tests/unit/test_duplicate.py
mauricedb/mergify-engine
b7c9c66e830a4c0c1ab54459a265c90cc67c968d
[ "Apache-2.0" ]
null
null
null
# -*- encoding: utf-8 -*- # # Copyright © 2018 Julien Danjou <julien@danjou.info> # # 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 # # Unles...
26.455446
84
0.684506
79815d945c947c4a5418075be6f85a44723078d0
9,058
py
Python
python/ccxt/async/bitso.py
destenson/ccxt--ccxt
3928a058cb1ecf00d11309c7812a0fcdb502080a
[ "MIT" ]
null
null
null
python/ccxt/async/bitso.py
destenson/ccxt--ccxt
3928a058cb1ecf00d11309c7812a0fcdb502080a
[ "MIT" ]
null
null
null
python/ccxt/async/bitso.py
destenson/ccxt--ccxt
3928a058cb1ecf00d11309c7812a0fcdb502080a
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from ccxt.async.base.exchange import Exchange from ccxt.base.errors import ExchangeError class bitso (Exchange): def describe(self): return self.deep_extend(super(bitso, self).describe(), { 'id': 'bitso', 'name': 'Bitso', 'countries': 'MX', # ...
37.122951
126
0.460477
79815e201e9ab8af8e73dfe18b6bebcfe14889c4
3,930
py
Python
pglgen/xmlparse.py
mdsitton/pyogl
16666dfdb9ad0606d9737bb0ed324ac7f16e8b47
[ "BSD-2-Clause" ]
null
null
null
pglgen/xmlparse.py
mdsitton/pyogl
16666dfdb9ad0606d9737bb0ed324ac7f16e8b47
[ "BSD-2-Clause" ]
null
null
null
pglgen/xmlparse.py
mdsitton/pyogl
16666dfdb9ad0606d9737bb0ed324ac7f16e8b47
[ "BSD-2-Clause" ]
null
null
null
from xml.parsers import expat class TagStack(object): def __init__(self): self.tags = [] self.args = [] self.data = [] self.dataAdded = [] self.stackSize = 0 self.frameHasData = False def push(self, tag, args): self.tags.append(tag) self.args.ap...
26.375839
74
0.585242
79815fef55b901346bc0237f30f4b1586b986017
2,647
py
Python
data/seattle_rain_modify.py
ucds-sg/h2oai
7042860767dc25d1a7d7122103bbd5016d02df53
[ "Apache-2.0" ]
null
null
null
data/seattle_rain_modify.py
ucds-sg/h2oai
7042860767dc25d1a7d7122103bbd5016d02df53
[ "Apache-2.0" ]
null
null
null
data/seattle_rain_modify.py
ucds-sg/h2oai
7042860767dc25d1a7d7122103bbd5016d02df53
[ "Apache-2.0" ]
null
null
null
"""Transpose the Monthly Seattle Rain Inches data set for Time Series use cases""" # Contributors: Michelle Tanco - michelle.tanco@h2oai # Created: October 18th, 2019 # Last Updated: October 18th, 2019 from typing import Union, List from h2oaicore.data import CustomData import datatable as dt import numpy as np impor...
41.359375
105
0.648281
79816009255dce9c48f408bf94779f9fb46831f7
10,566
py
Python
tests/test_drivehandler.py
nehak0601/gramex
0354f58efe5e1fe7e5339c91dcf6baa38bcc50b7
[ "MIT" ]
null
null
null
tests/test_drivehandler.py
nehak0601/gramex
0354f58efe5e1fe7e5339c91dcf6baa38bcc50b7
[ "MIT" ]
null
null
null
tests/test_drivehandler.py
nehak0601/gramex
0354f58efe5e1fe7e5339c91dcf6baa38bcc50b7
[ "MIT" ]
null
null
null
import os import json import time import requests import pandas as pd import gramex.data from shutil import rmtree from mimetypes import guess_type from tornado.web import create_signed_value from gramex import conf from gramex.http import (OK, BAD_REQUEST, NOT_FOUND, REQUEST_ENTITY_TOO_LARGE, ...
45.543103
98
0.573065
79816071e03cf40464f5e3d1341f96acf9b837dc
4,850
py
Python
src/experimental_code/graphframe_ex2_bv.py
papaemman/Mining-of-Massive-Datasets-AUTh
99a92e133bb21e4a86e9f7b3b704d258007d5f15
[ "MIT" ]
null
null
null
src/experimental_code/graphframe_ex2_bv.py
papaemman/Mining-of-Massive-Datasets-AUTh
99a92e133bb21e4a86e9f7b3b704d258007d5f15
[ "MIT" ]
null
null
null
src/experimental_code/graphframe_ex2_bv.py
papaemman/Mining-of-Massive-Datasets-AUTh
99a92e133bb21e4a86e9f7b3b704d258007d5f15
[ "MIT" ]
2
2021-08-31T20:29:22.000Z
2021-10-01T10:20:16.000Z
from pyspark import SparkContext from pyspark.sql import SparkSession, Row from pyspark.sql.types import StructType, StructField, StringType, FloatType from pyspark.sql.functions import udf,lit,col,when from pyspark import StorageLevel from graphframes.examples import Graphs from graphframes import * from functools imp...
38.188976
208
0.605979
79816093c7efa3b94a57fe0909712c2894b55aab
7,971
py
Python
proxy_pool/orm.py
ruxtain/proxy_pool
482b9e9e58dc70c59dfd79e290eeefd399f745c8
[ "MIT" ]
3
2018-12-27T11:59:37.000Z
2021-07-07T21:27:45.000Z
proxy_pool/orm.py
ruxtain/proxy_pool
482b9e9e58dc70c59dfd79e290eeefd399f745c8
[ "MIT" ]
null
null
null
proxy_pool/orm.py
ruxtain/proxy_pool
482b9e9e58dc70c59dfd79e290eeefd399f745c8
[ "MIT" ]
null
null
null
''' A mini ORM for mongodb. It's `OBSOLETED` already. But I keep it here for future reference. ''' import random import pymongo from datetime import datetime from proxy_pool import settings class ClassPropertyDescriptor(object): ''' classmethod decorator thanks to `Mahmoud Abdelkader`: https://stack...
31.756972
196
0.582361
79816122c54b9006ebd1633e3f15c372116e76e0
847
py
Python
ComicRN.py
Corey-Evans/sickbeard_mp4_automator
ac2f8b2f5d7b39291f2aa782b44758e15e8e2f5a
[ "MIT" ]
null
null
null
ComicRN.py
Corey-Evans/sickbeard_mp4_automator
ac2f8b2f5d7b39291f2aa782b44758e15e8e2f5a
[ "MIT" ]
null
null
null
ComicRN.py
Corey-Evans/sickbeard_mp4_automator
ac2f8b2f5d7b39291f2aa782b44758e15e8e2f5a
[ "MIT" ]
null
null
null
#!/usr/bin/env python # ############################################################################## ### SABNZBD POST-PROCESSING SCRIPT ### # # Move and rename comics according to Mylar's autoProcessComics.cfg # # NOTE: This script requires Python to be installed on your system...
32.576923
116
0.567887
798162974ea84d3e4e326c37be164aefa60be3c6
268
py
Python
app/domain/value_objects/email.py
gabrielpereiram10/clean-api
0b8ccdb9745f098c9748b73b6f79b4e256fbbb6b
[ "MIT" ]
1
2021-01-26T21:01:23.000Z
2021-01-26T21:01:23.000Z
app/domain/value_objects/email.py
gabrielpereiram10/clean-api
0b8ccdb9745f098c9748b73b6f79b4e256fbbb6b
[ "MIT" ]
null
null
null
app/domain/value_objects/email.py
gabrielpereiram10/clean-api
0b8ccdb9745f098c9748b73b6f79b4e256fbbb6b
[ "MIT" ]
null
null
null
class Email: def __init__(self, value: str): self._set_value(value) @property def value(self) -> str: return self._value def _set_value(self, email: str): if not email: raise ValueError self._value = email
20.615385
37
0.58209
798163e9fb9f53b92d44d0ae0707da3f3e48d183
402
py
Python
catch/datasets/bat_mumps_rubulavirus.py
broadinstitute/catch
2fedca15f921116f580de8b2ae7ac9972932e59e
[ "MIT" ]
58
2018-01-24T16:31:37.000Z
2022-02-25T07:46:35.000Z
catch/datasets/bat_mumps_rubulavirus.py
broadinstitute/catch
2fedca15f921116f580de8b2ae7ac9972932e59e
[ "MIT" ]
29
2018-04-17T17:36:06.000Z
2022-02-25T11:48:58.000Z
catch/datasets/bat_mumps_rubulavirus.py
broadinstitute/catch
2fedca15f921116f580de8b2ae7ac9972932e59e
[ "MIT" ]
16
2018-05-23T12:19:41.000Z
2021-08-09T04:16:00.000Z
"""Dataset with 'Bat mumps rubulavirus' sequences. A dataset with 1 'Bat mumps rubulavirus' genomes. THIS PYTHON FILE WAS GENERATED BY A COMPUTER PROGRAM! DO NOT EDIT! """ import sys from catch.datasets import GenomesDatasetSingleChrom ds = GenomesDatasetSingleChrom(__name__, __file__, __spec__) ds.add_fasta_path...
25.125
71
0.793532
7981642ee9fc93e1c91970a4b62b14af301dd8c0
3,461
py
Python
avaxpython/vms/platformvm/import_tx.py
jgeofil/avax-python
b09e78e3d7e1c35db5ae42e3918e960e775f2d45
[ "MIT" ]
25
2021-05-16T23:43:47.000Z
2022-03-29T03:08:30.000Z
avaxpython/vms/platformvm/import_tx.py
zefonseca/ava-python
9c72af7c720edfab9c73379a102cf6a11d864ebd
[ "MIT" ]
2
2021-04-26T11:43:22.000Z
2021-06-04T07:55:22.000Z
avaxpython/vms/platformvm/import_tx.py
jgeofil/avax-python
b09e78e3d7e1c35db5ae42e3918e960e775f2d45
[ "MIT" ]
4
2021-08-06T10:55:58.000Z
2022-03-29T08:03:05.000Z
# avax-python : Python tools for the exploration of the Avalanche AVAX network. # # Find tutorials and use cases at https://crypto.bi """ Copyright (C) 2021 - crypto.bi Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), t...
43.2625
463
0.7128
79816563a9fc4699aaba010f73de97af3d12bc83
9,213
py
Python
source/office/outlook_mail.py
sailzeng/OAMail
22d36e94393eb0d5d6605a65b9f80fb008ff6dc5
[ "Apache-2.0" ]
null
null
null
source/office/outlook_mail.py
sailzeng/OAMail
22d36e94393eb0d5d6605a65b9f80fb008ff6dc5
[ "Apache-2.0" ]
null
null
null
source/office/outlook_mail.py
sailzeng/OAMail
22d36e94393eb0d5d6605a65b9f80fb008ff6dc5
[ "Apache-2.0" ]
null
null
null
import win32com.client as win32 import enum class SendMailInfo(object): """ 搜索替换的字符串 """ def __init__(self): self.sender = "" self.to = "" self.cc = "" self.subject = "" self.body = "" self.attachment_list = None # 邮件处理,处理OUTLOOK class OutlookMail(obj...
30.812709
101
0.583523
798166af705b775d86f2fbf559f35c96970f4919
10,515
py
Python
envoy.distribution.repo/tests/test_abstract.py
Nordix/pytooling
b48e70e9098c283d0f17db8016d2f32a2b103a57
[ "Apache-2.0" ]
null
null
null
envoy.distribution.repo/tests/test_abstract.py
Nordix/pytooling
b48e70e9098c283d0f17db8016d2f32a2b103a57
[ "Apache-2.0" ]
null
null
null
envoy.distribution.repo/tests/test_abstract.py
Nordix/pytooling
b48e70e9098c283d0f17db8016d2f32a2b103a57
[ "Apache-2.0" ]
null
null
null
from unittest.mock import AsyncMock, MagicMock, PropertyMock import pytest import abstracts from aio.run.runner import Runner from envoy.base import utils from envoy.distribution import repo @abstracts.implementer(repo.ARepoBuildingRunner) class DummyRepoBuildingRunner: def __init__(self): pass ...
28.266129
71
0.62292
79816859a07d75776beb42c9576c707178bc3159
2,487
py
Python
src/utils.py
iamkaiwei/kaggle-landmark-recognition-2020-1st-place
97df71ecfd37122730b7f0b29fde09ac36358609
[ "MIT" ]
249
2020-10-04T09:13:14.000Z
2022-03-29T14:09:33.000Z
src/utils.py
iamkaiwei/kaggle-landmark-recognition-2020-1st-place
97df71ecfd37122730b7f0b29fde09ac36358609
[ "MIT" ]
2
2021-01-05T09:34:15.000Z
2021-08-03T06:47:48.000Z
src/utils.py
iamkaiwei/kaggle-landmark-recognition-2020-1st-place
97df71ecfd37122730b7f0b29fde09ac36358609
[ "MIT" ]
53
2020-10-04T09:14:00.000Z
2022-03-01T02:32:32.000Z
from conf import * import torch import random import numpy as np import os from typing import Dict, Tuple, Any from sklearn.metrics import roc_auc_score from scipy.special import expit, softmax from sklearn.metrics import precision_score def set_seed(seed=1234): random.seed(seed) os.environ['PYTHONHASHSEE...
34.541667
101
0.687575
798168862c76e7ee67c149ab9536c4f9192cac77
1,554
py
Python
chexpert/data/transforms.py
PJansson/Chexpert
94b20deedbca9261eaf82b9a4309bb74d42ea8b0
[ "Apache-2.0" ]
null
null
null
chexpert/data/transforms.py
PJansson/Chexpert
94b20deedbca9261eaf82b9a4309bb74d42ea8b0
[ "Apache-2.0" ]
null
null
null
chexpert/data/transforms.py
PJansson/Chexpert
94b20deedbca9261eaf82b9a4309bb74d42ea8b0
[ "Apache-2.0" ]
null
null
null
import cv2 import numpy as np from albumentations import ImageOnlyTransform class TemplateMatch(ImageOnlyTransform): def __init__(self, data_dir, dataset, template_size=320, always_apply=True, p=1.0): super().__init__(always_apply, p) template_frontal = f"{data_dir}/{dataset}/templates/frontal.jpg...
36.139535
87
0.63964
79816a1b9d67612f764bbc83da8940c0351d2503
9,301
py
Python
ansible/modules/system/filesystem.py
EnjoyLifeFund/py36pkgs
0ac677fbbfa7b6d8c527fe2c759ba05117b07fd2
[ "MIT", "BSD-2-Clause", "BSD-3-Clause" ]
null
null
null
ansible/modules/system/filesystem.py
EnjoyLifeFund/py36pkgs
0ac677fbbfa7b6d8c527fe2c759ba05117b07fd2
[ "MIT", "BSD-2-Clause", "BSD-3-Clause" ]
null
null
null
ansible/modules/system/filesystem.py
EnjoyLifeFund/py36pkgs
0ac677fbbfa7b6d8c527fe2c759ba05117b07fd2
[ "MIT", "BSD-2-Clause", "BSD-3-Clause" ]
null
null
null
#!/usr/bin/python # -*- coding: utf-8 -*- # (c) 2013, Alexander Bulimov <lazywolf0@gmail.com> # # This file is part of Ansible # # Ansible is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of t...
34.321033
134
0.572304
79816a3ff90ad4d9dc117878c9cc7749f554c02a
5,437
py
Python
pcrc/connection/patch.py
YehowahLiu/PCRC
2338522402bf5c97a2346744442e23cdb8327630
[ "Apache-2.0" ]
null
null
null
pcrc/connection/patch.py
YehowahLiu/PCRC
2338522402bf5c97a2346744442e23cdb8327630
[ "Apache-2.0" ]
null
null
null
pcrc/connection/patch.py
YehowahLiu/PCRC
2338522402bf5c97a2346744442e23cdb8327630
[ "Apache-2.0" ]
null
null
null
from threading import Lock from typing import Set from redbaron import RedBaron, IfelseblockNode, AssignmentNode, WithNode from pcrc.utils import redbaron_util __patch_lock = Lock() __patched = False def patch_pycraft(): global __patched with __patch_lock: if __patched: return __patched = True print('Pa...
36.246667
159
0.820673