hexsha
stringlengths
40
40
size
int64
5
2.06M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
3
248
max_stars_repo_name
stringlengths
5
125
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
248
max_issues_repo_name
stringlengths
5
125
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
67k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
3
248
max_forks_repo_name
stringlengths
5
125
max_forks_repo_head_hexsha
stringlengths
40
78
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
5
2.06M
avg_line_length
float64
1
1.02M
max_line_length
int64
3
1.03M
alphanum_fraction
float64
0
1
count_classes
int64
0
1.6M
score_classes
float64
0
1
count_generators
int64
0
651k
score_generators
float64
0
1
count_decorators
int64
0
990k
score_decorators
float64
0
1
count_async_functions
int64
0
235k
score_async_functions
float64
0
1
count_documentation
int64
0
1.04M
score_documentation
float64
0
1
13abd087d6a8034a9d1a9da08f2dab574fb7be66
51,194
py
Python
polymath/srdfg/base.py
he-actlab/polymath
9b7937d0ddf7452f6cc74ee90d05f8c6acef737e
[ "Apache-2.0" ]
15
2021-05-09T05:46:04.000Z
2022-03-06T20:46:32.000Z
polymath/srdfg/base.py
he-actlab/polymath
9b7937d0ddf7452f6cc74ee90d05f8c6acef737e
[ "Apache-2.0" ]
null
null
null
polymath/srdfg/base.py
he-actlab/polymath
9b7937d0ddf7452f6cc74ee90d05f8c6acef737e
[ "Apache-2.0" ]
4
2021-08-24T07:46:29.000Z
2022-03-05T18:23:07.000Z
from polymath import UNSET_SHAPE, DEFAULT_SHAPES import builtins import operator from collections import OrderedDict, Mapping, Sequence, deque import functools from numbers import Integral, Rational, Real import contextlib import traceback import uuid import numpy as np import importlib from .graph import Graph from ....
35.725052
158
0.607239
45,773
0.894109
620
0.012111
7,170
0.140055
0
0
11,774
0.229988
13adaa6947a03ff103153b1b8c14da5ac9aaa4b0
392
py
Python
actors/models.py
rngallen/beyond_basics
2cfb7d97699a733251e68357a70eada3d0278680
[ "MIT" ]
null
null
null
actors/models.py
rngallen/beyond_basics
2cfb7d97699a733251e68357a70eada3d0278680
[ "MIT" ]
null
null
null
actors/models.py
rngallen/beyond_basics
2cfb7d97699a733251e68357a70eada3d0278680
[ "MIT" ]
null
null
null
from django.db import models from django.utils.translation import ugettext_lazy as _ # Create your models here. class Actor(models.Model): name = models.CharField(_("name"), max_length=200) # if is_star he/she will be directed to hollywood else directed to commercial is_star = models.BooleanField(_("is s...
28
81
0.729592
276
0.704082
0
0
0
0
0
0
119
0.303571
13aef1dee9a4b31316309780ab660b17ad23d9b2
1,285
py
Python
docs/buildscripts/docs.py
cwlalyy/mongo-c-driver
d771be13bc8f7d8b84d233de6fdc725d9bb337cc
[ "Apache-2.0" ]
13
2016-07-14T16:36:59.000Z
2018-06-01T18:06:14.000Z
docs/buildscripts/docs.py
cwlalyy/mongo-c-driver
d771be13bc8f7d8b84d233de6fdc725d9bb337cc
[ "Apache-2.0" ]
null
null
null
docs/buildscripts/docs.py
cwlalyy/mongo-c-driver
d771be13bc8f7d8b84d233de6fdc725d9bb337cc
[ "Apache-2.0" ]
9
2015-01-26T09:30:41.000Z
2016-03-15T14:48:18.000Z
"""Build the C client docs. """ from __future__ import with_statement import os import shutil import socket import subprocess import time import urllib2 def clean_dir(dir): try: shutil.rmtree(dir) except: pass os.makedirs(dir) def gen_api(dir): clean_dir(dir) clean_dir("docs/sourc...
22.155172
79
0.636576
0
0
0
0
0
0
0
0
415
0.322957
13afb94123467877efe58458ed4c502384fb753b
1,921
py
Python
tilegame/render/rs.py
defgsus/thegame
38a627d9108f1418b94b08831fd640dd87fbba83
[ "MIT" ]
1
2021-11-05T11:49:26.000Z
2021-11-05T11:49:26.000Z
tilegame/render/rs.py
defgsus/thegame
38a627d9108f1418b94b08831fd640dd87fbba83
[ "MIT" ]
null
null
null
tilegame/render/rs.py
defgsus/thegame
38a627d9108f1418b94b08831fd640dd87fbba83
[ "MIT" ]
null
null
null
import glm import math from lib.opengl import RenderSettings class GameProjection: def __init__(self, rs: "GameRenderSettings"): self.rs = rs self.scale = 10. self.rotation_deg = 0. self.location = glm.vec3(0) self._stack = [] def projection_matrix_4(self) -> glm.mat...
26.315068
90
0.563248
1,644
0.855804
0
0
0
0
0
0
74
0.038522
13afbf984a23501bfd2bc3f3a3b28ed6375a3779
4,865
py
Python
tools/stats/export_slow_tests.py
stungkit/pytorch
0f05e398705bf15406bce79f7ee57d3935ad2abd
[ "Intel" ]
2
2020-03-13T06:57:49.000Z
2020-05-17T04:18:14.000Z
tools/stats/export_slow_tests.py
ellhe-blaster/pytorch
e5282c3cb8bf6ad8c5161f9d0cc271edb9abed25
[ "Intel" ]
1
2022-01-10T18:39:28.000Z
2022-01-10T19:15:57.000Z
tools/stats/export_slow_tests.py
ellhe-blaster/pytorch
e5282c3cb8bf6ad8c5161f9d0cc271edb9abed25
[ "Intel" ]
1
2022-03-26T14:42:50.000Z
2022-03-26T14:42:50.000Z
#!/usr/bin/env python3 import argparse import json import os import statistics from collections import defaultdict from tools.stats.s3_stat_parser import ( get_previous_reports_for_branch, Report, Version2Report, ) from typing import cast, DefaultDict, Dict, List, Any from urllib.request import urlopen SL...
36.856061
127
0.658787
0
0
0
0
0
0
0
0
1,315
0.270298
13b0a600d04c4f624b452b2451a329662c1e6704
14,128
py
Python
ml/rl/evaluation/weighted_sequential_doubly_robust_estimator.py
michaeltashman/Horizon
ee310b34adeb807bbae379a6e1703d0f725f26a9
[ "BSD-3-Clause" ]
1
2020-07-30T06:15:20.000Z
2020-07-30T06:15:20.000Z
ml/rl/evaluation/weighted_sequential_doubly_robust_estimator.py
michaeltashman/Horizon
ee310b34adeb807bbae379a6e1703d0f725f26a9
[ "BSD-3-Clause" ]
null
null
null
ml/rl/evaluation/weighted_sequential_doubly_robust_estimator.py
michaeltashman/Horizon
ee310b34adeb807bbae379a6e1703d0f725f26a9
[ "BSD-3-Clause" ]
1
2019-06-05T15:52:18.000Z
2019-06-05T15:52:18.000Z
#!/usr/bin/env python3 # Copyright (c) Facebook, Inc. and its affiliates. All rights reserved. import itertools import logging import numpy as np import scipy as sp import torch from ml.rl.evaluation.cpe import CpeEstimate from ml.rl.evaluation.evaluation_data_page import EvaluationDataPage logger = logging.getLogg...
37.674667
106
0.613675
13,695
0.969352
0
0
5,122
0.362542
0
0
743
0.052591
13b1070ba0b79397d1d29eb7190ddb42cc92bb2c
678
py
Python
LeetCode/2019-08-03-384-Shuffle-an-Array.py
HeRuivio/-Algorithm
1fbe6256630758fda3af68f469471ee246730afc
[ "MIT" ]
5
2018-10-30T05:07:32.000Z
2019-06-18T08:11:38.000Z
LeetCode/2019-08-03-384-Shuffle-an-Array.py
HeRuivio/-Algorithm
1fbe6256630758fda3af68f469471ee246730afc
[ "MIT" ]
1
2020-05-09T09:05:16.000Z
2020-05-09T09:05:16.000Z
LeetCode/2019-08-03-384-Shuffle-an-Array.py
HeRuivio/-Algorithm
1fbe6256630758fda3af68f469471ee246730afc
[ "MIT" ]
2
2020-05-09T09:02:22.000Z
2020-12-09T13:23:00.000Z
# -*- coding: utf-8 -*- # @Author: 何睿 # @Create Date: 2019-08-03 10:48:30 # @Last Modified by: 何睿 # @Last Modified time: 2019-08-03 10:53:15 import copy import random from typing import List class Solution: def __init__(self, nums: List[int]): self.shuffle_ = nums self.orig...
21.870968
69
0.581121
461
0.672012
0
0
0
0
0
0
314
0.457726
13b20f00d86e94eb5e2fb0079121846394df7d95
5,255
py
Python
src/wspc/feature_selection.py
shakedna1/wspc_rep
f4492af8cec25a3f7b00687c08d30754a1c0c91f
[ "MIT" ]
null
null
null
src/wspc/feature_selection.py
shakedna1/wspc_rep
f4492af8cec25a3f7b00687c08d30754a1c0c91f
[ "MIT" ]
null
null
null
src/wspc/feature_selection.py
shakedna1/wspc_rep
f4492af8cec25a3f7b00687c08d30754a1c0c91f
[ "MIT" ]
null
null
null
import numpy as np import sklearn import pandas as pd import scipy.spatial.distance as ssd from scipy.cluster import hierarchy from scipy.stats import chi2_contingency from sklearn.base import BaseEstimator from sklearn.ensemble import RandomForestClassifier from sklearn.feature_extraction.text import CountVectorizer f...
33.259494
120
0.664891
4,005
0.762131
0
0
0
0
0
0
2,339
0.4451
13b2ef5da8cb4bdd6ae2ffffe9632e5405ed5cb0
5,985
py
Python
Python3/PS_scraping_selenium.py
fsj-digital/pages
8360f27e67974ed2b4f39eb64377f39c0189a224
[ "MIT" ]
5
2019-10-28T19:09:16.000Z
2021-08-19T07:44:54.000Z
Python3/PS_scraping_selenium.py
fsj-digital/pages
8360f27e67974ed2b4f39eb64377f39c0189a224
[ "MIT" ]
null
null
null
Python3/PS_scraping_selenium.py
fsj-digital/pages
8360f27e67974ed2b4f39eb64377f39c0189a224
[ "MIT" ]
6
2020-04-28T22:33:06.000Z
2021-06-22T15:53:52.000Z
from bs4 import BeautifulSoup import requests import re from selenium.webdriver.support.ui import WebDriverWait from selenium.webdriver.support import expected_conditions as EC from selenium.common.exceptions import TimeoutException from selenium.webdriver.common.by import By from selenium import webdriver from seleni...
43.057554
143
0.637594
0
0
0
0
0
0
0
0
1,612
0.26934
13b41f50da86c6a2be3204ada5e6385e678b7b05
5,531
py
Python
AppTest/testTCPserver.py
STRATOLOGIC/SpacePyLibrary
89fc3873c6d787ad4e391f6080d9dd3218ffc4a2
[ "MIT" ]
22
2015-01-22T13:40:22.000Z
2022-02-19T02:03:12.000Z
AppTest/testTCPserver.py
STRATOLOGIC/SpacePyLibrary
89fc3873c6d787ad4e391f6080d9dd3218ffc4a2
[ "MIT" ]
3
2018-09-28T13:14:40.000Z
2022-02-08T14:19:13.000Z
AppTest/testTCPserver.py
STRATOLOGIC/SpacePyLibrary
89fc3873c6d787ad4e391f6080d9dd3218ffc4a2
[ "MIT" ]
11
2016-06-01T11:53:56.000Z
2022-02-08T14:19:34.000Z
#!/usr/bin/env python3 #****************************************************************************** # (C) 2018, Stefan Korner, Austria * # * # The Space Python Library is free software; you can redi...
39.22695
83
0.513108
2,780
0.502622
0
0
0
0
0
0
3,239
0.585608
13b42a597f46ffd75065d8212ea8951934240d0a
9,253
py
Python
tests/clientlib_test.py
yoavcaspi/pre-commit
77947f212e7b88a479dbe6feebc60a9f773e8c13
[ "MIT" ]
null
null
null
tests/clientlib_test.py
yoavcaspi/pre-commit
77947f212e7b88a479dbe6feebc60a9f773e8c13
[ "MIT" ]
null
null
null
tests/clientlib_test.py
yoavcaspi/pre-commit
77947f212e7b88a479dbe6feebc60a9f773e8c13
[ "MIT" ]
null
null
null
from __future__ import unicode_literals import logging import cfgv import pytest import pre_commit.constants as C from pre_commit.clientlib import check_type_tag from pre_commit.clientlib import CONFIG_HOOK_DICT from pre_commit.clientlib import CONFIG_REPO_DICT from pre_commit.clientlib import CONFIG_SCHEMA from pre...
29.189274
78
0.556576
0
0
0
0
5,018
0.542311
0
0
2,408
0.26024
13b520f65af9148fce1413d5d355fa797126e985
5,494
py
Python
ikalog/ui/options.py
fetus-hina/IkaLog
bd476da541fcc296f792d4db76a6b9174c4777ad
[ "Apache-2.0" ]
285
2015-08-15T14:38:38.000Z
2022-02-18T15:00:06.000Z
ikalog/ui/options.py
fetus-hina/IkaLog
bd476da541fcc296f792d4db76a6b9174c4777ad
[ "Apache-2.0" ]
323
2015-09-24T12:21:34.000Z
2018-05-06T16:34:54.000Z
ikalog/ui/options.py
fetus-hina/IkaLog
bd476da541fcc296f792d4db76a6b9174c4777ad
[ "Apache-2.0" ]
72
2015-08-22T00:18:54.000Z
2022-02-18T14:44:20.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # IkaLog # ====== # Copyright (C) 2015 Takeshi HASEGAWA # # 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/l...
32.508876
80
0.630142
4,556
0.829268
0
0
0
0
0
0
1,033
0.188023
13b61f77d9db0538ba6a1a1c9673544d53143882
584
py
Python
setup.py
CyberTKR/Simple-LINELIB
8596afb6b201b13675a0ed6314b3151f6bbf208b
[ "BSD-3-Clause" ]
4
2022-02-20T11:27:29.000Z
2022-03-05T00:50:05.000Z
setup.py
CyberTKR/Simple-LINELIB
8596afb6b201b13675a0ed6314b3151f6bbf208b
[ "BSD-3-Clause" ]
null
null
null
setup.py
CyberTKR/Simple-LINELIB
8596afb6b201b13675a0ed6314b3151f6bbf208b
[ "BSD-3-Clause" ]
null
null
null
from setuptools import setup, find_packages with open("README.md", 'r',encoding="utf-8") as f: long_description = f.read() setup( name='LineBot', version='0.1.0', description='Simple-LINELIB', long_description=long_description, author='Tolg KR', author_email='[email protected]', url=...
25.391304
61
0.628425
0
0
0
0
0
0
0
0
206
0.35274
13b64cfd2fd1152628636d4313ba611c18b0ee8d
4,552
py
Python
lib/SeparateDriver/CgwshDeviceDriverSetParameterECDB.py
multi-service-fabric/element-manager
e550d1b5ec9419f1fb3eb6e058ce46b57c92ee2f
[ "Apache-2.0" ]
null
null
null
lib/SeparateDriver/CgwshDeviceDriverSetParameterECDB.py
multi-service-fabric/element-manager
e550d1b5ec9419f1fb3eb6e058ce46b57c92ee2f
[ "Apache-2.0" ]
null
null
null
lib/SeparateDriver/CgwshDeviceDriverSetParameterECDB.py
multi-service-fabric/element-manager
e550d1b5ec9419f1fb3eb6e058ce46b57c92ee2f
[ "Apache-2.0" ]
1
2020-04-02T01:17:43.000Z
2020-04-02T01:17:43.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- # Copyright(c) 2019 Nippon Telegraph and Telephone Corporation # Filename: CgwshDeviceDriverSetParameterECDB.py ''' Parameter module for Cgwsh driver configuration ''' import GlobalModule from EmCommonLog import decorater_log from DriverSetParameterECDB import Dr...
32.985507
79
0.530097
4,204
0.92355
0
0
4,022
0.883568
0
0
1,798
0.394991
13b73188b11fd452c2465eac91ddbc3efbb01c8c
13,767
py
Python
scripts/common_lib/build_lib.py
Bhaskers-Blu-Org1/wc-devops-utilities
d8131261cb3d67ce872b541c5e2d8ff22fcbf614
[ "Apache-2.0" ]
15
2018-06-26T19:48:08.000Z
2021-01-18T13:29:16.000Z
scripts/common_lib/build_lib.py
Bhaskers-Blu-Org1/wc-devops-utilities
d8131261cb3d67ce872b541c5e2d8ff22fcbf614
[ "Apache-2.0" ]
16
2018-05-29T08:12:38.000Z
2022-02-15T15:25:14.000Z
scripts/common_lib/build_lib.py
IBM/wc-devops-utilities
d8131261cb3d67ce872b541c5e2d8ff22fcbf614
[ "Apache-2.0" ]
21
2018-05-29T11:54:05.000Z
2021-12-20T06:42:54.000Z
#!/usr/bin/env python3.6 import os import subprocess import json import argparse import zipfile import shutil import requests import datetime import re import operator import unicodedata # global list of error messages to keep track of all error msgs errorMessages = [] """ Collection of Common Functions used by Buil...
36.81016
145
0.648217
0
0
0
0
0
0
0
0
6,866
0.498729
13b7df8dc09a874c18b0de4987e789a5a8c1dfcd
10,035
py
Python
src/static_grasp_kt.py
ivalab/GraspKpNet
d4b6186d74ac82a745d778892742d52a204bd1cf
[ "MIT" ]
16
2021-05-04T23:08:47.000Z
2022-01-19T08:33:14.000Z
src/static_grasp_kt.py
ivalab/GraspKpNet
d4b6186d74ac82a745d778892742d52a204bd1cf
[ "MIT" ]
2
2021-06-22T22:54:44.000Z
2021-10-04T19:23:35.000Z
src/static_grasp_kt.py
ivalab/GraspKpNet
d4b6186d74ac82a745d778892742d52a204bd1cf
[ "MIT" ]
2
2021-07-10T12:51:29.000Z
2022-02-17T06:45:54.000Z
from __future__ import absolute_import from __future__ import division from __future__ import print_function import _init_paths import os import json import cv2 import cv2.aruco as aruco import numpy as np import sys import rospy from std_msgs.msg import Bool from std_msgs.msg import Float64MultiArray from sensor_ms...
34.249147
107
0.623019
0
0
0
0
0
0
0
0
1,923
0.191629
13b8dc2efbc6e5399774e3bdb1583b1ec3d22dca
13,278
py
Python
source/utils/augmentations.py
dovietchinh/multi-task-classification
23a70300a7a800bc982f87902b6aa1faaf91b489
[ "RSA-MD" ]
null
null
null
source/utils/augmentations.py
dovietchinh/multi-task-classification
23a70300a7a800bc982f87902b6aa1faaf91b489
[ "RSA-MD" ]
null
null
null
source/utils/augmentations.py
dovietchinh/multi-task-classification
23a70300a7a800bc982f87902b6aa1faaf91b489
[ "RSA-MD" ]
null
null
null
import numpy as np import cv2 import random def preprocess(img,img_size,padding=True): """[summary] Args: img (np.ndarray): images img_size (int,list,tuple): target size. eg: 224 , (224,224) or [224,224] padding (bool): padding img before resize. Prevent from image distortion. Default...
42.694534
131
0.581865
11,857
0.892981
0
0
0
0
0
0
2,304
0.17352
13b9386ce9cd9ff6be8dca6211a1ab2dc6917f81
7,340
py
Python
BaseTools/Source/Python/GenFds/CapsuleData.py
James992927108/uEFI_Edk2_Practice
2cac7618dfee10bfa5104a2e167c85425fde0100
[ "BSD-2-Clause" ]
6
2020-01-10T05:16:15.000Z
2022-01-06T17:41:58.000Z
BaseTools/Source/Python/GenFds/CapsuleData.py
James992927108/uEFI_Edk2_Practice
2cac7618dfee10bfa5104a2e167c85425fde0100
[ "BSD-2-Clause" ]
null
null
null
BaseTools/Source/Python/GenFds/CapsuleData.py
James992927108/uEFI_Edk2_Practice
2cac7618dfee10bfa5104a2e167c85425fde0100
[ "BSD-2-Clause" ]
3
2018-04-21T07:59:33.000Z
2018-04-23T02:06:01.000Z
## @file # generate capsule # # Copyright (c) 2007-2017, Intel Corporation. All rights reserved.<BR> # # This program and the accompanying materials # are licensed and made available under the terms and conditions of the BSD License # which accompanies this distribution. The full text of the license may be found a...
29.837398
143
0.568665
6,376
0.868665
0
0
0
0
0
0
2,499
0.340463
13b9d127851e263bb83cf946e93cc967e190ce5a
453
py
Python
CalculatingPi/pi_linear_plot.py
davidmallasen/Hello_MPI
8a5b5694ffc1515d2bb2dee45355f92f1b68fbed
[ "MIT" ]
null
null
null
CalculatingPi/pi_linear_plot.py
davidmallasen/Hello_MPI
8a5b5694ffc1515d2bb2dee45355f92f1b68fbed
[ "MIT" ]
null
null
null
CalculatingPi/pi_linear_plot.py
davidmallasen/Hello_MPI
8a5b5694ffc1515d2bb2dee45355f92f1b68fbed
[ "MIT" ]
null
null
null
import matplotlib.pyplot as plt import numpy as np # Read data size = [] time = [] with open("pi_linear.txt") as file: for line in file.readlines(): x, y = line.split(',') size.append(int(x.strip())) time.append(float(y.strip())) # Plot data fig, ax = plt.subplots() ax.plot(size, tim...
19.695652
50
0.611479
0
0
0
0
0
0
0
0
102
0.225166
13bb8f895f0b886cb437c77e5bc0bd429007f636
2,193
py
Python
esque_wire/protocol/structs/api/elect_preferred_leaders_response.py
real-digital/esque-wire
eb02c49f38b89ad5e5d25aad15fb4ad795e52807
[ "MIT" ]
null
null
null
esque_wire/protocol/structs/api/elect_preferred_leaders_response.py
real-digital/esque-wire
eb02c49f38b89ad5e5d25aad15fb4ad795e52807
[ "MIT" ]
7
2019-11-26T08:19:49.000Z
2021-03-15T14:27:47.000Z
esque_wire/protocol/structs/api/elect_preferred_leaders_response.py
real-digital/esque-wire
eb02c49f38b89ad5e5d25aad15fb4ad795e52807
[ "MIT" ]
null
null
null
from typing import ClassVar, List, Optional from ...constants import ApiKey, ErrorCode from ..base import ResponseData class PartitionResult: partition_id: int error_code: ErrorCode error_message: Optional[str] def __init__(self, partition_id: int, error_code: ErrorCode, error_message: Optional[str...
36.55
112
0.690378
2,064
0.941176
0
0
0
0
0
0
1,054
0.48062
13bc25bc6434cc017d92bbc47c055999ff8c038c
3,181
py
Python
tests/stack_test.py
arthurlogilab/py_zipkin
8e733506c399967ea74c56b99a9a421e1bb1736a
[ "Apache-2.0" ]
225
2016-09-16T17:57:51.000Z
2022-02-12T22:15:32.000Z
tests/stack_test.py
arthurlogilab/py_zipkin
8e733506c399967ea74c56b99a9a421e1bb1736a
[ "Apache-2.0" ]
156
2016-09-17T03:50:04.000Z
2021-03-17T23:19:40.000Z
tests/stack_test.py
arthurlogilab/py_zipkin
8e733506c399967ea74c56b99a9a421e1bb1736a
[ "Apache-2.0" ]
53
2016-09-20T18:34:08.000Z
2021-08-31T06:14:03.000Z
import mock import pytest import py_zipkin.storage @pytest.fixture(autouse=True, scope="module") def create_zipkin_attrs(): # The following tests all expect _thread_local.zipkin_attrs to exist: if it # doesn't, mock.patch will fail. py_zipkin.storage.ThreadLocalStack().get() def test_get_zipkin_attrs_r...
34.576087
83
0.727759
0
0
0
0
236
0.074191
0
0
381
0.119774
13bd80e7104701ce224a3004f95e9aa8f8c681e9
2,293
py
Python
myapp/processes/plotter.py
cp4cds/cp4cds-wps-template
ed170fcee72146dc07c64f76ec71cc289672fd32
[ "Apache-2.0" ]
null
null
null
myapp/processes/plotter.py
cp4cds/cp4cds-wps-template
ed170fcee72146dc07c64f76ec71cc289672fd32
[ "Apache-2.0" ]
null
null
null
myapp/processes/plotter.py
cp4cds/cp4cds-wps-template
ed170fcee72146dc07c64f76ec71cc289672fd32
[ "Apache-2.0" ]
null
null
null
from pywps import Process, LiteralInput, ComplexInput, ComplexOutput from pywps import Format import logging LOGGER = logging.getLogger('PYWPS') import matplotlib # no X11 server ... must be run first # https://github.com/matplotlib/matplotlib/issues/3466/ matplotlib.use('Agg') import matplotlib.pylab as plt import...
32.295775
115
0.613171
1,412
0.615787
0
0
0
0
0
0
529
0.230702
13be33895810fafc0b133ddfa170c7d200a7bd44
56
py
Python
json_schema_checker/composed/__init__.py
zorgulle/json_schema_checker
20cac68f899528619e5059f0e1fbee0a0f7219d6
[ "MIT" ]
null
null
null
json_schema_checker/composed/__init__.py
zorgulle/json_schema_checker
20cac68f899528619e5059f0e1fbee0a0f7219d6
[ "MIT" ]
null
null
null
json_schema_checker/composed/__init__.py
zorgulle/json_schema_checker
20cac68f899528619e5059f0e1fbee0a0f7219d6
[ "MIT" ]
null
null
null
from .composed import List from .composed import IntList
28
29
0.839286
0
0
0
0
0
0
0
0
0
0
13beebf4acd9b21bb28b852b68ff91457137cd72
9,767
py
Python
backend/social_quiz.py
jmigual/socialQuiz
3d9d0980961619b555732899121d8ce6366fa96f
[ "MIT" ]
null
null
null
backend/social_quiz.py
jmigual/socialQuiz
3d9d0980961619b555732899121d8ce6366fa96f
[ "MIT" ]
null
null
null
backend/social_quiz.py
jmigual/socialQuiz
3d9d0980961619b555732899121d8ce6366fa96f
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- import json import os.path import random import re from flask import Flask, send_from_directory from flask import request, abort from flaskrun.flaskrun import flask_run import datab.social_database as db app = Flask(__name__) # Regular expression to only accept certain files fileChecker = r...
33.221088
115
0.61288
0
0
0
0
9,163
0.938159
0
0
2,783
0.284939
13bef8558df71652db939d620d20eb4457b48c53
10,282
py
Python
astacus/node/snapshotter.py
aiven/astacus
2d64e1f33e01d50a41127f41d9da3d1ab0ce0387
[ "Apache-2.0" ]
19
2020-06-22T12:17:59.000Z
2022-02-18T00:12:17.000Z
astacus/node/snapshotter.py
aiven/astacus
2d64e1f33e01d50a41127f41d9da3d1ab0ce0387
[ "Apache-2.0" ]
7
2020-06-24T05:16:20.000Z
2022-02-28T07:35:31.000Z
astacus/node/snapshotter.py
aiven/astacus
2d64e1f33e01d50a41127f41d9da3d1ab0ce0387
[ "Apache-2.0" ]
2
2020-09-05T21:23:08.000Z
2022-02-17T15:02:37.000Z
""" Copyright (c) 2020 Aiven Ltd See LICENSE for details """ from astacus.common import magic, utils from astacus.common.ipc import SnapshotFile, SnapshotHash, SnapshotState from astacus.common.progress import increase_worth_reporting, Progress from pathlib import Path from typing import Optional import base64 impo...
41.128
122
0.642774
9,629
0.936491
1,042
0.101342
0
0
0
0
2,185
0.212507
13c016b99333655007d9a8cc82e9391a0d3526d8
6,671
py
Python
colcon_gradle/task/gradle/build.py
richiware/colcon-gradle
00b121def8c15abd1dca310d0ea4e1f34f98f4d1
[ "Apache-2.0" ]
null
null
null
colcon_gradle/task/gradle/build.py
richiware/colcon-gradle
00b121def8c15abd1dca310d0ea4e1f34f98f4d1
[ "Apache-2.0" ]
null
null
null
colcon_gradle/task/gradle/build.py
richiware/colcon-gradle
00b121def8c15abd1dca310d0ea4e1f34f98f4d1
[ "Apache-2.0" ]
null
null
null
# Copyright 2018 Esteve Fernandez # Licensed under the Apache License, Version 2.0 from distutils import dir_util import glob import os from pathlib import Path import shutil from colcon_core.environment import create_environment_scripts from colcon_core.logging import colcon_logger from colcon_core.plugin_system imp...
37.268156
95
0.644431
5,915
0.886674
0
0
0
0
4,618
0.69225
1,210
0.181382
13c18896742aca9b72a3db6ff3b991575fad3170
5,092
py
Python
model_compression_toolkit/keras/quantizer/gradient_ptq/utils.py
eladc-git/model_optimization
46d1c893ca23e61d8ef7597184ad2ba6e2ae6e7a
[ "Apache-2.0" ]
null
null
null
model_compression_toolkit/keras/quantizer/gradient_ptq/utils.py
eladc-git/model_optimization
46d1c893ca23e61d8ef7597184ad2ba6e2ae6e7a
[ "Apache-2.0" ]
null
null
null
model_compression_toolkit/keras/quantizer/gradient_ptq/utils.py
eladc-git/model_optimization
46d1c893ca23e61d8ef7597184ad2ba6e2ae6e7a
[ "Apache-2.0" ]
null
null
null
# Copyright 2021 Sony Semiconductors Israel, Inc. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required b...
34.876712
125
0.626866
0
0
0
0
0
0
0
0
2,460
0.483111
13c2b5d7ceaee0819464ed2dba5f6801b590f3e0
9,421
py
Python
pygments/lexers/tnt.py
btashton/pygments
ceaad0372055ed0064121020fea032fdda429779
[ "BSD-2-Clause" ]
1
2020-05-04T00:34:41.000Z
2020-05-04T00:34:41.000Z
pygments/lexers/tnt.py
btashton/pygments
ceaad0372055ed0064121020fea032fdda429779
[ "BSD-2-Clause" ]
1
2019-03-08T20:01:19.000Z
2019-03-08T20:01:19.000Z
pygments/lexers/tnt.py
btashton/pygments
ceaad0372055ed0064121020fea032fdda429779
[ "BSD-2-Clause" ]
1
2019-03-08T19:44:02.000Z
2019-03-08T19:44:02.000Z
# -*- coding: utf-8 -*- """ pygments.lexers.tnt ~~~~~~~~~~~~~~~~~~~ Lexer for Typographic Number Theory. :copyright: Copyright 2019-2020 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ import re from pygments.lexer import Lexer from pygments.token import Text, Commen...
37.987903
85
0.519478
9,030
0.956771
0
0
0
0
0
0
1,947
0.206294
13c2bfaf0d362a6c304791ee3c1accf9f548727b
1,233
py
Python
contacts/urls.py
cheradenine/Django-CRM
692572ced050d314c1f880af8b4000c97cbf7440
[ "MIT" ]
2
2019-08-30T14:42:45.000Z
2019-09-01T01:49:38.000Z
contacts/urls.py
cheradenine/Django-CRM
692572ced050d314c1f880af8b4000c97cbf7440
[ "MIT" ]
8
2020-06-05T20:58:52.000Z
2022-03-11T23:48:48.000Z
contacts/urls.py
gthreepwood/Django-CRM
12de7e6c622d9d7483c210212c8b7fe3dbde2739
[ "MIT" ]
1
2019-05-31T16:06:24.000Z
2019-05-31T16:06:24.000Z
from django.urls import path from contacts.views import ( ContactsListView, CreateContactView, ContactDetailView, UpdateContactView, RemoveContactView, GetContactsView, AddCommentView, UpdateCommentView, DeleteCommentView, AddAttachmentsView, DeleteAttachmentsView) app_name = 'contacts' urlpatterns =...
36.264706
77
0.691809
0
0
0
0
0
0
0
0
325
0.263585
13c4fe2bf0cd10d5be8344221103967c7cea77fd
12,883
py
Python
windows/winobject/network.py
marpie/PythonForWindows
b253bc5873e7d97087ed22f2753b51fc6880ec18
[ "BSD-3-Clause" ]
1
2018-11-15T11:15:56.000Z
2018-11-15T11:15:56.000Z
windows/winobject/network.py
killvxk/PythonForWindows
b253bc5873e7d97087ed22f2753b51fc6880ec18
[ "BSD-3-Clause" ]
null
null
null
windows/winobject/network.py
killvxk/PythonForWindows
b253bc5873e7d97087ed22f2753b51fc6880ec18
[ "BSD-3-Clause" ]
1
2020-12-25T12:59:10.000Z
2020-12-25T12:59:10.000Z
import windows import ctypes import socket import struct from windows import winproxy import windows.generated_def as gdef from windows.com import interfaces as cominterfaces from windows.generated_def.winstructs import * from windows.generated_def.windef import * class TCP4Connection(MIB_TCPROW_OWNER_PID): """A...
28.756696
134
0.623613
12,070
0.936894
0
0
9,291
0.721183
0
0
3,753
0.291314
13c55ddf22e3a453950de6b6142214790512cd06
4,269
py
Python
LIM_scripts/func_curry.py
Bhare8972/LOFAR-LIM
89f25be8c02cb8980c2e237da3eaac279d40a06a
[ "MIT" ]
3
2019-04-21T13:13:02.000Z
2020-10-15T12:44:23.000Z
LIM_scripts/func_curry.py
Bhare8972/LOFAR-LIM
89f25be8c02cb8980c2e237da3eaac279d40a06a
[ "MIT" ]
null
null
null
LIM_scripts/func_curry.py
Bhare8972/LOFAR-LIM
89f25be8c02cb8980c2e237da3eaac279d40a06a
[ "MIT" ]
2
2018-11-06T18:34:33.000Z
2019-04-04T14:16:57.000Z
#!/usr/bin/env python3 # Coded by Massimiliano Tomassoli, 2012. # # - Thanks to b49P23TIvg for suggesting that I should use a set operation # instead of repeated membership tests. # - Thanks to Ian Kelly for pointing out that # - "minArgs = None" is better than "minArgs = -1", # - "if args" is better than ...
38.809091
84
0.444601
0
0
0
0
0
0
0
0
1,741
0.407824
13c5d0054209f9afb389d03f1764cab446c01a96
742
py
Python
src/messages.py
Ewpratten/chat
4cc8461e442b6530b7874f234b1a2261f3db8456
[ "MIT" ]
null
null
null
src/messages.py
Ewpratten/chat
4cc8461e442b6530b7874f234b1a2261f3db8456
[ "MIT" ]
null
null
null
src/messages.py
Ewpratten/chat
4cc8461e442b6530b7874f234b1a2261f3db8456
[ "MIT" ]
null
null
null
greeting = """ --------------- BEGIN SESSION --------------- You have connected to a chat server. Welcome! :: About Chat is a small piece of server software written by Evan Pratten to allow people to talk to eachother from any computer as long as it has an internet connection. (Even an arduino!). Check out the proje...
32.26087
45
0.690027
0
0
0
0
0
0
0
0
731
0.985175
13c625629058a335547038a4cdc3550a5d9f78a2
3,572
py
Python
Prediction.py
khayam-hafezi/CRNN-keras-persian
3f99838e5b3b0e0ca79899e25b0648940b7fdfac
[ "MIT" ]
null
null
null
Prediction.py
khayam-hafezi/CRNN-keras-persian
3f99838e5b3b0e0ca79899e25b0648940b7fdfac
[ "MIT" ]
null
null
null
Prediction.py
khayam-hafezi/CRNN-keras-persian
3f99838e5b3b0e0ca79899e25b0648940b7fdfac
[ "MIT" ]
null
null
null
import cv2 import itertools, os, time import numpy as np from Model import get_Model from parameter import letters import argparse from keras import backend as K K.set_learning_phase(0) Region = {"A": "서울 ", "B": "경기 ", "C": "인천 ", "D": "강원 ", "E": "충남 ", "F": "대전 ", "G": "충북 ", "H": "부산 ", "I": "울산 ", "J": ...
32.472727
129
0.555151
0
0
0
0
0
0
0
0
1,218
0.328302
13c705bea50bc8d33e8f2c2e57d0e51683dbf67b
8,038
py
Python
torcharrow/_interop.py
OswinC/torcharrow
45a57c45afeffee488c51e3387179292b3504a6c
[ "BSD-3-Clause" ]
null
null
null
torcharrow/_interop.py
OswinC/torcharrow
45a57c45afeffee488c51e3387179292b3504a6c
[ "BSD-3-Clause" ]
null
null
null
torcharrow/_interop.py
OswinC/torcharrow
45a57c45afeffee488c51e3387179292b3504a6c
[ "BSD-3-Clause" ]
null
null
null
# Copyright (c) Facebook, Inc. and its affiliates. from typing import List, Optional, cast # Skipping analyzing 'numpy': found module but no type hints or library stubs import numpy as np # type: ignore import numpy.ma as ma # type: ignore # Skipping analyzing 'pandas': found module but no type hints or library stu...
31.155039
99
0.61682
0
0
75
0.009331
0
0
0
0
2,340
0.291117
13c7d55115d132308c18e527238726863764f8de
3,883
py
Python
research/gan/image_compression/eval.py
jdavidagudelo/tensorflow-models
6f019beec73b01861363bf717706e27f4210b979
[ "Apache-2.0" ]
1
2021-05-17T01:42:29.000Z
2021-05-17T01:42:29.000Z
research/gan/image_compression/eval.py
jdavidagudelo/tensorflow-models
6f019beec73b01861363bf717706e27f4210b979
[ "Apache-2.0" ]
null
null
null
research/gan/image_compression/eval.py
jdavidagudelo/tensorflow-models
6f019beec73b01861363bf717706e27f4210b979
[ "Apache-2.0" ]
null
null
null
# Copyright 2017 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
38.83
80
0.702807
0
0
0
0
0
0
0
0
1,580
0.406902
13c974d988a5a072e9adfbe93d6a9ef5022a8ab3
1,712
py
Python
source/dump_query_results.py
CheyenneNS/metrics
cfeeac6d01d99679897a998b193d630ada169c61
[ "MIT" ]
null
null
null
source/dump_query_results.py
CheyenneNS/metrics
cfeeac6d01d99679897a998b193d630ada169c61
[ "MIT" ]
null
null
null
source/dump_query_results.py
CheyenneNS/metrics
cfeeac6d01d99679897a998b193d630ada169c61
[ "MIT" ]
null
null
null
#!/usr/local/bin/python import os import mysql.connector as mysql metrics_mysql_password = os.environ['METRICS_MYSQL_PWD'] sql_host = os.environ['SQL_HOST'] metrics = os.environ['QUERY_ON'] def dump_query_results(): """ This is a simple SQL table dump of a given query so we can supply users with custom ...
33.568627
164
0.675234
0
0
0
0
0
0
0
0
854
0.498832
13c9e31c590bfc0b0cb4adceaddaadb36e84b31a
538
py
Python
desktop_local_tests/windows/test_windows_packet_capture_disrupt_force_public_dns_servers.py
UAEKondaya1/expressvpn_leak_testing
9e4cee899ac04f7820ac351fa55efdc0c01370ba
[ "MIT" ]
219
2017-12-12T09:42:46.000Z
2022-03-13T08:25:13.000Z
desktop_local_tests/windows/test_windows_packet_capture_disrupt_force_public_dns_servers.py
UAEKondaya1/expressvpn_leak_testing
9e4cee899ac04f7820ac351fa55efdc0c01370ba
[ "MIT" ]
11
2017-12-14T08:14:51.000Z
2021-08-09T18:37:45.000Z
desktop_local_tests/windows/test_windows_packet_capture_disrupt_force_public_dns_servers.py
UAEKondaya1/expressvpn_leak_testing
9e4cee899ac04f7820ac351fa55efdc0c01370ba
[ "MIT" ]
45
2017-12-14T07:26:36.000Z
2022-03-11T09:36:56.000Z
from desktop_local_tests.local_packet_capture_test_case_with_disrupter import LocalPacketCaptureTestCaseWithDisrupter from desktop_local_tests.windows.windows_dns_force_public_dns_servers_disrupter import WindowsDNSForcePublicDNSServersDisrupter class TestWindowsPacketCaptureDisruptForcePublicDNSServers(LocalPacketCap...
53.8
127
0.877323
290
0.539033
0
0
0
0
0
0
50
0.092937
13ca0867e3b5094c9f6e2eb05d9af7e3c93bd96a
16,159
py
Python
kivy/loader.py
geojeff/kivy
25ab20e5b0e87269531abe1f8cc76bf270bcc755
[ "MIT" ]
1
2017-11-15T08:59:23.000Z
2017-11-15T08:59:23.000Z
kivy/loader.py
5y/kivy
6bee66946f5434ca92921a8bc9559d82ec955896
[ "MIT" ]
null
null
null
kivy/loader.py
5y/kivy
6bee66946f5434ca92921a8bc9559d82ec955896
[ "MIT" ]
3
2015-07-18T11:03:59.000Z
2018-03-17T01:32:42.000Z
''' Asynchronous data loader ======================== This is the Asynchronous Loader. You can use it to load an image and use it, even if data are not yet available. You must specify a default loading image for using a such loader:: from kivy import * image = Loader.image('mysprite.png') You can also load i...
31.684314
80
0.590692
14,356
0.888421
0
0
0
0
0
0
6,295
0.389566
13ca207f4f2fb0793c69bd95418294b71cd89e2c
467
py
Python
Season 01 - Intro to Python/Episode 13 - Join.py
Pythobit/Python-tutorial
b0743eaa9c237c3578131ead1b3f2c295f11b7ee
[ "MIT" ]
3
2021-02-19T18:33:00.000Z
2021-08-03T14:56:50.000Z
Season 01 - Intro to Python/Episode 13 - Join.py
barawalojas/Python-tutorial
3f4b2b073e421888b3d62ff634658317d9abcb9b
[ "MIT" ]
1
2021-07-10T14:37:57.000Z
2021-07-20T09:51:39.000Z
Season 01 - Intro to Python/Episode 13 - Join.py
barawalojas/Python-tutorial
3f4b2b073e421888b3d62ff634658317d9abcb9b
[ "MIT" ]
1
2021-08-02T05:39:38.000Z
2021-08-02T05:39:38.000Z
# 13. Join # it allows to print list a bit better friends = ['Pythobit','boy','Pythoman'] print(f'My friends are {friends}.') # Output - My friends are ['Pythobit', 'boy', 'Pythoman']. # So, the Output needs to be a bit clearer. friends = ['Pythobit','boy','Pythoman'] friend = ', '.join(friends) print(f'My friend...
38.916667
98
0.663812
0
0
0
0
0
0
0
0
379
0.811563
13caf57909dc254d637b57702b6b442c435e3b48
2,327
py
Python
buildsettings.py
randomizax/polygon-label
5091bd54aee5166d418b240f34d7a5c336685c06
[ "MIT" ]
null
null
null
buildsettings.py
randomizax/polygon-label
5091bd54aee5166d418b240f34d7a5c336685c06
[ "MIT" ]
null
null
null
buildsettings.py
randomizax/polygon-label
5091bd54aee5166d418b240f34d7a5c336685c06
[ "MIT" ]
null
null
null
# settings file for builds. # if you want to have custom builds, copy this file to "localbuildsettings.py" and make changes there. # possible fields: # resourceBaseUrl - optional - the URL base for external resources (all resources embedded in standard IITC) # distUrlBase - optional - the base URL to use for update c...
42.309091
151
0.701762
0
0
0
0
0
0
0
0
2,063
0.886549
13cbb884947e5c5ee43f164c1fde11e81811776b
4,399
py
Python
osaka/storage/sftp.py
riverma/osaka
f9ed386936500303c629d7213d91215085bcf346
[ "Apache-2.0" ]
2
2018-05-08T03:13:49.000Z
2022-02-09T08:48:06.000Z
osaka/storage/sftp.py
riverma/osaka
f9ed386936500303c629d7213d91215085bcf346
[ "Apache-2.0" ]
6
2019-02-06T19:12:09.000Z
2022-02-08T04:29:49.000Z
osaka/storage/sftp.py
riverma/osaka
f9ed386936500303c629d7213d91215085bcf346
[ "Apache-2.0" ]
12
2018-04-08T12:58:29.000Z
2022-03-31T18:35:53.000Z
from __future__ import print_function from __future__ import unicode_literals from __future__ import division from __future__ import absolute_import from builtins import int from future import standard_library standard_library.install_aliases() import os import os.path import stat import urllib.parse import paramiko...
30.130137
90
0.562855
3,967
0.901796
0
0
261
0.059332
0
0
1,620
0.368266
13cc4a79cdbfb09ff64440ffca1bacc5cc651798
4,192
py
Python
thesis/pettingzoo/butterfly/cooperative_pong/cake_paddle.py
heavenlysf/thesis
646553c45860f337c91a48ab7f666a174784472f
[ "MIT" ]
null
null
null
thesis/pettingzoo/butterfly/cooperative_pong/cake_paddle.py
heavenlysf/thesis
646553c45860f337c91a48ab7f666a174784472f
[ "MIT" ]
null
null
null
thesis/pettingzoo/butterfly/cooperative_pong/cake_paddle.py
heavenlysf/thesis
646553c45860f337c91a48ab7f666a174784472f
[ "MIT" ]
null
null
null
import os os.environ["PYGAME_HIDE_SUPPORT_PROMPT"] = "hide" import pygame RENDER_RATIO = 2 class CakePaddle(pygame.sprite.Sprite): def __init__(self, speed=12): # surf is the right-most (largest) tier of the cake self.surf = pygame.Surface((30 // RENDER_RATIO, 120 // RENDER_RATIO)) self....
34.644628
77
0.530057
4,096
0.977099
0
0
0
0
0
0
579
0.13812
13cd2bb4addf837c7a09ba721bc230b691ca3e1b
2,080
py
Python
src/internal_representation_analysis/decoder/StateDataset.py
aidkilda/understanding-drl-navigation
0d637c2390a935ec1182d4f2d5165644d98d6404
[ "MIT" ]
null
null
null
src/internal_representation_analysis/decoder/StateDataset.py
aidkilda/understanding-drl-navigation
0d637c2390a935ec1182d4f2d5165644d98d6404
[ "MIT" ]
null
null
null
src/internal_representation_analysis/decoder/StateDataset.py
aidkilda/understanding-drl-navigation
0d637c2390a935ec1182d4f2d5165644d98d6404
[ "MIT" ]
null
null
null
import random from internal_representation_analysis.network import ActorCriticFFNetwork from internal_representation_analysis.scene_loader import THORDiscreteEnvironment as Environment from internal_representation_analysis.constants import MINI_BATCH_SIZE class StateDataset(object): def __init__(self, states): ...
38.518519
96
0.669712
1,819
0.874519
0
0
0
0
0
0
0
0
13cd2ed4d981d4b892a318dfe3960eb2c118e4ce
3,147
py
Python
test_dataset_model.py
ferrine/PerceptualSimilarity
2ff66e86b12dbfbc337991def71b09e3b86d4b12
[ "BSD-2-Clause" ]
null
null
null
test_dataset_model.py
ferrine/PerceptualSimilarity
2ff66e86b12dbfbc337991def71b09e3b86d4b12
[ "BSD-2-Clause" ]
null
null
null
test_dataset_model.py
ferrine/PerceptualSimilarity
2ff66e86b12dbfbc337991def71b09e3b86d4b12
[ "BSD-2-Clause" ]
null
null
null
import numpy as np from models import dist_model as dm from data import data_loader as dl import argparse from IPython import embed parser = argparse.ArgumentParser() parser.add_argument("--dataset_mode", type=str, default="2afc", help="[2afc,jnd]") parser.add_argument( "--datasets", type=str, nargs="+", ...
30.553398
218
0.67048
0
0
0
0
0
0
0
0
1,365
0.433746
13cde4f4ec9916ff8a799bc071fde32fd8bf29b3
2,461
py
Python
plotter.py
StrangeTcy/pathnet-pytorch
58c8088b992ad2f36b843186d93edc872d547c7b
[ "BSD-3-Clause" ]
86
2017-04-05T13:03:13.000Z
2022-03-28T12:38:48.000Z
plotter.py
StrangeTcy/pathnet-pytorch
58c8088b992ad2f36b843186d93edc872d547c7b
[ "BSD-3-Clause" ]
7
2017-04-30T20:59:46.000Z
2019-02-09T10:56:40.000Z
plotter.py
StrangeTcy/pathnet-pytorch
58c8088b992ad2f36b843186d93edc872d547c7b
[ "BSD-3-Clause" ]
21
2017-04-05T23:42:39.000Z
2021-11-17T21:17:22.000Z
import argparse import os import pickle import numpy as np import matplotlib.pyplot as plt plt.style.use('ggplot') parser = argparse.ArgumentParser(description='PyTorch MNIST Example') parser.add_argument('--mnist', action='store_true', default=False, help='open mnist result') args = parser.parse_a...
28.952941
95
0.603007
0
0
0
0
0
0
0
0
295
0.11987
13ce074cf333bc82bde9c49d1dbfefb77ad96d57
715
py
Python
kindler/solver/optimizer.py
mingruimingrui/kindler
8a9c2278b607a167b0ce827b218e54949a1120e7
[ "MIT" ]
null
null
null
kindler/solver/optimizer.py
mingruimingrui/kindler
8a9c2278b607a167b0ce827b218e54949a1120e7
[ "MIT" ]
null
null
null
kindler/solver/optimizer.py
mingruimingrui/kindler
8a9c2278b607a167b0ce827b218e54949a1120e7
[ "MIT" ]
null
null
null
import torch def make_sgd_optimizer( model, base_lr=0.001, bias_lr_factor=2.0, momentum=0.9, weight_decay=0.0005, weight_decay_bias=0.0, ): params = [] for key, value in model.named_parameters(): if not value.requires_grad: continue param_lr = base_lr ...
22.34375
67
0.601399
0
0
0
0
0
0
0
0
32
0.044755
13ce147cc376d9100195efcbf75606622c35be95
2,805
py
Python
platypus/tests/test_operators.py
sctiwari/EZFF_ASE
94710d4cf778ff2db5e6df0cd6d10d92e1b98afe
[ "MIT" ]
2
2021-05-10T16:28:50.000Z
2021-12-15T04:03:34.000Z
platypus/tests/test_operators.py
sctiwari/EZFF_ASE
94710d4cf778ff2db5e6df0cd6d10d92e1b98afe
[ "MIT" ]
null
null
null
platypus/tests/test_operators.py
sctiwari/EZFF_ASE
94710d4cf778ff2db5e6df0cd6d10d92e1b98afe
[ "MIT" ]
null
null
null
# Copyright 2015-2018 David Hadka # # This file is part of Platypus, a Python module for designing and using # evolutionary algorithms (EAs) and multiobjective evolutionary algorithms # (MOEAs). # # Platypus is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License a...
35.961538
74
0.636364
1,842
0.656684
0
0
0
0
0
0
873
0.31123
13cea3eb1b8257abf1a1958d34086a311a9082d4
6,241
py
Python
fusion_net/bilinear_sampler.py
ClovisChen/LearningCNN
cd9102a3d71f602024558d818039f5b759c92fa5
[ "Apache-2.0" ]
null
null
null
fusion_net/bilinear_sampler.py
ClovisChen/LearningCNN
cd9102a3d71f602024558d818039f5b759c92fa5
[ "Apache-2.0" ]
null
null
null
fusion_net/bilinear_sampler.py
ClovisChen/LearningCNN
cd9102a3d71f602024558d818039f5b759c92fa5
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*-are not covered by the UCLB ACP-A Licence, from __future__ import absolute_import, division, print_function import tensorflow as tf def bilinear_sampler_1d_h(input_images, x_offset, wrap_mode='border', name='bilinear_sampler', **kwargs): ''' 一维双线性采样: x_offset--输入X上...
41.331126
155
0.497196
0
0
0
0
0
0
0
0
3,733
0.527037
13cebdf8d097569317951da787d81aebd898d39b
7,125
py
Python
Supernovae.py
adamamiller/iptf16hvw-1
d674114e94b5b20398d2e4208b55eb8e2394dce9
[ "MIT" ]
null
null
null
Supernovae.py
adamamiller/iptf16hvw-1
d674114e94b5b20398d2e4208b55eb8e2394dce9
[ "MIT" ]
null
null
null
Supernovae.py
adamamiller/iptf16hvw-1
d674114e94b5b20398d2e4208b55eb8e2394dce9
[ "MIT" ]
1
2018-08-21T15:17:48.000Z
2018-08-21T15:17:48.000Z
#import relevant libraries import numpy as np import pandas as pd import matplotlib.pyplot as plt from astropy.io import ascii import json from IPython.display import display, Image from specutils import Spectrum1D from astropy import units from scipy.optimize import curve_fit from scipy.interpolate import interp1d imp...
28.27381
108
0.629474
2,848
0.399719
0
0
0
0
0
0
3,309
0.464421
13cfe935b3ae2ffb5842e273c8ff7ca4cd002f6d
2,753
py
Python
userbot/plugins/alive.py
iraqis1/irqis
d95303c48b5f15dbe814454a48d847e838793713
[ "MIT" ]
null
null
null
userbot/plugins/alive.py
iraqis1/irqis
d95303c48b5f15dbe814454a48d847e838793713
[ "MIT" ]
null
null
null
userbot/plugins/alive.py
iraqis1/irqis
d95303c48b5f15dbe814454a48d847e838793713
[ "MIT" ]
null
null
null
"""Check if userbot alive. If you change these, you become the gayest gay such that even the gay world will disown you.""" import asyncio from telethon import events from telethon.tl.types import ChannelParticipantsAdmins from platform import uname from userbot import ALIVE_NAME from userbot.utils import admin_cm...
26.219048
123
0.521976
0
0
0
0
3,814
0.898892
3,772
0.888994
3,707
0.873674
13d20c58618bae1fd9184241e64ff9b913dd727d
9,313
py
Python
connector/ADBConnector.py
qiutongxue/ArknightsAutoHelper
6b97b289e9ea4e5e3f39561ef8c2217657f6ff60
[ "MIT" ]
1
2020-12-16T06:19:02.000Z
2020-12-16T06:19:02.000Z
connector/ADBConnector.py
qiutongxue/ArknightsAutoHelper
6b97b289e9ea4e5e3f39561ef8c2217657f6ff60
[ "MIT" ]
null
null
null
connector/ADBConnector.py
qiutongxue/ArknightsAutoHelper
6b97b289e9ea4e5e3f39561ef8c2217657f6ff60
[ "MIT" ]
null
null
null
import os import logging.config from random import randint import zlib import struct import socket import time from PIL import Image import config # from config import ADB_ROOT, ADB_HOST, SCREEN_SHOOT_SAVE_PATH, ShellColor, CONFIG_PATH,enable_adb_host_auto_detect, ADB_SERVER from .ADBClientSession import ADBClientSes...
36.521569
163
0.57962
7,848
0.82135
0
0
0
0
0
0
1,471
0.153951
13d25057738843cced8f3d82852dabf41375fb9a
754
py
Python
redshift_upload/base_utilities.py
douglassimonsen/redshift_upload
e549c770538f022c0b90a983ca056f3e9c16c643
[ "MIT" ]
null
null
null
redshift_upload/base_utilities.py
douglassimonsen/redshift_upload
e549c770538f022c0b90a983ca056f3e9c16c643
[ "MIT" ]
1
2022-03-12T03:50:55.000Z
2022-03-12T03:50:55.000Z
redshift_upload/base_utilities.py
douglassimonsen/redshift_upload
e549c770538f022c0b90a983ca056f3e9c16c643
[ "MIT" ]
null
null
null
import inspect import os from pathlib import Path class change_directory: """ A class for changing the working directory using a "with" statement. It takes the directory to change to as an argument. If no directory is given, it takes the directory of the file from which this function was call...
30.16
98
0.624668
695
0.921751
0
0
0
0
0
0
261
0.346154
13d2e35293cf4b36df0d8aa584ec383e80a8a174
263
py
Python
main.py
Gloriel621/MgallManager
7d5c02ab6bdc2f6c6922d4a7e021faef33d868bb
[ "MIT" ]
9
2021-12-22T11:37:23.000Z
2022-03-09T02:25:35.000Z
main.py
Gloriel621/MgallManager
7d5c02ab6bdc2f6c6922d4a7e021faef33d868bb
[ "MIT" ]
4
2021-12-16T14:26:01.000Z
2022-02-16T02:05:41.000Z
main.py
Gloriel621/MgallManager
7d5c02ab6bdc2f6c6922d4a7e021faef33d868bb
[ "MIT" ]
1
2021-12-22T12:59:57.000Z
2021-12-22T12:59:57.000Z
import sys from PyQt5.QtWidgets import QApplication from gui import MgallManager def main(): app = QApplication(sys.argv) ex = MgallManager() app.aboutToQuit.connect(ex.ExitHandler) sys.exit(app.exec_()) if __name__ == "__main__": main()
16.4375
43
0.69962
0
0
0
0
0
0
0
0
10
0.038023
13d331fdd92f5e0cc56507427afe5e4da7edb40a
636
py
Python
utils/src/adventofcode/utils/Point3D.py
dh256/adventofcode
428eec13f4cbf153333a0e359bcff23070ef6d27
[ "MIT" ]
null
null
null
utils/src/adventofcode/utils/Point3D.py
dh256/adventofcode
428eec13f4cbf153333a0e359bcff23070ef6d27
[ "MIT" ]
null
null
null
utils/src/adventofcode/utils/Point3D.py
dh256/adventofcode
428eec13f4cbf153333a0e359bcff23070ef6d27
[ "MIT" ]
null
null
null
class Point3D: def __init__(self,x,y,z): self.x = x self.y = y self.z = z ''' Returns the distance between two 3D points ''' def distance(self, value): return abs(self.x - value.x) + abs(self.y - value.y) + abs(self.z - value.z) def __eq__(self, value): ...
27.652174
84
0.561321
636
1
0
0
0
0
0
0
89
0.139937
13d3859368c4908cf2a507d1bd62d989795acc1a
54,009
py
Python
pysc2/lib/actions.py
javierrcc522/starcraft2_api_machineLear
5833ba1344ab5445c4f09fafc33e6058070ebe6c
[ "Apache-2.0" ]
2
2020-04-30T09:07:25.000Z
2021-03-21T22:58:22.000Z
pysc2/lib/actions.py
javierrcc522/starcraft2_api_machineLear
5833ba1344ab5445c4f09fafc33e6058070ebe6c
[ "Apache-2.0" ]
null
null
null
pysc2/lib/actions.py
javierrcc522/starcraft2_api_machineLear
5833ba1344ab5445c4f09fafc33e6058070ebe6c
[ "Apache-2.0" ]
null
null
null
# Copyright 2017 Google Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or ...
57.825482
100
0.750745
6,851
0.126849
0
0
2,379
0.044048
0
0
20,283
0.375549
13d4be5ff6607a768ff6f008bc6f55355c95eab1
3,209
py
Python
pywick/meters/aucmeter.py
ashishpatel26/pywick
1afffd1c21c2b188836d3599e802146182757bb5
[ "MIT" ]
2
2020-11-28T07:56:09.000Z
2021-11-08T09:30:39.000Z
pywick/meters/aucmeter.py
ashishpatel26/pywick
1afffd1c21c2b188836d3599e802146182757bb5
[ "MIT" ]
null
null
null
pywick/meters/aucmeter.py
ashishpatel26/pywick
1afffd1c21c2b188836d3599e802146182757bb5
[ "MIT" ]
null
null
null
import numbers from . import meter import numpy as np import torch class AUCMeter(meter.Meter): """ The AUCMeter measures the area under the receiver-operating characteristic (ROC) curve for binary classification problems. The area under the curve (AUC) can be interpreted as the probability that, give...
38.662651
91
0.606108
3,139
0.978186
0
0
0
0
0
0
1,194
0.372079
13d5b4c27424ce3f3958c70f0a0828815649d42f
2,971
py
Python
homeassistant/components/zha/core/channels/lighting.py
liangleslie/core
cc807b4d597daaaadc92df4a93c6e30da4f570c6
[ "Apache-2.0" ]
30,023
2016-04-13T10:17:53.000Z
2020-03-02T12:56:31.000Z
homeassistant/components/zha/core/channels/lighting.py
liangleslie/core
cc807b4d597daaaadc92df4a93c6e30da4f570c6
[ "Apache-2.0" ]
24,710
2016-04-13T08:27:26.000Z
2020-03-02T12:59:13.000Z
homeassistant/components/zha/core/channels/lighting.py
liangleslie/core
cc807b4d597daaaadc92df4a93c6e30da4f570c6
[ "Apache-2.0" ]
11,956
2016-04-13T18:42:31.000Z
2020-03-02T09:32:12.000Z
"""Lighting channels module for Zigbee Home Automation.""" from __future__ import annotations from contextlib import suppress from zigpy.zcl.clusters import lighting from .. import registries from ..const import REPORT_CONFIG_DEFAULT from .base import ClientChannel, ZigbeeChannel @registries.ZIGBEE_CHANNEL_REGISTR...
33.382022
76
0.693369
2,393
0.805453
0
0
2,678
0.90138
0
0
911
0.306631
13d60376951a923005fa671870c17c7889bfb96b
6,140
py
Python
pf/queue.py
PiRAT4/py-pf
7ffdd0a283d4a36fc4c473433d5f79a84eeb5d31
[ "BSD-3-Clause" ]
null
null
null
pf/queue.py
PiRAT4/py-pf
7ffdd0a283d4a36fc4c473433d5f79a84eeb5d31
[ "BSD-3-Clause" ]
null
null
null
pf/queue.py
PiRAT4/py-pf
7ffdd0a283d4a36fc4c473433d5f79a84eeb5d31
[ "BSD-3-Clause" ]
null
null
null
"""Classes to represent Packet Filter's queueing schedulers and statistics.""" import pf._struct from pf._base import PFObject from pf.constants import * from pf._utils import rate2str __all__ = ["ServiceCurve", "FlowQueue", "PFQueue", "PFQueueStats"] class ServiceCurve(PFObject): ...
29.95122
79
0.548534
5,839
0.950977
0
0
0
0
0
0
666
0.108469
13d646c36a3c1b8a275d4d104aa95c23081163a3
2,378
py
Python
sdk/python/pulumi_azure_native/labservices/v20181015/__init__.py
pulumi-bot/pulumi-azure-native
f7b9490b5211544318e455e5cceafe47b628e12c
[ "Apache-2.0" ]
null
null
null
sdk/python/pulumi_azure_native/labservices/v20181015/__init__.py
pulumi-bot/pulumi-azure-native
f7b9490b5211544318e455e5cceafe47b628e12c
[ "Apache-2.0" ]
null
null
null
sdk/python/pulumi_azure_native/labservices/v20181015/__init__.py
pulumi-bot/pulumi-azure-native
f7b9490b5211544318e455e5cceafe47b628e12c
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi SDK Generator. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** # Export this package's modules as members: from ._enums import * from .environment import * from .environment_setting import * from .gallery_image imp...
38.983607
102
0.710681
1,190
0.500421
0
0
0
0
0
0
555
0.233389
13d760267b20f874fc4b087de72759e81f401445
6,123
py
Python
servicedirectory/src/sd-api/users/tests/tests_serializers.py
ealogar/servicedirectory
fb4f4bfa8b499b93c03af589ef2f34c08a830b17
[ "Apache-2.0" ]
null
null
null
servicedirectory/src/sd-api/users/tests/tests_serializers.py
ealogar/servicedirectory
fb4f4bfa8b499b93c03af589ef2f34c08a830b17
[ "Apache-2.0" ]
null
null
null
servicedirectory/src/sd-api/users/tests/tests_serializers.py
ealogar/servicedirectory
fb4f4bfa8b499b93c03af589ef2f34c08a830b17
[ "Apache-2.0" ]
null
null
null
''' (c) Copyright 2013 Telefonica, I+D. Printed in Spain (Europe). All Rights Reserved. The copyright to the software program(s) is property of Telefonica I+D. The program(s) may be used and or copied only with the express written consent of Telefonica I+D or in accordance with the terms and conditions stipulated in t...
52.784483
114
0.6634
5,471
0.893516
0
0
0
0
0
0
1,948
0.318145
13d7896d6d799cba6c0e766504d5f3eea5f2e531
3,124
py
Python
Web/notifyXAPI/app/src/users/views.py
abs0lut3pwn4g3/RootersCTF2019-challenges
397a6fad0b03e55541df06e5103172ae850cd4e5
[ "MIT" ]
14
2019-10-13T07:38:04.000Z
2022-02-13T09:03:50.000Z
Web/notifyXAPI/app/src/users/views.py
abs0lut3pwn4g3/RootersCTF2019-challenges
397a6fad0b03e55541df06e5103172ae850cd4e5
[ "MIT" ]
1
2019-10-13T07:35:13.000Z
2019-10-13T08:22:48.000Z
Web/notifyXAPI/app/src/users/views.py
abs0lut3pwn4g3/RootersCTF2019-challenges
397a6fad0b03e55541df06e5103172ae850cd4e5
[ "MIT" ]
4
2019-10-13T08:21:43.000Z
2022-01-09T16:39:33.000Z
''' User views ''' from datetime import timedelta from flask import request, jsonify, make_response, redirect, json, render_template from flask_jwt_extended import (create_access_token, jwt_required) from flask_restful import Resource from flask_login import login_user, current_user from sqlalchemy.exc import Integrit...
40.571429
124
0.588348
2,468
0.790013
0
0
0
0
0
0
345
0.110435
13d7ee99520201ddee21c6a144be012df62e596b
14,211
py
Python
querybuilder/tests/window_tests.py
wesokes/django-query-builder
3cc53d33ee0a4ada515635e4be631167a774b457
[ "MIT" ]
110
2015-01-28T17:38:38.000Z
2022-02-17T02:51:55.000Z
querybuilder/tests/window_tests.py
wesokes/django-query-builder
3cc53d33ee0a4ada515635e4be631167a774b457
[ "MIT" ]
31
2015-02-17T19:57:29.000Z
2021-08-30T03:44:55.000Z
querybuilder/tests/window_tests.py
wesokes/django-query-builder
3cc53d33ee0a4ada515635e4be631167a774b457
[ "MIT" ]
33
2015-02-05T22:08:46.000Z
2021-12-06T08:12:49.000Z
from querybuilder.fields import ( RankField, RowNumberField, DenseRankField, PercentRankField, CumeDistField, NTileField, LagField, LeadField, FirstValueField, LastValueField, NthValueField, NumStdDevField ) from querybuilder.query import QueryWindow, Query from querybuilder.tests.models import Order from query...
33.916468
119
0.521779
13,818
0.972345
0
0
0
0
0
0
3,203
0.225389
13d92122cdb041cef0407b7567e1db27fbf5978f
676
py
Python
emoji/coffee.py
wbprice/ojimoji
7b1a8b5ed0062d1d52e151e7412e1131e3de7924
[ "MIT" ]
null
null
null
emoji/coffee.py
wbprice/ojimoji
7b1a8b5ed0062d1d52e151e7412e1131e3de7924
[ "MIT" ]
null
null
null
emoji/coffee.py
wbprice/ojimoji
7b1a8b5ed0062d1d52e151e7412e1131e3de7924
[ "MIT" ]
null
null
null
import numpy h = .25 s = 1 bitmap = numpy.array([ [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0], [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0], [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0], [0,0,1,1,1,1,1,1,1,1,1,0,0,0,0,0], [0,0,1,1,1,1,1,1,1,1,1,1,1,1,0,0], [0,0,1,1,1,0,1,0,1,1,1,0,0,1,0,0], [0,0,1,1,0,1,0,1,0,1,1,0,0,1,0,...
30.727273
39
0.426036
0
0
0
0
0
0
0
0
0
0
13d981ac5c1effe03cfb8f11663b3250b5130bd2
4,546
py
Python
dumpcode/npzbdt.py
gkfthddk/keras
46d96c65d69c39df298800336bbb4d867a2561fb
[ "MIT" ]
null
null
null
dumpcode/npzbdt.py
gkfthddk/keras
46d96c65d69c39df298800336bbb4d867a2561fb
[ "MIT" ]
null
null
null
dumpcode/npzbdt.py
gkfthddk/keras
46d96c65d69c39df298800336bbb4d867a2561fb
[ "MIT" ]
null
null
null
import numpy as np from sklearn.model_selection import RandomizedSearchCV, GridSearchCV from sklearn.metrics import roc_auc_score from sklearn.model_selection import StratifiedKFold from sklearn.model_selection import KFold import scipy.stats as sts import xgboost as xgb from xiter import * import pandas as pd import a...
38.525424
167
0.720853
0
0
0
0
0
0
0
0
1,440
0.316762
13dbe7e355868c585eddb2ca7609fa83a2860aed
12,384
py
Python
rlenv/StockTradingEnv0.py
watchsea/RL-Stock
53bd13a1bd1760e082c6db2ad9b010adbc3a767b
[ "MIT" ]
null
null
null
rlenv/StockTradingEnv0.py
watchsea/RL-Stock
53bd13a1bd1760e082c6db2ad9b010adbc3a767b
[ "MIT" ]
null
null
null
rlenv/StockTradingEnv0.py
watchsea/RL-Stock
53bd13a1bd1760e082c6db2ad9b010adbc3a767b
[ "MIT" ]
null
null
null
import random import json import gym from gym import spaces import pandas as pd import numpy as np MAX_ACCOUNT_BALANCE = 2147483647 MAX_NUM_SHARES = 2147483647 MAX_SHARE_PRICE = 5000 MAX_VOLUME = 1000e8 MAX_AMOUNT = 3e10 MAX_OPEN_POSITIONS = 5 MAX_STEPS = 20000 MAX_DAY_CHANGE = 1 INITIAL_ACCOUNT_BALANCE = 10000 DATA...
41.69697
127
0.581476
11,896
0.960594
0
0
0
0
0
0
3,104
0.250646
13dd331f73864377a1d0952e862e552f50ab90bf
2,053
py
Python
processing/manager.py
mrfleap/us-population-heatmap
e3f1c5d8294716ff491c7b8b40adb77929f9aeee
[ "MIT" ]
null
null
null
processing/manager.py
mrfleap/us-population-heatmap
e3f1c5d8294716ff491c7b8b40adb77929f9aeee
[ "MIT" ]
null
null
null
processing/manager.py
mrfleap/us-population-heatmap
e3f1c5d8294716ff491c7b8b40adb77929f9aeee
[ "MIT" ]
null
null
null
import json import os import pathlib import time from tqdm import tqdm from aggregator import aggregate from download import DOWNLOAD_PATH, download_files, unzip_files from tqdm.contrib.concurrent import process_map def main(): start = time.time() # print("Downloading files...") # download_files() #...
27.013158
103
0.632245
0
0
0
0
0
0
0
0
546
0.265952
13ddb1c02b1ed46330b061450969494a2a48af52
794
py
Python
gen_data.py
kshoji6011/vehicleai
135de71cce65f4a61b42c49493ed356f2d512d6c
[ "MIT" ]
null
null
null
gen_data.py
kshoji6011/vehicleai
135de71cce65f4a61b42c49493ed356f2d512d6c
[ "MIT" ]
null
null
null
gen_data.py
kshoji6011/vehicleai
135de71cce65f4a61b42c49493ed356f2d512d6c
[ "MIT" ]
null
null
null
from PIL import Image import os, glob import numpy as np from sklearn import model_selection classes = ["car", "bycycle", "motorcycle", "pedestrian"] num_class = len(classes) image_size = 50 # 画像の読み込み X = [] Y = [] for index, classlabel in enumerate(classes): photos_dir = "./" + classlabel files = glob.glob...
24.8125
73
0.644836
0
0
0
0
0
0
0
0
93
0.115099
13de3e4f691cb4b36cd9750b30e5106c02f72fb9
724
py
Python
app/main.py
immortel32/Sword_Sorcery_Story_Generator
7978dfc335813362b2d94c455b970f58421123c8
[ "MIT" ]
2
2021-04-01T00:50:22.000Z
2021-04-01T02:18:45.000Z
app/main.py
immortel32/Sword_Sorcery_Story_Generator
7978dfc335813362b2d94c455b970f58421123c8
[ "MIT" ]
1
2021-04-01T21:39:44.000Z
2021-04-01T21:39:44.000Z
app/main.py
immortel32/Sword_Sorcery_Story_Generator
7978dfc335813362b2d94c455b970f58421123c8
[ "MIT" ]
1
2021-04-01T01:03:33.000Z
2021-04-01T01:03:33.000Z
from services import waypoint_scenarios, quest_scenarios from services.build_campaign import Campaign from log_setup import log if __name__ == "__main__": number_waypoint_scenario = waypoint_scenarios.get_number_of_waypoint_scenarios() log.info(f"We have {number_waypoint_scenario} waypoint available") numb...
42.588235
84
0.809392
0
0
0
0
0
0
0
0
119
0.164365
13ded3828a8c037ea4aa78b91386fb78512809eb
326
py
Python
tests/test-recipes/metadata/ignore_some_prefix_files/run_test.py
mbargull/conda-build
ebc56f48196774301863fecbe98a32a7ded6eb7e
[ "BSD-3-Clause" ]
null
null
null
tests/test-recipes/metadata/ignore_some_prefix_files/run_test.py
mbargull/conda-build
ebc56f48196774301863fecbe98a32a7ded6eb7e
[ "BSD-3-Clause" ]
null
null
null
tests/test-recipes/metadata/ignore_some_prefix_files/run_test.py
mbargull/conda-build
ebc56f48196774301863fecbe98a32a7ded6eb7e
[ "BSD-3-Clause" ]
null
null
null
import os pkgs = os.path.join(os.environ["ROOT"], "pkgs") info_dir = os.path.join(pkgs, "conda-build-test-ignore-some-prefix-files-1.0-0", "info") has_prefix_file = os.path.join(info_dir, "has_prefix") print(info_dir) assert os.path.isfile(has_prefix_file) with open(has_prefix_file) as f: assert "test2" not in f.r...
32.6
88
0.733129
0
0
0
0
0
0
0
0
86
0.263804
13defa0932ab990d6739afd72d573b29bcd8a6e3
2,473
py
Python
distill.py
Lukeming-tsinghua/Interpretable-NN-for-IBD-diagnosis
5fb0fae774e010cdd6b63ff487a4528f0397647d
[ "MIT" ]
null
null
null
distill.py
Lukeming-tsinghua/Interpretable-NN-for-IBD-diagnosis
5fb0fae774e010cdd6b63ff487a4528f0397647d
[ "MIT" ]
null
null
null
distill.py
Lukeming-tsinghua/Interpretable-NN-for-IBD-diagnosis
5fb0fae774e010cdd6b63ff487a4528f0397647d
[ "MIT" ]
null
null
null
import os from collections import namedtuple import torch import torch.nn as nn import torch.nn.functional as F from sklearn.metrics import classification_report from torch.optim import Adam from tqdm import tqdm from data import DataIteratorDistill from loss import FocalLoss from model import CNN from torchtext impo...
34.347222
89
0.632835
0
0
0
0
0
0
0
0
93
0.037606
13df4c0e986f7c76ecd11c6a6721e985d305104d
7,597
py
Python
tests/TALTests/HTMLTests/TALAttributesTestCases.py
janbrohl/SimpleTAL
f5a3ddd9a74cf9af7356bb431513e3534717802d
[ "BSD-3-Clause" ]
5
2015-11-20T12:17:04.000Z
2021-03-19T13:49:33.000Z
tests/TALTests/HTMLTests/TALAttributesTestCases.py
mar10/SimpleTAL
f5a3ddd9a74cf9af7356bb431513e3534717802d
[ "BSD-3-Clause" ]
5
2015-09-20T12:55:23.000Z
2018-05-12T10:34:20.000Z
tests/TALTests/HTMLTests/TALAttributesTestCases.py
mar10/SimpleTAL
f5a3ddd9a74cf9af7356bb431513e3534717802d
[ "BSD-3-Clause" ]
1
2022-01-24T13:37:38.000Z
2022-01-24T13:37:38.000Z
#!/usr/bin/python # -*- coding: iso-8859-1 -*- # Copyright (c) 2016, Jan Brohl <[email protected]> # All rights reserved. # See LICENSE.txt # Copyright (c) 2004 Colin Stewart (http://www.owlfish.com/) # All rights reserved. # # Redistribution and use in source and binary forms, with or without # ...
46.042424
162
0.65618
5,475
0.720679
0
0
0
0
0
0
5,111
0.672766
13dfb252487b62555c998999e6abd56dcb22612c
562
py
Python
iseq_prof/fasta.py
EBI-Metagenomics/iseq-prof
ca41a0f3aa1e70e59648bdc08b36da1ec76220ad
[ "MIT" ]
null
null
null
iseq_prof/fasta.py
EBI-Metagenomics/iseq-prof
ca41a0f3aa1e70e59648bdc08b36da1ec76220ad
[ "MIT" ]
null
null
null
iseq_prof/fasta.py
EBI-Metagenomics/iseq-prof
ca41a0f3aa1e70e59648bdc08b36da1ec76220ad
[ "MIT" ]
null
null
null
from pathlib import Path from typing import List from fasta_reader import FASTAItem, FASTAWriter, read_fasta __all__ = ["downsample"] def downsample(infile: Path, outfile: Path, size: int, random): targets: List[FASTAItem] = list(read_fasta(infile)) if size > len(targets): raise ValueError("Size is ...
29.578947
71
0.715302
0
0
0
0
0
0
0
0
57
0.101423
13e04df35258103610f99481901f9649956a3c76
209
py
Python
src/data_settings.py
DhruvSrikanth/TSLA-React
2ce4edb6b21ec1a301047124cfda5bb30deb3a90
[ "MIT" ]
null
null
null
src/data_settings.py
DhruvSrikanth/TSLA-React
2ce4edb6b21ec1a301047124cfda5bb30deb3a90
[ "MIT" ]
null
null
null
src/data_settings.py
DhruvSrikanth/TSLA-React
2ce4edb6b21ec1a301047124cfda5bb30deb3a90
[ "MIT" ]
null
null
null
# API keys # YF_API_KEY = "YRVHVLiFAt3ANYZf00BXr2LHNfZcgKzdWVmsZ9Xi" # yahoo finance api key TICKER = "TSLA" INTERVAL = "1m" PERIOD = "1d" LOOK_BACK = 30 # hard limit to not reach rate limit of 100 per day
20.9
81
0.732057
0
0
0
0
0
0
0
0
156
0.746411
13e067146d5c409e953e8fe9a97ca674f7b0976f
2,217
py
Python
ymir/backend/src/ymir_controller/controller/utils/invoker_mapping.py
phoenix-xhuang/ymir
537d3ac389c4a365ce4daef431c95b42ddcd5b1b
[ "Apache-2.0" ]
64
2021-11-15T03:48:00.000Z
2022-03-25T07:08:46.000Z
ymir/backend/src/ymir_controller/controller/utils/invoker_mapping.py
phoenix-xhuang/ymir
537d3ac389c4a365ce4daef431c95b42ddcd5b1b
[ "Apache-2.0" ]
35
2021-11-23T04:14:35.000Z
2022-03-26T09:03:43.000Z
ymir/backend/src/ymir_controller/controller/utils/invoker_mapping.py
phoenix-xhuang/ymir
537d3ac389c4a365ce4daef431c95b42ddcd5b1b
[ "Apache-2.0" ]
57
2021-11-11T10:15:40.000Z
2022-03-29T07:27:54.000Z
from controller.invoker import ( invoker_cmd_branch_checkout, invoker_cmd_branch_commit, invoker_cmd_branch_create, invoker_cmd_branch_delete, invoker_cmd_branch_list, invoker_cmd_evaluate, invoker_cmd_filter, invoker_cmd_gpu_info, invoker_cmd_inference, invoker_cmd_init, inv...
43.470588
87
0.834461
0
0
0
0
0
0
0
0
0
0
13e0862967d39493794d0afe2c6e9020dad2d87c
777
py
Python
tests/utils/date_utils.py
asuol/worky
362257e77486af05941cc977055c01e49b09a2dd
[ "MIT" ]
null
null
null
tests/utils/date_utils.py
asuol/worky
362257e77486af05941cc977055c01e49b09a2dd
[ "MIT" ]
null
null
null
tests/utils/date_utils.py
asuol/worky
362257e77486af05941cc977055c01e49b09a2dd
[ "MIT" ]
null
null
null
from datetime import datetime, timedelta due_date_format = '%Y-%m-%d' datepicker_date_format = '%m%d%Y' def current_date(): return datetime.utcnow().strftime(due_date_format) def datepicker_current_date(): return datetime.utcnow().strftime(datepicker_date_format) def _date_from_today(days_to_add): r...
25.064516
78
0.776062
0
0
0
0
0
0
0
0
18
0.023166
13e0ca25df4bf90f8ba82de1f47aa08f14078d33
5,304
py
Python
numba/roc/tests/hsapy/test_gufuncbuilding.py
luk-f-a/numba
3a682bd827e416335e3574bc7b10f0ec69adb701
[ "BSD-2-Clause", "BSD-3-Clause" ]
76
2020-07-06T14:44:05.000Z
2022-02-14T15:30:21.000Z
numba/roc/tests/hsapy/test_gufuncbuilding.py
luk-f-a/numba
3a682bd827e416335e3574bc7b10f0ec69adb701
[ "BSD-2-Clause", "BSD-3-Clause" ]
108
2020-08-17T22:38:26.000Z
2021-12-06T09:44:14.000Z
numba/roc/tests/hsapy/test_gufuncbuilding.py
luk-f-a/numba
3a682bd827e416335e3574bc7b10f0ec69adb701
[ "BSD-2-Clause", "BSD-3-Clause" ]
11
2020-07-12T16:18:07.000Z
2022-02-05T16:48:35.000Z
import numpy as np from numba.roc.vectorizers import HsaGUFuncVectorize from numba.roc.dispatch import HSAGenerializedUFunc from numba import guvectorize import unittest def ufunc_add_core(a, b, c): for i in range(c.size): c[i] = a[i] + b[i] class TestGUFuncBuilding(unittest.TestCase): def test_guf...
31.951807
75
0.532805
4,992
0.941176
0
0
237
0.044683
0
0
416
0.078431
13e10f247a53a809b100dc05b97804f51f30b05a
463
py
Python
server/form/mongo.py
SRM-IST-KTR/ossmosis
06e375dfdd67f91286ffbcb13e04b6543585d8ad
[ "MIT" ]
6
2021-07-04T07:59:17.000Z
2021-07-04T14:41:00.000Z
server/form/mongo.py
SRM-IST-KTR/ossmosis
06e375dfdd67f91286ffbcb13e04b6543585d8ad
[ "MIT" ]
null
null
null
server/form/mongo.py
SRM-IST-KTR/ossmosis
06e375dfdd67f91286ffbcb13e04b6543585d8ad
[ "MIT" ]
1
2022-02-15T13:31:46.000Z
2022-02-15T13:31:46.000Z
import os from pymongo import MongoClient from dotenv import load_dotenv def database_entry(data): try: load_dotenv() mongo_string = os.getenv('MONGODB_AUTH_URI') client = MongoClient(mongo_string) database = client[os.getenv('MONGODB_DB')] col = database['users'] c...
21.045455
52
0.637149
0
0
0
0
0
0
0
0
47
0.101512
13e1722808236b6aeebbdaf4b408b6e5d0b9cadb
738
py
Python
control-flow/solution/file_hosts.py
giserh/book-python
ebd4e70cea1dd56986aa8efbae3629ba3f1ba087
[ "MIT" ]
1
2019-01-02T15:04:08.000Z
2019-01-02T15:04:08.000Z
control-flow/solution/file_hosts.py
giserh/book-python
ebd4e70cea1dd56986aa8efbae3629ba3f1ba087
[ "MIT" ]
null
null
null
control-flow/solution/file_hosts.py
giserh/book-python
ebd4e70cea1dd56986aa8efbae3629ba3f1ba087
[ "MIT" ]
null
null
null
FILE = r'../src/etc-hosts.txt' hostnames = [] try: with open(FILE, encoding='utf-8') as file: content = file.readlines() except FileNotFoundError: print('File does not exist') except PermissionError: print('Permission denied') for line in content: if line.startswith('#'): continue ...
19.421053
56
0.550136
0
0
0
0
0
0
0
0
128
0.173442
13e172837fb61cdf3f4fe7914fb4c72959b8c9f8
497
py
Python
zindi/docs/utils/n_subimissions_per_day.py
eaedk/testing-zindi-package
5aef7375a629b328fa8ecf9c4559e2897611a1e9
[ "MIT" ]
6
2020-09-07T17:56:49.000Z
2021-12-09T12:34:01.000Z
zindi/docs/utils/n_subimissions_per_day.py
eaedk/testing-zindi-package
5aef7375a629b328fa8ecf9c4559e2897611a1e9
[ "MIT" ]
2
2021-02-24T11:56:48.000Z
2021-03-30T14:40:45.000Z
zindi/docs/utils/n_subimissions_per_day.py
eaedk/testing-zindi-package
5aef7375a629b328fa8ecf9c4559e2897611a1e9
[ "MIT" ]
4
2020-11-01T00:06:36.000Z
2021-11-19T19:20:52.000Z
def n_subimissions_per_day( url, headers ): """Get the number of submissions we can make per day for the selected challenge. Parameters ---------- url : {'prize', 'points', 'knowledge' , 'all'}, default='all' The reward of the challenges for top challengers. headers : dictionary , T...
35.5
84
0.629779
0
0
0
0
0
0
0
0
449
0.903421
13e274ea10a3039f67d424845564d23d8affb74d
2,875
py
Python
algo/test/test_maximum_cut.py
ssavinash1/Algorithm_stanford
f2588b6bcac2b0858e78b819e6e8402109e80ee2
[ "MIT" ]
24
2016-03-21T07:53:54.000Z
2020-06-29T12:16:36.000Z
algo/test/test_maximum_cut.py
ssavinash1/Algorithm_stanford
f2588b6bcac2b0858e78b819e6e8402109e80ee2
[ "MIT" ]
5
2015-09-29T17:12:36.000Z
2020-03-26T20:51:56.000Z
algo/test/test_maximum_cut.py
ssavinash1/Algorithm_stanford
f2588b6bcac2b0858e78b819e6e8402109e80ee2
[ "MIT" ]
12
2016-05-24T16:48:32.000Z
2020-10-02T12:22:09.000Z
# -*- coding: utf-8 -*- import unittest from src.graph import Graph from src.maximum_cut import maximum_cut, maximum_cut_for_bipartite_graph class MaximumCut(unittest.TestCase): def test_maximum_cut_for_bipartite_graphs(self): """ Given the following bipartite graph. (a)-----(b) ...
33.823529
79
0.420522
2,729
0.949217
0
0
0
0
0
0
1,207
0.419826
13e34fac65209ea50100d76fe6090282f3d8e3b4
5,788
py
Python
gdb/print-avs-rbtree.py
kemonats/avs_commons
ecce4edf5376d132e3686af227c9adf22ce1090e
[ "Apache-2.0" ]
4
2016-11-04T12:55:32.000Z
2019-03-21T15:07:58.000Z
gdb/print-avs-rbtree.py
kemonats/avs_commons
ecce4edf5376d132e3686af227c9adf22ce1090e
[ "Apache-2.0" ]
5
2015-02-11T09:34:36.000Z
2021-04-19T08:51:50.000Z
gdb/print-avs-rbtree.py
kemonats/avs_commons
ecce4edf5376d132e3686af227c9adf22ce1090e
[ "Apache-2.0" ]
17
2015-12-17T10:32:09.000Z
2022-02-14T10:58:39.000Z
# -*- coding: utf-8 -*- # # Copyright 2021 AVSystem <[email protected]> # # 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 requi...
37.102564
146
0.593988
5,015
0.866448
0
0
0
0
0
0
1,481
0.255874
13e3573ef0ab92fc261e9835b12be4ef8345103f
1,372
py
Python
hour17/PythonGroup.py
sampx/mongodb-practice
0698b21b7da57693ba4146384c8ad65530b0066b
[ "MIT" ]
null
null
null
hour17/PythonGroup.py
sampx/mongodb-practice
0698b21b7da57693ba4146384c8ad65530b0066b
[ "MIT" ]
null
null
null
hour17/PythonGroup.py
sampx/mongodb-practice
0698b21b7da57693ba4146384c8ad65530b0066b
[ "MIT" ]
null
null
null
from pymongo import MongoClient def displayGroup(results): for result in results: print (result) def firstIsALastIsVowel(collection): key = {'first' : True, "last" : True} cond = {'first' : 'a', 'last' : {'$in' : ["a","e","i","o","u"]}} initial = {'count' : 0} red...
39.2
69
0.54519
0
0
0
0
0
0
0
0
456
0.332362
13e4eede3d6e6a6be8776d50a9b969b677e1d046
5,115
py
Python
packnet_sfm/models/model_utils.py
pection/packnet-sfm
d5673567b649e6bfda292c894cacdeb06aa80913
[ "MIT" ]
1
2022-02-22T06:19:02.000Z
2022-02-22T06:19:02.000Z
packnet_sfm/models/model_utils.py
pection/packnet-sfm
d5673567b649e6bfda292c894cacdeb06aa80913
[ "MIT" ]
null
null
null
packnet_sfm/models/model_utils.py
pection/packnet-sfm
d5673567b649e6bfda292c894cacdeb06aa80913
[ "MIT" ]
null
null
null
# Copyright 2020 Toyota Research Institute. All rights reserved. from packnet_sfm.utils.image import flip_lr, interpolate_scales from packnet_sfm.utils.misc import filter_dict from packnet_sfm.utils.types import is_tensor, is_list, is_numpy def flip(tensor, flip_fn): """ Flip tensors or list of tensors base...
28.259669
93
0.585728
0
0
0
0
0
0
0
0
2,625
0.513196
13e58721f5e2c382c66ef605548dfd06ad0e1f44
1,363
py
Python
utils/stg/min_jerk_traj.py
dgerod/more-dmps
4dc886a138f289532b2672537f91ff857448ad27
[ "BSD-2-Clause" ]
7
2017-12-23T13:43:33.000Z
2021-08-21T14:50:55.000Z
utils/stg/min_jerk_traj.py
dgerod/more-dmps
4dc886a138f289532b2672537f91ff857448ad27
[ "BSD-2-Clause" ]
1
2016-08-21T05:05:32.000Z
2016-08-21T05:05:32.000Z
utils/stg/min_jerk_traj.py
dgerod/more-dmps
4dc886a138f289532b2672537f91ff857448ad27
[ "BSD-2-Clause" ]
2
2018-02-11T02:01:32.000Z
2019-09-16T01:43:43.000Z
''' Created on 25.07.2012 @author: karl ''' def trajectory(start, goal, duration, delta_t): traj = [] # inital values t, td, tdd = start, 0, 0 for i in range(int(2 * duration / delta_t)): try: t, td, tdd = _min_jerk_step(t, td, tdd, goal, duration - i * delta_t, delta_t) except: break ...
24.781818
96
0.533382
0
0
0
0
0
0
0
0
379
0.278063
13e5f9585262ddf6bd1e3799d8611f18effa881a
40
py
Python
tests/__init__.py
karanrampal/triplet-loss
b62008dedbf8640ccf0dc359b5aadd5e8b0ab134
[ "MIT" ]
null
null
null
tests/__init__.py
karanrampal/triplet-loss
b62008dedbf8640ccf0dc359b5aadd5e8b0ab134
[ "MIT" ]
null
null
null
tests/__init__.py
karanrampal/triplet-loss
b62008dedbf8640ccf0dc359b5aadd5e8b0ab134
[ "MIT" ]
null
null
null
# To make directory as a python package
20
39
0.775
0
0
0
0
0
0
0
0
39
0.975
13e74a7f98e6571f4fc714e2743e38c7eafbf58e
2,607
py
Python
orthoexon/tests/test_util.py
jessicalettes/orthoexon
463ad1908364c602cf75dbddb0b16a42f4100a36
[ "BSD-3-Clause" ]
null
null
null
orthoexon/tests/test_util.py
jessicalettes/orthoexon
463ad1908364c602cf75dbddb0b16a42f4100a36
[ "BSD-3-Clause" ]
null
null
null
orthoexon/tests/test_util.py
jessicalettes/orthoexon
463ad1908364c602cf75dbddb0b16a42f4100a36
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- """ test_orthoexon ---------------------------------- Tests for `orthoexon` module. """ import os import pytest @pytest.fixture def exon_id_with_quotes(): return "'ENSE00001229068.1'" @pytest.fixture def exon_id(): return "ENSE00001229068.1" def test_separate_...
23.917431
86
0.678558
0
0
0
0
570
0.218642
0
0
867
0.332566
13e8cb3c3e9246762451e5cb22ca74f1dccc3db7
2,656
py
Python
predict_recognition.py
yeyupiaoling/Kersa-Speaker-Recognition
7ccf42c006f42ff6074ad3937e44a0dfa68c6d33
[ "Apache-2.0" ]
42
2020-07-12T13:21:13.000Z
2021-07-01T01:06:12.000Z
predict_recognition.py
yeyupiaoling/VoiceprintRecognition-Keras
7ccf42c006f42ff6074ad3937e44a0dfa68c6d33
[ "Apache-2.0" ]
3
2020-08-19T06:16:02.000Z
2020-11-02T02:16:56.000Z
predict_recognition.py
yeyupiaoling/Kersa-Speaker-Recognition
7ccf42c006f42ff6074ad3937e44a0dfa68c6d33
[ "Apache-2.0" ]
12
2020-07-15T14:33:51.000Z
2021-05-24T03:55:04.000Z
import argparse import os import shutil import time import numpy as np from utils import model, utils from utils.record import RecordAudio parser = argparse.ArgumentParser() parser.add_argument('--audio_db', default='audio_db/', type=str, help='音频库的路径') parser.add_argument('--threshold', default=...
28.255319
103
0.628765
0
0
0
0
0
0
0
0
628
0.213315
13e90500b4879323474a6761d01dbd32906a8b6c
6,853
py
Python
cubedash/_product.py
vconrado/datacube-explorer
ccb9a9a42e5dd16e2b0325a1f881b080bb2806e6
[ "Apache-2.0" ]
null
null
null
cubedash/_product.py
vconrado/datacube-explorer
ccb9a9a42e5dd16e2b0325a1f881b080bb2806e6
[ "Apache-2.0" ]
null
null
null
cubedash/_product.py
vconrado/datacube-explorer
ccb9a9a42e5dd16e2b0325a1f881b080bb2806e6
[ "Apache-2.0" ]
null
null
null
import logging from datetime import timedelta from flask import Blueprint, Response, abort, redirect, url_for from cubedash import _model, _utils, _utils as utils _LOG = logging.getLogger(__name__) bp = Blueprint("product", __name__) @bp.route("/about.csv") def legacy_about_csv(): return redirect(".storage_csv...
27.522088
86
0.620604
0
0
0
0
5,642
0.823289
0
0
1,732
0.252736
13e960260e528ba2d92aa2f22ba8b6f12cf5bbfe
1,923
py
Python
litex_boards/platforms/sipeed_tang_nano.py
ozbenh/litex-boards
f18b10d1edb4e162a77972e2e9c5bad54ca00788
[ "BSD-2-Clause" ]
null
null
null
litex_boards/platforms/sipeed_tang_nano.py
ozbenh/litex-boards
f18b10d1edb4e162a77972e2e9c5bad54ca00788
[ "BSD-2-Clause" ]
null
null
null
litex_boards/platforms/sipeed_tang_nano.py
ozbenh/litex-boards
f18b10d1edb4e162a77972e2e9c5bad54ca00788
[ "BSD-2-Clause" ]
null
null
null
# # This file is part of LiteX-Boards. # # Copyright (c) 2021 Florent Kermarrec <[email protected]> # SPDX-License-Identifier: BSD-2-Clause # Board diagram/pinout: # https://user-images.githubusercontent.com/1450143/133655492-532d5e9a-0635-4889-85c9-68683d06cae0.png # http://dl.sipeed.com/TANG/Nano/HDK/Tang-NAN...
32.05
115
0.573583
544
0.282891
0
0
0
0
0
0
917
0.476859
13eaaea3944207924e8d3d8e8f4c1a6a0ee51732
10,525
py
Python
nm_cavia/rl/metalearner.py
anon-6994/nm-metarl
45c8798c2139d8c200cc7a398331c1b98a0dccec
[ "MIT" ]
null
null
null
nm_cavia/rl/metalearner.py
anon-6994/nm-metarl
45c8798c2139d8c200cc7a398331c1b98a0dccec
[ "MIT" ]
null
null
null
nm_cavia/rl/metalearner.py
anon-6994/nm-metarl
45c8798c2139d8c200cc7a398331c1b98a0dccec
[ "MIT" ]
null
null
null
import torch from torch.distributions.kl import kl_divergence from torch.nn.utils.convert_parameters import (vector_to_parameters, parameters_to_vector) from rl_utils.optimization import conjugate_gradient from rl_utils.torch_utils import (weighted_mean, detach_distributi...
40.171756
120
0.624323
10,178
0.967031
0
0
0
0
0
0
2,684
0.255012
13eac7b96baca5f54a52331a42d7e035d905943e
2,321
py
Python
request/management/commands/purgerequests.py
hramezani/django-request
4b9c7b22f26338d2c93110477aa44041b1c5ddb4
[ "BSD-2-Clause" ]
373
2016-04-22T21:18:41.000Z
2022-03-31T23:13:31.000Z
request/management/commands/purgerequests.py
hramezani/django-request
4b9c7b22f26338d2c93110477aa44041b1c5ddb4
[ "BSD-2-Clause" ]
128
2016-04-22T21:30:55.000Z
2022-03-08T20:24:44.000Z
request/management/commands/purgerequests.py
hramezani/django-request
4b9c7b22f26338d2c93110477aa44041b1c5ddb4
[ "BSD-2-Clause" ]
79
2016-04-25T08:44:56.000Z
2022-03-17T01:41:27.000Z
from datetime import timedelta from dateutil.relativedelta import relativedelta from django.core.management.base import BaseCommand, CommandError from django.utils import timezone from ...models import Request DURATION_OPTIONS = { 'hours': lambda amount: timezone.now() - timedelta(hours=amount), 'days': lamb...
30.142857
88
0.623007
1,621
0.698406
0
0
0
0
0
0
632
0.272296
13ebac2480a38d6864e7de863e165c5d96c0e1f7
10,928
py
Python
tests/test_crypto.py
kimtaehong/PythonForWindows
d04eed1754e2e23474213b89580d68e1b73c3fe4
[ "BSD-3-Clause" ]
null
null
null
tests/test_crypto.py
kimtaehong/PythonForWindows
d04eed1754e2e23474213b89580d68e1b73c3fe4
[ "BSD-3-Clause" ]
null
null
null
tests/test_crypto.py
kimtaehong/PythonForWindows
d04eed1754e2e23474213b89580d68e1b73c3fe4
[ "BSD-3-Clause" ]
null
null
null
import pytest import windows.crypto import windows.generated_def as gdef import windows.crypto.generation from .pfwtest import * pytestmark = pytest.mark.usefixtures('check_for_gc_garbage') TEST_CERT = b""" MIIBwTCCASqgAwIBAgIQG46Uyws+67ZBOfPJCbFrRjANBgkqhkiG9w0BAQsFADAfMR0wGwYDVQQD ExRQeXRob25Gb3JXaW5kb3dzVGVzdDAe...
45.344398
132
0.811585
0
0
2,259
0.206717
2,403
0.219894
0
0
5,327
0.487463
13ec7c22478f599c0c77b64f3478dbd3b142fa61
8,135
py
Python
cdci_data_analysis/analysis/plot_tools.py
andreatramacere/cdci_data_analysis
8ae34a7252d6baf011a3b99fbe4f6e624b63d7df
[ "MIT" ]
null
null
null
cdci_data_analysis/analysis/plot_tools.py
andreatramacere/cdci_data_analysis
8ae34a7252d6baf011a3b99fbe4f6e624b63d7df
[ "MIT" ]
null
null
null
cdci_data_analysis/analysis/plot_tools.py
andreatramacere/cdci_data_analysis
8ae34a7252d6baf011a3b99fbe4f6e624b63d7df
[ "MIT" ]
null
null
null
from __future__ import absolute_import, division, print_function from builtins import (bytes, str, open, super, range, zip, round, input, int, pow, object, map, zip) __author__ = "Andrea Tramacere" import numpy as np from astropy import wcs from bokeh.layouts import row, widgetbox,gridplot ...
31.288462
132
0.547019
7,593
0.933374
0
0
0
0
0
0
1,901
0.233682
13edd551b75e71fd96ef5d443c0c54bbec028a56
844
py
Python
test/unit/test_testaid_unit_pathlist.py
RebelCodeBase/testaid
998c827b826fe4374ecf0a234fef61a975e2fcd7
[ "Apache-2.0" ]
17
2019-08-04T09:29:19.000Z
2020-05-16T02:25:20.000Z
test/unit/test_testaid_unit_pathlist.py
RebelCodeBase/testaid
998c827b826fe4374ecf0a234fef61a975e2fcd7
[ "Apache-2.0" ]
12
2019-07-19T22:20:42.000Z
2020-01-20T06:45:38.000Z
test/unit/test_testaid_unit_pathlist.py
RebelCodeBase/testaid
998c827b826fe4374ecf0a234fef61a975e2fcd7
[ "Apache-2.0" ]
3
2019-08-08T18:18:13.000Z
2019-10-07T13:46:03.000Z
from pathlib import Path from testaid.pathlist import PathList def test_testaid_unit_pathlist_roles_blacklist(testvars_roles_blacklist): assert testvars_roles_blacklist is not None def test_testaid_unit_pathlist_roles_whitelist(testvars_roles_whitelist): assert testvars_roles_whitelist is not None def tes...
29.103448
73
0.726303
0
0
0
0
0
0
0
0
98
0.116114
13ee6c7b533dc2afb81ce7087fea00c547679671
22,147
py
Python
tests/unit/zhmcclient/test_hba.py
vkpro-forks/python-zhmcclient
eab2dca37cb417d03411450dabf72805214b5ca0
[ "Apache-2.0" ]
null
null
null
tests/unit/zhmcclient/test_hba.py
vkpro-forks/python-zhmcclient
eab2dca37cb417d03411450dabf72805214b5ca0
[ "Apache-2.0" ]
null
null
null
tests/unit/zhmcclient/test_hba.py
vkpro-forks/python-zhmcclient
eab2dca37cb417d03411450dabf72805214b5ca0
[ "Apache-2.0" ]
null
null
null
# Copyright 2016-2017 IBM Corp. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or...
34.658842
77
0.557457
20,939
0.945455
0
0
13,186
0.595385
0
0
7,682
0.346864
13ef6d428251649b315fbe8757c2d7336d7471a8
367
py
Python
compiler-rt/test/asan/TestCases/Windows/lit.local.cfg.py
medismailben/llvm-project
e334a839032fe500c3bba22bf976ab7af13ce1c1
[ "Apache-2.0" ]
2,338
2018-06-19T17:34:51.000Z
2022-03-31T11:00:37.000Z
compiler-rt/test/asan/TestCases/Windows/lit.local.cfg.py
medismailben/llvm-project
e334a839032fe500c3bba22bf976ab7af13ce1c1
[ "Apache-2.0" ]
3,740
2019-01-23T15:36:48.000Z
2022-03-31T22:01:13.000Z
compiler-rt/test/asan/TestCases/Windows/lit.local.cfg.py
medismailben/llvm-project
e334a839032fe500c3bba22bf976ab7af13ce1c1
[ "Apache-2.0" ]
500
2019-01-23T07:49:22.000Z
2022-03-30T02:59:37.000Z
def getRoot(config): if not config.parent: return config return getRoot(config.parent) root = getRoot(config) # We only run a small set of tests on Windows for now. # Override the parent directory's "unsupported" decision until we can handle # all of its tests. if root.host_os in ['Windows']: config.unsuppo...
24.466667
76
0.73842
0
0
0
0
0
0
0
0
158
0.430518
13efdb45818b7da3afae845201256a86d37c940d
4,302
py
Python
Lib/test/libregrtest/utils.py
oskomorokhov/cpython
c0e11a3ceb9427e09db4224f394c7789bf6deec5
[ "0BSD" ]
5
2017-08-25T04:31:30.000Z
2022-03-22T15:01:56.000Z
Lib/test/libregrtest/utils.py
oskomorokhov/cpython
c0e11a3ceb9427e09db4224f394c7789bf6deec5
[ "0BSD" ]
20
2021-03-25T12:52:42.000Z
2022-03-01T02:02:03.000Z
Lib/test/libregrtest/utils.py
oskomorokhov/cpython
c0e11a3ceb9427e09db4224f394c7789bf6deec5
[ "0BSD" ]
3
2020-04-13T14:41:31.000Z
2022-03-02T18:56:32.000Z
import math import os.path import sys import textwrap from test import support def format_duration(seconds): ms = math.ceil(seconds * 1e3) seconds, ms = divmod(ms, 1000) minutes, seconds = divmod(seconds, 60) hours, minutes = divmod(minutes, 60) parts = [] if hours: parts.append('%s h...
22.761905
75
0.600418
0
0
0
0
0
0
0
0
812
0.188749
13f22ca29da54a0f4486e1f8539ee236d259fc1e
5,960
py
Python
efetch_server/plugins/fa_sqlite/fa_sqlite_ajax.py
Syrkadian/efetch
120ac963507d54998beecfd8b8cd85ad123e6e54
[ "Apache-2.0" ]
38
2015-08-18T00:29:16.000Z
2021-12-06T15:53:47.000Z
efetch_server/plugins/fa_sqlite/fa_sqlite_ajax.py
Syrkadian/efetch
120ac963507d54998beecfd8b8cd85ad123e6e54
[ "Apache-2.0" ]
20
2016-03-18T02:20:27.000Z
2020-04-09T22:16:42.000Z
efetch_server/plugins/fa_sqlite/fa_sqlite_ajax.py
Syrkadian/efetch
120ac963507d54998beecfd8b8cd85ad123e6e54
[ "Apache-2.0" ]
8
2016-08-23T14:59:15.000Z
2020-04-09T21:43:25.000Z
""" AJAX for SQLite Viewer plugin """ from yapsy.IPlugin import IPlugin from flask import Response, jsonify import json import logging import sqlite3 class FaSqliteAjax(IPlugin): def __init__(self): self.display_name = 'SQLite Ajax' self.popularity = 0 self.cache = True self.fast ...
35.266272
133
0.51896
5,807
0.974329
0
0
0
0
0
0
1,568
0.263087
13f2af320410f86bedc3a6ddc8c44eb547f14053
252
py
Python
raspagem/random/lista_cidades.py
sslppractice/propython
fa470c3bf0dcfbb26037146d77c7491596cabb26
[ "MIT" ]
null
null
null
raspagem/random/lista_cidades.py
sslppractice/propython
fa470c3bf0dcfbb26037146d77c7491596cabb26
[ "MIT" ]
null
null
null
raspagem/random/lista_cidades.py
sslppractice/propython
fa470c3bf0dcfbb26037146d77c7491596cabb26
[ "MIT" ]
null
null
null
import requests, json url = 'http://educacao.dadosabertosbr.com/api/cidades/ce' cidades = requests.get(url).content cidades = cidades.decode('utf-8') cidades = json.loads(cidades) for cidade in cidades: codigo, nome = cidade.split(':') print(nome)
22.909091
57
0.734127
0
0
0
0
0
0
0
0
61
0.242063
13f387c5b382d039623c959bbf8db86a94b8f10b
29
py
Python
mezzanine/__init__.py
startupgrind/mezzanine
23d24a07c69bf8f02d60148b0b8da6c76bc5061e
[ "BSD-2-Clause" ]
null
null
null
mezzanine/__init__.py
startupgrind/mezzanine
23d24a07c69bf8f02d60148b0b8da6c76bc5061e
[ "BSD-2-Clause" ]
3
2019-02-18T07:52:41.000Z
2021-03-31T03:51:11.000Z
mezzanine/__init__.py
startupgrind/mezzanine
23d24a07c69bf8f02d60148b0b8da6c76bc5061e
[ "BSD-2-Clause" ]
null
null
null
__version__ = "4.3.1.post1"
9.666667
27
0.655172
0
0
0
0
0
0
0
0
13
0.448276