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
2ddb711319d2de41b35803baad0302688374879f
1,600
py
Python
plots/plottingcompare.py
HPQC-LABS/Quantum-Graph-Spectra
b897d94dd03c48ffec5735b3dc5b86f8c3ab5a8f
[ "MIT" ]
1
2020-07-29T06:42:32.000Z
2020-07-29T06:42:32.000Z
plots/plottingcompare.py
HPQC-LABS/Quantum-Graph-Spectra
b897d94dd03c48ffec5735b3dc5b86f8c3ab5a8f
[ "MIT" ]
null
null
null
plots/plottingcompare.py
HPQC-LABS/Quantum-Graph-Spectra
b897d94dd03c48ffec5735b3dc5b86f8c3ab5a8f
[ "MIT" ]
2
2021-03-29T13:40:47.000Z
2021-03-29T13:41:00.000Z
''' @author: Josh Payne Description: For creating multiple overlaid charts ''' from mpl_toolkits.axes_grid1 import host_subplot import mpl_toolkits.axisartist as AA import matplotlib.pyplot as plt import numpy as np ### Get values from performance.py, input here ### x = [4, 5, 8, 9, 16, 32, 64] lst = [(2.585895228...
30.769231
302
0.71
0
0
0
0
0
0
0
0
400
0.25
2ddc43ce9995edf0340e08d59a52ccaf4be2ad42
804
py
Python
pulse2percept/datasets/__init__.py
pulse2percept/pulse2percept
67e0f2354db5ebe306b617f7f78a9ea8c02327ac
[ "BSD-3-Clause" ]
40
2019-11-01T14:09:34.000Z
2022-02-28T19:08:01.000Z
pulse2percept/datasets/__init__.py
jgranley/pulse2percept
65c11393a33d1531cd02a3e38243414bf8172e9a
[ "BSD-3-Clause" ]
277
2019-11-22T03:30:31.000Z
2022-03-28T00:11:03.000Z
pulse2percept/datasets/__init__.py
jgranley/pulse2percept
65c11393a33d1531cd02a3e38243414bf8172e9a
[ "BSD-3-Clause" ]
31
2020-01-22T06:36:36.000Z
2022-01-20T09:54:25.000Z
"""Utilities to download and import datasets. * **Dataset loaders** can be used to load small datasets that come pre-packaged with the pulse2percept software. * **Dataset fetchers** can be used to download larger datasets from a given URL and directly import them into pulse2percept. .. autosummary:: :toct...
22.333333
76
0.726368
0
0
0
0
0
0
0
0
563
0.700249
2ddca5cc12de3a408cda0ff45249cbd6d8e54333
7,452
py
Python
pysnmp-with-texts/TIMETRA-SAS-IEEE8021-PAE-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
8
2019-05-09T17:04:00.000Z
2021-06-09T06:50:51.000Z
pysnmp-with-texts/TIMETRA-SAS-IEEE8021-PAE-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
4
2019-05-31T16:42:59.000Z
2020-01-31T21:57:17.000Z
pysnmp-with-texts/TIMETRA-SAS-IEEE8021-PAE-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
10
2019-04-30T05:51:36.000Z
2022-02-16T03:33:41.000Z
# # PySNMP MIB module TIMETRA-SAS-IEEE8021-PAE-MIB (http://snmplabs.com/pysmi) # ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/TIMETRA-SAS-IEEE8021-PAE-MIB # Produced by pysmi-0.3.4 at Wed May 1 15:21:45 2019 # On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4 # Using Python vers...
143.307692
1,076
0.800322
0
0
0
0
0
0
0
0
3,463
0.464707
2ddf7737c3560fadbc544f9a488716622f8551b0
7,093
py
Python
pipeline/mk_all_level1_fsf_bbr.py
lbconner/openfMRI
265d8ef013dad14fd1741d5817d00f9411d85103
[ "BSD-2-Clause" ]
33
2015-02-17T17:21:43.000Z
2021-08-23T08:27:10.000Z
pipeline/mk_all_level1_fsf_bbr.py
lbconner/openfMRI
265d8ef013dad14fd1741d5817d00f9411d85103
[ "BSD-2-Clause" ]
13
2015-01-14T15:17:09.000Z
2017-07-10T02:17:06.000Z
pipeline/mk_all_level1_fsf_bbr.py
lbconner/openfMRI
265d8ef013dad14fd1741d5817d00f9411d85103
[ "BSD-2-Clause" ]
24
2015-01-27T10:02:47.000Z
2021-03-19T20:05:35.000Z
#!/usr/bin/env python """ mk_all_level1_fsf.py - make fsf files for all subjects USAGE: python mk_all_level1_fsf_bbr.py <name of dataset> <modelnum> <basedir - default is staged> <nonlinear - default=1> <smoothing - default=0> <tasknum - default to all> """ ## Copyright 2011, Russell Poldrack. All rights reserved. ...
41.238372
172
0.661638
0
0
0
0
0
0
0
0
3,597
0.50712
2de03c9b6f61130c7a0de0bbdb46eed6409dcbac
2,492
py
Python
gettweets.py
ketankokane94/twitter-analysis
7820fe7d3350af5066799c7540352993b1ecc36c
[ "MIT" ]
null
null
null
gettweets.py
ketankokane94/twitter-analysis
7820fe7d3350af5066799c7540352993b1ecc36c
[ "MIT" ]
null
null
null
gettweets.py
ketankokane94/twitter-analysis
7820fe7d3350af5066799c7540352993b1ecc36c
[ "MIT" ]
null
null
null
import tweepy import csv class dealWithTwitter: def __init__(self): self.access_token = "" self.access_token_secret = "" self.consumer_key = "" self.consumer_secret = "" self.api = "" def loadTokens(self): tokens = [] with open('pwd.txt') as pwd_file: ...
38.338462
105
0.611156
2,323
0.932183
0
0
0
0
0
0
674
0.270465
2de11305e60f62768eeb9919ec2876747df54327
22,175
py
Python
main.py
Swaraj-Deep/UAV-GRN-DRN
f18fe05751794bc7530b58312f6fadacb1e4a500
[ "MIT" ]
1
2020-06-16T11:27:30.000Z
2020-06-16T11:27:30.000Z
main.py
Swaraj-Deep/UAV-GRN-DRN
f18fe05751794bc7530b58312f6fadacb1e4a500
[ "MIT" ]
null
null
null
main.py
Swaraj-Deep/UAV-GRN-DRN
f18fe05751794bc7530b58312f6fadacb1e4a500
[ "MIT" ]
null
null
null
import json import random import numpy as np import os import time import os.path import networkx as nx import users_endpoint.users import grn_endpoint.grn_info import move_endpoint.movement import reward_endpoint.rewards import matplotlib.pyplot as plt from matplotlib.backends.backend_pdf import PdfPages # Global var...
35.48
309
0.659436
0
0
0
0
0
0
0
0
5,465
0.246449
2de4906cd9dd45c4ba1ae99f800a8a5ed211db6d
2,384
py
Python
tests/work_with_gdscript/test_native_call.py
curradium/godot-python
11355dfd03a3dad80253b49c532fbb61a8b26d98
[ "CC-BY-3.0" ]
null
null
null
tests/work_with_gdscript/test_native_call.py
curradium/godot-python
11355dfd03a3dad80253b49c532fbb61a8b26d98
[ "CC-BY-3.0" ]
null
null
null
tests/work_with_gdscript/test_native_call.py
curradium/godot-python
11355dfd03a3dad80253b49c532fbb61a8b26d98
[ "CC-BY-3.0" ]
null
null
null
# TODO: # - allow inheritance from GDScript class # - overload native method ? import pytest from godot.bindings import ResourceLoader, GDScript, PluginScript def test_native_method(node): original_name = node.get_name() try: node.set_name("foo") name = node.get_name() ass...
23.145631
72
0.693372
0
0
0
0
909
0.381292
0
0
415
0.174077
2de4ee5bc7351ca57d213412fccfba40eb972d36
1,880
py
Python
tests/python/unittest/test_arith_stmt_simplify.py
ndl/tvm
6e4c6d7a3a840ae1f7f996c856357068ba7c68ee
[ "Apache-2.0" ]
15
2019-05-02T00:06:28.000Z
2022-03-25T03:11:14.000Z
tests/python/unittest/test_arith_stmt_simplify.py
ndl/tvm
6e4c6d7a3a840ae1f7f996c856357068ba7c68ee
[ "Apache-2.0" ]
5
2019-05-13T20:44:51.000Z
2019-09-25T19:56:29.000Z
tests/python/unittest/test_arith_stmt_simplify.py
ndl/tvm
6e4c6d7a3a840ae1f7f996c856357068ba7c68ee
[ "Apache-2.0" ]
5
2019-03-06T19:54:18.000Z
2022-02-01T14:27:58.000Z
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
35.471698
62
0.685106
0
0
0
0
0
0
0
0
907
0.482447
2de6561887dd2c5980bf1f012aa5a1b51a0aef2b
3,350
py
Python
worker/worker.py
cshenton/neuroevolution
12f0d52513b2d9a91c96f9a4d9b4aafab1d95fe8
[ "MIT" ]
45
2018-04-18T21:37:12.000Z
2020-09-28T22:35:08.000Z
worker/worker.py
cshenton/neuroevolution
12f0d52513b2d9a91c96f9a4d9b4aafab1d95fe8
[ "MIT" ]
null
null
null
worker/worker.py
cshenton/neuroevolution
12f0d52513b2d9a91c96f9a4d9b4aafab1d95fe8
[ "MIT" ]
10
2018-04-19T10:13:03.000Z
2022-02-02T14:06:59.000Z
"""The Worker class, which manages running policy evaluations.""" import datetime import grpc import gym import os from google.protobuf import empty_pb2 from proto.neuroevolution_pb2 import Evaluation, Individual from proto.neuroevolution_pb2_grpc import NeuroStub from worker.policy import Policy ENVIRONMENT = os.ge...
32.211538
84
0.584478
2,841
0.84806
0
0
0
0
0
0
1,389
0.414627
2de6c51e3b98221f5e9ca7c29a7762f77132e57d
836
py
Python
CAP4-Case study_interface design/docstring.py
falble/mythinkpython2
25de15c8657f32a8f85189d9cb0588c816e9e7d3
[ "Apache-2.0" ]
1
2020-11-20T16:28:32.000Z
2020-11-20T16:28:32.000Z
CAP4-Case study_interface design/docstring.py
falble/mythinkpython2
25de15c8657f32a8f85189d9cb0588c816e9e7d3
[ "Apache-2.0" ]
null
null
null
CAP4-Case study_interface design/docstring.py
falble/mythinkpython2
25de15c8657f32a8f85189d9cb0588c816e9e7d3
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Sat Feb 16 17:05:36 2019 @author: Utente """ #Chapter 4 #docstring import turtle import math bob = turtle.Turtle() print(bob) def polyline(t, n, lenght, angle): #documentation string---> """Draws n line segments with the given lenght and angle...
25.333333
102
0.62201
0
0
0
0
0
0
0
0
549
0.656699
2de89c57ba2b6a38a0def3e77a44733886f67fe3
378
py
Python
Day02/part2.py
JavierRizzoA/AoC2021
948177b135f2570090cd3a13aafaa0199566248a
[ "Beerware" ]
null
null
null
Day02/part2.py
JavierRizzoA/AoC2021
948177b135f2570090cd3a13aafaa0199566248a
[ "Beerware" ]
null
null
null
Day02/part2.py
JavierRizzoA/AoC2021
948177b135f2570090cd3a13aafaa0199566248a
[ "Beerware" ]
null
null
null
x = 0 y = 0 aim = 0 with open('input') as f: for line in f: direction = line.split()[0] magnitude = int(line.split()[1]) if direction == 'forward': x += magnitude y += aim * magnitude elif direction == 'down': aim += magnitude elif directio...
23.625
40
0.481481
0
0
0
0
0
0
0
0
26
0.068783
2de8dc7fc9d8a2753db8ec50c0b95c8f4645d196
2,329
py
Python
ddd_domain_driven_design/application/dto/generalisation/dtometa.py
pidevops/py-domain-driven-design
86f5743e5a37628a2146e62bebd4489a93ad8f16
[ "MIT" ]
2
2019-11-14T15:10:00.000Z
2020-05-12T07:33:37.000Z
ddd_domain_driven_design/application/dto/generalisation/dtometa.py
pidevops/py-domain-driven-design
86f5743e5a37628a2146e62bebd4489a93ad8f16
[ "MIT" ]
null
null
null
ddd_domain_driven_design/application/dto/generalisation/dtometa.py
pidevops/py-domain-driven-design
86f5743e5a37628a2146e62bebd4489a93ad8f16
[ "MIT" ]
null
null
null
from . import type_checker from .dtodescriptor import DTODescriptor class DTOMeta(type): def __init__(cls, name, bases, namespace, partial: bool = False): super().__init__(name, bases, namespace) def __new__(cls, name, bases, class_dict, partial: bool = False): descriptors = {k: v for k, v i...
43.943396
119
0.522542
2,259
0.969944
0
0
0
0
0
0
147
0.063117
2de971a92eef57fed46cbae27fb964015248a42c
10,158
py
Python
model.py
r-or/cnn-eyetrack
93a09f209aa8d34defc82c8734d35d5ce56b9060
[ "MIT" ]
null
null
null
model.py
r-or/cnn-eyetrack
93a09f209aa8d34defc82c8734d35d5ce56b9060
[ "MIT" ]
null
null
null
model.py
r-or/cnn-eyetrack
93a09f209aa8d34defc82c8734d35d5ce56b9060
[ "MIT" ]
null
null
null
#!/usr/bin/python3 import json import pprint import sys import os import numpy as np import traceback import random import argparse import json import tensorflow import keras from keras import optimizers from keras.models import Sequential from keras.models import load_model from keras.layers import Conv2D, MaxPooling...
35.767606
137
0.641366
1,316
0.129553
0
0
0
0
0
0
1,947
0.191672
2dea338f874c3ce26ae59e17c28ac999a26659a9
43,498
py
Python
ec2driver.py
venumurthy/ec2-driver
65b0482af3af80e34c00c327f54487d492933b25
[ "Apache-2.0" ]
null
null
null
ec2driver.py
venumurthy/ec2-driver
65b0482af3af80e34c00c327f54487d492933b25
[ "Apache-2.0" ]
null
null
null
ec2driver.py
venumurthy/ec2-driver
65b0482af3af80e34c00c327f54487d492933b25
[ "Apache-2.0" ]
null
null
null
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # Copyright (c) 2014 Thoughtworks. # # 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 # #...
43.324701
161
0.635271
39,482
0.907674
0
0
198
0.004552
0
0
13,851
0.318428
2dec3a7fdb0143127ec3b1adee9a1d3e5ba90910
1,239
py
Python
output/models/ms_data/additional/isdefault072_xsd/isdefault072.py
tefra/xsdata-w3c-tests
b6b6a4ac4e0ab610e4b50d868510a8b7105b1a5f
[ "MIT" ]
1
2021-08-14T17:59:21.000Z
2021-08-14T17:59:21.000Z
output/models/ms_data/additional/isdefault072_xsd/isdefault072.py
tefra/xsdata-w3c-tests
b6b6a4ac4e0ab610e4b50d868510a8b7105b1a5f
[ "MIT" ]
4
2020-02-12T21:30:44.000Z
2020-04-15T20:06:46.000Z
output/models/ms_data/additional/isdefault072_xsd/isdefault072.py
tefra/xsdata-w3c-tests
b6b6a4ac4e0ab610e4b50d868510a8b7105b1a5f
[ "MIT" ]
null
null
null
from dataclasses import dataclass, field from typing import List from xml.etree.ElementTree import QName __NAMESPACE__ = "http://schemas.microsoft.com/2003/10/Serialization/" @dataclass class Array: class Meta: namespace = "http://schemas.microsoft.com/2003/10/Serialization/" item: List[object] = fi...
24.78
79
0.514124
1,049
0.846651
0
0
1,060
0.855529
0
0
383
0.30912
2deca87ea9f9f2cd6faccaa2e1e2be6b9753edc0
54,161
py
Python
pysnmp/PRIVATE-SW0657840-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
11
2021-02-02T16:27:16.000Z
2021-08-31T06:22:49.000Z
pysnmp/PRIVATE-SW0657840-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
75
2021-02-24T17:30:31.000Z
2021-12-08T00:01:18.000Z
pysnmp/PRIVATE-SW0657840-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
10
2019-04-30T05:51:36.000Z
2022-02-16T03:33:41.000Z
# # PySNMP MIB module PRIVATE-SW0657840-MIB (http://snmplabs.com/pysmi) # ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/PRIVATE-SW0657840-MIB # Produced by pysmi-0.3.4 at Mon Apr 29 20:33:18 2019 # On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4 # Using Python version 3.7.3 (def...
129.882494
10,027
0.773342
0
0
0
0
0
0
0
0
5,080
0.093794
2dedbb9bc8cf45b074be9e76b40b810632cf828b
14,005
py
Python
simpleference/inference/util.py
neptunes5thmoon/simpleference
96c74187bd3d83f6f1e910e72e56f45d6cc8d5d9
[ "MIT" ]
null
null
null
simpleference/inference/util.py
neptunes5thmoon/simpleference
96c74187bd3d83f6f1e910e72e56f45d6cc8d5d9
[ "MIT" ]
null
null
null
simpleference/inference/util.py
neptunes5thmoon/simpleference
96c74187bd3d83f6f1e910e72e56f45d6cc8d5d9
[ "MIT" ]
null
null
null
from __future__ import print_function try: import h5py WITH_H5PY = True except ImportError: WITH_H5PY = False try: import zarr WITH_ZARR = True from .io import IoZarr except ImportError: WITH_ZARR = False try: import z5py WITH_Z5PY = True from .io import IoN5 except ImportError: ...
37.95393
124
0.57865
0
0
0
0
315
0.022492
0
0
1,538
0.109818
2def07ac71914db60c5520bf17ab094d2838a077
481
py
Python
python/ds/MinDiffList.py
unhingedporter/DataStructureMustKnow
3c5b3225afa2775d37a2ff90121f73208717640a
[ "MIT" ]
3
2019-11-23T08:43:58.000Z
2019-11-23T08:52:53.000Z
python/ds/MinDiffList.py
unhingedpotter/DSMustKnow
64958cbbbb3f4cdb1104c2255e555233554503f9
[ "MIT" ]
null
null
null
python/ds/MinDiffList.py
unhingedpotter/DSMustKnow
64958cbbbb3f4cdb1104c2255e555233554503f9
[ "MIT" ]
null
null
null
class MinDiffList: # def __init__(self): # self.diff = sys.maxint def findMinDiff(self, arr): arr.sort() self.diff = arr[len(arr) - 1] for iter in range(len(arr)): adjacentDiff = abs(arr[iter + 1]) - abs(arr[iter]) if adjacentDiff < self.diff: ...
24.05
68
0.555094
384
0.798337
0
0
0
0
0
0
49
0.101871
2defa74f0ad5c7fdce73289dd8fcc91dc1f25cf7
2,075
py
Python
ncbi/patric_add_taxonomy.py
johned0/EdwardsLab
ae0d8b51a579cd009b414d11224b4110ba13af66
[ "MIT" ]
null
null
null
ncbi/patric_add_taxonomy.py
johned0/EdwardsLab
ae0d8b51a579cd009b414d11224b4110ba13af66
[ "MIT" ]
null
null
null
ncbi/patric_add_taxonomy.py
johned0/EdwardsLab
ae0d8b51a579cd009b414d11224b4110ba13af66
[ "MIT" ]
null
null
null
""" Add the taxonomy to the patric metadata file """ import os import sys import argparse from taxon import get_taxonomy_db, get_taxonomy c = get_taxonomy_db() if __name__ == '__main__': parser = argparse.ArgumentParser(description="Append taxonomy to the patric metadata file. This adds it at column 67") par...
33.467742
122
0.517108
0
0
0
0
0
0
0
0
498
0.24
2df494efc476f1235a7fd4bca3824c402be41058
11,450
py
Python
project/save_FlowFile_BPFormat.py
wesleybowman/karsten
ef4b2d6debae605902d76cd0484e71c0ba74fdd1
[ "MIT" ]
1
2015-05-04T17:48:56.000Z
2015-05-04T17:48:56.000Z
project/save_FlowFile_BPFormat.py
wesleybowman/karsten
ef4b2d6debae605902d76cd0484e71c0ba74fdd1
[ "MIT" ]
null
null
null
project/save_FlowFile_BPFormat.py
wesleybowman/karsten
ef4b2d6debae605902d76cd0484e71c0ba74fdd1
[ "MIT" ]
1
2021-11-15T17:53:19.000Z
2021-11-15T17:53:19.000Z
from __future__ import division import numpy as np from rawADCPclass import rawADCP from datetime import datetime from datetime import timedelta import scipy.io as sio import scipy.interpolate as sip import matplotlib.pyplot as plt import seaborn def date2py(matlab_datenum): python_datetime = datetime.fromordinal(...
32.902299
94
0.599301
86
0.007511
0
0
0
0
0
0
4,081
0.356419
2df53d0c6968d61a6511d518ea06ce30084abc51
1,923
py
Python
Module1/Day06/module1_day06_lists.py
datsaloglou/100DaysPython
b6a90bfa5260fb2cb66da9eceaafda9a53c76c0f
[ "MIT" ]
1
2019-06-02T12:16:52.000Z
2019-06-02T12:16:52.000Z
Module1/Day06/module1_day06_lists.py
datsaloglou/100DaysPython
b6a90bfa5260fb2cb66da9eceaafda9a53c76c0f
[ "MIT" ]
null
null
null
Module1/Day06/module1_day06_lists.py
datsaloglou/100DaysPython
b6a90bfa5260fb2cb66da9eceaafda9a53c76c0f
[ "MIT" ]
null
null
null
""" Author: CaptCorpMURICA Project: 100DaysPython File: module1_day06_lists.py Creation Date: 6/2/2019, 8:55 AM Description: Learn the basic of lists in python. """ list_1 = [] list_2 = list() print("List 1 Type: {}\nList 2 Type: {}".format(type(list_1), type(list_2))) ...
27.084507
76
0.667707
0
0
0
0
0
0
0
0
637
0.331253
2df53ea42aed1c3338e8b5cf86c170ffdfe06678
131
py
Python
magicdice/__init__.py
emre/magicdice
326512696b766248cfb8998aec5b0bd8bff393ba
[ "MIT" ]
5
2019-02-26T21:59:21.000Z
2019-05-28T06:32:06.000Z
magicdice/__init__.py
emre/magicdice
326512696b766248cfb8998aec5b0bd8bff393ba
[ "MIT" ]
null
null
null
magicdice/__init__.py
emre/magicdice
326512696b766248cfb8998aec5b0bd8bff393ba
[ "MIT" ]
null
null
null
class MagicDice: def __init__(self, account, active_key): self.account = account self.active_key = active_key
21.833333
44
0.671756
130
0.992366
0
0
0
0
0
0
0
0
2df5a62d162481addcad6f25157f37024121dd7c
708
py
Python
Interview Preparation Kit/01 - Warm-up Challenges/04 - Repeated String.py
srgeyK87/Hacker-Rank-30-days-challlenge
4a929935148db493057dd3a5a88e77efcc0fd086
[ "MIT" ]
275
2020-04-10T18:01:13.000Z
2022-03-23T15:03:41.000Z
Interview Preparation Kit/01 - Warm-up Challenges/04 - Repeated String.py
rakshit6432/HackerRank-Solutions
9fd5b295f03cc80b77e80810bb6b7b6acd160e79
[ "MIT" ]
2
2020-12-20T10:55:40.000Z
2021-05-20T12:52:53.000Z
Interview Preparation Kit/01 - Warm-up Challenges/04 - Repeated String.py
rakshit6432/HackerRank-Solutions
9fd5b295f03cc80b77e80810bb6b7b6acd160e79
[ "MIT" ]
196
2020-09-26T16:24:43.000Z
2022-03-28T10:40:05.000Z
# ======================== # Information # ======================== # Direct Link: https://www.hackerrank.com/challenges/repeated-string/problem # Difficulty: Easy # Max Score: 20 # Language: Python # ======================== # Solution # ======================== import os # Complete the repeatedStrin...
22.83871
76
0.542373
0
0
0
0
0
0
0
0
349
0.492938
2df6288c891a7e36cd3f5221f22fe8e36ca68a70
6,056
py
Python
regress/PORT_ME_TESTS/tests-glen.py
fp7-ofelia/VeRTIGO
11f39f819196c8352611852435dea17bc6a2292f
[ "BSD-3-Clause" ]
2
2016-10-12T08:20:00.000Z
2017-05-09T13:13:18.000Z
regress/PORT_ME_TESTS/tests-glen.py
fp7-ofelia/VeRTIGO
11f39f819196c8352611852435dea17bc6a2292f
[ "BSD-3-Clause" ]
null
null
null
regress/PORT_ME_TESTS/tests-glen.py
fp7-ofelia/VeRTIGO
11f39f819196c8352611852435dea17bc6a2292f
[ "BSD-3-Clause" ]
1
2020-10-01T07:57:34.000Z
2020-10-01T07:57:34.000Z
#!/usr/bin/python from fvregress import * import string # really? you have to do this? if len(sys.argv) > 1 : wantPause = True timeout=9999999 valgrindArgs= [] else: wantPause = False timeout=5 valgrindArgs= None # start up a flowvisor with 1 switch (default) and two guests #h= HyperTest(guests=[('localhost'...
67.288889
192
0.803831
0
0
0
0
0
0
0
0
3,984
0.65786
2df6451745f6199069fa0651e5f50fd52805e8f8
1,325
py
Python
pseudo/__init__.py
pniedzwiedzinski/pseudo
b27570bd8400b6a51a2958454b31f1ce2e25c4f9
[ "MIT" ]
5
2019-04-02T07:01:34.000Z
2019-11-24T02:08:03.000Z
pseudo/__init__.py
pniedzwiedzinski/pseudo
b27570bd8400b6a51a2958454b31f1ce2e25c4f9
[ "MIT" ]
11
2019-03-20T08:29:30.000Z
2019-05-21T11:57:03.000Z
pseudo/__init__.py
pniedzwiedzinski/pseudo
b27570bd8400b6a51a2958454b31f1ce2e25c4f9
[ "MIT" ]
1
2019-04-02T15:24:40.000Z
2019-04-02T15:24:40.000Z
""" Writing actual code might be hard to understand for new-learners. Pseudocode is a tool for writing algorithms without knowing how to code. This module contains classes and methods for parsing pseudocode to AST and then evaluating it. Example: If you installed this module with pip you can run pseudocode from fi...
24.537037
92
0.675472
0
0
0
0
0
0
0
0
795
0.599096
2df6c6319b7d1906f84dc0b600c9446955b1aa9f
320
py
Python
adabru_talon/code/deep_sleep.py
adabru/speech
74a4398693186f5b90ac5b3252aa7bd2764fa695
[ "WTFPL" ]
null
null
null
adabru_talon/code/deep_sleep.py
adabru/speech
74a4398693186f5b90ac5b3252aa7bd2764fa695
[ "WTFPL" ]
null
null
null
adabru_talon/code/deep_sleep.py
adabru/speech
74a4398693186f5b90ac5b3252aa7bd2764fa695
[ "WTFPL" ]
null
null
null
from talon import ( Module, Context, ) mod = Module() mod.tag("deep_sleep", desc="Enable deep sleep") ctx = Context() @mod.action_class class Actions: def enable_deep_sleep(): """???""" ctx.tags = ["user.deep_sleep"] def disable_deep_sleep(): """???""" ctx.tags = []
15.238095
47
0.55625
171
0.534375
0
0
189
0.590625
0
0
66
0.20625
2df782b87d6da8a3b61ad938472a58ca41cb66f2
396
py
Python
stubs/esp32_1_10_0/upip_utarfile.py
jmannau/micropython-stubber
8930e8a0038192fd259b31a193d1da3b2501256a
[ "MIT" ]
null
null
null
stubs/esp32_1_10_0/upip_utarfile.py
jmannau/micropython-stubber
8930e8a0038192fd259b31a193d1da3b2501256a
[ "MIT" ]
null
null
null
stubs/esp32_1_10_0/upip_utarfile.py
jmannau/micropython-stubber
8930e8a0038192fd259b31a193d1da3b2501256a
[ "MIT" ]
null
null
null
"Module 'upip_utarfile' on firmware 'v1.10-247-g0fb15fc3f on 2019-03-29'" DIRTYPE = 'dir' class FileSection(): ... def read(): pass def readinto(): pass def skip(): pass REGTYPE = 'file' TAR_HEADER = None class TarFile(): ... def extractfile(): pass def next(): ...
13.2
73
0.560606
64
0.161616
0
0
0
0
0
0
84
0.212121
2df89db144b707f4b0822c6ae9ce1acc6ef701ad
482
py
Python
core/src/zeit/content/author/browser/interfaces.py
rickdg/vivi
16134ac954bf8425646d4ad47bdd1f372e089355
[ "BSD-3-Clause" ]
5
2019-05-16T09:51:29.000Z
2021-05-31T09:30:03.000Z
core/src/zeit/content/author/browser/interfaces.py
rickdg/vivi
16134ac954bf8425646d4ad47bdd1f372e089355
[ "BSD-3-Clause" ]
107
2019-05-24T12:19:02.000Z
2022-03-23T15:05:56.000Z
core/src/zeit/content/author/browser/interfaces.py
rickdg/vivi
16134ac954bf8425646d4ad47bdd1f372e089355
[ "BSD-3-Clause" ]
3
2020-08-14T11:01:17.000Z
2022-01-08T17:32:19.000Z
from zeit.cms.i18n import MessageFactory as _ import zope.formlib.interfaces import zope.interface @zope.interface.implementer(zope.formlib.interfaces.IWidgetInputError) class DuplicateAuthorWarning(Exception): def doc(self): return _( u'An author with the given name already exists. ' ...
32.133333
70
0.692946
309
0.641079
0
0
380
0.788382
0
0
178
0.369295
2df8c42e864589ea93f8316ea84d6115885699fb
237
py
Python
Skyhero-admin/Day 29/exp8_3.py
adityajoshi-08/100-Days-of-Code
22026ca37dd8bcf5e5e22a8a302510249936c002
[ "MIT" ]
33
2022-01-11T14:00:24.000Z
2022-03-24T02:49:44.000Z
Skyhero-admin/Day 29/exp8_3.py
adityajoshi-08/100-Days-of-Code
22026ca37dd8bcf5e5e22a8a302510249936c002
[ "MIT" ]
28
2022-01-11T17:08:52.000Z
2022-03-15T17:03:15.000Z
Skyhero-admin/Day 29/exp8_3.py
adityajoshi-08/100-Days-of-Code
22026ca37dd8bcf5e5e22a8a302510249936c002
[ "MIT" ]
57
2022-01-11T15:54:07.000Z
2022-03-27T04:37:42.000Z
def countWord(word): count = 0 with open('test.txt') as file: for line in file: if word in line: count += line.count(word) return count word = input('Enter word: ') count = countWord(word) print(word, '- occurence: ', count)
21.545455
35
0.658228
0
0
0
0
0
0
0
0
39
0.164557
2df9a0c0fb58029492e4ab2e5a697ee378f5037d
9,190
py
Python
utils.py
khangt1k25/Clustering-Segmentation
4a7262c9d12fac4f595c8d0740342017b498262b
[ "MIT" ]
null
null
null
utils.py
khangt1k25/Clustering-Segmentation
4a7262c9d12fac4f595c8d0740342017b498262b
[ "MIT" ]
null
null
null
utils.py
khangt1k25/Clustering-Segmentation
4a7262c9d12fac4f595c8d0740342017b498262b
[ "MIT" ]
null
null
null
import random import os import logging import pickle import numpy as np import torch import torch.nn as nn import torch.nn.functional as F import torch.backends.cudnn as cudnn # import faiss ################################################################################ # General-...
31.152542
111
0.569206
774
0.084222
0
0
0
0
0
0
2,209
0.24037
2df9e5faeeb7d475c0095425ade4eae6bf0cbee6
7,009
py
Python
rif_template.py
EngRaff92/RDL_REG_GEN
1da36a247552217d009b41b035ddda742ad2aa3e
[ "MIT" ]
2
2022-01-11T19:22:16.000Z
2022-01-11T20:19:55.000Z
rif_template.py
EngRaff92/RDL_REG_GEN
1da36a247552217d009b41b035ddda742ad2aa3e
[ "MIT" ]
null
null
null
rif_template.py
EngRaff92/RDL_REG_GEN
1da36a247552217d009b41b035ddda742ad2aa3e
[ "MIT" ]
null
null
null
header = """/* Icebreaker and IceSugar RSMB5 project - RV32I for Lattice iCE40 With complete open-source toolchain flow using: -> yosys -> icarus verilog -> icestorm project Tests are written in several languages -> Systemverilog Pure Testbench (Vivado) -> UVM testbench (Vivado) -> PyUvm (Icarus) -> Formal ...
31.151111
119
0.66329
0
0
0
0
0
0
0
0
6,110
0.871736
2dfab9e21824f933194ff41412afd5eaebd5cb04
438
py
Python
reader.py
Asylumrunner/FeedingFrenzy
7f0d96f8361cb2c37cd41d06345e6ec0aa721472
[ "MIT" ]
1
2020-12-08T13:09:38.000Z
2020-12-08T13:09:38.000Z
reader.py
weisisheng/FeedingFrenzy
7f0d96f8361cb2c37cd41d06345e6ec0aa721472
[ "MIT" ]
null
null
null
reader.py
weisisheng/FeedingFrenzy
7f0d96f8361cb2c37cd41d06345e6ec0aa721472
[ "MIT" ]
1
2020-12-08T13:09:39.000Z
2020-12-08T13:09:39.000Z
import feedparser def read_rss_feed(feed_url): feed = feedparser.parse(feed_url) return [trim_entry(entry) for entry in feed.entries] def trim_entry(entry): return { 'date': "{}/{}/{}".format(entry.published_parsed.tm_year, entry.published_parsed.tm_mon, entry.published_parsed.tm_mday), 't...
31.285714
129
0.6621
0
0
0
0
0
0
0
0
46
0.105023
2dfac8a859dbed739d1b56982bcc545aec26ba63
9,229
py
Python
modmail/config.py
fossabot/modmail-1
ffbc3f981efb455f920e8c9f52657fbc2b802816
[ "MIT" ]
null
null
null
modmail/config.py
fossabot/modmail-1
ffbc3f981efb455f920e8c9f52657fbc2b802816
[ "MIT" ]
null
null
null
modmail/config.py
fossabot/modmail-1
ffbc3f981efb455f920e8c9f52657fbc2b802816
[ "MIT" ]
null
null
null
import asyncio import datetime import json import logging import os import sys import typing from pathlib import Path from typing import Any, Dict, Optional, Tuple import discord import toml from discord.ext.commands import BadArgument from pydantic import BaseModel from pydantic import BaseSettings as PydanticBaseSet...
29.113565
98
0.694983
7,086
0.767797
0
0
487
0.052768
0
0
2,301
0.249323
2dfc0e1a9a6d36009062ade1fde99b49f19b17a2
5,851
py
Python
turnip/prots.py
RuthAngus/turnip
83aa899b6f35e709cd8a63c5395ff8e070a91bb9
[ "MIT" ]
null
null
null
turnip/prots.py
RuthAngus/turnip
83aa899b6f35e709cd8a63c5395ff8e070a91bb9
[ "MIT" ]
null
null
null
turnip/prots.py
RuthAngus/turnip
83aa899b6f35e709cd8a63c5395ff8e070a91bb9
[ "MIT" ]
null
null
null
# plot rotation period vs orbital period import os import numpy as np import matplotlib.pyplot as plt import pandas as pd import glob import re from gyro import gyro_age import teff_bv as tbv import scipy.stats as sps from calc_completeness import calc_comp # np.set_printoptions(threshold=np.nan, linewidth=9) plotpar...
30.633508
78
0.604683
0
0
0
0
0
0
0
0
1,338
0.228679
2dfc27f1da91e13bb0050491db5539cdfb26d239
9,911
py
Python
proper_mod/prop_dm.py
RupertDodkins/medis
bdb1f00fb93506da2a1f251bc6780e70e97a16c5
[ "MIT" ]
1
2021-06-25T17:35:56.000Z
2021-06-25T17:35:56.000Z
proper_mod/prop_dm.py
RupertDodkins/medis
bdb1f00fb93506da2a1f251bc6780e70e97a16c5
[ "MIT" ]
null
null
null
proper_mod/prop_dm.py
RupertDodkins/medis
bdb1f00fb93506da2a1f251bc6780e70e97a16c5
[ "MIT" ]
2
2018-12-08T15:05:13.000Z
2019-08-08T17:28:24.000Z
# Copyright 2016, 2017 California Institute of Technology # Users must agree to abide by the restrictions listed in the # file "LegalStuff.txt" in the PROPER library directory. # # PROPER developed at Jet Propulsion Laboratory/California Inst. Technology # Original IDL version by John Krist # Python transla...
38.414729
114
0.634648
0
0
0
0
0
0
0
0
4,729
0.477147
2dfeb124e98b0f347e20cdfa1b942484c6bbcdf7
1,571
py
Python
asap-tools/experiments/depricated/handler/comparative.py
project-asap/Profiler
eaad7eafe3635a2d0881c13069a3ac632784fd3a
[ "Apache-2.0" ]
3
2017-04-18T17:09:29.000Z
2017-11-08T22:55:32.000Z
asap-tools/experiments/depricated/handler/comparative.py
project-asap/Profiler
eaad7eafe3635a2d0881c13069a3ac632784fd3a
[ "Apache-2.0" ]
18
2016-11-07T10:44:58.000Z
2017-04-25T12:40:24.000Z
asap-tools/experiments/depricated/handler/comparative.py
project-asap/Profiler
eaad7eafe3635a2d0881c13069a3ac632784fd3a
[ "Apache-2.0" ]
4
2015-12-09T09:09:59.000Z
2018-05-23T14:29:00.000Z
__author__ = 'cmantas' from tools import * # Kmeans mahout vs spark m_q = """select mahout_kmeans_text.documents/1000, mahout_kmeans_text.time/1000 from mahout_tfidf inner join mahout_kmeans_text ON mahout_tfidf.documents=mahout_kmeans_text.documents AND mahout_tfidf.dimensions=mahout_kmeans_text.dimensions where ...
38.317073
128
0.760025
0
0
0
0
0
0
0
0
1,313
0.835773
2dff63249548afd5c182283e332b2e72f7db6505
1,818
py
Python
docs/sample_code/debugging_info/src/dataset.py
mindspore-ai/docs
e7cbd69fe2bbd7870aa4591510ed3342ec6a3d41
[ "Apache-2.0", "CC-BY-4.0" ]
288
2020-03-28T07:00:25.000Z
2021-12-26T14:56:31.000Z
docs/sample_code/debugging_info/src/dataset.py
mindspore-ai/docs
e7cbd69fe2bbd7870aa4591510ed3342ec6a3d41
[ "Apache-2.0", "CC-BY-4.0" ]
1
2021-07-21T08:11:58.000Z
2021-07-21T08:11:58.000Z
docs/sample_code/debugging_info/src/dataset.py
mindspore-ai/docs
e7cbd69fe2bbd7870aa4591510ed3342ec6a3d41
[ "Apache-2.0", "CC-BY-4.0" ]
37
2020-03-30T06:38:37.000Z
2021-09-17T05:47:59.000Z
# Copyright 2021 Huawei Technologies Co., Ltd # # 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...
42.27907
94
0.69802
0
0
474
0.260726
0
0
0
0
709
0.389989
2dffcb312aeb4d575f278141844b269942663fab
3,338
py
Python
exercise/venv/lib/python3.7/site-packages/sqreen/sdk/events.py
assuzzanne/my-sqreen
81ae0eab417a1dbc0ae6b1778ebfdd71591c3c5b
[ "MIT" ]
null
null
null
exercise/venv/lib/python3.7/site-packages/sqreen/sdk/events.py
assuzzanne/my-sqreen
81ae0eab417a1dbc0ae6b1778ebfdd71591c3c5b
[ "MIT" ]
1
2021-06-02T00:27:34.000Z
2021-06-02T00:27:34.000Z
exercise/venv/lib/python3.7/site-packages/sqreen/sdk/events.py
assuzzanne/notifications-dispatcher-api
81ae0eab417a1dbc0ae6b1778ebfdd71591c3c5b
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright (c) 2016, 2017, 2018, 2019 Sqreen. All rights reserved. # Please refer to our terms for more information: # # https://www.sqreen.io/terms.html # import logging import traceback from datetime import datetime from ..runtime_storage import runtime from ..utils import is_string LO...
29.539823
78
0.629718
0
0
0
0
0
0
0
0
1,088
0.325944
930100236a4359a4387dd68192ff211e5a4519df
149
py
Python
roona/roona/doctype/roona_app_setting/test_roona_app_setting.py
mohsinalimat/roona
b24336d9d56eb443a883131afffd9091c9a66add
[ "MIT" ]
1
2021-08-28T04:24:00.000Z
2021-08-28T04:24:00.000Z
roona/roona/doctype/roona_app_setting/test_roona_app_setting.py
mohsinalimat/roona
b24336d9d56eb443a883131afffd9091c9a66add
[ "MIT" ]
null
null
null
roona/roona/doctype/roona_app_setting/test_roona_app_setting.py
mohsinalimat/roona
b24336d9d56eb443a883131afffd9091c9a66add
[ "MIT" ]
null
null
null
# Copyright (c) 2021, Roona and Contributors # See license.txt # import frappe import unittest class TestRoonaAppSetting(unittest.TestCase): pass
16.555556
45
0.785235
51
0.342282
0
0
0
0
0
0
76
0.510067
9302285f60696162f64b949eeb7c5d5dad50cb49
37,505
py
Python
workspace/module/maya-python-2.7/LxMaya/command/maShdr.py
no7hings/Lynxi
43c745198a714c2e5aca86c6d7a014adeeb9abf7
[ "MIT" ]
2
2018-03-06T03:33:55.000Z
2019-03-26T03:25:11.000Z
workspace/module/maya-python-2.7/LxMaya/command/maShdr.py
no7hings/lynxi
43c745198a714c2e5aca86c6d7a014adeeb9abf7
[ "MIT" ]
null
null
null
workspace/module/maya-python-2.7/LxMaya/command/maShdr.py
no7hings/lynxi
43c745198a714c2e5aca86c6d7a014adeeb9abf7
[ "MIT" ]
null
null
null
# coding=utf-8 # noinspection PyUnresolvedReferences import maya.cmds as cmds from LxBasic import bscMtdCore, bscObjects, bscMethods # from LxPreset import prsConfigure, prsOutputs # from LxCore.config import appCfg # from LxCore.preset.prod import assetPr # from LxDatabase import dtbMtdCore # from LxDatabase.data imp...
36.878073
153
0.627916
0
0
0
0
195
0.005199
0
0
2,708
0.072204
9302303524c2d1d2dcea444d0b37ee6e17561f6a
441
py
Python
db/Service.py
hamedsh/healthCheck
8f6b8ffffc1f1d8849a58b4966e54d30ead9556b
[ "Apache-2.0" ]
null
null
null
db/Service.py
hamedsh/healthCheck
8f6b8ffffc1f1d8849a58b4966e54d30ead9556b
[ "Apache-2.0" ]
null
null
null
db/Service.py
hamedsh/healthCheck
8f6b8ffffc1f1d8849a58b4966e54d30ead9556b
[ "Apache-2.0" ]
null
null
null
import json class Service(object): id: int = None name: str = None type: int = None type_name: str = None repeat_period: int = 5 # repeat period by second metadata = {} def __init__(self, arr: list): self.id = arr[0] self.name = arr[1] self.type = arr[2] ...
25.941176
60
0.557823
428
0.970522
0
0
0
0
0
0
31
0.070295
9302d12e0eb5ea7aeef313eeca626e9071df7895
22,422
py
Python
nbpipeline/rules.py
krassowski/nbpipeline
c2337db2b19767b2cdfcc9bf019e2bf687bb4423
[ "MIT" ]
16
2019-07-17T17:15:52.000Z
2021-11-19T07:15:19.000Z
nbpipeline/rules.py
krassowski/nbpipeline
c2337db2b19767b2cdfcc9bf019e2bf687bb4423
[ "MIT" ]
5
2019-07-17T21:09:31.000Z
2020-04-18T18:53:46.000Z
nbpipeline/rules.py
krassowski/nbpipeline
c2337db2b19767b2cdfcc9bf019e2bf687bb4423
[ "MIT" ]
2
2019-12-18T19:23:38.000Z
2021-03-05T10:55:48.000Z
import json import pickle import re from copy import copy, deepcopy from functools import lru_cache from json import JSONDecodeError from os import system, walk, sep from abc import ABC, abstractmethod from pathlib import Path import time from subprocess import check_output from tempfile import NamedTemporaryFile from ...
36.281553
181
0.550085
19,145
0.853849
0
0
1,365
0.060878
0
0
5,900
0.263134
9303234b67903102cb5d3258f289b230610a2cf6
801
py
Python
analyse_images.py
aalto-ui/SemanticCollage
61b4f241aef6c029a634f0d70a2a35799db46076
[ "MIT" ]
null
null
null
analyse_images.py
aalto-ui/SemanticCollage
61b4f241aef6c029a634f0d70a2a35799db46076
[ "MIT" ]
4
2021-06-08T21:23:18.000Z
2022-03-12T00:25:45.000Z
analyse_images.py
aalto-ui/SemanticCollage
61b4f241aef6c029a634f0d70a2a35799db46076
[ "MIT" ]
1
2021-04-21T03:41:32.000Z
2021-04-21T03:41:32.000Z
# encoding=utf8 from load_to_db import * save_list = [] import random import string def randomString(url, stringLength=20): """Generate a random string of fixed length """ Letters = string.ascii_lowercase + string.ascii_uppercase + string.digits url_split = url.split(".") format_ = url_split[-1] ...
25.83871
78
0.694132
0
0
0
0
0
0
0
0
183
0.228464
93034a9a6233faadc660e34f44294b994aedc83c
124
py
Python
Eolymp_DSAWeek1_Solns/Digits.py
sulphatet/MiniProjectsndCodingProbs
a8f6c9c3993854cad9444800f9d1b1720a239b39
[ "MIT" ]
1
2022-02-24T08:29:00.000Z
2022-02-24T08:29:00.000Z
Eolymp_DSAWeek1_Solns/Digits.py
sulphatet/MiniProjectsndCodingProbs
a8f6c9c3993854cad9444800f9d1b1720a239b39
[ "MIT" ]
null
null
null
Eolymp_DSAWeek1_Solns/Digits.py
sulphatet/MiniProjectsndCodingProbs
a8f6c9c3993854cad9444800f9d1b1720a239b39
[ "MIT" ]
null
null
null
num = int(input()) x = 0 if num == 0: print(1) exit() while num != 0: x +=1 num = num//10 print(x)
12.4
19
0.435484
0
0
0
0
0
0
0
0
0
0
9304179c9a7ef19d7cafd259a2cdab5634a69a04
786
py
Python
stable_baselines_model_based_rl/wrapper/gym_step_handlers/continuous_mountain_car.py
micheltokic/stable_baselines_model_based_rl
75bac906aeba69072878ceb15d9be459b1f436c3
[ "Apache-2.0" ]
1
2022-01-08T17:08:13.000Z
2022-01-08T17:08:13.000Z
stable_baselines_model_based_rl/wrapper/gym_step_handlers/continuous_mountain_car.py
micheltokic/stable_baselines_model_based_rl
75bac906aeba69072878ceb15d9be459b1f436c3
[ "Apache-2.0" ]
5
2021-09-15T18:14:48.000Z
2021-09-19T16:17:51.000Z
stable_baselines_model_based_rl/wrapper/gym_step_handlers/continuous_mountain_car.py
micheltokic/stable_baselines_model_based_rl
75bac906aeba69072878ceb15d9be459b1f436c3
[ "Apache-2.0" ]
null
null
null
import math from stable_baselines_model_based_rl.wrapper.step_handler import StepRewardDoneHandler class ContinuousMountainCarStepHandler(StepRewardDoneHandler): goal_position = 0.45 goal_velocity = 0 def get_done(self, step: int) -> bool: s = self.observation.to_value_list() ...
27.103448
87
0.614504
677
0.861323
0
0
0
0
0
0
50
0.063613
9304861c31e91f902b6f121f6ca51fab98031cbe
3,305
py
Python
src/mod_stats_by_aircraft/background_jobs/background_job.py
FGlazov/IL2Stats_ByAircraftMod
acf66eb3f31a7e789d61a5c60d32fd30dbcedf4b
[ "MIT" ]
null
null
null
src/mod_stats_by_aircraft/background_jobs/background_job.py
FGlazov/IL2Stats_ByAircraftMod
acf66eb3f31a7e789d61a5c60d32fd30dbcedf4b
[ "MIT" ]
null
null
null
src/mod_stats_by_aircraft/background_jobs/background_job.py
FGlazov/IL2Stats_ByAircraftMod
acf66eb3f31a7e789d61a5c60d32fd30dbcedf4b
[ "MIT" ]
null
null
null
from django.core.exceptions import FieldError from django.db import ProgrammingError from stats.models import Tour, Sortie from django.db.models import Max import config RETRO_COMPUTE_FOR_LAST_TOURS = config.get_conf()['stats'].getint('retro_compute_for_last_tours') if RETRO_COMPUTE_FOR_LAST_TOURS is None: RETRO_C...
39.819277
120
0.69289
2,753
0.83298
0
0
0
0
0
0
2,036
0.616036
9306105a7d6f94715dda6856227c83b2b5fdd102
2,016
py
Python
peakinvestigator/actions/run.py
jct197/PeakInvestigator-Python-SDK
75d58d67208deff07b6e366e0b34d37570b46bf5
[ "BSD-3-Clause" ]
null
null
null
peakinvestigator/actions/run.py
jct197/PeakInvestigator-Python-SDK
75d58d67208deff07b6e366e0b34d37570b46bf5
[ "BSD-3-Clause" ]
4
2019-03-14T03:01:05.000Z
2019-10-16T20:51:03.000Z
peakinvestigator/actions/run.py
jct197/PeakInvestigator-Python-SDK
75d58d67208deff07b6e366e0b34d37570b46bf5
[ "BSD-3-Clause" ]
1
2019-01-05T03:50:02.000Z
2019-01-05T03:50:02.000Z
## -*- coding: utf-8 -*- # # Copyright (c) 2016, Veritomyx, Inc. # # This file is part of the Python SDK for PeakInvestigator # (http://veritomyx.com) and is distributed under the terms # of the BSD 3-Clause license. from .base import BaseAction class RunAction(BaseAction): """This class is used to make a RUN cal...
28
80
0.590278
1,762
0.874008
0
0
102
0.050595
0
0
862
0.427579
93067822138f982e5bd62fcfd10cc9b4ae612b62
3,757
py
Python
.setup/bin/input_forum_data.py
zeez2030/Submitty
7118944ff4adc6f15d76984eb10a1e862926d724
[ "BSD-3-Clause" ]
411
2016-06-14T20:52:25.000Z
2022-03-31T21:20:25.000Z
.setup/bin/input_forum_data.py
KaelanWillauer/Submitty
cf9b6ceda15ec0a661e2ca81ea7864790094c64a
[ "BSD-3-Clause" ]
5,730
2016-05-23T21:04:32.000Z
2022-03-31T10:08:06.000Z
.setup/bin/input_forum_data.py
KaelanWillauer/Submitty
cf9b6ceda15ec0a661e2ca81ea7864790094c64a
[ "BSD-3-Clause" ]
423
2016-09-22T21:11:30.000Z
2022-03-29T18:55:28.000Z
#!/usr/bin/env python3 import os import sys import json from datetime import datetime from submitty_utils import dateutils def generatePossibleDatabases(): current = dateutils.get_current_semester() pre = 'submitty_' + current + '_' path = "/var/local/submitty/courses/" + current return [pre + name for name in ...
51.465753
398
0.672345
0
0
0
0
0
0
0
0
2,265
0.602875
93074d51c0af568361ff79fea1825596f6e8553e
252
py
Python
edbdeploy/spec/__init__.py
mw2q/postgres-deployment
7b07375588da6ede25062c5518922275ed35844b
[ "BSD-3-Clause" ]
null
null
null
edbdeploy/spec/__init__.py
mw2q/postgres-deployment
7b07375588da6ede25062c5518922275ed35844b
[ "BSD-3-Clause" ]
1
2021-07-01T18:02:00.000Z
2021-07-01T18:02:00.000Z
edbdeploy/spec/__init__.py
jt-edb/postgres-deployment
871cf517379152f096f44d682dd03d93971715a2
[ "BSD-3-Clause" ]
null
null
null
class SpecValidator: def __init__(self, type=None, default=None, choices=[], min=None, max=None): self.type = type self.default = default self.choices = choices self.min = min self.max = max
28
69
0.559524
251
0.996032
0
0
0
0
0
0
0
0
930766e7b8ffd5a77cf2414fe0de6b57a69af041
48
py
Python
levelpy/async/__init__.py
rch/levelpy
59e546854b3d478f3467bd573eb5f6b4da62d239
[ "MIT" ]
4
2015-11-06T22:50:22.000Z
2020-05-31T14:49:58.000Z
levelpy/async/__init__.py
rch/levelpy
59e546854b3d478f3467bd573eb5f6b4da62d239
[ "MIT" ]
null
null
null
levelpy/async/__init__.py
rch/levelpy
59e546854b3d478f3467bd573eb5f6b4da62d239
[ "MIT" ]
3
2017-01-25T22:26:40.000Z
2021-03-24T07:49:33.000Z
# # levelpy/async/__init__.py # import asyncio
8
27
0.729167
0
0
0
0
0
0
0
0
29
0.604167
9308413560c1330a48aacec8d18de1204b19be47
751
py
Python
app/domain/messaging/tests/test_models.py
anthon-alindada/sanic_messaging
2afbc601790b4a3dbe17e0a95c589412250d8bee
[ "MIT" ]
1
2019-06-21T08:51:01.000Z
2019-06-21T08:51:01.000Z
app/domain/messaging/tests/test_models.py
anthon-alindada/sanic_messaging
2afbc601790b4a3dbe17e0a95c589412250d8bee
[ "MIT" ]
6
2021-03-09T07:47:26.000Z
2022-02-26T11:33:25.000Z
app/domain/messaging/tests/test_models.py
anthon-alindada/sanic_messaging
2afbc601790b4a3dbe17e0a95c589412250d8bee
[ "MIT" ]
null
null
null
# -*- coding: utf-8 # Models from ..models import Channel, ChannelUser, Message async def test_channel_model(channel_data): channel = Channel( owner_id=1, name='General') channel = await channel.create() assert repr(channel) == "<Channel: 'General'>" async def test_channel_user_model(c...
21.457143
62
0.653795
0
0
0
0
0
0
662
0.881491
102
0.135819
93095d98ffed279b01860ac139ac53ed5312a8e1
206
py
Python
aiosnow/models/__init__.py
michaeldcanady/aiosnow
db515b1560d651fc7696a184990c2a2d68db8961
[ "MIT" ]
38
2020-08-03T17:58:48.000Z
2022-03-30T19:39:24.000Z
aiosnow/models/__init__.py
michaeldcanady/aiosnow
db515b1560d651fc7696a184990c2a2d68db8961
[ "MIT" ]
34
2020-01-20T10:11:46.000Z
2020-06-05T21:25:23.000Z
aiosnow/models/__init__.py
michaeldcanady/aiosnow
db515b1560d651fc7696a184990c2a2d68db8961
[ "MIT" ]
5
2021-03-26T19:35:20.000Z
2022-01-23T20:09:55.000Z
from ._base import BaseModel, BaseModelMeta, BaseTableModel from ._schema import BaseField, ModelSchema, ModelSchemaMeta, Pluck, fields from .attachment import AttachmentModel from .table import TableModel
41.2
75
0.84466
0
0
0
0
0
0
0
0
0
0
930a3159a270d17b3e016e6419675cf9059057cd
506
py
Python
examples/providers/factory_aggregate/prototype.py
kinow/python-dependency-injector
ebd98bebe9a8fc0b57e68cfc12c4979833baa6a5
[ "BSD-3-Clause" ]
null
null
null
examples/providers/factory_aggregate/prototype.py
kinow/python-dependency-injector
ebd98bebe9a8fc0b57e68cfc12c4979833baa6a5
[ "BSD-3-Clause" ]
null
null
null
examples/providers/factory_aggregate/prototype.py
kinow/python-dependency-injector
ebd98bebe9a8fc0b57e68cfc12c4979833baa6a5
[ "BSD-3-Clause" ]
null
null
null
"""FactoryAggregate provider prototype.""" class FactoryAggregate: """FactoryAggregate provider prototype.""" def __init__(self, **factories): """Initialize instance.""" self.factories = factories def __call__(self, factory_name, *args, **kwargs): """Create object.""" ret...
28.111111
60
0.656126
460
0.909091
0
0
0
0
0
0
171
0.337945
930b6911eb3b99feb00dad0f3f43696dfc1d21e0
27,385
py
Python
test_cnlunardate.py
YuBPan/cnlunardate
c19aa9821aecadea6647ac026bf233ab9f7cff90
[ "MIT" ]
null
null
null
test_cnlunardate.py
YuBPan/cnlunardate
c19aa9821aecadea6647ac026bf233ab9f7cff90
[ "MIT" ]
1
2020-01-10T05:06:27.000Z
2020-01-10T05:06:27.000Z
test_cnlunardate.py
YuBPan/cnlunardate
c19aa9821aecadea6647ac026bf233ab9f7cff90
[ "MIT" ]
null
null
null
"""Test cnlunardate.""" import unittest import pickle from cnlunardate import cnlunardate from cnlunardate import MIN_YEAR, MAX_YEAR from datetime import timedelta pickle_loads = {pickle.loads, pickle._loads} pickle_choices = [(pickle, pickle, proto) for proto in range(pickle.HIGHEST_PROTOCOL + 1)...
38.843972
88
0.560964
26,996
0.985795
0
0
0
0
0
0
3,373
0.12317
930cba7bd9d0b2f6492d68c76893da92e46a129b
756
py
Python
sloc_report/sloc_time.py
depop/sloc_report
0e65ece3f5c95e6ab38313b38c110fea275326b2
[ "MIT" ]
1
2016-11-08T13:57:42.000Z
2016-11-08T13:57:42.000Z
sloc_report/sloc_time.py
depop/sloc_report
0e65ece3f5c95e6ab38313b38c110fea275326b2
[ "MIT" ]
null
null
null
sloc_report/sloc_time.py
depop/sloc_report
0e65ece3f5c95e6ab38313b38c110fea275326b2
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- import time def time_now(): """returns current unix time as an integer""" return int(time.time()) def get_day_times(num_days=1, end_time=time_now()): """returns a list of tuples, where each tuple contains the start and end times (in unix time format, as integers) of the day(s...
30.24
78
0.650794
0
0
0
0
0
0
0
0
421
0.556878
930f2ed4f673b85667c94e0ca3470af435e95eb6
4,593
py
Python
tests/home_platform/test_env.py
LuCeHe/home-platform
06f9370bfacecebd0c8623a3b8f0511532a9a1f0
[ "BSD-3-Clause" ]
1
2021-07-27T09:15:43.000Z
2021-07-27T09:15:43.000Z
tests/home_platform/test_env.py
LuCeHe/home-platform
06f9370bfacecebd0c8623a3b8f0511532a9a1f0
[ "BSD-3-Clause" ]
null
null
null
tests/home_platform/test_env.py
LuCeHe/home-platform
06f9370bfacecebd0c8623a3b8f0511532a9a1f0
[ "BSD-3-Clause" ]
1
2021-07-27T09:21:12.000Z
2021-07-27T09:21:12.000Z
# Copyright (c) 2017, IGLU consortium # All rights reserved. # # Redistribution and use in source and binary forms, with or without modification, # are permitted provided that the following conditions are met: # # - Redistributions of source code must retain the above copyright notice, # this list of conditions and...
34.276119
108
0.660353
2,499
0.544089
0
0
0
0
0
0
1,855
0.403875
931108d420be8aaf39aff7a40c0bd93abe403cb2
9,244
py
Python
slack_sdk/oauth/installation_store/sqlite3/__init__.py
timgates42/python-slack-sdk
6339fbe81031c9aec3f95927ac03706fd31f3544
[ "MIT" ]
null
null
null
slack_sdk/oauth/installation_store/sqlite3/__init__.py
timgates42/python-slack-sdk
6339fbe81031c9aec3f95927ac03706fd31f3544
[ "MIT" ]
null
null
null
slack_sdk/oauth/installation_store/sqlite3/__init__.py
timgates42/python-slack-sdk
6339fbe81031c9aec3f95927ac03706fd31f3544
[ "MIT" ]
null
null
null
import logging import sqlite3 from logging import Logger from sqlite3 import Connection from typing import Optional from slack_sdk.oauth.installation_store.async_installation_store import ( AsyncInstallationStore, ) from slack_sdk.oauth.installation_store.installation_store import InstallationStore from slack_sdk....
33.860806
115
0.442449
8,794
0.95132
0
0
157
0.016984
289
0.031264
4,511
0.487992
93131be5c2c31240f968a45b8920858ae167fb1c
381
py
Python
address/admin.py
City-of-Helsinki/geo-search
d200e06223938e456d13ae9ab94e9dad149216d0
[ "MIT" ]
null
null
null
address/admin.py
City-of-Helsinki/geo-search
d200e06223938e456d13ae9ab94e9dad149216d0
[ "MIT" ]
11
2021-09-13T11:46:17.000Z
2022-03-11T08:40:02.000Z
address/admin.py
City-of-Helsinki/geo-search
d200e06223938e456d13ae9ab94e9dad149216d0
[ "MIT" ]
1
2021-10-04T09:15:44.000Z
2021-10-04T09:15:44.000Z
from django.contrib import admin from parler.admin import TranslatableAdmin from .models import Address, Municipality, Street @admin.register(Municipality) class MunicipalityAdmin(TranslatableAdmin): pass @admin.register(Street) class StreetAdmin(TranslatableAdmin): pass @admin.register(Address) class Ad...
19.05
49
0.792651
166
0.435696
0
0
245
0.643045
0
0
8
0.020997
93146c79f274fc09fa5d075dfc9d826dd48bbd57
7,704
py
Python
src/pynwb/core.py
q0j0p/pynwb
6c3a864662f2cce63b542f9f614cc632903f9bc1
[ "BSD-3-Clause-LBNL" ]
null
null
null
src/pynwb/core.py
q0j0p/pynwb
6c3a864662f2cce63b542f9f614cc632903f9bc1
[ "BSD-3-Clause-LBNL" ]
1
2021-06-01T22:25:36.000Z
2021-06-01T22:25:36.000Z
src/pynwb/core.py
q0j0p/pynwb
6c3a864662f2cce63b542f9f614cc632903f9bc1
[ "BSD-3-Clause-LBNL" ]
null
null
null
from collections import Iterable from h5py import RegionReference from .form.utils import docval, getargs, ExtenderMeta, call_docval_func, popargs from .form import Container, Data, DataRegion, get_region_slicer from . import CORE_NAMESPACE, register_class from six import with_metaclass def set_parents(container, p...
35.666667
113
0.610462
6,967
0.904335
0
0
6,305
0.818406
0
0
2,405
0.312175
9314b87cfdabe5d7ea05f8832e4b689d86e607b3
2,246
py
Python
tests/test_get_google_streetview.py
AQ-AI/open-geo-engine
a9382083d5a51ffef4af0a76df7a6e15d64cbaf5
[ "BSD-3-Clause" ]
null
null
null
tests/test_get_google_streetview.py
AQ-AI/open-geo-engine
a9382083d5a51ffef4af0a76df7a6e15d64cbaf5
[ "BSD-3-Clause" ]
19
2022-01-15T19:13:26.000Z
2022-03-20T22:30:00.000Z
tests/test_get_google_streetview.py
AQ-AI/open-geo-engine
a9382083d5a51ffef4af0a76df7a6e15d64cbaf5
[ "BSD-3-Clause" ]
2
2022-01-18T11:34:28.000Z
2022-03-01T15:54:45.000Z
import os import pandas as pd from open_geo_engine.src.get_google_streetview import GetGoogleStreetView def test_get_google_streetview(): size = "600x300" heading = "151.78" pitch = "-0.76" key = os.environ.get("GOOGLE_DEV_API_KEY") image_folder = "tests/test_data" links_file = "tests/test_da...
32.085714
93
0.661175
0
0
0
0
0
0
0
0
514
0.228851
93157bdf0f57eb1e0ef1f559e165114bea5a6259
6,186
py
Python
src/cirrus/selfupdate.py
Maxsparrow/cirrus
ae9639daba4f2d8d9285e98d5b11a89eac573f96
[ "Apache-2.0" ]
12
2016-04-30T16:13:55.000Z
2021-01-20T23:42:31.000Z
src/cirrus/selfupdate.py
Maxsparrow/cirrus
ae9639daba4f2d8d9285e98d5b11a89eac573f96
[ "Apache-2.0" ]
153
2015-02-12T15:25:42.000Z
2020-03-09T07:16:15.000Z
src/cirrus/selfupdate.py
Maxsparrow/cirrus
ae9639daba4f2d8d9285e98d5b11a89eac573f96
[ "Apache-2.0" ]
7
2015-06-15T21:30:38.000Z
2020-02-17T02:13:00.000Z
#!/usr/bin/env python """ _selfupdate_ Util command for updating the cirrus install itself Supports getting a spefified branch or tag, or defaults to looking up the latest release and using that instead. """ import sys import argparse import arrow import os import requests import inspect import contextlib from cirru...
24.943548
95
0.619787
0
0
172
0.027805
199
0.032169
0
0
2,165
0.349984
9315f46f0473c586d45b30c9a29e297a98f70f78
1,335
py
Python
util.py
DrD1esel/GoWDiscordTeamBot
9e61a386e2d341a42dd45b60eda7f57a95100283
[ "BSD-3-Clause" ]
null
null
null
util.py
DrD1esel/GoWDiscordTeamBot
9e61a386e2d341a42dd45b60eda7f57a95100283
[ "BSD-3-Clause" ]
null
null
null
util.py
DrD1esel/GoWDiscordTeamBot
9e61a386e2d341a42dd45b60eda7f57a95100283
[ "BSD-3-Clause" ]
null
null
null
from base_bot import log def atoi(text): return int(text) if text.isdigit() else text def bool_to_emoticon(value): return value and "✅" or "❌" # https://stackoverflow.com/questions/7204805/how-to-merge-dictionaries-of-dictionaries # merges b into a def merge(a, b, path=None): if path is None: path = [...
23.421053
95
0.591011
0
0
124
0.092606
0
0
134
0.100075
230
0.17177
93163adbfdd7c695f51e1b653629e2cdd3f9438d
877
py
Python
jsgf_tags.py
onchiptech/pyjsgf
f7ff26323e5e602ea10e7d302610c2fcb46234d6
[ "MIT" ]
null
null
null
jsgf_tags.py
onchiptech/pyjsgf
f7ff26323e5e602ea10e7d302610c2fcb46234d6
[ "MIT" ]
null
null
null
jsgf_tags.py
onchiptech/pyjsgf
f7ff26323e5e602ea10e7d302610c2fcb46234d6
[ "MIT" ]
null
null
null
from jsgf import parse_grammar_string def main(args): # Parse input grammar file. with open(args.input_file_path, "r") as fp: text = fp.read() print("\ninput grammar: ") print(text) grammar = parse_grammar_string(text) # Print it. print("\noutput grammar: ") text = ...
28.290323
90
0.654504
0
0
0
0
0
0
0
0
290
0.330673
931a1eefc8b03639fa3b9346aaf0553aa1293c86
2,685
py
Python
webspider/utils/log.py
chem2099/webspider
5577878b69d85a4b75ece6701f6018767d0ee4bc
[ "MIT" ]
256
2017-06-01T10:56:41.000Z
2019-06-28T17:26:08.000Z
webspider/utils/log.py
chem2099/webspider
5577878b69d85a4b75ece6701f6018767d0ee4bc
[ "MIT" ]
14
2017-10-30T14:32:08.000Z
2019-05-27T09:49:39.000Z
webspider/utils/log.py
chem2099/webspider
5577878b69d85a4b75ece6701f6018767d0ee4bc
[ "MIT" ]
88
2017-09-01T08:06:48.000Z
2019-06-26T06:23:04.000Z
# coding: utf-8 import os import logging.config from webspider import setting LOG_FILE_PATH = os.path.join(setting.BASE_DIR, 'log', 'spider_log.txt') LOGGING_CONFIG = { 'version': 1, 'disable_existing_loggers': True, 'formatters': { 'default': { 'format': '%(asctime)s- %(module)s:%(l...
27.397959
100
0.448417
0
0
0
0
0
0
0
0
1,192
0.440015
931abc49c69a201ff08a4c4d4963b916bcd4009f
53,851
py
Python
manila/tests/share/drivers/hitachi/hnas/test_driver.py
kpawar89/manila
d487c2db728cedf8357b9f4acbc0a45c21c3a83e
[ "Apache-2.0" ]
1
2020-06-17T13:20:21.000Z
2020-06-17T13:20:21.000Z
manila/tests/share/drivers/hitachi/hnas/test_driver.py
viroel/manila
fbcabd2c03985000bd9b4d4d9a4478bc0b784efa
[ "Apache-2.0" ]
null
null
null
manila/tests/share/drivers/hitachi/hnas/test_driver.py
viroel/manila
fbcabd2c03985000bd9b4d4d9a4478bc0b784efa
[ "Apache-2.0" ]
1
2021-02-23T05:52:11.000Z
2021-02-23T05:52:11.000Z
# Copyright (c) 2015 Hitachi Data Systems, Inc. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # U...
42.236078
79
0.624705
47,348
0.879241
0
0
47,357
0.879408
0
0
11,584
0.215112
931acb0aff55dcc9d21d89e7ab39172fc95002c7
2,978
py
Python
sloth/test/dummy_data.py
maurov/xraysloth
6f18ddcb02050431574693d46bcf4b89c719c40b
[ "BSD-3-Clause" ]
4
2015-07-03T09:38:58.000Z
2022-03-16T11:09:49.000Z
sloth/test/dummy_data.py
maurov/xraysloth
6f18ddcb02050431574693d46bcf4b89c719c40b
[ "BSD-3-Clause" ]
null
null
null
sloth/test/dummy_data.py
maurov/xraysloth
6f18ddcb02050431574693d46bcf4b89c719c40b
[ "BSD-3-Clause" ]
2
2017-05-22T17:14:11.000Z
2017-07-04T04:52:08.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- """Generate dummy data for tests/examples """ import numpy as np def dummy_gauss_image(x=None, y=None, xhalfrng=1.5, yhalfrng=None, xcen=0.5, ycen=0.9, xnpts=1024, ynpts=None, xsigma=0.55, ysigma=0.25, nois...
28.09434
78
0.576897
0
0
0
0
0
0
0
0
1,530
0.513768
931b5bb2e3fc783e728514ebc6699f871cd2d505
159
py
Python
approximate_equilibrium/optimize/__init__.py
NREL/EMISApproximateEquilibrium.jl
a94ec58e812496cec3cb40bdb84b14229c1b6440
[ "BSD-3-Clause" ]
1
2021-12-04T06:37:50.000Z
2021-12-04T06:37:50.000Z
approximate_equilibrium/optimize/__init__.py
NREL/EMISApproximateEquilibrium.jl
a94ec58e812496cec3cb40bdb84b14229c1b6440
[ "BSD-3-Clause" ]
null
null
null
approximate_equilibrium/optimize/__init__.py
NREL/EMISApproximateEquilibrium.jl
a94ec58e812496cec3cb40bdb84b14229c1b6440
[ "BSD-3-Clause" ]
null
null
null
from approximate_equilibrium.optimize.optimization import de_optimizer, objective_function, brute_force_optimizer, objective_function_iccn, gradient_optimizer
79.5
158
0.91195
0
0
0
0
0
0
0
0
0
0
931b8e121065b6e7d0568d8a4e43d037da1b3b77
4,295
py
Python
dynatrace/environment_v2/networkzones.py
hashmibilaldt/api-client-python
910008a4c6800a547535acba79b7a49e540b5d16
[ "Apache-2.0" ]
null
null
null
dynatrace/environment_v2/networkzones.py
hashmibilaldt/api-client-python
910008a4c6800a547535acba79b7a49e540b5d16
[ "Apache-2.0" ]
null
null
null
dynatrace/environment_v2/networkzones.py
hashmibilaldt/api-client-python
910008a4c6800a547535acba79b7a49e540b5d16
[ "Apache-2.0" ]
null
null
null
""" Copyright 2021 Dynatrace LLC Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software ...
40.518868
122
0.723632
3,421
0.796508
0
0
0
0
0
0
2,036
0.47404
931c579da4bce33b29c5c9ae99f9be7566e00afb
2,984
py
Python
tools/scruffy/checkers/orgs.py
paultag/pupa
137293925503496e15137540e049bf544e129971
[ "BSD-3-Clause" ]
null
null
null
tools/scruffy/checkers/orgs.py
paultag/pupa
137293925503496e15137540e049bf544e129971
[ "BSD-3-Clause" ]
null
null
null
tools/scruffy/checkers/orgs.py
paultag/pupa
137293925503496e15137540e049bf544e129971
[ "BSD-3-Clause" ]
null
null
null
from .. import Check from .common import common_checks def check(db): for org in db.organizations.find({"classification": "legislature"}): for check in common_checks(org, 'organization', 'organizations'): yield check jid = org.get('jurisdiction_id') if jid is None: ...
40.324324
76
0.464142
0
0
2,926
0.980563
0
0
0
0
823
0.275804
931d21150c4fef29838bf9c36548a5b31d001040
5,165
py
Python
ip_allow_lists/ip_compare.py
PaloAltoNetworks/pcs-migration-management
766c8c861befa92e593b23ad6d248e33f62054bb
[ "ISC" ]
1
2022-03-17T12:51:45.000Z
2022-03-17T12:51:45.000Z
ip_allow_lists/ip_compare.py
PaloAltoNetworks/pcs-migration-management
766c8c861befa92e593b23ad6d248e33f62054bb
[ "ISC" ]
2
2021-11-03T15:34:40.000Z
2021-12-14T19:50:20.000Z
ip_allow_lists/ip_compare.py
PaloAltoNetworks/pcs-migration-management
766c8c861befa92e593b23ad6d248e33f62054bb
[ "ISC" ]
4
2021-11-09T17:57:01.000Z
2022-01-24T17:41:21.000Z
from sdk.color_print import c_print from tqdm import tqdm #Migrate def compare_trusted_networks(source_networks, clone_networks): ''' Accepts the source trusted alert network list and a clone trusted alert network list. Compares the source tenants network list to a clone tenant networks list. ''' ...
40.992063
134
0.634656
0
0
0
0
0
0
0
0
1,496
0.289642
931dd502335fb2a0b22db32c479212aa84cc2649
4,004
py
Python
lib/surface/source/captures/upload.py
bopopescu/SDK
e6d9aaee2456f706d1d86e8ec2a41d146e33550d
[ "Apache-2.0" ]
null
null
null
lib/surface/source/captures/upload.py
bopopescu/SDK
e6d9aaee2456f706d1d86e8ec2a41d146e33550d
[ "Apache-2.0" ]
null
null
null
lib/surface/source/captures/upload.py
bopopescu/SDK
e6d9aaee2456f706d1d86e8ec2a41d146e33550d
[ "Apache-2.0" ]
2
2020-11-04T03:08:21.000Z
2020-11-05T08:14:41.000Z
# Copyright 2015 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 ag...
37.074074
80
0.665085
3,157
0.788462
0
0
1,217
0.303946
0
0
2,795
0.698052
931f2ac2304379a993c5a0b48864b82b64c72225
7,047
py
Python
pyk/src/pyk/tests/test_kcfg.py
runtimeverification/k
044c49e535516c1d142206795bf1d8b2c0fcbf0d
[ "BSD-3-Clause" ]
23
2017-02-26T10:49:29.000Z
2022-03-22T20:32:10.000Z
pyk/src/pyk/tests/test_kcfg.py
runtimeverification/k
044c49e535516c1d142206795bf1d8b2c0fcbf0d
[ "BSD-3-Clause" ]
112
2016-01-20T16:23:47.000Z
2022-03-31T21:54:59.000Z
pyk/src/pyk/tests/test_kcfg.py
runtimeverification/k
044c49e535516c1d142206795bf1d8b2c0fcbf0d
[ "BSD-3-Clause" ]
6
2016-02-23T19:12:26.000Z
2022-03-31T01:53:24.000Z
from typing import Any, Dict, List, Tuple from unittest import TestCase from ..cterm import CTerm from ..kast import TRUE, KApply, KInner, KVariable from ..kcfg import KCFG from ..prelude import token def nid(i: int) -> str: return node(i).id # over 10 is variables def term(i: int) -> CTerm: inside: KInner...
28.301205
97
0.548744
5,964
0.846318
0
0
0
0
0
0
518
0.073506
931f8afd4a5774ac2d04ce2cc9a73a4ae7812abb
645
py
Python
tests/test_unit/test_graph/test_tesserae.py
karljohanw/cortexpy
70dcce771136f98edb5250ad8abd2a46bda7f0a6
[ "Apache-2.0" ]
null
null
null
tests/test_unit/test_graph/test_tesserae.py
karljohanw/cortexpy
70dcce771136f98edb5250ad8abd2a46bda7f0a6
[ "Apache-2.0" ]
null
null
null
tests/test_unit/test_graph/test_tesserae.py
karljohanw/cortexpy
70dcce771136f98edb5250ad8abd2a46bda7f0a6
[ "Apache-2.0" ]
null
null
null
from cortexpy.tesserae import Tesserae class TestTesserae: def test_mosaic_alignment_on_short_query_and_two_templates(self): # given query = "GTAGGCGAGATGACGCCAT" targets = ["GTAGGCGAGTCCCGTTTATA", "CCACAGAAGATGACGCCATT"] # when t = Tesserae() p = t.align(query, ta...
24.807692
69
0.541085
603
0.934884
0
0
0
0
0
0
136
0.210853
93208a4a4fa8500fdf154d105073add88c48b822
151
py
Python
napari_bb_annotations/__init__.py
czbiohub/napari-bb-annotation
c316931de363e41c702e69316933b486d5f38cb2
[ "BSD-3-Clause" ]
3
2021-03-12T18:13:40.000Z
2021-04-27T00:22:03.000Z
napari_bb_annotations/__init__.py
czbiohub/napari-bb-annotation
c316931de363e41c702e69316933b486d5f38cb2
[ "BSD-3-Clause" ]
13
2021-04-05T20:32:08.000Z
2021-06-23T05:35:37.000Z
napari_bb_annotations/__init__.py
czbiohub/napari-bb-annotations
c316931de363e41c702e69316933b486d5f38cb2
[ "BSD-3-Clause" ]
null
null
null
try: from ._version import version as __version__ except ImportError: __version__ = "unknown" from . import _key_bindings del _key_bindings
15.1
48
0.761589
0
0
0
0
0
0
0
0
9
0.059603
9320c7176b7d0f5a4f94419ff900dc0287dd18c3
8,544
py
Python
tests/l_layer/backward.py
felix990302/nnlib
618c9f860ff2298ed2e0bbcb249ae74eeb8a408b
[ "Apache-2.0" ]
1
2019-03-27T17:02:50.000Z
2019-03-27T17:02:50.000Z
tests/l_layer/backward.py
felix990302/nnlib
618c9f860ff2298ed2e0bbcb249ae74eeb8a408b
[ "Apache-2.0" ]
null
null
null
tests/l_layer/backward.py
felix990302/nnlib
618c9f860ff2298ed2e0bbcb249ae74eeb8a408b
[ "Apache-2.0" ]
null
null
null
import numpy as np from numpy.random import RandomState from numpy.testing import assert_allclose from nnlib.l_layer.backward import linear_backward, linear_backward_activation, model_backward from nnlib.utils.derivative import sigmoid_backward, relu_backward from nnlib.utils.activation import sigmoid, relu def test...
37.147826
122
0.508544
0
0
0
0
0
0
0
0
59
0.006905
93220f73e54d4401d09974fa1a394a20787d5fd3
137
py
Python
src/news_lk/upload_data.py
nuuuwan/news_lk
a2e60fd2dfb49f7c5e8d432cdd5fad0511575197
[ "MIT" ]
null
null
null
src/news_lk/upload_data.py
nuuuwan/news_lk
a2e60fd2dfb49f7c5e8d432cdd5fad0511575197
[ "MIT" ]
null
null
null
src/news_lk/upload_data.py
nuuuwan/news_lk
a2e60fd2dfb49f7c5e8d432cdd5fad0511575197
[ "MIT" ]
null
null
null
"""Uploaded data to nuuuwan/news_lk:data branch.""" from news_lk import scrape if __name__ == '__main__': scrape.scrape_and_dump()
19.571429
51
0.729927
0
0
0
0
0
0
0
0
61
0.445255
932270b633249ca330baa6276f57f5c2b0d91f48
1,814
py
Python
deli_counter/http/mounts/root/routes/v1/validation_models/regions.py
sandwichcloud/deli-counter
e72ee3966f4457ffbd1d432b3516965075c7c86e
[ "MIT" ]
1
2017-10-19T09:25:29.000Z
2017-10-19T09:25:29.000Z
deli_counter/http/mounts/root/routes/v1/validation_models/regions.py
sandwichcloud/deli-counter
e72ee3966f4457ffbd1d432b3516965075c7c86e
[ "MIT" ]
null
null
null
deli_counter/http/mounts/root/routes/v1/validation_models/regions.py
sandwichcloud/deli-counter
e72ee3966f4457ffbd1d432b3516965075c7c86e
[ "MIT" ]
null
null
null
from schematics import Model from schematics.types import IntType, UUIDType, StringType, BooleanType from ingredients_db.models.region import RegionState, Region from ingredients_http.schematics.types import ArrowType, EnumType class RequestCreateRegion(Model): name = StringType(required=True, min_length=3) ...
31.275862
71
0.738699
1,570
0.865491
0
0
624
0.343991
0
0
0
0
932632d6c40f6be38b39dba6166b3aebd0e53a0b
257
py
Python
winremoteenum.py
simondotsh/WinRemoteEnum
f40cff76788709e54e7ed19157870dacfcaa0bc3
[ "MIT" ]
2
2021-11-25T14:15:12.000Z
2022-02-02T04:27:17.000Z
winremoteenum.py
simondotsh/WinRemoteEnum
f40cff76788709e54e7ed19157870dacfcaa0bc3
[ "MIT" ]
null
null
null
winremoteenum.py
simondotsh/WinRemoteEnum
f40cff76788709e54e7ed19157870dacfcaa0bc3
[ "MIT" ]
2
2021-11-03T18:11:40.000Z
2022-02-02T15:11:30.000Z
#!/usr/bin/env python3 from src.cli import Cli from src.core import Orchestrator def main(): config, args = Cli.parse_and_validate() Orchestrator.launch_modules(config, args.modules, args.targets, args.audit) if __name__ == '__main__': main()
23.363636
79
0.727626
0
0
0
0
0
0
0
0
32
0.124514
93280c05a831eacbb39a47e2e89a3ee261d3a78f
1,696
py
Python
setup.py
easyScience/easyCore
5d16d5b27803277d0c44886f94dab599f764ae0b
[ "BSD-3-Clause" ]
2
2021-11-02T10:22:45.000Z
2022-02-18T23:41:19.000Z
setup.py
easyScience/easyCore
5d16d5b27803277d0c44886f94dab599f764ae0b
[ "BSD-3-Clause" ]
114
2020-06-30T08:52:27.000Z
2022-03-30T20:47:56.000Z
setup.py
easyScience/easyCore
5d16d5b27803277d0c44886f94dab599f764ae0b
[ "BSD-3-Clause" ]
1
2022-03-04T13:01:09.000Z
2022-03-04T13:01:09.000Z
# -*- coding: utf-8 -*- # DO NOT EDIT THIS FILE! # This file has been autogenerated by dephell <3 # https://github.com/dephell/dephell try: from setuptools import setup except ImportError: from distutils.core import setup import os.path readme = '' here = os.path.abspath(os.path.dirname(__file__)) readme_...
43.487179
266
0.661557
0
0
0
0
0
0
0
0
1,053
0.620873
9328e23e8d93546efc5261e03fba860e2483f556
1,505
py
Python
submit_scripts/mizuRoute/mizuRoute_wrapper.py
BrisClimate/flood-cascade
660c29275a87785153d0f107ed23104fcbcbddee
[ "MIT" ]
null
null
null
submit_scripts/mizuRoute/mizuRoute_wrapper.py
BrisClimate/flood-cascade
660c29275a87785153d0f107ed23104fcbcbddee
[ "MIT" ]
null
null
null
submit_scripts/mizuRoute/mizuRoute_wrapper.py
BrisClimate/flood-cascade
660c29275a87785153d0f107ed23104fcbcbddee
[ "MIT" ]
3
2020-11-08T16:01:47.000Z
2021-01-13T17:13:32.000Z
#!/cm/shared/languages/python-3.3.2/bin/python # submit script for submission of mizuRoute simualtions # Peter Uhe Oct 29 2019 # # call this script from 'run_mizuRoute_templated_mswep050calib.py which creates a qsub job to submit to the HPC queue # This script is actually called from 'call_pythonscript.sh' (which is n...
35
120
0.765449
0
0
0
0
0
0
0
0
772
0.512957
932c68f3bfdd0fa4f25517ebea01555ab01db520
17,968
py
Python
txml.py
jdelgit/txml
07c28962a34397b546d56c1adb60c0ef20f71c22
[ "MIT" ]
null
null
null
txml.py
jdelgit/txml
07c28962a34397b546d56c1adb60c0ef20f71c22
[ "MIT" ]
null
null
null
txml.py
jdelgit/txml
07c28962a34397b546d56c1adb60c0ef20f71c22
[ "MIT" ]
null
null
null
from xml.etree.ElementTree import iterparse, ParseError from io import StringIO from os.path import isfile from re import findall class XmlParser: def __init__(self, source=""): self.source = source self.proces_file = False self.use_io = False self.encoding = 'UTF-8' self....
37.668763
105
0.509016
17,832
0.992431
4,728
0.263134
0
0
0
0
4,922
0.273931
932d1dd3f28fbe11836dbddd059b224fbf55e0a8
1,404
py
Python
app/orders.py
Gabkings/fast-food-api1
129bea30cfa0ecb017f2f26bb34a6aa2716f9f04
[ "MIT" ]
null
null
null
app/orders.py
Gabkings/fast-food-api1
129bea30cfa0ecb017f2f26bb34a6aa2716f9f04
[ "MIT" ]
null
null
null
app/orders.py
Gabkings/fast-food-api1
129bea30cfa0ecb017f2f26bb34a6aa2716f9f04
[ "MIT" ]
null
null
null
from flask import Flask, request from flask_restful import Resource from .models import Order, orders class OrderDetals(Resource): def get(self, id): order = Order().get_order_by_id(id) if not order: return {"message":"Order not found"}, 404 return {"order": ord...
25.527273
78
0.58547
1,276
0.908832
0
0
0
0
0
0
364
0.259259
932e05da095fad449ca578a15a6dc14375d17137
5,198
py
Python
python/storyboard/bias_optimizer.py
stanford-futuredata/sketchstore
c209e4d01343a05dc5aecdb7a9801fc639019fd3
[ "Apache-2.0" ]
5
2020-05-07T02:25:01.000Z
2021-05-25T07:54:42.000Z
python/storyboard/bias_optimizer.py
stanford-futuredata/sketchstore
c209e4d01343a05dc5aecdb7a9801fc639019fd3
[ "Apache-2.0" ]
1
2020-07-31T20:04:59.000Z
2020-07-31T20:04:59.000Z
python/storyboard/bias_optimizer.py
stanford-futuredata/sketchstore
c209e4d01343a05dc5aecdb7a9801fc639019fd3
[ "Apache-2.0" ]
1
2020-07-06T20:39:05.000Z
2020-07-06T20:39:05.000Z
from typing import Mapping, Any, Sequence import numpy as np import heapq import math from tqdm import tqdm import scipy.optimize import cvxpy as cvx def n_bias(x_count: np.ndarray, bias: float): # return np.sum(x_count[x_count >= bias]) clipped = np.clip(x_count - bias, a_min=0, a_max=None) return n...
29.039106
93
0.55329
0
0
0
0
0
0
0
0
624
0.120046
932e5914cfad78eadac43b5ef29f6ed1ab78376e
874
py
Python
config/conf.d/04-spawner-common.py
possiblyMikeB/davidson-jupyter
8980c1249756d421b70950b9895b75e16d7e68c0
[ "BSD-3-Clause" ]
null
null
null
config/conf.d/04-spawner-common.py
possiblyMikeB/davidson-jupyter
8980c1249756d421b70950b9895b75e16d7e68c0
[ "BSD-3-Clause" ]
null
null
null
config/conf.d/04-spawner-common.py
possiblyMikeB/davidson-jupyter
8980c1249756d421b70950b9895b75e16d7e68c0
[ "BSD-3-Clause" ]
null
null
null
import json, os ## base spawner config try: c.Spawner.cmd = \ json.loads(os.environ['SPAWNER_CMD']) except KeyError: c.Spawner.cmd = [ 'jupyterhub-singleuser', # OAuth wrapped jupyter instance server '--KernelManager.transport=ipc', # -- all kernel comms over UNIX sockets '--Ma...
33.615385
114
0.693364
0
0
0
0
0
0
0
0
508
0.581236
932fbbd3b2489556c428736a9418ed424b87b707
339
py
Python
datasets/__init__.py
radarsat1/latentspace
e651dc14ed7b4dd3f28577639a06b7160c5fca5e
[ "MIT" ]
null
null
null
datasets/__init__.py
radarsat1/latentspace
e651dc14ed7b4dd3f28577639a06b7160c5fca5e
[ "MIT" ]
null
null
null
datasets/__init__.py
radarsat1/latentspace
e651dc14ed7b4dd3f28577639a06b7160c5fca5e
[ "MIT" ]
null
null
null
__all__ = ['get_dataset'] def get_dataset(params): if params['name'] == 'multimodal_points': from datasets.multimodal_gaussian_2d import Dataset return Dataset(params) elif params['name'] == 'kicks': from datasets.kicks import Dataset return Dataset(params) assert False and...
28.25
59
0.675516
0
0
0
0
0
0
0
0
68
0.20059
932fd6103c8719c4b707f1914eddb51377cb4198
8,419
py
Python
memsource_cli/models/async_request_dto.py
unofficial-memsource/memsource-cli-client
a6639506b74e95476da87f4375953448b76ea90c
[ "Apache-2.0" ]
16
2019-09-25T00:20:38.000Z
2021-05-04T05:56:10.000Z
memsource_cli/models/async_request_dto.py
zerodayz/memsource-cli-client
c2574f1467539a49e6637c874e88d75c7ef789b3
[ "Apache-2.0" ]
26
2019-09-30T14:00:03.000Z
2021-05-12T11:15:18.000Z
memsource_cli/models/async_request_dto.py
zerodayz/memsource-cli-client
c2574f1467539a49e6637c874e88d75c7ef789b3
[ "Apache-2.0" ]
1
2021-05-24T16:19:14.000Z
2021-05-24T16:19:14.000Z
# coding: utf-8 """ Memsource REST API Welcome to Memsource's API documentation. To view our legacy APIs please [visit our documentation](https://wiki.memsource.com/wiki/Memsource_API) and for more information about our new APIs, [visit our blog](https://www.memsource.com/blog/2017/10/24/introducing-rest-apis...
29.749117
421
0.602328
7,459
0.885972
0
0
3,967
0.471196
0
0
4,302
0.510987
932ff6498e2e97f5e213cd233e1d1ac08b819528
188
py
Python
python/p.py
gmasching/project-euler
b4afa94f83756f3a44667ec2d7fcb5bca4304825
[ "MIT" ]
2
2020-06-03T20:55:27.000Z
2021-04-17T10:10:17.000Z
python/p.py
gmasching/project-euler
b4afa94f83756f3a44667ec2d7fcb5bca4304825
[ "MIT" ]
null
null
null
python/p.py
gmasching/project-euler
b4afa94f83756f3a44667ec2d7fcb5bca4304825
[ "MIT" ]
2
2020-06-03T20:55:33.000Z
2021-04-17T10:10:47.000Z
def f(x): #return 1*x**3 + 5*x**2 - 2*x - 24 #return 1*x**4 - 4*x**3 - 2*x**2 + 12*x - 3 return 82*x + 6*x**2 - 0.67*x**3 print(f(2)-f(1)) #print((f(3.5) - f(0.5)) / -3) #print(f(0.5))
23.5
44
0.457447
0
0
0
0
0
0
0
0
121
0.643617
93319b806e1474fb346a2ce001af51f8482adee0
19,194
py
Python
Inference_Model.py
CODEJIN/WaveRNN
835462e71fd151c8ca0a0ed68f691089f1637851
[ "MIT" ]
1
2020-03-22T16:55:53.000Z
2020-03-22T16:55:53.000Z
Inference_Model.py
CODEJIN/WaveRNN
835462e71fd151c8ca0a0ed68f691089f1637851
[ "MIT" ]
null
null
null
Inference_Model.py
CODEJIN/WaveRNN
835462e71fd151c8ca0a0ed68f691089f1637851
[ "MIT" ]
1
2020-12-12T14:41:50.000Z
2020-12-12T14:41:50.000Z
from __future__ import absolute_import from __future__ import division from __future__ import print_function import collections import functools import itertools import threading import numpy as np from six.moves import zip # pylint: disable=redefined-builtin from google.protobuf import json_format from tensorflow....
53.022099
109
0.627019
16,036
0.835469
0
0
4,900
0.255288
0
0
5,449
0.283891
9333f46a3199aee3308e67cf5584433366413e92
761
py
Python
tests/test_net_sender_proxy.py
nicoddemus/aioworkers
4ab85064844dc28141833d1348989d8c891f3d7d
[ "Apache-2.0" ]
45
2017-04-26T23:50:30.000Z
2021-12-29T03:21:06.000Z
tests/test_net_sender_proxy.py
nicoddemus/aioworkers
4ab85064844dc28141833d1348989d8c891f3d7d
[ "Apache-2.0" ]
63
2017-08-01T10:35:45.000Z
2022-03-01T18:07:49.000Z
tests/test_net_sender_proxy.py
nicoddemus/aioworkers
4ab85064844dc28141833d1348989d8c891f3d7d
[ "Apache-2.0" ]
6
2017-10-19T08:21:23.000Z
2021-12-29T03:25:32.000Z
import pytest @pytest.fixture def config_yaml(): return """ local_sender: cls: aioworkers.net.sender.proxy.Facade queue: queue1 queue1: cls: aioworkers.queue.base.Queue worker: cls: aioworkers.net.sender.proxy.Worker autorun: true input: queue1 ...
20.026316
47
0.603154
0
0
0
0
478
0.628121
263
0.345598
493
0.647832
9335654c2c674182289730fd81c0651f4e53ee52
2,794
py
Python
train.py
olavosamp/kaggle_isic_2020
d4680251997b65987f25d66a6d1d8aec1e71adaa
[ "MIT" ]
null
null
null
train.py
olavosamp/kaggle_isic_2020
d4680251997b65987f25d66a6d1d8aec1e71adaa
[ "MIT" ]
null
null
null
train.py
olavosamp/kaggle_isic_2020
d4680251997b65987f25d66a6d1d8aec1e71adaa
[ "MIT" ]
null
null
null
import torch import torchvision import numpy as np import lib.model from lib.model import MetadataModel, train_model import lib.dataset import lib.dirs as dirs import lib.utils as utils import lib.vis_utils as vutils import lib.defines as defs if __name__ == "__main__": data_path = dirs.data...
39.914286
107
0.67287
0
0
0
0
0
0
0
0
609
0.217967
9335a61ad4c952dbdf3a5969c7c3e1df83b69ab0
1,533
py
Python
src/owncloud_rename.py
pzia/keepmydatas
3783909119e7ece986a92b9e56ec53cddeb924e3
[ "MIT" ]
1
2020-07-17T02:14:39.000Z
2020-07-17T02:14:39.000Z
src/owncloud_rename.py
pzia/keepmydatas
3783909119e7ece986a92b9e56ec53cddeb924e3
[ "MIT" ]
null
null
null
src/owncloud_rename.py
pzia/keepmydatas
3783909119e7ece986a92b9e56ec53cddeb924e3
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- """Parse tree and find files matching owncloud forbidden characters. Rename in place or move into a specific folder """ import KmdCmd import KmdFiles import os, re import logging class KmdOwncloudRename(KmdCmd.KmdCommand): regexp = r'[\*:"?><|]+' def extendParser...
37.390244
133
0.55773
1,226
0.799739
0
0
0
0
0
0
366
0.238748
93367dc6cd9bf8f8bcaab3536826c212ad41d6ba
13,975
py
Python
gym_tetris/board.py
michielcx/Tetris-DQN
66ee640aaa2068f3db4798ddf51f1518c3779cc6
[ "MIT" ]
13
2019-10-23T09:32:33.000Z
2021-08-01T10:39:57.000Z
gym_tetris/board.py
michielcx/Tetris-DQN
66ee640aaa2068f3db4798ddf51f1518c3779cc6
[ "MIT" ]
1
2022-02-10T00:29:36.000Z
2022-02-10T00:29:36.000Z
gym_tetris/board.py
michielcx/Tetris-DQN
66ee640aaa2068f3db4798ddf51f1518c3779cc6
[ "MIT" ]
6
2020-10-16T01:43:35.000Z
2022-01-28T12:05:32.000Z
import random def get_random_bag(): """Returns a bag with unique pieces. (Bag randomizer)""" random_shapes = list(SHAPES) random.shuffle(random_shapes) return [Piece(0, 0, shape) for shape in random_shapes] class Shape: def __init__(self, code, blueprints): self.code = code self....
28.873967
115
0.536887
12,773
0.913989
340
0.024329
0
0
0
0
2,579
0.184544
9336c65fb9f6e0d74ee67f3a8efdd3cd42889844
249
py
Python
03. DP/2xn tile 2.py
KLumy/Basic-Algorithm
e52e4200c1955a9062569814ff3418dd06666845
[ "MIT" ]
1
2021-01-22T15:58:32.000Z
2021-01-22T15:58:32.000Z
03. DP/2xn tile 2.py
KLumy/Basic-Algorithm
e52e4200c1955a9062569814ff3418dd06666845
[ "MIT" ]
null
null
null
03. DP/2xn tile 2.py
KLumy/Basic-Algorithm
e52e4200c1955a9062569814ff3418dd06666845
[ "MIT" ]
null
null
null
import sys input = sys.stdin.readline n = int(input()) if n < 2: print(n) exit(0) d = [0] * (n+1) d[1] = 1 d[2] = 3 for i in range(n+1): if i < 3: continue d[i] = (d[i-1] % 10007 + (d[i-2]*2) % 10007) % 10007 print(d[n])
13.105263
56
0.481928
0
0
0
0
0
0
0
0
0
0
93371a58fa9ad1c5d98cbf050ae2c7e71f6f8acc
1,074
py
Python
menu.py
dadiletta/Saber
515751e7e9f0f12d97fa07606883eac73a352044
[ "MIT", "BSD-3-Clause" ]
null
null
null
menu.py
dadiletta/Saber
515751e7e9f0f12d97fa07606883eac73a352044
[ "MIT", "BSD-3-Clause" ]
null
null
null
menu.py
dadiletta/Saber
515751e7e9f0f12d97fa07606883eac73a352044
[ "MIT", "BSD-3-Clause" ]
null
null
null
import Light __author__ = 'adilettad' print("---------------") print("----Welcome----") print("------to-------") print("-----Saber-----") print("---------------") sab = Light.Saber() while True: command = raw_input('Your command:') if command == "blink": sab.demoLED() elif command == "dist" or...
22.851064
61
0.529795
0
0
0
0
0
0
0
0
276
0.256983
93388ca96a9f3273e22a1cd4ed97d8092f0d63f7
739
py
Python
a10/build/lib/a10/asvr/types.py
THS-on/AttestationEngine
6746d602215df43056b04515bd9b831f0bb0ddbb
[ "BSD-3-Clause-Clear" ]
null
null
null
a10/build/lib/a10/asvr/types.py
THS-on/AttestationEngine
6746d602215df43056b04515bd9b831f0bb0ddbb
[ "BSD-3-Clause-Clear" ]
4
2021-11-08T19:47:56.000Z
2021-11-25T10:30:50.000Z
a10/build/lib/a10/asvr/types.py
THS-on/AttestationEngine
6746d602215df43056b04515bd9b831f0bb0ddbb
[ "BSD-3-Clause-Clear" ]
null
null
null
# Copyright 2021 Nokia # Licensed under the BSD 3-Clause License. # SPDX-License-Identifier: BSD-3-Clause import a10.structures.constants import a10.structures.identity import a10.structures.returncode import a10.asvr.db.core import a10.asvr.db.announce import a10.asvr.elements def getTypes(): """Gets a list of...
21.114286
50
0.630582
0
0
0
0
0
0
0
0
317
0.428958
9338957c2d0434f6f713ebe7005892553e33c34d
456
py
Python
packages/migrations/0004_auto_20210416_1013.py
dandeduck/package-tracking-web
f7cb3dffd6f7f6b7ced5b1106a049c79c192dfa5
[ "MIT" ]
1
2021-02-11T22:16:51.000Z
2021-02-11T22:16:51.000Z
packages/migrations/0004_auto_20210416_1013.py
dandeduck/package-tracking-web
f7cb3dffd6f7f6b7ced5b1106a049c79c192dfa5
[ "MIT" ]
54
2021-02-11T18:52:11.000Z
2021-06-13T13:45:01.000Z
packages/migrations/0004_auto_20210416_1013.py
dandeduck/package-tracking-web
f7cb3dffd6f7f6b7ced5b1106a049c79c192dfa5
[ "MIT" ]
null
null
null
# Generated by Django 2.2.12 on 2021-04-16 10:13 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('packages', '0003_auto_20210416_1007'), ] operations = [ migrations.AlterField( model_name='address', name='street_n...
22.8
74
0.620614
362
0.79386
0
0
0
0
0
0
107
0.234649
933b4da8586a2940f3a4d00ebc21c1950b2eb3db
241
py
Python
website/music/views.py
mrsmartpants/DjangoTutorial-Beginners
11e64f4f982a576f814db5ed466f8b31bba5ae5c
[ "MIT" ]
null
null
null
website/music/views.py
mrsmartpants/DjangoTutorial-Beginners
11e64f4f982a576f814db5ed466f8b31bba5ae5c
[ "MIT" ]
null
null
null
website/music/views.py
mrsmartpants/DjangoTutorial-Beginners
11e64f4f982a576f814db5ed466f8b31bba5ae5c
[ "MIT" ]
null
null
null
from django.shortcuts import render # Python functions - user is going to request an url # Create your views here. from django.http import HttpResponse def index(request): return HttpResponse("<h1> This is the music app homepage</h1>")
30.125
67
0.763485
0
0
0
0
0
0
0
0
119
0.493776
933cd25c41f2ec4430b1ae8b3e9ce531b2bfd7b9
1,073
py
Python
LeafNATS/modules/embedding/position_embedding.py
dumpmemory/AspDecSSCL
004d73d3248e8fdee1336cfc6490ef4872583665
[ "MIT" ]
23
2020-12-16T15:50:07.000Z
2022-03-17T05:51:20.000Z
LeafNATS/modules/embedding/position_embedding.py
dumpmemory/AspDecSSCL
004d73d3248e8fdee1336cfc6490ef4872583665
[ "MIT" ]
3
2021-02-01T07:24:35.000Z
2021-11-24T09:28:35.000Z
LeafNATS/modules/embedding/position_embedding.py
dumpmemory/AspDecSSCL
004d73d3248e8fdee1336cfc6490ef4872583665
[ "MIT" ]
4
2021-05-12T06:49:43.000Z
2021-10-04T04:41:08.000Z
''' @author Tian Shi Please contact tshi@vt.edu ''' import math import torch class PositionalEmbedding(torch.nn.Module): ''' Implementation of Positional Embedding. ''' def __init__(self, hidden_size, device=torch.device("cpu")): super().__init__() self.hidden_size = hidden_size ...
26.170732
72
0.625349
992
0.924511
0
0
0
0
0
0
158
0.147251
933d30b34a1b5fd85d26dcd036d20209cd0759ee
3,108
py
Python
tests/tensor/sum_test.py
kbrodt/tor4
d09740b746c534e67a72f492c7c03654f5888a46
[ "MIT" ]
null
null
null
tests/tensor/sum_test.py
kbrodt/tor4
d09740b746c534e67a72f492c7c03654f5888a46
[ "MIT" ]
null
null
null
tests/tensor/sum_test.py
kbrodt/tor4
d09740b746c534e67a72f492c7c03654f5888a46
[ "MIT" ]
null
null
null
from tor4 import tensor def test_tensor_sum(): a = tensor(data=[-1, 1, 2]) a_sum = a.sum() assert a_sum.tolist() == 2 assert not a_sum.requires_grad def test_tensor_sum_backward(): a = tensor(data=[-1, 1, 2.0], requires_grad=True) a_sum = a.sum() a_sum.backward() assert a_sum.tolis...
28.254545
78
0.560811
0
0
0
0
0
0
0
0
0
0
933e03200f3271fcfb99f615ab7c6f6d828aa8d2
3,150
py
Python
Excite.py
JohnDoe2576/MyPythonCodes
9d714bc9f9909af0ade4142439da518b30b7d51d
[ "MIT" ]
null
null
null
Excite.py
JohnDoe2576/MyPythonCodes
9d714bc9f9909af0ade4142439da518b30b7d51d
[ "MIT" ]
null
null
null
Excite.py
JohnDoe2576/MyPythonCodes
9d714bc9f9909af0ade4142439da518b30b7d51d
[ "MIT" ]
null
null
null
import numpy as np import matplotlib.pyplot as plt def aprbs(**parms): # Generate an Amplitude modulated Pseudo-Random Binary Sequence (APRBS) # # The Pseudo-Random Binary Sequence (PRBS) is extensively used as an # excitation signal for System Identification of linear systems. It is # cha...
35
94
0.634286
0
0
0
0
0
0
0
0
1,505
0.477778