hexsha stringlengths 40 40 | size int64 5 2.06M | ext stringclasses 11
values | lang stringclasses 1
value | max_stars_repo_path stringlengths 3 251 | max_stars_repo_name stringlengths 4 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 251 | max_issues_repo_name stringlengths 4 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 251 | max_forks_repo_name stringlengths 4 130 | max_forks_repo_head_hexsha stringlengths 40 78 | max_forks_repo_licenses listlengths 1 10 | max_forks_count int64 1 105k ⌀ | max_forks_repo_forks_event_min_datetime stringlengths 24 24 ⌀ | max_forks_repo_forks_event_max_datetime stringlengths 24 24 ⌀ | content stringlengths 1 1.05M | avg_line_length float64 1 1.02M | max_line_length int64 3 1.04M | alphanum_fraction float64 0 1 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
208ab0efab1a44dca566c2b25386582351d6f44f | 1,465 | py | Python | examples/tf/reps_gym_cartpole.py | thanhkaist/garage | 1d840df357282a675b8fce839bb0e5f72a8abba9 | [
"MIT"
] | 7 | 2022-02-01T03:02:24.000Z | 2022-02-10T12:54:05.000Z | examples/tf/reps_gym_cartpole.py | thanhkaist/garage | 1d840df357282a675b8fce839bb0e5f72a8abba9 | [
"MIT"
] | null | null | null | examples/tf/reps_gym_cartpole.py | thanhkaist/garage | 1d840df357282a675b8fce839bb0e5f72a8abba9 | [
"MIT"
] | 2 | 2022-02-03T03:33:25.000Z | 2022-02-10T12:54:07.000Z | #!/usr/bin/env python3
"""This is an example to train a task with REPS algorithm.
Here it runs gym CartPole env with 100 iterations.
Results:
AverageReturn: 100 +/- 40
RiseTime: itr 10 +/- 5
"""
import gym
from garage import wrap_experiment
from garage.envs import GarageEnv
from garage.experiment import Lo... | 27.641509 | 79 | 0.690102 |
208b5a19512f2c1942088dd7f08d4f5e98808037 | 869 | py | Python | examples/python_in_cpp/python_src/py_display.py | aff3ct/py_aff3ct | 8afb7e6b1db1b621db0ae4153b29a2e848e09fcf | [
"MIT"
] | 15 | 2021-01-24T11:59:04.000Z | 2022-03-23T07:23:44.000Z | examples/python_in_cpp/python_src/py_display.py | aff3ct/py_aff3ct | 8afb7e6b1db1b621db0ae4153b29a2e848e09fcf | [
"MIT"
] | 8 | 2021-05-24T18:22:45.000Z | 2022-03-11T09:48:05.000Z | examples/python_in_cpp/python_src/py_display.py | aff3ct/py_aff3ct | 8afb7e6b1db1b621db0ae4153b29a2e848e09fcf | [
"MIT"
] | 4 | 2021-01-26T19:18:21.000Z | 2021-12-07T17:02:34.000Z | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
import sys
sys.path.insert(0, '../../../build/lib')
import numpy as np
import matplotlib.pyplot as plt
from py_aff3ct.module.py_module import Py_Module | 24.828571 | 59 | 0.654776 |
208b826ac073ffc78e9fc4a4daa39a825a8767d0 | 3,906 | py | Python | tests/_dao/TestRTKEnvironment.py | rakhimov/rtk | adc35e218ccfdcf3a6e3082f6a1a1d308ed4ff63 | [
"BSD-3-Clause"
] | null | null | null | tests/_dao/TestRTKEnvironment.py | rakhimov/rtk | adc35e218ccfdcf3a6e3082f6a1a1d308ed4ff63 | [
"BSD-3-Clause"
] | null | null | null | tests/_dao/TestRTKEnvironment.py | rakhimov/rtk | adc35e218ccfdcf3a6e3082f6a1a1d308ed4ff63 | [
"BSD-3-Clause"
] | 2 | 2020-04-03T04:14:42.000Z | 2021-02-22T05:30:35.000Z | #!/usr/bin/env python -O
# -*- coding: utf-8 -*-
#
# tests.unit._dao.TestRTKEnvironment.py is part of The RTK Project
#
# All rights reserved.
"""
This is the test class for testing the RTKEnvironment module algorithms and
models.
"""
import sys
from os.path import dirname
sys.path.insert(
0,
dirname(d... | 31.248 | 111 | 0.647465 |
208d55bf2af77c0581700d580f1805b2e51b5213 | 30,297 | py | Python | model/dualposenet.py | wx-b/DualPoseNet | 393f786a28f857eee36d913f335912da72b28371 | [
"MIT"
] | 14 | 2021-08-19T09:12:23.000Z | 2022-03-22T06:58:58.000Z | model/dualposenet.py | wx-b/DualPoseNet | 393f786a28f857eee36d913f335912da72b28371 | [
"MIT"
] | 4 | 2021-09-16T05:48:53.000Z | 2022-02-28T16:23:40.000Z | model/dualposenet.py | wx-b/DualPoseNet | 393f786a28f857eee36d913f335912da72b28371 | [
"MIT"
] | 7 | 2021-10-11T05:38:39.000Z | 2022-01-04T03:22:57.000Z | # Copyright (c) Gorilla Lab, SCUT.
#
# This source code is licensed under the MIT license found in the
# LICENSE file in the root directory of this source tree.
"""
Dual Pose Network with Refined Learning of Pose Consistency.
Author: Jiehong Lin
"""
import os
import tensorflow as tf
import numpy as np
... | 48.243631 | 175 | 0.529491 |
208e001e2d8d189eee888e06083e153b859d3d35 | 1,652 | py | Python | tests/friend/test_net.py | cloudboss/friend | 3357e6ec849552e3ae9ed28017ff0926e4006e4e | [
"MIT"
] | null | null | null | tests/friend/test_net.py | cloudboss/friend | 3357e6ec849552e3ae9ed28017ff0926e4006e4e | [
"MIT"
] | null | null | null | tests/friend/test_net.py | cloudboss/friend | 3357e6ec849552e3ae9ed28017ff0926e4006e4e | [
"MIT"
] | null | null | null | # Copyright 2018 Joseph Wright <joseph@cloudboss.co>
#
# 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, mer... | 44.648649 | 79 | 0.735472 |
20903497b848af034e0eb1186f088232c687e594 | 341 | py | Python | Day 10 Binary Numbers.py | rajnish-13547/Hackerrank-30-day-Code | ef3a754e39b9902ac9b6b0b728e11296f22cd054 | [
"Apache-2.0"
] | null | null | null | Day 10 Binary Numbers.py | rajnish-13547/Hackerrank-30-day-Code | ef3a754e39b9902ac9b6b0b728e11296f22cd054 | [
"Apache-2.0"
] | null | null | null | Day 10 Binary Numbers.py | rajnish-13547/Hackerrank-30-day-Code | ef3a754e39b9902ac9b6b0b728e11296f22cd054 | [
"Apache-2.0"
] | null | null | null | #!/bin/python3
import math
import os
import random
import re
import sys
if __name__ == '__main__':
n = int(input().strip())
out = bin(n)[2:].split('0') #bin binarizes into form '0b----' where ---- is binary representataion
out = len(max(out)) # choosing maximum length of string as '11' > ... | 20.058824 | 103 | 0.607038 |
20914f481667d4d16d02db12f46ade70ba6a337e | 836 | py | Python | vim/del_mq_transfer.py | quentin-wang/audioset_classification | b21887484a94babd4613b01368edeb86706bdd37 | [
"MIT"
] | 2 | 2020-04-05T21:24:39.000Z | 2021-06-04T09:03:58.000Z | vim/del_mq_transfer.py | quentin-wang/audioset_classification | b21887484a94babd4613b01368edeb86706bdd37 | [
"MIT"
] | 13 | 2020-01-28T22:01:40.000Z | 2021-12-13T19:51:09.000Z | vim/del_mq_transfer.py | quentin-wang/audioset_classification | b21887484a94babd4613b01368edeb86706bdd37 | [
"MIT"
] | 1 | 2021-07-06T21:12:15.000Z | 2021-07-06T21:12:15.000Z | # -*- coding=utf-8 -*-
import pika
import sys
import numpy as np
import pickle
credentials = pika.PlainCredentials('myuser', 'mypassword')
with pika.BlockingConnection(
pika.ConnectionParameters('ice-P910',5672,'myvhost',
credentials)) as connection:
# connection = pika.BlockingConnection(pika.Connection... | 32.153846 | 87 | 0.735646 |
20915d22a85cdbcd4b2ea977314aae79038fd886 | 225 | py | Python | api/base/serializers.py | felliott/SHARE | 8fd60ff4749349c9b867f6188650d71f4f0a1a56 | [
"Apache-2.0"
] | 87 | 2015-01-06T18:24:45.000Z | 2021-08-08T07:59:40.000Z | api/base/serializers.py | fortress-biotech/SHARE | 9c5a05dd831447949fa6253afec5225ff8ab5d4f | [
"Apache-2.0"
] | 442 | 2015-01-01T19:16:01.000Z | 2022-03-30T21:10:26.000Z | api/base/serializers.py | fortress-biotech/SHARE | 9c5a05dd831447949fa6253afec5225ff8ab5d4f | [
"Apache-2.0"
] | 67 | 2015-03-10T16:32:58.000Z | 2021-11-12T16:33:41.000Z | from rest_framework_json_api import serializers
__all__ = ('ShareSerializer', )
| 25 | 88 | 0.795556 |
20920539583830803e507b6abeed56abf3e464c5 | 114 | py | Python | config.py | hyhplus/FlaskFirstDemo | 4db0a374b32e58bba841e5a499535a8aa34e9237 | [
"Apache-2.0"
] | null | null | null | config.py | hyhplus/FlaskFirstDemo | 4db0a374b32e58bba841e5a499535a8aa34e9237 | [
"Apache-2.0"
] | null | null | null | config.py | hyhplus/FlaskFirstDemo | 4db0a374b32e58bba841e5a499535a8aa34e9237 | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
DATABASE = 'db/user.db'
DEBUG = True
SECRET_KEY = 'secret_key_1'
| 14.25 | 27 | 0.640351 |
20943719a2fcad2a95774d69c03867118816c653 | 599 | py | Python | txt2sh.py | pib/gpio_ssd1306 | 7897e117529a57df2ea810ae2dad2756b3ea193f | [
"MIT"
] | 2 | 2016-05-24T14:16:37.000Z | 2018-09-25T06:35:55.000Z | txt2sh.py | pib/gpio_ssd1306 | 7897e117529a57df2ea810ae2dad2756b3ea193f | [
"MIT"
] | null | null | null | txt2sh.py | pib/gpio_ssd1306 | 7897e117529a57df2ea810ae2dad2756b3ea193f | [
"MIT"
] | null | null | null | import sys
lines = [l.rstrip() for l in open(sys.argv[1]).readlines() if len(l.rstrip()) > 0]
if len(lines) > 64:
print "Max 64 lines"
sys.exit(1)
lines.extend([""] * (64 % len(lines))) # Pad out to 64 lines
cols = max(len(l) for l in lines)
if cols > 128:
print "Max 128 columns"
sys.exit(1)
for i in ... | 28.52381 | 82 | 0.562604 |
20947dad3cda2fd32b55ac90d29dde10b443304e | 2,704 | py | Python | models.py | RidleyLeisy/data-science-1 | bdb0ce1d5b01e2ee0b6b455c9382638cce0027e2 | [
"MIT"
] | null | null | null | models.py | RidleyLeisy/data-science-1 | bdb0ce1d5b01e2ee0b6b455c9382638cce0027e2 | [
"MIT"
] | 3 | 2021-02-08T20:34:21.000Z | 2021-06-02T00:21:00.000Z | models.py | RidleyLeisy/data-science-1 | bdb0ce1d5b01e2ee0b6b455c9382638cce0027e2 | [
"MIT"
] | 1 | 2019-08-28T21:51:14.000Z | 2019-08-28T21:51:14.000Z | import pandas as pd
import numpy as np
from sklearn.pipeline import Pipeline
import category_encoders as ce
from scipy.spatial.distance import cdist
from sklearn.externals import joblib
from db_helper import DbHelper
cols = ['column_a', 'player', 'all_nba', 'all_star', 'draft_yr','pk','team', 'college', 'yrs', 'gam... | 37.041096 | 120 | 0.640902 |
20955b537db28fcb9f49cbce39f463fbee44592c | 5,692 | py | Python | third_party/dimorphite_dl/acid_base_pairs.py | uta-smile/CD-MVGNN | b48f4cd14befed298980a83edb417ab6809f0af6 | [
"MIT"
] | 3 | 2022-02-06T09:13:51.000Z | 2022-02-19T15:03:35.000Z | third_party/dimorphite_dl/acid_base_pairs.py | uta-smile/CD-MVGNN | b48f4cd14befed298980a83edb417ab6809f0af6 | [
"MIT"
] | 1 | 2022-02-14T23:16:27.000Z | 2022-02-14T23:16:27.000Z | third_party/dimorphite_dl/acid_base_pairs.py | uta-smile/CD-MVGNN | b48f4cd14befed298980a83edb417ab6809f0af6 | [
"MIT"
] | null | null | null | from third_party.molvs.charge import AcidBasePair
from rdkit import Chem
pair_string = """Nitro [C,c,N,n,O,o:1]-[NX3:2](=[O:3])-[O-1:4] [C,c,N,n,O,o:1]-[NX3:2](=[O:3])-[O:4]-[H] 3
Sulfate [SX4:1](=[O:2])(=[O:3])([O:4]-[C,c,N,n:5])-[O-1:6] [SX4:1](=[O:2])(=[O:3])([O:4]-[C,c,N,n:5])-[OX2:6]-[H] 5
Sulfonate [SX4:1](=[O:2... | 56.356436 | 230 | 0.500703 |
2096856b33bf00dedb67422295e6927b9ab0e166 | 854 | py | Python | aggregate/color_videos.py | isaiahnields/attention.ai | 96fe8d738e4fc36f05e6c72e2f1fcdd7a4048261 | [
"MIT"
] | 8 | 2019-02-12T07:07:42.000Z | 2022-03-02T08:13:01.000Z | aggregate/color_videos.py | isaiahnields/attention.ai | 96fe8d738e4fc36f05e6c72e2f1fcdd7a4048261 | [
"MIT"
] | 7 | 2020-01-28T22:06:03.000Z | 2022-02-09T23:29:48.000Z | aggregate/color_videos.py | isaiahnields/attention.ai | 96fe8d738e4fc36f05e6c72e2f1fcdd7a4048261 | [
"MIT"
] | 8 | 2019-02-12T07:07:46.000Z | 2021-09-21T13:37:19.000Z | import cv2
from os import listdir
from os.path import isfile, join
import numpy as np
from math import sin, pi
paths = [f for f in listdir('combined_videos') if isfile(join('combined_videos', f))]
preds = np.load('agg_preds.npy')
preds = np.sqrt(preds)
for i in range(len(paths)):
ps = preds[i, :]
cap = cv2.V... | 26.6875 | 85 | 0.533958 |
2096b0b7ee6813ddc0e5f25a4499c5eee7710cfc | 701 | py | Python | phillydata/reversion_utils.py | ebrelsford/django-phillydata | 444a3ff9d436cd276530534642dd092402278ba5 | [
"BSD-3-Clause"
] | null | null | null | phillydata/reversion_utils.py | ebrelsford/django-phillydata | 444a3ff9d436cd276530534642dd092402278ba5 | [
"BSD-3-Clause"
] | null | null | null | phillydata/reversion_utils.py | ebrelsford/django-phillydata | 444a3ff9d436cd276530534642dd092402278ba5 | [
"BSD-3-Clause"
] | 1 | 2020-01-23T04:59:36.000Z | 2020-01-23T04:59:36.000Z | from django.utils.importlib import import_module
from reversion import default_revision_manager
| 29.208333 | 74 | 0.619116 |
2096bbd23d6d1eb8cd8c79333789419dd5da64b5 | 120 | py | Python | bind/__init__.py | PowerOlive/bind | dca84228b43b0bf93580d5ae9c4fd1a79bce42c5 | [
"MIT"
] | 2 | 2018-07-18T11:37:37.000Z | 2019-05-03T11:37:13.000Z | bind/__init__.py | PowerOlive/bind | dca84228b43b0bf93580d5ae9c4fd1a79bce42c5 | [
"MIT"
] | 3 | 2018-10-22T15:19:32.000Z | 2019-06-01T15:06:26.000Z | bind/__init__.py | PowerOlive/bind | dca84228b43b0bf93580d5ae9c4fd1a79bce42c5 | [
"MIT"
] | 4 | 2019-05-03T11:37:21.000Z | 2020-08-07T08:10:24.000Z | from .bind import bind # noqa
__version__ = '3.0.0' # DO NOT EDIT THIS LINE MANUALLY. LET bump2version UTILITY DO IT
| 30 | 87 | 0.725 |
2099d8a4a1df272a200a2b4774039e76e7ba0d00 | 5,909 | py | Python | src/beansapplicationmgr.py | primroses/docklet | 6c42a472a8b427496c03fad18b873cb4be219db3 | [
"BSD-3-Clause"
] | null | null | null | src/beansapplicationmgr.py | primroses/docklet | 6c42a472a8b427496c03fad18b873cb4be219db3 | [
"BSD-3-Clause"
] | null | null | null | src/beansapplicationmgr.py | primroses/docklet | 6c42a472a8b427496c03fad18b873cb4be219db3 | [
"BSD-3-Clause"
] | null | null | null | #!/usr/bin/python3
'''
This module consists of three parts:
1.send_beans_email: a function to send email to remind users of their beans.
2.ApplicationMgr: a class that will deal with users' requests about beans application.
3.ApprovalRobot: a automatic robot to examine and approve users' applications.
'''
import t... | 39.657718 | 137 | 0.616517 |
209a7c9fd12e2cce719dba7f8f99eed34a7d71a3 | 863 | py | Python | Chapter03/Cisco/cisco_nxapi_4.py | stavsta/Mastering-Python-Networking-Second-Edition | 9999d2e415a1eb9c653ac3507500da7ddac2b556 | [
"MIT"
] | 107 | 2017-03-31T09:39:47.000Z | 2022-01-10T17:43:12.000Z | Chapter03/Cisco/cisco_nxapi_4.py | muzhang90/Mastering-Python-Networking-Third-Edition | f8086fc9a28e441cf8c31099d16839c2e868c7fc | [
"MIT"
] | 3 | 2020-03-29T14:14:43.000Z | 2020-10-29T18:21:09.000Z | Chapter03/Cisco/cisco_nxapi_4.py | muzhang90/Mastering-Python-Networking-Third-Edition | f8086fc9a28e441cf8c31099d16839c2e868c7fc | [
"MIT"
] | 98 | 2017-02-25T17:55:43.000Z | 2022-02-20T19:06:06.000Z | #!/usr/bin/env python3
import requests
import json
url='http://172.16.1.90/ins'
switchuser='cisco'
switchpassword='cisco'
myheaders={'content-type':'application/json-rpc'}
payload=[
{
"jsonrpc": "2.0",
"method": "cli",
"params": {
"cmd": "interface ethernet 2/12",
"version": 1.2
},
... | 15.981481 | 113 | 0.505214 |
209acd05a3b02a15fcea937bc6fde4ebaf25e231 | 7,684 | py | Python | poli/python/poli/modal.py | Humhu/percepto | 4a45cce7dd294a8ce0b962bb68cae5c2b48c3b7f | [
"AFL-3.0"
] | 1 | 2021-06-15T09:34:24.000Z | 2021-06-15T09:34:24.000Z | poli/python/poli/modal.py | Humhu/percepto | 4a45cce7dd294a8ce0b962bb68cae5c2b48c3b7f | [
"AFL-3.0"
] | null | null | null | poli/python/poli/modal.py | Humhu/percepto | 4a45cce7dd294a8ce0b962bb68cae5c2b48c3b7f | [
"AFL-3.0"
] | null | null | null | """This policy contains classes for modal policies.
"""
import numpy as np
from sklearn.cluster import KMeans
#from sklearn.svm import SVC, SVR
#from sklearn.naive_bayes import GaussianNB
from sklearn.neighbors import KNeighborsClassifier
from sklearn.neighbors.kde import KernelDensity
from poli import importance_sa... | 34.769231 | 95 | 0.593441 |
209ba14e1d9e24a86fee89293a465d6242084374 | 1,510 | py | Python | website/__init__.py | oforiwaasam/bookshub | 5c83422971f4abdc5fe18d9b088ed3ca5a230636 | [
"MIT"
] | null | null | null | website/__init__.py | oforiwaasam/bookshub | 5c83422971f4abdc5fe18d9b088ed3ca5a230636 | [
"MIT"
] | null | null | null | website/__init__.py | oforiwaasam/bookshub | 5c83422971f4abdc5fe18d9b088ed3ca5a230636 | [
"MIT"
] | null | null | null | from os import path, environ
from flask import Flask
from flask_sqlalchemy import SQLAlchemy
from flask_login import LoginManager
# Define a new database below
db = SQLAlchemy()
DB_NAME = "site.db"
login_manager = LoginManager()
# you can also create the database here | 34.318182 | 154 | 0.72649 |
209bcc7136e45237b3ef4f72a6a5d6341d1f6455 | 31 | py | Python | ofdft_ml/statslib/data_loader/__init__.py | HamletWantToCode/ofdft-ml | 4115405b6f530cdf8956d0b5b353569ce7c09496 | [
"MIT"
] | 6 | 2019-01-16T07:00:27.000Z | 2022-03-18T07:09:25.000Z | ofdft_ml/statslib/data_loader/__init__.py | HamletWantToCode/ofdft-ml | 4115405b6f530cdf8956d0b5b353569ce7c09496 | [
"MIT"
] | null | null | null | ofdft_ml/statslib/data_loader/__init__.py | HamletWantToCode/ofdft-ml | 4115405b6f530cdf8956d0b5b353569ce7c09496 | [
"MIT"
] | null | null | null | from .dataloader import Dataset | 31 | 31 | 0.870968 |
209bd889393f7e101ff66a22355ff5e0d930a797 | 1,230 | py | Python | python/ql/test/experimental/query-tests/Security/CWE-079/smtplib_bad_subparts.py | RasmusWL/ql | 298f4ab899dcb12414d4fd5112956b82effd140f | [
"MIT"
] | null | null | null | python/ql/test/experimental/query-tests/Security/CWE-079/smtplib_bad_subparts.py | RasmusWL/ql | 298f4ab899dcb12414d4fd5112956b82effd140f | [
"MIT"
] | 4 | 2022-02-17T06:25:43.000Z | 2022-02-23T15:55:30.000Z | python/ql/test/experimental/query-tests/Security/CWE-079/smtplib_bad_subparts.py | jketema/codeql | 09578015886a0c59c2d21c9d09d565742803a5a4 | [
"MIT"
] | null | null | null | # This test checks that the developer doesn't pass a MIMEText instance to a MIMEMultipart initializer via the subparts parameter.
from flask import Flask, request
import json
import smtplib
import ssl
from email.mime.text import MIMEText
from email.mime.multipart import MIMEMultipart
app = Flask(__name__)
# if __na... | 28.604651 | 129 | 0.710569 |
209d3f8143bb0c9a52bff1f3e1c1e5bf2dd136e1 | 1,072 | py | Python | tests/testOptArg.py | miniufo/xinvert | 5fec8586730ec16646304d3eedae1cd501f0673b | [
"MIT"
] | 4 | 2021-05-29T14:56:24.000Z | 2022-03-30T11:54:32.000Z | tests/testOptArg.py | miniufo/xinvert | 5fec8586730ec16646304d3eedae1cd501f0673b | [
"MIT"
] | null | null | null | tests/testOptArg.py | miniufo/xinvert | 5fec8586730ec16646304d3eedae1cd501f0673b | [
"MIT"
] | 2 | 2021-11-22T10:27:21.000Z | 2022-03-30T11:54:33.000Z | # -*- coding: utf-8 -*-
"""
Created on 2020.12.19
@author: MiniUFO
Copyright 2018. All rights reserved. Use is subject to license terms.
"""
#%% load data
import xarray as xr
import numpy as np
nx, ny = 100, 100
gridx = xr.DataArray(np.arange(nx), dims=['X'], coords={'X': np.arange(nx)})
gridy = xr.DataArray(np.aran... | 22.808511 | 80 | 0.649254 |
209db664ddb0050867ee984f6e1fa194d70e545b | 867 | py | Python | main/migrations/0007_auto_20210116_0038.py | Arts-Technology-Lab/exp_taste | 291d26894c534a82379252d1af1b9b0b321fc71b | [
"MIT"
] | null | null | null | main/migrations/0007_auto_20210116_0038.py | Arts-Technology-Lab/exp_taste | 291d26894c534a82379252d1af1b9b0b321fc71b | [
"MIT"
] | null | null | null | main/migrations/0007_auto_20210116_0038.py | Arts-Technology-Lab/exp_taste | 291d26894c534a82379252d1af1b9b0b321fc71b | [
"MIT"
] | 1 | 2021-09-01T03:16:10.000Z | 2021-09-01T03:16:10.000Z | # Generated by Django 3.0.10 on 2021-01-16 00:38
from django.db import migrations, models
| 30.964286 | 134 | 0.60323 |
209dd913bd69c44b411f4ac37d2ead791d37fb9b | 1,451 | py | Python | scripts/plot_solutions.py | sovrasov/linear_sde_solver | 50a7248d9472889523e59c26b1c6448b8ce220da | [
"MIT"
] | null | null | null | scripts/plot_solutions.py | sovrasov/linear_sde_solver | 50a7248d9472889523e59c26b1c6448b8ce220da | [
"MIT"
] | null | null | null | scripts/plot_solutions.py | sovrasov/linear_sde_solver | 50a7248d9472889523e59c26b1c6448b8ce220da | [
"MIT"
] | null | null | null | import argparse
import os
import sys
import json
import pylab as pl
import numpy as np
if __name__ == '__main__':
parser = argparse.ArgumentParser(description='')
parser.add_argument('solution_files', type=str, nargs='+')
parser.add_argument('--average', action='store_true')
main(parser.parse_args(... | 29.02 | 98 | 0.535493 |
209ef0d114b6e2246d0313cca7bc6428bd8f1b6f | 2,275 | py | Python | lottery/db/MySqlUtil.py | DEAN-Lee/py_tools | 96968a5c5be3fa5e293671588ad7ec75cb0910f8 | [
"MIT"
] | null | null | null | lottery/db/MySqlUtil.py | DEAN-Lee/py_tools | 96968a5c5be3fa5e293671588ad7ec75cb0910f8 | [
"MIT"
] | 1 | 2021-01-08T08:40:54.000Z | 2021-01-08T08:40:54.000Z | lottery/db/MySqlUtil.py | DEAN-Lee/py_tools | 96968a5c5be3fa5e293671588ad7ec75cb0910f8 | [
"MIT"
] | null | null | null | import pymysql
import time
from lottery.conf import common_data
| 30.743243 | 85 | 0.491429 |
20a178a7f03998c835263b3fd062485db5864e1a | 398 | py | Python | operacion/migrations/0005_remove_turno_hora_inicio.py | exildev/Rondax | a4a4cad4ec9c575a288f66a353e07e9a57362ede | [
"Apache-2.0"
] | null | null | null | operacion/migrations/0005_remove_turno_hora_inicio.py | exildev/Rondax | a4a4cad4ec9c575a288f66a353e07e9a57362ede | [
"Apache-2.0"
] | null | null | null | operacion/migrations/0005_remove_turno_hora_inicio.py | exildev/Rondax | a4a4cad4ec9c575a288f66a353e07e9a57362ede | [
"Apache-2.0"
] | null | null | null | # -*- coding: utf-8 -*-
# Generated by Django 1.10.1 on 2016-09-08 15:20
from __future__ import unicode_literals
from django.db import migrations
| 19.9 | 48 | 0.61809 |
20a2e7e453f2ab360ec62bed41bb72c2802359a4 | 1,381 | py | Python | utils/py_utils.py | KAIST-AILab/PyOpenDial | c9bca653c18ccc082dc8b86b4a8feee9ed00a75b | [
"MIT"
] | 9 | 2019-09-23T01:56:43.000Z | 2022-03-13T17:58:40.000Z | utils/py_utils.py | KAIST-AILab/PyOpenDial | c9bca653c18ccc082dc8b86b4a8feee9ed00a75b | [
"MIT"
] | 2 | 2019-11-18T17:02:30.000Z | 2021-07-14T15:47:08.000Z | utils/py_utils.py | KAIST-AILab/PyOpenDial | c9bca653c18ccc082dc8b86b4a8feee9ed00a75b | [
"MIT"
] | 1 | 2022-02-08T06:41:19.000Z | 2022-02-08T06:41:19.000Z | import time
import threading
| 24.22807 | 116 | 0.616944 |
20a392002d1e2c2127d30a148baaa0e429a4ea95 | 2,493 | py | Python | interestCalculatorNew.py | Heliodex/PythonCalculators | ab360d79b9e0a503fbb34adfdfa2e2e557097aad | [
"Unlicense"
] | null | null | null | interestCalculatorNew.py | Heliodex/PythonCalculators | ab360d79b9e0a503fbb34adfdfa2e2e557097aad | [
"Unlicense"
] | null | null | null | interestCalculatorNew.py | Heliodex/PythonCalculators | ab360d79b9e0a503fbb34adfdfa2e2e557097aad | [
"Unlicense"
] | null | null | null | # Heliodex 2021/08/24
# Last edited 2022/02/16 -- count number of steps and add reverse mode
# edit of vatRemover
# uses Short Method
print("Calculates amount after adding a percentage a number of times")
while True:
c = input("1 for normal, 2 for reverse, 3 for catchup ")
if c == "1":
val =... | 28.011236 | 71 | 0.441637 |
20a3b0acfd3632b1e52670412907b6db19696003 | 2,623 | py | Python | src/pylexibank/commands/init_profile.py | martino-vic/pylexibank | eefbfbb1754e85264a9fe98fefbcf5df254ad19a | [
"Apache-2.0"
] | 6 | 2019-11-04T09:15:34.000Z | 2022-02-19T23:02:51.000Z | src/pylexibank/commands/init_profile.py | martino-vic/pylexibank | eefbfbb1754e85264a9fe98fefbcf5df254ad19a | [
"Apache-2.0"
] | 228 | 2018-04-13T09:39:20.000Z | 2022-03-08T23:30:46.000Z | src/pylexibank/commands/init_profile.py | martino-vic/pylexibank | eefbfbb1754e85264a9fe98fefbcf5df254ad19a | [
"Apache-2.0"
] | 5 | 2019-07-10T04:53:15.000Z | 2022-03-07T01:43:23.000Z | """
Create an initial orthography profile, seeded from the forms created by a first run
of lexibank.makecldf.
"""
from lingpy import Wordlist
from lingpy.sequence import profile
from cldfbench.cli_util import get_dataset, add_catalog_spec
from csvw.dsv import UnicodeWriter
from clldutils.clilib import ParserError
from... | 33.628205 | 97 | 0.629813 |
20a60c00e978fa11291e28ff7b092caf77628614 | 9,537 | py | Python | Source/ThirdParty/angle/testing/legion/lib/rpc/jsonrpclib.py | elix22/Urho3D | 99902ae2a867be0d6dbe4c575f9c8c318805ec64 | [
"MIT"
] | 20 | 2019-04-18T07:37:34.000Z | 2022-02-02T21:43:47.000Z | testing/legion/lib/rpc/jsonrpclib.py | lyapple2008/webrtc_simplify | c4f9bdc72d8e2648c4f4b1934d22ae94a793b553 | [
"BSD-3-Clause"
] | 11 | 2019-10-21T13:39:41.000Z | 2021-11-05T08:11:54.000Z | testing/legion/lib/rpc/jsonrpclib.py | lyapple2008/webrtc_simplify | c4f9bdc72d8e2648c4f4b1934d22ae94a793b553 | [
"BSD-3-Clause"
] | 1 | 2021-12-03T18:11:36.000Z | 2021-12-03T18:11:36.000Z | # Copyright 2014 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
"""Module to implement the JSON-RPC protocol.
This module uses xmlrpclib as the base and only overrides those
portions that implement the XML-RPC protocol. ... | 25.5 | 79 | 0.676838 |
20a8a073cd2c94b8099ac2c571da041af73d129b | 21,838 | py | Python | src/third_party/ffmpeg/chromium/scripts/build_ffmpeg.py | neeker/chromium_extract | 0f9a0206a1876e98cf69e03869983e573138284c | [
"BSD-3-Clause"
] | 27 | 2016-04-27T01:02:03.000Z | 2021-12-13T08:53:19.000Z | src/third_party/ffmpeg/chromium/scripts/build_ffmpeg.py | neeker/chromium_extract | 0f9a0206a1876e98cf69e03869983e573138284c | [
"BSD-3-Clause"
] | 2 | 2017-03-09T09:00:50.000Z | 2017-09-21T15:48:20.000Z | src/third_party/ffmpeg/chromium/scripts/build_ffmpeg.py | neeker/chromium_extract | 0f9a0206a1876e98cf69e03869983e573138284c | [
"BSD-3-Clause"
] | 17 | 2016-04-27T02:06:39.000Z | 2019-12-18T08:07:00.000Z | #!/usr/bin/env python
#
# Copyright 2014 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
from __future__ import print_function
import collections
import multiprocessing
import optparse
import os
import platform
import re
... | 34.773885 | 81 | 0.61512 |
20ab340c51fea34db17694c288889d5ae11f982b | 340 | py | Python | res_cookie.py | HLRJ/py-crawler | 326128f8aa8e83cb7a142a31efedc7d944dac4da | [
"MIT"
] | 1 | 2022-03-29T16:01:41.000Z | 2022-03-29T16:01:41.000Z | res_cookie.py | HLRJ/py-crawler | 326128f8aa8e83cb7a142a31efedc7d944dac4da | [
"MIT"
] | null | null | null | res_cookie.py | HLRJ/py-crawler | 326128f8aa8e83cb7a142a31efedc7d944dac4da | [
"MIT"
] | 1 | 2022-03-29T16:02:10.000Z | 2022-03-29T16:02:10.000Z | import requests
# cookie
#
session = requests.session()
data = {
"" : "########",
"" : "########"
}
url = ""
res = session.post(url, data=data)
print(res.text)
res = session.get(url)
# resquests
header = {
"user-agent" : "dddd",
"Cookie" : "url"
}
resp = requests.get(url,headers=header)
print(res... | 14.166667 | 39 | 0.576471 |
20af13f324e132c3a20d60cbd72a4f1adb5b9083 | 13,891 | py | Python | Auto Scroller - Python/venv/lib/python3.8/site-packages/listener/daemon.py | Nischal200/Music-Lyrics-Auto-Scroller | 92663e13451022a1500bfe56dff479dd0b3f1cac | [
"MIT"
] | null | null | null | Auto Scroller - Python/venv/lib/python3.8/site-packages/listener/daemon.py | Nischal200/Music-Lyrics-Auto-Scroller | 92663e13451022a1500bfe56dff479dd0b3f1cac | [
"MIT"
] | null | null | null | Auto Scroller - Python/venv/lib/python3.8/site-packages/listener/daemon.py | Nischal200/Music-Lyrics-Auto-Scroller | 92663e13451022a1500bfe56dff479dd0b3f1cac | [
"MIT"
] | null | null | null | #! /usr/bin/env python3
"""process which runs inside the docker daemon
the purpose of the doctor damon process is to allow the set up of
an environment which will support the deep speech recognition engine
to run on any recent nvidia Ubuntu host.
the basic operation of the demon is to create a named pipe
in the users... | 35.346056 | 146 | 0.608452 |
20b0cb026df5e39e3d7cf7213155978963ec27ea | 314 | py | Python | python/day05.py | narimiran/AdventOfCode2019 | 7ca324ab6f292a93e3ab2327e9377eae2e462004 | [
"MIT"
] | 2 | 2019-12-05T08:39:34.000Z | 2019-12-26T15:45:10.000Z | python/day05.py | narimiran/AdventOfCode2019 | 7ca324ab6f292a93e3ab2327e9377eae2e462004 | [
"MIT"
] | null | null | null | python/day05.py | narimiran/AdventOfCode2019 | 7ca324ab6f292a93e3ab2327e9377eae2e462004 | [
"MIT"
] | null | null | null | from intcode import *
instructions = read_intcode_input(5)
print(solve(instructions, 1))
print(solve(instructions, 2))
| 19.625 | 45 | 0.703822 |
20b1b21ec139b97e272ccfb76245282c96f81627 | 3,736 | py | Python | client.py | NordCox/Nordcox-Bot | 3ed83bfdc10523cdcbfd13a0f45d3d68f3df056c | [
"MIT"
] | 7 | 2017-04-26T20:49:46.000Z | 2017-06-02T01:08:00.000Z | client.py | NordCox/Nordcox-Bot | 3ed83bfdc10523cdcbfd13a0f45d3d68f3df056c | [
"MIT"
] | 9 | 2017-04-26T16:22:59.000Z | 2018-07-16T18:21:50.000Z | client.py | NordCox/Nordcox-Bot | 3ed83bfdc10523cdcbfd13a0f45d3d68f3df056c | [
"MIT"
] | 11 | 2017-06-02T03:46:29.000Z | 2019-02-27T21:20:06.000Z | import logging
import threading
import time
import pinylib
log = logging.getLogger(__name__)
if __name__ == '__main__':
if pinylib.CONFIG.DEBUG_TO_FILE:
formater = '%(asctime)s : %(levelname)s : %(filename)s : %(lineno)d : %(funcName)s() : %(name)s : %(message)s'
logging.basicConfig(filename=piny... | 38.122449 | 118 | 0.523287 |
20b1e4ce9fc466a2b7e51f104d05fa8d81c11041 | 23,645 | py | Python | nifpga/session.py | auchter/nifpga-python | d24ac338ec9b9d1bb94f1c8b8d06643670289e9e | [
"MIT"
] | null | null | null | nifpga/session.py | auchter/nifpga-python | d24ac338ec9b9d1bb94f1c8b8d06643670289e9e | [
"MIT"
] | null | null | null | nifpga/session.py | auchter/nifpga-python | d24ac338ec9b9d1bb94f1c8b8d06643670289e9e | [
"MIT"
] | 1 | 2020-09-19T15:44:08.000Z | 2020-09-19T15:44:08.000Z | """
Session, a convenient wrapper around the low-level _NiFpga class.
Copyright (c) 2017 National Instruments
"""
from .nifpga import (_SessionType, _IrqContextType, _NiFpga, DataType,
OPEN_ATTRIBUTE_NO_RUN, RUN_ATTRIBUTE_WAIT_UNTIL_DONE,
CLOSE_ATTRIBUTE_NO_RESET_IF_LAST_SESS... | 39.806397 | 102 | 0.587735 |
20b1f01b27ef48f6d139f9138e4bcf3552657d52 | 1,822 | py | Python | old/mael_dmg_calc.py | IronHeart7334/Maelstrom | aaea823c393a1cdc908b987ec5a27904322845ce | [
"MIT"
] | null | null | null | old/mael_dmg_calc.py | IronHeart7334/Maelstrom | aaea823c393a1cdc908b987ec5a27904322845ce | [
"MIT"
] | null | null | null | old/mael_dmg_calc.py | IronHeart7334/Maelstrom | aaea823c393a1cdc908b987ec5a27904322845ce | [
"MIT"
] | null | null | null | TOTAL = 1000
ask() | 18.039604 | 68 | 0.588913 |
20b28d884d7b7314d9f1c0fd125fd2bca1b74c56 | 2,439 | py | Python | in-app-payments-with-server-validation/backend-appengine/jwt/__init__.py | Acidburn0zzz/chrome-app-samples | 53c3184d3ff210918a5d9c7420dd2a92c0870cf5 | [
"Apache-2.0"
] | 16 | 2019-08-08T02:04:54.000Z | 2019-10-15T17:52:36.000Z | in-app-payments-with-server-validation/backend-appengine/jwt/__init__.py | Acidburn0zzz/chrome-app-samples | 53c3184d3ff210918a5d9c7420dd2a92c0870cf5 | [
"Apache-2.0"
] | null | null | null | in-app-payments-with-server-validation/backend-appengine/jwt/__init__.py | Acidburn0zzz/chrome-app-samples | 53c3184d3ff210918a5d9c7420dd2a92c0870cf5 | [
"Apache-2.0"
] | 8 | 2015-07-04T07:24:08.000Z | 2020-04-27T02:23:49.000Z | """ JSON Web Token implementation
Minimum implementation based on this spec:
http://self-issued.info/docs/draft-jones-json-web-token-01.html
"""
import base64
import hashlib
import hmac
try:
import json
except ImportError:
import simplejson as json
__all__ = ['encode', 'decode', 'DecodeError']
signing_m... | 33.410959 | 89 | 0.678147 |
20b37fe078b398c2a89ecdde10b0aa1f69e2a0fc | 4,931 | py | Python | app/models/attribute.py | hack4impact/women-veterans-rock | 7de5f5645819dbe67ba71a1f0b29f84a45e35789 | [
"MIT"
] | 16 | 2015-10-26T20:30:35.000Z | 2017-02-01T01:45:35.000Z | app/models/attribute.py | hack4impact/women-veterans-rock | 7de5f5645819dbe67ba71a1f0b29f84a45e35789 | [
"MIT"
] | 34 | 2015-10-21T02:58:42.000Z | 2017-02-24T06:57:07.000Z | app/models/attribute.py | hack4impact/women-veterans-rock | 7de5f5645819dbe67ba71a1f0b29f84a45e35789 | [
"MIT"
] | 1 | 2015-10-23T21:32:28.000Z | 2015-10-23T21:32:28.000Z | from .. import db
user_tag_associations_table = db.Table(
'user_tag_associations', db.Model.metadata,
db.Column('tag_id', db.Integer, db.ForeignKey('tags.id')),
db.Column('user_id', db.Integer, db.ForeignKey('users.id'))
)
resource_tag_associations_table = db.Table(
'resource_tag_associations', db.Mod... | 33.773973 | 78 | 0.608801 |
20b557e25c85bd79516024b5db25efc8be4b20b6 | 2,631 | py | Python | python/wlu_lr/CNN.py | GG-yuki/bugs | aabd576e9e57012a3390007af890b7c6ab6cdda8 | [
"MIT"
] | null | null | null | python/wlu_lr/CNN.py | GG-yuki/bugs | aabd576e9e57012a3390007af890b7c6ab6cdda8 | [
"MIT"
] | null | null | null | python/wlu_lr/CNN.py | GG-yuki/bugs | aabd576e9e57012a3390007af890b7c6ab6cdda8 | [
"MIT"
] | null | null | null | import torch
import torch.nn.functional as F
import matplotlib.pyplot as plt
import numpy
x = torch.unsqueeze(torch.linspace(-1, 1, 300), dim=1) # x data (tensor), shape=(100, 1)
print(x)
y = x.pow(2) + 0.2 * torch.rand(x.size()) # noisy y data (tensor), shape=(100, 1)
plt.scatter(x.data.numpy(), y.data.numpy())
plt... | 32.085366 | 113 | 0.625618 |
20b5b58aed3d21c4c4915daa30f4e8dbda82f3a5 | 650 | py | Python | 4_PersistanceBugger.py | joanzhu728/Codewar | 13d383957594c926ac5338a20d760f614271beab | [
"MIT"
] | null | null | null | 4_PersistanceBugger.py | joanzhu728/Codewar | 13d383957594c926ac5338a20d760f614271beab | [
"MIT"
] | null | null | null | 4_PersistanceBugger.py | joanzhu728/Codewar | 13d383957594c926ac5338a20d760f614271beab | [
"MIT"
] | null | null | null | import codewars_test as test
# import operator
# def persistence(n):
# i = 0
# while n>=10:
# n=reduce(operator.mul,[int(x) for x in str(n)],1)
# i+=1
# return i
test.it("Basic tests")
test.assert_equals(persistence(39), 3)
test.assert_equals(persistence(4), 0)
test.assert_equals(persisten... | 23.214286 | 59 | 0.556923 |
20b5d321129450b24c961028f4c4a899c4e5b34f | 7,440 | py | Python | mechanic/modifier.py | dl-stuff/dl9 | 1cbe98afc53a1de9d413797fb130946acc4b6ba4 | [
"MIT"
] | null | null | null | mechanic/modifier.py | dl-stuff/dl9 | 1cbe98afc53a1de9d413797fb130946acc4b6ba4 | [
"MIT"
] | null | null | null | mechanic/modifier.py | dl-stuff/dl9 | 1cbe98afc53a1de9d413797fb130946acc4b6ba4 | [
"MIT"
] | null | null | null | """
kinds of modifiers
1. Ability Passive
- stat mods
- act damage up/down
- punisher
2. Action condtion (and Aura)
- there's a lot of crap here but they r all additive if same field
- str aura is same as _RateAttack
- certain fields (crit, crit dmg, punisher) are same bracket for w/e reason
3. hitattr
- independent... | 32.920354 | 135 | 0.562366 |
20b7cdbf4698fba9cb58486cf5f4749c946cfd11 | 4,154 | py | Python | ino/argparsing.py | qguv/ino | f23ee5cb14edc30ec087d3eab7b301736da42362 | [
"MIT"
] | 558 | 2015-01-02T08:12:53.000Z | 2022-03-08T17:13:26.000Z | ino/argparsing.py | jboone/ino | 4798827272f6b3916f1fb887e42538a976789d90 | [
"MIT"
] | 84 | 2015-01-01T11:17:27.000Z | 2021-02-11T02:40:23.000Z | ino/argparsing.py | jboone/ino | 4798827272f6b3916f1fb887e42538a976789d90 | [
"MIT"
] | 176 | 2015-01-14T08:59:39.000Z | 2021-06-24T07:41:31.000Z | # -*- coding: utf-8; -*-
# Stolen from: http://bugs.python.org/issue12806
import argparse
import re
import textwrap
if __name__ == '__main__':
parser = argparse.ArgumentParser(formatter_class=FlexiFormatter)
parser.add_argument('--example', help='''\
This argument's help text will have this first long... | 41.54 | 78 | 0.553683 |
20b85e774f4f333362b32f59f4d25bf560a3cebc | 6,997 | py | Python | NN_buildingblock/ConvNN.py | xupingxie/deep-learning-models | cc76aedf9631317452f9cd7df38998e2de727816 | [
"MIT"
] | null | null | null | NN_buildingblock/ConvNN.py | xupingxie/deep-learning-models | cc76aedf9631317452f9cd7df38998e2de727816 | [
"MIT"
] | null | null | null | NN_buildingblock/ConvNN.py | xupingxie/deep-learning-models | cc76aedf9631317452f9cd7df38998e2de727816 | [
"MIT"
] | null | null | null | #!/usr/bin/env python2
# -*- coding: utf-8 -*-
"""
This script contains basic functions for Conv Neural Nets.
foward conv and pooling
backward conv and pooling
@author: xuping
"""
import numpy as np
import h5py
import matplotlib.pyplot as plt
def Conv_forward(A_prev, W, b, para):
'''
This is the forward prop... | 33.319048 | 103 | 0.489924 |
20b8bb3fcf2671b92bff3531ad074b19f746b4aa | 6,682 | py | Python | 00_core.py | DanyWind/fast_neptune | e07c354514df1debdff607584bb042f000f03f31 | [
"Apache-2.0"
] | 5 | 2020-01-28T22:28:36.000Z | 2020-02-22T07:04:52.000Z | 00_core.py | DanyWind/fast_neptune | e07c354514df1debdff607584bb042f000f03f31 | [
"Apache-2.0"
] | 2 | 2021-09-28T00:42:24.000Z | 2022-02-26T06:26:10.000Z | 00_core.py | dhuynh95/fast_neptune | e07c354514df1debdff607584bb042f000f03f31 | [
"Apache-2.0"
] | 2 | 2020-04-28T05:00:38.000Z | 2020-12-04T09:08:03.000Z | #!/usr/bin/env python
# coding: utf-8
# In[1]:
#hide
get_ipython().run_line_magic('load_ext', 'autoreload')
get_ipython().run_line_magic('autoreload', '2')
# In[2]:
# default_exp core
# In[3]:
#export
from nbdev.export import check_re,read_nb
from pathlib import Path
import re
import os
import platform
# #... | 20.623457 | 99 | 0.652649 |
20b99c84a1d02922ac3d349c7b10e48dcaede0db | 4,974 | py | Python | nnf/dsharp.py | vishalbelsare/python-nnf | c2e81fd7851a3d11fff904bf5b4c5e521fde59ab | [
"0BSD"
] | 14 | 2020-07-14T01:51:26.000Z | 2021-12-17T22:45:47.000Z | nnf/dsharp.py | vishalbelsare/python-nnf | c2e81fd7851a3d11fff904bf5b4c5e521fde59ab | [
"0BSD"
] | 26 | 2020-07-14T23:37:52.000Z | 2021-11-04T18:06:38.000Z | nnf/dsharp.py | vishalbelsare/python-nnf | c2e81fd7851a3d11fff904bf5b4c5e521fde59ab | [
"0BSD"
] | 7 | 2020-07-26T10:53:21.000Z | 2021-09-19T00:35:30.000Z | """Interoperability with `DSHARP <https://github.com/QuMuLab/dsharp>`_.
``load`` and ``loads`` can be used to parse files created by DSHARP's
``-Fnnf`` option.
``compile`` invokes DSHARP directly to compile a sentence. This requires
having DSHARP installed.
The parser was derived by studying DSHARP's output and sour... | 32.090323 | 79 | 0.621431 |
20ba293476d59761a6ef6fe44c77fac5699f68be | 4,513 | py | Python | stats/offense.py | wisarut-sirimart/Python-Baseball | f794455d4a217d7684bd86fdff19d1706bf7aab2 | [
"MIT"
] | null | null | null | stats/offense.py | wisarut-sirimart/Python-Baseball | f794455d4a217d7684bd86fdff19d1706bf7aab2 | [
"MIT"
] | null | null | null | stats/offense.py | wisarut-sirimart/Python-Baseball | f794455d4a217d7684bd86fdff19d1706bf7aab2 | [
"MIT"
] | null | null | null | import pandas as pd
import matplotlib.pyplot as plt
from data import games
# Select All Plays
# In the file called offense.py in the stats folder you will find similar imports as the last module.
# Import the games DataFrame from data.
# Now that we have access to the games DataFrame.
# Select all rows that have a type... | 65.405797 | 239 | 0.731886 |
20bada261f2bc5bee2c060bfdfd13f8adc62d780 | 2,156 | py | Python | tests/gmprocess/io/read_test.py | baagaard-usgs/groundmotion-processing | 6be2b4460d598bba0935135efa85af2655578565 | [
"Unlicense"
] | 54 | 2019-01-12T02:05:38.000Z | 2022-03-29T19:43:56.000Z | tests/gmprocess/io/read_test.py | baagaard-usgs/groundmotion-processing | 6be2b4460d598bba0935135efa85af2655578565 | [
"Unlicense"
] | 700 | 2018-12-18T19:44:31.000Z | 2022-03-30T20:54:28.000Z | tests/gmprocess/io/read_test.py | baagaard-usgs/groundmotion-processing | 6be2b4460d598bba0935135efa85af2655578565 | [
"Unlicense"
] | 41 | 2018-11-29T23:17:56.000Z | 2022-03-31T04:04:23.000Z | #!/usr/bin/env python
# -*- coding: utf-8 -*-
# stdlib imports
import os
from gmprocess.io.read import read_data, _get_format, _validate_format
from gmprocess.utils.test_utils import read_data_dir
from gmprocess.utils.config import get_config
if __name__ == "__main__":
os.environ["CALLED_FROM_PYTEST"] = "True"... | 35.344262 | 88 | 0.670223 |
20be3885a4f5f899c0e126b28f81e284e4b6e23c | 633 | py | Python | tests/syft/lib/torch/device_test.py | JMLourier/PySyft | 065a862ca061f9a526af81db5b3ee0d39d4f6407 | [
"MIT"
] | 2 | 2020-03-06T15:51:52.000Z | 2020-03-08T13:14:24.000Z | tests/syft/lib/torch/device_test.py | JMLourier/PySyft | 065a862ca061f9a526af81db5b3ee0d39d4f6407 | [
"MIT"
] | 5 | 2020-12-03T21:06:20.000Z | 2020-12-31T03:46:57.000Z | tests/syft/lib/torch/device_test.py | JMLourier/PySyft | 065a862ca061f9a526af81db5b3ee0d39d4f6407 | [
"MIT"
] | 1 | 2020-12-05T07:22:27.000Z | 2020-12-05T07:22:27.000Z | # third party
import torch as th
# syft absolute
import syft as sy
from syft.core.common.uid import UID
from syft.lib.python import String
| 23.444444 | 59 | 0.709321 |
20bf152d1098acb69e542429f3dd7a20635a56bc | 8,495 | py | Python | clu/periodic_actions_test.py | andsteing/CommonLoopUtils | b39e992f60d041bc77809d859586027700a2c3a9 | [
"Apache-2.0"
] | 80 | 2020-10-11T17:37:52.000Z | 2022-03-30T17:17:05.000Z | clu/periodic_actions_test.py | andsteing/CommonLoopUtils | b39e992f60d041bc77809d859586027700a2c3a9 | [
"Apache-2.0"
] | 22 | 2020-12-18T15:12:04.000Z | 2021-09-24T08:10:23.000Z | clu/periodic_actions_test.py | andsteing/CommonLoopUtils | b39e992f60d041bc77809d859586027700a2c3a9 | [
"Apache-2.0"
] | 10 | 2020-10-13T16:35:30.000Z | 2022-02-08T21:00:00.000Z | # Copyright 2021 The CLU 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 or agreed to in writ... | 30.339286 | 80 | 0.671218 |
20c0713b32c4e888c8d8eba2e53d1e750e99ff54 | 570 | py | Python | _scripts/tools/utils/frontmatter_getter.py | gogntao/gogntao.github.io | ee200345d39521652b8c1cf9d27bcc2a6e02f3ef | [
"MIT"
] | null | null | null | _scripts/tools/utils/frontmatter_getter.py | gogntao/gogntao.github.io | ee200345d39521652b8c1cf9d27bcc2a6e02f3ef | [
"MIT"
] | null | null | null | _scripts/tools/utils/frontmatter_getter.py | gogntao/gogntao.github.io | ee200345d39521652b8c1cf9d27bcc2a6e02f3ef | [
"MIT"
] | null | null | null | #!/usr/bin/env python
# -*- coding: utf-8 -*-
'''
Read the posts and return a tuple that consisting of
Front Matter and its line number.
2018-2019 Cotes Chung
MIT License
'''
| 18.387097 | 52 | 0.452632 |
20c17791d1b4f3f9764ce5a02c3f17aa3c7d9e44 | 1,014 | py | Python | main/cart.py | Dogechi/Me2U | 0852600983dc1058ee347f4065ee801e16c1249e | [
"MIT"
] | null | null | null | main/cart.py | Dogechi/Me2U | 0852600983dc1058ee347f4065ee801e16c1249e | [
"MIT"
] | 9 | 2020-06-06T01:16:25.000Z | 2021-06-04T23:20:37.000Z | main/cart.py | Me2U-Afrika/Me2U | aee054afedff1e6c87f87494eaddf044e217aa95 | [
"MIT"
] | null | null | null | from django.conf import settings
from django.db.models import Max
from datetime import datetime, timedelta
from me2ushop.models import Order, OrderItem
| 36.214286 | 90 | 0.708087 |
20c351d08261a89f6671fb61ae44dfb0f32ca3f0 | 3,658 | py | Python | tasks/python3/processTemporalLayer.py | greck2908/worldview | d17c463080218ce0a3d922be3dc8da5152860391 | [
"NASA-1.3"
] | 1 | 2021-03-01T22:10:14.000Z | 2021-03-01T22:10:14.000Z | tasks/python3/processTemporalLayer.py | greck2908/worldview | d17c463080218ce0a3d922be3dc8da5152860391 | [
"NASA-1.3"
] | 4 | 2021-12-03T00:01:57.000Z | 2022-03-22T21:01:34.000Z | tasks/python3/processTemporalLayer.py | greck2908/worldview | d17c463080218ce0a3d922be3dc8da5152860391 | [
"NASA-1.3"
] | null | null | null | from datetime import datetime
import isodate
import re
import traceback
# Add duration to end date using
# ISO 8601 duration keys
# This method takes a layer and a temporal
# value and tranlates it to start and end dates
| 49.432432 | 161 | 0.541006 |
20c46aef8b21547d823f1dda228583f79f1a470c | 1,162 | py | Python | baal/active/__init__.py | llv22/baal_tf2.4_mac | 6eed225f8b57e61d8d16b1868ea655384c566700 | [
"Apache-2.0"
] | 575 | 2019-09-30T20:44:28.000Z | 2022-03-27T17:39:22.000Z | baal/active/__init__.py | llv22/baal_tf2.4_mac | 6eed225f8b57e61d8d16b1868ea655384c566700 | [
"Apache-2.0"
] | 84 | 2019-10-01T15:58:55.000Z | 2022-03-28T13:27:32.000Z | baal/active/__init__.py | llv22/baal_tf2.4_mac | 6eed225f8b57e61d8d16b1868ea655384c566700 | [
"Apache-2.0"
] | 51 | 2019-10-08T23:05:39.000Z | 2022-02-14T22:13:27.000Z | from typing import Union, Callable
from . import heuristics
from .active_loop import ActiveLearningLoop
from .dataset import ActiveLearningDataset
from .file_dataset import FileDataset
def get_heuristic(
name: str, shuffle_prop: float = 0.0, reduction: Union[str, Callable] = "none", **kwargs
) -> heuristics.Abst... | 33.2 | 92 | 0.69191 |
20c55612c6dde9a99bf02d10377bbecda4d7f7ce | 1,916 | py | Python | migrations/versions/e454b1597ab0_.py | Maybells/PostClassical | cbb45add86463deb942825d3c792bc8b6dcdd29b | [
"MIT"
] | null | null | null | migrations/versions/e454b1597ab0_.py | Maybells/PostClassical | cbb45add86463deb942825d3c792bc8b6dcdd29b | [
"MIT"
] | null | null | null | migrations/versions/e454b1597ab0_.py | Maybells/PostClassical | cbb45add86463deb942825d3c792bc8b6dcdd29b | [
"MIT"
] | null | null | null | """empty message
Revision ID: e454b1597ab0
Revises:
Create Date: 2021-01-19 11:50:17.899068
"""
from alembic import op
import sqlalchemy as sa
# revision identifiers, used by Alembic.
revision = 'e454b1597ab0'
down_revision = None
branch_labels = None
depends_on = None
| 40.765957 | 86 | 0.693111 |
20c5797dd314a61d66fc031c71f6307cee019dde | 81 | py | Python | miniquora/qac/apps.py | rochakgupta/miniquora | 341722806c6d42c7cc1ecfe6ff0254f11e9370c7 | [
"MIT"
] | null | null | null | miniquora/qac/apps.py | rochakgupta/miniquora | 341722806c6d42c7cc1ecfe6ff0254f11e9370c7 | [
"MIT"
] | 6 | 2020-06-05T19:47:55.000Z | 2022-03-11T23:38:53.000Z | miniquora/qac/apps.py | rochakgupta/miniquora | 341722806c6d42c7cc1ecfe6ff0254f11e9370c7 | [
"MIT"
] | null | null | null | from django.apps import AppConfig
| 13.5 | 33 | 0.728395 |
20c609aa615f44f48228ba80019cfecbd7a032e3 | 3,249 | py | Python | config/application.py | dlsaavedra/Web-API | b3ad6d7d7dc7434c630ac4dcff3a805bba5e47a9 | [
"MIT"
] | null | null | null | config/application.py | dlsaavedra/Web-API | b3ad6d7d7dc7434c630ac4dcff3a805bba5e47a9 | [
"MIT"
] | null | null | null | config/application.py | dlsaavedra/Web-API | b3ad6d7d7dc7434c630ac4dcff3a805bba5e47a9 | [
"MIT"
] | null | null | null | from os import getenv
from pathlib import Path
from dotenv import load_dotenv
base_path = Path('.') # Fully qualified path to the project root
env_path = base_path / '.env' # Fully qualified path to the enviroment file
app_path = base_path.joinpath('app') # The fully qualified path to the app fold... | 48.492537 | 100 | 0.492767 |
20c6bab3994c954ecffd3763529c8895304de913 | 72,964 | py | Python | versioned_hdf5/tests/test_api.py | Quansight/versioned-hdf5 | e2d2eb2bbe2eed851239ee9d1ed7a9cf5cee3c55 | [
"BSD-3-Clause"
] | 9 | 2019-12-12T16:04:03.000Z | 2020-06-09T05:18:21.000Z | versioned_hdf5/tests/test_api.py | Quansight/versioned-hdf5 | e2d2eb2bbe2eed851239ee9d1ed7a9cf5cee3c55 | [
"BSD-3-Clause"
] | 64 | 2019-12-13T18:43:13.000Z | 2020-06-11T15:58:07.000Z | versioned_hdf5/tests/test_api.py | Quansight/versioned-hdf5 | e2d2eb2bbe2eed851239ee9d1ed7a9cf5cee3c55 | [
"BSD-3-Clause"
] | 3 | 2020-02-11T18:53:47.000Z | 2020-03-10T21:52:43.000Z | import os
import itertools
from pytest import raises, mark
import h5py
import datetime
import numpy as np
from numpy.testing import assert_equal
from .helpers import setup_vfile
from ..backend import DEFAULT_CHUNK_SIZE
from ..api import VersionedHDF5File
from ..versions import TIMESTAMP_FMT
from ..wrappers import ... | 39.249059 | 118 | 0.638932 |
20c83995292e682498e01d8809458f2de8d3b1a0 | 1,875 | py | Python | faculty/clients/auth.py | jkeelan/faculty | 3cf50f243fba1bfe7a346de88654d3616ac35b15 | [
"Apache-2.0"
] | null | null | null | faculty/clients/auth.py | jkeelan/faculty | 3cf50f243fba1bfe7a346de88654d3616ac35b15 | [
"Apache-2.0"
] | null | null | null | faculty/clients/auth.py | jkeelan/faculty | 3cf50f243fba1bfe7a346de88654d3616ac35b15 | [
"Apache-2.0"
] | null | null | null | # Copyright 2018-2019 Faculty Science 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 License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed... | 30.241935 | 74 | 0.691733 |
20c8dc629ba478e2775bf9fa36b8d56bb2d26c1d | 2,612 | py | Python | ward_mapping/migrations/0001_initial.py | Suraj1127/ward-mapping-application | 53fa39bab875ca47fdab814fd28ea0b7d2086c15 | [
"MIT"
] | 1 | 2019-05-16T04:08:40.000Z | 2019-05-16T04:08:40.000Z | ward_mapping/migrations/0001_initial.py | Suraj1127/ward-mapping-application | 53fa39bab875ca47fdab814fd28ea0b7d2086c15 | [
"MIT"
] | null | null | null | ward_mapping/migrations/0001_initial.py | Suraj1127/ward-mapping-application | 53fa39bab875ca47fdab814fd28ea0b7d2086c15 | [
"MIT"
] | null | null | null | # Generated by Django 2.2 on 2019-05-15 16:43
from django.db import migrations, models
| 46.642857 | 114 | 0.584227 |
20ca4306616ba4229666606128bb772fe88420f6 | 2,704 | py | Python | hangingart/space.py | IanRichardDavies/HangingArt | 94f6321c6e3bd6c73d479a33b6b18d3bfbaf371a | [
"MIT"
] | null | null | null | hangingart/space.py | IanRichardDavies/HangingArt | 94f6321c6e3bd6c73d479a33b6b18d3bfbaf371a | [
"MIT"
] | null | null | null | hangingart/space.py | IanRichardDavies/HangingArt | 94f6321c6e3bd6c73d479a33b6b18d3bfbaf371a | [
"MIT"
] | null | null | null | """
Module concerning Space objects
"""
# Python Libraries
# First Party Imports | 29.714286 | 67 | 0.566938 |
20cc5934d839eb06728df2e30f577167bc2cdc91 | 5,443 | py | Python | main.py | yycho0108/2048_tf | b29a8a20d051a464814957e153ea7c099576bc0a | [
"MIT"
] | 1 | 2017-09-07T22:47:52.000Z | 2017-09-07T22:47:52.000Z | main.py | yycho0108/2048_tf | b29a8a20d051a464814957e153ea7c099576bc0a | [
"MIT"
] | null | null | null | main.py | yycho0108/2048_tf | b29a8a20d051a464814957e153ea7c099576bc0a | [
"MIT"
] | 1 | 2020-04-12T16:12:20.000Z | 2020-04-12T16:12:20.000Z | #!/usr/bin/python
import sys
import numpy as np
import tensorflow as tf
from memory import Memory, MultiMemory
from qnet import *
from layers import *
from game import Game
## Load Parameters
gamma = .99 #Discount factor.
num_episodes = 10000 #Total number of episodes to train network for.
test_episodes = 200 #Total... | 31.645349 | 112 | 0.570825 |
20cca36f0660a5cec8d40a240e5c97178d31a054 | 5,511 | py | Python | predict.py | ciampluca/counting_perineuronal_nets | 29463a4810b74943ee5234673e9e0816716b7fee | [
"Apache-2.0"
] | 6 | 2021-12-16T13:47:56.000Z | 2022-02-05T09:49:37.000Z | predict.py | ciampluca/counting_perineuronal_nets | 29463a4810b74943ee5234673e9e0816716b7fee | [
"Apache-2.0"
] | 1 | 2021-06-28T17:09:48.000Z | 2021-06-28T18:58:04.000Z | predict.py | ciampluca/counting_perineuronal_nets | 29463a4810b74943ee5234673e9e0816716b7fee | [
"Apache-2.0"
] | null | null | null | import argparse
from pathlib import Path
import hydra
from omegaconf import OmegaConf
import torch
from torch.utils.data import DataLoader
from tqdm import tqdm
from datasets.patched_datasets import PatchedMultiImageDataset, RandomAccessMultiImageDataset
if __name__ == "__main__":
parser = argparse.ArgumentPar... | 43.054688 | 141 | 0.678098 |
20cda404e20b8445bfe6243758a4bf304606f130 | 375 | py | Python | test/test.py | innovate-invent/configutator | 372b45c44a10171b8518e61f2a7974969304c33a | [
"MIT"
] | null | null | null | test/test.py | innovate-invent/configutator | 372b45c44a10171b8518e61f2a7974969304c33a | [
"MIT"
] | 1 | 2017-09-22T05:52:54.000Z | 2017-09-22T05:52:54.000Z | test/test.py | innovate-invent/configutator | 372b45c44a10171b8518e61f2a7974969304c33a | [
"MIT"
] | null | null | null | from configutator import ConfigMap, ArgMap, EnvMap, loadConfig
import sys
def test(param1: int, param2: str):
"""
This is a test
:param param1: An integer
:param param2: A string
:return: Print the params
"""
print(param1, param2)
if __name__ == '__main__':
for argMap in loadConfig(sys... | 22.058824 | 62 | 0.642667 |
20cdadc43f7f0fbddcc40c1c7b51c46475d844b7 | 2,384 | py | Python | app/ecommerce/admin.py | nguyenanhtuan21/ecommerce-django | df29b31073b8e24ae9fbb294ca0c3ba8c81c09ae | [
"MIT"
] | 1 | 2019-12-16T16:45:11.000Z | 2019-12-16T16:45:11.000Z | app/ecommerce/admin.py | nguyenanhtuan21/ecommerce-django | df29b31073b8e24ae9fbb294ca0c3ba8c81c09ae | [
"MIT"
] | 3 | 2021-06-04T22:05:06.000Z | 2021-09-22T18:05:05.000Z | app/ecommerce/admin.py | nguyenanhtuan21/ecommerce-django | df29b31073b8e24ae9fbb294ca0c3ba8c81c09ae | [
"MIT"
] | null | null | null | from django.contrib import admin
from .models import Brand, Product, Profile, Instagram, OrderItem,Order
from django.utils.html import format_html
# Register your models here.
make_published.short_description = "Mark selected stories as published"
admin.site.register(Brand,BrandAdmin)
admin.site.register(Pr... | 40.40678 | 149 | 0.707215 |
20cdcbc31867bb9709b928a4acae70fbdca1641b | 3,211 | py | Python | util/dates.py | cumanachao/utopia-crm | 6d648971c427ca9f380b15ed0ceaf5767b88e8b9 | [
"BSD-3-Clause"
] | 13 | 2020-12-14T19:56:04.000Z | 2021-11-06T13:24:48.000Z | util/dates.py | cumanachao/utopia-crm | 6d648971c427ca9f380b15ed0ceaf5767b88e8b9 | [
"BSD-3-Clause"
] | 5 | 2020-12-14T19:56:30.000Z | 2021-09-22T22:09:39.000Z | util/dates.py | cumanachao/utopia-crm | 6d648971c427ca9f380b15ed0ceaf5767b88e8b9 | [
"BSD-3-Clause"
] | 3 | 2021-03-24T03:55:08.000Z | 2022-01-13T15:22:34.000Z | import calendar
from datetime import date, datetime, timedelta
from time import localtime
from django.utils.translation import ugettext_lazy as _
def add_business_days(from_date, add_days):
"""
This is just used to add business days to a function. Should be moved to util.
"""
business_days_to_add = ad... | 30.875 | 116 | 0.638742 |
20cfca94bf1866157bf1f47a272c02db1e2ee2a1 | 1,211 | py | Python | leetcode/9isPalindrome.py | wanglingyun/interview-questions | 41aad1146c1cf8cfff741a0127ce973733fdcac6 | [
"Apache-2.0"
] | null | null | null | leetcode/9isPalindrome.py | wanglingyun/interview-questions | 41aad1146c1cf8cfff741a0127ce973733fdcac6 | [
"Apache-2.0"
] | null | null | null | leetcode/9isPalindrome.py | wanglingyun/interview-questions | 41aad1146c1cf8cfff741a0127ce973733fdcac6 | [
"Apache-2.0"
] | null | null | null | # Definition for singly-linked list.
import unittest
import math
if __name__ == '__main__':
unittest.main() | 22.425926 | 44 | 0.523534 |
20d0880440126c65c69df8c4573d843710e04d7e | 433 | py | Python | polyglot/utils.py | riccardoFasan/deeply | b025d2b85282d6934edc8c2f824ca9ad68a8ba08 | [
"MIT"
] | 2 | 2022-03-14T17:47:20.000Z | 2022-03-20T09:51:27.000Z | polyglot/utils.py | riccardoFasan/deepl-translator-script | b025d2b85282d6934edc8c2f824ca9ad68a8ba08 | [
"MIT"
] | 1 | 2022-03-31T07:00:28.000Z | 2022-03-31T07:01:05.000Z | polyglot/utils.py | riccardoFasan/deepl-translator-script | b025d2b85282d6934edc8c2f824ca9ad68a8ba08 | [
"MIT"
] | 1 | 2021-12-28T09:21:31.000Z | 2021-12-28T09:21:31.000Z | from typing import Any, Iterator, Optional
import colorama
DownloadedDocumentStream = Optional[Iterator[Any]]
| 25.470588 | 62 | 0.706697 |
20d29550aa2f57d0c74fa67f5970acb95e350f79 | 2,771 | py | Python | LocadoraDeFilmes/funcoes_dos_filmes.py | JoaoVitorBernardino/Sistema-de-locadora-de-filmes | cf0cd0d8c9ad49fe48ab14626f241c4e0bb39846 | [
"MIT"
] | null | null | null | LocadoraDeFilmes/funcoes_dos_filmes.py | JoaoVitorBernardino/Sistema-de-locadora-de-filmes | cf0cd0d8c9ad49fe48ab14626f241c4e0bb39846 | [
"MIT"
] | null | null | null | LocadoraDeFilmes/funcoes_dos_filmes.py | JoaoVitorBernardino/Sistema-de-locadora-de-filmes | cf0cd0d8c9ad49fe48ab14626f241c4e0bb39846 | [
"MIT"
] | null | null | null | import os
from DataBase.dados_filmes import *
from DataBase.dados_aluguel import * | 32.6 | 103 | 0.582461 |
20d2eced67b2dc37a106dd6188cfaac2ce3f1efd | 599 | py | Python | find-optional-modules/delete-pyc.py | berkut-174/salt-windows-msi | 3a0b9c891db95dfcfc5daa518305e1a5cc20d1b0 | [
"Apache-2.0"
] | null | null | null | find-optional-modules/delete-pyc.py | berkut-174/salt-windows-msi | 3a0b9c891db95dfcfc5daa518305e1a5cc20d1b0 | [
"Apache-2.0"
] | null | null | null | find-optional-modules/delete-pyc.py | berkut-174/salt-windows-msi | 3a0b9c891db95dfcfc5daa518305e1a5cc20d1b0 | [
"Apache-2.0"
] | null | null | null | ''' delete pyc except salt-minion.pyc '''
from __future__ import print_function
import os
SRCDIR = r'c:\salt'
action(SRCDIR)
| 23.038462 | 60 | 0.534224 |
20d36a5f003e151ad485d22dfd0ea098ae87f73e | 387 | py | Python | DeepLearningAI/notification.py | philson-philip/harp | 8e38573cad1c3e16c062044a8f011658293d1531 | [
"MIT"
] | 1 | 2019-02-08T20:14:14.000Z | 2019-02-08T20:14:14.000Z | DeepLearningAI/notification.py | philson-philip/harp | 8e38573cad1c3e16c062044a8f011658293d1531 | [
"MIT"
] | 6 | 2021-03-18T22:10:34.000Z | 2022-03-11T23:40:16.000Z | DeepLearningAI/notification.py | philson-philip/harp | 8e38573cad1c3e16c062044a8f011658293d1531 | [
"MIT"
] | 3 | 2019-02-08T20:14:23.000Z | 2019-03-10T06:10:07.000Z | from win10toast import ToastNotifier
import time | 35.181818 | 53 | 0.689922 |
20d57f78d8a0255a09b457d1362b139f81bf6db0 | 2,883 | py | Python | datasets/cifar10.py | killianlevacher/defenseInvGAN-src | 8fa398536773c5bc00c906562d2d9359572b8157 | [
"MIT"
] | 14 | 2019-12-12T11:28:18.000Z | 2022-03-09T11:56:04.000Z | datasets/cifar10.py | killianlevacher/defenseInvGAN-src | 8fa398536773c5bc00c906562d2d9359572b8157 | [
"MIT"
] | 7 | 2019-12-16T22:20:01.000Z | 2022-02-10T00:45:21.000Z | datasets/cifar10.py | killianlevacher/defenseInvGAN-src | 8fa398536773c5bc00c906562d2d9359572b8157 | [
"MIT"
] | 2 | 2020-04-01T09:02:00.000Z | 2021-08-01T14:27:11.000Z | import os
import numpy as np
import cPickle as pickle
from datasets.dataset import Dataset
| 30.347368 | 101 | 0.534513 |
20d64baaf85f6901221960787dd47f6f3ae74d9b | 759 | py | Python | tests/test_collide.py | csayres/kaiju | 0b4ca4fab5322351b97b8316b2d755d91bc05c16 | [
"BSD-3-Clause"
] | null | null | null | tests/test_collide.py | csayres/kaiju | 0b4ca4fab5322351b97b8316b2d755d91bc05c16 | [
"BSD-3-Clause"
] | null | null | null | tests/test_collide.py | csayres/kaiju | 0b4ca4fab5322351b97b8316b2d755d91bc05c16 | [
"BSD-3-Clause"
] | null | null | null | import pytest
import kaiju
from kaiju.robotGrid import RobotGridNominal
from kaiju import utils
if __name__ == "__main__":
test_collide(True) | 24.483871 | 104 | 0.648221 |
20d675e25832cd9793c5f67b4cb83f944dbf455c | 2,839 | py | Python | Lib/site-packages/psycopg/__init__.py | RosaSineSpinis/twitter_bitcon_tag_analyser | 3311022b6fd629ce85f0c4fa0516e310bed05d74 | [
"bzip2-1.0.6"
] | null | null | null | Lib/site-packages/psycopg/__init__.py | RosaSineSpinis/twitter_bitcon_tag_analyser | 3311022b6fd629ce85f0c4fa0516e310bed05d74 | [
"bzip2-1.0.6"
] | null | null | null | Lib/site-packages/psycopg/__init__.py | RosaSineSpinis/twitter_bitcon_tag_analyser | 3311022b6fd629ce85f0c4fa0516e310bed05d74 | [
"bzip2-1.0.6"
] | null | null | null | """
psycopg -- PostgreSQL database adapter for Python
"""
# Copyright (C) 2020-2021 The Psycopg Team
import logging
from . import pq # noqa: F401 import early to stabilize side effects
from . import types
from . import postgres
from .copy import Copy, AsyncCopy
from ._enums import IsolationLevel
from .cursor import... | 27.563107 | 76 | 0.738288 |
20d72cb6f933da26640aaaa4fbce23b2cbb317bd | 434 | py | Python | Datasets/Terrain/us_ned_topo_diversity.py | liuxb555/earthengine-py-examples | cff5d154b15a17d6a241e3c003b7fc9a2c5903f3 | [
"MIT"
] | 75 | 2020-06-09T14:40:11.000Z | 2022-03-07T08:38:10.000Z | Datasets/Terrain/us_ned_topo_diversity.py | gentaprekazi/earthengine-py-examples | 76ae8e071a71b343f5e464077afa5b0ed2f9314c | [
"MIT"
] | 1 | 2022-03-15T02:23:45.000Z | 2022-03-15T02:23:45.000Z | Datasets/Terrain/us_ned_topo_diversity.py | gentaprekazi/earthengine-py-examples | 76ae8e071a71b343f5e464077afa5b0ed2f9314c | [
"MIT"
] | 35 | 2020-06-12T23:23:48.000Z | 2021-11-15T17:34:50.000Z | import ee
import geemap
# Create a map centered at (lat, lon).
Map = geemap.Map(center=[40, -100], zoom=4)
dataset = ee.Image('CSP/ERGo/1_0/US/topoDiversity')
usTopographicDiversity = dataset.select('constant')
usTopographicDiversityVis = {
'min': 0.0,
'max': 1.0,
}
Map.setCenter(-111.313, 39.724, 6)
Map.addLaye... | 21.7 | 54 | 0.71659 |
20d89580fd6577e22f09078f9105ed4eb217404f | 6,139 | py | Python | cnn_to_mlp.py | minimario/CNN-Cert | 0dd60a8e8277cfecef3ab4d1ed055e62f92fd71c | [
"Apache-2.0"
] | 54 | 2020-09-09T12:43:43.000Z | 2022-03-17T17:31:19.000Z | cnn_to_mlp.py | jinzh154/CNN-Cert | 0dd60a8e8277cfecef3ab4d1ed055e62f92fd71c | [
"Apache-2.0"
] | 9 | 2019-04-26T15:33:21.000Z | 2022-02-17T13:20:47.000Z | cnn_to_mlp.py | jinzh154/CNN-Cert | 0dd60a8e8277cfecef3ab4d1ed055e62f92fd71c | [
"Apache-2.0"
] | 16 | 2019-02-17T03:02:36.000Z | 2021-05-17T13:59:07.000Z | """
cnn_to_mlp.py
Converts CNNs to MLP networks
Copyright (C) 2018, Akhilan Boopathy <akhilan@mit.edu>
Lily Weng <twweng@mit.edu>
Pin-Yu Chen <Pin-Yu.Chen@ibm.com>
Sijia Liu <Sijia.Liu@ibm.com>
Luca Daniel <dluca@mit.edu>
"""
from tenso... | 42.93007 | 127 | 0.620948 |
20da2372e14378343601425914ba9a4d487c8b91 | 5,328 | py | Python | libsymple.py | aoeftiger/PySymple | 00b887a59a107426d940aeb1e42a30a521b5729d | [
"MIT"
] | 1 | 2019-12-18T15:30:19.000Z | 2019-12-18T15:30:19.000Z | libsymple.py | aoeftiger/PySymple | 00b887a59a107426d940aeb1e42a30a521b5729d | [
"MIT"
] | null | null | null | libsymple.py | aoeftiger/PySymple | 00b887a59a107426d940aeb1e42a30a521b5729d | [
"MIT"
] | null | null | null | '''
Copyright 2014 by Adrian Oeftiger, oeftiger@cern.ch
This module provides various numerical integration methods
for Hamiltonian vector fields on (currently two-dimensional) phase space.
The integrators are separated according to symplecticity.
The method is_symple() is provided to check for symplecticity
of a given... | 45.152542 | 77 | 0.647147 |
20dc7c2e8b065dfa920a34dee44b90c37f1c51a5 | 256 | py | Python | Rasp_Pi_2018/should_i_water/water_plants_task.py | BitKnitting/should_I_water | 8d849671892b7bbc9e947e0ba041c4c3527b6bbd | [
"MIT"
] | 2 | 2018-05-20T00:26:31.000Z | 2018-06-13T16:22:48.000Z | Rasp_Pi_2018/should_i_water/water_plants_task.py | BitKnitting/should_I_water | 8d849671892b7bbc9e947e0ba041c4c3527b6bbd | [
"MIT"
] | null | null | null | Rasp_Pi_2018/should_i_water/water_plants_task.py | BitKnitting/should_I_water | 8d849671892b7bbc9e947e0ba041c4c3527b6bbd | [
"MIT"
] | null | null | null | import os
import sys
LIB_PATH = os.environ['LADYBUG_LIB_PATH']
sys.path.append(LIB_PATH)
from water_plants_lib import WaterPlants
###############
if __name__ == "__main__":
water_plants = WaterPlants()
water_plants.send_start_watering_packets()
| 19.692308 | 46 | 0.734375 |
20de1adfff69feef6f33b16295086d0f5529ee20 | 2,055 | py | Python | undp-transparency-portal-be/undp_admin/api_views.py | undp/transparencyportal | 244fbb82c05d119f0acbe7f5efbb44572d9150a0 | [
"CC-BY-3.0"
] | 5 | 2019-09-10T15:05:18.000Z | 2022-02-02T02:53:32.000Z | undp-transparency-portal-be/undp_admin/api_views.py | undp/transparencyportal | 244fbb82c05d119f0acbe7f5efbb44572d9150a0 | [
"CC-BY-3.0"
] | 4 | 2019-04-02T15:02:20.000Z | 2021-11-09T10:55:32.000Z | undp-transparency-portal-be/undp_admin/api_views.py | undp/transparencyportal | 244fbb82c05d119f0acbe7f5efbb44572d9150a0 | [
"CC-BY-3.0"
] | 2 | 2021-09-01T14:30:29.000Z | 2021-09-01T14:32:57.000Z | from django.shortcuts import render
# Create your views here.
from rest_framework.views import APIView
from rest_framework.viewsets import GenericViewSet
from undp_admin.models import AboutUs, AdminLog, JOBS, LOG_STATUSES
from undp_admin.serializers import AboutUsSerializer
from utilities.mixins import ResponseViewMi... | 39.519231 | 96 | 0.697324 |
20df1df6d17c6f6ed2e728f416d617232f800db9 | 2,681 | py | Python | COVIDSafepassage/passsystem/admin.py | VICS-CORE/safepassage_server | 58bc04dbfa55430c0218567211e5259de77518ae | [
"MIT"
] | null | null | null | COVIDSafepassage/passsystem/admin.py | VICS-CORE/safepassage_server | 58bc04dbfa55430c0218567211e5259de77518ae | [
"MIT"
] | 8 | 2020-04-25T09:42:25.000Z | 2022-03-12T00:23:32.000Z | COVIDSafepassage/passsystem/admin.py | VICS-CORE/safepassage_server | 58bc04dbfa55430c0218567211e5259de77518ae | [
"MIT"
] | null | null | null | from django.contrib import admin
from .models import Pass, User, Organisation, Roles, Vehicle, Identity, Team
from treebeard.admin import TreeAdmin
from treebeard.forms import movenodeform_factory
admin.site.register(Team, AdminTeamView)
admin.site.register(User, AdminUserView)
admin.site.regist... | 37.760563 | 121 | 0.70981 |
20df31b6f10759e65d52beef5fda7d1f46c80d54 | 1,592 | py | Python | python/climate_ae/data_generator/utils.py | kueddelmaier/latent-linear-adjustment-autoencoders | f180732695a6c2abd8a9ad9d8cfeed2f82f047bb | [
"MIT"
] | 3 | 2020-10-29T19:08:27.000Z | 2021-08-14T09:19:48.000Z | python/climate_ae/data_generator/utils.py | kueddelmaier/latent-linear-adjustment-autoencoders | f180732695a6c2abd8a9ad9d8cfeed2f82f047bb | [
"MIT"
] | 6 | 2020-11-13T19:01:07.000Z | 2022-01-04T09:34:05.000Z | python/climate_ae/data_generator/utils.py | kueddelmaier/latent-linear-adjustment-autoencoders | f180732695a6c2abd8a9ad9d8cfeed2f82f047bb | [
"MIT"
] | 1 | 2021-03-01T15:28:56.000Z | 2021-03-01T15:28:56.000Z | import numpy as np
import tensorflow as tf
| 41.894737 | 84 | 0.704774 |
20df33ace10cb4d9d76d4f800c169534a71238a5 | 78 | py | Python | uci_janggi/__init__.py | sprinter89/uci_janggi | 1acdf8db9a186eb44be6c462329c9965f5952f7e | [
"MIT"
] | null | null | null | uci_janggi/__init__.py | sprinter89/uci_janggi | 1acdf8db9a186eb44be6c462329c9965f5952f7e | [
"MIT"
] | null | null | null | uci_janggi/__init__.py | sprinter89/uci_janggi | 1acdf8db9a186eb44be6c462329c9965f5952f7e | [
"MIT"
] | null | null | null | #this file does nothing except informing pypi that uci_janggi.py is a package
| 39 | 77 | 0.820513 |
20e0cbef167c1c068cc1264bcbdca5e71f4391df | 8,251 | py | Python | app/app/api/views.py | dtcooper/crazyarms | 71ea0e58958233daaceb8750043f74ef1a141079 | [
"MIT"
] | 15 | 2021-01-18T17:16:51.000Z | 2022-03-28T22:16:19.000Z | app/app/api/views.py | dtcooper/carb | 71ea0e58958233daaceb8750043f74ef1a141079 | [
"MIT"
] | 4 | 2021-03-14T16:28:40.000Z | 2021-03-31T16:48:49.000Z | app/app/api/views.py | dtcooper/carb | 71ea0e58958233daaceb8750043f74ef1a141079 | [
"MIT"
] | 3 | 2021-07-15T02:24:19.000Z | 2022-03-18T11:50:05.000Z | import json
import logging
from django.conf import settings
from django.contrib.auth import authenticate
from django.http import HttpResponse, HttpResponseBadRequest, HttpResponseForbidden, JsonResponse
from django.utils.decorators import method_decorator
from django.views import View
from django.views.decorators.csrf... | 37 | 120 | 0.5769 |
20e14f7ef604899504925d65072a7843fff0a6db | 40,435 | py | Python | notebooks/Users/kasri@berkeley.edu/final_project_team25_centrality.py | superli3/ucb-w261-sp2021-team25 | 102e9859e878a54f84554e66425097217a0485e7 | [
"Apache-2.0"
] | null | null | null | notebooks/Users/kasri@berkeley.edu/final_project_team25_centrality.py | superli3/ucb-w261-sp2021-team25 | 102e9859e878a54f84554e66425097217a0485e7 | [
"Apache-2.0"
] | null | null | null | notebooks/Users/kasri@berkeley.edu/final_project_team25_centrality.py | superli3/ucb-w261-sp2021-team25 | 102e9859e878a54f84554e66425097217a0485e7 | [
"Apache-2.0"
] | 1 | 2021-04-19T20:41:48.000Z | 2021-04-19T20:41:48.000Z | // Databricks notebook source
// MAGIC %md
// MAGIC
// MAGIC W261 Final Project
// MAGIC ------------------
// MAGIC ## Graph Centrality for Airline Delay Prediction
// MAGIC
// MAGIC #### Justin Trobec, Jeff Li, Sonya Chen, Karthik Srinivasan
// MAGIC #### Spring 2021, Section 5
// MAGIC #### Group 25
// COMMAN... | 35.130321 | 656 | 0.679609 |
20e4504512f6f3017cd6e385cfabae07f81ee87a | 382 | py | Python | datasets/script/ds_cut_last.py | PoCInnovation/SmartShark | 2cf5eb32306fb5bd88972f44331322ae58d4bb2c | [
"MIT"
] | 26 | 2020-11-26T13:05:31.000Z | 2022-03-22T11:04:41.000Z | datasets/script/ds_cut_last.py | PoCFrance/SmartShark | 2cf5eb32306fb5bd88972f44331322ae58d4bb2c | [
"MIT"
] | 4 | 2020-09-26T16:30:47.000Z | 2022-03-06T18:02:52.000Z | datasets/script/ds_cut_last.py | PoCFrance/SmartShark | 2cf5eb32306fb5bd88972f44331322ae58d4bb2c | [
"MIT"
] | 9 | 2021-01-19T16:44:23.000Z | 2022-02-15T21:06:29.000Z | fichier = open("/run/media/Thytu/TOSHIBA EXT/PoC/Smartshark/DS/ds_benign_cleaned_div_3.csv", "r")
pos = 12 #pos to flatten
for line in fichier:
flat_line(line, pos)
| 21.222222 | 97 | 0.552356 |
20e53640a34afd90bd7994b855aba3b499daef58 | 835 | py | Python | Scripts/python/setup_k8s_thirdparty.py | SnowPhoenix0105/ToolSite | c5084010665434711867b1b5cd4915fe79ab2c7b | [
"MIT"
] | null | null | null | Scripts/python/setup_k8s_thirdparty.py | SnowPhoenix0105/ToolSite | c5084010665434711867b1b5cd4915fe79ab2c7b | [
"MIT"
] | 7 | 2021-08-28T09:27:39.000Z | 2021-09-26T15:35:13.000Z | Scripts/python/setup_k8s_thirdparty.py | SnowPhoenix0105/ToolSite | c5084010665434711867b1b5cd4915fe79ab2c7b | [
"MIT"
] | null | null | null |
from python.utils.cmd_exec import cmd_exec
import json
import logging
from python.utils.path import Path, pcat
from logging import DEBUG
from python.utils.log import config_logging
_logger = logging.getLogger(__name__)
if __name__ == '__main__':
config_logging(__file__, console_level=logging.INFO)
setup_k8... | 29.821429 | 65 | 0.728144 |
20e5596dc72fd005174ca47cd9087713926d0058 | 1,506 | py | Python | utils/callbacks.py | YossiAsher/utils | c389d061378fca0b5495691c999f93adfa882faf | [
"MIT"
] | null | null | null | utils/callbacks.py | YossiAsher/utils | c389d061378fca0b5495691c999f93adfa882faf | [
"MIT"
] | null | null | null | utils/callbacks.py | YossiAsher/utils | c389d061378fca0b5495691c999f93adfa882faf | [
"MIT"
] | null | null | null | import os.path
import glob
import wandb
import numpy as np
from tensorflow.keras.callbacks import Callback
| 40.702703 | 97 | 0.616866 |
20e603c9bd357a4fc46fca97e132ad4376a93633 | 12,680 | py | Python | cirrocumulus/anndata_util.py | PfizerRD/cirrocumulus | c7ce0c8c3c246282046e6d373d60442af55d3f09 | [
"BSD-3-Clause"
] | null | null | null | cirrocumulus/anndata_util.py | PfizerRD/cirrocumulus | c7ce0c8c3c246282046e6d373d60442af55d3f09 | [
"BSD-3-Clause"
] | null | null | null | cirrocumulus/anndata_util.py | PfizerRD/cirrocumulus | c7ce0c8c3c246282046e6d373d60442af55d3f09 | [
"BSD-3-Clause"
] | 1 | 2022-02-06T23:08:26.000Z | 2022-02-06T23:08:26.000Z | import anndata
import numpy as np
import pandas as pd
DATA_TYPE_MODULE = 'module'
DATA_TYPE_UNS_KEY = 'data_type'
ADATA_MODULE_UNS_KEY = 'anndata_module'
def dataset_schema(dataset, n_features=10):
""" Gets dataset schema.
Returns
schema dict. Example:
{"version":"1.0.0",
"cate... | 41.168831 | 135 | 0.596688 |
20e63d705639da49401b6833ac2f7010dc3cf8e6 | 23,612 | py | Python | apps/cumulative_gdd.py | ua-snap/usda-dash | caeab072728a5c78b63b1547985f3e6476b348fa | [
"MIT"
] | null | null | null | apps/cumulative_gdd.py | ua-snap/usda-dash | caeab072728a5c78b63b1547985f3e6476b348fa | [
"MIT"
] | 17 | 2020-01-22T00:15:52.000Z | 2021-11-04T21:35:37.000Z | apps/cumulative_gdd.py | ua-snap/usda-dash | caeab072728a5c78b63b1547985f3e6476b348fa | [
"MIT"
] | 1 | 2022-03-31T04:39:34.000Z | 2022-03-31T04:39:34.000Z | #!/usr/bin/env python3
"""
Template for SNAP Dash apps.
"""
import os
import json
import plotly.graph_objs as go
import xarray as xr
import dash
import dash_core_components as dcc
import dash_html_components as html
import dash_dangerously_set_inner_html as ddsih
import dash_table
import pandas as pd
import geopandas ... | 34.825959 | 3,692 | 0.380103 |
20e69aa1204b71354dd606f9dd415d38b56a677a | 15,298 | py | Python | tests/integration/test_occ.py | aavcc/taiga-openshift | 7c33284573ceed38f755b8159ad83f3f68d2f7cb | [
"MIT"
] | null | null | null | tests/integration/test_occ.py | aavcc/taiga-openshift | 7c33284573ceed38f755b8159ad83f3f68d2f7cb | [
"MIT"
] | 12 | 2019-11-25T14:08:32.000Z | 2021-06-24T10:35:51.000Z | tests/integration/test_occ.py | threefoldtech/Threefold-Circles | cbc433796b25cf7af9a295af65d665a4a279e2d6 | [
"Apache-2.0"
] | 1 | 2018-06-07T10:58:15.000Z | 2018-06-07T10:58:15.000Z | # -*- coding: utf-8 -*-
# Copyright (C) 2014-2017 Andrey Antukh <niwi@niwi.nz>
# Copyright (C) 2014-2017 Jess Espino <jespinog@gmail.com>
# Copyright (C) 2014-2017 David Barragn <bameda@dbarragan.com>
# Copyright (C) 2014-2017 Alejandro Alonso <alejandro.alonso@kaleidos.net>
# This program is free software: you can red... | 42.376731 | 88 | 0.664727 |
20e7676617875b614527d964e3fa868094f4c605 | 4,450 | py | Python | python-code/dlib-learning/face_reco_from_camera.py | juxiangwu/image-processing | c644ef3386973b2b983c6b6b08f15dc8d52cd39f | [
"Apache-2.0"
] | 13 | 2018-09-07T02:29:07.000Z | 2021-06-18T08:40:09.000Z | python-code/dlib-learning/face_reco_from_camera.py | juxiangwu/image-processing | c644ef3386973b2b983c6b6b08f15dc8d52cd39f | [
"Apache-2.0"
] | null | null | null | python-code/dlib-learning/face_reco_from_camera.py | juxiangwu/image-processing | c644ef3386973b2b983c6b6b08f15dc8d52cd39f | [
"Apache-2.0"
] | 4 | 2019-06-20T00:09:39.000Z | 2021-07-15T10:14:36.000Z | # created at 2018-05-11
# updated at 2018-08-23
# support multi-faces now
# By coneypo
# Blog: http://www.cnblogs.com/AdaminXie
# GitHub: https://github.com/coneypo/Dlib_face_recognition_from_camera
import dlib # dlib
import numpy as np # numpy
import cv2 # OpenCv
import pandas as pd # Pandas
# fac... | 28.164557 | 120 | 0.634382 |
20e848a5145974495ecc337b35a8d2b22c5a5616 | 340 | py | Python | tpow/examples/check_read_rom.py | sken10/tpow | 6accbfe133a41959c2d35d5c8401e622d4f9efc2 | [
"MIT"
] | 1 | 2020-10-31T05:37:41.000Z | 2020-10-31T05:37:41.000Z | tpow/examples/check_read_rom.py | sken10/tpow | 6accbfe133a41959c2d35d5c8401e622d4f9efc2 | [
"MIT"
] | null | null | null | tpow/examples/check_read_rom.py | sken10/tpow | 6accbfe133a41959c2d35d5c8401e622d4f9efc2 | [
"MIT"
] | null | null | null | """check_read_rom.py
get ROMID of 1-wire device.
assume only one 1-wire device on the bus.
"""
import tpow.usb9097
import tpow.device
import cfg
bus = tpow.usb9097.USB9097(cfg.com_port) # USB9097('COM3')
id_little = tpow.device.read_rom(bus)
id_big = [a for a in reversed(id_little)]
print(" ".join(['%02X' % ord(a) ... | 21.25 | 59 | 0.711765 |
20e8ac2901c046279a37346f2a01171b0a59374c | 1,522 | py | Python | common/xrd-ui-tests-python/tests/xroad_trust_view_details_cs_ca/XroadTrustViewDetailsCsCa.py | ria-ee/XTM | 6103f3f5bbba387b8b59b050c0c4f1fb2180fc37 | [
"MIT"
] | 3 | 2018-03-15T14:22:50.000Z | 2021-11-08T10:30:35.000Z | common/xrd-ui-tests-python/tests/xroad_trust_view_details_cs_ca/XroadTrustViewDetailsCsCa.py | ria-ee/XTM | 6103f3f5bbba387b8b59b050c0c4f1fb2180fc37 | [
"MIT"
] | 11 | 2017-04-06T09:25:41.000Z | 2018-06-04T09:08:48.000Z | common/xrd-ui-tests-python/tests/xroad_trust_view_details_cs_ca/XroadTrustViewDetailsCsCa.py | ria-ee/XTM | 6103f3f5bbba387b8b59b050c0c4f1fb2180fc37 | [
"MIT"
] | 20 | 2017-03-14T07:21:58.000Z | 2019-05-21T09:26:30.000Z | # coding=utf-8
import unittest
from main.maincontroller import MainController
import view_management
"""
UC TRUST_02: View the Details of a Certification Service CA
RIA URL:https://jira.ria.ee/browse/XTKB-185
Depends on finishing other test(s):
Requires helper scenarios:
X-Road version: 6.16.0
"""
| 31.708333 | 131 | 0.657687 |
20eb0a186ef36f16b32ac0c98a703bfa733a0d35 | 8,002 | py | Python | test/test_jarsigner_sign_command.py | fullstaq-labs/venafi-codesigning-gitlab | 0799ce7e6b74c8d1836a01b509dc5f50541356b3 | [
"Apache-2.0"
] | null | null | null | test/test_jarsigner_sign_command.py | fullstaq-labs/venafi-codesigning-gitlab | 0799ce7e6b74c8d1836a01b509dc5f50541356b3 | [
"Apache-2.0"
] | 1 | 2021-07-12T09:06:53.000Z | 2021-07-12T09:06:53.000Z | test/test_jarsigner_sign_command.py | fullstaq-labs/venafi-codesigning-gitlab | 0799ce7e6b74c8d1836a01b509dc5f50541356b3 | [
"Apache-2.0"
] | null | null | null | from venafi_codesigning_gitlab_integration.jarsigner_sign_command import JarsignerSignConfig
from venafi_codesigning_gitlab_integration.jarsigner_sign_command import JarsignerSignCommand
from venafi_codesigning_gitlab_integration import utils
import pytest
import logging
import subprocess
import os
import re
fake_tpp_... | 33.481172 | 97 | 0.676456 |
20eb50420f20c4e8a8059ec57505d6d0d5ad5fae | 1,602 | py | Python | GreyNsights/utils.py | kamathhrishi/GreyNSights | 9a79b8ed04ccb4a9dd538c425ed6da00ebd1b00f | [
"MIT"
] | 19 | 2021-02-24T12:28:04.000Z | 2021-10-06T11:55:46.000Z | GreyNsights/utils.py | kamathhrishi/GreyNSights | 9a79b8ed04ccb4a9dd538c425ed6da00ebd1b00f | [
"MIT"
] | 2 | 2021-08-11T01:25:14.000Z | 2021-08-11T01:26:32.000Z | GreyNsights/utils.py | kamathhrishi/GreyNSights | 9a79b8ed04ccb4a9dd538c425ed6da00ebd1b00f | [
"MIT"
] | null | null | null | # python dependencies
import codecs
import pickle
import struct
def log_message(msg_type: str, message: str):
"""The default style of log messages displayed on DataOwner's screen
args[str]: The type of message
message[str]: The message to be displayed
"""
print("Logger", "<" + msg_type + ">", ... | 22.56338 | 72 | 0.637328 |
20eced0df909101c4f435345f41c4866a1674f9a | 138 | py | Python | test/resources/inspectors/python/case27_using_requests.py | nihalshetty-boop/hyperstyle | 9a6d53cd1ca220d97d296c0087056b5885b26281 | [
"Apache-2.0"
] | 18 | 2020-10-05T16:48:11.000Z | 2022-03-22T04:15:38.000Z | test/resources/inspectors/python/case27_using_requests.py | nihalshetty-boop/hyperstyle | 9a6d53cd1ca220d97d296c0087056b5885b26281 | [
"Apache-2.0"
] | 60 | 2020-10-05T17:01:05.000Z | 2022-01-27T12:46:14.000Z | test/resources/inspectors/python/case27_using_requests.py | nihalshetty-boop/hyperstyle | 9a6d53cd1ca220d97d296c0087056b5885b26281 | [
"Apache-2.0"
] | 6 | 2021-02-09T09:31:19.000Z | 2021-08-13T07:45:51.000Z | import requests
| 19.714286 | 42 | 0.652174 |
20ed1b39d69f2ba4a229353cc72ed388d06f0047 | 4,568 | py | Python | scripts/location_map_report.py | xperylabhub/iLEAPP | fd1b301bf2094387f51ccdbd10ed233ce9abd687 | [
"MIT"
] | null | null | null | scripts/location_map_report.py | xperylabhub/iLEAPP | fd1b301bf2094387f51ccdbd10ed233ce9abd687 | [
"MIT"
] | null | null | null | scripts/location_map_report.py | xperylabhub/iLEAPP | fd1b301bf2094387f51ccdbd10ed233ce9abd687 | [
"MIT"
] | null | null | null | # coding: utf-8
#Import the necessary Python modules
import pandas as pd
import folium
from folium.plugins import TimestampedGeoJson
from shapely.geometry import Point
import os
from datetime import datetime
from branca.element import Template, MacroElement
import html
from scripts.location_map_constants import iLEAPP_... | 35.968504 | 170 | 0.613835 |
20eec783eef37492901442687717aaffec487075 | 48 | py | Python | onebarangay_psql/statistics/__init__.py | PrynsTag/oneBarangay-PostgreSQL | 11d7b97b57603f4c88948905560a22a5314409ce | [
"Apache-2.0"
] | null | null | null | onebarangay_psql/statistics/__init__.py | PrynsTag/oneBarangay-PostgreSQL | 11d7b97b57603f4c88948905560a22a5314409ce | [
"Apache-2.0"
] | 43 | 2022-02-07T00:18:35.000Z | 2022-03-21T04:42:48.000Z | onebarangay_psql/statistics/__init__.py | PrynsTag/oneBarangay-PostgreSQL | 11d7b97b57603f4c88948905560a22a5314409ce | [
"Apache-2.0"
] | null | null | null | """Default init file for statistics package."""
| 24 | 47 | 0.729167 |
20eeefc46871bc4a82ccda95a4d09005d4444a71 | 1,096 | py | Python | src/BL/test/test_RandomNumber.py | yukiYamada/ThaGame | 4f206303d60b5760452a7eab8700626657f3e39e | [
"MIT"
] | null | null | null | src/BL/test/test_RandomNumber.py | yukiYamada/ThaGame | 4f206303d60b5760452a7eab8700626657f3e39e | [
"MIT"
] | null | null | null | src/BL/test/test_RandomNumber.py | yukiYamada/ThaGame | 4f206303d60b5760452a7eab8700626657f3e39e | [
"MIT"
] | null | null | null | # third party modules
import pytest
# user modules
from BL_main.RandomNumber import Number, Numbers, InvalidArgumentExceptionOfNumber
def test_NumberClass_InvalidException_underNumber():
'''
Test argument. under number.
'''
with pytest.raises(InvalidArgumentExceptionOfNumber):
Number.create(1)
... | 24.355556 | 82 | 0.667883 |
20efb6e68d19a66f29b03a03d92401ec1cbcda69 | 6,185 | py | Python | evaluate_ranking.py | aydindemircioglu/radFS | b50b2a78f7c7975751b699b6b74a2761f7fa3501 | [
"MIT",
"Unlicense"
] | 1 | 2022-02-24T02:16:55.000Z | 2022-02-24T02:16:55.000Z | evaluate_ranking.py | aydindemircioglu/radFS | b50b2a78f7c7975751b699b6b74a2761f7fa3501 | [
"MIT",
"Unlicense"
] | null | null | null | evaluate_ranking.py | aydindemircioglu/radFS | b50b2a78f7c7975751b699b6b74a2761f7fa3501 | [
"MIT",
"Unlicense"
] | null | null | null | #!/usr/bin/python3
import json
import seaborn as sns
from matplotlib import cm
from matplotlib.colors import ListedColormap, LinearSegmentedColormap
import matplotlib.colors as colors
from scipy.stats import spearmanr
import pylab
import scipy.cluster.hierarchy as sch
from scipy.stats import pearsonr, friedmanchisqu... | 30.46798 | 114 | 0.620049 |