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
803c3d134a5f7c8c9d98bb08a92ab672814d7745
1,095
py
Python
aliyunsdkcore/auth/md5_tool.py
gikoluo/aliyun-python-sdk-core
5c4e79ad5f7668af048ae1a18d424c4919131a9c
[ "MIT" ]
1
2019-05-30T03:53:33.000Z
2019-05-30T03:53:33.000Z
aliyun-python-sdk-release-test/aliyunsdkcore/auth/md5_tool.py
liusc27/aliyun-openapi-python-sdk
5e3db3535dd21de987dc5981e71151327d5a884f
[ "Apache-2.0" ]
null
null
null
aliyun-python-sdk-release-test/aliyunsdkcore/auth/md5_tool.py
liusc27/aliyun-openapi-python-sdk
5e3db3535dd21de987dc5981e71151327d5a884f
[ "Apache-2.0" ]
4
2017-07-27T11:27:01.000Z
2020-09-01T07:49:21.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...
27.375
62
0.749772
969e16088d39a5ddc8574562df7c31103ae27330
5,288
py
Python
experiments/run_covid_experiments.py
AaltoPML/spatiotemporal-graph-kernels
b82529b6a1dfeb4ff06fb9ea0952ec926f0d7ae0
[ "Apache-2.0" ]
5
2022-03-25T16:17:50.000Z
2022-03-26T09:27:11.000Z
experiments/run_covid_experiments.py
AaltoPML/spatiotemporal-graph-kernels
b82529b6a1dfeb4ff06fb9ea0952ec926f0d7ae0
[ "Apache-2.0" ]
null
null
null
experiments/run_covid_experiments.py
AaltoPML/spatiotemporal-graph-kernels
b82529b6a1dfeb4ff06fb9ea0952ec926f0d7ae0
[ "Apache-2.0" ]
null
null
null
import os import pickle import json import time import argparse import copy from tqdm import tqdm import gpflow from graph_kernels import utils from graph_kernels import time_kernels from graph_kernels import data_utils from graph_kernels import utils_opt def parse_arguments(): parser = argparse.ArgumentParser...
38.318841
106
0.700265
b5f365b96f88cc30b8f42011d768c56a4bec7693
19,035
py
Python
tests/collection/test_collection.py
fathur/masonite-orm
99f32b18b1c5e227edb156ecd2d6205bde63e73e
[ "MIT" ]
null
null
null
tests/collection/test_collection.py
fathur/masonite-orm
99f32b18b1c5e227edb156ecd2d6205bde63e73e
[ "MIT" ]
null
null
null
tests/collection/test_collection.py
fathur/masonite-orm
99f32b18b1c5e227edb156ecd2d6205bde63e73e
[ "MIT" ]
null
null
null
import unittest from src.masoniteorm.collection import Collection from src.masoniteorm.factories import Factory as factory from src.masoniteorm.models import Model from tests.User import User class TestCollection(unittest.TestCase): def test_take(self): collection = Collection([1, 2, 3, 4]) self...
31.777963
88
0.494247
8e71ae57185a097cc1de3b1647ac61686a2e4f82
146
py
Python
uiautomator/constants.py
anuraagbaishya/uiautomator
e74de3bb579f623c66c47e5b3cbc1efd69180122
[ "MIT" ]
null
null
null
uiautomator/constants.py
anuraagbaishya/uiautomator
e74de3bb579f623c66c47e5b3cbc1efd69180122
[ "MIT" ]
null
null
null
uiautomator/constants.py
anuraagbaishya/uiautomator
e74de3bb579f623c66c47e5b3cbc1efd69180122
[ "MIT" ]
null
null
null
import os DEVICE_PORT = int(os.environ.get('UIAUTOMATOR_DEVICE_PORT', '9008')) LOCAL_PORT = int(os.environ.get('UIAUTOMATOR_LOCAL_PORT', '9008'))
36.5
68
0.767123
51017c0cad4122cb09a17ddf2e53f310fc1932ba
42,582
py
Python
hummingbot/connector/exchange/probit/probit_exchange.py
JulesText/hummingbot
96566b20f5fb4a6c6dc2edb39cb94b6cfc2a9444
[ "Apache-2.0" ]
null
null
null
hummingbot/connector/exchange/probit/probit_exchange.py
JulesText/hummingbot
96566b20f5fb4a6c6dc2edb39cb94b6cfc2a9444
[ "Apache-2.0" ]
null
null
null
hummingbot/connector/exchange/probit/probit_exchange.py
JulesText/hummingbot
96566b20f5fb4a6c6dc2edb39cb94b6cfc2a9444
[ "Apache-2.0" ]
null
null
null
import asyncio import logging import math import time from decimal import Decimal from typing import ( Any, AsyncIterable, Dict, List, Optional, ) import aiohttp import ujson from hummingbot.connector.exchange.probit import probit_constants as CONSTANTS, probit_utils from hummingbot.connector.exch...
44.495298
130
0.587126
75994074e2a40a85f511827639753c4e62393903
3,394
py
Python
yekpay/utils.py
maryam-afzp/django-yekpay
f7b9d7914035ea4f27238eba9e0c70227cc65046
[ "MIT" ]
3
2020-05-17T18:33:22.000Z
2021-12-06T08:31:42.000Z
yekpay/utils.py
Glyphack/django-yekpay
8c4a44853207be4ff0b1711c0524fb0201859b19
[ "MIT" ]
null
null
null
yekpay/utils.py
Glyphack/django-yekpay
8c4a44853207be4ff0b1711c0524fb0201859b19
[ "MIT" ]
4
2019-11-14T14:16:49.000Z
2021-12-06T08:31:44.000Z
from random import randint from django.apps import apps from django.urls import reverse from django.contrib.sites.models import Site import logging from .config import * def generate_yekpay_start_transaction_data(transaction): start_transaction_data = dict() start_transaction_data["merchantId"] = MERCHANTI...
32.634615
79
0.696229
acc4b6ea30fdf3989beaacf6a519a973c3f934e0
1,002
py
Python
rlds_creator/gym_renderer.py
plcuhk/rlds-creator
fc7b42a16cabb9590e6d8cf99fe6b29b682bd7b5
[ "Apache-2.0" ]
13
2021-08-09T06:35:18.000Z
2022-01-28T15:58:14.000Z
rlds_creator/gym_renderer.py
plcuhk/rlds-creator
fc7b42a16cabb9590e6d8cf99fe6b29b682bd7b5
[ "Apache-2.0" ]
1
2022-01-16T13:13:57.000Z
2022-01-16T15:04:59.000Z
rlds_creator/gym_renderer.py
plcuhk/rlds-creator
fc7b42a16cabb9590e6d8cf99fe6b29b682bd7b5
[ "Apache-2.0" ]
5
2021-09-27T14:35:20.000Z
2022-01-16T12:07:47.000Z
# coding=utf-8 # Copyright 2021 RLDSCreator 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 # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law o...
31.3125
74
0.740519
cc0b2af0a427ede5207a4898e3f20174eae8be68
832
py
Python
setup.py
hvnsweeting/uds
ffb1271ead70a6e9507e5df9e7b4ab5322394ca7
[ "MIT" ]
1
2019-05-31T01:53:39.000Z
2019-05-31T01:53:39.000Z
setup.py
hvnsweeting/uds
ffb1271ead70a6e9507e5df9e7b4ab5322394ca7
[ "MIT" ]
null
null
null
setup.py
hvnsweeting/uds
ffb1271ead70a6e9507e5df9e7b4ab5322394ca7
[ "MIT" ]
2
2019-05-31T01:54:08.000Z
2020-10-31T02:09:49.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- try: from setuptools import setup, find_packages except ImportError: from distutils.core import setup, find_packages requisites = ['requests-html>=0.10.0', 'requests>=2.19.1', 'crayons==0.2.0'] setup( name='uds', version='0.1.15', description='Diction...
26
76
0.641827
1a3aa7e9e8022782edf1b0a08bee33318f48fbdd
233
py
Python
tcpclient.py
OCEANOFANYTHING/blackhat_python3
b67ec0dfb84d2ae4745be8c4bd2e62b0e3ba1255
[ "MIT" ]
3
2017-12-06T01:15:41.000Z
2018-06-29T11:18:16.000Z
tcpclient.py
OCEANOFANYTHING/blackhat_python3
b67ec0dfb84d2ae4745be8c4bd2e62b0e3ba1255
[ "MIT" ]
null
null
null
tcpclient.py
OCEANOFANYTHING/blackhat_python3
b67ec0dfb84d2ae4745be8c4bd2e62b0e3ba1255
[ "MIT" ]
1
2020-09-28T18:44:22.000Z
2020-09-28T18:44:22.000Z
import socket host = '127.0.0.1' port = 4000 client = socket.socket(socket.AF_INET, socket.SOCK_STREAM) client.connect((host, port)) client.send(b'Hello! Is there anybody in there?!') response = client.recv(4096) print(response)
17.923077
58
0.733906
5a49efc3b9b768cf360feb49312517ad01ed1f69
3,702
py
Python
plenum/test/node_catchup_with_3pc/helper.py
jandayanan/indy-plenum
2815e994404c77ad87eddcfd09062d5fe6efc1c5
[ "Apache-2.0" ]
148
2017-07-11T19:05:25.000Z
2022-03-16T21:31:20.000Z
plenum/test/node_catchup_with_3pc/helper.py
jandayanan/indy-plenum
2815e994404c77ad87eddcfd09062d5fe6efc1c5
[ "Apache-2.0" ]
561
2017-06-29T17:59:56.000Z
2022-03-09T15:47:14.000Z
plenum/test/node_catchup_with_3pc/helper.py
jandayanan/indy-plenum
2815e994404c77ad87eddcfd09062d5fe6efc1c5
[ "Apache-2.0" ]
378
2017-06-29T17:45:27.000Z
2022-03-26T07:27:59.000Z
from contextlib import contextmanager from typing import Iterable from plenum.common.messages.node_messages import Commit from plenum.common.util import compare_3PC_keys from plenum.server.catchup.node_leecher_service import NodeLeecherService from plenum.test.delayers import delay_3pc, cr_delay from plenum.test.helpe...
46.860759
100
0.732577
314eea024a79da6b8d57f6e53a880a29e5cfe185
210
py
Python
app/main/errors.py
benjaminbills/pitches
e80135ac7a80f0d974c04606ad4814a78b097958
[ "MIT" ]
null
null
null
app/main/errors.py
benjaminbills/pitches
e80135ac7a80f0d974c04606ad4814a78b097958
[ "MIT" ]
null
null
null
app/main/errors.py
benjaminbills/pitches
e80135ac7a80f0d974c04606ad4814a78b097958
[ "MIT" ]
null
null
null
from flask import render_template from . import main @main.app_errorhandler(404) def four_Ow_four(error): """ Function to render the 404 error page """ return render_template("404.html"), 404
19.090909
43
0.709524
d29a885eec176a20fdd73845a7c83180deae25c6
892
py
Python
intake/source/__init__.py
danielballan/intake
5a70b7981b76717203f8f5ba74c0aea345405c8c
[ "BSD-2-Clause" ]
null
null
null
intake/source/__init__.py
danielballan/intake
5a70b7981b76717203f8f5ba74c0aea345405c8c
[ "BSD-2-Clause" ]
null
null
null
intake/source/__init__.py
danielballan/intake
5a70b7981b76717203f8f5ba74c0aea345405c8c
[ "BSD-2-Clause" ]
null
null
null
import logging logger = logging.getLogger('intake') # The registry is the mapping of plugin name (aka driver) to DataSource class registry = {} # A set of fully-qualifies package.module.Class mappings classes = {} def get_plugin_class(name): if name in registry: return registry[name] if '.' not in n...
29.733333
77
0.609865
c3223fb9b76b783152a2fab7f11e6f94a89e5358
7,551
py
Python
datacomp/__main__.py
kappamaki/datacomp
4ef24b16ff96fb06edcba6fdd85d8b7a4da31b0c
[ "MIT" ]
null
null
null
datacomp/__main__.py
kappamaki/datacomp
4ef24b16ff96fb06edcba6fdd85d8b7a4da31b0c
[ "MIT" ]
8
2021-07-20T18:35:53.000Z
2021-12-15T19:06:53.000Z
datacomp/__main__.py
kappamaki/datacomp
4ef24b16ff96fb06edcba6fdd85d8b7a4da31b0c
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 import argparse import sys from pathlib import Path import pandas as pd CRED = "\033[91m" CGRN = "\033[92m" CEND = "\033[0m" def series_nonequal_index(ser1, ser2): ser1_null = ser1.isnull() ser2_null = ser2.isnull() # Get index where series values are null in one series but the o...
36.302885
107
0.610912
9898c414703ca4313582b394a36e0a6ea33216f7
2,928
py
Python
src/ouraws.py
rahup97/IoT-video-surveillance
1471ed47944c837eb602a6fa366332330f975089
[ "MIT" ]
4
2019-03-02T06:15:58.000Z
2021-07-29T04:25:15.000Z
src/ouraws.py
rahup97/IoT-video-surveillance
1471ed47944c837eb602a6fa366332330f975089
[ "MIT" ]
null
null
null
src/ouraws.py
rahup97/IoT-video-surveillance
1471ed47944c837eb602a6fa366332330f975089
[ "MIT" ]
2
2019-03-28T21:37:10.000Z
2019-04-03T17:50:46.000Z
from boto3 import client import sys import logging import rds_config import pymysql import time from datetime import datetime import os now = time.localtime() rds_host = rds_config.db_endpoint name = rds_config.db_username password = rds_config.db_password db_name = rds_config.db_name port = 3306 conn = pymysql...
28.990099
152
0.632172
229ccf60204e0c3b789402ad4c66eddee532885f
2,525
py
Python
data/p4VQE/R4/benchmark/startQiskit333.py
UCLA-SEAL/QDiff
d968cbc47fe926b7f88b4adf10490f1edd6f8819
[ "BSD-3-Clause" ]
null
null
null
data/p4VQE/R4/benchmark/startQiskit333.py
UCLA-SEAL/QDiff
d968cbc47fe926b7f88b4adf10490f1edd6f8819
[ "BSD-3-Clause" ]
null
null
null
data/p4VQE/R4/benchmark/startQiskit333.py
UCLA-SEAL/QDiff
d968cbc47fe926b7f88b4adf10490f1edd6f8819
[ "BSD-3-Clause" ]
null
null
null
# qubit number=3 # total number=12 import numpy as np from qiskit import QuantumCircuit, execute, Aer, QuantumRegister, ClassicalRegister, transpile, BasicAer, IBMQ import networkx as nx from qiskit.visualization import plot_histogram from typing import * from pprint import pprint from math import log2 from collectio...
27.747253
118
0.636436
bb887e49ea37153ace558315da76ab834b89be7f
57,283
py
Python
tests/auth_tests/test_views.py
GertBurger/django
6e9c5ee88fc948e05b4a7d9f82a8861ed2b0343d
[ "CNRI-Python-GPL-Compatible", "BSD-3-Clause" ]
2
2020-10-13T07:33:12.000Z
2021-01-29T07:10:18.000Z
tests/auth_tests/test_views.py
GertBurger/django
6e9c5ee88fc948e05b4a7d9f82a8861ed2b0343d
[ "CNRI-Python-GPL-Compatible", "BSD-3-Clause" ]
1
2020-10-30T01:00:15.000Z
2020-10-30T01:00:15.000Z
tests/auth_tests/test_views.py
GertBurger/django
6e9c5ee88fc948e05b4a7d9f82a8861ed2b0343d
[ "CNRI-Python-GPL-Compatible", "BSD-3-Clause" ]
1
2020-08-09T16:00:59.000Z
2020-08-09T16:00:59.000Z
import datetime import itertools import re from importlib import import_module from unittest import mock from urllib.parse import quote, urljoin from django.apps import apps from django.conf import settings from django.contrib.admin.models import LogEntry from django.contrib.auth import ( BACKEND_SESSION_KEY, HASH...
43.265106
119
0.654767
8ddc387558025ca9d1b7f931310cae675072bc7e
4,006
py
Python
src/vbox/cli/util/format.py
autumnjolitz/vbox
38015ee0bb2316982490172068b791762e092a85
[ "BSD-3-Clause" ]
1
2020-08-12T15:03:31.000Z
2020-08-12T15:03:31.000Z
src/vbox/cli/util/format.py
autumnjolitz/vbox
38015ee0bb2316982490172068b791762e092a85
[ "BSD-3-Clause" ]
null
null
null
src/vbox/cli/util/format.py
autumnjolitz/vbox
38015ee0bb2316982490172068b791762e092a85
[ "BSD-3-Clause" ]
null
null
null
import collections is_container = lambda el: isinstance(el, collections.Iterable) and (not isinstance(el, basestring)) class Formatter(object): """Object that formats input to command line arguments.""" def __init__(self, all, mandatory, flags=(), positional=(), onOff=...
35.140351
113
0.549176
f8de3a6ab37cc3f3ca6fcf5f497ee65164608937
9,460
py
Python
config/settings/base.py
dyjung123/rgram
56223d08b2cd46fe73842ba3b5c817cd6b4e3fe4
[ "MIT" ]
null
null
null
config/settings/base.py
dyjung123/rgram
56223d08b2cd46fe73842ba3b5c817cd6b4e3fe4
[ "MIT" ]
7
2020-06-05T17:08:40.000Z
2021-09-07T23:49:22.000Z
config/settings/base.py
dyjung123/rgram
56223d08b2cd46fe73842ba3b5c817cd6b4e3fe4
[ "MIT" ]
null
null
null
""" Base settings to build other settings files upon. """ import environ ROOT_DIR = environ.Path(__file__) - 3 # (rgram/config/settings/base.py - 3 = rgram/) APPS_DIR = ROOT_DIR.path('rgram') env = environ.Env() READ_DOT_ENV_FILE = env.bool('DJANGO_READ_DOT_ENV_FILE', default=False) if READ_DOT_ENV_FILE: # OS ...
39.090909
98
0.626533
258cb47461a6d28385fe57b65d901439363f0b9f
2,201
py
Python
tensorflow_graphics/notebooks/resources/triangulated_stripe.py
Dawars/graphics
8b3013e0188f9317aea3bc0637b6ae74b4a3e837
[ "Apache-2.0" ]
1
2019-08-10T06:45:01.000Z
2019-08-10T06:45:01.000Z
tensorflow_graphics/notebooks/resources/triangulated_stripe.py
fanghao6666/graphics
8b3013e0188f9317aea3bc0637b6ae74b4a3e837
[ "Apache-2.0" ]
null
null
null
tensorflow_graphics/notebooks/resources/triangulated_stripe.py
fanghao6666/graphics
8b3013e0188f9317aea3bc0637b6ae74b4a3e837
[ "Apache-2.0" ]
1
2019-08-09T04:28:52.000Z
2019-08-09T04:28:52.000Z
#Copyright 2018 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, so...
21.792079
74
0.446161
3cef5614572ae440f31ee0e0c4eb4d95a380fb4e
14,336
py
Python
py/selenium/webdriver/firefox/firefox_profile.py
chrsmithdemos/selenium
af0f14107393eebf4e1a3d985cc34d5cb2a58d68
[ "Apache-2.0" ]
12
2015-02-13T14:53:27.000Z
2020-03-23T07:47:39.000Z
py/selenium/webdriver/firefox/firefox_profile.py
chrsmithdemos/selenium
af0f14107393eebf4e1a3d985cc34d5cb2a58d68
[ "Apache-2.0" ]
1
2015-01-23T02:34:34.000Z
2015-01-23T02:34:34.000Z
py/selenium/webdriver/firefox/firefox_profile.py
chrsmithdemos/selenium
af0f14107393eebf4e1a3d985cc34d5cb2a58d68
[ "Apache-2.0" ]
14
2015-04-29T15:01:54.000Z
2022-03-18T14:48:29.000Z
# Copyright 2014 Software Freedom Conservancy # Copyright 2008-2011 WebDriver committers # Copyright 2008-2011 Google 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.a...
38.026525
100
0.606236
0b734fad0c1537dc1fb47eb9f132280b9f728781
2,564
py
Python
slug/slug/pdf2txt_test.py
errorzhu/casuarina
3492fbc71f66b64de65204e9b5471db84e87da1d
[ "Apache-2.0" ]
null
null
null
slug/slug/pdf2txt_test.py
errorzhu/casuarina
3492fbc71f66b64de65204e9b5471db84e87da1d
[ "Apache-2.0" ]
null
null
null
slug/slug/pdf2txt_test.py
errorzhu/casuarina
3492fbc71f66b64de65204e9b5471db84e87da1d
[ "Apache-2.0" ]
null
null
null
from pdfminer.pdfinterp import PDFResourceManager, process_pdf from pdfminer.converter import TextConverter from pdfminer.layout import LAParams from io import StringIO from io import open import os from pdfminer.pdfparser import PDFParser, PDFDocument from pdfminer.pdfinterp import PDFResourceManager, PDFPageInterpret...
29.471264
70
0.662246
4143a21bb6af1a508cfdd3a0300e3539e4b8e566
18,302
py
Python
qlutils.py
raina-wu/qltoolbox
24372ee02c3198d46631b65bca24ab003d81eab4
[ "MIT" ]
null
null
null
qlutils.py
raina-wu/qltoolbox
24372ee02c3198d46631b65bca24ab003d81eab4
[ "MIT" ]
null
null
null
qlutils.py
raina-wu/qltoolbox
24372ee02c3198d46631b65bca24ab003d81eab4
[ "MIT" ]
null
null
null
__author__ = 'wuxiaoyu' import pymel.core as pm import json import sys # if pm.pluginInfo('qualoth',loaded=True, query=True): # pass # else: # pm.loadPlugin('qualoth.so') qlTypes = ['cloth', 'collision'] mapAttrs = {} mapAttrs['cloth'] = [ 'airDragMap', 'bendM...
33.520147
85
0.584308
00514021e94a2ec443830fedcd0f37e871437581
241
py
Python
Chapter_2/End_of_chapter_2/2_6.py
charliealpha094/Introduction-to-Python-Programming-for-Business-and-Social-Sciences-Applications
52c4612b0d80da3311411bc7aee1d98f75de3d95
[ "MIT" ]
null
null
null
Chapter_2/End_of_chapter_2/2_6.py
charliealpha094/Introduction-to-Python-Programming-for-Business-and-Social-Sciences-Applications
52c4612b0d80da3311411bc7aee1d98f75de3d95
[ "MIT" ]
null
null
null
Chapter_2/End_of_chapter_2/2_6.py
charliealpha094/Introduction-to-Python-Programming-for-Business-and-Social-Sciences-Applications
52c4612b0d80da3311411bc7aee1d98f75de3d95
[ "MIT" ]
null
null
null
# Done by Carlos Amaral (2020/09/17) weight = input("Please, enter a weight in pounds: ") def convert(weight): return (float(weight)*0.453592) print("You've entered: ", weight, "\n", "Conversion to kg is equal to: ", convert(weight))
26.777778
90
0.676349
835e0f9394c68640448597875d7e1465dc2f66c1
6,384
py
Python
mxs_video_sorter/config.py
Scheercuzy/mxs_video_sorter
84a36eaf4c416ff8f632df5184336307f52f2cdd
[ "MIT" ]
2
2018-10-12T13:29:45.000Z
2020-01-24T05:42:36.000Z
mxs_video_sorter/config.py
Scheercuzy/mxs_video_sorter
84a36eaf4c416ff8f632df5184336307f52f2cdd
[ "MIT" ]
null
null
null
mxs_video_sorter/config.py
Scheercuzy/mxs_video_sorter
84a36eaf4c416ff8f632df5184336307f52f2cdd
[ "MIT" ]
null
null
null
import yaml import os import logging import re import subprocess import shutil import configparser from collections import OrderedDict logger = logging.getLogger('main') CONFTEMPLATE = os.path.join(os.path.dirname(__file__), 'conf_template') class ConfigManager: """A controller to access all the configs from the c...
35.664804
87
0.709117
bcfa8607964b06a308094bd655322c9699edbd36
162
py
Python
flask_oauthlib/contrib/__init__.py
mdxs/flask-oauthlib
21f5c3e73a023d399890d91d84f69c4ac0ea284b
[ "BSD-3-Clause" ]
null
null
null
flask_oauthlib/contrib/__init__.py
mdxs/flask-oauthlib
21f5c3e73a023d399890d91d84f69c4ac0ea284b
[ "BSD-3-Clause" ]
null
null
null
flask_oauthlib/contrib/__init__.py
mdxs/flask-oauthlib
21f5c3e73a023d399890d91d84f69c4ac0ea284b
[ "BSD-3-Clause" ]
null
null
null
# coding: utf-8 """ flask_oauthlib.contrib ~~~~~~~~~~~~~~~~~~~~~~ Contributions for Flask OAuthlib. :copyright: (c) 2013 by Hsiaoming Yang. """
16.2
43
0.549383
8b74bba3476011dcfd04743e70559d83b23ac547
1,284
py
Python
thrift/lib/py3/test/mixin/mixin.py
dgrnbrg-meta/fbthrift
1d5f0799ef53feeb83425b6c9c79f86aeac7d9ed
[ "Apache-2.0" ]
null
null
null
thrift/lib/py3/test/mixin/mixin.py
dgrnbrg-meta/fbthrift
1d5f0799ef53feeb83425b6c9c79f86aeac7d9ed
[ "Apache-2.0" ]
1
2022-03-03T09:40:25.000Z
2022-03-03T09:40:25.000Z
thrift/lib/py3/test/mixin/mixin.py
dgrnbrg-meta/fbthrift
1d5f0799ef53feeb83425b6c9c79f86aeac7d9ed
[ "Apache-2.0" ]
null
null
null
# Copyright (c) Meta Platforms, Inc. and affiliates. # # 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 o...
30.571429
74
0.609034
9be245c25e1fe75dd49457b72d97cf6383004496
1,032
py
Python
test/test_util_awe.py
starcraftman/new-awesome
59f779e2aa0b1aab2eca2aaf351f789f2833c4a9
[ "BSD-3-Clause" ]
6
2016-03-09T04:17:42.000Z
2020-03-02T18:46:28.000Z
test/test_util_awe.py
starcraftman/new-awesome
59f779e2aa0b1aab2eca2aaf351f789f2833c4a9
[ "BSD-3-Clause" ]
null
null
null
test/test_util_awe.py
starcraftman/new-awesome
59f779e2aa0b1aab2eca2aaf351f789f2833c4a9
[ "BSD-3-Clause" ]
null
null
null
# pylint: disable=missing-docstring """ Test the util.awe.py utility script. """ from __future__ import absolute_import, print_function import os import tempfile import mock import util import util.awe import test.common as tc @mock.patch('util.ROOT', tempfile.mkdtemp()) def test_parse_clean_all(mock_print): tr...
27.891892
75
0.596899
23c339b4b167a0bd6171acba02ebe1e82efdbac6
1,075
py
Python
lotus/wallet/derive_keys.py
Pamenarti/lotus-blockchain1
53b75a2fa5d6330a26f31ad03be0c7159124c728
[ "Apache-2.0" ]
11
2021-06-25T02:50:23.000Z
2021-11-14T17:42:58.000Z
lotus/wallet/derive_keys.py
Pamenarti/lotus-blockchain1
53b75a2fa5d6330a26f31ad03be0c7159124c728
[ "Apache-2.0" ]
6
2021-06-23T15:12:48.000Z
2022-01-10T23:12:36.000Z
lotus/wallet/derive_keys.py
Pamenarti/lotus-blockchain1
53b75a2fa5d6330a26f31ad03be0c7159124c728
[ "Apache-2.0" ]
1
2021-06-30T16:14:54.000Z
2021-06-30T16:14:54.000Z
from typing import List from blspy import AugSchemeMPL, PrivateKey from lotus.util.ints import uint32 # EIP 2334 bls key derivation # https://eips.ethereum.org/EIPS/eip-2334 # 12381 = bls spec number # 8444 = lotus blockchain number and port number # 0, 1, 2, 3, 4, farmer, pool, wallet, local, backup key numbers d...
28.289474
76
0.731163
55c12bc2a37fcd40e978c5834a410f4f2b80094b
2,960
py
Python
SmartDeal-Training/se/linear_mask.py
VITA-Group/SmartDeal
8e1de77497eedbeea412a8c51142834c28a53709
[ "MIT" ]
2
2021-07-20T02:48:35.000Z
2021-11-29T02:55:36.000Z
SmartDeal-Training/se/linear_mask.py
VITA-Group/SmartDeal
8e1de77497eedbeea412a8c51142834c28a53709
[ "MIT" ]
null
null
null
SmartDeal-Training/se/linear_mask.py
VITA-Group/SmartDeal
8e1de77497eedbeea412a8c51142834c28a53709
[ "MIT" ]
null
null
null
''' # @ Author: Xiaohan Chen # @ Email: chernxh@tamu.edu # @ Create Time: 2019-07-11 01:35:15 # @ Modified by: Xiaohan Chen # @ Modified time: 2019-07-11 01:36:19 # @ Description: ''' import math import torch import torch.nn as nn import torch.nn.functional as F import torch.nn.init as init from utils_quantize...
33.636364
87
0.618581
6e186862ebbd37e3d27cebeadcc0785eae150dfb
27,158
py
Python
transformations/insert_abbreviation/grammaire.py
ZhexiongLiu/NL-Augmenter
fd9b699fc75824db942bdf485f49dc5c31bf60dc
[ "MIT" ]
583
2021-06-12T02:30:26.000Z
2022-03-28T05:57:45.000Z
transformations/insert_abbreviation/grammaire.py
ZhexiongLiu/NL-Augmenter
fd9b699fc75824db942bdf485f49dc5c31bf60dc
[ "MIT" ]
246
2021-06-11T15:49:36.000Z
2022-02-02T12:17:41.000Z
transformations/insert_abbreviation/grammaire.py
ZhexiongLiu/NL-Augmenter
fd9b699fc75824db942bdf485f49dc5c31bf60dc
[ "MIT" ]
189
2021-06-15T14:14:15.000Z
2022-03-15T22:10:46.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Grammaire Copyright 2021-present NAVER Corp. Created on Wed Jul 21 10:40:14 2021 @author: claude.roux@naverlabs.com @author: caroline.brun@naverlabs.com """ import re # import tokenize # from io import BytesIO # -----------------------------------------------------...
31.5058
124
0.475735
7913171649e32bf9449ed2ce98834c27c21c51b0
3,478
py
Python
plugins/Factoids/config.py
Supybot/Supybot
8d16953e1dcbb455ec75bc30c9950e64879a8d8a
[ "BSD-3-Clause" ]
40
2015-01-28T22:16:36.000Z
2021-12-15T02:22:56.000Z
plugins/Factoids/config.py
DalavanCloud/supybot
159c1e7cd886cb5f8c68d1ba703b1d302a716e5d
[ "BSD-3-Clause" ]
17
2015-01-05T21:06:22.000Z
2015-12-07T20:45:44.000Z
plugins/Factoids/config.py
DalavanCloud/supybot
159c1e7cd886cb5f8c68d1ba703b1d302a716e5d
[ "BSD-3-Clause" ]
28
2015-01-03T23:53:58.000Z
2021-06-01T05:27:20.000Z
### # Copyright (c) 2002-2005, Jeremiah Fincher # Copyright (c) 2009, James McCoy # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # # * Redistributions of source code must retain the above copyr...
51.147059
79
0.757332
49881a03b11a0638bc293766738e036c0f55673f
3,348
py
Python
vision/ssd/mobilenetv1_ssd_lite.py
idenc/SSD-translate
6cf8c83b42d6d47282d98822b90491264288d6f1
[ "MIT" ]
2
2020-03-17T02:49:26.000Z
2020-05-21T04:10:12.000Z
vision/ssd/mobilenetv1_ssd_lite.py
idenc/SSD-translate
6cf8c83b42d6d47282d98822b90491264288d6f1
[ "MIT" ]
2
2021-08-25T15:47:57.000Z
2022-02-10T00:31:17.000Z
vision/ssd/mobilenetv1_ssd_lite.py
idenc/SSD-translate
6cf8c83b42d6d47282d98822b90491264288d6f1
[ "MIT" ]
1
2020-05-21T04:10:13.000Z
2020-05-21T04:10:13.000Z
from tensorflow.python.keras.layers import Conv2D, SeparableConv2D from vision.nn.mobilenet import MobileNet from .config import mobilenetv1_ssd_config as config from .predictor import Predictor from .ssd import SSD def create_mobilenetv1_ssd_lite(num_classes, is_test=False, is_train=False): base_net = MobileNet...
46.5
98
0.631123
52391e005ff0364d56cb9def5f40d299ea8681e7
1,281
py
Python
services/file_system/project/__init__.py
geraldomacias/MarkLogic
996c48a970a24aa7e5af4752fe9c12b63d4834fe
[ "BSD-2-Clause" ]
5
2018-12-03T18:08:34.000Z
2019-03-13T05:59:07.000Z
services/file_system/project/__init__.py
geraldomacias/MarkLogic
996c48a970a24aa7e5af4752fe9c12b63d4834fe
[ "BSD-2-Clause" ]
7
2018-12-03T23:11:14.000Z
2019-06-06T06:00:39.000Z
services/file_system/project/__init__.py
geraldomacias/MarkLogic
996c48a970a24aa7e5af4752fe9c12b63d4834fe
[ "BSD-2-Clause" ]
1
2019-04-11T16:34:55.000Z
2019-04-11T16:34:55.000Z
""" Copyright 2019 Team Mark 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 dist...
24.169811
72
0.733802
a34553ea94b569628df99bdb93da9782acc32861
63,984
py
Python
apero/core/instruments/nirps_ha/recipe_definitions.py
njcuk9999/apero-drs
83b043e9f277a011b03e0227c77307961b200901
[ "MIT" ]
1
2021-03-09T17:49:31.000Z
2021-03-09T17:49:31.000Z
apero/core/instruments/nirps_ha/recipe_definitions.py
njcuk9999/apero-drs
83b043e9f277a011b03e0227c77307961b200901
[ "MIT" ]
43
2020-10-06T18:42:24.000Z
2022-03-28T21:23:10.000Z
apero/core/instruments/nirps_ha/recipe_definitions.py
njcuk9999/apero-drs
83b043e9f277a011b03e0227c77307961b200901
[ "MIT" ]
null
null
null
from apero.core import constants from apero.core.core import drs_recipe from apero import lang from apero.core.instruments.nirps_ha import file_definitions as sf # ============================================================================= # Define variables # ========================================================...
46.669584
82
0.589397
088da1ef877e53fca9b2b8587824eba3b3c2dbab
7,224
py
Python
fhir/resources/DSTU2/order.py
cstoltze/fhir.resources
52f99738935b7313089d89daf94d73ce7d167c9d
[ "BSD-3-Clause" ]
144
2019-05-08T14:24:43.000Z
2022-03-30T02:37:11.000Z
fhir/resources/DSTU2/order.py
cstoltze/fhir.resources
52f99738935b7313089d89daf94d73ce7d167c9d
[ "BSD-3-Clause" ]
82
2019-05-13T17:43:13.000Z
2022-03-30T16:45:17.000Z
fhir/resources/DSTU2/order.py
cstoltze/fhir.resources
52f99738935b7313089d89daf94d73ce7d167c9d
[ "BSD-3-Clause" ]
48
2019-04-04T14:14:53.000Z
2022-03-30T06:07:31.000Z
# -*- coding: utf-8 -*- """ Profile: None Release: DSTU2 Version: 1.0.2 Revision: None """ from typing import Any, Dict from typing import List as ListType from pydantic import Field, root_validator from . import fhirtypes from .backboneelement import BackboneElement from .domainresource import DomainResource class...
35.940299
92
0.631091
580b61b770fb9d4494bba0c452adcd5bcc702e05
4,216
py
Python
refinery/units/formats/pe/dotnet/dncfx.py
larsborn/refinery
c8b19156b17e5fa5de5c72bc668a14d646584560
[ "BSD-3-Clause" ]
null
null
null
refinery/units/formats/pe/dotnet/dncfx.py
larsborn/refinery
c8b19156b17e5fa5de5c72bc668a14d646584560
[ "BSD-3-Clause" ]
null
null
null
refinery/units/formats/pe/dotnet/dncfx.py
larsborn/refinery
c8b19156b17e5fa5de5c72bc668a14d646584560
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- import struct import re from Crypto.Util.strxor import strxor from ... import Unit from .....lib import chunks from .....lib.dotnet.header import DotNetHeader, StreamReader, StringPrimitive, UInt32, ParserEOF from ....compression.lz import lzma class dncfx(Unit): "...
38.327273
111
0.518501
de69d93a9564b542d7461deab557ff24471f1102
861
py
Python
setup.py
dantin/chess-game
24037f1f10274f2112ad46d0a572ee130607881c
[ "BSD-3-Clause" ]
1
2019-10-22T02:50:42.000Z
2019-10-22T02:50:42.000Z
setup.py
dantin/chess-game
24037f1f10274f2112ad46d0a572ee130607881c
[ "BSD-3-Clause" ]
null
null
null
setup.py
dantin/chess-game
24037f1f10274f2112ad46d0a572ee130607881c
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- """Setup Scripts.""" import io import re from setuptools import setup, find_packages with io.open('README.md', 'rt', encoding='utf8') as f: README = f.read() with io.open('chess/__init__.py', 'rt', encoding='utf8') as f: VERSION = re.search(r'__version__ = \'(.*?)\'', f.read()).grou...
27.774194
94
0.646922
76305f478449fcc772114a22502a0128d02f9818
2,735
py
Python
codelighthouse/CodeLighthouseWebHandler.py
CodeLighthouse/sdk-python
2725f961c377d3d289e3e6c88186ce1629335944
[ "MIT" ]
3
2020-11-11T22:23:36.000Z
2020-11-23T02:02:00.000Z
codelighthouse/CodeLighthouseWebHandler.py
CodeLighthouse/sdk-python
2725f961c377d3d289e3e6c88186ce1629335944
[ "MIT" ]
7
2020-10-24T18:22:24.000Z
2020-12-30T19:30:44.000Z
codelighthouse/CodeLighthouseWebHandler.py
CodeLighthouse/sdk-python
2725f961c377d3d289e3e6c88186ce1629335944
[ "MIT" ]
null
null
null
import requests import json class CodeLighthouseWebHandler: BASE_URL = "http://localhost:5000" version = "v1" organization_name = "\"" x_api_key = "\"" DEBUG = False def send_error(self, *args, **kwargs): headers = { "x-api-key": self.x_api_key, "Content-Type":...
40.820896
119
0.578428
627d493dcc81bbb502a8f026dac0b19c0383e43b
854
py
Python
isi_sdk_7_2/test/test_copy_errors.py
mohitjain97/isilon_sdk_python
a371f438f542568edb8cda35e929e6b300b1177c
[ "Unlicense" ]
24
2018-06-22T14:13:23.000Z
2022-03-23T01:21:26.000Z
isi_sdk_7_2/test/test_copy_errors.py
mohitjain97/isilon_sdk_python
a371f438f542568edb8cda35e929e6b300b1177c
[ "Unlicense" ]
46
2018-04-30T13:28:22.000Z
2022-03-21T21:11:07.000Z
isi_sdk_7_2/test/test_copy_errors.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: 2 Contact: sdk@isilon.com Generated by: https://github.com/swagger-api/swagger-codegen.git """ from __future__ import absolute_import import unittest import isi_sdk_7_2 from isi...
20.829268
79
0.688525
67a396cbbf050005cd27d34aa2f063d16e025f01
2,483
py
Python
locations/spiders/goldsgym.py
mfjackson/alltheplaces
37c90b4041c80a574e6e4c2f886883e97df4b636
[ "MIT" ]
null
null
null
locations/spiders/goldsgym.py
mfjackson/alltheplaces
37c90b4041c80a574e6e4c2f886883e97df4b636
[ "MIT" ]
null
null
null
locations/spiders/goldsgym.py
mfjackson/alltheplaces
37c90b4041c80a574e6e4c2f886883e97df4b636
[ "MIT" ]
null
null
null
import json import re from urllib.parse import urlparse import scrapy from scrapy.selector import Selector from locations.items import GeojsonPointItem from locations.hours import OpeningHours class GoldsGymSpider(scrapy.Spider): name = "goldsgym" item_attributes = {"brand": "Gold's Gym"} allowed_domains...
32.246753
83
0.54853
d4f4db8e67036e1b157bc608f05d7b18ad12ff82
106
py
Python
config.py
hank9999/QQBot
a28ec55218dd5cee11ef17376a0c79991e87d1aa
[ "MIT" ]
1
2021-01-29T23:14:56.000Z
2021-01-29T23:14:56.000Z
config.py
hank9999/QQBot
a28ec55218dd5cee11ef17376a0c79991e87d1aa
[ "MIT" ]
null
null
null
config.py
hank9999/QQBot
a28ec55218dd5cee11ef17376a0c79991e87d1aa
[ "MIT" ]
null
null
null
from nonebot.default_config import * SUPERUSERS = {} HOST = '127.0.0.1' PORT = 8080 COMMAND_START = {'#'}
17.666667
36
0.679245
bd14663d6ea9fac4a89df2bdbfc56f610897f715
4,117
py
Python
tests/sim_list_test.py
mkeilman/sirepo
29ac632f688b019c95d69191a84848f263433dd7
[ "Apache-2.0" ]
49
2015-07-29T14:11:29.000Z
2021-12-10T15:24:26.000Z
tests/sim_list_test.py
mkeilman/sirepo
29ac632f688b019c95d69191a84848f263433dd7
[ "Apache-2.0" ]
3,732
2015-08-03T22:07:26.000Z
2022-03-31T22:48:33.000Z
tests/sim_list_test.py
mkeilman/sirepo
29ac632f688b019c95d69191a84848f263433dd7
[ "Apache-2.0" ]
28
2015-11-20T16:23:46.000Z
2021-09-20T07:22:48.000Z
# -*- coding: utf-8 -*- u"""test simulation list :copyright: Copyright (c) 2019 RadiaSoft LLC. All Rights Reserved. :license: http://www.apache.org/licenses/LICENSE-2.0.html """ from __future__ import absolute_import, division, print_function import pytest def test_copy_non_session(fc): from pykern.pkcollections...
27.817568
75
0.588778
2f70dea0115ef87a4a7b4215743e9f093f69a468
2,554
py
Python
networkx/generators/triads.py
theaverageguy/networkx
b2b74b3ba028ef3788f796aa64b037c8ea446539
[ "BSD-3-Clause" ]
null
null
null
networkx/generators/triads.py
theaverageguy/networkx
b2b74b3ba028ef3788f796aa64b037c8ea446539
[ "BSD-3-Clause" ]
null
null
null
networkx/generators/triads.py
theaverageguy/networkx
b2b74b3ba028ef3788f796aa64b037c8ea446539
[ "BSD-3-Clause" ]
1
2020-09-11T06:41:14.000Z
2020-09-11T06:41:14.000Z
# triads.py - generators for triad graphs # # Copyright 2015 NetworkX developers. # Copyright 2011 Reya Group <http://www.reyagroup.com> # Copyright 2011 Alex Levenson <alex@isnotinvain.com> # Copyright 2011 Diederik van Liere <diederik.vanliere@rotman.utoronto.ca> # # This file is part of NetworkX. # # NetworkX is dis...
31.146341
78
0.528974
89187138d06cbfe1daa89ce6571e58b890cb7858
2,468
py
Python
benchmark/framework/fake_connection.py
valory-xyz/agents-aea
8f38efa96041b0156ed1ae328178e395dbabf2fc
[ "Apache-2.0" ]
126
2019-09-07T09:32:44.000Z
2022-03-29T14:28:41.000Z
benchmark/framework/fake_connection.py
valory-xyz/agents-aea
8f38efa96041b0156ed1ae328178e395dbabf2fc
[ "Apache-2.0" ]
1,814
2019-08-24T10:08:07.000Z
2022-03-31T14:28:36.000Z
benchmark/framework/fake_connection.py
valory-xyz/agents-aea
8f38efa96041b0156ed1ae328178e395dbabf2fc
[ "Apache-2.0" ]
46
2019-09-03T22:13:58.000Z
2022-03-22T01:25:16.000Z
# -*- coding: utf-8 -*- # ------------------------------------------------------------------------------ # # Copyright 2018-2019 Fetch.AI Limited # # 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 ...
33.351351
85
0.60778
2906af39f6e3b66f14914ac0ae0656bf87d8a8ff
1,120
py
Python
utils.py
etetteh/OoD_Gen-Chest_Xray
dfd78a951f457a87bc9a3196e5efaeec1061dfa2
[ "MIT" ]
null
null
null
utils.py
etetteh/OoD_Gen-Chest_Xray
dfd78a951f457a87bc9a3196e5efaeec1061dfa2
[ "MIT" ]
null
null
null
utils.py
etetteh/OoD_Gen-Chest_Xray
dfd78a951f457a87bc9a3196e5efaeec1061dfa2
[ "MIT" ]
1
2021-12-28T05:36:59.000Z
2021-12-28T05:36:59.000Z
import os import csv def write_results(filename: str, field_names: list, results: dict): read_file = open(filename, "r") results_file = csv.DictReader(read_file) update = [] new = [] row = {} for r in results_file: if r['Model'] == results['Model']: for key, value in results...
29.473684
81
0.570536
8f8dd460b748feeca14dc2098ff807e632fd76b8
13,243
py
Python
tools/ci.py
adiang01/SCP-firmware
fed55f27cee86eb0d6199aaaf89480d89e8b5ffa
[ "BSD-3-Clause" ]
null
null
null
tools/ci.py
adiang01/SCP-firmware
fed55f27cee86eb0d6199aaaf89480d89e8b5ffa
[ "BSD-3-Clause" ]
null
null
null
tools/ci.py
adiang01/SCP-firmware
fed55f27cee86eb0d6199aaaf89480d89e8b5ffa
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python3 # # Arm SCP/MCP Software # Copyright (c) 2015-2021, Arm Limited and Contributors. All rights reserved. # # SPDX-License-Identifier: BSD-3-Clause # import check_copyright import check_doc import check_spacing import check_tabs import subprocess import sys def banner(text): columns = 80 ...
27.88
77
0.567319
46398b087314e0799b0b730abfe8c88ac5070c25
11,964
py
Python
catalyst/utils/tradingcalendar.py
izokay/catalyst
db312be6543cd00f7f4f3ff6dc9072d29f6e7d97
[ "Apache-2.0" ]
6
2019-05-23T17:52:22.000Z
2022-01-30T08:13:19.000Z
catalyst/utils/tradingcalendar.py
Donstesh/catalyst
83e2e2b23c0266bde1c11e68a6acde7460c6eadf
[ "Apache-2.0" ]
null
null
null
catalyst/utils/tradingcalendar.py
Donstesh/catalyst
83e2e2b23c0266bde1c11e68a6acde7460c6eadf
[ "Apache-2.0" ]
1
2019-10-29T04:33:15.000Z
2019-10-29T04:33:15.000Z
# # Copyright 2013 Quantopian, 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 wr...
27.888112
103
0.63875
520a02966c9330a202ca90dbd845db30c406520d
973
py
Python
test/test_code_page_data_item.py
NVE/python-varsom-landslide-client
553f562d463e67545daa9fc9bfdd554f3c5d471c
[ "MIT" ]
null
null
null
test/test_code_page_data_item.py
NVE/python-varsom-landslide-client
553f562d463e67545daa9fc9bfdd554f3c5d471c
[ "MIT" ]
null
null
null
test/test_code_page_data_item.py
NVE/python-varsom-landslide-client
553f562d463e67545daa9fc9bfdd554f3c5d471c
[ "MIT" ]
null
null
null
# coding: utf-8 """ Jordskredvarsel API No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) # noqa: E501 OpenAPI spec version: v1.0.6 Generated by: https://github.com/swagger-api/swagger-codegen.git """ from __future__ import absolute_import i...
24.325
119
0.722508
99045f5f20f0dc40ad577ef3f0f452a158b6b517
8,446
py
Python
extra/parallax_svg_tools/example/parallax_svg_tools/svg/__init__.py
rlaneyjr/project_pawz
27f316ef35968ed1319ec0585a050ebed795763a
[ "MIT" ]
323
2017-08-03T11:24:24.000Z
2022-03-13T20:46:14.000Z
example/parallax_svg_tools/svg/__init__.py
parallax/svg-animation-tools
3cbad1696760c049ed66b7e0c8631357000dbdb6
[ "MIT" ]
13
2020-02-12T00:12:52.000Z
2022-02-12T09:42:36.000Z
extra/parallax_svg_tools/example/parallax_svg_tools/svg/__init__.py
rlaneyjr/project_pawz2
46c0914bbcdb9f694bb3e884b1e1516b1ea723e3
[ "MIT" ]
32
2017-08-07T03:12:41.000Z
2020-11-26T18:14:04.000Z
# Super simple Illustrator SVG processor for animations. Uses the BeautifulSoup python xml library. import os import errno from bs4 import BeautifulSoup def create_file(path, mode): directory = os.path.dirname(path) if directory != '' and not os.path.exists(directory): try: os.makedirs(directory) except OSE...
28.342282
124
0.687189
cc7d487e3c9f354bc2119abf229c6ef258ba6b54
11,424
py
Python
louie_experiments/permutation_testing.py
SIGKDD2021ANON/PaperCodeBandits
bf1c3a6cf2de2dc81228bedb97c5aa3657cebebd
[ "Apache-2.0" ]
null
null
null
louie_experiments/permutation_testing.py
SIGKDD2021ANON/PaperCodeBandits
bf1c3a6cf2de2dc81228bedb97c5aa3657cebebd
[ "Apache-2.0" ]
null
null
null
louie_experiments/permutation_testing.py
SIGKDD2021ANON/PaperCodeBandits
bf1c3a6cf2de2dc81228bedb97c5aa3657cebebd
[ "Apache-2.0" ]
null
null
null
''' Created on Aug 10, 2018 @author: rafferty ''' import sys import csv import beta_bernoulli import ng_normal import numpy as np from output_format import H_ALGO_OBSERVED_REWARD, H_ALGO_ACTION import pandas as pd import read_config import run_effect_size_simulations_beta import run_effect_size_simulations from read_c...
48
175
0.651786
feac4985b18ce91287855b2bad853dc2d448fc7a
1,365
py
Python
aliyun-python-sdk-devops-rdc/aliyunsdkdevops_rdc/request/v20200303/DeleteDevopsProjectSprintRequest.py
yndu13/aliyun-openapi-python-sdk
12ace4fb39fe2fb0e3927a4b1b43ee4872da43f5
[ "Apache-2.0" ]
1,001
2015-07-24T01:32:41.000Z
2022-03-25T01:28:18.000Z
aliyun-python-sdk-devops-rdc/aliyunsdkdevops_rdc/request/v20200303/DeleteDevopsProjectSprintRequest.py
yndu13/aliyun-openapi-python-sdk
12ace4fb39fe2fb0e3927a4b1b43ee4872da43f5
[ "Apache-2.0" ]
363
2015-10-20T03:15:00.000Z
2022-03-08T12:26:19.000Z
aliyun-python-sdk-devops-rdc/aliyunsdkdevops_rdc/request/v20200303/DeleteDevopsProjectSprintRequest.py
yndu13/aliyun-openapi-python-sdk
12ace4fb39fe2fb0e3927a4b1b43ee4872da43f5
[ "Apache-2.0" ]
682
2015-09-22T07:19:02.000Z
2022-03-22T09:51:46.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.921053
85
0.755311
794d5c0b4f0b2473663fe6db3537edf561e9352a
1,905
py
Python
DM900-USB-ArduinoNano/DM900-Enigmalight-Service/home/elight-addons/wifilight/philips_hue/enigmalight_hue_LR.py
NeedfulThings/hyperionconfigs
1428d62b0d0d59bd062309870481d1b360e625e1
[ "MIT" ]
null
null
null
DM900-USB-ArduinoNano/DM900-Enigmalight-Service/home/elight-addons/wifilight/philips_hue/enigmalight_hue_LR.py
NeedfulThings/hyperionconfigs
1428d62b0d0d59bd062309870481d1b360e625e1
[ "MIT" ]
null
null
null
DM900-USB-ArduinoNano/DM900-Enigmalight-Service/home/elight-addons/wifilight/philips_hue/enigmalight_hue_LR.py
NeedfulThings/hyperionconfigs
1428d62b0d0d59bd062309870481d1b360e625e1
[ "MIT" ]
2
2019-10-12T17:14:13.000Z
2019-10-20T14:59:41.000Z
import sys import os import time import json import httplib from rgb_xy import Converter from rgb_xy import GamutC # or GamutA, GamutB (you must look for the type of your lamps in rgb_xy.py from line 42) counter = 12 def popen(): converter = Converter(GamutC) spidev = file( os.getcwd()+'/aufruf.log', "wb") ...
24.74026
124
0.648294
74d523a569811e8d5709c239dbd68cb2f54119f8
8,775
py
Python
slippi_ai/networks.py
supersteph/slippi-ai
97e0845789e95c1511295bad626a514fff46ce74
[ "MIT" ]
12
2020-11-11T06:39:23.000Z
2022-02-26T04:55:31.000Z
slippi_ai/networks.py
supersteph/slippi-ai
97e0845789e95c1511295bad626a514fff46ce74
[ "MIT" ]
5
2020-11-26T18:17:17.000Z
2022-02-07T16:48:34.000Z
slippi_ai/networks.py
supersteph/slippi-ai
97e0845789e95c1511295bad626a514fff46ce74
[ "MIT" ]
9
2020-11-15T18:24:47.000Z
2022-01-15T18:00:18.000Z
from typing import Any, Tuple import sonnet as snt import tensorflow as tf from slippi_ai import embed, utils, data RecurrentState = Any Inputs = Tuple[data.Game, tf.Tensor] # don't use opponent's controller # our own will be exposed in the input embed_game = embed.make_game_embedding( player_config=dict(with_c...
27.59434
90
0.69265
3cfabeb3dfe1ae78a0303b691c3b0cb79cb7f819
7,107
py
Python
internationalflavor/timezone/data.py
an42rus/django-internationalflavor
0d560d3e3dfb4d6fb54bf22e8eab07796180e29e
[ "BSD-3-Clause" ]
null
null
null
internationalflavor/timezone/data.py
an42rus/django-internationalflavor
0d560d3e3dfb4d6fb54bf22e8eab07796180e29e
[ "BSD-3-Clause" ]
null
null
null
internationalflavor/timezone/data.py
an42rus/django-internationalflavor
0d560d3e3dfb4d6fb54bf22e8eab07796180e29e
[ "BSD-3-Clause" ]
null
null
null
from __future__ import absolute_import, division import six import datetime from django.core.exceptions import ImproperlyConfigured from django.utils.encoding import force_text from django.utils.functional import lazy from django.utils.translation import ugettext_lazy as _, ugettext import itertools from internationa...
40.844828
118
0.701843
d5cd9fab9a3ca9cde1e6a2099b8d21a8ff3a51e5
2,439
py
Python
Oem/jsoncpp/scons-local-0.97/SCons/Tool/tar.py
achilex/MgDev
f7baf680a88d37659af32ee72b9a2046910b00d8
[ "PHP-3.0" ]
2
2017-04-19T01:38:30.000Z
2020-07-31T03:05:32.000Z
Oem/jsoncpp/scons-local-0.97/SCons/Tool/tar.py
achilex/MgDev
f7baf680a88d37659af32ee72b9a2046910b00d8
[ "PHP-3.0" ]
null
null
null
Oem/jsoncpp/scons-local-0.97/SCons/Tool/tar.py
achilex/MgDev
f7baf680a88d37659af32ee72b9a2046910b00d8
[ "PHP-3.0" ]
1
2021-12-29T10:46:12.000Z
2021-12-29T10:46:12.000Z
"""SCons.Tool.tar Tool-specific initialization for tar. There normally shouldn't be any need to import this module directly. It will usually be imported through the generic SCons.Tool.Tool() selection method. """ # # Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007 The SCons Foundation # # Permission is hereb...
35.867647
118
0.687167
80d1a68ae5912dde75f4f051853b89b22231a916
11,098
py
Python
packages/Python/lldbsuite/test/dotest_args.py
xiaobai/swift-lldb
9238527ce430e6837108a16d2a91b147551fb83c
[ "Apache-2.0" ]
765
2015-12-03T16:44:59.000Z
2022-03-07T12:41:10.000Z
packages/Python/lldbsuite/test/dotest_args.py
xiaobai/swift-lldb
9238527ce430e6837108a16d2a91b147551fb83c
[ "Apache-2.0" ]
1,815
2015-12-11T23:56:05.000Z
2020-01-10T19:28:43.000Z
packages/Python/lldbsuite/test/dotest_args.py
xiaobai/swift-lldb
9238527ce430e6837108a16d2a91b147551fb83c
[ "Apache-2.0" ]
284
2015-12-03T16:47:25.000Z
2022-03-12T05:39:48.000Z
from __future__ import print_function from __future__ import absolute_import # System modules import argparse import sys import os import textwrap # LLDB modules from . import configuration def create_parser(): parser = argparse.ArgumentParser( description='description', prefix_chars='+-', ...
43.521569
213
0.648856
e6f6ec1f24a6d54e818b2c41b7e78c7e0fa2c6e5
2,808
py
Python
bin/pylama/pytest.py
ShadowLNC/linter-pylama
86e6960455f46c099bfd500c859e40c6bd3f9f7e
[ "MIT" ]
463
2015-01-15T08:17:42.000Z
2022-03-28T15:10:20.000Z
bin/pylama/pytest.py
ShadowLNC/linter-pylama
86e6960455f46c099bfd500c859e40c6bd3f9f7e
[ "MIT" ]
93
2015-01-02T12:35:32.000Z
2021-12-12T22:42:33.000Z
bin/pylama/pytest.py
ShadowLNC/linter-pylama
86e6960455f46c099bfd500c859e40c6bd3f9f7e
[ "MIT" ]
249
2015-01-07T22:49:49.000Z
2022-03-18T02:32:06.000Z
""" py.test plugin for checking files with pylama. """ from __future__ import absolute_import from os import path as op import py # noqa import pytest HISTKEY = "pylama/mtimes" def pytest_load_initial_conftests(early_config, parser, args): # Marks have to be registered before usage # to not fail with --st...
29.25
76
0.667735
e66531748e456111fd30421d5dd0b9f6697c6b4f
615
py
Python
setup.py
square/reqpi
0eef3e615607b618a3017217474083d15690beeb
[ "Apache-2.0" ]
3
2016-04-23T11:10:31.000Z
2019-06-17T19:47:12.000Z
setup.py
square/reqpi
0eef3e615607b618a3017217474083d15690beeb
[ "Apache-2.0" ]
null
null
null
setup.py
square/reqpi
0eef3e615607b618a3017217474083d15690beeb
[ "Apache-2.0" ]
3
2016-04-05T05:42:41.000Z
2020-11-14T17:53:37.000Z
# Copyright (c) Square, Inc. # See LICENSE for details. import setuptools import versioneer with open('README.rst') as fp: long_description = fp.read() setuptools.setup( url='https://github.com/square/reqpi', packages=setuptools.find_packages() + ['twisted.plugins'], install_requires=['mainland', 'Tw...
26.73913
62
0.708943
5bc2af272d3b82e5d186722ff67e25e462bcea64
485
py
Python
examples/linux64/hello/rundbg.py
rakati/ppci-mirror
8f5b0282fd1122d7c389b39c86fcf5d9352b7bb2
[ "BSD-2-Clause" ]
161
2020-05-31T03:29:42.000Z
2022-03-07T08:36:19.000Z
examples/linux64/hello/rundbg.py
rakati/ppci-mirror
8f5b0282fd1122d7c389b39c86fcf5d9352b7bb2
[ "BSD-2-Clause" ]
74
2020-05-26T18:05:48.000Z
2021-02-13T21:55:39.000Z
examples/linux64/hello/rundbg.py
rakati/ppci-mirror
8f5b0282fd1122d7c389b39c86fcf5d9352b7bb2
[ "BSD-2-Clause" ]
19
2020-05-27T19:22:11.000Z
2022-02-17T18:53:52.000Z
#!/usr/bin/python from ppci import api from ppci.binutils.dbg import Debugger from ppci.binutils.dbg.ptcli import PtDebugCli from ppci.binutils.dbg.linux64debugdriver import Linux64DebugDriver if __name__ == '__main__': dut = 'hello' obj = 'hello.oj' linux_specific = Linux64DebugDriver() linux_speci...
25.526316
67
0.738144
fe157e75801f561cf95dfe96aa12aa00e1ccbc05
2,030
py
Python
globals/utils/ipmask.py
procool/mygw
f35b72b5915d314e883dcde45c3c33ff26f173df
[ "BSD-2-Clause" ]
null
null
null
globals/utils/ipmask.py
procool/mygw
f35b72b5915d314e883dcde45c3c33ff26f173df
[ "BSD-2-Clause" ]
null
null
null
globals/utils/ipmask.py
procool/mygw
f35b72b5915d314e883dcde45c3c33ff26f173df
[ "BSD-2-Clause" ]
null
null
null
class NetData(object): def __init__(self, addr, cidr): self.setaddr(addr) self.cidr = int(cidr) self.set_mask_by_cidr() self.set_net() self.set_broadcast() def setaddr(self, addr): self.__addr = map(int, addr.split('.')) # Initialize the netmask and calcula...
28.591549
82
0.580788
180b601eadf89468bab2f3628eec339597f2e102
5,395
py
Python
antlir/rpm/replay/rpm_replay.py
SaurabhAgarwala/antlir
d9513d35d3eaa9d28717a40057a14d099c6ec775
[ "MIT" ]
null
null
null
antlir/rpm/replay/rpm_replay.py
SaurabhAgarwala/antlir
d9513d35d3eaa9d28717a40057a14d099c6ec775
[ "MIT" ]
null
null
null
antlir/rpm/replay/rpm_replay.py
SaurabhAgarwala/antlir
d9513d35d3eaa9d28717a40057a14d099c6ec775
[ "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. "See `replay_rpms_and_compiler_items()`" import itertools import logging import pwd from contextlib import ExitStack, contextmanager from typi...
32.896341
80
0.640593
031cbc2cfe18f2ee3e49a908e1b4ddf3db7f8702
622
py
Python
jinja2/jinja-tutorial-p4-template-filters/custom_filters/python/hash_filter.py
progala/ttl255.com
100ae0e96ab7a9f72d0c18d985de2311a517878f
[ "MIT" ]
32
2018-05-28T13:35:49.000Z
2022-03-05T23:18:32.000Z
jinja2/jinja-tutorial-p4-template-filters/custom_filters/python/hash_filter.py
progala/ttl255.com
100ae0e96ab7a9f72d0c18d985de2311a517878f
[ "MIT" ]
1
2021-09-23T23:32:50.000Z
2021-09-23T23:32:50.000Z
jinja2/jinja-tutorial-p4-template-filters/custom_filters/python/hash_filter.py
progala/ttl255.com
100ae0e96ab7a9f72d0c18d985de2311a517878f
[ "MIT" ]
18
2019-02-19T22:36:45.000Z
2022-02-12T19:13:35.000Z
# hash_filter.py import hashlib def j2_hash_filter(value, hash_type="sha1"): """ Example filter providing custom Jinja2 filter - hash Hash type defaults to 'sha1' if one is not specified :param value: value to be hashed :param hash_type: valid hash type :return: computed hash as a hexadecima...
25.916667
71
0.672026
346000f68abe6d39f7af90ebae0d1827d98669c8
78,483
py
Python
pstem/stem-random-walk-nin-20-77/stem-random-walk-nin-20-77.py
Jeffrey-Ede/partial-STEM
916766091b81b54cacde85a319f34a47d50bce48
[ "MIT" ]
10
2019-06-12T00:24:37.000Z
2021-11-23T12:58:02.000Z
pstem/stem-random-walk-nin-20-77/stem-random-walk-nin-20-77.py
Jeffrey-Ede/partial-STEM
916766091b81b54cacde85a319f34a47d50bce48
[ "MIT" ]
null
null
null
pstem/stem-random-walk-nin-20-77/stem-random-walk-nin-20-77.py
Jeffrey-Ede/partial-STEM
916766091b81b54cacde85a319f34a47d50bce48
[ "MIT" ]
5
2019-06-11T05:49:10.000Z
2021-11-12T15:55:22.000Z
from __future__ import absolute_import from __future__ import division from __future__ import print_function import os os.environ["CUDA_VISIBLE_DEVICES"] = "0" import argparse import numpy as np import tensorflow as tf import cv2 from scipy.misc import imread from scipy import ndimage as nd impor...
40.855284
176
0.56016
dd1b360424f25fdc83851d61b084c1b98759297f
12,888
py
Python
test/functional/bip9-softforks.py
xraymemory/manna
b2f118bdce9b6a128ef171798ab3fac483517afa
[ "MIT" ]
null
null
null
test/functional/bip9-softforks.py
xraymemory/manna
b2f118bdce9b6a128ef171798ab3fac483517afa
[ "MIT" ]
null
null
null
test/functional/bip9-softforks.py
xraymemory/manna
b2f118bdce9b6a128ef171798ab3fac483517afa
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # Copyright (c) 2015-2016 The manna Core developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. """Test BIP 9 soft forks. Connect to a single node. regtest lock-in with 108/144 block signalling activatio...
45.540636
112
0.674426
a52cef50fe77b527e5adb2df9abfb2e1b3bf3fb5
4,612
py
Python
src/twillio_utils.py
trujivan/covid-helpline
abc79e0f14ad23c8c1d2063c3f8a036438f7de50
[ "MIT" ]
24
2020-03-11T16:32:42.000Z
2020-10-07T04:49:45.000Z
src/twillio_utils.py
trujivan/covid-helpline
abc79e0f14ad23c8c1d2063c3f8a036438f7de50
[ "MIT" ]
41
2020-03-16T01:27:08.000Z
2020-06-09T15:06:31.000Z
src/twillio_utils.py
trujivan/covid-helpline
abc79e0f14ad23c8c1d2063c3f8a036438f7de50
[ "MIT" ]
8
2020-03-12T14:20:36.000Z
2021-12-14T17:24:42.000Z
from flask import Flask, request from twilio.twiml.messaging_response import MessagingResponse from twilio.rest import Client from google.cloud import storage from google.cloud.storage import blob from datetime import datetime, timedelta from flask import Flask, request from twilio.twiml.messaging_response import Messa...
35.751938
116
0.710538
c2261be9772a888eabd432fba6a217663e1f0b18
68,955
py
Python
module_utils/network_lsr/argument_validator.py
sepiros62/network
880b7ab0ccd495c1b5c8d4698901a55e20c7a6ae
[ "BSD-3-Clause" ]
1
2021-05-13T11:28:57.000Z
2021-05-13T11:28:57.000Z
module_utils/network_lsr/argument_validator.py
sepiros62/network
880b7ab0ccd495c1b5c8d4698901a55e20c7a6ae
[ "BSD-3-Clause" ]
null
null
null
module_utils/network_lsr/argument_validator.py
sepiros62/network
880b7ab0ccd495c1b5c8d4698901a55e20c7a6ae
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/python3 -tt # vim: fileencoding=utf8 # SPDX-License-Identifier: BSD-3-Clause import posixpath import socket import re # pylint: disable=import-error, no-name-in-module from ansible.module_utils.network_lsr import MyError # noqa:E501 from ansible.module_utils.network_lsr.utils import Util # noqa:E501 UIN...
39.357877
88
0.525357
3701860abefc5fd080b7cb2807f7157565bfdb37
1,611
py
Python
100days/day102/aiohttp_multi_usage.py
chainren/python-learn
5e48e96c4bb212806b9ae0954fdb368abdcf9ba3
[ "Apache-2.0" ]
null
null
null
100days/day102/aiohttp_multi_usage.py
chainren/python-learn
5e48e96c4bb212806b9ae0954fdb368abdcf9ba3
[ "Apache-2.0" ]
16
2020-02-12T03:09:30.000Z
2022-03-12T00:08:59.000Z
100days/day102/aiohttp_multi_usage.py
chainren/python-learn
5e48e96c4bb212806b9ae0954fdb368abdcf9ba3
[ "Apache-2.0" ]
null
null
null
import aiohttp import asyncio # 抓取字节流数据并处理 async def fetch(client): async with client.get('http://httpbin.org/image/png') as resp: return await resp.read() async def main(): async with aiohttp.ClientSession() as client: img = await fetch(client) with open('httpbin_img.png', 'wb') as ...
27.775862
87
0.657976
47e7bee0159a2aeb15b28533a044af5e4e39326d
274
py
Python
tests/artificial/transf_Quantization/trend_Lag1Trend/cycle_7/ar_/test_artificial_1024_Quantization_Lag1Trend_7__100.py
jmabry/pyaf
afbc15a851a2445a7824bf255af612dc429265af
[ "BSD-3-Clause" ]
null
null
null
tests/artificial/transf_Quantization/trend_Lag1Trend/cycle_7/ar_/test_artificial_1024_Quantization_Lag1Trend_7__100.py
jmabry/pyaf
afbc15a851a2445a7824bf255af612dc429265af
[ "BSD-3-Clause" ]
1
2019-11-30T23:39:38.000Z
2019-12-01T04:34:35.000Z
tests/artificial/transf_Quantization/trend_Lag1Trend/cycle_7/ar_/test_artificial_1024_Quantization_Lag1Trend_7__100.py
jmabry/pyaf
afbc15a851a2445a7824bf255af612dc429265af
[ "BSD-3-Clause" ]
null
null
null
import pyaf.Bench.TS_datasets as tsds import pyaf.tests.artificial.process_artificial_dataset as art art.process_dataset(N = 1024 , FREQ = 'D', seed = 0, trendtype = "Lag1Trend", cycle_length = 7, transform = "Quantization", sigma = 0.0, exog_count = 100, ar_order = 0);
39.142857
169
0.737226
c8f394451463cb0a29fdaf03f04d21cf5f58d0b4
22,674
py
Python
nova/tests/unit/accelerator/test_cyborg.py
zjzh/nova
7bb21723171c59b93e28f5d508c2b6df39220f13
[ "Apache-2.0" ]
1,874
2015-01-04T05:18:34.000Z
2022-03-31T03:30:28.000Z
nova/tests/unit/accelerator/test_cyborg.py
zjzh/nova
7bb21723171c59b93e28f5d508c2b6df39220f13
[ "Apache-2.0" ]
40
2015-04-13T02:32:42.000Z
2022-02-16T02:28:06.000Z
nova/tests/unit/accelerator/test_cyborg.py
zjzh/nova
7bb21723171c59b93e28f5d508c2b6df39220f13
[ "Apache-2.0" ]
1,996
2015-01-04T15:11:51.000Z
2022-03-31T11:03:13.000Z
# Copyright 2019 OpenStack Foundation # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law ...
42.781132
79
0.654185
ba980768de372f3aa4125961a8f487b1e49f1897
196
py
Python
dtags/version.py
joowani/dtags
9e9d02267cc56bf406ee0bfe0af9c5e56db6a8e3
[ "MIT" ]
405
2016-01-25T05:51:42.000Z
2022-01-07T06:53:43.000Z
dtags/version.py
joowani/dtags
9e9d02267cc56bf406ee0bfe0af9c5e56db6a8e3
[ "MIT" ]
21
2016-01-31T16:23:19.000Z
2019-08-24T15:14:03.000Z
dtags/version.py
joowani/dtags
9e9d02267cc56bf406ee0bfe0af9c5e56db6a8e3
[ "MIT" ]
16
2016-02-01T09:06:00.000Z
2020-09-23T13:19:31.000Z
# coding: utf-8 # file generated by setuptools_scm # don't change, don't track in version control version = '3.2.5.dev0+g80daf36.d20210307' version_tuple = (3, 2, 5, 'dev0+g80daf36', 'd20210307')
32.666667
55
0.72449
25af2351b6a0c84d15e680025874a1cf84e3ea32
683
py
Python
app/core/migrations/0002_tag.py
venky-web/recipe-app-api
0cef9aae704fe6e3412c6aa0790631411840420b
[ "MIT" ]
null
null
null
app/core/migrations/0002_tag.py
venky-web/recipe-app-api
0cef9aae704fe6e3412c6aa0790631411840420b
[ "MIT" ]
null
null
null
app/core/migrations/0002_tag.py
venky-web/recipe-app-api
0cef9aae704fe6e3412c6aa0790631411840420b
[ "MIT" ]
null
null
null
# Generated by Django 2.1.15 on 2020-09-15 17:13 from django.conf import settings from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('core', '0001_initial'), ] operations = [ migrations.CreateModel( ...
28.458333
118
0.616398
95d048d5e325ad7e4504b8416820a4b5e4425be7
1,027
py
Python
common/file/fileHandler.py
DJAcquila/CompilerMGOL
db21bbdb0c2b36663469d879af81fdd66a1bb96f
[ "MIT" ]
1
2019-04-16T03:37:34.000Z
2019-04-16T03:37:34.000Z
common/file/fileHandler.py
DJAcquila/CompilerMGOL
db21bbdb0c2b36663469d879af81fdd66a1bb96f
[ "MIT" ]
null
null
null
common/file/fileHandler.py
DJAcquila/CompilerMGOL
db21bbdb0c2b36663469d879af81fdd66a1bb96f
[ "MIT" ]
1
2019-04-18T20:15:35.000Z
2019-04-18T20:15:35.000Z
#!/usr/bin/python3 from common.utility.util import * class FileHandler(): def __init__(self, name): self. name = name self._arquivo = open(name, 'r') self.lines = self._arquivo.readlines() self.eof = self._arquivo.tell() self.coluna = 0 self.linha = 1 self.po...
22.822222
46
0.567673
c8e03abb6e462f7f31ce4ad451a3dcafdf462bf1
1,902
py
Python
pairedtwosamplegeneration.py
amon80/fslscripts
f0800c475a5038f4194ea2ecde2863342475e463
[ "MIT" ]
null
null
null
pairedtwosamplegeneration.py
amon80/fslscripts
f0800c475a5038f4194ea2ecde2863342475e463
[ "MIT" ]
null
null
null
pairedtwosamplegeneration.py
amon80/fslscripts
f0800c475a5038f4194ea2ecde2863342475e463
[ "MIT" ]
null
null
null
import sys def generate_files(num_subjects, mat_output_filename, con_output_filename, grp_output_filename): matrix = [] #Allocating matrix num_maps = num_subjects*2 num_cols = num_subjects+1 for i in range(num_maps): matrix.append(list()) for i in range(num_maps): for j in range...
32.237288
98
0.593586
ffe63198e93d858726f66cc11151085b4d8beb52
616
py
Python
scripts/validutils_ztf/misc.py
LSSTDESC/transient-host-sims
a9c02077d2378bd2e3391c52ef2eeecf916cf313
[ "BSD-3-Clause" ]
null
null
null
scripts/validutils_ztf/misc.py
LSSTDESC/transient-host-sims
a9c02077d2378bd2e3391c52ef2eeecf916cf313
[ "BSD-3-Clause" ]
null
null
null
scripts/validutils_ztf/misc.py
LSSTDESC/transient-host-sims
a9c02077d2378bd2e3391c52ef2eeecf916cf313
[ "BSD-3-Clause" ]
null
null
null
""" Additional utilities """ import pandas import numpy as np from .table import LSST_FILTERS def dict2df(datadict): """ Convert dictionary object to a DataFrame """ for idx in datadict: sn = datadict[idx] for filt in LSST_FILTERS: sn['mjd_%s' % filt] = np.array(sn[filt]['...
24.64
73
0.590909
c171039c0ce00af9f16ef2cf69457a9378e248d4
2,048
py
Python
util/test/annotate.py
tmacd9/chapel
9a833f6620a1d7ebeccb32e4a637f0f829b82d54
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
util/test/annotate.py
tmacd9/chapel
9a833f6620a1d7ebeccb32e4a637f0f829b82d54
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
util/test/annotate.py
tmacd9/chapel
9a833f6620a1d7ebeccb32e4a637f0f829b82d54
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
import socket, time import json from collections import defaultdict import yaml try: # Use CLoader if available for the speed boost from yaml import CLoader as Loader except ImportError: # Fall back to the python Loader otherwise from yaml import Loader _hostname = socket.gethostname().split('.')[0] _dat_date...
25.924051
78
0.65918
ecaed0bf3ac6e7260dd8c1185282b383789d6cce
6,864
py
Python
Watershed_Spatial_Dataset/LiDAR/waveform/chunk_waveforms.py
hmworsham/eastriver
090171bcbc5b5d7db5f4f619dbc5af53e152d36d
[ "MIT" ]
null
null
null
Watershed_Spatial_Dataset/LiDAR/waveform/chunk_waveforms.py
hmworsham/eastriver
090171bcbc5b5d7db5f4f619dbc5af53e152d36d
[ "MIT" ]
null
null
null
Watershed_Spatial_Dataset/LiDAR/waveform/chunk_waveforms.py
hmworsham/eastriver
090171bcbc5b5d7db5f4f619dbc5af53e152d36d
[ "MIT" ]
null
null
null
# Chunk NEON waveform LiDAR binary files # Author: Marshall Worsham # Revised: 21-03-29 # This script contains functions to ingest large (20+GB) files from NEON waveform LiDAR acquisition and split them into more manageable chunks of ~1GB in size. The script defines several functions, which can be combined into a sing...
39
419
0.646707
90b822273f94eaa38b92daed3d57c7ca6379a71c
869
py
Python
test/test_term_group.py
apsinha-equinix/controlm-client
f24e0f935c82306074f4e4025cf62c217348dc3f
[ "MIT" ]
1
2021-12-02T08:49:25.000Z
2021-12-02T08:49:25.000Z
test/test_term_group.py
apsinha-equinix/controlm-client
f24e0f935c82306074f4e4025cf62c217348dc3f
[ "MIT" ]
null
null
null
test/test_term_group.py
apsinha-equinix/controlm-client
f24e0f935c82306074f4e4025cf62c217348dc3f
[ "MIT" ]
null
null
null
# coding: utf-8 """ Control-M Services Provides access to BMC Control-M Services # noqa: E501 OpenAPI spec version: 9.18.3 Contact: support@bmc.com Generated by: https://github.com/swagger-api/swagger-codegen.git """ from __future__ import absolute_import import unittest import controlm_clie...
21.195122
79
0.693901
1c5ce5a5ce0a79b73fa4004fc5c18547725f0347
14,422
py
Python
utils.py
VijaySingh-GSLab/venue_recommender
3c3bddc19c2f3be71833b85c5a1de2522771f0b3
[ "MIT" ]
null
null
null
utils.py
VijaySingh-GSLab/venue_recommender
3c3bddc19c2f3be71833b85c5a1de2522771f0b3
[ "MIT" ]
null
null
null
utils.py
VijaySingh-GSLab/venue_recommender
3c3bddc19c2f3be71833b85c5a1de2522771f0b3
[ "MIT" ]
2
2021-05-10T10:59:55.000Z
2021-05-10T11:09:11.000Z
import numpy as np import pandas as pd from scipy import stats from scipy.spatial import distance import matplotlib.pyplot as plt import seaborn as sns from matplotlib.ticker import MaxNLocator from pathlib import Path import plotly.graph_objects as go MAPBOX_TOKEN = 'pk.eyJ1IjoidmlqYXlzaW5naGdzbGFiIiwiYSI6ImNrbDE2dzB...
35.261614
168
0.67397
dcc5dfe7dcd9a17cf5c7125b117e802582209cbb
4,720
py
Python
proxypool/schedule.py
guoweikang/proxypool
84ef21833af859b3eb770cc1fdd9bfa1a7f7e216
[ "Apache-2.0" ]
null
null
null
proxypool/schedule.py
guoweikang/proxypool
84ef21833af859b3eb770cc1fdd9bfa1a7f7e216
[ "Apache-2.0" ]
null
null
null
proxypool/schedule.py
guoweikang/proxypool
84ef21833af859b3eb770cc1fdd9bfa1a7f7e216
[ "Apache-2.0" ]
null
null
null
import time from multiprocessing import Process import asyncio import aiohttp from aiohttp import streams try: from aiohttp.errors import ProxyConnectionError,ServerDisconnectedError,ClientResponseError,ClientConnectorError except: from aiohttp import ClientProxyConnectionError as ProxyConnectionError,ServerDis...
33.475177
139
0.600212
a5374527fcb2cafe851135fe830beb6a9f5ba4e5
84,895
py
Python
django/contrib/admin/options.py
nicois/django
db4149a063fb99e2d2ba760bafeef3f14590fef6
[ "PSF-2.0", "BSD-3-Clause" ]
null
null
null
django/contrib/admin/options.py
nicois/django
db4149a063fb99e2d2ba760bafeef3f14590fef6
[ "PSF-2.0", "BSD-3-Clause" ]
null
null
null
django/contrib/admin/options.py
nicois/django
db4149a063fb99e2d2ba760bafeef3f14590fef6
[ "PSF-2.0", "BSD-3-Clause" ]
null
null
null
import copy import json import operator from collections import OrderedDict from functools import partial, reduce, update_wrapper from urllib.parse import quote as urlquote from django import forms from django.conf import settings from django.contrib import messages from django.contrib.admin import helpers, widgets fr...
41.513447
118
0.61503
5cab87bdc6fdeb04f3b1613101b376997e639c9c
2,691
py
Python
streetlevel/streetview/protobuf.py
sk-zk/streetlevel
3d7171849dd5f45a3a20f1f770a0b328061e53ff
[ "MIT" ]
null
null
null
streetlevel/streetview/protobuf.py
sk-zk/streetlevel
3d7171849dd5f45a3a20f1f770a0b328061e53ff
[ "MIT" ]
null
null
null
streetlevel/streetview/protobuf.py
sk-zk/streetlevel
3d7171849dd5f45a3a20f1f770a0b328061e53ff
[ "MIT" ]
null
null
null
# Some code to deal with the URL-encoded protobuf Google uses in Maps. from enum import Enum class ProtobufType(Enum): """ Data types found in protobuf and their identifier in the URL encoded version. """ # There are more data types in protobuf, # these are just the ones I've encountered in this p...
28.03125
81
0.662951
ed336b3628ae140e2b2b2c9893dfbd74e519b0cf
915,713
py
Python
venv/lib/python3.6/site-packages/phonenumbers/geodata/data13.py
exdeam/opencrm
dfdcfdf99f0b42eb3959171927cb6574583f5ee0
[ "MIT" ]
null
null
null
venv/lib/python3.6/site-packages/phonenumbers/geodata/data13.py
exdeam/opencrm
dfdcfdf99f0b42eb3959171927cb6574583f5ee0
[ "MIT" ]
null
null
null
venv/lib/python3.6/site-packages/phonenumbers/geodata/data13.py
exdeam/opencrm
dfdcfdf99f0b42eb3959171927cb6574583f5ee0
[ "MIT" ]
null
null
null
"""Per-prefix data, mapping each prefix to a dict of locale:name. Auto-generated file, do not edit by hand. """ from ..util import u # Copyright (C) 2011-2019 The Libphonenumber Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the Licens...
91.361169
139
0.647827
b63ee1ee8be46be82a71b9805e05b77854562b1a
2,402
py
Python
rllib/utils/framework.py
thavlik/ray
9b9c7f86f7e2c0723b7e14e38cd52c69cc7e1c43
[ "Apache-2.0" ]
4
2019-10-18T17:44:58.000Z
2021-04-14T14:37:21.000Z
rllib/utils/framework.py
Eric2Hamel/ray
bfaee49880611a65d16a4561c94c60851573b6f2
[ "Apache-2.0" ]
1
2022-03-30T17:52:44.000Z
2022-03-30T17:52:44.000Z
rllib/utils/framework.py
Eric2Hamel/ray
bfaee49880611a65d16a4561c94c60851573b6f2
[ "Apache-2.0" ]
1
2020-06-26T07:54:25.000Z
2020-06-26T07:54:25.000Z
import logging import os logger = logging.getLogger(__name__) def check_framework(framework="tf"): """ Checks, whether the given framework is "valid", meaning, whether all necessary dependencies are installed. Errors otherwise. Args: framework (str): Once of "tf", "torch", or None. Retu...
24.510204
76
0.603664
234cbbed1ce00d47b09391a5092a4027aed71a5a
2,871
py
Python
No_0264_Ugly Number II/ugly_nubmer_ii_by_look_up_table.py
coderMaruf/leetcode-1
20ffe26e43999e44c8acf9800acb371a49bb5853
[ "MIT" ]
32
2020-01-05T13:37:16.000Z
2022-03-26T07:27:09.000Z
No_0264_Ugly Number II/ugly_nubmer_ii_by_look_up_table.py
coderMaruf/leetcode-1
20ffe26e43999e44c8acf9800acb371a49bb5853
[ "MIT" ]
null
null
null
No_0264_Ugly Number II/ugly_nubmer_ii_by_look_up_table.py
coderMaruf/leetcode-1
20ffe26e43999e44c8acf9800acb371a49bb5853
[ "MIT" ]
8
2020-06-18T16:17:27.000Z
2022-03-15T23:58:18.000Z
''' Description: Write a program to find the n-th ugly number. Ugly numbers are positive numbers whose prime factors only include 2, 3, 5. Example: Input: n = 10 Output: 12 Explanation: 1, 2, 3, 4, 5, 6, 8, 9, 10, 12 is the sequence of the first 10 ugly numbers. Note: 1 is typically treated as an ugly number. ...
19.9375
89
0.537095
290818959b4fd4e4f3b8cc7e92184fa34a76b999
25,882
py
Python
swift/proxy/server.py
hbhdytf/mac
51252356b22a792599a401f40ede0b9fda9fccdc
[ "Apache-2.0" ]
null
null
null
swift/proxy/server.py
hbhdytf/mac
51252356b22a792599a401f40ede0b9fda9fccdc
[ "Apache-2.0" ]
null
null
null
swift/proxy/server.py
hbhdytf/mac
51252356b22a792599a401f40ede0b9fda9fccdc
[ "Apache-2.0" ]
null
null
null
# Copyright (c) 2010-2012 OpenStack Foundation # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agree...
45.090592
79
0.604938
eb1371e077bc54249e63715a937165fce230e445
94
py
Python
exersizes/ch3dotwice.py
KitN/ThinkPython2
70df29d014198c5725fc01a6c619787b487a1fdb
[ "MIT" ]
null
null
null
exersizes/ch3dotwice.py
KitN/ThinkPython2
70df29d014198c5725fc01a6c619787b487a1fdb
[ "MIT" ]
null
null
null
exersizes/ch3dotwice.py
KitN/ThinkPython2
70df29d014198c5725fc01a6c619787b487a1fdb
[ "MIT" ]
null
null
null
def dotwice(f,n): f(n) f(n) def print_spam(): print('spam') dotwice(print_spam)
10.444444
19
0.585106
e35430be4618cb16bf44f2a1f4369d522b8bbc32
5,229
py
Python
pyalgotrade/optimizer/local.py
Richard-L-Johnson/pyalgotrader
ad2bcc6b25c06c66eee4a8d522ce844504d8ec62
[ "Apache-2.0" ]
3,719
2015-01-06T09:00:02.000Z
2022-03-31T20:55:01.000Z
pyalgotrade/optimizer/local.py
Richard-L-Johnson/pyalgotrader
ad2bcc6b25c06c66eee4a8d522ce844504d8ec62
[ "Apache-2.0" ]
122
2015-01-01T17:06:22.000Z
2022-03-22T13:33:38.000Z
pyalgotrade/optimizer/local.py
Richard-L-Johnson/pyalgotrader
ad2bcc6b25c06c66eee4a8d522ce844504d8ec62
[ "Apache-2.0" ]
1,428
2015-01-01T17:07:38.000Z
2022-03-31T10:02:37.000Z
# PyAlgoTrade # # Copyright 2011-2018 Gabriel Martin Becedillas Ruiz # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by ap...
33.094937
127
0.676802
b5d0213de62ed3ea48e3a10bf0cc5d6b41c2e553
5,979
py
Python
djproject/pictureupload/views.py
missingDown/webForUpload
fbd5ed9e8cfcd4ad906913f4a31c24e87919f9a3
[ "MIT" ]
null
null
null
djproject/pictureupload/views.py
missingDown/webForUpload
fbd5ed9e8cfcd4ad906913f4a31c24e87919f9a3
[ "MIT" ]
null
null
null
djproject/pictureupload/views.py
missingDown/webForUpload
fbd5ed9e8cfcd4ad906913f4a31c24e87919f9a3
[ "MIT" ]
null
null
null
from django.shortcuts import render from django.http import HttpResponse import logging import json import base64 import time # Create your views here. logger = logging.getLogger(__name__) # 文件上传:form-data/Multipart方式 POST方法 def index(request): sendfile = request.FILES.items() haveFiles = False for key,...
38.082803
85
0.632882
a95325b64917b7df7e476268360d53e5a5de9525
1,734
py
Python
lwr/cache/__init__.py
jmchilton/lwr
cd1e51b0b9b1a9fa01b92b0026e7b535d954e03b
[ "Apache-2.0" ]
1
2016-08-17T06:36:03.000Z
2016-08-17T06:36:03.000Z
lwr/cache/__init__.py
jmchilton/lwr
cd1e51b0b9b1a9fa01b92b0026e7b535d954e03b
[ "Apache-2.0" ]
null
null
null
lwr/cache/__init__.py
jmchilton/lwr
cd1e51b0b9b1a9fa01b92b0026e7b535d954e03b
[ "Apache-2.0" ]
null
null
null
from os.path import join, exists from hashlib import sha256 from .persistence import PersistenceStore from .util import atomicish_move from .util import Time class CacheFileMapper(object): def __init__(self, directory): self.directory = directory def get(self, token): return join(self.dire...
26.272727
73
0.631488
13a015db3f045b0c4268e355463010c75a7f56f5
1,773
py
Python
framework/layers/positional_encoding.py
RobertCsordas/modules
efdb8790b074862581e035c9ab5bf889440a8023
[ "BSD-3-Clause" ]
22
2020-10-19T07:40:01.000Z
2022-03-24T15:26:34.000Z
framework/layers/positional_encoding.py
xdever/modules
efdb8790b074862581e035c9ab5bf889440a8023
[ "BSD-3-Clause" ]
6
2020-10-19T23:57:23.000Z
2022-03-12T00:51:58.000Z
framework/layers/positional_encoding.py
xdever/modules
efdb8790b074862581e035c9ab5bf889440a8023
[ "BSD-3-Clause" ]
5
2020-11-30T00:17:34.000Z
2021-06-26T11:43:24.000Z
import torch import math class PositionalEncoding(torch.nn.Module): r"""Inject some information about the relative or absolute position of the tokens in the sequence. The positional encodings have the same dimension as the embeddings, so that the two can be summed. Here, we use sine and cosine ...
43.243902
101
0.652002
a9f705306cb5845c3338744a65e509d7dc4d6cb3
10,731
py
Python
mapproxy/test/unit/test_async.py
kaiCu/mapproxy
9b28f9ca1286e686b8f2188dd52ce56b607427a7
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
mapproxy/test/unit/test_async.py
kaiCu/mapproxy
9b28f9ca1286e686b8f2188dd52ce56b607427a7
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
mapproxy/test/unit/test_async.py
kaiCu/mapproxy
9b28f9ca1286e686b8f2188dd52ce56b607427a7
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
# This file is part of the MapProxy project. # Copyright (C) 2011 Omniscale <http://omniscale.de> # # 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...
31.469208
105
0.586991
384c2333140573572d833852c0791f03f33bb61c
249
py
Python
app_quis/admin.py
naelallves/proj_sinal_transito
bc8b82c1809b8ff97996227bbefc07f42ea5f736
[ "MIT" ]
null
null
null
app_quis/admin.py
naelallves/proj_sinal_transito
bc8b82c1809b8ff97996227bbefc07f42ea5f736
[ "MIT" ]
null
null
null
app_quis/admin.py
naelallves/proj_sinal_transito
bc8b82c1809b8ff97996227bbefc07f42ea5f736
[ "MIT" ]
null
null
null
from django.contrib import admin from .models import Categoria, Pergunta, Alternativa, RelPerguntaAlternativa admin.site.register(Categoria) admin.site.register(Pergunta) admin.site.register(Alternativa) admin.site.register(RelPerguntaAlternativa)
31.125
76
0.851406
06cbaa91ff8aa03ebfd048e700fac3289597fac5
215
py
Python
14_pr1_04.py
AmreshTripathy/Advance-Python
0cfe3fc263af1080edbf9167895a51d27be64993
[ "Apache-2.0" ]
null
null
null
14_pr1_04.py
AmreshTripathy/Advance-Python
0cfe3fc263af1080edbf9167895a51d27be64993
[ "Apache-2.0" ]
null
null
null
14_pr1_04.py
AmreshTripathy/Advance-Python
0cfe3fc263af1080edbf9167895a51d27be64993
[ "Apache-2.0" ]
null
null
null
a = float(input('Enter the No.1: ')) b = float(input('Enter the No.2: ')) try: c = a/b print (c) except ZeroDivisionError: print ('infinite') except ValueError: print ('Give a valid value')
21.5
37
0.595349
a961946608c3f71233e106cd30814511f5be80ae
438
py
Python
accounts/migrations/0006_user_pronouns.py
Muirrum/lnldb
e72dc4ce729a53b0bd462e53578515b901307214
[ "MIT" ]
5
2017-09-25T21:24:59.000Z
2021-12-18T17:08:13.000Z
accounts/migrations/0006_user_pronouns.py
WPI-LNL/lnldb
cc34383b785ae86a691686e31bebbbc8038fcd8a
[ "MIT" ]
304
2015-03-24T17:44:22.000Z
2022-03-29T14:09:41.000Z
accounts/migrations/0006_user_pronouns.py
Muirrum/lnldb
e72dc4ce729a53b0bd462e53578515b901307214
[ "MIT" ]
10
2017-10-24T02:18:12.000Z
2021-09-20T20:40:25.000Z
# Generated by Django 3.1.13 on 2021-09-20 00:45 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('accounts', '0005_remove_duplicate_perms'), ] operations = [ migrations.AddField( model_name='user', name='pronouns'...
23.052632
98
0.621005
159ae76ae9c29cecafa1b3644743cf82d9128fbb
5,459
py
Python
goose/crawler.py
stungkit/PyTeaser
b8792b1efe1a8642d24db84816e5281253ab2a92
[ "MIT" ]
728
2015-01-01T11:06:38.000Z
2022-03-16T21:32:54.000Z
goose/crawler.py
stungkit/PyTeaser
b8792b1efe1a8642d24db84816e5281253ab2a92
[ "MIT" ]
22
2015-01-09T00:35:17.000Z
2021-08-28T22:29:28.000Z
goose/crawler.py
stungkit/PyTeaser
b8792b1efe1a8642d24db84816e5281253ab2a92
[ "MIT" ]
128
2015-01-08T20:50:04.000Z
2021-07-31T21:33:41.000Z
# -*- coding: utf-8 -*- """\ This is a python port of "Goose" orignialy licensed to Gravity.com under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. Python port was written by Xavier Grangier for Recrutae Gravity.co...
36.637584
101
0.70654
88fd17714fc217b55f3694a91e3906d51ae6aa29
14,802
py
Python
clinicgen/models/transformer.py
kttian/ifcc
017827fb175713802d3128de4841cc4d54cc7598
[ "Apache-2.0" ]
43
2020-10-21T03:25:21.000Z
2022-03-26T08:13:06.000Z
clinicgen/models/transformer.py
kttian/ifcc
017827fb175713802d3128de4841cc4d54cc7598
[ "Apache-2.0" ]
8
2020-12-04T15:06:45.000Z
2022-03-28T12:18:14.000Z
clinicgen/models/transformer.py
kttian/ifcc
017827fb175713802d3128de4841cc4d54cc7598
[ "Apache-2.0" ]
10
2020-11-13T03:46:09.000Z
2022-02-05T21:39:52.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- import math import random import numpy as np import torch from torch.nn import Dropout, Embedding, LayerNorm, Linear, Module from torch.distributions.categorical import Categorical from torch.nn.functional import cross_entropy, log_softmax, relu, softmax from torch.nn.modu...
44.719033
129
0.599041
3a4290311cd426c85bec5be328709300867f9091
1,425
py
Python
lib/ansiblelint/rules/NoFormattingInWhenRule.py
senyoltw/ansible-lint
0e53d73c97601351bbac8a6d2eb092efb29609b8
[ "MIT" ]
null
null
null
lib/ansiblelint/rules/NoFormattingInWhenRule.py
senyoltw/ansible-lint
0e53d73c97601351bbac8a6d2eb092efb29609b8
[ "MIT" ]
null
null
null
lib/ansiblelint/rules/NoFormattingInWhenRule.py
senyoltw/ansible-lint
0e53d73c97601351bbac8a6d2eb092efb29609b8
[ "MIT" ]
null
null
null
from typing import TYPE_CHECKING, List from ansiblelint.rules import AnsibleLintRule if TYPE_CHECKING: from ansiblelint.errors import MatchError from ansiblelint.file_utils import Lintable class NoFormattingInWhenRule(AnsibleLintRule): id = '102' shortdesc = 'No Jinja2 in when' description = '``...
34.756098
97
0.595088
5e10087f90cefa4fdc608b2c37b3ff40b762707c
7,646
py
Python
bot/main.py
vmariano/meme-classifier
e8d6e73e4a843542143f20381c0741df16d3945d
[ "BSD-3-Clause" ]
null
null
null
bot/main.py
vmariano/meme-classifier
e8d6e73e4a843542143f20381c0741df16d3945d
[ "BSD-3-Clause" ]
1
2022-02-07T12:06:59.000Z
2022-02-07T12:06:59.000Z
bot/main.py
vmariano/meme-classifier
e8d6e73e4a843542143f20381c0741df16d3945d
[ "BSD-3-Clause" ]
1
2022-02-07T02:38:04.000Z
2022-02-07T02:38:04.000Z
from dotenv import load_dotenv load_dotenv() import os import sys import logging import io import re import json import urllib from datetime import datetime import psycopg2 from telegram import BotCommand, InlineKeyboardMarkup, InlineKeyboardButton from telegram.ext import Updater, MessageHandler, Filters, CommandHan...
40.242105
202
0.662961
f4e701c554f8c67341b0c4dc7d8f1ceb8920169e
1,155
py
Python
src/utils/format_sparse.py
mbortolon97/ipfp-hpc-cluster
bffa79b46f61135018562a13b587e5fed76782b0
[ "MIT" ]
null
null
null
src/utils/format_sparse.py
mbortolon97/ipfp-hpc-cluster
bffa79b46f61135018562a13b587e5fed76782b0
[ "MIT" ]
null
null
null
src/utils/format_sparse.py
mbortolon97/ipfp-hpc-cluster
bffa79b46f61135018562a13b587e5fed76782b0
[ "MIT" ]
null
null
null
from scipy.sparse import csr_matrix, load_npz import argparse def input(): parser = argparse.ArgumentParser(description="Convert a sparse SciPy matrix into the format for the IPFP") parser.add_argument("input_filepath", type=str, help="the filepath where the SciPy ipfp matrix are stored") parser.add_argume...
41.25
111
0.707359
5b375c15ddcbea74e9355e1ff09c5c42c115f770
4,105
py
Python
scone_phobia/metadata/corpora.py
Thomas-Schatz/scone-phobia
55577d150ff71fd1f1c52073143c64e242b28600
[ "MIT" ]
null
null
null
scone_phobia/metadata/corpora.py
Thomas-Schatz/scone-phobia
55577d150ff71fd1f1c52073143c64e242b28600
[ "MIT" ]
1
2018-10-26T18:20:56.000Z
2018-10-26T18:20:56.000Z
scone_phobia/metadata/corpora.py
Thomas-Schatz/scone-phobia
55577d150ff71fd1f1c52073143c64e242b28600
[ "MIT" ]
1
2019-08-02T15:53:12.000Z
2019-08-02T15:53:12.000Z
# -*- coding: utf-8 -*- """ Created on Wed Jun 27 12:18:50 2018 @author: Thomas Schatz Useful info about corpora of speech recordings. Currently there are four functions: - two which take the corpus name as input and respectively return the: - language - register - two which take a language a...
25.65625
80
0.358831