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
cb4dd1da5b0959f9409976e2ab317566a78b6489
1,107
py
Python
Leet-Code/Container-With-Most-Water.py
aminzayer/My-Python-Code
475e99a134f11e5784478c1d68bce7033ffe02a2
[ "MIT" ]
2
2022-02-16T22:24:14.000Z
2022-02-24T16:59:42.000Z
Leet-Code/Container-With-Most-Water.py
aminzayer/My-Python-Code
475e99a134f11e5784478c1d68bce7033ffe02a2
[ "MIT" ]
null
null
null
Leet-Code/Container-With-Most-Water.py
aminzayer/My-Python-Code
475e99a134f11e5784478c1d68bce7033ffe02a2
[ "MIT" ]
null
null
null
# You are given an integer array height of length n. There are n vertical lines drawn such that the two endpoints of the ith line are(i, 0) and (i, height[i]). # Find two lines that together with the x-axis form a container, such that the container contains the most water. # Return the maximum amount of water a conta...
32.558824
175
0.611563
419
0.3785
0
0
0
0
0
0
668
0.603433
cb4e075a8fb39d2720294e6c1ba006452f6ff42c
2,304
py
Python
ssseg/modules/models/encnet/encoding.py
skydengyao/sssegmentation
606b05983fa967bb3c98d1120f44dfc516532dad
[ "MIT" ]
1
2021-05-28T06:42:37.000Z
2021-05-28T06:42:37.000Z
ssseg/modules/models/encnet/encoding.py
skydengyao/sssegmentation
606b05983fa967bb3c98d1120f44dfc516532dad
[ "MIT" ]
null
null
null
ssseg/modules/models/encnet/encoding.py
skydengyao/sssegmentation
606b05983fa967bb3c98d1120f44dfc516532dad
[ "MIT" ]
null
null
null
''' Function: define the Encoding Layer: a learnable residual encoder Author: Zhenchao Jin ''' import torch import torch.nn as nn import torch.nn.functional as F '''Encoding Layer''' class Encoding(nn.Module): def __init__(self, channels, num_codes): super(Encoding, self).__init__() # init...
43.471698
130
0.65842
2,111
0.916233
0
0
905
0.392795
0
0
383
0.166233
cb4e5f859ce8ac9363882484ef9e2ee69ad80da8
238
py
Python
examples/quiet.py
NiumXp/slog
5635c0cf49fb8dd096f843cfed83e669e68da3de
[ "MIT" ]
null
null
null
examples/quiet.py
NiumXp/slog
5635c0cf49fb8dd096f843cfed83e669e68da3de
[ "MIT" ]
null
null
null
examples/quiet.py
NiumXp/slog
5635c0cf49fb8dd096f843cfed83e669e68da3de
[ "MIT" ]
null
null
null
import slog slog.quiet("debbug") slog.debbug("Hi!") slog.warning("Debbug?") slog.unquiet() slog.debbug("Aaaaaaaaa") with slog.quiet("debbug"): slog.debbug("Hello!") slog.info("Hi!") slog.info("Debbug?") slog.debbug("Hey.")
12.526316
26
0.651261
0
0
0
0
0
0
0
0
69
0.289916
cb4ecf77cafee160b1760b224789bf4aa4f08fa5
7,325
py
Python
features.py
sethnabarro/stance-detector
c201b91359ce9e6ad6523a5adb0587730fac3b9b
[ "MIT" ]
null
null
null
features.py
sethnabarro/stance-detector
c201b91359ce9e6ad6523a5adb0587730fac3b9b
[ "MIT" ]
null
null
null
features.py
sethnabarro/stance-detector
c201b91359ce9e6ad6523a5adb0587730fac3b9b
[ "MIT" ]
null
null
null
# coding=utf-8 """Functions for calculation of features""" from nltk import sentiment, tokenize import numpy as np import pandas as pd from sklearn.feature_extraction import text as text_sk from sklearn import preprocessing as preprocessing_sk import preprocessing def bag_of_words(tr_tweets, te_tweets, tr_targets=pd...
46.656051
99
0.690102
0
0
0
0
0
0
0
0
3,220
0.43959
cb4f9d88257810b11fcfe2f3d7d48b189b5318eb
328
py
Python
bflib/sizes.py
ChrisLR/BasicDungeonRL
b293d40bd9a0d3b7aec41b5e1d58441165997ff1
[ "MIT" ]
3
2017-10-28T11:28:38.000Z
2018-09-12T09:47:00.000Z
bflib/sizes.py
ChrisLR/BasicDungeonRL
b293d40bd9a0d3b7aec41b5e1d58441165997ff1
[ "MIT" ]
null
null
null
bflib/sizes.py
ChrisLR/BasicDungeonRL
b293d40bd9a0d3b7aec41b5e1d58441165997ff1
[ "MIT" ]
null
null
null
from enum import Enum class Size(Enum): VerySmall = "Very Small" Small = "Small" Medium = "Medium" Large = "Large" Huge = "Huge" feet_map = { Size.VerySmall: 1, Size.Small: 3, Size.Medium: 5, Size.Large: 10, Size.Huge: 20, } def size_in_feet(size): return feet_map.get(s...
14.26087
32
0.591463
126
0.384146
0
0
0
0
0
0
40
0.121951
cb50ca5b982e09c30bdecff282510af0ac7a5e35
629
py
Python
setup.py
davidjurgens/support
dd3c676a063998dd883abaab19afd23adb121895
[ "MIT" ]
4
2019-09-13T10:08:36.000Z
2021-03-07T15:53:50.000Z
setup.py
davidjurgens/support
dd3c676a063998dd883abaab19afd23adb121895
[ "MIT" ]
1
2020-04-21T14:02:57.000Z
2020-04-21T14:02:57.000Z
setup.py
davidjurgens/support
dd3c676a063998dd883abaab19afd23adb121895
[ "MIT" ]
null
null
null
import setuptools import os with open("README.md", "r") as fh: long_description = fh.read() setuptools.setup( name="supportr", version="0.1", author="Zijian Wang and David Jurgens", author_email="jurgens@umich.edu", description="Supportr", long_description=long_description, long_descri...
27.347826
65
0.666137
0
0
0
0
0
0
0
0
210
0.333863
cb50de8faedd2889100e35c361608289adda1cc5
1,095
py
Python
src/utils/common.py
neerajbafila/TransferLearning-pytorch
aa90420ecdaa82579ed766dee060745dc55f2586
[ "MIT" ]
null
null
null
src/utils/common.py
neerajbafila/TransferLearning-pytorch
aa90420ecdaa82579ed766dee060745dc55f2586
[ "MIT" ]
null
null
null
src/utils/common.py
neerajbafila/TransferLearning-pytorch
aa90420ecdaa82579ed766dee060745dc55f2586
[ "MIT" ]
null
null
null
import logging import os from zipfile import ZipFile import yaml from pathlib import Path logging.basicConfig( filename=os.path.join("Logs", "running.log"), format="[%(asctime)s: %(module)s: %(levelname)s]: %(message)s", level=logging.INFO, filemode="a" ) def read_yaml(config_path): with open(conf...
28.815789
72
0.6621
0
0
0
0
0
0
0
0
201
0.183562
cb52f297e432ab0e60e0a856d69e25f2ec7d762c
1,432
py
Python
svc/ivoiriansAPI.py
Ivoirians/hour-a-day
1225d6b4548fbf2eebdf28be7eae32c41754b520
[ "Apache-2.0" ]
null
null
null
svc/ivoiriansAPI.py
Ivoirians/hour-a-day
1225d6b4548fbf2eebdf28be7eae32c41754b520
[ "Apache-2.0" ]
null
null
null
svc/ivoiriansAPI.py
Ivoirians/hour-a-day
1225d6b4548fbf2eebdf28be7eae32c41754b520
[ "Apache-2.0" ]
null
null
null
import os import redis import code import urlparse import json from werkzeug.wrappers import Request, Response from werkzeug.routing import Map, Rule from werkzeug.exceptions import HTTPException, NotFound from werkzeug.wsgi import SharedDataMiddleware from werkzeug.utils import redirect from jinja2 import Environment,...
26.518519
100
0.773743
0
0
0
0
0
0
0
0
194
0.135475
cb53bb0ef01ccf5af589daed69e669358bd1faa4
1,714
py
Python
bin/val2rank.py
MichaelMW/crispy
44a076bd90078f773a58c1e83e8d0185ac2eebfd
[ "MIT" ]
1
2019-06-28T21:14:07.000Z
2019-06-28T21:14:07.000Z
bin/val2rank.py
MichaelMW/crispy
44a076bd90078f773a58c1e83e8d0185ac2eebfd
[ "MIT" ]
null
null
null
bin/val2rank.py
MichaelMW/crispy
44a076bd90078f773a58c1e83e8d0185ac2eebfd
[ "MIT" ]
null
null
null
#!/usr/bin/env python ##### convert values to ranks, tie breaker as average ##### from __future__ import division from sys import argv, stdin, stdout from signal import signal, SIGPIPE, SIG_DFL import argparse signal(SIGPIPE, SIG_DFL) # parse args parser = argparse.ArgumentParser() parser.add_argument("-i", "--inVal...
33.607843
87
0.616103
0
0
0
0
0
0
0
0
334
0.194866
cb56bcf8fe68538776f3fb4e542fc3f89b7ad574
414
py
Python
SAplatform/SAcore/migrations/0009_auto_20190529_2231.py
ThankPan/SA_Backend
9aecd5950a9170fff264278eded9ab37ee35187b
[ "MIT" ]
2
2019-05-22T09:16:51.000Z
2019-05-29T10:26:12.000Z
SAplatform/SAcore/migrations/0009_auto_20190529_2231.py
ThankPan/SA_Backend
9aecd5950a9170fff264278eded9ab37ee35187b
[ "MIT" ]
null
null
null
SAplatform/SAcore/migrations/0009_auto_20190529_2231.py
ThankPan/SA_Backend
9aecd5950a9170fff264278eded9ab37ee35187b
[ "MIT" ]
null
null
null
# Generated by Django 2.0.6 on 2019-05-29 14:31 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('SAcore', '0008_user_avator'), ] operations = [ migrations.AlterField( model_name='user', name='avator', ...
21.789474
88
0.608696
321
0.775362
0
0
0
0
0
0
114
0.275362
cb575e0025f5490ee367cec528d88472fed65faf
2,121
py
Python
crons/tests/test_CLI_system_stats.py
j9ac9k/navitron
efe7fba739037da7cc35e34dbe10d7d292260860
[ "MIT" ]
2
2018-07-22T18:09:44.000Z
2021-06-20T19:09:33.000Z
crons/tests/test_CLI_system_stats.py
j9ac9k/navitron
efe7fba739037da7cc35e34dbe10d7d292260860
[ "MIT" ]
4
2017-10-24T22:45:29.000Z
2018-12-19T17:19:46.000Z
crons/tests/test_CLI_system_stats.py
j9ac9k/navitron
efe7fba739037da7cc35e34dbe10d7d292260860
[ "MIT" ]
null
null
null
"""test_CLI_system_stats.py: tests expected behavior for CLI application""" from os import path import pytest from plumbum import local import pandas as pd import navitron_crons.exceptions as exceptions import navitron_crons._version as _version import navitron_crons.navitron_system_stats as navitron_system_stats im...
28.662162
82
0.69967
535
0.25224
0
0
0
0
0
0
577
0.272041
cb5819de6ef04c884c9b16d14543be6dc4d97431
6,414
py
Python
examples/example_envSampling.py
zmorrell-sand/WDRT
5a28ef268a1ea7431bdba5bc2ac02d03f39ab608
[ "Apache-2.0" ]
null
null
null
examples/example_envSampling.py
zmorrell-sand/WDRT
5a28ef268a1ea7431bdba5bc2ac02d03f39ab608
[ "Apache-2.0" ]
null
null
null
examples/example_envSampling.py
zmorrell-sand/WDRT
5a28ef268a1ea7431bdba5bc2ac02d03f39ab608
[ "Apache-2.0" ]
null
null
null
import numpy as np import WDRT.ESSC as ESSC import copy import matplotlib.pyplot as plt # Create buoy object, in this case for Station #46022 buoy46022 = ESSC.Buoy('46022', 'NDBC') # Read data from ndbc.noaa.gov #buoy46022.fetchFromWeb() #buoy46022.saveAsTxt(savePath = "./Data") #buoy46022.saveAsH5('NDBC46022.h5') #...
43.931507
96
0.778609
0
0
0
0
0
0
0
0
2,507
0.390864
cb5837210fd058388e872dafed24e5a5f22d8292
386
py
Python
beamr/parsers/generic.py
teonistor/py-beams
2b954bc000607cc2b4cd56ac080da90c889f1643
[ "MIT" ]
3
2019-11-11T13:25:34.000Z
2021-02-04T14:15:12.000Z
beamr/parsers/generic.py
teonistor/beamr
2b954bc000607cc2b4cd56ac080da90c889f1643
[ "MIT" ]
null
null
null
beamr/parsers/generic.py
teonistor/beamr
2b954bc000607cc2b4cd56ac080da90c889f1643
[ "MIT" ]
null
null
null
''' Functionality common to all parsers Created on 1 Feb 2018 @author: Teodor G Nistor @copyright: 2018 Teodor G Nistor @license: MIT License ''' from beamr.debug import warn def p_nil(p): # An empty production 'nil :' pass def p_error(t): # Parsing error try: warn("Syntax error at toke...
17.545455
52
0.647668
0
0
0
0
0
0
0
0
245
0.634715
cb59d14e450dc1448658413d643fbebe5f530c2e
1,553
py
Python
forklib/iterator.py
leenr/forklib
08e2bf1aed41c1247ddf1f859838fa4b2b93b939
[ "Apache-2.0" ]
null
null
null
forklib/iterator.py
leenr/forklib
08e2bf1aed41c1247ddf1f859838fa4b2b93b939
[ "Apache-2.0" ]
null
null
null
forklib/iterator.py
leenr/forklib
08e2bf1aed41c1247ddf1f859838fa4b2b93b939
[ "Apache-2.0" ]
null
null
null
import pickle import struct from contextlib import ExitStack from tempfile import NamedTemporaryFile from .forking import fork, get_id def skip(iterable, skip, shift): for idx, item in enumerate(iterable): if idx % skip != shift: continue yield item _HEADER_FORMAT = '>Q' _HEADER_SIZE...
25.459016
77
0.588538
0
0
1,017
0.654862
0
0
0
0
11
0.007083
cb5ae8d3cb0553fb8e1a0c3762332d78fda9c262
438
py
Python
st201712-1.py
terry-gjt/csp_python
ecab7c3302fac3db912b7d3734fa4078f09b2b46
[ "MIT" ]
1
2021-11-24T11:11:00.000Z
2021-11-24T11:11:00.000Z
st201712-1.py
terry-gjt/csp_python
ecab7c3302fac3db912b7d3734fa4078f09b2b46
[ "MIT" ]
null
null
null
st201712-1.py
terry-gjt/csp_python
ecab7c3302fac3db912b7d3734fa4078f09b2b46
[ "MIT" ]
null
null
null
# 最小差值 #   给定n个数,请找出其中相差(差的绝对值)最小的两个数,输出它们的差值的绝对值。 def st171201(): n= int(input()) numbers = list(map(int, input().split())) numbers.sort() # print(numbers) before=numbers[1] temp = abs(before-numbers[0]) for i in numbers[2:]: # print(temp,before,i,abs(i-before)) if abs(i-bef...
25.764706
45
0.582192
0
0
0
0
0
0
0
0
199
0.378327
cb5bf325d16c4ad64611039b02ce9e3296d30e86
279
py
Python
niaaml_gui/progress_bar.py
zStupan/NiaAML-GUI
fff3dd3e5ae1ec26df77d952970d90e1b26a0cf3
[ "MIT" ]
2
2020-12-02T19:27:03.000Z
2021-12-23T11:56:02.000Z
niaaml_gui/progress_bar.py
zStupan/NiaAML-GUI
fff3dd3e5ae1ec26df77d952970d90e1b26a0cf3
[ "MIT" ]
8
2020-12-08T21:50:48.000Z
2021-11-23T09:47:43.000Z
niaaml_gui/progress_bar.py
zStupan/NiaAML-GUI
fff3dd3e5ae1ec26df77d952970d90e1b26a0cf3
[ "MIT" ]
3
2021-04-21T09:42:57.000Z
2021-11-22T15:47:08.000Z
from PyQt5 import QtCore from PyQt5.QtWidgets import QProgressBar class ProgressBar(QProgressBar): def __init__(self): super(ProgressBar, self).__init__() self.setTextVisible(True) self.setMaximum(100) self.setAlignment(QtCore.Qt.AlignCenter)
31
48
0.724014
212
0.759857
0
0
0
0
0
0
0
0
cb5c75b075a2566834211447cb78fb5a7db8b5cf
11,655
py
Python
virtualenv_tools.py
benbariteau/virtualenv-tools
c355a0b77f77b125c58f7576e47ccff727c47103
[ "BSD-3-Clause" ]
null
null
null
virtualenv_tools.py
benbariteau/virtualenv-tools
c355a0b77f77b125c58f7576e47ccff727c47103
[ "BSD-3-Clause" ]
null
null
null
virtualenv_tools.py
benbariteau/virtualenv-tools
c355a0b77f77b125c58f7576e47ccff727c47103
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python """ move-virtualenv ~~~~~~~~~~~~~~~ A helper script that moves virtualenvs to a new location. It only supports POSIX based virtualenvs and at the moment. :copyright: (c) 2012 by Fireteam Ltd. :license: BSD, see LICENSE for more details. """ from __future__ import print_f...
32.019231
79
0.618018
188
0.01613
0
0
0
0
0
0
2,504
0.214843
cb5c89e48bd2c30aa38a5010bbb42d8492152c7a
664
py
Python
icq/event.py
azalio/python-icq-bot
b5ab8306d2abf8c259da71db1a3195c842d51110
[ "MIT" ]
null
null
null
icq/event.py
azalio/python-icq-bot
b5ab8306d2abf8c259da71db1a3195c842d51110
[ "MIT" ]
null
null
null
icq/event.py
azalio/python-icq-bot
b5ab8306d2abf8c259da71db1a3195c842d51110
[ "MIT" ]
null
null
null
from enum import Enum class EventType(Enum): MY_INFO = "myInfo" PRESENCE = "presence" BUDDY_LIST = "buddylist" TYPING = "typing" IM = "im" DATA_IM = "dataIM" CLIENT_ERROR = "clientError" SESSION_ENDED = "sessionEnded" OFFLINE_IM = "offlineIM" SENT_IM = "sentIM" SEND_DATA_IM...
22.896552
53
0.64759
636
0.957831
0
0
0
0
0
0
171
0.25753
cb5c97743b3ff2a34f8214c80bd98f52c642c0dc
4,730
py
Python
AwsGameKit/Resources/cloudResources/functions/gamesaving/UpdateSlotMetadata/index.py
aws/aws-gamekit-unreal
72ecf02081e06f2926a5db9269e551f86df9bd10
[ "Apache-2.0" ]
17
2022-03-23T18:30:33.000Z
2022-03-31T19:59:27.000Z
AwsGameKit/Resources/cloudResources/functions/gamesaving/UpdateSlotMetadata/index.py
aws/aws-gamekit-unreal
72ecf02081e06f2926a5db9269e551f86df9bd10
[ "Apache-2.0" ]
null
null
null
AwsGameKit/Resources/cloudResources/functions/gamesaving/UpdateSlotMetadata/index.py
aws/aws-gamekit-unreal
72ecf02081e06f2926a5db9269e551f86df9bd10
[ "Apache-2.0" ]
4
2022-03-24T00:52:16.000Z
2022-03-28T18:09:08.000Z
# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. # SPDX-License-Identifier: Apache-2.0 import boto3 import botocore import logging import os import urllib.parse from typing import Any from gamekithelpers import ddb # Custom Types: S3Object = Any # Magic Values: ISO_8601_FORMAT = '%Y-%m-%dT%H:%M:%...
36.953125
123
0.68203
0
0
0
0
0
0
0
0
2,159
0.456448
cb5fa397d201436a1a4389a0c1366f5ef179cacd
1,533
py
Python
SimTracker/TrackerMaterialAnalysis/test/listGroups.py
SWuchterl/cmssw
769b4a7ef81796579af7d626da6039dfa0347b8e
[ "Apache-2.0" ]
6
2017-09-08T14:12:56.000Z
2022-03-09T23:57:01.000Z
SimTracker/TrackerMaterialAnalysis/test/listGroups.py
SWuchterl/cmssw
769b4a7ef81796579af7d626da6039dfa0347b8e
[ "Apache-2.0" ]
545
2017-09-19T17:10:19.000Z
2022-03-07T16:55:27.000Z
SimTracker/TrackerMaterialAnalysis/test/listGroups.py
SWuchterl/cmssw
769b4a7ef81796579af7d626da6039dfa0347b8e
[ "Apache-2.0" ]
14
2017-10-04T09:47:21.000Z
2019-10-23T18:04:45.000Z
from __future__ import print_function #! /usr/bin/env cmsRun import sys import FWCore.ParameterSet.Config as cms from SimTracker.TrackerMaterialAnalysis.trackingMaterialVarParsing import options process = cms.Process("MaterialAnalyser") if options.geometry == 'run2': process.load('Configuration.Geometry.Geometr...
40.342105
139
0.785388
0
0
0
0
0
0
0
0
676
0.440965
cb613677a3ee27a118aee3be62a3a2fe9492cc91
2,515
py
Python
src/main/resources/test/test_python_server.py
BlindConferenceCode/s-RDF2vec
4cbd260f083f92af49380a57e06c9a27e9bde977
[ "MIT" ]
null
null
null
src/main/resources/test/test_python_server.py
BlindConferenceCode/s-RDF2vec
4cbd260f083f92af49380a57e06c9a27e9bde977
[ "MIT" ]
null
null
null
src/main/resources/test/test_python_server.py
BlindConferenceCode/s-RDF2vec
4cbd260f083f92af49380a57e06c9a27e9bde977
[ "MIT" ]
null
null
null
# This unit test checks the python_server.py # Run `pytest` in the root directory of the jRDF2vec project (where the pom.xml resides). import threading import python_server as server import time import requests from pathlib import Path uri_prefix = "http://localhost:1808/" class ServerThread(threading.Thread): ...
28.258427
89
0.667594
388
0.154274
0
0
0
0
0
0
677
0.269185
cb6231bee43feb497d0b9c5732c4d882c9add250
1,041
py
Python
SOLVED/counting-bits.py
Roxxum/Coding-Challenges
4212653e9687d002586249df8bb42d17b398f667
[ "MIT" ]
null
null
null
SOLVED/counting-bits.py
Roxxum/Coding-Challenges
4212653e9687d002586249df8bb42d17b398f667
[ "MIT" ]
null
null
null
SOLVED/counting-bits.py
Roxxum/Coding-Challenges
4212653e9687d002586249df8bb42d17b398f667
[ "MIT" ]
null
null
null
""" Given an integer n, return an array ans of length n + 1 such that for each i (0 <= i <= n), ans[i] is the number of 1's in the binary representation of i.   Example 1: Input: n = 2 Output: [0,1,1] Explanation: 0 --> 0 1 --> 1 2 --> 10 Example 2: Input: n = 5 Output: [0,1,1,2,1,2] Explanation: 0 --> 0 1 --> 1 2 --...
18.927273
154
0.647454
0
0
0
0
0
0
0
0
814
0.777459
cb6279ec0b7ded0ba4cb59e073b1c143b3a2125e
2,197
py
Python
tests/test_contributors.py
chfw/gease
dc5e69840c368dab15e0929824a7c952bd7074c3
[ "MIT" ]
1
2019-01-12T19:39:35.000Z
2019-01-12T19:39:35.000Z
tests/test_contributors.py
chfw/gease
dc5e69840c368dab15e0929824a7c952bd7074c3
[ "MIT" ]
10
2017-10-20T07:24:49.000Z
2020-10-18T11:37:51.000Z
tests/test_contributors.py
chfw/gease
dc5e69840c368dab15e0929824a7c952bd7074c3
[ "MIT" ]
null
null
null
from mock import MagicMock, patch from nose.tools import eq_ from gease.contributors import EndPoint from gease.exceptions import NoGeaseConfigFound class TestPublish: @patch("gease.contributors.get_token") @patch("gease.contributors.Api.get_public_api") def test_all_contributors(self, fake_api, get_toke...
30.09589
75
0.549841
2,044
0.93036
0
0
2,009
0.914429
0
0
549
0.249886
cb62bf96d17a2cbe4ec9423845b5e3e251f64ba5
1,594
py
Python
visualizations/urls.py
IlyaLab/ISB-LSDF
897825832aabb819659bb5ad6f0b1df941619bc9
[ "Apache-2.0" ]
null
null
null
visualizations/urls.py
IlyaLab/ISB-LSDF
897825832aabb819659bb5ad6f0b1df941619bc9
[ "Apache-2.0" ]
null
null
null
visualizations/urls.py
IlyaLab/ISB-LSDF
897825832aabb819659bb5ad6f0b1df941619bc9
[ "Apache-2.0" ]
null
null
null
""" Copyright 2015, Institute for Systems Biology 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 w...
40.871795
81
0.700753
0
0
0
0
0
0
0
0
1,016
0.63739
cb62d1c69dc7705da42bb88388ff4a6278a5a329
2,913
py
Python
temp/oldFiles/provaCursorsTweet.py
JeyDi/Mispelling
e2a91178707532f4b00949bbf37fcd17671f1a08
[ "MIT" ]
1
2019-03-19T23:08:58.000Z
2019-03-19T23:08:58.000Z
temp/oldFiles/provaCursorsTweet.py
JeyDi/Mispelling
e2a91178707532f4b00949bbf37fcd17671f1a08
[ "MIT" ]
null
null
null
temp/oldFiles/provaCursorsTweet.py
JeyDi/Mispelling
e2a91178707532f4b00949bbf37fcd17671f1a08
[ "MIT" ]
null
null
null
import tweepy import re import string # Consumer keys and access tokens, used for OAuth consumer_key = "P5wTozEUuNOAJCXMajGnRcDs2" consumer_secret = "RB7p2JVEZxbodmRT3eaA32caonxpo5fS5DOKXcoTxEKJelTZys" access_token = "997065391644917761-mSZZ6gkTdLEOdDSOAFfu7clvJO4vQPq" access_token_secret = "MoAMNPZeAmYMwtjaopDrAs1njC...
37.346154
92
0.718503
0
0
0
0
0
0
0
0
1,193
0.409543
cb645b5cde2711211a9e1c6089b1e7f29a0ed5c0
8,529
py
Python
tools/test_balloon_dataset.py
superclass-FSIS/test
9bb2844c77704a609291135b75e94a794f235aa0
[ "Apache-2.0" ]
45
2021-04-09T12:52:44.000Z
2022-03-30T09:08:58.000Z
tools/test_balloon_dataset.py
superclass-FSIS/test
9bb2844c77704a609291135b75e94a794f235aa0
[ "Apache-2.0" ]
8
2021-06-29T07:47:07.000Z
2022-03-23T04:21:00.000Z
tools/test_balloon_dataset.py
superclass-FSIS/test
9bb2844c77704a609291135b75e94a794f235aa0
[ "Apache-2.0" ]
10
2021-05-23T05:48:29.000Z
2022-03-16T06:42:13.000Z
import json import os import cv2 import numpy as np import dutils.imageutils as diu import dutils.learnutils as dlu import torch, torchvision import dutils.simpleutils as dsu from detectron2.utils.logger import setup_logger from detectron2.utils import comm from detectron2 import model_zoo from detectron2.engine impor...
39.304147
140
0.680502
2,316
0.271544
0
0
1,975
0.231563
0
0
2,868
0.336265
cb65458f6c0cf5ce9fd7e7e10dc2952a2760f0a5
5,166
py
Python
src/data_processing/results_visualization.py
YoavLotem/NeuriteOutgrowth
253fe2d6ab024d905a7f245b052773c850b932c4
[ "MIT" ]
1
2022-03-29T09:59:47.000Z
2022-03-29T09:59:47.000Z
src/data_processing/results_visualization.py
YoavLotem/NeuriteOutgrowth
253fe2d6ab024d905a7f245b052773c850b932c4
[ "MIT" ]
null
null
null
src/data_processing/results_visualization.py
YoavLotem/NeuriteOutgrowth
253fe2d6ab024d905a7f245b052773c850b932c4
[ "MIT" ]
null
null
null
import numpy as np import matplotlib.pyplot as plt import seaborn as sns def get_location(well_name, char2num): """ calculates for a well's name its row and column indices in an array that represents the plate. Parameters ---------- well_name: str the name of the well in the form "B - 02" ...
34.211921
120
0.661247
0
0
0
0
0
0
0
0
2,568
0.497096
cb6614d079e45fa5d3bb1ee408477e4669627542
53,973
py
Python
bindings/java/gen_jni.py
protocols-comnet/openwebrtc
49e507623133f8faf10c7c99cc60f2c41c9847d2
[ "BSD-2-Clause" ]
1
2015-01-26T18:53:22.000Z
2015-01-26T18:53:22.000Z
bindings/java/gen_jni.py
protocols-comnet/openwebrtc
49e507623133f8faf10c7c99cc60f2c41c9847d2
[ "BSD-2-Clause" ]
null
null
null
bindings/java/gen_jni.py
protocols-comnet/openwebrtc
49e507623133f8faf10c7c99cc60f2c41c9847d2
[ "BSD-2-Clause" ]
2
2020-09-01T07:00:35.000Z
2020-09-27T01:13:23.000Z
#!/usr/bin/env python -B # Copyright (c) 2014, Ericsson AB. All rights reserved. # # Redistribution and use in source and binary forms, with or without modification, # are permitted provided that the following conditions are met: # # 1. Redistributions of source code must retain the above copyright notice, this # list...
30.649063
171
0.528857
19,123
0.354307
0
0
1,052
0.019491
0
0
21,054
0.390084
cb665aa274b71e0f1b9621b1df3278784b362d8f
223
py
Python
azdashboard/config/environments/production.py
alinlacea/azdashboard
3ca41bfdac21c324789937c60491dcbb1d70b05c
[ "MIT" ]
null
null
null
azdashboard/config/environments/production.py
alinlacea/azdashboard
3ca41bfdac21c324789937c60491dcbb1d70b05c
[ "MIT" ]
null
null
null
azdashboard/config/environments/production.py
alinlacea/azdashboard
3ca41bfdac21c324789937c60491dcbb1d70b05c
[ "MIT" ]
null
null
null
# server backend server = 'cherrypy' # debug error messages debug = False # auto-reload reloader = False # database url db_url = 'postgresql://user:pass@localhost/dbname' # echo database engine messages db_echo = False
14.866667
50
0.744395
0
0
0
0
0
0
0
0
147
0.659193
cb66f50e920c621e6d847f079089141e524ab650
880
py
Python
test/functional_requirements/fault_tolerance/REBUILD_TRIGGERED_RIGHT_AFTER_ARRAY_MOUNTED.py
so931/poseidonos
2aa82f26bfbd0d0aee21cd0574779a655634f08c
[ "BSD-3-Clause" ]
38
2021-04-06T03:20:55.000Z
2022-03-02T09:33:28.000Z
test/functional_requirements/fault_tolerance/REBUILD_TRIGGERED_RIGHT_AFTER_ARRAY_MOUNTED.py
so931/poseidonos
2aa82f26bfbd0d0aee21cd0574779a655634f08c
[ "BSD-3-Clause" ]
19
2021-04-08T02:27:44.000Z
2022-03-23T00:59:04.000Z
test/functional_requirements/fault_tolerance/REBUILD_TRIGGERED_RIGHT_AFTER_ARRAY_MOUNTED.py
so931/poseidonos
2aa82f26bfbd0d0aee21cd0574779a655634f08c
[ "BSD-3-Clause" ]
28
2021-04-08T04:39:18.000Z
2022-03-24T05:56:00.000Z
#!/usr/bin/env python3 import subprocess import os import sys sys.path.append("../") sys.path.append("../../system/lib/") sys.path.append("../array/") import json_parser import pos import pos_util import cli import api import json import time import CREATE_ARRAY_BASIC ARRAYNAME = CREATE_ARRAY_BASIC.ARRAYNAME def exec...
24.444444
78
0.7125
0
0
0
0
0
0
0
0
95
0.107955
cb67393408279dfc1bb2c5b77e787a0b82d4c97b
476
py
Python
newspaper/newspaper/news/managers.py
luisfer85/newspaper
7829eede4ef878562e54ee591bb61862f6fd6ac8
[ "Apache-2.0" ]
null
null
null
newspaper/newspaper/news/managers.py
luisfer85/newspaper
7829eede4ef878562e54ee591bb61862f6fd6ac8
[ "Apache-2.0" ]
null
null
null
newspaper/newspaper/news/managers.py
luisfer85/newspaper
7829eede4ef878562e54ee591bb61862f6fd6ac8
[ "Apache-2.0" ]
null
null
null
from datetime import datetime from django.db import models from django.db.models.query import QuerySet class BaseNewsQuerySet(QuerySet): def published(self): return self.filter(publish_date__lte=datetime.now()).order_by('publish_date') class BaseNewsManager(models.Manager): def get_...
23.8
86
0.714286
356
0.747899
0
0
0
0
0
0
14
0.029412
cb67e96b671f73979043a0074a5a15e47b3714e9
5,885
py
Python
pygem/oggm_compat.py
lilianschuster/PyGEM
c805d09960f937fe6e35cdd1587f9089d4bec6b8
[ "MIT" ]
null
null
null
pygem/oggm_compat.py
lilianschuster/PyGEM
c805d09960f937fe6e35cdd1587f9089d4bec6b8
[ "MIT" ]
null
null
null
pygem/oggm_compat.py
lilianschuster/PyGEM
c805d09960f937fe6e35cdd1587f9089d4bec6b8
[ "MIT" ]
null
null
null
from oggm import cfg, utils from oggm import workflow from oggm import tasks from oggm.cfg import SEC_IN_YEAR from oggm.core.massbalance import MassBalanceModel import numpy as np import pandas as pd import netCDF4 def single_flowline_glacier_directory(rgi_id, reset=False, prepro_border=80): """Prepare a GlacierD...
31.303191
79
0.625828
2,693
0.457604
0
0
0
0
0
0
2,637
0.448088
cb67f6f07d17c1715cbe8c59cbc66eb52c3ad29b
6,601
py
Python
plotting/single_trials.py
PFMassiani/vibly
5e552cb2ed375d5cd378b92de2f2473485211f2f
[ "MIT" ]
5
2020-06-08T09:44:44.000Z
2022-03-12T06:13:10.000Z
plotting/single_trials.py
PFMassiani/vibly
5e552cb2ed375d5cd378b92de2f2473485211f2f
[ "MIT" ]
7
2019-09-27T07:05:34.000Z
2020-04-27T14:15:07.000Z
plotting/single_trials.py
PFMassiani/vibly
5e552cb2ed375d5cd378b92de2f2473485211f2f
[ "MIT" ]
6
2019-10-02T09:55:10.000Z
2021-03-08T13:55:21.000Z
import numpy as np import matplotlib.pyplot as plt # colors corresponding to initial flight, stance, second flight colors = ['k', 'b', 'g'] ### The attributes of sol are: ## sol.t : series of time-points at which the solution was calculated ## sol.y : simulation results, size 6 x times ## sol.t_events : list of t...
32.2
97
0.645054
0
0
0
0
0
0
0
0
1,527
0.231329
cb69d8258327daf341149548a2557f2a2fe05f55
111,710
py
Python
ultracart/api/order_api.py
UltraCart/rest_api_v2_sdk_python
d734ea13fabc7a57872ff68bac06861edb8fd882
[ "Apache-2.0" ]
1
2018-03-15T16:56:23.000Z
2018-03-15T16:56:23.000Z
ultracart/api/order_api.py
UltraCart/rest_api_v2_sdk_python
d734ea13fabc7a57872ff68bac06861edb8fd882
[ "Apache-2.0" ]
null
null
null
ultracart/api/order_api.py
UltraCart/rest_api_v2_sdk_python
d734ea13fabc7a57872ff68bac06861edb8fd882
[ "Apache-2.0" ]
null
null
null
# coding: utf-8 """ UltraCart Rest API V2 UltraCart REST API Version 2 # noqa: E501 OpenAPI spec version: 2.0.0 Contact: support@ultracart.com Generated by: https://github.com/swagger-api/swagger-codegen.git """ from __future__ import absolute_import import re # noqa: F401 # python 2 and py...
44.737685
762
0.631403
111,254
0.995918
0
0
394
0.003527
0
0
62,982
0.563799
cb6bafc6882d4075105c5df412ef7ffb30632ec6
7,753
py
Python
project-vitas.py
bertmiller/nucypher-data-sharing-PoC
fad28f93277aff3c46e4073f1a9c812c6e6d8b4c
[ "Apache-2.0" ]
1
2020-08-25T18:05:17.000Z
2020-08-25T18:05:17.000Z
project-vitas.py
bertmiller/nucypher-data-sharing-PoC
fad28f93277aff3c46e4073f1a9c812c6e6d8b4c
[ "Apache-2.0" ]
null
null
null
project-vitas.py
bertmiller/nucypher-data-sharing-PoC
fad28f93277aff3c46e4073f1a9c812c6e6d8b4c
[ "Apache-2.0" ]
1
2020-08-25T18:05:18.000Z
2020-08-25T18:05:18.000Z
import os import sys import json import shutil import ipfsapi import base64 import datetime import maya from twisted.logger import globalLogPublisher from umbral.keys import UmbralPublicKey ### NuCypher ### from nucypher.characters.lawful import Alice, Bob, Ursula from nucypher.config.characters import ...
32.57563
148
0.582871
0
0
0
0
0
0
0
0
2,585
0.333419
cb6bfa1a351710813d824ef3686ff4624c0467f4
70,114
py
Python
SublimeText3_3176/Data/Packages/SublimeCodeIntel-master/libs/codeintel2/pythoncile1.py
xiexie1993/Tool_Sublime_Text3_for_Windows
51b11ac2d7df36242d68b3b5f85af5f2a8c550e2
[ "RSA-MD" ]
1
2018-06-23T08:07:39.000Z
2018-06-23T08:07:39.000Z
SublimeText3_3176/Data/Packages/SublimeCodeIntel-master/libs/codeintel2/pythoncile1.py
xiexie1993/Tool_Sublime_Text3_for_Windows
51b11ac2d7df36242d68b3b5f85af5f2a8c550e2
[ "RSA-MD" ]
null
null
null
SublimeText3_3176/Data/Packages/SublimeCodeIntel-master/libs/codeintel2/pythoncile1.py
xiexie1993/Tool_Sublime_Text3_for_Windows
51b11ac2d7df36242d68b3b5f85af5f2a8c550e2
[ "RSA-MD" ]
null
null
null
#!/usr/bin/env python # Copyright (c) 2004-2006 ActiveState Software Inc. # # Contributors: # Trent Mick (TrentM@ActiveState.com) """ pythoncile - a Code Intelligence Language Engine for the Python language Module Usage: from pythoncile import scan mtime = os.stat("foo.py")[stat.ST_MTIME] ...
39.257559
86
0.53306
45,816
0.65345
0
0
0
0
0
0
23,940
0.341444
cb6da2d343e562805f2cca4c8548848e2468245e
2,092
py
Python
Perceptron/plot.py
hduliufan/work
951a69aad5de3387c26fabe417a939349def3df6
[ "Apache-2.0" ]
null
null
null
Perceptron/plot.py
hduliufan/work
951a69aad5de3387c26fabe417a939349def3df6
[ "Apache-2.0" ]
null
null
null
Perceptron/plot.py
hduliufan/work
951a69aad5de3387c26fabe417a939349def3df6
[ "Apache-2.0" ]
null
null
null
import numpy as np class perceptron(object): #eta learning rata #n_iter times def __init__(self,eta,n_iter): self.eta=eta self.n_iter=n_iter def fit(self,x,y): ''' x=ndarray(n_samples,n_features),training data y=ndarray(n_samples),labels returns se...
27.526316
80
0.605163
1,083
0.517686
0
0
0
0
0
0
550
0.262906
cb6dd223fbcda5dd89b671bf21c46619bf3da3ff
2,552
py
Python
src/pipelines/epidemiology/sd_humdata.py
chrismayemba/covid-19-open-data
cacecb05cd8277f8e61b6e7932915826f41af24b
[ "Apache-2.0" ]
430
2020-07-23T23:45:20.000Z
2022-03-25T09:44:28.000Z
src/pipelines/epidemiology/sd_humdata.py
chrismayemba/covid-19-open-data
cacecb05cd8277f8e61b6e7932915826f41af24b
[ "Apache-2.0" ]
222
2020-07-30T11:45:05.000Z
2022-02-22T18:58:11.000Z
src/pipelines/epidemiology/sd_humdata.py
chrismayemba/covid-19-open-data
cacecb05cd8277f8e61b6e7932915826f41af24b
[ "Apache-2.0" ]
123
2020-07-30T09:18:47.000Z
2022-02-24T18:08:17.000Z
# Copyright 2020 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, ...
36.457143
131
0.641066
1,806
0.70768
0
0
0
0
0
0
1,490
0.583856
cb6e1054c6b990606b9dd982aae2049b69146307
6,990
py
Python
posthog/helpers/session_recording.py
lharress/posthog
73809d54b14ffc1b6ad6f600e0e4f06ab3090cb1
[ "MIT" ]
null
null
null
posthog/helpers/session_recording.py
lharress/posthog
73809d54b14ffc1b6ad6f600e0e4f06ab3090cb1
[ "MIT" ]
null
null
null
posthog/helpers/session_recording.py
lharress/posthog
73809d54b14ffc1b6ad6f600e0e4f06ab3090cb1
[ "MIT" ]
null
null
null
import base64 import dataclasses import gzip import json from collections import defaultdict from typing import DefaultDict, Dict, Generator, List, Optional from sentry_sdk.api import capture_exception, capture_message from posthog.models import utils Event = Dict SnapshotData = Dict @dataclasses.dataclass class P...
36.40625
127
0.669957
86
0.012303
2,051
0.293419
109
0.015594
0
0
1,393
0.199285
cb6e6dd109fe14cd4863e7a3ef1390182e64eed7
3,142
py
Python
lexical-parse-float/etc/limits.py
sjurajpuchky/rust-lexical
827dd8722967030bfe75cfbd786f0e160ffb9c0c
[ "Apache-2.0", "MIT" ]
249
2018-12-15T22:10:42.000Z
2022-03-28T05:43:13.000Z
lexical-parse-float/etc/limits.py
sjurajpuchky/rust-lexical
827dd8722967030bfe75cfbd786f0e160ffb9c0c
[ "Apache-2.0", "MIT" ]
76
2018-11-25T03:41:43.000Z
2022-03-15T18:57:00.000Z
lexical-parse-float/etc/limits.py
sjurajpuchky/rust-lexical
827dd8722967030bfe75cfbd786f0e160ffb9c0c
[ "Apache-2.0", "MIT" ]
35
2018-12-02T19:35:28.000Z
2022-03-12T23:37:39.000Z
#!/usr/bin/env python3 """ Generate the numeric limits for a given radix. This is used for the fast-path algorithms, to calculate the maximum number of digits or exponent bits that can be exactly represented as a native value. """ import math def is_pow2(value): '''Calculate if a value is a power of 2.''' ...
30.504854
82
0.619669
0
0
0
0
0
0
0
0
1,709
0.543921
cb71623c916418a16c084ab270fc77fa09bde0bc
1,077
py
Python
importer/management/commands/rebuild_variant_summary.py
brand-fabian/varfish-server
6a084d891d676ff29355e72a29d4f7b207220283
[ "MIT" ]
14
2019-09-30T12:44:17.000Z
2022-02-04T14:45:16.000Z
importer/management/commands/rebuild_variant_summary.py
brand-fabian/varfish-server
6a084d891d676ff29355e72a29d4f7b207220283
[ "MIT" ]
244
2021-03-26T15:13:15.000Z
2022-03-31T15:48:04.000Z
importer/management/commands/rebuild_variant_summary.py
brand-fabian/varfish-server
6a084d891d676ff29355e72a29d4f7b207220283
[ "MIT" ]
8
2020-05-19T21:55:13.000Z
2022-03-31T07:02:58.000Z
"""Django command for rebuilding cohort statistics after import.""" from django.core.management.base import BaseCommand from django.db import transaction from ...tasks import refresh_variants_smallvariantsummary import variants.models as models class Command(BaseCommand): """Implementation of rebuilding variant...
34.741935
100
0.692665
827
0.767874
0
0
439
0.407614
0
0
437
0.405757
cb7491736bfbd22fd0d03bf388c942817f7860a2
299
py
Python
Python/9. Errors and Exceptions/exercise2.py
mukeshmithrakumar/HackerRankSolutions
cd9e71be5e8703287b9f4efc042df8827175af1b
[ "MIT" ]
12
2019-10-29T09:49:26.000Z
2022-02-21T09:43:41.000Z
Python/9. Errors and Exceptions/exercise2.py
ozturkosu/HackerRankSolutions
cd9e71be5e8703287b9f4efc042df8827175af1b
[ "MIT" ]
null
null
null
Python/9. Errors and Exceptions/exercise2.py
ozturkosu/HackerRankSolutions
cd9e71be5e8703287b9f4efc042df8827175af1b
[ "MIT" ]
10
2019-12-22T03:18:50.000Z
2021-09-23T16:55:25.000Z
# Incorrect Regex "https://www.hackerrank.com/challenges/incorrect-regex/problem" # Enter your code here. Read input from STDIN. Print output to STDOUT import re for i in range(int(input())): try: re.compile(input()) print("True") except ValueError: print("False")
24.916667
81
0.665552
0
0
0
0
0
0
0
0
163
0.545151
cb7497c601659c58ede1aada3b1214314ef1b050
634
py
Python
Lectures/week_12/demo/api/urls.py
diable201/WEB-development
370bd731b9a65a1658033a60c63abece11d4e259
[ "MIT" ]
1
2022-02-18T15:44:46.000Z
2022-02-18T15:44:46.000Z
Lectures/week_12/demo/api/urls.py
diable201/WEB-development
370bd731b9a65a1658033a60c63abece11d4e259
[ "MIT" ]
null
null
null
Lectures/week_12/demo/api/urls.py
diable201/WEB-development
370bd731b9a65a1658033a60c63abece11d4e259
[ "MIT" ]
1
2021-03-26T13:55:52.000Z
2021-03-26T13:55:52.000Z
from django.urls import path from rest_framework_jwt.views import obtain_jwt_token from api.views import category_list, category_detail, CategoryListAPIView, CategoryDetailAPIView, \ ProductListAPIView, ProductDetailAPIView urlpatterns = [ # path('categories/', category_list), # path('categories/<int:cat...
28.818182
99
0.742902
0
0
0
0
0
0
0
0
167
0.263407
cb759e2270367c9453c4335425e65154c101afd0
6,340
py
Python
igibson/examples/learning/demo_replaying_batch.py
StanfordVL/InteractiveGibsonEnv
58ac14cf62949008b6851a5a95602cd5084edffd
[ "MIT" ]
51
2019-06-17T06:01:40.000Z
2020-03-29T03:34:20.000Z
igibson/examples/learning/demo_replaying_batch.py
StanfordVL/InteractiveGibsonEnv
58ac14cf62949008b6851a5a95602cd5084edffd
[ "MIT" ]
25
2019-06-28T18:39:03.000Z
2020-03-19T17:53:55.000Z
igibson/examples/learning/demo_replaying_batch.py
StanfordVL/InteractiveGibsonEnv
58ac14cf62949008b6851a5a95602cd5084edffd
[ "MIT" ]
12
2019-08-01T21:03:44.000Z
2020-04-01T11:05:18.000Z
""" BEHAVIOR demo batch analysis script """ import argparse import json import logging import os from pathlib import Path import pandas as pd import igibson from igibson.examples.learning.demo_replaying_example import replay_demo def replay_demo_batch( demo_dir, demo_manifest, out_dir, get_callbacks...
39.135802
118
0.659621
0
0
0
0
0
0
0
0
2,444
0.385489
cb779cc66f314d2d2731877166e373742311a2fe
428
py
Python
editor/importme.py
Amazeryogo/surf-exel
0d6a43a7ba2b059f61405db846e546308a035733
[ "MIT" ]
3
2020-08-12T05:59:47.000Z
2020-11-08T00:01:04.000Z
editor/importme.py
Amazeryogo/surf-exel
0d6a43a7ba2b059f61405db846e546308a035733
[ "MIT" ]
8
2020-08-19T06:24:06.000Z
2020-10-27T04:37:46.000Z
editor/importme.py
Amazeryogo/surf-exel
0d6a43a7ba2b059f61405db846e546308a035733
[ "MIT" ]
1
2020-10-25T13:35:17.000Z
2020-10-25T13:35:17.000Z
from Tkinter import * from Tkinter import filedialog, simpledialog from Tkinter import messagebox from editor.settings import backgroundcolor as bc from editor.settings import forgroundcolor as fc from editor.settings import back as b from editor.settings import fore as f from editor.settings import size from editor.se...
23.777778
49
0.831776
0
0
0
0
0
0
0
0
26
0.060748
cb7c33f1129f73ea16522644b0dc0c8fff4d920f
712
py
Python
UDPMulticastClient.py
monteno-m/Challenge
facebb31d3e04dcd497577e4e6f38020b846c614
[ "MIT" ]
null
null
null
UDPMulticastClient.py
monteno-m/Challenge
facebb31d3e04dcd497577e4e6f38020b846c614
[ "MIT" ]
null
null
null
UDPMulticastClient.py
monteno-m/Challenge
facebb31d3e04dcd497577e4e6f38020b846c614
[ "MIT" ]
null
null
null
# Basic UDP Multicasting server built in python import socket import struct def UDPReceiveMultiCast(group, port): # Create UDP Socket s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM, socket.IPPROTO_UDP) s.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1) s.bind(('', port)) mreq = stru...
25.428571
76
0.657303
0
0
0
0
0
0
0
0
130
0.182584
cb7cbdea43eb0a87e369eaad496fe599a41ed30b
1,232
py
Python
tests/test_scripts_basic.py
Holt59/bain-wizard-interpreter
70a95e6b9238c1399d20c947a798891eba7fb647
[ "MIT" ]
2
2020-11-08T12:22:34.000Z
2021-12-30T15:41:47.000Z
tests/test_scripts_basic.py
Holt59/bain-wizard-interpreter
70a95e6b9238c1399d20c947a798891eba7fb647
[ "MIT" ]
1
2020-11-09T10:37:47.000Z
2020-11-09T10:38:16.000Z
tests/test_scripts_basic.py
Holt59/bain-wizard-interpreter
70a95e6b9238c1399d20c947a798891eba7fb647
[ "MIT" ]
1
2021-02-07T10:53:00.000Z
2021-02-07T10:53:00.000Z
# -*- encoding: utf-8 -*- """ These tests are only here to check that running the test scripts do not actually fails. Important: If a script contains While loop that are cancelled by user, it should not be tested here. """ from antlr4.error.Errors import ParseCancellationException from pathlib import Path from wiz...
26.782609
78
0.693182
0
0
0
0
0
0
0
0
684
0.555195
cb7f6dcf22a868c02e40a1c04eb933a6c7a3c1bd
341
py
Python
celerytest/tasks.py
dpfried/mocs
d594a47c2e3125a30fe14c2bc646d0e0614cb8b2
[ "MIT" ]
8
2016-05-31T09:54:15.000Z
2021-08-13T13:25:01.000Z
celerytest/tasks.py
dpfried/mocs
d594a47c2e3125a30fe14c2bc646d0e0614cb8b2
[ "MIT" ]
null
null
null
celerytest/tasks.py
dpfried/mocs
d594a47c2e3125a30fe14c2bc646d0e0614cb8b2
[ "MIT" ]
10
2015-01-07T06:45:44.000Z
2021-06-21T08:41:57.000Z
from celery.task import task from time import sleep @task() def add(x, y): return x + y; @task() def status(delay): status.update_state(state='PROGRESS', meta={'description': 'starting timer'}) sleep(delay) status.update_state(state='PROGRESS', meta={'description': 'after first sleep'}) sleep(dela...
22.733333
84
0.677419
0
0
0
0
285
0.835777
0
0
87
0.255132
cb7fc096b934fb70ce80d9b25b9920992168492e
824
py
Python
python-CSDN博客爬虫/CSDN_article/csdn/test.py
wangchuanli001/Project-experience
b563c5c3afc07c913c2e1fd25dff41c70533f8de
[ "Apache-2.0" ]
12
2019-12-07T01:44:55.000Z
2022-01-27T14:13:30.000Z
python-CSDN博客爬虫/CSDN_article/csdn/test.py
hujiese/Project-experience
b563c5c3afc07c913c2e1fd25dff41c70533f8de
[ "Apache-2.0" ]
23
2020-05-23T03:56:33.000Z
2022-02-28T07:54:45.000Z
python-CSDN博客爬虫/CSDN_article/csdn/test.py
hujiese/Project-experience
b563c5c3afc07c913c2e1fd25dff41c70533f8de
[ "Apache-2.0" ]
7
2019-12-20T04:48:56.000Z
2021-11-19T02:23:45.000Z
import random import MySQLdb import requests # ! -*- encoding:utf-8 -*- import requests # 要访问的目标页面 targetUrl = "https://blog.csdn.net/wang978252321/article/details/95489446" # targetUrl = "http://proxy.abuyun.com/switch-ip" # targetUrl = "http://proxy.abuyun.com/current-ip" # 代理服务器 proxyHost = "http-dyn.abuyun.com...
19.619048
74
0.684466
0
0
0
0
0
0
0
0
444
0.512702
cb80633fe8db6b18104c502bfcdb1176d8840b4c
1,093
py
Python
to_offer/37_SerializeBinaryTrees.py
Run0812/algorithm
1a73ce6e81cf8c3ebe58f736204dc686e85d44c5
[ "MIT" ]
null
null
null
to_offer/37_SerializeBinaryTrees.py
Run0812/algorithm
1a73ce6e81cf8c3ebe58f736204dc686e85d44c5
[ "MIT" ]
null
null
null
to_offer/37_SerializeBinaryTrees.py
Run0812/algorithm
1a73ce6e81cf8c3ebe58f736204dc686e85d44c5
[ "MIT" ]
null
null
null
""" 面试题37:序列化二叉树 题目:请实现两个函数,分别用来序列化和反序列化二叉树 例: 树: 1 / \ 2 3 / / \ 4 5 6 序列化: [1, 2, 4, $, $, $, 3, 5, $, $, 6, $, $] """ from datstru import TreeNode from datstru import list_to_treenode def serialize(root): """ :param root:tree root :return:pre-order val list ""...
18.216667
51
0.534309
0
0
0
0
0
0
0
0
398
0.337574
cb80caec425effb53efd7354ad0dff729134141a
803
py
Python
setup.py
codecov/tornpsql
6d24b20db6ba554064edd747febeea5028bd2e84
[ "Apache-2.0" ]
null
null
null
setup.py
codecov/tornpsql
6d24b20db6ba554064edd747febeea5028bd2e84
[ "Apache-2.0" ]
2
2019-10-01T07:31:06.000Z
2020-10-29T15:53:39.000Z
setup.py
codecov/tornpsql
6d24b20db6ba554064edd747febeea5028bd2e84
[ "Apache-2.0" ]
3
2020-08-27T00:03:18.000Z
2021-05-30T02:04:57.000Z
from setuptools import setup setup(name='tornpsql', version='2.1.5', description="PostgreSQL handler for Tornado Web", long_description="", classifiers=["Development Status :: 5 - Production/Stable", "License :: OSI Approved :: Apache Software License", "Pr...
36.5
72
0.597758
0
0
0
0
0
0
0
0
391
0.486924
cb811398470b8cc79c6cd844862ffc7058f5bb1b
7,392
py
Python
workflow/scripts/mask-contigs.py
AKBrueggemann/snakemake-workflow-sars-cov2
e4cfe0f2f93efc6b45ede0183070bff81f08f502
[ "BSD-2-Clause" ]
null
null
null
workflow/scripts/mask-contigs.py
AKBrueggemann/snakemake-workflow-sars-cov2
e4cfe0f2f93efc6b45ede0183070bff81f08f502
[ "BSD-2-Clause" ]
null
null
null
workflow/scripts/mask-contigs.py
AKBrueggemann/snakemake-workflow-sars-cov2
e4cfe0f2f93efc6b45ede0183070bff81f08f502
[ "BSD-2-Clause" ]
null
null
null
'# Copyright ' + str(datetime.datetime.now().year) + ' Thomas Battenfeld, Alexander Thomas, Johannes Köster.' '# Licensed under the GNU GPLv3 license (https://opensource.org/licenses/GPL-3.0)' '# This file may not be copied, modified, or distributed' '# except according to those terms. ' '# Copyright 2021 Thomas Ba...
37.145729
125
0.540449
0
0
0
0
0
0
0
0
2,684
0.362948
cb81a1e07f6c274ad26ad849f859995ac2573b0c
638
py
Python
prototyper/build/stages/wsgi_app.py
vitalik/django-prototyper
0bf7b2437c45868d2ee90c7c4d69c7d71247c978
[ "MIT" ]
114
2018-03-19T14:45:22.000Z
2022-02-07T20:42:28.000Z
prototyper/build/stages/wsgi_app.py
vitalik/django-prototyper
0bf7b2437c45868d2ee90c7c4d69c7d71247c978
[ "MIT" ]
7
2018-05-04T13:35:20.000Z
2022-02-10T12:03:46.000Z
prototyper/build/stages/wsgi_app.py
vitalik/django-prototyper
0bf7b2437c45868d2ee90c7c4d69c7d71247c978
[ "MIT" ]
8
2018-06-25T08:09:06.000Z
2022-02-07T20:42:36.000Z
from ..base import BuildStage from pathlib import Path TPL = """\"\"\" WSGI config for {0} project. It exposes the WSGI callable as a module-level variable named ``application``. For more information on this file, see https://docs.djangoproject.com/en/2.0/howto/deployment/wsgi/ \"\"\" import os from django.core.ws...
23.62963
78
0.730408
186
0.291536
0
0
0
0
0
0
405
0.634796
cb82a4817e12d6d4179e7cddccb7eec72aa3842a
399
py
Python
tests/test_http_api.py
b2wads/baas-transfer
ce2b62c2bed3a06ec85faf1e30fa86d12ede6fea
[ "BSD-3-Clause" ]
null
null
null
tests/test_http_api.py
b2wads/baas-transfer
ce2b62c2bed3a06ec85faf1e30fa86d12ede6fea
[ "BSD-3-Clause" ]
2
2021-03-31T19:48:34.000Z
2021-12-13T20:48:54.000Z
tests/test_http_api.py
b2wads/baas-transfer
ce2b62c2bed3a06ec85faf1e30fa86d12ede6fea
[ "BSD-3-Clause" ]
1
2020-03-16T15:10:22.000Z
2020-03-16T15:10:22.000Z
from aioresponses import aioresponses from asynctest import TestCase from asyncworker.testing import HttpClientContext from baas.api import app class TransferAPITest(TestCase): async def test_health(self): async with HttpClientContext(app) as client: resp = await client.get("/health") ...
28.5
52
0.701754
251
0.629073
0
0
0
0
214
0.536341
13
0.032581
cb83b19aafb196f862003b235a938146859af09c
1,288
py
Python
RLBotPack/BotimusPrime/source/maneuvers/air/fast_recovery.py
DaCoolOne/RLBotPack
d418aa85433022dd8d3d0324f1586b6ea5084616
[ "MIT" ]
null
null
null
RLBotPack/BotimusPrime/source/maneuvers/air/fast_recovery.py
DaCoolOne/RLBotPack
d418aa85433022dd8d3d0324f1586b6ea5084616
[ "MIT" ]
null
null
null
RLBotPack/BotimusPrime/source/maneuvers/air/fast_recovery.py
DaCoolOne/RLBotPack
d418aa85433022dd8d3d0324f1586b6ea5084616
[ "MIT" ]
null
null
null
from maneuvers.kit import * from maneuvers.driving.arrive import Arrive class FastRecovery(Maneuver): def __init__(self, car: Car): super().__init__(car) self.turn = AerialTurn(car, look_at(vec3(0, 0, -1))) self.landing = False def step(self, dt): self.turn.step(d...
32.2
99
0.537267
1,188
0.92236
0
0
0
0
0
0
0
0
cb83bfc3bc5471588970f456d7d61bea25c6a0d0
1,046
py
Python
target/opsdev/WEB-INF/classes/shell/updateMobileManagerDataSource.py
ws02752587/opsdev
1c0ba65defd80af2570e7fcdf1c45277235d7d0d
[ "Apache-2.0" ]
null
null
null
target/opsdev/WEB-INF/classes/shell/updateMobileManagerDataSource.py
ws02752587/opsdev
1c0ba65defd80af2570e7fcdf1c45277235d7d0d
[ "Apache-2.0" ]
null
null
null
target/opsdev/WEB-INF/classes/shell/updateMobileManagerDataSource.py
ws02752587/opsdev
1c0ba65defd80af2570e7fcdf1c45277235d7d0d
[ "Apache-2.0" ]
null
null
null
import sys import re argvs = list(sys.argv) result = '' dataSourceName=argvs[1] name=argvs[2] if not dataSourceName or not name: return path="/mobile/app/upload/"+name+"/WEB-INF/classes/spring/applicationContext-ibatis.xml" with open(path) as file: result = file.read() result = re.sub('<bean\\s+id\\s*=\\s*"da...
37.357143
148
0.681644
0
0
0
0
0
0
0
0
565
0.540153
cb84957ad1b624b8b574c38b8823c92d6f5be898
96
py
Python
werewolf/models/__init__.py
LucienZhang/werewolf-back
289468c3589a7ad101358175e26401ba6b3b4f16
[ "MIT" ]
null
null
null
werewolf/models/__init__.py
LucienZhang/werewolf-back
289468c3589a7ad101358175e26401ba6b3b4f16
[ "MIT" ]
null
null
null
werewolf/models/__init__.py
LucienZhang/werewolf-back
289468c3589a7ad101358175e26401ba6b3b4f16
[ "MIT" ]
null
null
null
from .base import Base from .user import User from .game import Game from .role import Role
19.2
23
0.75
0
0
0
0
0
0
0
0
0
0
cb84959677097edcddf65761e6fe0302bc26b8f5
3,382
py
Python
add-tags.py
tbma2014us/ops-tools
d6368fedbbf1fea06aea9fc657087b9371dd00cc
[ "Apache-2.0" ]
2
2020-08-13T15:33:35.000Z
2022-01-22T09:59:15.000Z
add-tags.py
tbma2014us/ops-tools
d6368fedbbf1fea06aea9fc657087b9371dd00cc
[ "Apache-2.0" ]
null
null
null
add-tags.py
tbma2014us/ops-tools
d6368fedbbf1fea06aea9fc657087b9371dd00cc
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python import logging import sys import argparse import boto3 import botocore.exceptions LOG_FORMAT = '%(asctime)s %(filename)s:%(lineno)s[%(process)d]: %(levelname)s: %(message)s' class ArgsParser(argparse.ArgumentParser): def __init__(self, *args, **kwargs): kwargs.setdefault( ...
35.6
115
0.609994
1,590
0.470136
0
0
0
0
0
0
713
0.210822
cb85aedb9943fc657db2a70bf855a03da6a15347
778
py
Python
carCapture.py
ishmam367/Vehcle-Monitoring-System-BLPR-
a43ef820b63c4af0856e9e04e6ea1577b7c7c34b
[ "CNRI-Python" ]
2
2020-07-12T12:10:06.000Z
2020-08-05T17:34:18.000Z
carCapture.py
ishmam367/Vehcle-Monitoring-System-BLPR-
a43ef820b63c4af0856e9e04e6ea1577b7c7c34b
[ "CNRI-Python" ]
null
null
null
carCapture.py
ishmam367/Vehcle-Monitoring-System-BLPR-
a43ef820b63c4af0856e9e04e6ea1577b7c7c34b
[ "CNRI-Python" ]
1
2020-06-12T15:27:15.000Z
2020-06-12T15:27:15.000Z
import cv2 import time #print(cv2.__version__) cascade_src = 'cars.xml' video_src = 'v3.avi' start_time = time.time() cap = cv2.VideoCapture(video_src) #framerate = cap.get(5) car_cascade = cv2.CascadeClassifier(cascade_src) i=0 while True: i=i+1 ret, img = cap.read() if (type(img) == type(None)): ...
18.97561
60
0.602828
0
0
0
0
0
0
0
0
109
0.140103
cb867addc7ccb49e4d1c2736f2d98b7fdcf1b6b4
985
py
Python
src/m2_run_this_on_robot.py
myerscar1555/99-CapstoneProject-201920
9f2dc26a562be61979e5f5ee5f2b3a791cff6340
[ "MIT" ]
null
null
null
src/m2_run_this_on_robot.py
myerscar1555/99-CapstoneProject-201920
9f2dc26a562be61979e5f5ee5f2b3a791cff6340
[ "MIT" ]
null
null
null
src/m2_run_this_on_robot.py
myerscar1555/99-CapstoneProject-201920
9f2dc26a562be61979e5f5ee5f2b3a791cff6340
[ "MIT" ]
null
null
null
""" Capstone Project. Code to run on the EV3 robot (NOT on a laptop). Author: Your professors (for the framework) and Michael Johnson. Winter term, 2018-2019. """ import rosebot import mqtt_remote_method_calls as com import time import shared_gui_delegate_on_robot as dingding def main(): """ This...
26.621622
79
0.596954
0
0
0
0
0
0
0
0
554
0.562437
cb8782c8d3ed5f70ac8e8fb4474a4810fb8ff2aa
1,276
py
Python
cvisionlib/camfeed.py
methusael13/cvision
4f147cd91bf43704662fe32960e6c98057ef5eac
[ "MIT" ]
2
2018-01-15T14:38:35.000Z
2018-03-04T10:00:28.000Z
cvisionlib/camfeed.py
methusael13/cvision
4f147cd91bf43704662fe32960e6c98057ef5eac
[ "MIT" ]
null
null
null
cvisionlib/camfeed.py
methusael13/cvision
4f147cd91bf43704662fe32960e6c98057ef5eac
[ "MIT" ]
null
null
null
''' Author: Methusael Murmu Module implementing parallel Camera I/O feed ''' import cv2 from threading import Thread class CameraFeedException(Exception): def __init__(self, src, msg = None): if msg is None: msg = 'Unable to open camera devive: %d' % src super(CameraFeedExcepti...
25.019608
60
0.61442
1,145
0.897335
0
0
60
0.047022
0
0
118
0.092476
cb88bb723ef070ee97fb86fb89979898c343a3f2
2,250
py
Python
downloader.py
MCodez/Youtube-MP4-MP3-Downloader
b63272309c309d53361a7e0045a38feb00abce5e
[ "MIT" ]
null
null
null
downloader.py
MCodez/Youtube-MP4-MP3-Downloader
b63272309c309d53361a7e0045a38feb00abce5e
[ "MIT" ]
null
null
null
downloader.py
MCodez/Youtube-MP4-MP3-Downloader
b63272309c309d53361a7e0045a38feb00abce5e
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Wed Jul 25 19:44:44 2018 @author: LALIT ARORA """ from __future__ import unicode_literals import youtube_dl import urllib.parse from bs4 import BeautifulSoup def check_internet(): try: urllib.request.urlopen('http://216.58.192.142', timeout=1) ...
26.470588
99
0.56
0
0
0
0
0
0
0
0
526
0.233778
cb892b030eca225bfcb188bb0987e05132d3e1b2
4,561
py
Python
newton.py
smrfeld/line_search_tutorial
4bdc450d7e62e5f8a7e19a3e6c2230ec9199bd5a
[ "MIT" ]
4
2020-11-05T03:38:57.000Z
2021-11-06T20:57:54.000Z
newton.py
smrfeld/line_search_tutorial
4bdc450d7e62e5f8a7e19a3e6c2230ec9199bd5a
[ "MIT" ]
null
null
null
newton.py
smrfeld/line_search_tutorial
4bdc450d7e62e5f8a7e19a3e6c2230ec9199bd5a
[ "MIT" ]
null
null
null
import numpy as np from typing import Any, Tuple, Dict import logging class NotDescentDirection(Exception): pass class ZeroDescentProduct(Exception): pass class ZeroUpdate(Exception): pass class Newton: def __init__(self, obj_func : Any, gradient_func : Any, reg_inv_hessi...
29.050955
133
0.546591
4,482
0.982679
0
0
0
0
0
0
523
0.114668
cb89eb6490818b42b34e9f033ff35f2c3751c687
2,993
py
Python
chatmanage.py
NyaNyak/2021_OSS
f9673bde96709430330760f0710d9804e8a0158b
[ "MIT" ]
null
null
null
chatmanage.py
NyaNyak/2021_OSS
f9673bde96709430330760f0710d9804e8a0158b
[ "MIT" ]
1
2021-12-21T16:42:35.000Z
2021-12-21T16:55:18.000Z
chatmanage.py
NyaNyak/2021_OSS
f9673bde96709430330760f0710d9804e8a0158b
[ "MIT" ]
null
null
null
import discord import random def filtering(message): manage = "소환사님 🎀✨예쁜 말✨🎀을 사용해😡주세요~!😎😘" return manage def command(): embed = discord.Embed(title=f"명령어 모음", description="꿀벌봇은 현재 아래 기능들을 지원하고 있습니다!", color=0xf3bb76) embed.set_thumbnail(url="https://mblogthumb-phinf.pstatic.net/MjAxODA1MTdfMjEx/M...
63.680851
242
0.669562
0
0
0
0
0
0
0
0
2,802
0.695631
cb8d02b22bb2917353763bb8532feaa16e03096a
202
py
Python
Server/Python/src/dbs/dao/MySQL/File/MgrtList.py
vkuznet/DBS
14df8bbe8ee8f874fe423399b18afef911fe78c7
[ "Apache-2.0" ]
8
2015-08-14T04:01:32.000Z
2021-06-03T00:56:42.000Z
Server/Python/src/dbs/dao/MySQL/File/MgrtList.py
yuyiguo/DBS
14df8bbe8ee8f874fe423399b18afef911fe78c7
[ "Apache-2.0" ]
162
2015-01-07T21:34:47.000Z
2021-10-13T09:42:41.000Z
Server/Python/src/dbs/dao/MySQL/File/MgrtList.py
yuyiguo/DBS
14df8bbe8ee8f874fe423399b18afef911fe78c7
[ "Apache-2.0" ]
16
2015-01-22T15:27:29.000Z
2021-04-28T09:23:28.000Z
#!/usr/bin/env python """ This module provides File.MgrtList data access object. """ from dbs.dao.Oracle.File.MgrtList import MgrtList as OraFileMgrtList class MgrtList(OraFileMgrtList): pass
20.2
68
0.752475
45
0.222772
0
0
0
0
0
0
83
0.410891
cb8d53a3ab59cdae86918dbce66c63400639164e
3,478
py
Python
test_intensity.py
gfzriesgos/deus
afa2b64d85a2da61025c9c7bfd253ea9572cfaed
[ "Apache-2.0" ]
1
2019-08-13T05:19:07.000Z
2019-08-13T05:19:07.000Z
test_intensity.py
gfzriesgos/deus
afa2b64d85a2da61025c9c7bfd253ea9572cfaed
[ "Apache-2.0" ]
19
2019-10-16T12:50:57.000Z
2022-03-11T23:58:20.000Z
test_intensity.py
gfzriesgos/deus
afa2b64d85a2da61025c9c7bfd253ea9572cfaed
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python3 # Copyright © 2021 Helmholtz Centre Potsdam GFZ German Research Centre for Geosciences, Potsdam, Germany # # Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at # # https://www.ap...
32.203704
307
0.646636
2,649
0.761426
0
0
0
0
0
0
1,185
0.340615
cb905a1474b77d18994505f88c59914d489cc249
512
py
Python
verify_package_installs.py
lukassnoek/ICON2017_MVPA
89af3be9b9565cd8a9f6be940edb1c870b5a1c9d
[ "MIT" ]
19
2017-08-06T06:30:21.000Z
2021-11-02T10:37:48.000Z
verify_package_installs.py
lukassnoek/ICON2017_MVPA
89af3be9b9565cd8a9f6be940edb1c870b5a1c9d
[ "MIT" ]
1
2017-08-06T11:44:10.000Z
2017-08-06T11:44:10.000Z
verify_package_installs.py
lukassnoek/ICON2017_MVPA
89af3be9b9565cd8a9f6be940edb1c870b5a1c9d
[ "MIT" ]
6
2017-08-06T07:08:12.000Z
2020-06-04T09:22:28.000Z
import warnings import os from importlib import import_module packages = ['sklearn', 'nibabel', 'numpy', 'matplotlib', 'skbold', 'niwidgets', 'scipy'] warnings.filterwarnings("ignore") for package in packages: try: import_module(package) print('%s was succesfully installed!' % package...
26.947368
68
0.642578
0
0
0
0
0
0
0
0
183
0.357422
cb91cfb48f8d827ab0cbcfd61e22339fb73c61b6
296
py
Python
python_practice/decorators.py
vishalvb/practice
4c38f863408c91aa072bd20510f098043fecd043
[ "MIT" ]
null
null
null
python_practice/decorators.py
vishalvb/practice
4c38f863408c91aa072bd20510f098043fecd043
[ "MIT" ]
null
null
null
python_practice/decorators.py
vishalvb/practice
4c38f863408c91aa072bd20510f098043fecd043
[ "MIT" ]
null
null
null
#decorators def decorator(myfunc): def wrapper(*args): return myfunc(*args) return wrapper @decorator def display(): print('display function') @decorator def info(name, age): print('name is {} and age is {}'.format(name,age)) info('john', 23) #hi = decorator(display) #hi() display()
14.095238
51
0.682432
0
0
0
0
135
0.456081
0
0
90
0.304054
cb925867e208753958f0b2c866d1017c0fd97bd5
1,886
py
Python
tests/article_part_test.py
jhroot/content-store
0e8752ded4c831562019898f29ad0f91c3bb431d
[ "MIT" ]
null
null
null
tests/article_part_test.py
jhroot/content-store
0e8752ded4c831562019898f29ad0f91c3bb431d
[ "MIT" ]
null
null
null
tests/article_part_test.py
jhroot/content-store
0e8752ded4c831562019898f29ad0f91c3bb431d
[ "MIT" ]
null
null
null
import pytest from sqlalchemy.orm.exc import NoResultFound from content_store.api.api import create_app from content_store.api.config import TestingConfig from content_store.api.models import ArticlePart from content_store.api.repositories import ArticlePartRepository from content_store.api.database import DB @pytest...
27.735294
85
0.683457
0
0
163
0.086426
1,566
0.830329
0
0
245
0.129905
cb927e4a27da1ae4f08594577d0c7318209a8f1e
630
py
Python
Algorithms/032_TREE.py
ChaoticMarauder/Project_Rosalind
6c70cd32908f3b11285e8505c3b43f1ea222decb
[ "MIT" ]
null
null
null
Algorithms/032_TREE.py
ChaoticMarauder/Project_Rosalind
6c70cd32908f3b11285e8505c3b43f1ea222decb
[ "MIT" ]
null
null
null
Algorithms/032_TREE.py
ChaoticMarauder/Project_Rosalind
6c70cd32908f3b11285e8505c3b43f1ea222decb
[ "MIT" ]
null
null
null
def connected_tree(n, edge_list): current_edges = len(edge_list) edges_needed = (n-1) - current_edges return edges_needed def main(): with open('datasets/rosalind_tree.txt') as input_file: input_data = input_file.read().strip().split('\n') n = int(input_data.pop(0)) edge_l...
27.391304
66
0.64127
0
0
0
0
0
0
0
0
74
0.11746
cb930dbc32b58947b55e2b163fde90a6ee380c13
13,135
py
Python
qiita_pet/handlers/api_proxy/processing.py
charles-cowart/qiita
328e986a9dc3d7caa2e33afacd61e6aae9abed85
[ "BSD-3-Clause" ]
96
2015-01-10T23:40:03.000Z
2021-01-04T09:07:16.000Z
qiita_pet/handlers/api_proxy/processing.py
charles-cowart/qiita
328e986a9dc3d7caa2e33afacd61e6aae9abed85
[ "BSD-3-Clause" ]
2,304
2015-01-01T17:46:14.000Z
2021-01-07T02:38:52.000Z
qiita_pet/handlers/api_proxy/processing.py
antgonza/qiita
714f3589ae1699317ad3a314653913f453d347d2
[ "BSD-3-Clause" ]
68
2015-02-18T21:42:31.000Z
2020-12-01T19:08:57.000Z
# ----------------------------------------------------------------------------- # Copyright (c) 2014--, The Qiita Development Team. # # Distributed under the terms of the BSD 3-clause License. # # The full license is in the file LICENSE, distributed with this software. # ------------------------------------------------...
34.933511
79
0.556681
0
0
0
0
0
0
0
0
6,455
0.491435
cb930e85278de85a62b2b49b52741474d0c750b3
342
py
Python
old_app/app.py
kelj0/GPGdotgetter
619ada58598fefbd9a5f33d50a15df7f35996d1e
[ "MIT" ]
null
null
null
old_app/app.py
kelj0/GPGdotgetter
619ada58598fefbd9a5f33d50a15df7f35996d1e
[ "MIT" ]
7
2021-04-02T10:26:34.000Z
2021-04-03T21:15:37.000Z
old_app/app.py
kelj0/GPGdotgetter
619ada58598fefbd9a5f33d50a15df7f35996d1e
[ "MIT" ]
null
null
null
from flask import Flask app = Flask('savedots') app.config['DATABASE_FILE'] = 'savedots_DB.sqlite' app.config['SQLALCHEMY_DATABASE_URI'] = 'sqlite:///savedots_DB.sqlite' app.config['SQLALCHEMY_TRACK_MODIFICATIONS'] = False app.secret_key = "CHANGE_ME" if __name__ == '__main__': print("Please run main.py to start...
26.307692
70
0.736842
0
0
0
0
0
0
0
0
189
0.552632
cb9336de0a97c2e079a64878f9bf7e7224882176
1,019
py
Python
painindex_app/migrations/0002_auto_20140823_2046.py
xanv/painindex
ba8b2fc8fdb38507ae7ede6c552de2447e13e944
[ "MIT" ]
null
null
null
painindex_app/migrations/0002_auto_20140823_2046.py
xanv/painindex
ba8b2fc8fdb38507ae7ede6c552de2447e13e944
[ "MIT" ]
null
null
null
painindex_app/migrations/0002_auto_20140823_2046.py
xanv/painindex
ba8b2fc8fdb38507ae7ede6c552de2447e13e944
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import models, migrations class Migration(migrations.Migration): dependencies = [ ('painindex_app', '0001_initial'), ] operations = [ migrations.CreateModel( name='PainProfile', fields...
29.114286
130
0.533857
910
0.893032
0
0
0
0
0
0
149
0.146222
cb9357f27908177cf2214963118161546dd6dd87
1,765
py
Python
nnet/trans_func.py
Bhumbra/Nnet
aa8a8891d28cb2244668093f90e1909be79314bd
[ "BSD-3-Clause" ]
1
2021-07-07T21:11:27.000Z
2021-07-07T21:11:27.000Z
nnet/trans_func.py
Bhumbra/Nnet
aa8a8891d28cb2244668093f90e1909be79314bd
[ "BSD-3-Clause" ]
null
null
null
nnet/trans_func.py
Bhumbra/Nnet
aa8a8891d28cb2244668093f90e1909be79314bd
[ "BSD-3-Clause" ]
null
null
null
# Transfer functions and derivatives # Note _all_ transfer functions and derivatives _must_ accept keyword arguments # and handle the output keyword argument out=z correctly. # Gary Bhumbra import numpy as np import scipy.special #------------------------------------------------------------------------------- """ de...
32.090909
80
0.430595
0
0
0
0
0
0
0
0
1,045
0.592068
cb94077eb248cb34b2ffab1ee0189b95332376de
28,267
py
Python
3GPP Meeting Helper/gui/tools.py
telekom/3gpp-meeting-tools
1276a62835fd595487aa817c9500c42c3f5e35f3
[ "MIT" ]
null
null
null
3GPP Meeting Helper/gui/tools.py
telekom/3gpp-meeting-tools
1276a62835fd595487aa817c9500c42c3f5e35f3
[ "MIT" ]
1
2020-09-04T06:26:41.000Z
2020-09-04T06:26:41.000Z
3GPP Meeting Helper/gui/tools.py
telekom/3gpp-meeting-tools
1276a62835fd595487aa817c9500c42c3f5e35f3
[ "MIT" ]
3
2020-06-12T02:09:48.000Z
2021-08-30T10:36:37.000Z
import application import tkinter import gui.main import gui.tdocs_table import os import os.path import server import traceback import parsing.html as html_parser import parsing.excel as excel_parser import parsing.outlook import parsing.word as word_parser import threading import pythoncom import tdoc import datetime...
51.023466
204
0.640217
27,931
0.988113
0
0
0
0
0
0
4,946
0.174974
cb94b15fac6dc17dea0801e6487a9fc364c3a0fd
1,997
py
Python
swift3/cfg.py
KoreaCloudObjectStorage/swift3
3bd412b33d524bb84bffbe5bd97642faaab71703
[ "Apache-2.0" ]
null
null
null
swift3/cfg.py
KoreaCloudObjectStorage/swift3
3bd412b33d524bb84bffbe5bd97642faaab71703
[ "Apache-2.0" ]
null
null
null
swift3/cfg.py
KoreaCloudObjectStorage/swift3
3bd412b33d524bb84bffbe5bd97642faaab71703
[ "Apache-2.0" ]
null
null
null
# Copyright (c) 2014 OpenStack Foundation. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to...
30.257576
69
0.648973
923
0.462193
0
0
0
0
0
0
883
0.442163
cb955cb73652fe567af5f31103db170d5be3b1fa
1,432
py
Python
console/widgets/pane.py
dustinlacewell/console
b65f63354dd8ba60f211e3e169e53c078b99fdf8
[ "MIT" ]
11
2015-06-10T22:23:03.000Z
2021-02-16T10:55:55.000Z
console/widgets/pane.py
rrosajp/console
b65f63354dd8ba60f211e3e169e53c078b99fdf8
[ "MIT" ]
1
2015-07-01T00:04:50.000Z
2015-08-19T16:40:18.000Z
console/widgets/pane.py
rrosajp/console
b65f63354dd8ba60f211e3e169e53c078b99fdf8
[ "MIT" ]
5
2015-06-20T11:08:32.000Z
2022-03-07T00:01:50.000Z
import urwid from console.app import app from console.widgets.help import HelpDialog class Pane(urwid.WidgetPlaceholder): """ A widget which allows for easy display of dialogs. """ def __init__(self, widget=urwid.SolidFill(' ')): urwid.WidgetPlaceholder.__init__(self, widget) self.wi...
28.64
65
0.583101
1,343
0.937849
0
0
0
0
0
0
146
0.101955
cb97efeed6f704cf24a8ea53acee6d4372fec9dd
47,000
py
Python
kvmagent/kvmagent/plugins/baremetal_v2_gateway_agent.py
zstackio/zstack-utility
919d686d46c68836cbcad51ab0b8bf53bc88abda
[ "ECL-2.0", "Apache-2.0" ]
55
2017-02-10T07:55:21.000Z
2021-09-01T00:59:36.000Z
kvmagent/kvmagent/plugins/baremetal_v2_gateway_agent.py
zstackio/zstack-utility
919d686d46c68836cbcad51ab0b8bf53bc88abda
[ "ECL-2.0", "Apache-2.0" ]
106
2017-02-13T09:58:27.000Z
2022-02-15T09:51:48.000Z
kvmagent/kvmagent/plugins/baremetal_v2_gateway_agent.py
zstackio/zstack-utility
919d686d46c68836cbcad51ab0b8bf53bc88abda
[ "ECL-2.0", "Apache-2.0" ]
68
2017-02-13T11:02:01.000Z
2021-12-16T11:02:01.000Z
import json import os import shutil from jinja2 import Template from zstacklib.utils import http from zstacklib.utils import jsonobject from zstacklib.utils import linux from zstacklib.utils import linux_v2 from zstacklib.utils import iptables from zstacklib.utils import lock from zstacklib.utils import log from zstac...
40.274207
108
0.59234
46,207
0.983128
0
0
15,088
0.321021
0
0
17,718
0.376979
cb9b068c1540439ce7eb94e4bb675995b9770c42
76
py
Python
ajaximage/__init__.py
kitsunefet/django-ajax-image-upload
bca4049b4fd4e1474892561ab170235936fa25d7
[ "MIT" ]
11
2018-01-29T12:57:58.000Z
2020-07-27T22:47:14.000Z
ajaximage/__init__.py
kitsunefet/django-ajax-image-upload
bca4049b4fd4e1474892561ab170235936fa25d7
[ "MIT" ]
5
2021-03-19T03:23:05.000Z
2022-03-11T23:58:21.000Z
ajaximage/__init__.py
kitsunefet/django-ajax-image-upload
bca4049b4fd4e1474892561ab170235936fa25d7
[ "MIT" ]
2
2019-09-03T11:22:56.000Z
2020-04-10T14:20:57.000Z
__version__ = '0.9.4' default_app_config = 'ajaximage.apps.AjaxImageConfig'
25.333333
53
0.789474
0
0
0
0
0
0
0
0
39
0.513158
cb9cb786bea91820326b5939c650093e3d8deda9
45,760
py
Python
qiskit_experiments/calibration_management/calibrations.py
blakejohnson/qiskit-experiments
2ecffa8f7d6aa6e8e6c1fc0a1c30f7776c49c493
[ "Apache-2.0" ]
null
null
null
qiskit_experiments/calibration_management/calibrations.py
blakejohnson/qiskit-experiments
2ecffa8f7d6aa6e8e6c1fc0a1c30f7776c49c493
[ "Apache-2.0" ]
null
null
null
qiskit_experiments/calibration_management/calibrations.py
blakejohnson/qiskit-experiments
2ecffa8f7d6aa6e8e6c1fc0a1c30f7776c49c493
[ "Apache-2.0" ]
null
null
null
# This code is part of Qiskit. # # (C) Copyright IBM 2021. # # This code is licensed under the Apache License, Version 2.0. You may # obtain a copy of this license in the LICENSE.txt file in the root directory # of this source tree or at http://www.apache.org/licenses/LICENSE-2.0. # # Any modifications or derivative wo...
42.766355
100
0.619493
44,411
0.97052
0
0
1,925
0.042067
0
0
24,321
0.53149
cb9ef821a05d706367656f99cdab7853cf9f59ee
1,857
py
Python
simple_open_graph/templatetags/simple_open_graph.py
haylmfao/django-simple-open-graph
7f89642177a63f3bf8ab854079ca3880ccc0b33c
[ "ISC" ]
null
null
null
simple_open_graph/templatetags/simple_open_graph.py
haylmfao/django-simple-open-graph
7f89642177a63f3bf8ab854079ca3880ccc0b33c
[ "ISC" ]
null
null
null
simple_open_graph/templatetags/simple_open_graph.py
haylmfao/django-simple-open-graph
7f89642177a63f3bf8ab854079ca3880ccc0b33c
[ "ISC" ]
null
null
null
from django import template from django.contrib.sites.models import Site from django.conf import settings from ..utils import string_to_dict, roundrobin register = template.Library() @register.tag def opengraph_meta(parser, token): try: tag_name, properties = token.split_contents() except ValueError:...
35.711538
97
0.621971
1,320
0.710824
0
0
347
0.186861
0
0
174
0.0937
cb9f2472517947e2b5fac779ceaa7fa3480dd5fd
11,974
py
Python
src/articles/migrations/0001_initial.py
yaongli/spadger
6eb2b192a1a6583119b0653c884b72614f6c4ce1
[ "MIT" ]
null
null
null
src/articles/migrations/0001_initial.py
yaongli/spadger
6eb2b192a1a6583119b0653c884b72614f6c4ce1
[ "MIT" ]
null
null
null
src/articles/migrations/0001_initial.py
yaongli/spadger
6eb2b192a1a6583119b0653c884b72614f6c4ce1
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by Django 1.9.2 on 2016-02-17 13:59 from __future__ import unicode_literals from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): initial = True dependencies = [ ] operations = [ migrations.Creat...
61.405128
193
0.583681
11,784
0.984132
0
0
0
0
0
0
3,469
0.289711
cb9f2ac1408c2f916e30ffa4b8d707e4f3ab1eff
2,281
py
Python
config/scripts/dados-pygen/models.py
uhndev/hateoas-server
7eac7928b9fb3be2ffcd9ec1eb833ba533333e98
[ "Unlicense", "MIT" ]
null
null
null
config/scripts/dados-pygen/models.py
uhndev/hateoas-server
7eac7928b9fb3be2ffcd9ec1eb833ba533333e98
[ "Unlicense", "MIT" ]
null
null
null
config/scripts/dados-pygen/models.py
uhndev/hateoas-server
7eac7928b9fb3be2ffcd9ec1eb833ba533333e98
[ "Unlicense", "MIT" ]
null
null
null
import random import config from faker import Factory fake = Factory.create() class User: def __init__(self): self.username = fake.user_name() self.email = fake.company_email() self.firstName = fake.first_name() self.lastName = fake.last_name() self.dateOfBirth = fake.iso8601() self.password...
31.246575
77
0.644454
2,192
0.960982
0
0
0
0
0
0
366
0.160456
cba1e5ee657e21be26d1c5f3f324dd59ed05b687
1,764
py
Python
src/test.py
chatdip98/Acoustic-Scene-Classification
cf410f14a1efb3e3dd2bbc240c24882969be98a9
[ "MIT" ]
null
null
null
src/test.py
chatdip98/Acoustic-Scene-Classification
cf410f14a1efb3e3dd2bbc240c24882969be98a9
[ "MIT" ]
null
null
null
src/test.py
chatdip98/Acoustic-Scene-Classification
cf410f14a1efb3e3dd2bbc240c24882969be98a9
[ "MIT" ]
null
null
null
#------testing the trained model and ensemble weights on the test data to get the final accuracy #importing required libraries and modules import os import sys import cv2 import numpy as np from preprocess import Preprocess from data_split import Load from conv_net import CNN from ensemble import Ensemble ...
30.947368
129
0.696145
0
0
0
0
0
0
0
0
695
0.393991
cba336f303822d216fee29cb5e72a4202e1f1e8c
23,152
py
Python
sdk/python/pulumi_google_native/clouddeploy/v1/rollout.py
AaronFriel/pulumi-google-native
75d1cda425e33d4610348972cd70bddf35f1770d
[ "Apache-2.0" ]
44
2021-04-18T23:00:48.000Z
2022-02-14T17:43:15.000Z
sdk/python/pulumi_google_native/clouddeploy/v1/rollout.py
AaronFriel/pulumi-google-native
75d1cda425e33d4610348972cd70bddf35f1770d
[ "Apache-2.0" ]
354
2021-04-16T16:48:39.000Z
2022-03-31T17:16:39.000Z
sdk/python/pulumi_google_native/clouddeploy/v1/rollout.py
AaronFriel/pulumi-google-native
75d1cda425e33d4610348972cd70bddf35f1770d
[ "Apache-2.0" ]
8
2021-04-24T17:46:51.000Z
2022-01-05T10:40:21.000Z
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi SDK Generator. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union, overload from ... import _utilities __...
47.056911
581
0.649447
22,772
0.983587
0
0
18,602
0.803473
0
0
9,998
0.431842
cba3386606abea1e2c3dfe0f137338d796e10c89
539
py
Python
batuta/base.py
makecodes/batuta
b460bdb216e0d9486dacab3273b891d7515287c3
[ "Unlicense" ]
null
null
null
batuta/base.py
makecodes/batuta
b460bdb216e0d9486dacab3273b891d7515287c3
[ "Unlicense" ]
2
2022-01-22T15:17:15.000Z
2022-01-22T16:08:27.000Z
batuta/base.py
makecodes/batuta
b460bdb216e0d9486dacab3273b891d7515287c3
[ "Unlicense" ]
null
null
null
from dynaconf import FlaskDynaconf from flask import Flask def create_app(**config): app = Flask(__name__) FlaskDynaconf(app) # config managed by Dynaconf app.config.load_extensions('EXTENSIONS') # Load extensions from settings.toml app.config.update(config) # Override with passed config return...
26.95
82
0.714286
0
0
0
0
0
0
0
0
236
0.437848
cba3c31ab7fc8222a105013241179fdcaa174f59
493
py
Python
classification/model/model.py
hirune924/CVpipeline
c58c9d390188b1fd6890e789a4c48d5810c4c16e
[ "Apache-2.0" ]
null
null
null
classification/model/model.py
hirune924/CVpipeline
c58c9d390188b1fd6890e789a4c48d5810c4c16e
[ "Apache-2.0" ]
null
null
null
classification/model/model.py
hirune924/CVpipeline
c58c9d390188b1fd6890e789a4c48d5810c4c16e
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- import torchvision.models as models import torch.nn as nn def get_model_from_name(model_name=None, image_size=None, num_classes=None, pretrained=True): if model_name == 'resnet18': model = models.resnet18(pretrained=pretrained) in_features = model.fc.i...
29
93
0.685598
0
0
0
0
0
0
0
0
77
0.156187
cba3c8c86c31d37a6802b0db75b82af1fea73139
371
py
Python
dragonBall.py
falconcode16/pythonprogramming
fc53a879be473ebceb1d7da061b0e8fc2a20706c
[ "MIT" ]
2
2020-04-11T14:15:10.000Z
2020-05-12T09:57:29.000Z
dragonBall.py
falconcode16/pythonprogramming
fc53a879be473ebceb1d7da061b0e8fc2a20706c
[ "MIT" ]
null
null
null
dragonBall.py
falconcode16/pythonprogramming
fc53a879be473ebceb1d7da061b0e8fc2a20706c
[ "MIT" ]
1
2021-10-10T02:13:42.000Z
2021-10-10T02:13:42.000Z
from collections import Counter if __name__ == '__main__': tc = int(input()) while tc > 0: x = int(input()) balls = list(map(int, input().split())) count = Counter(balls) balls = list(filter((x).__ne__, balls)) if balls[0] == count[balls[0]]: print("YES") ...
24.733333
47
0.493261
0
0
0
0
0
0
0
0
19
0.051213
cba5dfbe2d49f584c80eda8eee7e4ad40b87a300
1,502
py
Python
packages/terminal_colors_old/gen_colors.py
kboone/dotfiles
317b3c0708cf6117e4978c2c681acd925f770830
[ "MIT" ]
null
null
null
packages/terminal_colors_old/gen_colors.py
kboone/dotfiles
317b3c0708cf6117e4978c2c681acd925f770830
[ "MIT" ]
null
null
null
packages/terminal_colors_old/gen_colors.py
kboone/dotfiles
317b3c0708cf6117e4978c2c681acd925f770830
[ "MIT" ]
null
null
null
from skimage import color import numpy as np colors = [ ("base03", (10., +00., -05.)), ("base02", (15., +00., -05.)), ("base01", (45., -01., -05.)), ("base00", (50., -01., -05.)), ("base0", (60., -01., -02.)), ("base1", (65., -01., -02.)), ("base2", (92., -00., +02.)), ...
28.339623
61
0.509321
0
0
0
0
0
0
0
0
276
0.183755
cba775635f305bef7a2f3716c42191c15630f3b0
2,890
py
Python
python/smurff/test/test_predict_sideinfo.py
msteijaert/smurff
e6066d51e1640e9aad0118628ba72c9d662919fb
[ "MIT" ]
null
null
null
python/smurff/test/test_predict_sideinfo.py
msteijaert/smurff
e6066d51e1640e9aad0118628ba72c9d662919fb
[ "MIT" ]
null
null
null
python/smurff/test/test_predict_sideinfo.py
msteijaert/smurff
e6066d51e1640e9aad0118628ba72c9d662919fb
[ "MIT" ]
null
null
null
import unittest import numpy as np import pandas as pd import scipy.sparse import smurff verbose = 0 class TestPredictSession(unittest.TestCase): # Python 2.7 @unittest.skip fix __name__ = "TestPredictSession" def run_train_session(self): Ydense = np.random.normal(size = (10, 20)).reshape((10,20...
37.051282
93
0.652249
2,738
0.947405
0
0
0
0
0
0
309
0.10692
cba87e9e56a8df3787933c3ffc011bf3adb0fc4e
16,055
py
Python
gewittergefahr/dissertation/plot_gridrad_domains.py
dopplerchase/GewitterGefahr
4415b08dd64f37eba5b1b9e8cc5aa9af24f96593
[ "MIT" ]
26
2018-10-04T01:07:35.000Z
2022-01-29T08:49:32.000Z
gewittergefahr/dissertation/plot_gridrad_domains.py
liuximarcus/GewitterGefahr
d819874d616f98a25187bfd3091073a2e6d5279e
[ "MIT" ]
4
2017-12-25T02:01:08.000Z
2018-12-19T01:54:21.000Z
gewittergefahr/dissertation/plot_gridrad_domains.py
liuximarcus/GewitterGefahr
d819874d616f98a25187bfd3091073a2e6d5279e
[ "MIT" ]
11
2017-12-10T23:05:29.000Z
2022-01-29T08:49:33.000Z
"""Plots GridRad domains. Specifically, plots number of convective days with GridRad data at each grid point. """ import os.path import argparse import numpy import matplotlib matplotlib.use('agg') from matplotlib import pyplot from mpl_toolkits.basemap import Basemap from gewittergefahr.gg_io import gridrad_io from ...
36.405896
80
0.741015
0
0
0
0
0
0
0
0
3,082
0.191965
cba9095436981a955ade3bb8b2c607697e624bf0
1,181
py
Python
quetz/migrations/versions/30241b33d849_add_task_pending_state.py
maresb/quetz
55313ca9c2ae04577d23a1dddb38c045b4a056f4
[ "BSD-3-Clause" ]
108
2020-09-16T16:15:01.000Z
2022-03-29T02:49:31.000Z
quetz/migrations/versions/30241b33d849_add_task_pending_state.py
maresb/quetz
55313ca9c2ae04577d23a1dddb38c045b4a056f4
[ "BSD-3-Clause" ]
317
2020-09-07T18:37:33.000Z
2022-03-25T13:10:41.000Z
quetz/migrations/versions/30241b33d849_add_task_pending_state.py
LaudateCorpus1/quetz
339018ee3c35ae6700bea611d16a9924a33a0606
[ "BSD-3-Clause" ]
36
2020-09-07T22:01:27.000Z
2022-03-26T17:06:07.000Z
"""add task pending state Revision ID: 30241b33d849 Revises: cd404ed93cc0 Create Date: 2021-01-07 14:39:43.251123 """ import sqlalchemy as sa from alembic import op # revision identifiers, used by Alembic. revision = '30241b33d849' down_revision = 'cd404ed93cc0' branch_labels = None depends_on = None def upgrade()...
26.244444
127
0.639289
0
0
0
0
0
0
0
0
600
0.508044
cbaa96df2a077d7e67016498747d36eb53959c6e
4,932
py
Python
tests/RL_cache.py
RasoulNik/Deep-Reinforcement-Learning-Algorithms-with-PyTorch
18d0111f94804ebe68aaa9610f71cdb3b4d271e8
[ "MIT" ]
null
null
null
tests/RL_cache.py
RasoulNik/Deep-Reinforcement-Learning-Algorithms-with-PyTorch
18d0111f94804ebe68aaa9610f71cdb3b4d271e8
[ "MIT" ]
null
null
null
tests/RL_cache.py
RasoulNik/Deep-Reinforcement-Learning-Algorithms-with-PyTorch
18d0111f94804ebe68aaa9610f71cdb3b4d271e8
[ "MIT" ]
null
null
null
import random import matplotlib.pyplot as plt import gym # from agents.actor_critic_agents.A2C import A2C # from agents.actor_critic_agents.A3C import A3C # from agents.actor_critic_agents.SAC import SAC from agents.actor_critic_agents.SAC_Discrete import SAC_Discrete # from agents.DQN_agents.DQN_HER import DQN_HER #...
36.80597
111
0.696067
0
0
0
0
0
0
0
0
3,005
0.609286
cbaae545764c50282977504f4e3f0989363b73d8
13,812
py
Python
train_meta.py
Huadous/eecs545finalproject
8e66128deaad687806d6f86c1b20da5983861a63
[ "MIT" ]
4
2021-12-09T08:00:00.000Z
2021-12-10T04:06:41.000Z
train_meta.py
Huadous/eecs545finalproject
8e66128deaad687806d6f86c1b20da5983861a63
[ "MIT" ]
null
null
null
train_meta.py
Huadous/eecs545finalproject
8e66128deaad687806d6f86c1b20da5983861a63
[ "MIT" ]
null
null
null
import os, argparse, torch, math, time, random from os.path import join, isfile import torch.nn.functional as F from torch.optim import SGD from torch.distributions import Beta from tensorboardX import SummaryWriter import torchvision import modified_vgg from dataloader import dataloader1 import dataloader from utils ...
44.269231
135
0.640602
0
0
0
0
1,189
0.086085
0
0
3,705
0.268245
cbacafb5f56c73013cbcb2e365565a0e912e919c
4,138
py
Python
Monitor/MonitorPlatform/webshell_detect/jsp_cnn_model.py
Leeyuxun/CNN-WebShell-Detect-Tool
c7858b08590734f0b81c0a36c1887a7f53a0b7ad
[ "Apache-2.0" ]
2
2022-01-08T01:52:59.000Z
2022-03-08T14:51:29.000Z
Monitor/MonitorPlatform/webshell_detect/jsp_cnn_model.py
Leeyuxun/CNN-WebShell-Detect-Tool
c7858b08590734f0b81c0a36c1887a7f53a0b7ad
[ "Apache-2.0" ]
null
null
null
Monitor/MonitorPlatform/webshell_detect/jsp_cnn_model.py
Leeyuxun/CNN-WebShell-Detect-Tool
c7858b08590734f0b81c0a36c1887a7f53a0b7ad
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 import commands import multiprocessing import os import re import gensim import numpy as np import tensorflow as tf import tflearn from sklearn import metrics from tflearn.data_utils import to_categorical from tflearn.layers.conv import conv_1d, global_max_pool from tflearn.layers.core import input_data...
39.409524
174
0.710488
0
0
0
0
0
0
0
0
1,543
0.347993
cbad9816e7e831c48ab81d643492857b4a3aa670
2,433
py
Python
Task1/1.py
phumin1994/AiTasks
92004196e1d31c062090a2df10fb4ec9751a661b
[ "MIT" ]
null
null
null
Task1/1.py
phumin1994/AiTasks
92004196e1d31c062090a2df10fb4ec9751a661b
[ "MIT" ]
null
null
null
Task1/1.py
phumin1994/AiTasks
92004196e1d31c062090a2df10fb4ec9751a661b
[ "MIT" ]
null
null
null
import pandas as pd df = pd.read_csv('data.csv') # read the data print(df) def median(list_vales): n_num = list_vales n = len(n_num) n_num.sort() if n % 2 == 0: median1 = n_num[n // 2] median2 = n_num[n // 2 - 1] median = (median1 + median2) / 2 else: median = n_n...
38.619048
104
0.602548
0
0
0
0
0
0
0
0
862
0.354295
cbaebd6bb5d7abbb741351bd7616c2e249f796fe
2,408
py
Python
RGBMatrixEmulator/graphics/__init__.py
WardBrian/RGBMatrixEmulator
edc17d6fac3fad5e313732e07b41798d5ab66cd2
[ "MIT" ]
null
null
null
RGBMatrixEmulator/graphics/__init__.py
WardBrian/RGBMatrixEmulator
edc17d6fac3fad5e313732e07b41798d5ab66cd2
[ "MIT" ]
null
null
null
RGBMatrixEmulator/graphics/__init__.py
WardBrian/RGBMatrixEmulator
edc17d6fac3fad5e313732e07b41798d5ab66cd2
[ "MIT" ]
null
null
null
from skimage.draw import line as sk_line from skimage.draw import circle_perimeter as sk_circle_perimeter from RGBMatrixEmulator.graphics.color import Color from RGBMatrixEmulator.graphics.font import Font def DrawText(canvas, font, x, y, color, text): # Early return for empty string prevents bugs in bdfparser l...
35.411765
102
0.620017
0
0
0
0
0
0
0
0
341
0.141611
cbaee4fc044ef35d2b85f72b5d495f1dbab0a143
1,291
py
Python
dorado/scheduling/scripts/skygrid.py
bwgref/dorado-scheduling
f3f8784bcc0646d10b7bc2c11040ef9c933b92b1
[ "NASA-1.3" ]
6
2021-03-02T04:44:21.000Z
2021-11-16T21:30:32.000Z
dorado/scheduling/scripts/skygrid.py
bwgref/dorado-scheduling
f3f8784bcc0646d10b7bc2c11040ef9c933b92b1
[ "NASA-1.3" ]
75
2021-03-11T21:00:02.000Z
2021-10-19T18:48:13.000Z
dorado/scheduling/scripts/skygrid.py
bwgref/dorado-scheduling
f3f8784bcc0646d10b7bc2c11040ef9c933b92b1
[ "NASA-1.3" ]
6
2021-03-11T17:34:35.000Z
2021-08-02T15:45:36.000Z
# # Copyright © 2021 United States Government as represented by the Administrator # of the National Aeronautics and Space Administration. No copyright is claimed # in the United States under Title 17, U.S. Code. All Other Rights Reserved. # # SPDX-License-Identifier: NASA-1.3 # """Generate a grid of pointings on the sk...
32.275
79
0.671572
0
0
0
0
0
0
0
0
525
0.406347
cbaf10d4a0aa43c5e434d348b34679078fdc57a8
1,475
py
Python
python/euler002/euler002.py
marvins/ProjectEuler
55a377bb9702067bac6908c1316c578498402668
[ "MIT" ]
null
null
null
python/euler002/euler002.py
marvins/ProjectEuler
55a377bb9702067bac6908c1316c578498402668
[ "MIT" ]
null
null
null
python/euler002/euler002.py
marvins/ProjectEuler
55a377bb9702067bac6908c1316c578498402668
[ "MIT" ]
1
2020-12-16T09:25:19.000Z
2020-12-16T09:25:19.000Z
#!/usr/bin/env python #---------------------------------# #- Fibonacci Lookup Table -# #---------------------------------# fib_table = {0:0, 1:1, 2:1, 3:2} #---------------------------------# #- Compute Fibonacci Value -# #---------------------------------# def Fibonacci( F ): # Check exit ...
19.666667
50
0.44
0
0
0
0
0
0
0
0
675
0.457627
cbaf1b82c2ecb6d4674dab39d250186c1e1db49e
42,365
py
Python
aiidalab_sssp/steps.py
aiidalab/aiidalab-sssp
4f06d7fdff32b86996e85b6c65b372a41f0192a4
[ "MIT" ]
null
null
null
aiidalab_sssp/steps.py
aiidalab/aiidalab-sssp
4f06d7fdff32b86996e85b6c65b372a41f0192a4
[ "MIT" ]
1
2022-03-28T10:22:31.000Z
2022-03-28T10:22:31.000Z
aiidalab_sssp/steps.py
aiidalab/aiidalab-sssp
4f06d7fdff32b86996e85b6c65b372a41f0192a4
[ "MIT" ]
1
2021-09-30T08:47:39.000Z
2021-09-30T08:47:39.000Z
"""widget for pseudo inmport""" import io import os import ipywidgets as ipw import traitlets from aiida import orm from aiida.common import NotExistent from aiida.engine import ProcessState, submit from aiida.orm import Node, ProcessNode, load_code from aiida.plugins import DataFactory, WorkflowFactory from aiida_sss...
35.511316
120
0.59214
41,062
0.969243
592
0.013974
2,661
0.062811
0
0
10,077
0.237861