hexsha
stringlengths
40
40
size
int64
3
1.03M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
3
972
max_stars_repo_name
stringlengths
6
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
972
max_issues_repo_name
stringlengths
6
130
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
3
972
max_forks_repo_name
stringlengths
6
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
3
1.03M
avg_line_length
float64
1.13
941k
max_line_length
int64
2
941k
alphanum_fraction
float64
0
1
1dead6613b5cfb747ba9748baa073b14401914b5
4,867
py
Python
test-runner/test_connect_disconnect_fi.py
v-greach/iot-sdks-e2e-fx
2ceb178c886ced2a639dcd61bf11206a58685509
[ "MIT" ]
null
null
null
test-runner/test_connect_disconnect_fi.py
v-greach/iot-sdks-e2e-fx
2ceb178c886ced2a639dcd61bf11206a58685509
[ "MIT" ]
null
null
null
test-runner/test_connect_disconnect_fi.py
v-greach/iot-sdks-e2e-fx
2ceb178c886ced2a639dcd61bf11206a58685509
[ "MIT" ]
null
null
null
#!/usr/bin/env python # Copyright (c) Microsoft. All rights reserved. # Licensed under the MIT license. See LICENSE file in the project root for # full license information. import sys import pytest import connections from adapters import print_message as log_message import urllib from edgehub_control import ( dis...
29.858896
144
0.80789
da72758b24ca391b9e620835788c941645551ef8
4,417
py
Python
custom_components/xiaomi_miot/device_tracker.py
toyan/hass-xiaomi-miot
7fae0c2506e46f922312c23a34008506de99221f
[ "Apache-2.0" ]
919
2020-12-07T07:53:32.000Z
2022-03-31T07:37:30.000Z
custom_components/xiaomi_miot/device_tracker.py
toyan/hass-xiaomi-miot
7fae0c2506e46f922312c23a34008506de99221f
[ "Apache-2.0" ]
481
2020-12-25T08:09:38.000Z
2022-03-31T18:05:24.000Z
custom_components/xiaomi_miot/device_tracker.py
toyan/hass-xiaomi-miot
7fae0c2506e46f922312c23a34008506de99221f
[ "Apache-2.0" ]
105
2020-12-07T08:31:24.000Z
2022-03-31T17:43:19.000Z
"""Support for Xiaomi device tracker.""" import logging from datetime import timedelta from homeassistant.const import * # noqa: F401 from homeassistant.components.device_tracker import ( DOMAIN as ENTITY_DOMAIN, ) from homeassistant.components.device_tracker.config_entry import TrackerEntity from . import ( ...
33.976923
111
0.678741
e69d6d65348df773713e85e34ace077e2ef1e4ad
1,026
py
Python
neutron/plugins/plumgrid/plumgrid_plugin/plumgrid_plugin.py
wxjinyq01/esdk_neutron_ac
96c0eff2321a775798d08b62afa4672d91fff48e
[ "Apache-2.0" ]
null
null
null
neutron/plugins/plumgrid/plumgrid_plugin/plumgrid_plugin.py
wxjinyq01/esdk_neutron_ac
96c0eff2321a775798d08b62afa4672d91fff48e
[ "Apache-2.0" ]
null
null
null
neutron/plugins/plumgrid/plumgrid_plugin/plumgrid_plugin.py
wxjinyq01/esdk_neutron_ac
96c0eff2321a775798d08b62afa4672d91fff48e
[ "Apache-2.0" ]
null
null
null
# Copyright 2013 PLUMgrid, 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 ...
39.461538
78
0.688109
898d0f5659515c831404a3048350b86178d66bb3
20,338
py
Python
qctrlopencontrols/dynamic_decoupling_sequences/dynamic_decoupling_sequence.py
random7s/python-open-controls
a69886090b3706e8e70d1ca9faa4f78ce6e65c86
[ "Apache-2.0" ]
79
2019-04-17T04:42:39.000Z
2022-03-18T02:56:23.000Z
qctrlopencontrols/dynamic_decoupling_sequences/dynamic_decoupling_sequence.py
random7s/python-open-controls
a69886090b3706e8e70d1ca9faa4f78ce6e65c86
[ "Apache-2.0" ]
58
2019-05-06T02:18:53.000Z
2022-01-23T22:40:43.000Z
qctrlopencontrols/dynamic_decoupling_sequences/dynamic_decoupling_sequence.py
random7s/python-open-controls
a69886090b3706e8e70d1ca9faa4f78ce6e65c86
[ "Apache-2.0" ]
30
2019-04-18T00:46:10.000Z
2022-03-29T16:51:47.000Z
# Copyright 2021 Q-CTRL # # 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, softwa...
37.523985
98
0.643721
b66f375f22432bc2afe4b0dff5dbba4e183a68d0
1,693
py
Python
tests/pytest/session_overrides/session_locale/test_manual_injection.py
tactlabs/randum
11274a52d206f9fcc2ec1a8935257d93fd83fe66
[ "MIT" ]
null
null
null
tests/pytest/session_overrides/session_locale/test_manual_injection.py
tactlabs/randum
11274a52d206f9fcc2ec1a8935257d93fd83fe66
[ "MIT" ]
null
null
null
tests/pytest/session_overrides/session_locale/test_manual_injection.py
tactlabs/randum
11274a52d206f9fcc2ec1a8935257d93fd83fe66
[ "MIT" ]
null
null
null
"""TEST NOTES: The following tests cover cases where a ``randum_session_locale`` fixture was defined by the user as well as non-autouse ``randum_locale`` and ``randum_seed`` fixtures. The resulting behavior of the ``randum`` fixture will vary dependening on which fixtures are injected. """ from random import Random ...
29.701754
92
0.757826
fb4cf439f5a826cc375c161cda28c0454f05c970
1,703
py
Python
src/ws_disseminator/kafka_consumers/kafka_consumer.py
EzePze/l3_data_collection
ec147fec0308f83b479878bc93ed6111aa0f5ea2
[ "MIT" ]
1
2022-01-28T11:41:55.000Z
2022-01-28T11:41:55.000Z
src/ws_disseminator/kafka_consumers/kafka_consumer.py
EzePze/l3_data_collection
ec147fec0308f83b479878bc93ed6111aa0f5ea2
[ "MIT" ]
null
null
null
src/ws_disseminator/kafka_consumers/kafka_consumer.py
EzePze/l3_data_collection
ec147fec0308f83b479878bc93ed6111aa0f5ea2
[ "MIT" ]
null
null
null
from confluent_kafka import Consumer, KafkaError, KafkaException import sys class KafkaConsumer(): def __init__(self, topic): suffix = "" if topic not in ("BTCUSDT", "BTCUSD"): suffix = "-raw" self.topic = "test-" + topic + suffix self.conf = { 'bootstrap.se...
29.877193
86
0.527305
9afd62b29ced8e30aa928c6a2ffcd6d7c73a513f
778
py
Python
examples/loop_diffusion.py
DDMGNI/viIMHD2D
d7c3546a6245fa0b12538a785146af3895f16e18
[ "MIT" ]
null
null
null
examples/loop_diffusion.py
DDMGNI/viIMHD2D
d7c3546a6245fa0b12538a785146af3895f16e18
[ "MIT" ]
null
null
null
examples/loop_diffusion.py
DDMGNI/viIMHD2D
d7c3546a6245fa0b12538a785146af3895f16e18
[ "MIT" ]
null
null
null
import numpy as np A0 = 1E-3 R0 = 0.3 p0 = 1. u0 = 0. vx = 2. * u0 vy = 1. * u0 #nx = 128 #ny = 64 nx = 64 ny = 32 x1 = -1.0 x2 = +1.0 y1 = -0.5 y2 = +0.5 hx = (x2-x1) / nx hy = (y2-y1) / ny def magnetic_potential(x, y): r = np.sqrt(x**2 + y**2) if r < R0: A = A0 * (R0 - r) else: ...
12.754098
40
0.503856
008d8a06ba347a390b1232860370ef34fa4a666a
15,561
py
Python
doc/extensions/zephyr/application.py
jakub-uC/zephyr
d66d748b710ef7520d25d01752ea8a8c89c9e788
[ "Apache-2.0" ]
7
2021-07-27T00:12:02.000Z
2022-03-09T14:40:13.000Z
doc/extensions/zephyr/application.py
jakub-uC/zephyr
d66d748b710ef7520d25d01752ea8a8c89c9e788
[ "Apache-2.0" ]
22
2019-08-09T11:32:02.000Z
2022-03-09T16:33:19.000Z
doc/extensions/zephyr/application.py
jakub-uC/zephyr
d66d748b710ef7520d25d01752ea8a8c89c9e788
[ "Apache-2.0" ]
5
2020-12-05T01:03:13.000Z
2022-01-28T13:39:17.000Z
# Copyright (c) 2017 Open Source Foundries Limited. # # SPDX-License-Identifier: Apache-2.0 '''Sphinx extensions related to managing Zephyr applications.''' from docutils import nodes from docutils.parsers.rst import Directive from docutils.parsers.rst import directives # TODO: extend and modify this for Windows. #...
37.05
154
0.56783
e7ebc55fbfe1e7abb0f6dd0ce8f86bdb1276f844
4,396
py
Python
reproducible_research/generate_data.py
CosmoStat/OSCAR
ed0a8b784ce895f07f92dc21575d4fd5f4e5b282
[ "MIT" ]
5
2020-02-11T11:20:08.000Z
2021-06-28T10:07:20.000Z
reproducible_research/generate_data.py
CosmoStat/OSCAR
ed0a8b784ce895f07f92dc21575d4fd5f4e5b282
[ "MIT" ]
null
null
null
reproducible_research/generate_data.py
CosmoStat/OSCAR
ed0a8b784ce895f07f92dc21575d4fd5f4e5b282
[ "MIT" ]
2
2021-01-27T15:30:54.000Z
2021-06-04T20:13:18.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Fri Dec 20 11:42:54 2019 @authors: fnammour and aguinot """ from astropy.io import fits import galsim import numpy as np from score import score import os def check_dir(dir_path): if not os.path.exists(dir_path): os.makedirs(dir_path) ...
28.921053
108
0.702912
59ba6b76c19ab18e117fa75081eeb33f36dc579c
9,414
py
Python
sample-apps/deepedit_multilabel/lib/train.py
IntroAI-termproject/MONAILabel
6a0fcc797e24aff1a1582088bae71973b2b6582e
[ "Apache-2.0" ]
null
null
null
sample-apps/deepedit_multilabel/lib/train.py
IntroAI-termproject/MONAILabel
6a0fcc797e24aff1a1582088bae71973b2b6582e
[ "Apache-2.0" ]
null
null
null
sample-apps/deepedit_multilabel/lib/train.py
IntroAI-termproject/MONAILabel
6a0fcc797e24aff1a1582088bae71973b2b6582e
[ "Apache-2.0" ]
null
null
null
# Copyright 2020 - 2021 MONAI Consortium # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # http://www.apache.org/licenses/LICENSE-2.0 # Unless required by applicable law or agreed to in wri...
38.42449
119
0.607606
533570e7784509774027a912813b0ed5e6d4006b
2,808
py
Python
gyun/cli/iaas_client/actions/volume/create_volumes.py
gyun-gome/gyun-cli
275b6664335e2ef21a01a48f8c06d6a89dd63467
[ "Apache-2.0" ]
null
null
null
gyun/cli/iaas_client/actions/volume/create_volumes.py
gyun-gome/gyun-cli
275b6664335e2ef21a01a48f8c06d6a89dd63467
[ "Apache-2.0" ]
null
null
null
gyun/cli/iaas_client/actions/volume/create_volumes.py
gyun-gome/gyun-cli
275b6664335e2ef21a01a48f8c06d6a89dd63467
[ "Apache-2.0" ]
null
null
null
# encoding: utf-8 # ========================================================================= # ©2017-2018 北京国美云服科技有限公司 # ------------------------------------------------------------------------- # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this work except in compliance with the ...
41.294118
97
0.556624
09b4f02bc7e677d75cb574aac32ecfdfedfa9707
1,491
py
Python
examples/widgets/testdata.py
NeolithEra/Flask-AppBuilder
d9561bf89d925a2f5d74c226318884733b52718f
[ "BSD-3-Clause" ]
3,862
2015-01-01T11:59:24.000Z
2022-03-31T19:23:55.000Z
examples/widgets/testdata.py
NeolithEra/Flask-AppBuilder
d9561bf89d925a2f5d74c226318884733b52718f
[ "BSD-3-Clause" ]
1,566
2015-01-01T23:26:11.000Z
2022-03-31T16:23:08.000Z
examples/widgets/testdata.py
NeolithEra/Flask-AppBuilder
d9561bf89d925a2f5d74c226318884733b52718f
[ "BSD-3-Clause" ]
1,352
2015-01-02T10:45:59.000Z
2022-03-26T20:56:48.000Z
from app import db from app.models import ContactGroup, Gender, Contact import random from datetime import datetime def get_random_name(names_list, size=1): name_lst = [ names_list[random.randrange(0, len(names_list))].decode("utf-8").capitalize() for i in range(0, size) ] return " ".join(...
27.109091
85
0.657277
aa3bdfddea725d4a6109e503b2aa2233b7548739
1,399
py
Python
Redes-de-computadores/Sockets_SemMinhaAutoria/python2.7/10-tcp-handlingConnectionsUsingThreads.py
iOsnaaente/Faculdade_ECA-UFSM
aea8b8d66169b073c439b47ad990e45695cbe953
[ "MIT" ]
null
null
null
Redes-de-computadores/Sockets_SemMinhaAutoria/python2.7/10-tcp-handlingConnectionsUsingThreads.py
iOsnaaente/Faculdade_ECA-UFSM
aea8b8d66169b073c439b47ad990e45695cbe953
[ "MIT" ]
null
null
null
Redes-de-computadores/Sockets_SemMinhaAutoria/python2.7/10-tcp-handlingConnectionsUsingThreads.py
iOsnaaente/Faculdade_ECA-UFSM
aea8b8d66169b073c439b47ad990e45695cbe953
[ "MIT" ]
null
null
null
import socket import sys from thread import * HOST = '' # Symbolic name meaning all available interfaces PORT = 8888 # Arbitrary non-privileged port s = socket.socket(socket.AF_INET, socket.SOCK_STREAM) print 'Socket created' #Bind socket to local host and port try: s.bind((HOST, PORT)) except socket.error , m...
26.903846
120
0.681916
afa1e158965ec02f4d05db78c25d202955c5e3d0
2,524
py
Python
code-samples/language/v1/python/analyze_entity_sentiment_request_language_entity_sentiment_gcs.py
tswast/gapic-docs-samples
16976b148fb6eb53a8a685d475dcdb713ceb9e60
[ "Apache-2.0" ]
null
null
null
code-samples/language/v1/python/analyze_entity_sentiment_request_language_entity_sentiment_gcs.py
tswast/gapic-docs-samples
16976b148fb6eb53a8a685d475dcdb713ceb9e60
[ "Apache-2.0" ]
null
null
null
code-samples/language/v1/python/analyze_entity_sentiment_request_language_entity_sentiment_gcs.py
tswast/gapic-docs-samples
16976b148fb6eb53a8a685d475dcdb713ceb9e60
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # # Copyright 2019 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law...
31.55
87
0.705626
2936b9481faea528fb626a7b14b081625d8f164a
14,321
py
Python
src/olympia/addons/tests/test_utils_.py
ruchikabgosain/addons-server
96d6626881df90b6d14902d7f0d480382a90ea16
[ "BSD-3-Clause" ]
1
2019-08-19T08:31:08.000Z
2019-08-19T08:31:08.000Z
src/olympia/addons/tests/test_utils_.py
ruchikabgosain/addons-server
96d6626881df90b6d14902d7f0d480382a90ea16
[ "BSD-3-Clause" ]
null
null
null
src/olympia/addons/tests/test_utils_.py
ruchikabgosain/addons-server
96d6626881df90b6d14902d7f0d480382a90ea16
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- import json from unittest import mock import pytest import tempfile import zipfile from django.conf import settings from django.forms import ValidationError from django.utils.encoding import force_text from waffle.testutils import override_switch from olympia import amo from olympia.addons.mo...
43.661585
79
0.675302
4f1f53fa923b71085b4df8565ae1a71a6ab566e5
1,267
py
Python
mimic_preprocess/extraction_static.py
jli0117/preprocessing_physionet
b061d3d6fcfa9057f16b05863388ebd70e827d79
[ "MIT" ]
null
null
null
mimic_preprocess/extraction_static.py
jli0117/preprocessing_physionet
b061d3d6fcfa9057f16b05863388ebd70e827d79
[ "MIT" ]
null
null
null
mimic_preprocess/extraction_static.py
jli0117/preprocessing_physionet
b061d3d6fcfa9057f16b05863388ebd70e827d79
[ "MIT" ]
null
null
null
import pandas as pd import numpy as np import pickle import os # load data DATA_FILEPATH = '../../code/preprocessing/MIMIC-EXTRACT-data-preprocessing/data/all_hourly_data.h5' data_statics = pd.read_hdf(DATA_FILEPATH, 'patients') print("number of patients: {}".format(len(data_statics))) # cohort selection data_statics...
37.264706
99
0.779795
9b659fae505978c5ecd8511deab700fb9211a7c6
5,986
py
Python
djangoprovider/iterator.py
MPASolutions/django-provider
c305c79dcea381d04463384dc7ae8ad415152916
[ "MIT" ]
2
2018-10-25T08:56:39.000Z
2018-10-27T18:47:10.000Z
djangoprovider/iterator.py
MPASolutions/django-provider
c305c79dcea381d04463384dc7ae8ad415152916
[ "MIT" ]
null
null
null
djangoprovider/iterator.py
MPASolutions/django-provider
c305c79dcea381d04463384dc7ae8ad415152916
[ "MIT" ]
null
null
null
from qgis.core import ( QgsAbstractFeatureIterator, QgsFeatureRequest, QgsCoordinateTransform, QgsCsException, QgsGeometry, QgsFeature, QgsLogger, ) from django.db.models import Q from django.contrib.gis.db.models import Model from django.contrib.gis.geos import Polygon class DjangoFeatur...
39.381579
128
0.609756
5619c596893243505db7f821ee2f056272acaed5
35,870
py
Python
core_tools/GUI/keysight_videomaps/GUI/videomode_gui.py
opietx/core_tools
d5bd2d4beed74791b80ff5bdabd67774403763ef
[ "BSD-2-Clause" ]
null
null
null
core_tools/GUI/keysight_videomaps/GUI/videomode_gui.py
opietx/core_tools
d5bd2d4beed74791b80ff5bdabd67774403763ef
[ "BSD-2-Clause" ]
null
null
null
core_tools/GUI/keysight_videomaps/GUI/videomode_gui.py
opietx/core_tools
d5bd2d4beed74791b80ff5bdabd67774403763ef
[ "BSD-2-Clause" ]
null
null
null
# -*- coding: utf-8 -*- # Form implementation generated from reading ui file 'GUI.ui' # # Created by: PyQt5 UI code generator 5.12.2 # # WARNING! All changes made in this file will be lost! from PyQt5 import QtCore, QtGui, QtWidgets class Ui_MainWindow(object): def setupUi(self, MainWindow): MainWindow....
61.421233
114
0.73429
d2ee474d8bd9265b53a4a4058a0d476432bacb62
9,127
py
Python
gluon/utils.py
efaisal/web2py
e56f588deab92d7a7c2a568be6b7490cd309c417
[ "BSD-3-Clause" ]
1
2016-11-05T15:59:38.000Z
2016-11-05T15:59:38.000Z
gluon/utils.py
efaisal/web2py
e56f588deab92d7a7c2a568be6b7490cd309c417
[ "BSD-3-Clause" ]
null
null
null
gluon/utils.py
efaisal/web2py
e56f588deab92d7a7c2a568be6b7490cd309c417
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- """ This file is part of the web2py Web Framework Copyrighted by Massimo Di Pierro <mdipierro@cs.depaul.edu> License: LGPLv3 (http://www.gnu.org/licenses/lgpl.html) This file specifically includes utilities for security. """ import threading import struct import hashlib ...
31.472414
97
0.619481
2312b3465c9d39597e32243e270ceff646b9ddb5
2,952
py
Python
examples/train_wt103.py
zsquaredz/fastai
7afb666a605772742fd76bdd608d7f80e39114f1
[ "Apache-2.0" ]
null
null
null
examples/train_wt103.py
zsquaredz/fastai
7afb666a605772742fd76bdd608d7f80e39114f1
[ "Apache-2.0" ]
null
null
null
examples/train_wt103.py
zsquaredz/fastai
7afb666a605772742fd76bdd608d7f80e39114f1
[ "Apache-2.0" ]
null
null
null
##To train a language model on Wikitext-103 ##`python train_wt103.py fwd` for the forward pretrained model in fastai ##`python train_wt103.py bwd --backwards True` for the backward pretrained model in fastai ## Takes 6 hours on a Titan RTX (24Gb RAM), adjust batch size and lr if less GPU RAM from fastai.text import * ...
40.438356
93
0.64939
0c478d8f68fc0b8e2e61d65a40a28f0a096881b4
1,038
py
Python
server/test/test_message.py
byee123/battleships
0cd527217c8727f7b3274d8a661cbf8d49aa4276
[ "MIT" ]
2
2020-11-02T08:04:06.000Z
2020-11-25T12:20:45.000Z
server/test/test_message.py
byee123/battleships
0cd527217c8727f7b3274d8a661cbf8d49aa4276
[ "MIT" ]
17
2020-11-02T04:30:17.000Z
2020-12-07T00:35:34.000Z
server/test/test_message.py
byee123/battleships
0cd527217c8727f7b3274d8a661cbf8d49aa4276
[ "MIT" ]
20
2021-05-19T05:00:04.000Z
2021-11-20T02:50:31.000Z
import unittest from message import Message class TestMessage(unittest.TestCase): def setUp(self) -> None: self.type = Message.BEGIN self.player = "Player McPlayerface" self.data = "Some data" self.msg = Message(self.type, self.player, self.data) def test_create_message(self):...
33.483871
79
0.640655
137c2fadd996fb3af67e8786a1e5bf3f8d4e8e82
279
py
Python
hello.py
mrdon/flask
ffd0828772be99a56f21e23757c2607e1a338fad
[ "BSD-3-Clause" ]
25
2015-01-31T15:18:10.000Z
2021-11-14T20:09:43.000Z
hello.py
mrdon/flask
ffd0828772be99a56f21e23757c2607e1a338fad
[ "BSD-3-Clause" ]
1
2015-08-26T16:25:48.000Z
2015-08-26T16:25:48.000Z
hello.py
mrdon/flask
ffd0828772be99a56f21e23757c2607e1a338fad
[ "BSD-3-Clause" ]
4
2015-03-06T01:14:03.000Z
2020-12-23T00:27:56.000Z
from asyncio import coroutine, sleep from flask import Flask, request app = Flask(__name__) app.config['DEBUG'] = True @app.route("/hello/<string:name>") @coroutine def say_hi(name): yield from sleep(2) return "it worked %s" % request.args.get("name", name) app.run()
19.928571
58
0.698925
bf4af13ed7bbb60d8edf17e9b357166872108f19
1,093
py
Python
py/test.BRCA_generate_barycenters.py
BiCroLab/nucleAI
1fa1ea23e5b0f282b51e8a57f428f8e8cfc51589
[ "MIT" ]
1
2021-05-25T13:40:56.000Z
2021-05-25T13:40:56.000Z
py/test.BRCA_generate_barycenters.py
BiCroLab/nucleAI
1fa1ea23e5b0f282b51e8a57f428f8e8cfc51589
[ "MIT" ]
null
null
null
py/test.BRCA_generate_barycenters.py
BiCroLab/nucleAI
1fa1ea23e5b0f282b51e8a57f428f8e8cfc51589
[ "MIT" ]
1
2021-05-25T13:41:06.000Z
2021-05-25T13:41:06.000Z
#!/usr/bin/env python # coding: utf-8 import sys sys.path.insert(0, '../py') from graviti import * import numpy as np import os import os.path from os import path import sys import glob import h5py import pandas as pd import pickle import timeit import multiprocessing from joblib import Parallel, delayed from datet...
25.418605
122
0.762123
7001a7fdda5c6ed4045f802e3a67a822fb043c50
1,006
py
Python
WPTParser/Fetch/__init__.py
Bharat23/wpt-parser
e5679c50c8658dfb139663ca3392a42d2c2ea327
[ "MIT" ]
1
2020-08-09T16:54:16.000Z
2020-08-09T16:54:16.000Z
WPTParser/Fetch/__init__.py
Bharat23/wpt-parser
e5679c50c8658dfb139663ca3392a42d2c2ea327
[ "MIT" ]
null
null
null
WPTParser/Fetch/__init__.py
Bharat23/wpt-parser
e5679c50c8658dfb139663ca3392a42d2c2ea327
[ "MIT" ]
null
null
null
import requests from WPTParser import WPTParser class Fetch(): def __init__(self, headers: dict = {}): self.headers = { 'User-Agent': 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/50.0.2661.102 Safari/537.36' } self.headers.upda...
38.692308
149
0.649105
8b1491fd64f7d46f139ff09f1085ead2138484e7
11,084
py
Python
conditional_skill/ENSO/enso_ccdiff.py
nick-klingaman/dubstep
576ac6efa1748933aa37ae28a41e77c8c0dbe2ab
[ "Apache-2.0" ]
null
null
null
conditional_skill/ENSO/enso_ccdiff.py
nick-klingaman/dubstep
576ac6efa1748933aa37ae28a41e77c8c0dbe2ab
[ "Apache-2.0" ]
null
null
null
conditional_skill/ENSO/enso_ccdiff.py
nick-klingaman/dubstep
576ac6efa1748933aa37ae28a41e77c8c0dbe2ab
[ "Apache-2.0" ]
1
2022-02-21T06:35:51.000Z
2022-02-21T06:35:51.000Z
from __future__ import division #import cf, cfplot as cfp import numpy as np import matplotlib as mpl import matplotlib.pyplot as plt from matplotlib.colors import BoundaryNorm from mpl_toolkits.basemap import Basemap import scipy as sp from scipy import stats LAT=47 LON=47 WEEK=5 NUM=1000 NEL = 56 NNE = 108 NLA = 56 ...
47.367521
140
0.665193
6ebdfb0ed5ac06fb4f66a32d17a1a30f74e0698d
820
py
Python
tests/test_cloneable.py
team23/django_cloneable
dc77673a9c5771c6e9142849b6b2f0969f203955
[ "BSD-3-Clause" ]
15
2016-03-22T15:24:04.000Z
2019-10-05T06:34:44.000Z
tests/test_cloneable.py
team23/django_cloneable
dc77673a9c5771c6e9142849b6b2f0969f203955
[ "BSD-3-Clause" ]
6
2016-03-22T15:05:00.000Z
2019-03-26T22:18:52.000Z
tests/test_cloneable.py
team23/django_cloneable
dc77673a9c5771c6e9142849b6b2f0969f203955
[ "BSD-3-Clause" ]
16
2016-08-17T11:25:26.000Z
2021-02-27T10:17:54.000Z
from datetime import date from django.test import TestCase from .models import ModelWithCustomPK from .models import ModelWithFields class CloneableTests(TestCase): def test_cloning_generates_a_new_instance(self): i1 = ModelWithFields.objects.create( char='custom value', integer=2...
27.333333
66
0.628049
bb8f801d6b912448272d31fcd2616535944552fd
12,966
py
Python
corehq/apps/app_manager/views/view_generic.py
dannyroberts/commcare-hq
4b0b8ecbe851e46307d3a0e635d6d5d6e31c3598
[ "BSD-3-Clause" ]
null
null
null
corehq/apps/app_manager/views/view_generic.py
dannyroberts/commcare-hq
4b0b8ecbe851e46307d3a0e635d6d5d6e31c3598
[ "BSD-3-Clause" ]
null
null
null
corehq/apps/app_manager/views/view_generic.py
dannyroberts/commcare-hq
4b0b8ecbe851e46307d3a0e635d6d5d6e31c3598
[ "BSD-3-Clause" ]
null
null
null
from __future__ import absolute_import from __future__ import unicode_literals from django.http import Http404 from django.http import HttpResponseRedirect from django.urls import reverse from django.shortcuts import render from corehq.apps.app_manager.const import APP_V1 from corehq.apps.app_manager.exceptions import ...
39.530488
103
0.630495
7ac0823b55791e94475653e3908b7b0798d21e0b
3,925
py
Python
middleware/qira.py
pAplakidis/qira
9d0aa4f887e9dce8c0307a54c7051755ede26810
[ "MIT" ]
null
null
null
middleware/qira.py
pAplakidis/qira
9d0aa4f887e9dce8c0307a54c7051755ede26810
[ "MIT" ]
null
null
null
middleware/qira.py
pAplakidis/qira
9d0aa4f887e9dce8c0307a54c7051755ede26810
[ "MIT" ]
1
2020-12-02T16:32:17.000Z
2020-12-02T16:32:17.000Z
#!/usr/bin/env python2.7 import os import sys basedir = os.path.dirname(os.path.realpath(__file__)) import argparse import ipaddr import socket import threading import time import qira_config import qira_socat import qira_program import qira_webserver if __name__ == '__main__': # define arguments parser = argpars...
37.028302
157
0.722293
907af758f3d636194e323afa3a14d9e678d2f6bf
368
py
Python
data/migrations/0019_auto_20191007_0838.py
SIXMON/peps
48c09a951a0193ada7b91c8bb6efc4b1232c3520
[ "MIT" ]
5
2019-08-29T13:55:47.000Z
2021-11-15T08:30:33.000Z
data/migrations/0019_auto_20191007_0838.py
SIXMON/peps
48c09a951a0193ada7b91c8bb6efc4b1232c3520
[ "MIT" ]
295
2019-08-19T12:40:29.000Z
2022-01-24T14:03:20.000Z
data/migrations/0019_auto_20191007_0838.py
SIXMON/peps
48c09a951a0193ada7b91c8bb6efc4b1232c3520
[ "MIT" ]
7
2020-05-27T06:28:48.000Z
2021-11-17T10:00:54.000Z
# Generated by Django 2.2.4 on 2019-10-07 08:38 from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('data', '0018_auto_20191007_0819'), ] operations = [ migrations.RenameField( model_name='culture', old_name='period', ...
19.368421
47
0.589674
b792d002af61e4ffb7b3deef97fb0bd3cb243a3e
1,394
py
Python
setup.py
gitter-badger/SpeedTorch
c7a70c4db532c83168d5016499d688c1ad31407a
[ "MIT" ]
null
null
null
setup.py
gitter-badger/SpeedTorch
c7a70c4db532c83168d5016499d688c1ad31407a
[ "MIT" ]
null
null
null
setup.py
gitter-badger/SpeedTorch
c7a70c4db532c83168d5016499d688c1ad31407a
[ "MIT" ]
null
null
null
import codecs from setuptools import setup, find_packages with codecs.open('README.md', 'r', 'utf8') as reader: long_description = reader.read() with codecs.open('requirements.txt', 'r', 'utf8') as reader: install_requires = list(map(lambda x: x.strip(), reader.readlines())) try: import cupy except: ...
36.684211
135
0.685079
b4f8b41d5e364ae127a8cd1435d397e0aa7c8ed6
2,335
py
Python
custom_components/tahoma/alarm_entities/stateful_alarm_controller.py
greg2001/ha-tahoma
11a523614b158ed4c2f3ffa38ffc1e7d0c3baa3e
[ "MIT" ]
null
null
null
custom_components/tahoma/alarm_entities/stateful_alarm_controller.py
greg2001/ha-tahoma
11a523614b158ed4c2f3ffa38ffc1e7d0c3baa3e
[ "MIT" ]
null
null
null
custom_components/tahoma/alarm_entities/stateful_alarm_controller.py
greg2001/ha-tahoma
11a523614b158ed4c2f3ffa38ffc1e7d0c3baa3e
[ "MIT" ]
null
null
null
"""Support for Overkiz StatefulAlarmController.""" from __future__ import annotations from pyoverkiz.enums import OverkizCommand, OverkizCommandParam, OverkizState from homeassistant.components.alarm_control_panel import AlarmControlPanelEntity from homeassistant.components.alarm_control_panel.const import ( SUPP...
31.986301
82
0.704069
b6f69623d5ef3dd2015ba705e58b8aa041276af1
3,603
py
Python
tests/selenium/super_cookie_test.py
JacobHearst/privacybadger
6e9650def2aad2b29d861b17816068a7049ab1ba
[ "Apache-2.0" ]
null
null
null
tests/selenium/super_cookie_test.py
JacobHearst/privacybadger
6e9650def2aad2b29d861b17816068a7049ab1ba
[ "Apache-2.0" ]
null
null
null
tests/selenium/super_cookie_test.py
JacobHearst/privacybadger
6e9650def2aad2b29d861b17816068a7049ab1ba
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # -*- coding: UTF-8 -*- import unittest import pbtest from functools import partial class SupercookieTest(pbtest.PBSeleniumTest): """Make sure we detect potential supercookies. """ def get_snitch_map_for(self, origin): self.open_window() # don't replace the test page to allow...
36.765306
95
0.670275
e6e4b2c0900c5ec132cf52148a485eb04046bfbc
1,445
py
Python
changes/api/quarantine_tasks.py
vault-the/changes
37e23c3141b75e4785cf398d015e3dbca41bdd56
[ "Apache-2.0" ]
443
2015-01-03T16:28:39.000Z
2021-04-26T16:39:46.000Z
changes/api/quarantine_tasks.py
vault-the/changes
37e23c3141b75e4785cf398d015e3dbca41bdd56
[ "Apache-2.0" ]
12
2015-07-30T19:07:16.000Z
2016-11-07T23:11:21.000Z
changes/api/quarantine_tasks.py
vault-the/changes
37e23c3141b75e4785cf398d015e3dbca41bdd56
[ "Apache-2.0" ]
47
2015-01-09T10:04:00.000Z
2020-11-18T17:58:19.000Z
from __future__ import absolute_import, division, unicode_literals from flask import current_app from changes.api.base import APIView from changes.utils.phabricator_utils import PhabricatorClient import requests class QuarantineTasksAPIView(APIView): def get(self): """ Gets the list of open ta...
32.111111
92
0.608304
092380349ecc543f3ed34689c01c43b97dfb7b31
8,670
py
Python
examples/rsa/semantic_parsing.py
Jayanth-kumar5566/pyro
a98bb57e1704997a3e01c76a7820c0b1db909ee3
[ "Apache-2.0" ]
4,959
2017-11-03T14:39:17.000Z
2019-02-04T16:14:30.000Z
examples/rsa/semantic_parsing.py
Jayanth-kumar5566/pyro
a98bb57e1704997a3e01c76a7820c0b1db909ee3
[ "Apache-2.0" ]
985
2017-11-03T14:27:56.000Z
2019-02-02T18:52:54.000Z
examples/rsa/semantic_parsing.py
Jayanth-kumar5566/pyro
a98bb57e1704997a3e01c76a7820c0b1db909ee3
[ "Apache-2.0" ]
564
2017-11-03T15:05:55.000Z
2019-01-31T14:02:29.000Z
# Copyright (c) 2017-2019 Uber Technologies, Inc. # SPDX-License-Identifier: Apache-2.0 """ Combining models of RSA pragmatics and CCG-based compositional semantics. Taken from: http://dippl.org/examples/zSemanticPragmaticMashup.html """ import argparse import collections import torch from search_inference import B...
24.150418
88
0.535525
259874f5e3f05722cd322abd8e4c81025b40979d
6,053
py
Python
airflow/contrib/auth/backends/google_auth.py
mr-mcox/incubator-airflow
3f1bfd38cd5a1c9c58045004390a6a766bec5e8d
[ "Apache-2.0" ]
4
2015-11-12T10:58:54.000Z
2017-08-05T06:41:36.000Z
airflow/contrib/auth/backends/google_auth.py
mr-mcox/incubator-airflow
3f1bfd38cd5a1c9c58045004390a6a766bec5e8d
[ "Apache-2.0" ]
6
2015-12-08T21:41:51.000Z
2017-11-28T13:24:05.000Z
airflow/contrib/auth/backends/google_auth.py
mr-mcox/incubator-airflow
3f1bfd38cd5a1c9c58045004390a6a766bec5e8d
[ "Apache-2.0" ]
2
2015-12-14T11:38:49.000Z
2018-03-26T15:03:07.000Z
# Copyright 2016 Ananya Mishra (am747@cornell.edu) # # Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache ...
31.526042
85
0.635222
a1b0cb38adad6842ed377d04faea0305d3a32af1
51,385
py
Python
gs_quant/markets/securities.py
daniel-schreier/gs-quant
abc5670a35874f2ce701418c9e1da7987092b4f7
[ "Apache-2.0" ]
null
null
null
gs_quant/markets/securities.py
daniel-schreier/gs-quant
abc5670a35874f2ce701418c9e1da7987092b4f7
[ "Apache-2.0" ]
null
null
null
gs_quant/markets/securities.py
daniel-schreier/gs-quant
abc5670a35874f2ce701418c9e1da7987092b4f7
[ "Apache-2.0" ]
null
null
null
""" Copyright 2019 Goldman Sachs. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software di...
34.00728
120
0.623081
c330adbbab5ef93fb4500676c7049f36cd9d3020
2,087
py
Python
var/spack/repos/builtin/packages/hipsparse/package.py
healther/spack
389e9c11f6927ea27d629ed0e77ca0a52e402bc9
[ "ECL-2.0", "Apache-2.0", "MIT-0", "MIT" ]
9
2018-04-18T07:51:40.000Z
2021-09-10T03:56:57.000Z
var/spack/repos/builtin/packages/hipsparse/package.py
abouteiller/spack
95f54195021d3d32dec75bed6d8dbbaeac3d921f
[ "ECL-2.0", "Apache-2.0", "MIT-0", "MIT" ]
907
2018-04-18T11:17:57.000Z
2022-03-31T13:20:25.000Z
var/spack/repos/builtin/packages/hipsparse/package.py
abouteiller/spack
95f54195021d3d32dec75bed6d8dbbaeac3d921f
[ "ECL-2.0", "Apache-2.0", "MIT-0", "MIT" ]
29
2018-11-05T16:14:23.000Z
2022-02-03T16:07:09.000Z
# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) from spack import * class Hipsparse(CMakePackage): """hipSPARSE is a SPARSE marshalling library, with multipl...
41.74
95
0.661715
31f3a124598ed5e45b8503d7b6919a0f902caa66
1,306
py
Python
test_cases/test_index.py
zhaopiandehuiyiforsang/python_test
7a6ef77afd3b436f798ca68c77b9ac8669e00094
[ "MIT" ]
null
null
null
test_cases/test_index.py
zhaopiandehuiyiforsang/python_test
7a6ef77afd3b436f798ca68c77b9ac8669e00094
[ "MIT" ]
null
null
null
test_cases/test_index.py
zhaopiandehuiyiforsang/python_test
7a6ef77afd3b436f798ca68c77b9ac8669e00094
[ "MIT" ]
null
null
null
# -*- coding:utf-8 -*- from init_env import BASE_DIR from common.HttpUtils import HttpUtils from common.constains import index from test_cases.base_test import runTests import unittest class TestIndex(unittest.TestCase): """indexController中各个方法的测试用例 """ def setUp(self): """ 测试用例初始化操作 ...
25.115385
79
0.602603
6ebe2501c613ba8a2e70bece7de2e71a9620e1be
1,406
py
Python
airflow/providers/amazon/aws/example_dags/example_s3_to_ftp.py
npodewitz/airflow
511ea702d5f732582d018dad79754b54d5e53f9d
[ "Apache-2.0" ]
8,092
2016-04-27T20:32:29.000Z
2019-01-05T07:39:33.000Z
airflow/providers/amazon/aws/example_dags/example_s3_to_ftp.py
npodewitz/airflow
511ea702d5f732582d018dad79754b54d5e53f9d
[ "Apache-2.0" ]
2,961
2016-05-05T07:16:16.000Z
2019-01-05T08:47:59.000Z
airflow/providers/amazon/aws/example_dags/example_s3_to_ftp.py
npodewitz/airflow
511ea702d5f732582d018dad79754b54d5e53f9d
[ "Apache-2.0" ]
3,546
2016-05-04T20:33:16.000Z
2019-01-05T05:14:26.000Z
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
33.47619
76
0.743954
f5acf348a6d1d3a12eb1987b68ba086c9484e242
5,159
py
Python
pexels_scraper.py
ToishY/pexels-scraper
4948af7442a2a37f501d632f3b77cc362eb3127a
[ "MIT" ]
5
2021-04-25T15:54:16.000Z
2022-03-08T01:54:54.000Z
pexels_scraper.py
ToishY/pexels-scraper
4948af7442a2a37f501d632f3b77cc362eb3127a
[ "MIT" ]
null
null
null
pexels_scraper.py
ToishY/pexels-scraper
4948af7442a2a37f501d632f3b77cc362eb3127a
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Sat Aug 1 00:50:01 2020 @author: ToshY Simple scraper with Pexels API """ import os import math import argparse import requests from pathlib import Path def page_arguments(nmin,nmax): """ Limit nargs for argument parser """ class PageArgsCheck(a...
33.718954
126
0.55282
64888a0ea251d2ea810f5e5cf5021175abd652d9
593
py
Python
Chapter_06/mclip.py
GSantos23/Automate_Python
4bf3eadb5a330d5f22329bdcd08d37ab01a9454f
[ "MIT" ]
1
2019-08-12T04:28:54.000Z
2019-08-12T04:28:54.000Z
Chapter_06/mclip.py
GSantos23/Automate_Python
4bf3eadb5a330d5f22329bdcd08d37ab01a9454f
[ "MIT" ]
null
null
null
Chapter_06/mclip.py
GSantos23/Automate_Python
4bf3eadb5a330d5f22329bdcd08d37ab01a9454f
[ "MIT" ]
null
null
null
#! python3 # mclip.py - A multi clip program TEXT = {'agree':"""Yes, I agree. That sounds fine to me.""", 'busy':"""Sorry, can we do this later this week or next week?""", 'upsell':"""Would you consider making a monthly donation?"""} import sys, pyperclip if len(sys.argv) < 2: print("Usage: python mclip.py [ke...
28.238095
67
0.681282
2e580bc29b7784d69d77bc6c037fff531a3abaa0
60,046
py
Python
mac/google-cloud-sdk/lib/googlecloudsdk/third_party/apis/lifesciences/v2beta/lifesciences_v2beta_messages.py
bopopescu/cndw
ee432efef88a4351b355f3d6d5350defc7f4246b
[ "Apache-2.0" ]
null
null
null
mac/google-cloud-sdk/lib/googlecloudsdk/third_party/apis/lifesciences/v2beta/lifesciences_v2beta_messages.py
bopopescu/cndw
ee432efef88a4351b355f3d6d5350defc7f4246b
[ "Apache-2.0" ]
4
2020-07-21T12:51:46.000Z
2022-01-22T10:29:25.000Z
mac/google-cloud-sdk/lib/googlecloudsdk/third_party/apis/lifesciences/v2beta/lifesciences_v2beta_messages.py
bopopescu/cndw
ee432efef88a4351b355f3d6d5350defc7f4246b
[ "Apache-2.0" ]
1
2020-07-25T18:17:57.000Z
2020-07-25T18:17:57.000Z
"""Generated message classes for lifesciences version v2beta. Cloud Life Sciences is a suite of services and tools for managing, processing, and transforming life sciences data. """ # NOTE: This file is autogenerated and should not be edited by hand. from apitools.base.protorpclite import messages as _messages from a...
42.798289
89
0.737235
733af0cb8f9d8650a93427d4f0904ca49c387ba1
73,485
py
Python
tests/integration/helpers/cluster.py
nickshch/ClickHouse
fe49574e413e2bc83066ae1c18385e508f1e982d
[ "Apache-2.0" ]
null
null
null
tests/integration/helpers/cluster.py
nickshch/ClickHouse
fe49574e413e2bc83066ae1c18385e508f1e982d
[ "Apache-2.0" ]
null
null
null
tests/integration/helpers/cluster.py
nickshch/ClickHouse
fe49574e413e2bc83066ae1c18385e508f1e982d
[ "Apache-2.0" ]
null
null
null
import base64 import errno import http.client import logging import os import os.path as p import pprint import pwd import re import shutil import socket import subprocess import time import traceback import urllib.parse import shlex import cassandra.cluster import docker import psycopg2 import pymongo import pymysql ...
46.014402
231
0.610451
e8b9843edb03f133c5cdd7ddd1c011425e77c662
567
py
Python
bouser_simargl/clients/console.py
hitsl/bouser_simargl
e769bb07403b83f62de0772596e9d46ac521ee0f
[ "0BSD" ]
null
null
null
bouser_simargl/clients/console.py
hitsl/bouser_simargl
e769bb07403b83f62de0772596e9d46ac521ee0f
[ "0BSD" ]
null
null
null
bouser_simargl/clients/console.py
hitsl/bouser_simargl
e769bb07403b83f62de0772596e9d46ac521ee0f
[ "0BSD" ]
null
null
null
# -*- coding: utf-8 -*- import time import blinker from bouser_simargl.client import SimarglClient from bouser_simargl.message import Message from bouser.utils import as_json from twisted.internet.task import LoopingCall from twisted.python import log from twisted.python.log import callWithContext __author__ = 'viruz...
24.652174
66
0.751323
e7bf9818b0ef4e0af7b86d8ab8fca2fb9d0a8ac0
3,198
py
Python
roles/openshift_health_checker/test/fluentd_test.py
shgriffi/openshift-ansible
6313f519307cf50055589c3876d8bec398bbc4d4
[ "Apache-2.0" ]
164
2015-07-29T17:35:04.000Z
2021-12-16T16:38:04.000Z
roles/openshift_health_checker/test/fluentd_test.py
shgriffi/openshift-ansible
6313f519307cf50055589c3876d8bec398bbc4d4
[ "Apache-2.0" ]
3,634
2015-06-09T13:49:15.000Z
2022-03-23T20:55:44.000Z
roles/openshift_health_checker/test/fluentd_test.py
shgriffi/openshift-ansible
6313f519307cf50055589c3876d8bec398bbc4d4
[ "Apache-2.0" ]
250
2015-06-08T19:53:11.000Z
2022-03-01T04:51:23.000Z
import pytest import json from openshift_checks.logging.fluentd import Fluentd, OpenShiftCheckExceptionList, OpenShiftCheckException def assert_error_in_list(expect_err, errorlist): assert any(err.name == expect_err for err in errorlist), "{} in {}".format(str(expect_err), str(errorlist)) fluentd_pod_node1 = {...
28.300885
111
0.597248
8a5a8a3f68c041a246c78986ce892dce50f8b1b2
3,535
py
Python
lib/broker.py
eellak/gsoc2021-HA-Auto-Node-RED-
19b2bd4410ed964d0092b702297666b4799df25e
[ "MIT" ]
4
2021-06-05T16:48:18.000Z
2021-10-09T06:02:40.000Z
lib/broker.py
eellak/gsoc2021-HA-Auto-Node-RED
19b2bd4410ed964d0092b702297666b4799df25e
[ "MIT" ]
null
null
null
lib/broker.py
eellak/gsoc2021-HA-Auto-Node-RED
19b2bd4410ed964d0092b702297666b4799df25e
[ "MIT" ]
null
null
null
from commlib.transports.mqtt import ConnectionParameters as MQTT_ConnectionParameters, Credentials as MQTT_Credentials from commlib.transports.amqp import ConnectionParameters as AMQP_ConnectionParameters, Credentials as AMQP_Credentials from commlib.transports.redis import ConnectionParameters as Redis_ConnectionParam...
38.010753
121
0.679491
ad00d7d30af70a67feae3130c254d5d11255abb5
498
py
Python
dsatools/frequency.py
diarmaidocualain/dsatools
50b9259e2846b5fdd3dc52206967b0ee8d0144de
[ "MIT" ]
31
2020-09-14T16:12:01.000Z
2022-03-30T01:44:18.000Z
frequency.py
Jimmy-INL/dsatools
5c811838bb3fb8ae00195d5f68e451bd23b3448c
[ "MIT" ]
4
2021-09-24T17:47:42.000Z
2022-03-04T08:06:43.000Z
frequency.py
Jimmy-INL/dsatools
5c811838bb3fb8ae00195d5f68e451bd23b3448c
[ "MIT" ]
11
2020-12-06T08:18:56.000Z
2022-03-20T13:28:22.000Z
from ._base._frequency import(fitz_r, kay, mcrb, m_and_m, fitz, f_and_k, tretter_f, ml_fft, ...
38.307692
59
0.277108
330f834d62ffb6f830c61bf8b12ecb43649436d5
11,639
py
Python
isi_sdk_8_1_0/isi_sdk_8_1_0/models/cluster_patch_patches_patch.py
mohitjain97/isilon_sdk_python
a371f438f542568edb8cda35e929e6b300b1177c
[ "Unlicense" ]
24
2018-06-22T14:13:23.000Z
2022-03-23T01:21:26.000Z
isi_sdk_8_1_0/isi_sdk_8_1_0/models/cluster_patch_patches_patch.py
mohitjain97/isilon_sdk_python
a371f438f542568edb8cda35e929e6b300b1177c
[ "Unlicense" ]
46
2018-04-30T13:28:22.000Z
2022-03-21T21:11:07.000Z
isi_sdk_8_1_0/isi_sdk_8_1_0/models/cluster_patch_patches_patch.py
mohitjain97/isilon_sdk_python
a371f438f542568edb8cda35e929e6b300b1177c
[ "Unlicense" ]
29
2018-06-19T00:14:04.000Z
2022-02-08T17:51:19.000Z
# coding: utf-8 """ Isilon SDK Isilon SDK - Language bindings for the OneFS API # noqa: E501 OpenAPI spec version: 5 Contact: sdk@isilon.com Generated by: https://github.com/swagger-api/swagger-codegen.git """ import pprint import re # noqa: F401 import six from isi_sdk_8_1_0.models.cluster...
29.243719
189
0.60177
8683f1db4b96fcc5b59c58a992c30106b9880823
6,785
py
Python
server/intrinsic/algorithm/grosse2009/poisson.py
paulu/opensurfaces
7f3e987560faa62cd37f821760683ccd1e053c7c
[ "MIT" ]
137
2015-02-19T00:00:42.000Z
2022-03-31T03:56:01.000Z
server/intrinsic/algorithm/grosse2009/poisson.py
paulu/opensurfaces
7f3e987560faa62cd37f821760683ccd1e053c7c
[ "MIT" ]
20
2015-07-28T23:39:58.000Z
2020-05-19T11:40:55.000Z
server/intrinsic/algorithm/grosse2009/poisson.py
paulu/opensurfaces
7f3e987560faa62cd37f821760683ccd1e053c7c
[ "MIT" ]
49
2015-02-09T15:21:46.000Z
2021-12-15T14:22:33.000Z
import numpy as np import pyamg import scipy.sparse def get_gradients(I): """Get the vertical (derivative-row) and horizontal (derivative-column) gradients of an image.""" I_y = np.zeros(I.shape) I_y[1:, :, ...] = I[1:, :, ...] - I[:-1, :, ...] I_x = np.zeros(I.shape) I_x[:, 1:, ...] = I[:, 1:...
29.372294
88
0.500221
f0cbb0455fa0c010a6890072af876405572950a2
6,086
py
Python
project-metrics/metrics_service/metrics/base.py
ayumi-cloud/amp-github-apps
4d00a43c657f4168f3b0f40fd0ff4c1ec1dd2bbf
[ "Apache-2.0" ]
1
2019-11-10T06:58:02.000Z
2019-11-10T06:58:02.000Z
project-metrics/metrics_service/metrics/base.py
ayumi-cloud/amp-github-apps
4d00a43c657f4168f3b0f40fd0ff4c1ec1dd2bbf
[ "Apache-2.0" ]
8
2020-02-10T16:04:33.000Z
2022-03-26T13:56:22.000Z
project-metrics/metrics_service/metrics/base.py
ayumi-cloud/amp-github-apps
4d00a43c657f4168f3b0f40fd0ff4c1ec1dd2bbf
[ "Apache-2.0" ]
1
2019-10-08T01:34:21.000Z
2019-10-08T01:34:21.000Z
"""Base interface for metrics to implement. To create a new metric: 1. Subclass `Metric` or `PercentMetric` 2. Implement `_score_value`, `_compute_value`, and (unless you're using `PercentMetric`) `_format_value` and define the UNIT (for history plots) 3. Call `metrics.base.Metric.register(YourNewMetric)` 4. Import...
31.210256
80
0.694052
84b2aa8c2397d3d7fe17853358a64f447a1f3383
922
py
Python
data/flow_transforms.py
xuyu0010/ARID_v1
b03d0975f41547e8aa78929b8e26a62248f8e18f
[ "CC-BY-4.0" ]
5
2020-06-24T07:33:36.000Z
2021-11-30T17:52:08.000Z
data/flow_transforms.py
xuyu0010/ARID_v1
b03d0975f41547e8aa78929b8e26a62248f8e18f
[ "CC-BY-4.0" ]
1
2022-03-29T05:23:24.000Z
2022-03-29T06:19:57.000Z
data/flow_transforms.py
xuyu0010/ARID_v1
b03d0975f41547e8aa78929b8e26a62248f8e18f
[ "CC-BY-4.0" ]
3
2021-02-06T10:56:30.000Z
2022-01-18T18:50:12.000Z
""" Author: Yunpeng Chen """ import torch import numpy as np from .image_transforms import Compose, \ Transform, \ Resize, \ RandomScale, \ CenterCrop, \ RandomCrop, \ ...
32.928571
94
0.491323
0aeb4c18ddd8b4e0d02e416b43912036c372e4b6
367
py
Python
src/modules/catalog/tests/domain/test_rules.py
Ermlab/python-ddd
a3e1cc69cad45e901c820688d7b42173bb3e1a1d
[ "MIT" ]
308
2019-03-04T12:52:57.000Z
2022-03-16T10:33:25.000Z
src/modules/catalog/tests/domain/test_rules.py
Ermlab/python-ddd
a3e1cc69cad45e901c820688d7b42173bb3e1a1d
[ "MIT" ]
5
2018-12-07T08:14:52.000Z
2021-06-17T12:22:19.000Z
src/modules/catalog/tests/domain/test_rules.py
Ermlab/python-ddd
a3e1cc69cad45e901c820688d7b42173bb3e1a1d
[ "MIT" ]
58
2019-06-15T22:56:15.000Z
2022-03-01T02:00:17.000Z
from modules.catalog.domain.rules import ListingPriceMustBeGreaterThanZero def test_AuctionItemPriceMustBeGreaterThanZero_rule(): rule = ListingPriceMustBeGreaterThanZero(price=1) assert not rule.is_broken() def test_AuctionItemPriceMustBeGreaterThanZero_rule_is_broken(): rule = ListingPriceMustBeGreate...
30.583333
74
0.831063
c9c07d62f8ab21d034a317060a7c0be9bd8c4a68
1,114
py
Python
appimagebuilder/commands/__init__.py
AppImageCrafters/AppImageBuilder
dd041050e65f8eff28f878a092fd07bcf3ec5a4d
[ "MIT" ]
3
2019-11-01T09:23:59.000Z
2019-11-09T12:03:12.000Z
appimagebuilder/commands/__init__.py
AppImageCrafters/AppImageCraft
a08ae8d300d9632d78865003c974175dcb90ce21
[ "MIT" ]
2
2019-11-01T09:22:01.000Z
2019-11-11T23:25:48.000Z
appimagebuilder/commands/__init__.py
AppImageCrafters/AppImageBuilder
dd041050e65f8eff28f878a092fd07bcf3ec5a4d
[ "MIT" ]
null
null
null
# Copyright 2021 Alexis Lopez Zubieta # # Permission is hereby granted, free of charge, to any person obtaining a # copy of this software and associated documentation files (the "Software"), # to deal in the Software without restriction, including without limitation the # rights to use, copy, modify, merge, publi...
46.416667
80
0.821364
a1b7b8461ace82a3b93d583409c79ac7d9264fbf
568
py
Python
tests/test_observable/test_let.py
yutiansut/RxPY
c3bbba77f9ebd7706c949141725e220096deabd4
[ "ECL-2.0", "Apache-2.0" ]
1
2018-11-16T09:07:13.000Z
2018-11-16T09:07:13.000Z
tests/test_observable/test_let.py
yutiansut/RxPY
c3bbba77f9ebd7706c949141725e220096deabd4
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
tests/test_observable/test_let.py
yutiansut/RxPY
c3bbba77f9ebd7706c949141725e220096deabd4
[ "ECL-2.0", "Apache-2.0" ]
1
2020-05-08T08:23:08.000Z
2020-05-08T08:23:08.000Z
import unittest from rx import Observable from rx.testing import ReactiveTest on_next = ReactiveTest.on_next on_completed = ReactiveTest.on_completed on_error = ReactiveTest.on_error subscribe = ReactiveTest.subscribe subscribed = ReactiveTest.subscribed disposed = ReactiveTest.disposed created = ReactiveTest.created...
23.666667
50
0.730634
0db53e4a81ae67ef126a941b9b0e50b2813d8aae
769
py
Python
app/core/admin.py
zloybreg/drf_api
32e846a661681f198775d880be3fbc69913ef966
[ "MIT" ]
null
null
null
app/core/admin.py
zloybreg/drf_api
32e846a661681f198775d880be3fbc69913ef966
[ "MIT" ]
null
null
null
app/core/admin.py
zloybreg/drf_api
32e846a661681f198775d880be3fbc69913ef966
[ "MIT" ]
null
null
null
from django.contrib import admin from django.contrib.auth.admin import UserAdmin as BaseUserAdmin from django.utils.translation import gettext as _ from core import models class UserAdmin(BaseUserAdmin): ordering = ['id'] list_display = ['email', 'name'] fieldsets = ( (None, {'fields': ('email', ...
25.633333
66
0.559168
6a172fedff1e113bc7e7d505cf3b4bb36902a83d
2,061
py
Python
horovod/spark/driver/mpirun_rsh.py
hgao10/horovod_simulation
3678a7d1d424931f48af4b53ef3293073af71c2e
[ "Apache-2.0" ]
null
null
null
horovod/spark/driver/mpirun_rsh.py
hgao10/horovod_simulation
3678a7d1d424931f48af4b53ef3293073af71c2e
[ "Apache-2.0" ]
null
null
null
horovod/spark/driver/mpirun_rsh.py
hgao10/horovod_simulation
3678a7d1d424931f48af4b53ef3293073af71c2e
[ "Apache-2.0" ]
null
null
null
# Copyright 2019 Uber Technologies, 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 applica...
39.634615
88
0.683649
98e6f25679b634fe13137eab277603d2a07c07f3
386
py
Python
horizon/openstack_dashboard/api/cdn/test/commonTest.py
yianjiajia/openstack_horizon
9e36a4c3648ef29d0df6912d990465f51d6124a6
[ "Apache-2.0" ]
null
null
null
horizon/openstack_dashboard/api/cdn/test/commonTest.py
yianjiajia/openstack_horizon
9e36a4c3648ef29d0df6912d990465f51d6124a6
[ "Apache-2.0" ]
null
null
null
horizon/openstack_dashboard/api/cdn/test/commonTest.py
yianjiajia/openstack_horizon
9e36a4c3648ef29d0df6912d990465f51d6124a6
[ "Apache-2.0" ]
null
null
null
''' Created on 2014-4-25 @author: zzh ''' import unittest class CommonTest(unittest.TestCase): Host = "xxxx" def setUp(self): pass def tearDown(self): pass def testVar(self): print "-----start---" strs = self.returnWrong() print strs def r...
16.782609
36
0.523316
32727b474fccf44f56671fb8c6b4c0932d300301
3,424
py
Python
userbot/modules/blacklist.py
nayslaa/naysla
0352971c5cd6389d0eafaf398cdc83025a46f730
[ "Naumen", "Condor-1.1", "MS-PL" ]
1
2022-02-21T18:40:44.000Z
2022-02-21T18:40:44.000Z
userbot/modules/blacklist.py
nayslaa/naysla
0352971c5cd6389d0eafaf398cdc83025a46f730
[ "Naumen", "Condor-1.1", "MS-PL" ]
null
null
null
userbot/modules/blacklist.py
nayslaa/naysla
0352971c5cd6389d0eafaf398cdc83025a46f730
[ "Naumen", "Condor-1.1", "MS-PL" ]
null
null
null
# Copyright (C) 2019 The Raphielscape Company LLC. # # Licensed under the Raphielscape Public License, Version 1.d (the "License"); # you may not use this file except in compliance with the License. # port to userbot from uniborg by @keselekpermen69 import asyncio import io import re import userbot.modules.sql_helpe...
34.585859
90
0.635514
7d716da1a698db3b0e217269a851608d6decf392
2,277
py
Python
parser/fase2/team22/Instrucciones/FunctionMathematical/Log.py
Josue-Zea/tytus
f9e4be9a8c03eb698fade7a748972e4f52d46685
[ "MIT" ]
35
2020-12-07T03:11:43.000Z
2021-04-15T17:38:16.000Z
parser/fase2/team22/Instrucciones/FunctionMathematical/Log.py
Josue-Zea/tytus
f9e4be9a8c03eb698fade7a748972e4f52d46685
[ "MIT" ]
47
2020-12-09T01:29:09.000Z
2021-01-13T05:37:50.000Z
parser/fase2/team22/Instrucciones/FunctionMathematical/Log.py
Josue-Zea/tytus
f9e4be9a8c03eb698fade7a748972e4f52d46685
[ "MIT" ]
556
2020-12-07T03:13:31.000Z
2021-06-17T17:41:10.000Z
import math from Instrucciones.TablaSimbolos.Instruccion import Instruccion from Instrucciones.TablaSimbolos.Tipo import Tipo_Dato, Tipo from Instrucciones.Excepcion import Excepcion from Instrucciones.TablaSimbolos import Instruccion3D as c3d from Optimizador.C3D import Valor as ClassValor from Optimizador.C3D import ...
51.75
335
0.696091
0a626b0fde558d7e790ecf7fff147625a29a7a73
361
py
Python
tests/test_models.py
mariosgn/django-minibugs
ee3814f9a95860d7f5b057558e151749b508f745
[ "BSD-3-Clause" ]
null
null
null
tests/test_models.py
mariosgn/django-minibugs
ee3814f9a95860d7f5b057558e151749b508f745
[ "BSD-3-Clause" ]
null
null
null
tests/test_models.py
mariosgn/django-minibugs
ee3814f9a95860d7f5b057558e151749b508f745
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- """ test_django-minibugs ------------ Tests for `django-minibugs` models module. """ import os import shutil import unittest from minibugs import models class TestMinibugs(unittest.TestCase): def setUp(self): pass def test_something(self): pa...
12.892857
42
0.634349
039194324e5fc38a89fe683f2182aed0a9a3af76
10,089
py
Python
pycity_resilience/ga/preprocess/add_bes.py
RWTH-EBC/pyCity_resilience
e0ff1e137adb0edec0509b8b50ca0931e761a9b4
[ "MIT" ]
3
2020-06-18T02:01:09.000Z
2020-10-20T13:57:10.000Z
pycity_resilience/ga/preprocess/add_bes.py
RWTH-EBC/pyCity_resilience
e0ff1e137adb0edec0509b8b50ca0931e761a9b4
[ "MIT" ]
null
null
null
pycity_resilience/ga/preprocess/add_bes.py
RWTH-EBC/pyCity_resilience
e0ff1e137adb0edec0509b8b50ca0931e761a9b4
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- """ Script to add bes with all possible device types to all buildings, if not already existent. Necessary to enable GA usage. All newly added devices are saved on bes, but set to False (e.g. hasChp == False) """ from __future__ import division import warnings import pycit...
38.507634
79
0.45505
e9001bc3e2700295dcb6f2b339bf42162c336737
1,263
py
Python
python/pySimE/space/exp/OrbitalTransferOpt/OrbOpt_map/RandomMD.py
ProkopHapala/SimpleSimulationEngine
240f9b7e85b3a6eda7a27dc15fe3f7b8c08774c5
[ "MIT" ]
26
2016-12-04T04:45:12.000Z
2022-03-24T09:39:28.000Z
python/pySimE/space/exp/OrbitalTransferOpt/OrbOpt_map/RandomMD.py
Aki78/FlightAI
9c5480f2392c9c89b9fee4902db0c4cde5323a6c
[ "MIT" ]
null
null
null
python/pySimE/space/exp/OrbitalTransferOpt/OrbOpt_map/RandomMD.py
Aki78/FlightAI
9c5480f2392c9c89b9fee4902db0c4cde5323a6c
[ "MIT" ]
2
2019-02-09T12:31:06.000Z
2019-04-28T02:24:50.000Z
from pylab import * def MCMD_Run( fitnesFunc, XBest, stepSize, accuracy, stopAfter, missRatio, maxIter, GenHistory, wStep=0.7, fBias = 3.0, kBias0=0.5, kBiasf = 0.95 ): fitness = 100000000 fitness = fitnesFunc(Gen) print print " ========= MC-(quasi)MD Optimization ================= " print "stopAfte...
30.071429
151
0.577989
1c62e623d2a9e57c17e9c07ee2f68a401637c442
4,521
py
Python
API/src/main/resources/Lib/robot/running/outputcapture.py
TagExpress/SikuliX1
de9da11794dd94b3821eddc5c01b534d3f2fe828
[ "MIT" ]
null
null
null
API/src/main/resources/Lib/robot/running/outputcapture.py
TagExpress/SikuliX1
de9da11794dd94b3821eddc5c01b534d3f2fe828
[ "MIT" ]
null
null
null
API/src/main/resources/Lib/robot/running/outputcapture.py
TagExpress/SikuliX1
de9da11794dd94b3821eddc5c01b534d3f2fe828
[ "MIT" ]
null
null
null
# Copyright (c) 2010-2020, sikuli.org, sikulix.com - MIT license # # 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 b...
33
79
0.648971
36d78c2da8b0289a64c97731aceff1c323bd9dfa
542
py
Python
mmderain/models/common/utils.py
biubiubiiu/derain-toolbox
1669138d1aaa72c986d70d03f9cde7dbbbb70fa1
[ "Apache-2.0" ]
4
2022-02-22T13:20:15.000Z
2022-03-23T03:30:15.000Z
mmderain/models/common/utils.py
biubiubiiu/derain-toolbox
1669138d1aaa72c986d70d03f9cde7dbbbb70fa1
[ "Apache-2.0" ]
null
null
null
mmderain/models/common/utils.py
biubiubiiu/derain-toolbox
1669138d1aaa72c986d70d03f9cde7dbbbb70fa1
[ "Apache-2.0" ]
1
2022-03-22T14:10:37.000Z
2022-03-22T14:10:37.000Z
from typing import Tuple import torch from torch import nn def make_layer(block, num_blocks, **kwarg): """Make layers by stacking the same blocks. Args: block (nn.module): nn.module class for basic block. num_blocks (int): number of blocks. Returns: nn.Sequential: Stacked blocks...
21.68
59
0.647601
61a25a32b986564287e9ab744ec5136d2b017e17
4,420
py
Python
src/streamlink/plugins/senategov.py
xcgx/streamlink
b635e0d9d0fe9363817a96ec7d31faefed95cb57
[ "BSD-2-Clause" ]
10
2017-04-10T18:25:41.000Z
2021-09-15T20:14:58.000Z
src/streamlink/plugins/senategov.py
xcgx/streamlink
b635e0d9d0fe9363817a96ec7d31faefed95cb57
[ "BSD-2-Clause" ]
9
2020-04-04T09:49:52.000Z
2020-04-21T01:52:02.000Z
src/streamlink/plugins/senategov.py
xcgx/streamlink
b635e0d9d0fe9363817a96ec7d31faefed95cb57
[ "BSD-2-Clause" ]
4
2017-03-17T12:28:27.000Z
2018-01-11T21:14:32.000Z
import logging import re from urllib.parse import parse_qsl, urlparse from streamlink.plugin import Plugin, pluginmatcher from streamlink.plugin.api import useragents from streamlink.plugin.api.utils import itertags from streamlink.stream.hls import HLSStream log = logging.getLogger(__name__) @pluginmatcher(re.comp...
40.181818
100
0.576018
59e711f1a4ede15eb0f5ebfa6f64f53b59eff9e9
28,707
py
Python
code/main.py
ASU-ESIC-FAN-Lab/CVPR_2019_PNI
031e24fbffec56730840a7406be2be47cd5f234c
[ "Apache-2.0" ]
41
2019-04-22T19:09:12.000Z
2022-03-26T15:20:18.000Z
code/main.py
ASU-ESIC-FAN-Lab/CVPR_2019_PNI
031e24fbffec56730840a7406be2be47cd5f234c
[ "Apache-2.0" ]
3
2019-10-20T04:37:56.000Z
2021-12-02T06:47:37.000Z
code/main.py
ASU-ESIC-FAN-Lab/CVPR_2019_PNI
031e24fbffec56730840a7406be2be47cd5f234c
[ "Apache-2.0" ]
19
2019-08-10T15:53:18.000Z
2021-09-06T23:53:25.000Z
from __future__ import division from __future__ import absolute_import import os import sys import shutil import time import random import argparse import torch import torch.backends.cudnn as cudnn import torchvision.datasets as dset import torchvision.transforms as transforms from utils_.utils import AverageMeter, Re...
41.544139
135
0.581635
e42ffa0d86cb1fd8fce1808ddb451f30c854bd8d
3,539
py
Python
bindings/python/ensmallen/datasets/string/mesocricetusauratus.py
AnacletoLAB/ensmallen_graph
b2c1b18fb1e5801712852bcc239f239e03076f09
[ "MIT" ]
5
2021-02-17T00:44:45.000Z
2021-08-09T16:41:47.000Z
bindings/python/ensmallen/datasets/string/mesocricetusauratus.py
AnacletoLAB/ensmallen_graph
b2c1b18fb1e5801712852bcc239f239e03076f09
[ "MIT" ]
18
2021-01-07T16:47:39.000Z
2021-08-12T21:51:32.000Z
bindings/python/ensmallen/datasets/string/mesocricetusauratus.py
AnacletoLAB/ensmallen
b2c1b18fb1e5801712852bcc239f239e03076f09
[ "MIT" ]
3
2021-01-14T02:20:59.000Z
2021-08-04T19:09:52.000Z
""" This file offers the methods to automatically retrieve the graph Mesocricetus auratus. The graph is automatically retrieved from the STRING repository. References --------------------- Please cite the following if you use the data: ```bib @article{szklarczyk2019string, title={STRING v11: protein--protein a...
32.768519
223
0.676745
2bb1b43a8f102e66f7358441933b4391d2965b4c
8,150
py
Python
contacts/tests.py
Gugaon/Django-CRM
abcf8fc46b1e68ad902c5cd75fec4b95d616c2c9
[ "MIT" ]
null
null
null
contacts/tests.py
Gugaon/Django-CRM
abcf8fc46b1e68ad902c5cd75fec4b95d616c2c9
[ "MIT" ]
null
null
null
contacts/tests.py
Gugaon/Django-CRM
abcf8fc46b1e68ad902c5cd75fec4b95d616c2c9
[ "MIT" ]
null
null
null
from django.test import TestCase from contacts.models import Contact from common.models import Address, User, Comment, Attachments from cases.models import Case from django.test import Client from django.urls import reverse class ContactObjectsCreation(object): def setUp(self): self.client = Client() ...
37.557604
78
0.611166
5820abcb8e0d7a40b9e57be8468017f32d16014f
819
py
Python
id_generate/check_id_type.py
TheJacksonLaboratory/jaxid_generator
be5222d9c5ce57a169b94b0afd1ae9f7f10a66c1
[ "Apache-2.0" ]
2
2020-10-19T17:21:09.000Z
2020-10-20T14:27:25.000Z
id_generate/check_id_type.py
cometsong/jaxid_generator
be5222d9c5ce57a169b94b0afd1ae9f7f10a66c1
[ "Apache-2.0" ]
null
null
null
id_generate/check_id_type.py
cometsong/jaxid_generator
be5222d9c5ce57a169b94b0afd1ae9f7f10a66c1
[ "Apache-2.0" ]
null
null
null
import re def check_id_type(row_dict): """Determine which type of id this record holds. Varying on specific field values and lack thereof. Results: 'specimen', 'extraction', 'library', 'pool', 'Invalid' """ parent = row_dict['parent_jaxid'] sample = row_dict['sample_type'] nucleic = row_dic...
29.25
76
0.643468
1f5ed3e63c7243e6f553e512c5e67b49632eae2f
1,092
py
Python
sa/profiles/AlliedTelesis/AT8000S/profile.py
prorevizor/noc
37e44b8afc64318b10699c06a1138eee9e7d6a4e
[ "BSD-3-Clause" ]
84
2017-10-22T11:01:39.000Z
2022-02-27T03:43:48.000Z
sa/profiles/AlliedTelesis/AT8000S/profile.py
prorevizor/noc
37e44b8afc64318b10699c06a1138eee9e7d6a4e
[ "BSD-3-Clause" ]
22
2017-12-11T07:21:56.000Z
2021-09-23T02:53:50.000Z
sa/profiles/AlliedTelesis/AT8000S/profile.py
prorevizor/noc
37e44b8afc64318b10699c06a1138eee9e7d6a4e
[ "BSD-3-Clause" ]
23
2017-12-06T06:59:52.000Z
2022-02-24T00:02:25.000Z
# --------------------------------------------------------------------- # Vendor: Allied Telesis # OS: AT8000S # --------------------------------------------------------------------- # Copyright (C) 2007-2010 The NOC Project # coded by azhur # See LICENSE for details # ----------------------------------------------...
34.125
73
0.487179
7b79824d947b4bee654753e71068e95e75d994ce
37
py
Python
Demo/demolib/__init__.py
Hatsukikeika/CSC591-SIN21
36a65e7d2cbae755da98191fe877a488d1a9407a
[ "MIT" ]
null
null
null
Demo/demolib/__init__.py
Hatsukikeika/CSC591-SIN21
36a65e7d2cbae755da98191fe877a488d1a9407a
[ "MIT" ]
null
null
null
Demo/demolib/__init__.py
Hatsukikeika/CSC591-SIN21
36a65e7d2cbae755da98191fe877a488d1a9407a
[ "MIT" ]
null
null
null
def hello(): return 'Hello world'
18.5
24
0.648649
8aeb5f65bc4b1e61a443e797195aa6eb5e0d790b
4,518
py
Python
seaborn/flask/models/auto_register/auto_register.py
christensonb/Seaborn
adac2dfe60aabd754f93efd3b109213e5ee58772
[ "MIT" ]
null
null
null
seaborn/flask/models/auto_register/auto_register.py
christensonb/Seaborn
adac2dfe60aabd754f93efd3b109213e5ee58772
[ "MIT" ]
null
null
null
seaborn/flask/models/auto_register/auto_register.py
christensonb/Seaborn
adac2dfe60aabd754f93efd3b109213e5ee58772
[ "MIT" ]
null
null
null
__author__ = 'Ben Christenson' __date__ = "9/22/15" from seaborn.logger import log import inspect from seaborn.flask.models.models import ApiModel def auto_register_load_table(cls, api_model, id_name, database, unique_columns=None, clear_database=True, printer=None): """ This will create an update all columns...
41.833333
120
0.620629
7a6f03ce25537a1dfe0eb21bb6c42034c3588e76
6,949
py
Python
app/controllers/allocations.py
Joeper214/barm
77cd8ddcf73ceacf86b13ca819d8e56471e43574
[ "MIT" ]
2
2015-03-04T07:05:57.000Z
2015-03-04T07:06:00.000Z
app/controllers/allocations.py
Joeper214/barm
77cd8ddcf73ceacf86b13ca819d8e56471e43574
[ "MIT" ]
null
null
null
app/controllers/allocations.py
Joeper214/barm
77cd8ddcf73ceacf86b13ca819d8e56471e43574
[ "MIT" ]
null
null
null
from ferris import Controller, messages, route_with, route from ferris.components.pagination import Pagination from app.models.allocation import Allocation from app.models.project import Project from app.models.person import Person from app.models.event import Event from datetime import timedelta from plugins import ca...
36.573684
173
0.565405
23e6dfe785b434633d63eaa565beaac0332a3671
5,281
py
Python
indico/core/emails.py
aiforrural/Digital-Events-Example
628aaa8727b259b9367ac0ae1c5ba8e9e95eca82
[ "MIT" ]
1
2021-02-08T09:34:27.000Z
2021-02-08T09:34:27.000Z
indico/core/emails.py
pamirk/indico
c3b4e06b11cc21ad497f74d0b2ca901bc1b2a768
[ "MIT" ]
null
null
null
indico/core/emails.py
pamirk/indico
c3b4e06b11cc21ad497f74d0b2ca901bc1b2a768
[ "MIT" ]
null
null
null
# This file is part of Indico. # Copyright (C) 2002 - 2020 CERN # # Indico is free software; you can redistribute it and/or # modify it under the terms of the MIT License; see the # LICENSE file for more details. import os import pickle import tempfile from datetime import date from email.utils import make_msgid impo...
39.706767
120
0.65783
bc3b085b3a6455cc2920106fc0aba1c2aedffb12
5,040
py
Python
assignment1/run_cluster2.py
TheRevanchist/cs231n
b06607455bbb19c2eb1f0add7f2d53f34497dc71
[ "MIT" ]
null
null
null
assignment1/run_cluster2.py
TheRevanchist/cs231n
b06607455bbb19c2eb1f0add7f2d53f34497dc71
[ "MIT" ]
null
null
null
assignment1/run_cluster2.py
TheRevanchist/cs231n
b06607455bbb19c2eb1f0add7f2d53f34497dc71
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Thu Nov 24 10:10:17 2016 @author: revan """ # A bit of a setup import numpy as np import matplotlib.pyplot as plt from scipy import stats as st from cs231n.classifiers.two_layer_neural_net import TwoLayerNet from cs231n.classifiers.neural_net import ThreeLayerNet from cs231n.d...
32.101911
124
0.674206
6be12e14d074b9ba9a314fcdbd3f48350ad0c85d
3,747
py
Python
cinder/tests/api/openstack/volume/test_router.py
alexpilotti/cinder
df2f070604dad61738ccd3113016f76f2af20cae
[ "Apache-2.0" ]
null
null
null
cinder/tests/api/openstack/volume/test_router.py
alexpilotti/cinder
df2f070604dad61738ccd3113016f76f2af20cae
[ "Apache-2.0" ]
null
null
null
cinder/tests/api/openstack/volume/test_router.py
alexpilotti/cinder
df2f070604dad61738ccd3113016f76f2af20cae
[ "Apache-2.0" ]
null
null
null
# Copyright 2011 Denali Systems, 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 requ...
34.376147
78
0.680278
ea3860cd6d758aa91b6700400cc9fd4de1b29c19
592
py
Python
src/FlaskRTBCTF/users/utils.py
illseption/RTB-CTF-Framework
c70f1f488c03d138b87958c39407aef76d655f47
[ "MIT" ]
1
2020-05-22T13:57:52.000Z
2020-05-22T13:57:52.000Z
src/FlaskRTBCTF/users/utils.py
illseption/RTB-CTF-Framework
c70f1f488c03d138b87958c39407aef76d655f47
[ "MIT" ]
null
null
null
src/FlaskRTBCTF/users/utils.py
illseption/RTB-CTF-Framework
c70f1f488c03d138b87958c39407aef76d655f47
[ "MIT" ]
null
null
null
''' Utility Functions ''' import os import secrets from flask import url_for, current_app from flask_mail import Message from FlaskRTBCTF import mail def send_reset_email(user): token = user.get_reset_token() msg = Message('Password Reset Request', sender='noreply@demo.com', ...
29.6
91
0.702703
c95465582eabaa7004deb1d71c383aba26908941
1,086
py
Python
nis_visualizeer/ukf-nis-vis.py
vikram216/unscented-kalman-filter
1619fe365c73f198b39fa1de70fd5e203f8715a0
[ "MIT" ]
null
null
null
nis_visualizeer/ukf-nis-vis.py
vikram216/unscented-kalman-filter
1619fe365c73f198b39fa1de70fd5e203f8715a0
[ "MIT" ]
null
null
null
nis_visualizeer/ukf-nis-vis.py
vikram216/unscented-kalman-filter
1619fe365c73f198b39fa1de70fd5e203f8715a0
[ "MIT" ]
null
null
null
import matplotlib.pyplot as plt """ A chi square (X2) statistic is used to investigate whether distributions of categorical variables differ from one another. Here we consider 3 degrees of freedom for our system. Plotted against 95% line""" lidar_nis = [] with open('NISvals_laser.txt') as f: for line in f: ...
24.681818
78
0.721915
eb66bf358f3e4f6d795b44f50ac11c445949cc66
1,989
py
Python
invenio_app_ils/document_requests/mail/messages.py
jrcastro2/invenio-app-ils
502b9e7bac737863905976a1d07e2cd924f5d779
[ "MIT" ]
null
null
null
invenio_app_ils/document_requests/mail/messages.py
jrcastro2/invenio-app-ils
502b9e7bac737863905976a1d07e2cd924f5d779
[ "MIT" ]
null
null
null
invenio_app_ils/document_requests/mail/messages.py
jrcastro2/invenio-app-ils
502b9e7bac737863905976a1d07e2cd924f5d779
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # # Copyright (C) 2020 CERN. # # invenio-app-ils is free software; you can redistribute it and/or modify it # under the terms of the MIT License; see LICENSE file for more details. """Document requests mail message objects.""" from flask import current_app from invenio_app_ils.mail.messages i...
33.15
80
0.648567
f23e03e77bdec5503370785695c88fad3c60854e
2,032
py
Python
webservice/netconfnc/port_acc_nc.py
galenothiago/switch-automation
91d5494425e4d5dd00d2387631cd2983cfca51a2
[ "MIT" ]
null
null
null
webservice/netconfnc/port_acc_nc.py
galenothiago/switch-automation
91d5494425e4d5dd00d2387631cd2983cfca51a2
[ "MIT" ]
null
null
null
webservice/netconfnc/port_acc_nc.py
galenothiago/switch-automation
91d5494425e4d5dd00d2387631cd2983cfca51a2
[ "MIT" ]
1
2020-12-13T12:19:29.000Z
2020-12-13T12:19:29.000Z
#!/bin/python from ncclient import manager from config.settings import DEVICE_PARAMS # LinkType: 1 Access, 2 Trunk, 3 Hybrid def access(ip, user, password, interface, port_link_type, dados_vlan, desc_of_port): xml_port_type_acc = ''' <nc:config xmlns:nc="urn:ietf:params:xml:ns:netc...
45.155556
124
0.46063
222b6b645f961aebfb0b5431c0a2db1d1c74ebf3
5,286
py
Python
nephelae/mapping/WindMaps.py
pnarvor/nephelae_base
d5f1abeae0b0473b895b4735f182ddae0516a1bd
[ "BSD-3-Clause" ]
null
null
null
nephelae/mapping/WindMaps.py
pnarvor/nephelae_base
d5f1abeae0b0473b895b4735f182ddae0516a1bd
[ "BSD-3-Clause" ]
null
null
null
nephelae/mapping/WindMaps.py
pnarvor/nephelae_base
d5f1abeae0b0473b895b4735f182ddae0516a1bd
[ "BSD-3-Clause" ]
null
null
null
import numpy as np from sklearn.gaussian_process import kernels as gpk from nephelae.types import Bounds from nephelae.types import MultiObserverSubject from .MapInterface import MapInterface from .GprPredictor import GprPredictor from .GprKernel import WindKernel class WindMapConstant(MapInterface, MultiObserver...
31.652695
91
0.653235
0f15781fa942da438a9321d65fe800f98270ef4a
15,902
py
Python
django/contrib/admin/templatetags/admin_list.py
Miserlou/django
35ddeee45573de57ae3c791bf36496b4a7028ddf
[ "BSD-3-Clause" ]
2
2015-08-03T22:04:14.000Z
2015-08-03T22:04:16.000Z
django/contrib/admin/templatetags/admin_list.py
econchick/django
86c5c0154f69728eba4aad6204621f07cdd3459d
[ "BSD-3-Clause" ]
null
null
null
django/contrib/admin/templatetags/admin_list.py
econchick/django
86c5c0154f69728eba4aad6204621f07cdd3459d
[ "BSD-3-Clause" ]
1
2019-07-15T02:35:16.000Z
2019-07-15T02:35:16.000Z
from __future__ import unicode_literals import datetime from django.contrib.admin.util import (lookup_field, display_for_field, display_for_value, label_for_field) from django.contrib.admin.views.main import (ALL_VAR, EMPTY_CHANGELIST_VALUE, ORDER_VAR, PAGE_VAR, SEARCH_VAR) from django.contrib.admin.templatet...
40.984536
127
0.574582
d1f1e8ffc4fc0ce14add9e2f3cccb1f658a79f50
728
py
Python
common/util/updateQubitFreq.py
calebfried/Qlab
a7e559b287b6eafec70d679da1ede95436b47505
[ "Apache-2.0" ]
28
2015-09-06T03:24:08.000Z
2022-02-11T07:43:32.000Z
common/util/updateQubitFreq.py
calebfried/Qlab
a7e559b287b6eafec70d679da1ede95436b47505
[ "Apache-2.0" ]
50
2015-01-15T23:50:28.000Z
2017-07-20T13:20:35.000Z
common/util/updateQubitFreq.py
calebfried/Qlab
a7e559b287b6eafec70d679da1ede95436b47505
[ "Apache-2.0" ]
12
2015-02-13T05:30:36.000Z
2021-06-02T15:32:52.000Z
import argparse import sys, os parser = argparse.ArgumentParser() parser.add_argument('pyqlabpath', help='path to PyQLab directory') parser.add_argument('qubit', help='qubit') parser.add_argument('frequency', type=float, help='SSB frequency') args = parser.parse_args() sys.path.append(args.pyqlabpath) from QGL.Channel...
29.12
79
0.792582
e16a234bfd723604e60e7c4c6b63cb0a81eb9191
46,153
py
Python
superset/models/core.py
KilimAnnejaro/incubator-superset
402fd7981a8b7acf880b4037c6b8f80a21db805c
[ "Apache-2.0" ]
1
2018-08-25T02:48:53.000Z
2018-08-25T02:48:53.000Z
superset/models/core.py
rockyCheung/incubator-superset
9423e9a8be1c0fc0bad8fbd2f04fe298d08469bf
[ "Apache-2.0" ]
16
2021-03-20T05:43:23.000Z
2022-03-29T22:29:08.000Z
superset/models/core.py
rockyCheung/incubator-superset
9423e9a8be1c0fc0bad8fbd2f04fe298d08469bf
[ "Apache-2.0" ]
2
2019-11-29T06:43:56.000Z
2020-02-10T12:19:20.000Z
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
35.749806
88
0.62581
220e766094665871d789b7f42d94ae3f57eeab5b
305
py
Python
froide/accesstoken/widgets.py
manonthemat/froide
698c49935eaf2e922f3c9f6a46af0fd545ccbbbb
[ "MIT" ]
null
null
null
froide/accesstoken/widgets.py
manonthemat/froide
698c49935eaf2e922f3c9f6a46af0fd545ccbbbb
[ "MIT" ]
null
null
null
froide/accesstoken/widgets.py
manonthemat/froide
698c49935eaf2e922f3c9f6a46af0fd545ccbbbb
[ "MIT" ]
null
null
null
from django import forms class TokenWidget(forms.widgets.TextInput): template_name = 'accesstoken/token_widget.html' def get_context(self, name, value, attrs): context = super().get_context(name, value, attrs) context['widget'].update(self.extra_context) return context
27.727273
57
0.708197
e8522b095826622721de9f2e329c8c361f6f7c41
3,350
py
Python
PaddleRec/tagspace/infer.py
FrancisLiang/models-1
e14d5bc1ab36d0dd11977f27cff54605bf99c945
[ "Apache-2.0" ]
4
2020-01-04T13:15:02.000Z
2021-07-21T07:50:02.000Z
PaddleRec/tagspace/infer.py
FrancisLiang/models-1
e14d5bc1ab36d0dd11977f27cff54605bf99c945
[ "Apache-2.0" ]
2
2019-06-26T03:21:49.000Z
2019-09-19T09:43:42.000Z
PaddleRec/tagspace/infer.py
FrancisLiang/models-1
e14d5bc1ab36d0dd11977f27cff54605bf99c945
[ "Apache-2.0" ]
3
2019-10-31T07:18:49.000Z
2020-01-13T03:18:39.000Z
import sys import argparse import time import math import unittest import contextlib import numpy as np import six import paddle.fluid as fluid import paddle import utils def parse_args(): parser = argparse.ArgumentParser("tagspace benchmark.") parser.add_argument( '--test_dir', type=str, default='tes...
33.5
85
0.589552
55d8886a293c72aaefd8bb08c9ebd5f7aa5163f0
8,878
py
Python
translate.py
emw0083/python-translation-project
5d6691320348c6b7f9f36999960ce92bb75a9093
[ "CC-BY-4.0" ]
null
null
null
translate.py
emw0083/python-translation-project
5d6691320348c6b7f9f36999960ce92bb75a9093
[ "CC-BY-4.0" ]
null
null
null
translate.py
emw0083/python-translation-project
5d6691320348c6b7f9f36999960ce92bb75a9093
[ "CC-BY-4.0" ]
null
null
null
#! /usr/bin/env python3 import sys def translate_sequence(rna_sequence, genetic_code): """Translates a sequence of RNA into a sequence of amino acids. Translates `rna_sequence` into string of amino acids, according to the `genetic_code` given as a dict. Translation begins at the first position of the...
37.146444
787
0.552151
b205743af5edeb820d29a78eea08e18bb583f250
16,861
py
Python
instrumentserver/gui/instruments.py
hatlabcz/instrumentserver
113f633baa4edb86225176665ffb296430559b16
[ "MIT" ]
1
2020-05-05T15:22:36.000Z
2020-05-05T15:22:36.000Z
instrumentserver/gui/instruments.py
hatlabcz/instrumentserver
113f633baa4edb86225176665ffb296430559b16
[ "MIT" ]
6
2020-04-21T18:35:51.000Z
2020-05-17T03:56:52.000Z
instrumentserver/gui/instruments.py
hatlabcz/instrumentserver
113f633baa4edb86225176665ffb296430559b16
[ "MIT" ]
null
null
null
from typing import Optional, Any, Dict, List, Tuple, Union from qcodes import Instrument, Parameter from .. import QtWidgets, QtCore, QtGui from ..serialize import toParamDict from ..params import ParameterManager, paramTypeFromName, ParameterTypes, parameterTypes from ..helpers import stringToArgsAndKwargs, nestedAt...
35.722458
90
0.60038
00cbf8dc4a8fd3af67e896a52f3486da61d1a01c
3,787
py
Python
Order_Application_Java/build/classes/files/face_detection.py
aditya1962/BuyGrand
37a7ab2d40bb891ce054c02c7b7da443cc5a5ca6
[ "MIT" ]
4
2019-10-09T17:14:44.000Z
2020-10-08T20:05:15.000Z
Order_Application_Java/src/files/face_detection.py
aditya1962/BuyGrand
37a7ab2d40bb891ce054c02c7b7da443cc5a5ca6
[ "MIT" ]
null
null
null
Order_Application_Java/src/files/face_detection.py
aditya1962/BuyGrand
37a7ab2d40bb891ce054c02c7b7da443cc5a5ca6
[ "MIT" ]
null
null
null
import dlib import numpy as np import cv2 import imageio from PIL import Image from PIL import ImageFont from PIL import ImageDraw import face_recognition import datetime #Section to capture video and save images #### #get video input from webcamera camera = cv2.VideoCapture(0) #name of the window used to capture th...
35.726415
132
0.723264
84200d8dc36af19c9981b5643debc42299134435
5,304
py
Python
pipeline_dp/pipeline_operations.py
siddhartha18101/PipelineDP
69b2db4b248b05f1352edee2edac777cdd91b83f
[ "Apache-2.0" ]
null
null
null
pipeline_dp/pipeline_operations.py
siddhartha18101/PipelineDP
69b2db4b248b05f1352edee2edac777cdd91b83f
[ "Apache-2.0" ]
null
null
null
pipeline_dp/pipeline_operations.py
siddhartha18101/PipelineDP
69b2db4b248b05f1352edee2edac777cdd91b83f
[ "Apache-2.0" ]
null
null
null
"""Adapters for working with pipeline frameworks.""" import random import abc import apache_beam as beam import apache_beam.transforms.combiners as combiners import collections import typing class PipelineOperations(abc.ABC): """Interface for pipeline frameworks adapters.""" @abc.abstractmethod def map...
28.826087
85
0.627074
d17b137fb611700c27ba487e3fc502749be1d6c3
746
py
Python
app/main.py
Caresto/webhook-notifications
82303038902de6eadffc6f66c727816f91adf4a2
[ "MIT" ]
null
null
null
app/main.py
Caresto/webhook-notifications
82303038902de6eadffc6f66c727816f91adf4a2
[ "MIT" ]
null
null
null
app/main.py
Caresto/webhook-notifications
82303038902de6eadffc6f66c727816f91adf4a2
[ "MIT" ]
null
null
null
from flask import Flask, request import os import requests import json app = Flask(__name__) url_to_post = os.getenv('URL') @app.route('/events', methods=['POST']) def events(): data = request.get_json() headers = {'Content-type': 'application/json'} requests.post(url_to_post, headers = headers, data = fo...
31.083333
115
0.693029
0df9e8eb134be1b30158f58598344f732d13d62d
2,042
py
Python
flow_py_sdk/signer/signer.py
janezpodhostnik/flow-py-sdk
8b10f4ca2290f5d31920b86fd93a68a643cb1c75
[ "MIT" ]
21
2020-11-25T16:30:53.000Z
2022-03-08T06:24:02.000Z
flow_py_sdk/signer/signer.py
janezpodhostnik/flow-py-sdk
8b10f4ca2290f5d31920b86fd93a68a643cb1c75
[ "MIT" ]
29
2021-03-06T19:04:33.000Z
2022-03-18T15:16:44.000Z
flow_py_sdk/signer/signer.py
janezpodhostnik/flow-py-sdk
8b10f4ca2290f5d31920b86fd93a68a643cb1c75
[ "MIT" ]
15
2021-03-06T18:36:40.000Z
2022-02-09T15:14:01.000Z
from abc import ABC, abstractmethod from typing import Optional from flow_py_sdk.exceptions import PySDKError DomainTagLength = 32 def _padded_domain_tag(s: str) -> bytes: encoded = s.encode("utf-8") if len(encoded) > DomainTagLength: raise PySDKError( f"domain tag {s} cannot be longer t...
24.023529
106
0.595005
efbd887241efd353e6384d9a19af718a26796e6d
1,691
py
Python
wax/gym/haiku_agent.py
eserie/wax-ml
9cf92ff5c41ea681fd3eaaf4560b3380f986ee1e
[ "MIT", "ECL-2.0", "Apache-2.0", "BSD-3-Clause" ]
42
2021-06-14T16:27:54.000Z
2022-03-23T09:51:42.000Z
wax/gym/haiku_agent.py
eserie/wax-ml
9cf92ff5c41ea681fd3eaaf4560b3380f986ee1e
[ "MIT", "ECL-2.0", "Apache-2.0", "BSD-3-Clause" ]
1
2021-10-01T12:45:29.000Z
2021-10-03T18:06:39.000Z
wax/gym/haiku_agent.py
eserie/wax-ml
9cf92ff5c41ea681fd3eaaf4560b3380f986ee1e
[ "MIT", "ECL-2.0", "Apache-2.0", "BSD-3-Clause" ]
5
2021-06-11T12:32:41.000Z
2022-02-17T16:13:15.000Z
# Copyright 2021 The WAX-ML Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in w...
30.745455
94
0.694855
bcfe0b09f86c49c310c92c5e4428db1e1a2a1a44
10,661
py
Python
socialite/jython/Lib/test/test_types.py
Wangqge/PowerLog_ae
8546afbcb9a77d516e8c3f0dfbaf2041a4b888f9
[ "Apache-2.0" ]
49
2015-03-10T17:34:19.000Z
2021-11-10T22:23:18.000Z
Lib/test/test_types.py
weimingtom/j2mepython-midp
472333ebc6a7f06d92c5ede85c8ed55e4ad66c6d
[ "CNRI-Jython", "PSF-2.0", "Apache-2.0" ]
1
2021-04-11T15:01:12.000Z
2021-04-11T15:01:12.000Z
Lib/test/test_types.py
weimingtom/j2mepython-midp
472333ebc6a7f06d92c5ede85c8ed55e4ad66c6d
[ "CNRI-Jython", "PSF-2.0", "Apache-2.0" ]
32
2015-02-06T12:10:32.000Z
2019-06-18T03:21:36.000Z
# Python test set -- part 6, built-in types from test.test_support import * print '6. Built-in types' print '6.1 Truth value testing' if None: raise TestFailed, 'None is true instead of false' if 0: raise TestFailed, '0 is true instead of false' if 0L: raise TestFailed, '0L is true instead of false' if 0.0: raise Te...
36.889273
101
0.644874
b76bfbc82d121fd25049feea142837028f8b9cc9
10,388
py
Python
tests/python/unittest/test_profiler.py
sheep94lion/incubator-mxnet
c06ff4c8168c8d0bf05f7d188ae2e1c6d779bd9e
[ "Apache-2.0" ]
null
null
null
tests/python/unittest/test_profiler.py
sheep94lion/incubator-mxnet
c06ff4c8168c8d0bf05f7d188ae2e1c6d779bd9e
[ "Apache-2.0" ]
null
null
null
tests/python/unittest/test_profiler.py
sheep94lion/incubator-mxnet
c06ff4c8168c8d0bf05f7d188ae2e1c6d779bd9e
[ "Apache-2.0" ]
null
null
null
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
34.976431
95
0.655949
8f88befb8c6b6088f9528ca76d6ae6dcb071df0b
1,250
py
Python
tests/simple_test.py
benvial/gyptis
3f197fe33d0a0bac72be05a474baff4e450af0ab
[ "MIT" ]
null
null
null
tests/simple_test.py
benvial/gyptis
3f197fe33d0a0bac72be05a474baff4e450af0ab
[ "MIT" ]
null
null
null
tests/simple_test.py
benvial/gyptis
3f197fe33d0a0bac72be05a474baff4e450af0ab
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- # Author: Benjamin Vial # License: MIT import time from gyptis import BoxPML, Scattering from gyptis.source import PlaneWave from gyptis.utils import list_time def test_simple(pmesh=10): polarization = "TM" degree = 2 wavelength = 0.3 options = {"Gener...
25
84
0.6288
d6a30ef9f7b1066360fcd48fc862a8961bd4f60e
4,233
py
Python
rubato/utils/color.py
tinmarr/Alien-Fisher-Man
79aef592c7628860a1175892ac00ebd142305878
[ "MIT" ]
null
null
null
rubato/utils/color.py
tinmarr/Alien-Fisher-Man
79aef592c7628860a1175892ac00ebd142305878
[ "MIT" ]
null
null
null
rubato/utils/color.py
tinmarr/Alien-Fisher-Man
79aef592c7628860a1175892ac00ebd142305878
[ "MIT" ]
null
null
null
from rubato.utils import PMath class Color: # colors from https://www.rapidtables.com/web/color/RGB_Color.html black = (0, 0, 0) white = (255, 255, 255) red = (255, 0, 0) lime = (0, 255, 0) blue = (0, 0, 255) yellow = (255, 255, 0) cyan = aqua = (0, 255, 255) magenta = fuchsia = (2...
27.134615
85
0.437042
636f31720183d21b85b85955aec8e82d62fa809c
282
py
Python
forex/forex/doctype/forward_booking_underlying/forward_booking_underlying.py
finbyz/forex
46c248424fcf9625ef57f7ab05d356b2bed5abc8
[ "MIT" ]
2
2017-06-03T12:24:43.000Z
2018-02-18T10:42:23.000Z
forex/forex/doctype/forward_booking_underlying/forward_booking_underlying.py
finbyz/forex
46c248424fcf9625ef57f7ab05d356b2bed5abc8
[ "MIT" ]
null
null
null
forex/forex/doctype/forward_booking_underlying/forward_booking_underlying.py
finbyz/forex
46c248424fcf9625ef57f7ab05d356b2bed5abc8
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright (c) 2015, FinByz Tech Pvt. Ltd. and contributors # For license information, please see license.txt from __future__ import unicode_literals import frappe from frappe.model.document import Document class ForwardBookingUnderlying(Document): pass
25.636364
60
0.783688
598404928e7fb5d4df8157ec5d04d6d2e595ac58
1,621
py
Python
python/handler.py
jerobins/JamesThings
db2e9914315ed8fef1630e7b821847456531148e
[ "Apache-2.0" ]
null
null
null
python/handler.py
jerobins/JamesThings
db2e9914315ed8fef1630e7b821847456531148e
[ "Apache-2.0" ]
null
null
null
python/handler.py
jerobins/JamesThings
db2e9914315ed8fef1630e7b821847456531148e
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/python from BaseHTTPServer import BaseHTTPRequestHandler, HTTPServer import subprocess, urlparse PORT_NUMBER = 8080 class myHandler(BaseHTTPRequestHandler): state = "off" # boots in off state # turn off logging def log_request(code='-', size='-'): return #Handler for the GET request...
25.730159
70
0.608267
88b6a2b0d8c7a5b50a73f3a85ef5d300c43a80c5
11,837
py
Python
hypernets/tabular/cache.py
Enpen/Hypernets
5fbf01412ffaef310855d98f52f8cc169e96246b
[ "Apache-2.0" ]
1,080
2020-06-22T07:44:22.000Z
2022-03-22T07:46:48.000Z
hypernets/tabular/cache.py
Enpen/Hypernets
5fbf01412ffaef310855d98f52f8cc169e96246b
[ "Apache-2.0" ]
24
2020-08-06T02:06:37.000Z
2022-03-31T03:34:35.000Z
hypernets/tabular/cache.py
Enpen/Hypernets
5fbf01412ffaef310855d98f52f8cc169e96246b
[ "Apache-2.0" ]
170
2020-08-14T08:39:18.000Z
2022-03-23T12:58:17.000Z
import inspect import pickle from functools import partial import dask.array as da import dask.dataframe as dd import pandas as pd from sklearn.base import BaseEstimator from hypernets import __version__ from hypernets.tabular import get_tool_box from hypernets.utils import fs, logging from .cfg import TabularCfg as ...
34.510204
104
0.589845