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
dd99b6d2cdd53e9871b02f6e724fb47ac13372e3
12,973
py
Python
programs/loadsheet/loadsheet.py
admin-db/OnboardingTools
0f9d363d461df8c01e99157386338633828f5f92
[ "Apache-2.0" ]
3
2021-04-24T14:39:50.000Z
2021-07-20T17:11:19.000Z
programs/loadsheet/loadsheet.py
admin-db/OnboardingTools
0f9d363d461df8c01e99157386338633828f5f92
[ "Apache-2.0" ]
2
2020-07-22T21:34:33.000Z
2021-01-14T19:26:12.000Z
programs/loadsheet/loadsheet.py
admin-db/OnboardingTools
0f9d363d461df8c01e99157386338633828f5f92
[ "Apache-2.0" ]
2
2020-07-16T03:34:35.000Z
2020-07-22T21:18:12.000Z
#Copyright 2020 DB Engineering #Licensed under the Apache License, Version 2.0 (the "License"); #you may not use this file except in compliance with the License. #You may obtain a copy of the License at # http://www.apache.org/licenses/LICENSE-2.0 #Unless required by applicable law or agreed to in writing, softwa...
27.427061
145
0.697757
11,459
0.883296
0
0
4,658
0.359053
0
0
7,036
0.542357
dd9b08662b0371253cd734386bb9a5108ab7a965
59,491
py
Python
anita.py
utkarsh009/Bnita
0f8ea0b389907f835685c572194b1eb5580a6286
[ "BSD-3-Clause" ]
2
2017-06-12T05:40:48.000Z
2017-06-23T17:09:51.000Z
anita.py
utkarsh009/Bnita
0f8ea0b389907f835685c572194b1eb5580a6286
[ "BSD-3-Clause" ]
null
null
null
anita.py
utkarsh009/Bnita
0f8ea0b389907f835685c572194b1eb5580a6286
[ "BSD-3-Clause" ]
null
null
null
# # This is the library part of Anita, the Automated NetBSD Installation # and Test Application. # import os import pexpect import re import string import subprocess import sys import time import urllib import urlparse __version__='1.40' # Your preferred NetBSD FTP mirror site. # This is used only by the obsolete co...
34.933059
120
0.599351
48,824
0.820696
0
0
0
0
0
0
25,172
0.423123
dd9b53c1d51423e3d8a448dcde0235338b5a8f9d
5,356
py
Python
solitude/testing/context.py
incerto-crypto/solitude
1b21a2ca4912da212d413322953ceb4ec2983c17
[ "BSD-3-Clause" ]
7
2019-03-25T21:48:42.000Z
2022-02-25T08:21:35.000Z
solitude/testing/context.py
incerto-crypto/solitude
1b21a2ca4912da212d413322953ceb4ec2983c17
[ "BSD-3-Clause" ]
null
null
null
solitude/testing/context.py
incerto-crypto/solitude
1b21a2ca4912da212d413322953ceb4ec2983c17
[ "BSD-3-Clause" ]
null
null
null
# Copyright (c) 2019, Solitude Developers # # This source code is licensed under the BSD-3-Clause license found in the # COPYING file in the root directory of this source tree from typing import Mapping, Union, Optional # noqa import os import shutil import tempfile from functools import wraps from collections import...
32.460606
92
0.668969
3,542
0.661314
0
0
1,687
0.314974
0
0
1,512
0.2823
dd9c212b2612a151f4e10e08866ba944cee12a2b
2,883
py
Python
openwater/zone/model.py
jeradM/openwater
740b7e76622a1ee909b970d9e5c612a840466cec
[ "MIT" ]
null
null
null
openwater/zone/model.py
jeradM/openwater
740b7e76622a1ee909b970d9e5c612a840466cec
[ "MIT" ]
null
null
null
openwater/zone/model.py
jeradM/openwater
740b7e76622a1ee909b970d9e5c612a840466cec
[ "MIT" ]
null
null
null
from abc import ABC, abstractmethod from datetime import datetime from typing import TYPE_CHECKING, Dict, Any, List, Optional if TYPE_CHECKING: from openwater.core import OpenWater class ZoneRun: def __init__(self, id: int, zone_id: int, start: datetime, duration: int): self.id = id self.zone...
25.289474
78
0.539369
2,691
0.933403
0
0
696
0.241415
85
0.029483
259
0.089837
dd9c57daac230a88704ee45525c7ddcffe34b216
2,339
py
Python
shrinkaddrspace/fix_preinit.py
vusec/midfat
9eb8d3c5188c0c262ad5f5de84f9e26530e38a4c
[ "Apache-2.0" ]
6
2017-06-02T00:16:57.000Z
2018-12-08T20:49:19.000Z
shrinkaddrspace/fix_preinit.py
vusec/midfat
9eb8d3c5188c0c262ad5f5de84f9e26530e38a4c
[ "Apache-2.0" ]
null
null
null
shrinkaddrspace/fix_preinit.py
vusec/midfat
9eb8d3c5188c0c262ad5f5de84f9e26530e38a4c
[ "Apache-2.0" ]
3
2019-05-12T08:52:48.000Z
2019-08-08T11:17:52.000Z
#!/usr/bin/env python import struct from elftools.elf.elffile import ELFFile def elf_get_preinit(elffile): preinit_offset = None preinit_funcs = tuple() for sec in elffile.iter_sections(): if sec.name == '.preinit_array': sz = sec['sh_size'] preinit_offset = sec['sh_offset...
32.486111
80
0.607525
0
0
0
0
0
0
0
0
455
0.194528
dd9d9e745268a05b2a5397b1a32f3f6189d22b3b
41
py
Python
ppq/utils/__init__.py
openppl-public/ppq
0fdea7d4982bc57feb6bb8548c7f012707fbd607
[ "Apache-2.0" ]
100
2021-12-31T09:34:06.000Z
2022-03-25T02:54:51.000Z
ppq/utils/__init__.py
openppl-public/ppq
0fdea7d4982bc57feb6bb8548c7f012707fbd607
[ "Apache-2.0" ]
12
2021-12-31T10:28:15.000Z
2022-03-31T07:08:44.000Z
ppq/utils/__init__.py
openppl-public/ppq
0fdea7d4982bc57feb6bb8548c7f012707fbd607
[ "Apache-2.0" ]
21
2021-12-31T09:51:02.000Z
2022-03-30T12:21:55.000Z
from .attribute import process_attribute
20.5
40
0.878049
0
0
0
0
0
0
0
0
0
0
dda05eca52f0bd879e75366f591fdb92e3e9abbd
855
py
Python
tests/test_views.py
pennlabs/django-shortener
a8f362863d4d8f13916e9e924ed316384f588373
[ "MIT" ]
3
2018-11-04T15:46:01.000Z
2020-01-06T13:49:46.000Z
tests/test_views.py
pennlabs/shortener
a8f362863d4d8f13916e9e924ed316384f588373
[ "MIT" ]
1
2019-07-30T04:31:19.000Z
2019-07-30T04:31:19.000Z
tests/test_views.py
pennlabs/shortener
a8f362863d4d8f13916e9e924ed316384f588373
[ "MIT" ]
2
2021-02-22T18:12:27.000Z
2021-09-16T18:51:47.000Z
import hashlib from django.test import TestCase from django.urls import reverse from shortener.models import Url class RedirectViewTestCase(TestCase): def setUp(self): self.redirect = "https://pennlabs.org" self.url, _ = Url.objects.get_or_create(long_url=self.redirect) def test_exists(self...
34.2
84
0.691228
737
0.861988
0
0
0
0
0
0
76
0.088889
dda073c654623fd4431b83697b75b0c9003f460a
1,758
py
Python
Models/Loss/__init__.py
bobo0810/classification
b27397308c5294dcc30a5aaddab4692becfc45d3
[ "MIT" ]
null
null
null
Models/Loss/__init__.py
bobo0810/classification
b27397308c5294dcc30a5aaddab4692becfc45d3
[ "MIT" ]
null
null
null
Models/Loss/__init__.py
bobo0810/classification
b27397308c5294dcc30a5aaddab4692becfc45d3
[ "MIT" ]
null
null
null
import torch import torch.nn as nn from timm.loss import LabelSmoothingCrossEntropy from pytorch_metric_learning import losses class create_class_loss(nn.Module): """ 常规分类 - 损失函数入口 """ def __init__(self, name): super(create_class_loss, self).__init__() assert name in ["cross_entropy",...
27.46875
80
0.609215
1,699
0.927402
0
0
0
0
0
0
406
0.221616
dda150ca1f3fdf6e22fc599876192f67eb4fbf8e
1,195
py
Python
tests/main.py
caspervg/geontology
e5660629f57747d05cfe6e15721bca23039a672d
[ "MIT" ]
1
2015-12-25T10:46:27.000Z
2015-12-25T10:46:27.000Z
tests/main.py
caspervg/geontology
e5660629f57747d05cfe6e15721bca23039a672d
[ "MIT" ]
null
null
null
tests/main.py
caspervg/geontology
e5660629f57747d05cfe6e15721bca23039a672d
[ "MIT" ]
null
null
null
from rdflib import URIRef from rdflib.namespace import DC, RDF, OWL, RDFS from geontology import GeoOntology ont = GeoOntology("geo_ontology.ttl", frmt='n3') # print ont.serialize() graph = ont.graph print "InfoColumns" for s, p, o in graph.triples( (None, RDFS.subClassOf, URIRef('http://move.ugent.be/geod...
29.146341
93
0.551464
0
0
0
0
0
0
0
0
336
0.281172
dda2bd0af7d3de24450c99ea2968e3067f121da2
1,397
py
Python
VGG_GRU/TrainTestlist/Emotiw/getTraintest_Emotiw.py
XiaoYee/emotion_classification
6122e1b575bce5235169f155295b549a8f721ca1
[ "MIT" ]
74
2018-06-29T06:46:33.000Z
2022-02-26T19:15:55.000Z
VGG_GRU/TrainTestlist/Emotiw/getTraintest_Emotiw.py
JIangjiang1108/emotion_classification
6122e1b575bce5235169f155295b549a8f721ca1
[ "MIT" ]
6
2018-07-02T09:29:05.000Z
2020-01-30T14:21:26.000Z
VGG_GRU/TrainTestlist/Emotiw/getTraintest_Emotiw.py
JIangjiang1108/emotion_classification
6122e1b575bce5235169f155295b549a8f721ca1
[ "MIT" ]
23
2018-06-29T12:52:40.000Z
2020-12-02T12:55:13.000Z
import os import os.path as osp import argparse import random parser = argparse.ArgumentParser(description='Emotiw dataset list producer') args = parser.parse_args() train = "/home/quxiaoye/disk/FR/Emotiw2018/data/Train_AFEW_all/Emotiw-faces" test = "/home/quxiaoye/disk/FR/Emotiw2018/data/Val_AFEW/Emotiw-faces" tr...
29.723404
76
0.7602
0
0
0
0
0
0
0
0
260
0.186113
06b3cc12c35c6a81cb3cf69f89310f5caed75723
141
py
Python
config_default.py
wecassidy/pishow
310f935688e0b3ceeb8fe11bd0fda902c041dd45
[ "MIT" ]
null
null
null
config_default.py
wecassidy/pishow
310f935688e0b3ceeb8fe11bd0fda902c041dd45
[ "MIT" ]
null
null
null
config_default.py
wecassidy/pishow
310f935688e0b3ceeb8fe11bd0fda902c041dd45
[ "MIT" ]
null
null
null
IMG_DIR = "/path/to/pictures" IMG_POLL_RATE = 1 # minute DWELL_TIME = 5 # seconds FADE_TIME = 1 # seconds REFRESH_RATE = 10 # milliseconds
17.625
32
0.723404
0
0
0
0
0
0
0
0
59
0.41844
06b3ddf241a1d83947506562980f958105dbb002
5,050
py
Python
src/stdlib.py
tweakoz/zed64
c0231444418999191182d53d9319bf7978422bfb
[ "CC-BY-3.0" ]
4
2015-06-04T01:14:43.000Z
2018-06-16T05:45:57.000Z
src/stdlib.py
tweakoz/zed64
c0231444418999191182d53d9319bf7978422bfb
[ "CC-BY-3.0" ]
null
null
null
src/stdlib.py
tweakoz/zed64
c0231444418999191182d53d9319bf7978422bfb
[ "CC-BY-3.0" ]
null
null
null
####################################################################### ## ## Zed64 MetroComputer ## ## Unless a module otherwise marked, ## Copyright 2014, Michael T. Mayers (michael@tweakoz.com ## Provided under the Creative Commons Attribution License 3.0 ## Please see https://creativecommons.org/licenses/by/3.0/us/...
24.278846
86
0.50198
1,886
0.373465
0
0
583
0.115446
0
0
1,189
0.235446
06bb33b3d53b354d7a98d017485acac1da8698a5
1,127
py
Python
py/1081. Smallest Subsequence of Distinct Characters.py
longwangjhu/LeetCode
a5c33e8d67e67aedcd439953d96ac7f443e2817b
[ "MIT" ]
3
2021-08-07T07:01:34.000Z
2021-08-07T07:03:02.000Z
py/1081. Smallest Subsequence of Distinct Characters.py
longwangjhu/LeetCode
a5c33e8d67e67aedcd439953d96ac7f443e2817b
[ "MIT" ]
null
null
null
py/1081. Smallest Subsequence of Distinct Characters.py
longwangjhu/LeetCode
a5c33e8d67e67aedcd439953d96ac7f443e2817b
[ "MIT" ]
null
null
null
# https://leetcode.com/problems/smallest-subsequence-of-distinct-characters/ # Return the lexicographically smallest subsequence of s that contains all the # distinct characters of s exactly once. # Note: This question is the same as 316: https://leetcode.com/problems/remove- # duplicate-letters/ ###################...
38.862069
108
0.585626
598
0.530612
0
0
0
0
0
0
644
0.571429
06bbd57d69031c72132de965a30424f3da29237c
2,207
py
Python
ebs-snapshot-manager.py
phanirajendra/aws-ebs-snapshots-lambda
0464ec54de7e812163e33db73d1cb9d46c35c029
[ "Apache-2.0" ]
null
null
null
ebs-snapshot-manager.py
phanirajendra/aws-ebs-snapshots-lambda
0464ec54de7e812163e33db73d1cb9d46c35c029
[ "Apache-2.0" ]
null
null
null
ebs-snapshot-manager.py
phanirajendra/aws-ebs-snapshots-lambda
0464ec54de7e812163e33db73d1cb9d46c35c029
[ "Apache-2.0" ]
1
2020-05-17T14:45:51.000Z
2020-05-17T14:45:51.000Z
import boto3 import re import datetime import time ec = boto3.client('ec2') iam = boto3.client('iam') """ This function looks at *all* snapshots that have the tags "Type:Automated" and "DeleteOn" containing the current day formatted as YYYY-MM-DD. The function will delete the if the todays date is > than the "DeleteO...
34.484375
100
0.593113
0
0
0
0
0
0
0
0
939
0.425464
06bd33902db8a6c06128727e29c0eae037cf9894
378
py
Python
Cartwheel/lib/Python26/Lib/site-packages/OpenGL/GL/NV/fragment_program.py
MontyThibault/centre-of-mass-awareness
58778f148e65749e1dfc443043e9fc054ca3ff4d
[ "MIT" ]
null
null
null
Cartwheel/lib/Python26/Lib/site-packages/OpenGL/GL/NV/fragment_program.py
MontyThibault/centre-of-mass-awareness
58778f148e65749e1dfc443043e9fc054ca3ff4d
[ "MIT" ]
null
null
null
Cartwheel/lib/Python26/Lib/site-packages/OpenGL/GL/NV/fragment_program.py
MontyThibault/centre-of-mass-awareness
58778f148e65749e1dfc443043e9fc054ca3ff4d
[ "MIT" ]
null
null
null
'''OpenGL extension NV.fragment_program This module customises the behaviour of the OpenGL.raw.GL.NV.fragment_program to provide a more Python-friendly API ''' from OpenGL import platform, constants, constant, arrays from OpenGL import extensions, wrapper from OpenGL.GL import glget import ctypes from OpenGL.raw.GL....
31.5
56
0.812169
0
0
0
0
0
0
0
0
191
0.505291
06be7d0ae668828822753247461cfec9b2e4f3d3
675
py
Python
kpm/commands/push.py
ericchiang/kpm
3653b1dba8359f086a6a21d3a5003e80a46083a7
[ "Apache-2.0" ]
121
2016-08-05T17:54:27.000Z
2022-02-21T14:21:59.000Z
kpm/commands/push.py
ericchiang/kpm
3653b1dba8359f086a6a21d3a5003e80a46083a7
[ "Apache-2.0" ]
82
2016-08-07T01:42:41.000Z
2017-05-05T17:35:45.000Z
kpm/commands/push.py
ericchiang/kpm
3653b1dba8359f086a6a21d3a5003e80a46083a7
[ "Apache-2.0" ]
30
2016-08-15T13:12:10.000Z
2022-02-21T14:22:00.000Z
from appr.commands.push import PushCmd as ApprPushCmd from kpm.manifest_jsonnet import ManifestJsonnet class PushCmd(ApprPushCmd): default_media_type = 'kpm' def _kpm(self): self.filter_files = True self.manifest = ManifestJsonnet() ns, name = self.manifest.package['name'].split("/")...
32.142857
66
0.638519
568
0.841481
0
0
0
0
0
0
39
0.057778
06be9a64516dc7d92276fa93579a7f01f96fc979
360
py
Python
QASMToQuEST/errors.py
oerc0122/QASMParser
701b6f25f498ea67670f2d85ae0f2e6920aea267
[ "MIT" ]
5
2019-05-10T08:17:57.000Z
2021-12-19T05:06:18.000Z
QASMToQuEST/errors.py
oerc0122/QASMParser
701b6f25f498ea67670f2d85ae0f2e6920aea267
[ "MIT" ]
14
2019-04-11T11:28:08.000Z
2020-02-13T15:18:56.000Z
QASMToQuEST/errors.py
oerc0122/QASMParser
701b6f25f498ea67670f2d85ae0f2e6920aea267
[ "MIT" ]
2
2019-05-10T08:17:23.000Z
2021-12-18T16:37:02.000Z
""" Define the errors which may occur """ langMismatchWarning = "Classical language {} does not match output language {}" langNotDefWarning = "Language {0} translation not found, check QASMToQuEST/langs/{0}.py exists" noLangSpecWarning = "No language specified for screen print" noSpecWarning = "Neither language nor out...
45
95
0.786111
0
0
0
0
0
0
0
0
277
0.769444
06bfd7cd414a9434b1f295b51c26d7407c29f08d
383
py
Python
problem_29/distinct_powers.py
plilja/project-euler
646d1989cf15e903ef7e3c6e487284847d522ec9
[ "Apache-2.0" ]
null
null
null
problem_29/distinct_powers.py
plilja/project-euler
646d1989cf15e903ef7e3c6e487284847d522ec9
[ "Apache-2.0" ]
null
null
null
problem_29/distinct_powers.py
plilja/project-euler
646d1989cf15e903ef7e3c6e487284847d522ec9
[ "Apache-2.0" ]
null
null
null
from common.matrix import Matrix def distinct_powers(n): m = Matrix(n + 2, n + 2) for i in range(2, n + 1): m[i][2] = i ** 2 for j in range(3, n + 1): m[i][j] = m[i][j - 1] * i distinct_values = set() for i in range(2, n + 1): for j in range(2, n + 1): ...
21.277778
40
0.488251
0
0
0
0
0
0
0
0
0
0
06c21871e9ad89697d51562c488828bc64f7390f
1,436
py
Python
1-python/python/transpose.py
Domin-Imperial/Domin-Respository
2e531aabc113ed3511f349107695847b5c4e4320
[ "MIT" ]
null
null
null
1-python/python/transpose.py
Domin-Imperial/Domin-Respository
2e531aabc113ed3511f349107695847b5c4e4320
[ "MIT" ]
null
null
null
1-python/python/transpose.py
Domin-Imperial/Domin-Respository
2e531aabc113ed3511f349107695847b5c4e4320
[ "MIT" ]
1
2021-05-24T20:09:38.000Z
2021-05-24T20:09:38.000Z
# exercism exercise "transpose" def transpose(lines: str) -> str: input_list = lines.split('\n') # or splitlines input_height = len(input_list) input_width = get_input_width(input_list) output_list = [] for colnum in range(input_width): output = '' for rownum in range(input_height)...
27.615385
67
0.612117
0
0
0
0
0
0
0
0
598
0.416435
06c29fb490c1f0aa4c9251b922a903b4e7ce1750
548
py
Python
tests/create_file.py
stompsjo/RadClass
3bce664fbc1ea48c067e035adb18cc064db5df4b
[ "BSD-3-Clause" ]
null
null
null
tests/create_file.py
stompsjo/RadClass
3bce664fbc1ea48c067e035adb18cc064db5df4b
[ "BSD-3-Clause" ]
2
2021-05-11T15:11:17.000Z
2021-07-02T17:42:35.000Z
tests/create_file.py
stompsjo/RadClass
3bce664fbc1ea48c067e035adb18cc064db5df4b
[ "BSD-3-Clause" ]
null
null
null
import h5py def create_file(filename, datapath, labels, live, timestamps, spectra): # Creating sample dataset f = h5py.File(filename, "w") # data structure for MUSE files dset1 = f.create_dataset(datapath + labels['live'], (1000,)) dset2 = f.create_dataset(datapath + labels['timestamps'], (100...
30.444444
71
0.642336
0
0
0
0
0
0
0
0
139
0.25365
06c2aad42518b04959fd06448a4c2d1ef11c34fe
4,318
py
Python
core/models.py
mcflydesigner/innorussian
70bec97ad349f340bd66cd8234d94f8829540397
[ "MIT" ]
1
2021-04-12T18:54:37.000Z
2021-04-12T18:54:37.000Z
core/models.py
mcflydesigner/InnoRussian
70bec97ad349f340bd66cd8234d94f8829540397
[ "MIT" ]
null
null
null
core/models.py
mcflydesigner/InnoRussian
70bec97ad349f340bd66cd8234d94f8829540397
[ "MIT" ]
null
null
null
from django.db import models from django.utils.timezone import now from django.core.validators import FileExtensionValidator from django.contrib.auth import get_user_model from django.contrib.postgres.fields import ArrayField from django.db.models import (Func, Value, CharField, IntegerField) from .shortcuts import up...
35.393443
101
0.652154
3,795
0.878879
0
0
0
0
0
0
1,557
0.360584
06c565b07d3d63057b60da7cadb5483464d2b8ef
250
py
Python
tests/tushare_to_MongoDB.py
sibuzu/OnePy
464fca1c68a10f90ad128da3bfb03f05d2fc24bc
[ "MIT" ]
null
null
null
tests/tushare_to_MongoDB.py
sibuzu/OnePy
464fca1c68a10f90ad128da3bfb03f05d2fc24bc
[ "MIT" ]
null
null
null
tests/tushare_to_MongoDB.py
sibuzu/OnePy
464fca1c68a10f90ad128da3bfb03f05d2fc24bc
[ "MIT" ]
null
null
null
import OnePy as op instrument = "000001" ktype = "D" start = "2017-01-01" end = None test = op.Tushare_to_MongoDB(database=instrument, collection=ktype) test.data_to_db(code=instrument, start=start, end=end, ktype=ktype, autype="qfq", index=False)
25
94
0.748
0
0
0
0
0
0
0
0
28
0.112
06c71c090d4fa330c0d0b447373205ef201db5b3
1,836
py
Python
costar_models/python/costar_models/datasets/h5f_generator.py
cpaxton/costar_plan
be5c12f9d0e9d7078e6a5c283d3be059e7f3d040
[ "Apache-2.0" ]
66
2018-10-31T04:58:53.000Z
2022-03-17T02:32:25.000Z
costar_models/python/costar_models/datasets/h5f_generator.py
cpaxton/costar_plan
be5c12f9d0e9d7078e6a5c283d3be059e7f3d040
[ "Apache-2.0" ]
8
2018-10-23T21:19:25.000Z
2018-12-03T02:08:41.000Z
costar_models/python/costar_models/datasets/h5f_generator.py
cpaxton/costar_plan
be5c12f9d0e9d7078e6a5c283d3be059e7f3d040
[ "Apache-2.0" ]
25
2018-10-19T00:54:17.000Z
2021-10-10T08:28:15.000Z
from __future__ import print_function import h5py as h5f import numpy as np import six import os from .npy_generator import NpzGeneratorDataset from .image import * class H5fGeneratorDataset(NpzGeneratorDataset): ''' Placeholder class for use with the ctp training tool. This one generates samples from an...
30.098361
86
0.582789
1,667
0.907952
0
0
0
0
0
0
606
0.330065
06c7a3448e8983e9a265c812e501b174dd35b66d
5,821
py
Python
SegmentationAlgorithms/CBSMoT.py
JRose6/TrajLib
2a5749bf6e9517835801926d6a5e92564ef2c7f0
[ "Apache-2.0" ]
null
null
null
SegmentationAlgorithms/CBSMoT.py
JRose6/TrajLib
2a5749bf6e9517835801926d6a5e92564ef2c7f0
[ "Apache-2.0" ]
null
null
null
SegmentationAlgorithms/CBSMoT.py
JRose6/TrajLib
2a5749bf6e9517835801926d6a5e92564ef2c7f0
[ "Apache-2.0" ]
null
null
null
import Distances as d import pandas as pd import numpy as np class CBSmot: nano_to_seconds = 1000000000 def count_neighbors(self, traj, position, max_dist): neighbors = 0 yet = True j = position + 1 while j < len(traj.index) and yet: if d.Distances.calculate_two_poi...
35.932099
104
0.489263
5,758
0.989177
0
0
419
0.071981
0
0
130
0.022333
06c9a2b8530162b36b57399f64b942d4d2384eb7
164
py
Python
apps/presupuesto/admin.py
edilio/cubanoshaciamiami.com
541a22998b7c7ad3acda784c5657bfdf79cc7f07
[ "MIT" ]
null
null
null
apps/presupuesto/admin.py
edilio/cubanoshaciamiami.com
541a22998b7c7ad3acda784c5657bfdf79cc7f07
[ "MIT" ]
null
null
null
apps/presupuesto/admin.py
edilio/cubanoshaciamiami.com
541a22998b7c7ad3acda784c5657bfdf79cc7f07
[ "MIT" ]
null
null
null
from django.contrib import admin from .models import TipoDeGasto, PresupuestoDeGasto admin.site.register(TipoDeGasto) admin.site.register(PresupuestoDeGasto)
27.333333
52
0.829268
0
0
0
0
0
0
0
0
0
0
06c9d2978cf880b3371f69c40666eeeea090512c
13,838
py
Python
Support/validate.py
sgarbesi/javascript-eslint.tmbundle
b117fe0133582676113a96fc9804795c033d0b78
[ "BSD-3-Clause" ]
1
2015-05-01T14:24:39.000Z
2015-05-01T14:24:39.000Z
Support/validate.py
sgarbesi/javascript-eslint.tmbundle
b117fe0133582676113a96fc9804795c033d0b78
[ "BSD-3-Clause" ]
null
null
null
Support/validate.py
sgarbesi/javascript-eslint.tmbundle
b117fe0133582676113a96fc9804795c033d0b78
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python # encoding: utf-8 """ Validate a JavaScript file using eslint. Author: Nate Silva Copyright 2014 Nate Silva License: MIT """ from __future__ import print_function import sys import os import re import time import json import subprocess import tempfile import hashlib import shutil def find_up_...
33.833741
98
0.568001
0
0
0
0
0
0
0
0
6,160
0.443612
06cdfe64d4ce6044067a25d0bf7f0ef2fa35cf39
240
py
Python
Home_Work_2_B_Naychuk_Anastasiya/Task2.py
NaychukAnastasiya/goiteens-python3-naychuk
a79d0af238a15f58a822bb5d8e4d48227d4a7bc1
[ "MIT" ]
null
null
null
Home_Work_2_B_Naychuk_Anastasiya/Task2.py
NaychukAnastasiya/goiteens-python3-naychuk
a79d0af238a15f58a822bb5d8e4d48227d4a7bc1
[ "MIT" ]
null
null
null
Home_Work_2_B_Naychuk_Anastasiya/Task2.py
NaychukAnastasiya/goiteens-python3-naychuk
a79d0af238a15f58a822bb5d8e4d48227d4a7bc1
[ "MIT" ]
null
null
null
# y = f(X) # y = 2*x -10 # x>0 # y = 0# x=0 # y = 2 * abs(x) -1 # x<0 print("Введіть число") x = float(input()) y = 0 if x > 0: y = 2*x -10 elif x == 0: y = 0 else: #x<0 y = 2 * abs(x) -1 print ("y: ",y)
13.333333
26
0.375
0
0
0
0
0
0
0
0
107
0.424603
06d128fc6f207aa019def30c73ff71c2d5f4ad72
8,745
py
Python
imagenet_pytorch/utils.py
lishuliang/Emotion-Recognition
a8aea1b71b2508e6157410089b20ab463fe901f5
[ "MIT" ]
1
2019-03-16T08:11:53.000Z
2019-03-16T08:11:53.000Z
imagenet_pytorch/utils.py
lishuliang/Emotion-Recognition
a8aea1b71b2508e6157410089b20ab463fe901f5
[ "MIT" ]
null
null
null
imagenet_pytorch/utils.py
lishuliang/Emotion-Recognition
a8aea1b71b2508e6157410089b20ab463fe901f5
[ "MIT" ]
null
null
null
import torch import torch.nn as nn import torch.nn.parallel import torch.backends.cudnn as cudnn import torch.optim import torch.utils.data import torch.nn.functional as F from torch.nn import init class attention(nn.Module): def __init__(self, input_channels, map_size): super(attention, self).__init__() ...
43.507463
145
0.5992
8,532
0.975643
0
0
0
0
0
0
707
0.080846
06d1d332e24aee96ce48f604359996ef77a12eea
1,349
py
Python
setup.py
jopo666/HistoPrep
1b74c346b38c7ca44f92269246571f5f850836af
[ "MIT" ]
11
2021-04-21T10:37:22.000Z
2021-12-19T22:32:59.000Z
setup.py
jopo666/HistoPrep
1b74c346b38c7ca44f92269246571f5f850836af
[ "MIT" ]
1
2021-02-24T09:15:13.000Z
2021-04-19T06:38:58.000Z
setup.py
jopo666/HistoPrep
1b74c346b38c7ca44f92269246571f5f850836af
[ "MIT" ]
1
2021-09-16T05:00:21.000Z
2021-09-16T05:00:21.000Z
import setuptools exec(open('histoprep/_version.py').read()) with open("README.md", "r", encoding="utf-8") as fh: long_description = fh.read() setuptools.setup( name="histoprep", version=__version__, author="jopo666", scripts=['HistoPrep'], author_email="jopo@birdlover.com", description="...
32.119048
75
0.614529
0
0
0
0
0
0
0
0
723
0.535953
06d23d367076f35c30b175f7a472c7335658ae54
389
py
Python
setup.py
cprogrammer1994/python-depth-sort
5399d6d0791eb897d0cac16d2e38b26041478a82
[ "MIT" ]
null
null
null
setup.py
cprogrammer1994/python-depth-sort
5399d6d0791eb897d0cac16d2e38b26041478a82
[ "MIT" ]
null
null
null
setup.py
cprogrammer1994/python-depth-sort
5399d6d0791eb897d0cac16d2e38b26041478a82
[ "MIT" ]
null
null
null
import platform from setuptools import Extension, setup target = platform.system().lower() extra_compile_args = [] if target.startswith('linux'): extra_compile_args.append('-std=c++11') ext = Extension( name='depth_sort', sources=['depth_sort.cpp'], extra_compile_args=extra_compile_args, ) setup( ...
16.913043
43
0.691517
0
0
0
0
0
0
0
0
66
0.169666
06d28dfe07994e25ac5013d571490aa1301605ee
15,260
py
Python
train.py
Kiwi-PUJ/DataTraining
706642996e884b47a0aa7dfb19da33a7234a311e
[ "CC0-1.0" ]
3
2021-06-04T00:07:54.000Z
2021-06-09T01:14:07.000Z
train.py
Kiwi-PUJ/DataTraining
706642996e884b47a0aa7dfb19da33a7234a311e
[ "CC0-1.0" ]
null
null
null
train.py
Kiwi-PUJ/DataTraining
706642996e884b47a0aa7dfb19da33a7234a311e
[ "CC0-1.0" ]
null
null
null
## @package Training_app # Training code developed with Tensorflow Keras. Content: Unet, Unet++ and FCN # # @version 1 # # Pontificia Universidad Javeriana # # Electronic Enginnering # # Developed by: # - Andrea Juliana Ruiz Gomez # Mail: <andrea_ruiz@javeriana.edu.co> # GitHub: andrearuizg # - Pedro E...
29.921569
80
0.602687
0
0
0
0
0
0
0
0
4,142
0.271429
06d2f75b09d1b2bbd785ce87a1527c0fb7ae9040
12,133
py
Python
src_RealData/FCN_Object.py
XYZsake/DRFNS
73fc5683db5e9f860846e22c8c0daf73b7103082
[ "MIT" ]
42
2018-10-07T08:19:01.000Z
2022-02-08T17:41:24.000Z
src_RealData/FCN_Object.py
XYZsake/DRFNS
73fc5683db5e9f860846e22c8c0daf73b7103082
[ "MIT" ]
11
2018-12-22T00:15:46.000Z
2021-12-03T10:29:32.000Z
src_RealData/FCN_Object.py
XYZsake/DRFNS
73fc5683db5e9f860846e22c8c0daf73b7103082
[ "MIT" ]
14
2018-08-26T06:47:06.000Z
2021-07-24T11:52:58.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- import tensorflow as tf import copy from tf_image_segmentation.models.fcn_8s import FCN_8s from tf_image_segmentation.utils.tf_records import read_tfrecord_and_decode_into_image_annotation_pair_tensors from tf_image_segmentation.utils.training import get_valid_logits_and_l...
45.784906
161
0.570675
11,204
0.923432
0
0
0
0
0
0
1,216
0.100223
06d355973fd78ec8f3b614057e835f98f36682ef
379
py
Python
qt__pyqt__pyside__pyqode/qt_ini.py
DazEB2/SimplePyScripts
1dde0a42ba93fe89609855d6db8af1c63b1ab7cc
[ "CC-BY-4.0" ]
117
2015-12-18T07:18:27.000Z
2022-03-28T00:25:54.000Z
qt__pyqt__pyside__pyqode/qt_ini.py
DazEB2/SimplePyScripts
1dde0a42ba93fe89609855d6db8af1c63b1ab7cc
[ "CC-BY-4.0" ]
8
2018-10-03T09:38:46.000Z
2021-12-13T19:51:09.000Z
qt__pyqt__pyside__pyqode/qt_ini.py
DazEB2/SimplePyScripts
1dde0a42ba93fe89609855d6db8af1c63b1ab7cc
[ "CC-BY-4.0" ]
28
2016-08-02T17:43:47.000Z
2022-03-21T08:31:12.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- __author__ = 'ipetrash' try: from PyQt4.QtCore import QSettings except: from PyQt5.QtCore import QSettings if __name__ == '__main__': config = QSettings('config.ini', QSettings.IniFormat) counter = int(config.value('counter', 0)) config.setValue('...
18.95
57
0.664908
0
0
0
0
0
0
0
0
106
0.279683
06d39356c17a9b2e38d63f8d9aaf9f0140911fdf
46
py
Python
wafw00f/__init__.py
nofunofunofunofun/wafw00f
a1c3f3a045077d893cd9ed970f5d687b590abfa5
[ "BSD-3-Clause" ]
1
2022-03-22T09:15:04.000Z
2022-03-22T09:15:04.000Z
wafw00f/__init__.py
nofunofunofunofun/wafw00f
a1c3f3a045077d893cd9ed970f5d687b590abfa5
[ "BSD-3-Clause" ]
null
null
null
wafw00f/__init__.py
nofunofunofunofun/wafw00f
a1c3f3a045077d893cd9ed970f5d687b590abfa5
[ "BSD-3-Clause" ]
1
2021-01-11T17:26:14.000Z
2021-01-11T17:26:14.000Z
#!/usr/bin/env python __version__ = '0.9.6'
9.2
21
0.630435
0
0
0
0
0
0
0
0
28
0.608696
06d4487239efe1a625efc060f8606eba1b8fb684
3,410
py
Python
tests/api_tests.py
muhozi/WeConnect
46825d6ae27a7addbe8f7f2e298f5ee07cd9cf5f
[ "MIT" ]
3
2018-04-07T07:39:19.000Z
2018-04-13T14:15:26.000Z
tests/api_tests.py
muhozi/WeConnect
46825d6ae27a7addbe8f7f2e298f5ee07cd9cf5f
[ "MIT" ]
8
2018-03-01T21:11:05.000Z
2022-03-21T22:16:43.000Z
tests/api_tests.py
muhozi/WeConnect
46825d6ae27a7addbe8f7f2e298f5ee07cd9cf5f
[ "MIT" ]
3
2018-04-24T03:34:44.000Z
2018-07-19T09:53:08.000Z
""" Main test """ import unittest import uuid from api import APP from flask import json from api.models.user import User from api.models.business import Business from api.helpers import get_token class MainTests(unittest.TestCase): """ Main test """ url_prefix = '/api/v1/' def setUp(self...
35.520833
79
0.550733
3,206
0.940176
0
0
0
0
0
0
1,177
0.345161
06d6a4324acde5c358d0bd6522e052a2ede943db
423
py
Python
cookbook/c05/p03_print_sepend.py
itpubs/python3-cookbook
140f5e4cc0416b9674edca7f4c901b1f58fc1415
[ "Apache-2.0" ]
3
2018-09-19T06:44:13.000Z
2019-03-24T10:07:07.000Z
cookbook/c05/p03_print_sepend.py
itpubs/python3-cookbook
140f5e4cc0416b9674edca7f4c901b1f58fc1415
[ "Apache-2.0" ]
2
2020-09-19T17:10:23.000Z
2020-10-17T16:43:52.000Z
cookbook/c05/p03_print_sepend.py
itpubs/python3-cookbook
140f5e4cc0416b9674edca7f4c901b1f58fc1415
[ "Apache-2.0" ]
1
2020-12-22T06:33:18.000Z
2020-12-22T06:33:18.000Z
#!/usr/bin/env python # -*- encoding: utf-8 -*- """ Topic: print分隔符和结尾符 Desc : """ def print_sepend(): print('ACME', 50, 91.5) print('ACME', 50, 91.5, sep=',') print('ACME', 50, 91.5, sep=',', end='!!\n') for i in range(5): print(i) for i in range(5): print(i, end=' ') print() ...
17.625
48
0.501182
0
0
0
0
0
0
0
0
147
0.336384
06da3baaeb27b37984af143aca6a52ab058a5588
122
py
Python
src/config/config_loader.py
roybenyosef/loc-to-spot
1db54a8481317f5cd2f746974dcdda2a632d02ec
[ "MIT" ]
null
null
null
src/config/config_loader.py
roybenyosef/loc-to-spot
1db54a8481317f5cd2f746974dcdda2a632d02ec
[ "MIT" ]
null
null
null
src/config/config_loader.py
roybenyosef/loc-to-spot
1db54a8481317f5cd2f746974dcdda2a632d02ec
[ "MIT" ]
null
null
null
import yaml def read_config(): file_stream = open("config/config.yaml", "r") return yaml.safe_load(file_stream)
17.428571
49
0.704918
0
0
0
0
0
0
0
0
23
0.188525
06da67599586f6f3ad731d357524246723f211dc
331
py
Python
python/demo-django/code/character/models.py
denisroldan/talentum-2015-examples
4980f49dca56a55d26722f4f6d1fdd88e06f38dd
[ "MIT" ]
null
null
null
python/demo-django/code/character/models.py
denisroldan/talentum-2015-examples
4980f49dca56a55d26722f4f6d1fdd88e06f38dd
[ "MIT" ]
null
null
null
python/demo-django/code/character/models.py
denisroldan/talentum-2015-examples
4980f49dca56a55d26722f4f6d1fdd88e06f38dd
[ "MIT" ]
null
null
null
from django.db import models from game.models import Game class Character(models.Model): name = models.CharField(max_length=250) game = models.ManyToManyField(Game, related_name='characters') def __unicode__(self): return "{0}".format(self.name) def __str__(self): return "{0}".format...
25.461538
66
0.694864
271
0.818731
0
0
0
0
0
0
22
0.066465
06dacdda970f273fddcf69cadb01b1f2dd499e8c
296
py
Python
sim_test_model.py
feiyanke/simpy
bde9d09e47596e0bfe66dc7001f556bafd03acc5
[ "MIT" ]
1
2019-01-28T09:13:58.000Z
2019-01-28T09:13:58.000Z
sim_test_model.py
feiyanke/simpy
bde9d09e47596e0bfe66dc7001f556bafd03acc5
[ "MIT" ]
null
null
null
sim_test_model.py
feiyanke/simpy
bde9d09e47596e0bfe66dc7001f556bafd03acc5
[ "MIT" ]
2
2019-01-28T09:13:59.000Z
2020-12-13T09:48:20.000Z
import math import matplotlib.pyplot as plt from simpy import model ax1 = plt.subplot(121) ax2 = plt.subplot(122) model_sin = model.TimedFunctionModel(math.sin) model_cos = model.TimedFunctionModel(math.cos) scope = model.ScopeModel(ax1, ax2) def run(): scope(model_sin(), model_cos())
17.411765
46
0.75
0
0
0
0
0
0
0
0
0
0
06db5fed30a40e13ffe36a7460de36bf7c61b325
655
py
Python
monthlysal.py
aja512/Python-Lab
8f9c57d6d7f835e31a595223cdddf9c52ebe1cc9
[ "Apache-2.0" ]
null
null
null
monthlysal.py
aja512/Python-Lab
8f9c57d6d7f835e31a595223cdddf9c52ebe1cc9
[ "Apache-2.0" ]
null
null
null
monthlysal.py
aja512/Python-Lab
8f9c57d6d7f835e31a595223cdddf9c52ebe1cc9
[ "Apache-2.0" ]
null
null
null
bs=input("Enter basic salary:") days=input("Enter no. of working days:") ovrti=input("Enter no. of overtime working hrs:") deduct=0 if days<6: deduct=3500 salary=calci(bs,days,ovrti,deduct) elif days>=6 and days<=12: deduct=1000 salary= calci(bs,days,ovrti,deduct) elif days>=13 and days<=18: deduct=800 ...
22.586207
49
0.690076
0
0
0
0
0
0
0
0
121
0.184733
06db8ba3ca98cc15e56e2db049c572bc5f7c97a3
2,760
py
Python
Day_10_classes_and_objects/day10_uzd1.py
ValRCS/Python_TietoEvry_Sep2021
e11dac38deb17ba695ce8ad9dab9cf78b4adb99d
[ "MIT" ]
null
null
null
Day_10_classes_and_objects/day10_uzd1.py
ValRCS/Python_TietoEvry_Sep2021
e11dac38deb17ba695ce8ad9dab9cf78b4adb99d
[ "MIT" ]
null
null
null
Day_10_classes_and_objects/day10_uzd1.py
ValRCS/Python_TietoEvry_Sep2021
e11dac38deb17ba695ce8ad9dab9cf78b4adb99d
[ "MIT" ]
null
null
null
# class Song: # Song is name of Class, start with Capital letter # def __init__(self, title="", author="", lyrics=tuple()): # constructor method called upon creation of object # self.title = title # self.author = author # self.lyrics = lyrics # # print(f"New Song made by Author: {s...
34.5
115
0.595652
1,601
0.577561
0
0
488
0.176046
0
0
1,284
0.463203
06dc17868ef7177e219fa324d4ee2030cbe721d0
51
py
Python
appengine/src/greenday_core/settings/__init__.py
meedan/montage
4da0116931edc9af91f226876330645837dc9bcc
[ "Apache-2.0" ]
6
2018-07-31T16:48:07.000Z
2020-02-01T03:17:51.000Z
appengine/src/greenday_core/settings/__init__.py
meedan/montage
4da0116931edc9af91f226876330645837dc9bcc
[ "Apache-2.0" ]
41
2018-08-07T16:43:07.000Z
2020-06-05T18:54:50.000Z
appengine/src/greenday_core/settings/__init__.py
meedan/montage
4da0116931edc9af91f226876330645837dc9bcc
[ "Apache-2.0" ]
1
2018-08-07T16:40:18.000Z
2018-08-07T16:40:18.000Z
""" Modules to configure Django's settings """
12.75
42
0.647059
0
0
0
0
0
0
0
0
50
0.980392
06dc1c17dd56d7e1a1011a34a1e1d9b273c1982c
1,956
py
Python
rurina2/widgets/text.py
TeaCondemns/rurina
43725ebea5872953125271a9abb300a4e3a80a64
[ "MIT" ]
null
null
null
rurina2/widgets/text.py
TeaCondemns/rurina
43725ebea5872953125271a9abb300a4e3a80a64
[ "MIT" ]
null
null
null
rurina2/widgets/text.py
TeaCondemns/rurina
43725ebea5872953125271a9abb300a4e3a80a64
[ "MIT" ]
null
null
null
from constants import STYLE_NORMAL, STYLE_BOLD, STYLE_ITALIC from prefabs.text import write_autoline from widgets.widget import WidgetByRect from base_node import get_surface from prefabs.surface import blit from shape import Rect import pygame class Text(WidgetByRect): def __init__( self, ...
25.402597
90
0.541922
1,681
0.859407
0
0
499
0.255112
0
0
15
0.007669
06dcdfc975ea640979bb4f316bbb031845b68fa5
5,350
py
Python
Chapter05/B12322_05_code upload/topic_categorization.py
PacktPublishing/Python-Machine-Learning-By-Example-Second-Edition
830ad0124dc72c3a24929ff1b67081a66894f1f9
[ "MIT" ]
31
2019-05-25T11:28:23.000Z
2022-02-09T15:19:20.000Z
Chapter05/B12322_05_code upload/topic_categorization.py
PacktPublishing/Python-Machine-Learning-By-Example-Second-Edition
830ad0124dc72c3a24929ff1b67081a66894f1f9
[ "MIT" ]
null
null
null
Chapter05/B12322_05_code upload/topic_categorization.py
PacktPublishing/Python-Machine-Learning-By-Example-Second-Edition
830ad0124dc72c3a24929ff1b67081a66894f1f9
[ "MIT" ]
22
2019-02-27T20:11:39.000Z
2022-03-07T21:46:38.000Z
''' Source codes for Python Machine Learning By Example 2nd Edition (Packt Publishing) Chapter 5: Classifying Newsgroup Topic with Support Vector Machine Author: Yuxi (Hayden) Liu ''' from sklearn.feature_extraction.text import TfidfVectorizer from sklearn.datasets import fetch_20newsgroups from nltk.corpus import nam...
31.470588
108
0.774393
0
0
0
0
0
0
0
0
900
0.168224
06de4f84c6d45b4b9c062aad81f802376fdf7b81
9,076
py
Python
lib/enthought/traits/ui/key_bindings.py
mattfoster/matplotlib
0b47697b19b77226c633ec6a3d74a2199a153315
[ "PSF-2.0", "BSD-3-Clause" ]
1
2016-05-08T18:33:12.000Z
2016-05-08T18:33:12.000Z
lib/enthought/traits/ui/key_bindings.py
mattfoster/matplotlib
0b47697b19b77226c633ec6a3d74a2199a153315
[ "PSF-2.0", "BSD-3-Clause" ]
null
null
null
lib/enthought/traits/ui/key_bindings.py
mattfoster/matplotlib
0b47697b19b77226c633ec6a3d74a2199a153315
[ "PSF-2.0", "BSD-3-Clause" ]
null
null
null
#------------------------------------------------------------------------------- # # Written by: David C. Morrill # # Date: 05/20/2005 # # (c) Copyright 2005 by Enthought, Inc. # # Classes defined: KeyBinding, KeyBindings # #------------------------------------------------------------------------------- """ Defines...
42.213953
80
0.368114
7,519
0.828449
0
0
0
0
0
0
4,688
0.516527
06e007230d32188f666bcfa817cb0d72deaa62d6
639
py
Python
cocos#275--HTMLLabel/html_label_test.py
los-cocos/etc_code
71c642a5e0f7ff8049cb5fb4ecac3f166ca20280
[ "MIT" ]
2
2016-08-28T19:41:47.000Z
2018-12-14T22:01:26.000Z
cocos#275--HTMLLabel/html_label_test.py
los-cocos/etc_code
71c642a5e0f7ff8049cb5fb4ecac3f166ca20280
[ "MIT" ]
null
null
null
cocos#275--HTMLLabel/html_label_test.py
los-cocos/etc_code
71c642a5e0f7ff8049cb5fb4ecac3f166ca20280
[ "MIT" ]
2
2015-09-21T06:55:12.000Z
2020-05-29T14:34:34.000Z
#!/usr/bin/env python3 # -*-coding:utf-8 -* import cocos from cocos.text import HTMLLabel from cocos.director import director class TestLayer(cocos.layer.Layer): def __init__(self): super(TestLayer, self).__init__() x, y = director.get_window_size() self.text = HTMLLabel("""<center><font...
24.576923
68
0.640063
334
0.522692
0
0
0
0
0
0
155
0.242567
06e062374abeb59d36c97a31d852af3b3fb9d03c
4,284
py
Python
depronoun.py
rui-bettencourt/AutomaticSentenceDivision
4cb29897103189791c932aaea42c8d5b4ecd8bcd
[ "MIT" ]
null
null
null
depronoun.py
rui-bettencourt/AutomaticSentenceDivision
4cb29897103189791c932aaea42c8d5b4ecd8bcd
[ "MIT" ]
null
null
null
depronoun.py
rui-bettencourt/AutomaticSentenceDivision
4cb29897103189791c932aaea42c8d5b4ecd8bcd
[ "MIT" ]
null
null
null
# from nltk.tokenize import word_tokenize from xml.dom import minidom import progressbar from time import sleep input_file = 'data/dataset_output.txt' num_lines = sum(1 for line in open(input_file)) read_file = open(input_file, 'r') write_output_file = open('data/dataset_output_no_pronouns.txt', 'w') pronouns = ['h...
33.46875
157
0.614613
0
0
0
0
0
0
0
0
837
0.195378
06e4f094f267243cc672eb7459a8a3c1167d18f8
2,794
py
Python
pyaws/utils/userinput.py
mwozniczak/pyaws
af8f6d64ff47fd2ef2eb9fef25680e4656523fa3
[ "MIT" ]
null
null
null
pyaws/utils/userinput.py
mwozniczak/pyaws
af8f6d64ff47fd2ef2eb9fef25680e4656523fa3
[ "MIT" ]
null
null
null
pyaws/utils/userinput.py
mwozniczak/pyaws
af8f6d64ff47fd2ef2eb9fef25680e4656523fa3
[ "MIT" ]
null
null
null
""" Python3 Module Summary: User Input Manipulation """ import re from string import ascii_lowercase def bool_assignment(arg, patterns=None): """ Summary: Enforces correct bool argment assignment Arg: :arg (*): arg which must be interpreted as either bool True or False Returns: ...
30.043011
100
0.566929
0
0
0
0
0
0
0
0
1,203
0.430565
06e51ad894ceaca1307a132e1efdb1fe4242fe80
17,008
py
Python
batches.py
NRHelmi/ldbc_snb_data_converter
42eb5dfbe8b46bcb4d8ad56e1fd988e7635deea3
[ "Apache-2.0" ]
2
2021-01-22T10:07:18.000Z
2021-02-09T18:13:28.000Z
batches.py
NRHelmi/ldbc_snb_data_converter
42eb5dfbe8b46bcb4d8ad56e1fd988e7635deea3
[ "Apache-2.0" ]
5
2021-02-11T23:12:05.000Z
2021-05-21T12:16:29.000Z
batches.py
szarnyasg/ldbc-example-graph
1fd52bc60d50cf5184ee1331369d754db2b8489f
[ "Apache-2.0" ]
1
2022-03-24T20:02:23.000Z
2022-03-24T20:02:23.000Z
import duckdb from datetime import date from dateutil.relativedelta import relativedelta import os import shutil con = duckdb.connect(database='ldbc.duckdb', read_only=False) # batches are selected from the [network_start_date, network_end_date) interval, # each batch denotes a [batch_start_date, batch_end_date) wher...
50.619048
350
0.596954
0
0
0
0
0
0
0
0
14,060
0.82667
06e980c4f9e4c64a9ff9ed3aae6e787174a3969c
193
py
Python
College grade 2/Python 3/Lab_2/Ansel/exercise 1.py
SimonH19009/Lzu_Data-science
bd35c5e156b0db21c3585c11dce15fba0b7003e2
[ "MIT" ]
1
2022-03-06T05:30:44.000Z
2022-03-06T05:30:44.000Z
College grade 2/Python 3/Lab_2/Ansel/exercise 1.py
SimonH19009/Lzu_Data-science
bd35c5e156b0db21c3585c11dce15fba0b7003e2
[ "MIT" ]
null
null
null
College grade 2/Python 3/Lab_2/Ansel/exercise 1.py
SimonH19009/Lzu_Data-science
bd35c5e156b0db21c3585c11dce15fba0b7003e2
[ "MIT" ]
1
2022-03-06T06:07:40.000Z
2022-03-06T06:07:40.000Z
try: a=int(input("Please enter a number:")) if 9<a<100: a = str(a) print(a[0]) print(a[1]) else: print("no correct") except: print("no correct")
17.545455
42
0.487047
0
0
0
0
0
0
0
0
48
0.248705
06eb8e9951d11356b784f19e2310c1cacd28857e
122
py
Python
gameLogic/__init__.py
JoelEager/pyTanks-Server
4455c0475980ea1372f11d7ec41d95990b3c8f44
[ "MIT" ]
5
2017-09-04T09:36:40.000Z
2019-10-31T20:52:13.000Z
gameLogic/__init__.py
JoelEager/pyTanks-Server
4455c0475980ea1372f11d7ec41d95990b3c8f44
[ "MIT" ]
3
2018-12-28T08:09:51.000Z
2019-01-04T20:36:47.000Z
gameLogic/__init__.py
JoelEager/pyTanks-Server
4455c0475980ea1372f11d7ec41d95990b3c8f44
[ "MIT" ]
1
2018-12-28T08:12:36.000Z
2018-12-28T08:12:36.000Z
""" Contains all the logic for running the game (game clock, per-frame logic, game state update generation, and so on) """
40.666667
114
0.737705
0
0
0
0
0
0
0
0
122
1
06f25df0cac2fd1a3b4a6fa7c42cbde635e84014
1,131
py
Python
hypothesis/nn/neuromodulation/base.py
boyali/hypothesis-sre
f44d25eb281d49663d49d134ee73ad542849714b
[ "BSD-3-Clause" ]
45
2019-02-13T14:16:35.000Z
2022-02-23T21:30:02.000Z
hypothesis/nn/neuromodulation/base.py
boyali/hypothesis-sre
f44d25eb281d49663d49d134ee73ad542849714b
[ "BSD-3-Clause" ]
1
2020-01-13T08:29:50.000Z
2020-01-22T10:28:02.000Z
hypothesis/nn/neuromodulation/base.py
boyali/hypothesis-sre
f44d25eb281d49663d49d134ee73ad542849714b
[ "BSD-3-Clause" ]
8
2019-04-23T14:25:08.000Z
2021-07-28T15:05:31.000Z
import hypothesis import torch from hypothesis.nn.util import list_modules_with_type def allocate_neuromodulated_activation(activation, allocator): class LambdaNeuromodulatedActivation(BaseNeuromodulatedModule): def __init__(self): super(LambdaNeuromodulatedActivation, self).__init__( ...
26.928571
87
0.715296
783
0.692308
0
0
0
0
0
0
0
0
06f368aa1460565e63ed4a80b862ae97a70212cf
1,151
py
Python
2.py
zweed4u/dailycodingproblem
6e40eaad347e283f86a11adeff01c6426211a0be
[ "MIT" ]
null
null
null
2.py
zweed4u/dailycodingproblem
6e40eaad347e283f86a11adeff01c6426211a0be
[ "MIT" ]
null
null
null
2.py
zweed4u/dailycodingproblem
6e40eaad347e283f86a11adeff01c6426211a0be
[ "MIT" ]
null
null
null
#!/usr/bin/python3 """ Good morning! Here's your coding interview problem for today. This problem was asked by Uber. Given an array of integers, return a new array such that each element at index i of the new array is the product of all the numbers in the original array except the one at i. For example, if our input...
28.775
174
0.636838
0
0
0
0
0
0
0
0
564
0.490009
06fbcffd6a9d16ac26a727dde7c14ddf62ce182c
3,685
py
Python
ldap_login/management/commands/importLDAPusers.py
knightsamar/change_agent
53e8b6335f5f6856ae12dba6a509e4147c68a004
[ "Apache-2.0" ]
null
null
null
ldap_login/management/commands/importLDAPusers.py
knightsamar/change_agent
53e8b6335f5f6856ae12dba6a509e4147c68a004
[ "Apache-2.0" ]
null
null
null
ldap_login/management/commands/importLDAPusers.py
knightsamar/change_agent
53e8b6335f5f6856ae12dba6a509e4147c68a004
[ "Apache-2.0" ]
null
null
null
from django.core.management.base import NoArgsCommand, CommandError; from ldap_login.ldapUtils import ldapManager; from ldap_login.models import user,group,Role; from datetime import datetime; import traceback; class Command(NoArgsCommand): """Import LDAP users from Active Directory. Uses the ldapUtils back...
46.64557
131
0.536228
3,459
0.93867
0
0
0
0
0
0
1,202
0.326187
06fe538ead84c59a5f996694a885042a2b6cbe93
822
py
Python
rocketchat_API/APISections/subscriptions.py
dudanogueira/rocketchat_API
190952f07ce04a356c79ad29e9d1e01dea620ba6
[ "MIT" ]
210
2017-03-20T13:36:24.000Z
2022-03-30T17:37:02.000Z
rocketchat_API/APISections/subscriptions.py
dudanogueira/rocketchat_API
190952f07ce04a356c79ad29e9d1e01dea620ba6
[ "MIT" ]
144
2017-03-21T13:50:22.000Z
2022-03-28T09:43:26.000Z
rocketchat_API/APISections/subscriptions.py
dudanogueira/rocketchat_API
190952f07ce04a356c79ad29e9d1e01dea620ba6
[ "MIT" ]
103
2017-03-20T13:54:54.000Z
2022-03-22T05:00:18.000Z
from rocketchat_API.APISections.base import RocketChatBase class RocketChatSubscriptions(RocketChatBase): def subscriptions_get(self, **kwargs): """Get all subscriptions.""" return self.call_api_get("subscriptions.get", kwargs=kwargs) def subscriptions_get_one(self, room_id, **kwargs): ...
41.1
88
0.708029
760
0.924574
0
0
0
0
0
0
229
0.278589
06fefeedf2e0b5eb6fdb9935285ddf733447d30c
1,081
py
Python
accounts/models.py
Phist0ne/webvirtcloud
d94ca38e5c8b5bb1323d33067ee6b991775cc390
[ "Apache-2.0" ]
2
2018-03-14T09:46:49.000Z
2019-05-14T11:45:14.000Z
accounts/models.py
JamesLinus/webvirtcloud
d94ca38e5c8b5bb1323d33067ee6b991775cc390
[ "Apache-2.0" ]
1
2018-03-01T04:05:25.000Z
2018-10-01T08:30:00.000Z
accounts/models.py
caicloud/webvirtcloud
d94ca38e5c8b5bb1323d33067ee6b991775cc390
[ "Apache-2.0" ]
1
2019-06-11T19:54:08.000Z
2019-06-11T19:54:08.000Z
from django.db import models from django.contrib.auth.models import User from instances.models import Instance class UserInstance(models.Model): user = models.ForeignKey(User) instance = models.ForeignKey(Instance) is_change = models.BooleanField(default=False) is_delete = models.BooleanField(default=...
30.885714
63
0.747456
962
0.889917
0
0
0
0
0
0
0
0
6600b5f654aa204f83a56f1407440180c9d9fa01
8,744
py
Python
sdk/python/pulumi_cloudflare/custom_ssl.py
vijayraavi/pulumi-cloudflare
ba61514d650fc7a5a2667147519de213c07344b8
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
sdk/python/pulumi_cloudflare/custom_ssl.py
vijayraavi/pulumi-cloudflare
ba61514d650fc7a5a2667147519de213c07344b8
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
sdk/python/pulumi_cloudflare/custom_ssl.py
vijayraavi/pulumi-cloudflare
ba61514d650fc7a5a2667147519de213c07344b8
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import json import warnings import pulumi import pulumi.runtime from typing import Union from . import utilities, tables class CustomS...
60.722222
440
0.688358
8,435
0.964661
0
0
2,984
0.341263
0
0
5,798
0.663083
66012301064b5709a93a6fcc63e250bae442c6d6
1,804
py
Python
main.py
PortosKo/Python_Lesson_2
160c569f17d21cc1f2e48227b526a49594e90d59
[ "MIT" ]
null
null
null
main.py
PortosKo/Python_Lesson_2
160c569f17d21cc1f2e48227b526a49594e90d59
[ "MIT" ]
null
null
null
main.py
PortosKo/Python_Lesson_2
160c569f17d21cc1f2e48227b526a49594e90d59
[ "MIT" ]
null
null
null
#Задачи на циклы и оператор условия------ #---------------------------------------- ''' # Задача 1 Вывести на экран циклом пять строк из нулей, причем каждая строка должна быть пронумерована. ''' print ('Задача1') x = 0 for x in range (1,6,): print (x,0) ''' Задача 2 Пользователь в цикле вводит 10 цифр. Найти к...
15.288136
92
0.636364
0
0
0
0
0
0
0
0
1,551
0.64197
660235efa168bc77f41850e9696ac1ce83979716
5,062
py
Python
config_loader/loader.py
egabancho/config-loader
af45c7bef3afe4dee930754386a1763a28574d6c
[ "MIT" ]
null
null
null
config_loader/loader.py
egabancho/config-loader
af45c7bef3afe4dee930754386a1763a28574d6c
[ "MIT" ]
null
null
null
config_loader/loader.py
egabancho/config-loader
af45c7bef3afe4dee930754386a1763a28574d6c
[ "MIT" ]
null
null
null
"""Configuration loader class.""" import ast import logging import os import types from operator import attrgetter import pkg_resources logger = logging.getLogger(__name__) class Config(object): """Configuration loader, it's like a normal dictionary with super-powers. It will load configuration in the fol...
32.87013
79
0.633544
4,883
0.964638
0
0
239
0.047215
0
0
2,340
0.462268
6603d02ce7ae8ff687520b5fd3b5f402880ef876
1,616
py
Python
tginviter/storage/base_storage.py
cuamckuu/tg-inviter
80b8d4664d1e2628b46ac1a6d58f8495c408d4b4
[ "MIT" ]
20
2020-08-24T19:11:38.000Z
2022-03-17T19:24:50.000Z
tginviter/storage/base_storage.py
bequirky12/tg-inviter
5cad1bc1afce101be03a2cee805931e77b7f6842
[ "MIT" ]
null
null
null
tginviter/storage/base_storage.py
bequirky12/tg-inviter
5cad1bc1afce101be03a2cee805931e77b7f6842
[ "MIT" ]
8
2021-02-05T11:51:21.000Z
2022-03-22T08:48:44.000Z
import abc from typing import AbstractSet class BaseStorage(abc.ABC): """Abstract base class for storing invite link tokens""" def insert(self, token: str, *, payload: dict, max_uses=1): """Insert token to storage. Shoud call super().insert(...)""" if type(payload) != dict: raise...
31.076923
76
0.631188
1,571
0.972153
0
0
829
0.512995
0
0
590
0.365099
660466e84335250fcffeb29f786f70f54055b5a4
874
py
Python
docker/run.py
lvxiaojie111/2019NCCCU-
5b2d2b3a6e70e5b447ccaecd02fbead4763db82d
[ "Apache-2.0" ]
3
2020-10-18T02:16:37.000Z
2020-10-18T02:30:03.000Z
docker/run.py
lvxiaojie111/2019NCCCU-
5b2d2b3a6e70e5b447ccaecd02fbead4763db82d
[ "Apache-2.0" ]
null
null
null
docker/run.py
lvxiaojie111/2019NCCCU-
5b2d2b3a6e70e5b447ccaecd02fbead4763db82d
[ "Apache-2.0" ]
null
null
null
#! /usr/bin/env python # -*- coding: utf-8 -*- import numpy as np import os import pandas as pd import testmodel import imageio if __name__ == "__main__": #################### 不可修改区域开始 ###################### testpath = '/home/data/' #测试集路径。包含验证码图片文件 result_folder_path = '/code/result/submission.csv' ...
32.37037
74
0.613272
0
0
0
0
0
0
0
0
666
0.606557
6604fb1cbe01eb3c82eaa8f6e34b1bd3c2c37677
359
py
Python
app/api/v1/__init__.py
Ethan-Ceng/Flask-CMS
2fe2664e9ae60affe277e9c3b50c18a2e32e422b
[ "MIT" ]
null
null
null
app/api/v1/__init__.py
Ethan-Ceng/Flask-CMS
2fe2664e9ae60affe277e9c3b50c18a2e32e422b
[ "MIT" ]
null
null
null
app/api/v1/__init__.py
Ethan-Ceng/Flask-CMS
2fe2664e9ae60affe277e9c3b50c18a2e32e422b
[ "MIT" ]
null
null
null
from flask import Blueprint from app.api.v1 import user, book, client, token def create_blueprint(): bp_v1 = Blueprint('v1', __name__) user.api.register(bp_v1, url_prefix='/client') user.api.register(bp_v1, url_prefix='/user') book.api.register(bp_v1, url_prefix='/book') book.api.register(bp_v1, ...
25.642857
50
0.707521
0
0
0
0
0
0
0
0
35
0.097493
66055a1c87077054947e4816c06f4763187ad5d0
3,125
py
Python
draugr/visualisation/seaborn_utilities/seaborn_enums.py
cnHeider/draugr
b95e0bb1fa5efa581bfb28ff604f296ed2e6b7d6
[ "Apache-2.0" ]
3
2019-09-27T08:04:59.000Z
2020-12-02T06:14:45.000Z
draugr/visualisation/seaborn_utilities/seaborn_enums.py
cnHeider/draugr
b95e0bb1fa5efa581bfb28ff604f296ed2e6b7d6
[ "Apache-2.0" ]
64
2019-09-27T08:03:42.000Z
2022-03-28T15:07:30.000Z
draugr/visualisation/seaborn_utilities/seaborn_enums.py
cnHeider/draugr
b95e0bb1fa5efa581bfb28ff604f296ed2e6b7d6
[ "Apache-2.0" ]
1
2020-10-01T00:18:57.000Z
2020-10-01T00:18:57.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- __author__ = "Christian Heider Nielsen" __doc__ = r""" Created on 26-01-2021 """ from enum import Enum from typing import Tuple import numpy from matplotlib import patheffects, pyplot __all__ = ["plot_median_labels", "show_values_on_bars"] from ...
28.935185
86
0.57632
267
0.08544
0
0
0
0
0
0
836
0.26752
6606cccffcd956e1fc4991eb79ef12938f47ff11
523
py
Python
get_gecko_driver/platforms.py
zaironjacobs/get-gecko-driver
33a4a90c3a96b2e5519722f3dfab075b57e6482d
[ "MIT" ]
3
2021-08-16T14:49:55.000Z
2022-03-20T14:44:13.000Z
get_gecko_driver/platforms.py
zaironjacobs/get-gecko-driver
33a4a90c3a96b2e5519722f3dfab075b57e6482d
[ "MIT" ]
null
null
null
get_gecko_driver/platforms.py
zaironjacobs/get-gecko-driver
33a4a90c3a96b2e5519722f3dfab075b57e6482d
[ "MIT" ]
1
2022-02-19T08:41:57.000Z
2022-02-19T08:41:57.000Z
class Platforms: @property def win(self): return 'win' @property def linux(self): return 'linux' @property def macos(self): return 'macos' @property def win_32(self): return 'win32' @property def win_64(self): return 'win64' @prop...
15.382353
49
0.552581
522
0.998088
0
0
458
0.875717
0
0
51
0.097514
66085420dcc9a5728829c81982cb5b8af048ece5
1,061
py
Python
py/callback_dashboard.py
pnvnd/plotly
ede0bb0bb92484c2e3bf4e3631fa97f547e02c16
[ "Unlicense" ]
null
null
null
py/callback_dashboard.py
pnvnd/plotly
ede0bb0bb92484c2e3bf4e3631fa97f547e02c16
[ "Unlicense" ]
null
null
null
py/callback_dashboard.py
pnvnd/plotly
ede0bb0bb92484c2e3bf4e3631fa97f547e02c16
[ "Unlicense" ]
1
2022-01-22T17:19:25.000Z
2022-01-22T17:19:25.000Z
from dash import dash, dcc, html from dash.dependencies import Input, Output import plotly.graph_objs as go import pandas as pd url = 'csv/covidtesting.csv' df = pd.read_csv(url) app = dash.Dash() # list = df.columns[1:] # filter_options = [] # for option in list: # filter_options.append({'label': str(option), ...
24.113636
89
0.597549
0
0
0
0
468
0.441093
0
0
394
0.371348
6608592b97fcda5eb8dc5fb8cb22369434750380
4,288
py
Python
appface.py
iljoong/FaceTag
c43fce89c92ce6de2f397580d80aa834d3e2dbb6
[ "MIT" ]
2
2021-11-12T15:30:55.000Z
2021-11-14T13:53:13.000Z
appface.py
iljoong/FaceTag
c43fce89c92ce6de2f397580d80aa834d3e2dbb6
[ "MIT" ]
1
2018-07-31T08:30:33.000Z
2018-08-01T04:44:52.000Z
appface.py
iljoong/FaceTag
c43fce89c92ce6de2f397580d80aa834d3e2dbb6
[ "MIT" ]
1
2021-11-12T15:31:00.000Z
2021-11-12T15:31:00.000Z
############################################################################################### from keras.models import Model, load_model from PIL import Image import numpy as np import time import cv2 import os import logging import pymongo #import dlib import requests import appconfig import json cascade = cv2.Cas...
28.586667
145
0.614039
0
0
0
0
0
0
0
0
1,598
0.372668
6608e0e22e04d214ade1044f1d502d28fa22890a
5,488
py
Python
src/object2.py
vmlaker/sherlock
4827803400907cb892b73f74736b151463fcda27
[ "MIT" ]
62
2015-01-01T16:26:36.000Z
2022-03-07T11:38:57.000Z
src/object2.py
vmlaker/sherlock
4827803400907cb892b73f74736b151463fcda27
[ "MIT" ]
null
null
null
src/object2.py
vmlaker/sherlock
4827803400907cb892b73f74736b151463fcda27
[ "MIT" ]
13
2015-08-01T10:54:13.000Z
2020-12-05T02:19:23.000Z
"""Object detection pipeline.""" import multiprocessing import datetime import time import sys import cv2 import numpy as np import socket import sharedmem import mpipe import coils import util DEVICE = int(sys.argv[1]) WIDTH = int(sys.argv[2]) HEIGHT = int(sys.argv[3]) DURATION = float(sys.argv[4]) # In se...
29.347594
81
0.622085
1,936
0.35277
0
0
0
0
0
0
1,725
0.314322
6609a45086c57a15190dcecf91e35dfc73259aed
78
py
Python
answers/001/answer1.py
PyLadiesTokyo/pyladies-tokyo-homework
3727451d073eb6e9b48f3cd0561c3b64b109f3a5
[ "Apache-2.0" ]
null
null
null
answers/001/answer1.py
PyLadiesTokyo/pyladies-tokyo-homework
3727451d073eb6e9b48f3cd0561c3b64b109f3a5
[ "Apache-2.0" ]
null
null
null
answers/001/answer1.py
PyLadiesTokyo/pyladies-tokyo-homework
3727451d073eb6e9b48f3cd0561c3b64b109f3a5
[ "Apache-2.0" ]
1
2020-12-27T13:05:44.000Z
2020-12-27T13:05:44.000Z
# 1から10までの整数を表示する for num in [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]: print(num)
26
44
0.538462
0
0
0
0
0
0
0
0
42
0.411765
660ac2d8937432f3e9a4b2a9a74404def921da17
132
py
Python
lab2_typyOperacje/2.15.py
Damian9449/Python
dc9091e15356733821bbb6a768b7d5e428640340
[ "MIT" ]
1
2017-11-15T13:03:40.000Z
2017-11-15T13:03:40.000Z
lab2_typyOperacje/2.15.py
Damian9449/Python
dc9091e15356733821bbb6a768b7d5e428640340
[ "MIT" ]
null
null
null
lab2_typyOperacje/2.15.py
Damian9449/Python
dc9091e15356733821bbb6a768b7d5e428640340
[ "MIT" ]
null
null
null
#!/usr/bin/python L = [1, 3, 6, 77, 34, 45, 26, 81] result = "" for number in L: result = result + str(number) print(result)
13.2
33
0.575758
0
0
0
0
0
0
0
0
19
0.143939
660bd601b31c2cdb55bcbc98f8dc987a833cfa02
2,743
py
Python
af_scripts/tmp/blendShapeEditor.py
aaronfang/small-Scripts
890b10ab19fa9cdf2415aaf2dc08b81cc64fc79d
[ "MIT" ]
1
2018-03-08T16:34:00.000Z
2018-03-08T16:34:00.000Z
af_scripts/tmp/blendShapeEditor.py
aaronfang/personal_scripts
890b10ab19fa9cdf2415aaf2dc08b81cc64fc79d
[ "MIT" ]
null
null
null
af_scripts/tmp/blendShapeEditor.py
aaronfang/personal_scripts
890b10ab19fa9cdf2415aaf2dc08b81cc64fc79d
[ "MIT" ]
null
null
null
import maya.cmds as cmds class blendShapeEditor(object): def __init__(self): self.blendshape_node = blendshape_node = [] self.target_nodes = target_nodes = [] def prepareOrginialGeo(self,*args): sel = cmds.ls(sl=True)[0] if '_org' in sel: blendshape_base_geo = cmds...
49.872727
133
0.629603
2,682
0.977762
0
0
0
0
0
0
473
0.172439
660c4602652eeabae6b9b5b5f22abc8c78653e52
134
py
Python
bugtests/test000.py
doom38/jython_v2.2.1
0803a0c953c294e6d14f9fc7d08edf6a3e630a15
[ "CNRI-Jython" ]
null
null
null
bugtests/test000.py
doom38/jython_v2.2.1
0803a0c953c294e6d14f9fc7d08edf6a3e630a15
[ "CNRI-Jython" ]
null
null
null
bugtests/test000.py
doom38/jython_v2.2.1
0803a0c953c294e6d14f9fc7d08edf6a3e630a15
[ "CNRI-Jython" ]
null
null
null
""" Basic test, just raises a TestWarning """ import support raise support.TestWarning('A test of TestWarning. It is not an error')
16.75
70
0.738806
0
0
0
0
0
0
0
0
88
0.656716
660dfb4d814fae5a38c519d53465f866ae0f301e
5,511
py
Python
model.py
braemt/attentive-multi-task-deep-reinforcement-learning
921feefce98076f88c892f0b7e6db8572f596763
[ "MIT" ]
12
2019-04-07T02:04:48.000Z
2022-03-22T12:57:47.000Z
model.py
braemt/attentive-multi-task-deep-reinforcement-learning
921feefce98076f88c892f0b7e6db8572f596763
[ "MIT" ]
null
null
null
model.py
braemt/attentive-multi-task-deep-reinforcement-learning
921feefce98076f88c892f0b7e6db8572f596763
[ "MIT" ]
7
2019-04-07T02:04:49.000Z
2020-12-28T10:30:27.000Z
import numpy as np import tensorflow as tf def normalized_columns_initializer(std=1.0): def _initializer(shape, dtype=None, partition_info=None): out = np.random.randn(*shape).astype(np.float32) out *= std / np.sqrt(np.square(out).sum(axis=0, keepdims=True)) return tf.constant(out) ret...
46.310924
119
0.577209
3,313
0.601161
0
0
0
0
0
0
380
0.068953
660ea1a100d2f6604cf5b576d0992caedb50b349
632
py
Python
src/data/852.py
NULLCT/LOMC
79a16474a8f21310e0fb47e536d527dd5dc6d655
[ "MIT" ]
null
null
null
src/data/852.py
NULLCT/LOMC
79a16474a8f21310e0fb47e536d527dd5dc6d655
[ "MIT" ]
null
null
null
src/data/852.py
NULLCT/LOMC
79a16474a8f21310e0fb47e536d527dd5dc6d655
[ "MIT" ]
null
null
null
from collections import deque n, q = map(int, input().split()) graph = [[] for _ in range(n + 1)] for i in range(n - 1): a, b = map(int, input().split()) graph[a].append(b) graph[b].append(a) CD = [] for i in range(q): e, f = map(int, input().split()) CD.append([e, f]) dist = [-1] * (n + 1) dis...
16.631579
36
0.47943
0
0
0
0
0
0
0
0
12
0.018987
6611e568c85da823794769b3aacdd4d28bc257c0
265,414
py
Python
stashboard/contrib/status_images.py
l1kw1d/stashboard
3e4b18a8168c102d1e1d7f88fec22bcbfc530d23
[ "MIT" ]
761
2015-01-01T05:28:26.000Z
2022-03-24T10:07:31.000Z
stashboard/contrib/status_images.py
l1kw1d/stashboard
3e4b18a8168c102d1e1d7f88fec22bcbfc530d23
[ "MIT" ]
11
2015-02-05T23:43:47.000Z
2019-01-10T13:43:42.000Z
stashboard/contrib/status_images.py
l1kw1d/stashboard
3e4b18a8168c102d1e1d7f88fec22bcbfc530d23
[ "MIT" ]
226
2015-01-05T15:04:45.000Z
2022-03-23T11:41:00.000Z
# Copyright (c) 2010 Twilio Inc. # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, publish, distri...
25.193545
79
0.472439
0
0
0
0
0
0
0
0
165,519
0.623626
6613dec8d628000fe7b472846f82eac73bd8f3ea
49,047
py
Python
autojail/config/memory.py
ekut-es/autojail
bc16e40e6df55c0a28a3059715851ffa59b14ba8
[ "MIT" ]
6
2020-08-12T08:16:15.000Z
2022-03-05T02:25:53.000Z
autojail/config/memory.py
ekut-es/autojail
bc16e40e6df55c0a28a3059715851ffa59b14ba8
[ "MIT" ]
1
2021-03-30T10:34:51.000Z
2021-06-09T11:24:00.000Z
autojail/config/memory.py
ekut-es/autojail
bc16e40e6df55c0a28a3059715851ffa59b14ba8
[ "MIT" ]
1
2021-11-21T09:30:58.000Z
2021-11-21T09:30:58.000Z
import copy import logging import math import sys from collections import defaultdict from functools import reduce from typing import ( Any, Callable, Dict, Iterable, List, Optional, Sequence, Tuple, Union, ) import tabulate from ortools.sat.python import cp_model from ..model impo...
35.438584
140
0.538728
48,355
0.985891
0
0
291
0.005933
0
0
4,099
0.083573
661499e1d6e03e831ef662b0f10bed15a0e0160c
806
py
Python
tests/test_util.py
tsufeki/python-restclientaio
2af2ded9e22ba5552ace193691ed3a4b520cadf8
[ "BSD-2-Clause" ]
null
null
null
tests/test_util.py
tsufeki/python-restclientaio
2af2ded9e22ba5552ace193691ed3a4b520cadf8
[ "BSD-2-Clause" ]
null
null
null
tests/test_util.py
tsufeki/python-restclientaio
2af2ded9e22ba5552ace193691ed3a4b520cadf8
[ "BSD-2-Clause" ]
null
null
null
import pytest from restclientaio._util import * class TestFullName: @pytest.mark.parametrize('args,expected', [ ((str,), 'builtins.str'), ((str, 'lower'), 'builtins.str.lower'), ]) def test_full_name(self, args, expected): assert full_name(*args) == expected class TestFormatRe...
25.1875
74
0.555831
750
0.930521
0
0
545
0.676179
0
0
152
0.188586
6615213f91d714c671d2fcc45dfcb7ea7995394c
1,112
py
Python
experiments/test_experiments.py
srikarym/torchrl
fee98e78ac1657a2c9a4063dd8d63ba207a121e2
[ "Apache-2.0" ]
3
2019-02-27T19:00:32.000Z
2020-07-19T03:18:28.000Z
experiments/test_experiments.py
srikarym/torchrl
fee98e78ac1657a2c9a4063dd8d63ba207a121e2
[ "Apache-2.0" ]
null
null
null
experiments/test_experiments.py
srikarym/torchrl
fee98e78ac1657a2c9a4063dd8d63ba207a121e2
[ "Apache-2.0" ]
null
null
null
# pylint: disable=redefined-outer-name """Test Experiments. This test runs all problems and hyperparameter pairs for 100 time steps. It only guarantees correct API compatiblity and not the problem performance metrics. """ import pytest from torchrl import registry from torchrl.cli.commands.run import do_run proble...
24.711111
72
0.714029
0
0
335
0.301259
591
0.531475
0
0
366
0.329137
661546474c795c91d1a7e8fb806431b8b074972c
3,289
py
Python
gw2_price_get.py
rpatricktaylor/gw2_pricepull
ede658cd7cb567d8ab7e6c7698acee83eacc78a3
[ "MIT" ]
null
null
null
gw2_price_get.py
rpatricktaylor/gw2_pricepull
ede658cd7cb567d8ab7e6c7698acee83eacc78a3
[ "MIT" ]
null
null
null
gw2_price_get.py
rpatricktaylor/gw2_pricepull
ede658cd7cb567d8ab7e6c7698acee83eacc78a3
[ "MIT" ]
null
null
null
import json import time import bs4 import numpy as np import pandas as pd import requests as rqs url_apiV2 = r'https://api.guildwars2.com/v2' working_dir = r'/home/ubuntu/' def gw2_request(request_type, item_nums, retries = 25): item_num_str = ','.join([str(num) for num in item_nums]) req...
29.366071
89
0.549407
0
0
0
0
0
0
0
0
334
0.101551
66160d3954e8f1108b126460356e2b0740e00e9e
2,055
py
Python
create_db.py
vladstorm98/TaskBoard
ebe4244cc5cbdfda2fdaac84c0158692f440517c
[ "MIT" ]
null
null
null
create_db.py
vladstorm98/TaskBoard
ebe4244cc5cbdfda2fdaac84c0158692f440517c
[ "MIT" ]
null
null
null
create_db.py
vladstorm98/TaskBoard
ebe4244cc5cbdfda2fdaac84c0158692f440517c
[ "MIT" ]
null
null
null
from flask import Flask from flask_sqlalchemy import SQLAlchemy from config import Config app = Flask(__name__) app.config.from_object(Config) db = SQLAlchemy(app) class User(db.Model): __tablename__ = 'user' id = db.Column(db.Integer, primary_key=True) email = db.Column(db.String(128), ind...
29.357143
83
0.654988
1,392
0.677372
0
0
0
0
0
0
531
0.258394
661759e4ea700063225bc588e580457ea479d76a
1,954
py
Python
02_assignment/toolbox/Toolbox_Python02450/Scripts/ex3_1_2.py
LukaAvbreht/ML_projects
8b36acdeb017ce8a57959c609b96111968852d5f
[ "MIT" ]
null
null
null
02_assignment/toolbox/Toolbox_Python02450/Scripts/ex3_1_2.py
LukaAvbreht/ML_projects
8b36acdeb017ce8a57959c609b96111968852d5f
[ "MIT" ]
null
null
null
02_assignment/toolbox/Toolbox_Python02450/Scripts/ex3_1_2.py
LukaAvbreht/ML_projects
8b36acdeb017ce8a57959c609b96111968852d5f
[ "MIT" ]
null
null
null
# exercise 3.1.4 import numpy as np from sklearn.feature_extraction.text import CountVectorizer # Load the textDocs.txt as a long string into raw_file: with open('../Data/textDocs.txt', 'r') as f: raw_file = f.read() # raw_file contains sentences seperated by newline characters, # so we split by '\n': corpus = ra...
37.576923
79
0.746162
0
0
0
0
0
0
0
0
1,405
0.719038
661950464dde57e4e6f43aa2be8e46d0304ef9f0
797
py
Python
vid 18 dream logo.py
agneay/turtle-projects
88f7de0c8eb1bb0f37255746c3d11b9c272d1c10
[ "MIT" ]
null
null
null
vid 18 dream logo.py
agneay/turtle-projects
88f7de0c8eb1bb0f37255746c3d11b9c272d1c10
[ "MIT" ]
null
null
null
vid 18 dream logo.py
agneay/turtle-projects
88f7de0c8eb1bb0f37255746c3d11b9c272d1c10
[ "MIT" ]
null
null
null
from turtle import * def l(y,x): lt(y) fd(x) def r(y,x): rt(y) fd(x) def gt(x,y): pu() goto(x,y) pd() bgcolor("lime") color("black","white") shape("circle") ht() speed(1) width(15) gt(-365,-380) begin_fill() seth(90) fd(20) r(5,20) r(4,60) r(5,100) r(5,120) l(85,50) r(10,25) r(15,10) r(15,40) r(15,50) r(1...
9.16092
53
0.567127
0
0
0
0
0
0
0
0
63
0.079046
661ea642755905b0144b877774494043f351d6cb
1,316
py
Python
magicauth/otp_forms.py
glibersat/django-magicauth
545cb0df2b2368b27089e253fafa666ca8a870f1
[ "MIT" ]
null
null
null
magicauth/otp_forms.py
glibersat/django-magicauth
545cb0df2b2368b27089e253fafa666ca8a870f1
[ "MIT" ]
null
null
null
magicauth/otp_forms.py
glibersat/django-magicauth
545cb0df2b2368b27089e253fafa666ca8a870f1
[ "MIT" ]
null
null
null
from django import forms from django.core.validators import RegexValidator from django.core.exceptions import ValidationError from django_otp import user_has_device, devices_for_user from magicauth import settings as magicauth_settings class OTPForm(forms.Form): OTP_NUM_DIGITS = magicauth_settings.OTP_NUM_DIGIT...
37.6
173
0.705167
1,087
0.818524
0
0
0
0
0
0
308
0.231928
6620a1da84d2b9ed5781d255a6553d73c0a0fa9e
186
py
Python
backend/users/schema.py
DDoS000/Event_Registers
84a77d0914333ee830a72e2d31fa5374f70dea35
[ "MIT" ]
null
null
null
backend/users/schema.py
DDoS000/Event_Registers
84a77d0914333ee830a72e2d31fa5374f70dea35
[ "MIT" ]
null
null
null
backend/users/schema.py
DDoS000/Event_Registers
84a77d0914333ee830a72e2d31fa5374f70dea35
[ "MIT" ]
null
null
null
from pydantic import BaseModel class UserUpdate(BaseModel): fullname: str class ChangePassword(BaseModel): current_password: str new_password: str confirm_password: str
20.666667
32
0.768817
152
0.817204
0
0
0
0
0
0
0
0
662106942718d48504f32ad0e27db934931029d3
19,428
py
Python
tests/adapters/test_s3_adapter.py
MonolithAILtd/monolith-filemanager
2369e244e4d8a48890f55d00419a83001a5c6c40
[ "Apache-2.0" ]
3
2021-06-02T09:45:00.000Z
2022-02-01T14:30:01.000Z
tests/adapters/test_s3_adapter.py
MonolithAILtd/monolith-filemanager
2369e244e4d8a48890f55d00419a83001a5c6c40
[ "Apache-2.0" ]
3
2021-05-26T11:46:28.000Z
2021-11-04T10:14:42.000Z
tests/adapters/test_s3_adapter.py
MonolithAILtd/monolith-filemanager
2369e244e4d8a48890f55d00419a83001a5c6c40
[ "Apache-2.0" ]
2
2021-06-04T15:02:14.000Z
2021-09-03T09:26:45.000Z
from unittest import TestCase, main from unittest.mock import patch, MagicMock, call from monolith_filemanager.adapters.s3_processes import S3ProcessesAdapter, S3ProcessesAdapterError class TestS3ProcessesAdapter(TestCase): @patch("monolith_filemanager.adapters.s3_processes.S3ProcessesAdapter.__init__") def ...
51.261214
175
0.726992
19,201
0.988316
0
0
18,308
0.942351
0
0
4,850
0.24964
6621f5308d9319ae5e2c09eb61c97a4f6a12ea20
459
py
Python
maleorfemale.py
harshals13/Jigglypuffpuff
469ea64c71a123cafadc4ae40a1da5171182647b
[ "MIT" ]
null
null
null
maleorfemale.py
harshals13/Jigglypuffpuff
469ea64c71a123cafadc4ae40a1da5171182647b
[ "MIT" ]
null
null
null
maleorfemale.py
harshals13/Jigglypuffpuff
469ea64c71a123cafadc4ae40a1da5171182647b
[ "MIT" ]
null
null
null
from sklearn import tree #[height, weight, shoe size] X = [[181,80,44], [177,70, 43],[160, 60,38],[154, 54, 37], [166,65,40], [190, 90, 47], [175, 64, 39], [177, 70, 40],[159, 55, 45],[171, 75, 42], [181, 85, 43] ] Y = ['male', 'female', 'female', 'female', 'male','male', 'male', 'female', 'male', 'female', 'male'] ...
27
160
0.586057
0
0
0
0
0
0
0
0
120
0.261438
6622d00606e15445d1e62f002d0259e183e527a7
1,921
py
Python
Asap-3.8.4/doc/manual/Dislocation.py
auag92/n2dm
03403ef8da303b79478580ae76466e374ec9da60
[ "MIT" ]
1
2021-10-19T11:35:34.000Z
2021-10-19T11:35:34.000Z
Asap-3.8.4/doc/manual/Dislocation.py
auag92/n2dm
03403ef8da303b79478580ae76466e374ec9da60
[ "MIT" ]
null
null
null
Asap-3.8.4/doc/manual/Dislocation.py
auag92/n2dm
03403ef8da303b79478580ae76466e374ec9da60
[ "MIT" ]
3
2016-07-18T19:22:48.000Z
2021-07-06T03:06:42.000Z
#!/usr/bin/env python from Asap.Setup.Lattice.FCCOrtho import * from Asap.Setup.Dislocation import Dislocation from ASE.ChemicalElements import Element from Asap import * from Asap.Trajectories import NetCDFTrajectory from ASE.Visualization.PrimiPlotter import * from Numeric import * splitting = 5 size = (25, 35, 10)...
28.671642
83
0.692868
0
0
0
0
0
0
0
0
453
0.235815
662336d44c462304b2b5f94e8721da8b5b0d3e73
7,450
py
Python
supercache/engine/memory.py
Peter92/supercache
e85ae87e4c2fead6e2a6aa55c0983d249512f34d
[ "MIT" ]
2
2020-03-02T01:22:25.000Z
2020-05-18T16:52:11.000Z
supercache/engine/memory.py
huntfx/supercache
e85ae87e4c2fead6e2a6aa55c0983d249512f34d
[ "MIT" ]
null
null
null
supercache/engine/memory.py
huntfx/supercache
e85ae87e4c2fead6e2a6aa55c0983d249512f34d
[ "MIT" ]
null
null
null
import time from collections import defaultdict from .. import exceptions, utils class Memory(object): """Cache directly in memory. This is by far the fastest solution, but the cache cannot be shared outside the current process. This is not completely thread safe, but care has been taken to avoid...
32.251082
87
0.52094
7,365
0.988591
0
0
0
0
0
0
2,010
0.269799
6623eb16f8643fe3f8e712cd421dfd5fbd6d80c3
2,541
py
Python
problem_1_falling/test_agent.py
victor-armegioiu/ai-mas-challenges
c449f4bb3fd7e7a5c1c9b00d22209532c92f39aa
[ "MIT" ]
null
null
null
problem_1_falling/test_agent.py
victor-armegioiu/ai-mas-challenges
c449f4bb3fd7e7a5c1c9b00d22209532c92f39aa
[ "MIT" ]
null
null
null
problem_1_falling/test_agent.py
victor-armegioiu/ai-mas-challenges
c449f4bb3fd7e7a5c1c9b00d22209532c92f39aa
[ "MIT" ]
null
null
null
from utils import read_cfg from falling_objects_env import FallingObjects, PLAYER_KEYS, ACTIONS from argparse import ArgumentParser from demo_agent import DemoAgent from dqn_agent import DDQNAgent import importlib import numpy as np import cv2 as cv2 BATCH_SIZE = 32 if __name__ == "__main__": arg_parser = Argumen...
33.88
131
0.67375
0
0
0
0
0
0
0
0
914
0.359701
66240c3ee8769bc3f49297e677406217e8beaf2e
1,505
py
Python
TSTP_20210522_CH4_Functions.py
adjectiveJ/tstp_challenges
e0fcc174594387e0c6142980bf2706d7f5cbc5bd
[ "CC0-1.0" ]
null
null
null
TSTP_20210522_CH4_Functions.py
adjectiveJ/tstp_challenges
e0fcc174594387e0c6142980bf2706d7f5cbc5bd
[ "CC0-1.0" ]
null
null
null
TSTP_20210522_CH4_Functions.py
adjectiveJ/tstp_challenges
e0fcc174594387e0c6142980bf2706d7f5cbc5bd
[ "CC0-1.0" ]
null
null
null
""" The Self-Taught Programmer - Chapter 4 Challenges Author: Dante Valentine Date: 22 May, 2021 """ """ CHALLENGE 1 """ to_square = 12 def square_func(x): # Returns the square of x. return x*x resp = square_func(to_square) #print("The square of", to_square, "is", str(resp) + ".") """ CHAL...
21.5
87
0.621927
0
0
0
0
0
0
0
0
862
0.572757
6629f9d2ad476bdf575b8d97233a3d2d8781d35e
2,874
py
Python
src/unpurple.py
rnbdev/purple-fringe
b372c13f0e4d7d7ba9da53d7e6a4326c0e6c453a
[ "BSD-3-Clause" ]
2
2021-03-16T03:29:41.000Z
2021-05-21T03:32:57.000Z
src/unpurple.py
rnbdev/purple-fringe
b372c13f0e4d7d7ba9da53d7e6a4326c0e6c453a
[ "BSD-3-Clause" ]
null
null
null
src/unpurple.py
rnbdev/purple-fringe
b372c13f0e4d7d7ba9da53d7e6a4326c0e6c453a
[ "BSD-3-Clause" ]
null
null
null
import cv2 import numpy as np import argparse def unpurple(params): img = cv2.imread(params.input).astype(np.float64) img_b = img[..., 0] img_b = np.maximum(0, img_b - params.m * 255) img_b *= params.i / (1 - params.m) width = (params.r << 1) + 1 bl = cv2.blur(img_b, (width, width)) i...
29.9375
76
0.4746
0
0
0
0
0
0
0
0
462
0.160752
662b2a0d020eee523039d18045fe01c4d90be8ba
61
py
Python
psi/serialize/__init__.py
delta-mpc/python-psi
1665de12a713b37abd889268c66de84cddb1bf84
[ "Apache-2.0" ]
35
2021-05-28T10:03:09.000Z
2022-03-24T12:08:19.000Z
psi/serialize/__init__.py
delta-mpc/python-psi
1665de12a713b37abd889268c66de84cddb1bf84
[ "Apache-2.0" ]
9
2021-07-15T09:16:34.000Z
2022-03-31T03:59:16.000Z
psi/serialize/__init__.py
delta-mpc/python-psi
1665de12a713b37abd889268c66de84cddb1bf84
[ "Apache-2.0" ]
16
2021-06-18T02:18:56.000Z
2022-03-25T02:43:48.000Z
from .bit_arr import * from .ecc import * from .int import *
15.25
22
0.704918
0
0
0
0
0
0
0
0
0
0
662b8a1aba28c4cad375998a888ed93da1fcc650
1,588
py
Python
scripts/run_episodes.py
takuma-ynd/rrc_example_package
f53cf3191f4c38f4d1f394ccd55b1d935a6a70ba
[ "BSD-3-Clause" ]
null
null
null
scripts/run_episodes.py
takuma-ynd/rrc_example_package
f53cf3191f4c38f4d1f394ccd55b1d935a6a70ba
[ "BSD-3-Clause" ]
null
null
null
scripts/run_episodes.py
takuma-ynd/rrc_example_package
f53cf3191f4c38f4d1f394ccd55b1d935a6a70ba
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python3 import numpy as np # from rrc_example_package.code.training_env import make_training_env from rrc_example_package.code.training_env.env import ActionType import rrc_example_package.move_cube import rrc_example_package.cube_env # env = make_training_env(visualization=False, **eval_config) # env....
32.408163
82
0.687028
0
0
0
0
0
0
0
0
617
0.388539
662cd92db90d9d0b17d2a45ad47818909732dc56
1,253
py
Python
src/algorithms/utils.py
MSwenne/QSB-Suite
7860e4634bdce10fa79d7f850b6bc2099357d7b0
[ "MIT" ]
null
null
null
src/algorithms/utils.py
MSwenne/QSB-Suite
7860e4634bdce10fa79d7f850b6bc2099357d7b0
[ "MIT" ]
null
null
null
src/algorithms/utils.py
MSwenne/QSB-Suite
7860e4634bdce10fa79d7f850b6bc2099357d7b0
[ "MIT" ]
null
null
null
import random def QFT(first: int, last: int) -> str: res = "// Begin QFT\n" for a in range(first, last+1): res += f"h q[{a}];\n" for b in range(a+1,last+1): res += f"crz({1/(2**(b-a+1))}) q[{a}], q[{b}];\n" return res def QFT_inv(first: int, last: int) -> str: res = "// Beg...
27.23913
63
0.51237
0
0
0
0
0
0
0
0
342
0.272945
662db785b141a51d5e5c2d7a6ae200c6d7fc2fa6
1,458
py
Python
src/sprite.py
GreenXenith/zoria
30a16baab3643c820613a8c8669ee6235a2cd47c
[ "MIT" ]
null
null
null
src/sprite.py
GreenXenith/zoria
30a16baab3643c820613a8c8669ee6235a2cd47c
[ "MIT" ]
null
null
null
src/sprite.py
GreenXenith/zoria
30a16baab3643c820613a8c8669ee6235a2cd47c
[ "MIT" ]
null
null
null
import pygame from . import assets from .vector import * global registered_sprites registered_sprites = {} def register_sprite(name, definition): registered_sprites[name] = definition class Sprite: texture = "none.png" rect = pygame.Rect(0, 0, 0, 0) def __init__(self, name, pos, z): self.nam...
27
78
0.598765
1,265
0.867627
0
0
0
0
0
0
28
0.019204
662f6bd952e2e4b17cde090c9644c4ad6ec3e3d7
5,873
py
Python
pset1 /ps1.py
vnb/Data-Science
af2936b621d51a6839111b6c793f9a270cded16c
[ "MIT" ]
null
null
null
pset1 /ps1.py
vnb/Data-Science
af2936b621d51a6839111b6c793f9a270cded16c
[ "MIT" ]
null
null
null
pset1 /ps1.py
vnb/Data-Science
af2936b621d51a6839111b6c793f9a270cded16c
[ "MIT" ]
null
null
null
########################### # 6.00.2x Problem Set 1: Space Cows from ps1_partition import get_partitions import time #================================ # Part A: Transporting Space Cows #================================ def load_cows(filename): """ Read the contents of the given file. Assumes th...
30.910526
90
0.604461
0
0
0
0
0
0
0
0
3,141
0.53482
6630cfae3164736554237dd2d66a2111da1f1715
6,080
py
Python
blackboxopt/optimization_loops/dask_distributed.py
boschresearch/blackboxopt
85abea86f01a4a9d50f05d15e7d850e3288baafd
[ "ECL-2.0", "Apache-2.0" ]
8
2021-07-05T13:37:22.000Z
2022-03-11T12:23:27.000Z
blackboxopt/optimization_loops/dask_distributed.py
boschresearch/blackboxopt
85abea86f01a4a9d50f05d15e7d850e3288baafd
[ "ECL-2.0", "Apache-2.0" ]
14
2021-07-07T13:55:23.000Z
2022-02-07T13:09:01.000Z
blackboxopt/optimization_loops/dask_distributed.py
boschresearch/blackboxopt
85abea86f01a4a9d50f05d15e7d850e3288baafd
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
# Copyright (c) 2020 - for information on the respective copyright owner # see the NOTICE file and/or the repository https://github.com/boschresearch/blackboxopt # # SPDX-License-Identifier: Apache-2.0 import logging import time from typing import Callable, List, Set, Union try: import dask.distributed as dd exce...
34.742857
88
0.659539
2,026
0.333224
0
0
0
0
0
0
1,727
0.284046
66338488816d4107164bc58a2e6c72cf6c5eff02
2,997
py
Python
admit/at/test/test_ingest.py
astroumd/admit
bbf3d79bb6e1a6f7523553ed8ede0d358d106f2c
[ "MIT" ]
4
2017-03-01T17:26:28.000Z
2022-03-03T19:23:06.000Z
admit/at/test/test_ingest.py
teuben/admit
1cae54d1937c9af3f719102838df716e7e6d655c
[ "MIT" ]
48
2016-10-04T01:25:33.000Z
2021-09-08T14:51:10.000Z
admit/at/test/test_ingest.py
teuben/admit
1cae54d1937c9af3f719102838df716e7e6d655c
[ "MIT" ]
2
2016-11-10T14:10:22.000Z
2017-03-30T18:58:05.000Z
#! /usr/bin/env casarun # # # you can either use the "import" method from within casapy # or use the casarun shortcut to run this from a unix shell # with the argument being the casa image file to be processed # # Typical test usage: # ./test_ingest.py test123.fits [dummy] # This will produce admit....
29.382353
79
0.602936
0
0
0
0
0
0
0
0
1,344
0.448448
66349dcef473158c517a2f6336f11fae97c3b0b4
2,156
py
Python
app/Duration.py
joshuaMarple/phase-vocoder
d652a594da2b526eae758c4d0ca6e87e0497b89d
[ "Apache-2.0" ]
null
null
null
app/Duration.py
joshuaMarple/phase-vocoder
d652a594da2b526eae758c4d0ca6e87e0497b89d
[ "Apache-2.0" ]
null
null
null
app/Duration.py
joshuaMarple/phase-vocoder
d652a594da2b526eae758c4d0ca6e87e0497b89d
[ "Apache-2.0" ]
null
null
null
""" Authors: Fernando (UPDATE HIS INFO) License: GPL 3.0 Description: This file contains functions that allows the user to change the pitch of a .wav Comments: None. """ import subprocess import os from sys import platform as _platform from lib import pydub def changeDuration(filename,percent): """ Input: file...
34.222222
106
0.729128
0
0
0
0
0
0
0
0
1,106
0.512987
6634c188bd630f307a7ad6ecabe91c09bac5af47
12,711
py
Python
network-manager/varanuspy/utils.py
netx-ulx/varanus
7df5ec70563253d72a4287566b1fbb6bdf804a4c
[ "Apache-2.0" ]
null
null
null
network-manager/varanuspy/utils.py
netx-ulx/varanus
7df5ec70563253d72a4287566b1fbb6bdf804a4c
[ "Apache-2.0" ]
null
null
null
network-manager/varanuspy/utils.py
netx-ulx/varanus
7df5ec70563253d72a4287566b1fbb6bdf804a4c
[ "Apache-2.0" ]
null
null
null
from Queue import Empty, Queue import collections import ipaddress import netifaces import pwd import signal import socket from subprocess import Popen from threading import Thread ################################################################################ #### String utils def newline( *args ): class Single...
29.908235
119
0.571001
2,745
0.215955
0
0
0
0
0
0
3,737
0.293997
66373663ff85fccb4333f1b45aed30d0b9af2c3c
8,824
py
Python
load/DBPLoadController.py
faithcomesbyhearing/dbp-etl
ffd849111e8e2d40e9b07663408d31b5a2d15ce7
[ "MIT" ]
null
null
null
load/DBPLoadController.py
faithcomesbyhearing/dbp-etl
ffd849111e8e2d40e9b07663408d31b5a2d15ce7
[ "MIT" ]
4
2021-03-10T22:20:29.000Z
2022-03-23T22:18:00.000Z
load/DBPLoadController.py
faithcomesbyhearing/dbp-etl
ffd849111e8e2d40e9b07663408d31b5a2d15ce7
[ "MIT" ]
1
2021-03-10T20:49:43.000Z
2021-03-10T20:49:43.000Z
# DBPLoadController.py # 1) Run Validate on the files to process # 2) Move any Fileset that is accepted to uploading # 3) Perform upload # 4) Move any fully uploaded fileset to database # 5) Update fileset related tables # 6) Move updated fileset to complete import os from Config import * from RunStatus import * fro...
40.477064
174
0.779012
2,433
0.275725
0
0
0
0
0
0
5,420
0.614234