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
205f3f36d35279bed8e26e086ddaae4845a10bf2
4,211
py
Python
docs/examples/04/do_mcmc.py
ast0815/likelihood-machine
4b0ebd193253775c31539c4a0046b79cbec8fa2b
[ "MIT" ]
null
null
null
docs/examples/04/do_mcmc.py
ast0815/likelihood-machine
4b0ebd193253775c31539c4a0046b79cbec8fa2b
[ "MIT" ]
1
2017-03-15T15:36:48.000Z
2017-03-15T15:36:48.000Z
docs/examples/04/do_mcmc.py
ast0815/likelihood-machine
4b0ebd193253775c31539c4a0046b79cbec8fa2b
[ "MIT" ]
null
null
null
import emcee import numpy as np from matplotlib import pyplot as plt from remu import binning, likelihood, likelihood_utils, plotting with open("../01/reco-binning.yml") as f: reco_binning = binning.yaml.full_load(f) with open("../01/optimised-truth-binning.yml") as f: truth_binning = binning.yaml.full_load(f...
30.294964
82
0.722156
0
0
0
0
0
0
0
0
570
0.13536
20628f6d5bc6347f947ff9c3729ba2edb1f796e2
4,464
py
Python
data/tracking/sampler/_sampling_algos/sequence_sampling/triplet/_algo.py
zhangzhengde0225/SwinTrack
526be17f8ef266cb924c6939bd8dda23e9b73249
[ "MIT" ]
143
2021-12-03T02:33:36.000Z
2022-03-29T00:01:48.000Z
data/tracking/sampler/_sampling_algos/sequence_sampling/triplet/_algo.py
zhangzhengde0225/SwinTrack
526be17f8ef266cb924c6939bd8dda23e9b73249
[ "MIT" ]
33
2021-12-03T10:32:05.000Z
2022-03-31T02:13:55.000Z
data/tracking/sampler/_sampling_algos/sequence_sampling/triplet/_algo.py
zhangzhengde0225/SwinTrack
526be17f8ef266cb924c6939bd8dda23e9b73249
[ "MIT" ]
24
2021-12-04T06:46:42.000Z
2022-03-30T07:57:47.000Z
import numpy as np from data.tracking.sampler.SiamFC.type import SiamesePairSamplingMethod from data.tracking.sampler._sampling_algos.stateless.random import sampling_multiple_indices_with_range_and_mask from data.tracking.sampler._sampling_algos.sequence_sampling.common._algo import sample_one_positive def do_triple...
44.19802
174
0.670475
0
0
0
0
0
0
0
0
19
0.004256
206298366159a32b63385b54342b7c1ecae4f4f8
6,887
py
Python
check.py
imayank/project4
3ccab23560dec09180199726fbf252ac934b7bc2
[ "MIT" ]
null
null
null
check.py
imayank/project4
3ccab23560dec09180199726fbf252ac934b7bc2
[ "MIT" ]
null
null
null
check.py
imayank/project4
3ccab23560dec09180199726fbf252ac934b7bc2
[ "MIT" ]
null
null
null
import pandas as pd import numpy as np import csv import matplotlib.pyplot as plt import matplotlib.image as mpimg from sklearn.model_selection import train_test_split from keras import regularizers from keras.models import Sequential from keras.layers import Dense, Flatten, Lambda, Cropping2D, Conv2D, MaxPooling2D, Ac...
36.057592
121
0.684333
0
0
855
0.124147
0
0
0
0
977
0.141861
20643ff79358dd0c7cd7ca78a7b0ae595e1e3aee
1,183
py
Python
TalentHunter/accounts/models.py
Hnachik/JobMatchingPfeProjectBack
fdf6e54c51a435681d34e750ee3c53024f76a3ec
[ "bzip2-1.0.6" ]
null
null
null
TalentHunter/accounts/models.py
Hnachik/JobMatchingPfeProjectBack
fdf6e54c51a435681d34e750ee3c53024f76a3ec
[ "bzip2-1.0.6" ]
null
null
null
TalentHunter/accounts/models.py
Hnachik/JobMatchingPfeProjectBack
fdf6e54c51a435681d34e750ee3c53024f76a3ec
[ "bzip2-1.0.6" ]
null
null
null
from django.contrib.auth.models import AbstractUser from django.db import models class User(AbstractUser): is_jobSeeker = models.BooleanField(default=False) is_recruiter = models.BooleanField(default=False) class Recruiter(models.Model): user = models.OneToOneField(User, on_delete=models.CASCADE, relate...
35.848485
89
0.746407
1,091
0.922232
0
0
0
0
0
0
29
0.024514
20646ade19d84e61c29fbfddf68aea6634664078
4,069
py
Python
editor/translate_new.py
NTUEELightDance/2019-LightDance
2e2689f868364e16972465abc22801aaeaf3d8ba
[ "MIT" ]
2
2019-07-16T10:40:52.000Z
2022-03-14T00:26:42.000Z
editor/translate_new.py
NTUEELightDance/2019-LightDance
2e2689f868364e16972465abc22801aaeaf3d8ba
[ "MIT" ]
null
null
null
editor/translate_new.py
NTUEELightDance/2019-LightDance
2e2689f868364e16972465abc22801aaeaf3d8ba
[ "MIT" ]
2
2019-12-01T07:40:04.000Z
2020-02-15T09:58:50.000Z
BPM_1 = 120.000 BPM_2 = 150.000 BPM_3 = 128.000 BPM_4 = 180.000 SEC_BEAT_1 = 60. / BPM_1 SEC_BEAT_2 = 60. / BPM_2 SEC_BEAT_3 = 60. / BPM_3 SEC_BEAT_4 = 60. / BPM_4 N_DANCER = 8 N_PART = 16 ''' 2019_eenight_bpm (v9) 00:00.00 - 01:22.00 BPM = 120 (41*4拍) 01:22.00 - 01:58.80 BPM = 150 (23*4拍) 01:58.80 - 02:40.05 BPM = 1...
20.974227
71
0.482182
0
0
0
0
0
0
0
0
1,047
0.256304
206543d34f0f4d7d479c2636f88d0e4e3752b2f7
90
py
Python
enthought/envisage/plugin_event.py
enthought/etsproxy
4aafd628611ebf7fe8311c9d1a0abcf7f7bb5347
[ "BSD-3-Clause" ]
3
2016-12-09T06:05:18.000Z
2018-03-01T13:00:29.000Z
enthought/envisage/plugin_event.py
enthought/etsproxy
4aafd628611ebf7fe8311c9d1a0abcf7f7bb5347
[ "BSD-3-Clause" ]
1
2020-12-02T00:51:32.000Z
2020-12-02T08:48:55.000Z
enthought/envisage/plugin_event.py
enthought/etsproxy
4aafd628611ebf7fe8311c9d1a0abcf7f7bb5347
[ "BSD-3-Clause" ]
null
null
null
# proxy module from __future__ import absolute_import from envisage.plugin_event import *
22.5
38
0.844444
0
0
0
0
0
0
0
0
14
0.155556
2066d9d51ccdadc9c2fac356ffcd5ca1583c63bd
5,538
py
Python
src/qt/qtwebkit/Tools/Scripts/webkitpy/style/checkers/python.py
viewdy/phantomjs
eddb0db1d253fd0c546060a4555554c8ee08c13c
[ "BSD-3-Clause" ]
1
2015-05-27T13:52:20.000Z
2015-05-27T13:52:20.000Z
src/qt/qtwebkit/Tools/Scripts/webkitpy/style/checkers/python.py
mrampersad/phantomjs
dca6f77a36699eb4e1c46f7600cca618f01b0ac3
[ "BSD-3-Clause" ]
null
null
null
src/qt/qtwebkit/Tools/Scripts/webkitpy/style/checkers/python.py
mrampersad/phantomjs
dca6f77a36699eb4e1c46f7600cca618f01b0ac3
[ "BSD-3-Clause" ]
1
2022-02-18T10:41:38.000Z
2022-02-18T10:41:38.000Z
# Copyright (C) 2010 Chris Jerdonek (cjerdonek@webkit.org) # # 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 of conditions and...
42.6
117
0.68039
3,786
0.68364
0
0
0
0
0
0
2,536
0.457927
20672c1e3cc7378701a319c6aa66a5c9cd3fe2a4
581
py
Python
avgamah/modules/NSFW/pussy.py
thenishantsapkota/Avgamah
c7f1f9a69f8a3f4c4ea53b25dbf62e272750f76c
[ "MIT" ]
6
2021-11-03T06:37:33.000Z
2022-01-26T15:09:37.000Z
avgamah/modules/NSFW/pussy.py
thenishantsapkota/Avgamah
c7f1f9a69f8a3f4c4ea53b25dbf62e272750f76c
[ "MIT" ]
7
2021-11-03T14:58:38.000Z
2022-03-29T23:16:21.000Z
avgamah/modules/NSFW/pussy.py
thenishantsapkota/Avgamah
c7f1f9a69f8a3f4c4ea53b25dbf62e272750f76c
[ "MIT" ]
1
2021-08-31T08:04:51.000Z
2021-08-31T08:04:51.000Z
import hikari import tanjun from avgamah.core.client import Client pussy_component = tanjun.Component() @pussy_component.with_slash_command @tanjun.with_own_permission_check( hikari.Permissions.SEND_MESSAGES | hikari.Permissions.VIEW_CHANNEL | hikari.Permissions.EMBED_LINKS ) @tanjun.with_nsfw_check @ta...
24.208333
61
0.79346
0
0
0
0
469
0.807229
103
0.177281
32
0.055077
20685d91ffa78a319f6c16393a78a8570e8e34ff
564
py
Python
test.py
DougDimmadome7/Virtual-Jenga
0344b21126b680826ffd13c10e328e04db9b7ade
[ "MIT" ]
null
null
null
test.py
DougDimmadome7/Virtual-Jenga
0344b21126b680826ffd13c10e328e04db9b7ade
[ "MIT" ]
null
null
null
test.py
DougDimmadome7/Virtual-Jenga
0344b21126b680826ffd13c10e328e04db9b7ade
[ "MIT" ]
null
null
null
from jenga import Tower, Layer from bots import StatBot def layer_suite(): subjects = {Layer(): (3, (1, 1.0)), Layer(False, False): (1, (1, 0.0))} for subject in subjects: if subject.get_mass() != subjects[subject][0]: print("Failed: Expected {}".format(subjects[subj...
25.636364
70
0.58156
0
0
0
0
0
0
0
0
42
0.074468
2068c0e986090c60cdb370c89725baad0a37fb2d
83
py
Python
python/tests/transducer_test.py
DevL/trancedeuce
a1daea44fd8b30f6392dc8ef0724432bef2a99a9
[ "MIT" ]
null
null
null
python/tests/transducer_test.py
DevL/trancedeuce
a1daea44fd8b30f6392dc8ef0724432bef2a99a9
[ "MIT" ]
null
null
null
python/tests/transducer_test.py
DevL/trancedeuce
a1daea44fd8b30f6392dc8ef0724432bef2a99a9
[ "MIT" ]
null
null
null
from transducer import Transducer def test_transducer(): Transducer pass
11.857143
33
0.746988
0
0
0
0
0
0
0
0
0
0
20692b1ffec59a043c4925ca299dd808accf86ea
179
py
Python
Introduction to Computer Science and Programing Using Python/Exercises/Week 2 - Function, Strings and Alogorithms/Polysum.py
Dittz/Learning_Python
4c0c97075ef5e1717f82e2cf24b0587f0c8504f5
[ "MIT" ]
null
null
null
Introduction to Computer Science and Programing Using Python/Exercises/Week 2 - Function, Strings and Alogorithms/Polysum.py
Dittz/Learning_Python
4c0c97075ef5e1717f82e2cf24b0587f0c8504f5
[ "MIT" ]
null
null
null
Introduction to Computer Science and Programing Using Python/Exercises/Week 2 - Function, Strings and Alogorithms/Polysum.py
Dittz/Learning_Python
4c0c97075ef5e1717f82e2cf24b0587f0c8504f5
[ "MIT" ]
null
null
null
from math import pi from math import tan def polysum(n, s): perimeter = n * s area = (0.25 * n * (s **2))/ (tan(pi/n)) result = perimeter**2 + area return result
19.888889
44
0.581006
0
0
0
0
0
0
0
0
0
0
206a29865133fb8ad4a844440e59032795701c2f
20,863
py
Python
test/socializer_test.py
aquanauts/tellus
d1185357b8a2f1106bbd951558dc040c709ff826
[ "MIT" ]
null
null
null
test/socializer_test.py
aquanauts/tellus
d1185357b8a2f1106bbd951558dc040c709ff826
[ "MIT" ]
null
null
null
test/socializer_test.py
aquanauts/tellus
d1185357b8a2f1106bbd951558dc040c709ff826
[ "MIT" ]
null
null
null
# pylint: skip-file import copy import random from tellus.configuration import TELLUS_INTERNAL from tellus.tell import Tell, SRC_TELLUS_USER from tellus.tellus_sources.socializer import Socializer, CoffeeBot from tellus.tellus_utils import datetime_from_string from tellus.users import UserManager from test.tells_test ...
36.991135
118
0.658247
0
0
0
0
0
0
11,957
0.57312
6,384
0.305996
206fa5a515032d90fcee492996c5a515f42a29c6
56
py
Python
enthought/pyface/ui/qt4/python_shell.py
enthought/etsproxy
4aafd628611ebf7fe8311c9d1a0abcf7f7bb5347
[ "BSD-3-Clause" ]
3
2016-12-09T06:05:18.000Z
2018-03-01T13:00:29.000Z
enthought/pyface/ui/qt4/python_shell.py
enthought/etsproxy
4aafd628611ebf7fe8311c9d1a0abcf7f7bb5347
[ "BSD-3-Clause" ]
1
2020-12-02T00:51:32.000Z
2020-12-02T08:48:55.000Z
enthought/pyface/ui/qt4/python_shell.py
enthought/etsproxy
4aafd628611ebf7fe8311c9d1a0abcf7f7bb5347
[ "BSD-3-Clause" ]
null
null
null
# proxy module from pyface.ui.qt4.python_shell import *
18.666667
40
0.785714
0
0
0
0
0
0
0
0
14
0.25
20708794a4f17c85e6ca5fdd6d42ecbb66c5770e
1,149
py
Python
plugins/trending/weibo.py
su226/IdhagnBot
a5db1b6ab69fdf67fd6e53a63b34c6bc863d6609
[ "MIT" ]
2
2022-02-14T06:37:05.000Z
2022-03-30T12:18:15.000Z
plugins/trending/weibo.py
su226/IdhagnBot
a5db1b6ab69fdf67fd6e53a63b34c6bc863d6609
[ "MIT" ]
null
null
null
plugins/trending/weibo.py
su226/IdhagnBot
a5db1b6ab69fdf67fd6e53a63b34c6bc863d6609
[ "MIT" ]
null
null
null
from typing import Any from aiohttp import ClientSession from .common import Item, strip_html API = "https://weibo.com/ajax/statuses/hot_band" IMG = "https://wx4.sinaimg.cn/large/{}.jpg" SEARCH = "https://s.weibo.com/weibo?q=%23{}%23" def get_image(data: Any) -> str: try: return IMG.format(data["mblog"]["pic_ids"][...
26.72093
59
0.610966
0
0
0
0
0
0
738
0.636756
298
0.257118
2071613e7a408eabf03c6b2b9802aa4339e771ee
955
py
Python
WEEKS/CD_Sata-Structures/general/practice/leetCode_30DaysOfCode/day_17/number_of_islands.py
webdevhub42/Lambda
b04b84fb5b82fe7c8b12680149e25ae0d27a0960
[ "MIT" ]
null
null
null
WEEKS/CD_Sata-Structures/general/practice/leetCode_30DaysOfCode/day_17/number_of_islands.py
webdevhub42/Lambda
b04b84fb5b82fe7c8b12680149e25ae0d27a0960
[ "MIT" ]
null
null
null
WEEKS/CD_Sata-Structures/general/practice/leetCode_30DaysOfCode/day_17/number_of_islands.py
webdevhub42/Lambda
b04b84fb5b82fe7c8b12680149e25ae0d27a0960
[ "MIT" ]
null
null
null
""" Given a 2d grid map of '1's (land) and '0's (water), count the number of islands. An island is surrounded by water and is formed by connecting adjacent lands horizontally or vertically. You may assume all four edges of the grid are all surrounded by water. """ def numIslands(grid): if grid is None and len(gri...
25.131579
114
0.503665
0
0
0
0
0
0
0
0
306
0.320419
2071b7738ea9668595f43aa1c16e6826cb81da1e
2,607
py
Python
tests/integration/helpers.py
canonical/alertmanager-operator
48faea21c701a2edefe853de5b04ac1faf6cd736
[ "Apache-2.0" ]
1
2021-03-28T14:37:13.000Z
2021-03-28T14:37:13.000Z
tests/integration/helpers.py
canonical/alertmanager-operator
48faea21c701a2edefe853de5b04ac1faf6cd736
[ "Apache-2.0" ]
14
2020-11-12T11:22:28.000Z
2021-09-23T23:51:05.000Z
tests/integration/helpers.py
canonical/alertmanager-operator
48faea21c701a2edefe853de5b04ac1faf6cd736
[ "Apache-2.0" ]
7
2020-11-11T23:10:41.000Z
2021-11-12T14:11:14.000Z
# Copyright 2021 Canonical Ltd. # See LICENSE file for licensing details. """Helper functions for writing tests.""" import logging from typing import Dict from pytest_operator.plugin import OpsTest log = logging.getLogger(__name__) async def get_unit_address(ops_test: OpsTest, app_name: str, unit_num: int) -> str...
31.792683
93
0.667817
1,037
0.397775
0
0
0
0
1,629
0.624856
1,059
0.406214
207275b58d80650023d7512a278cfc21b82f461a
1,841
py
Python
c3py/regions.py
h0s/c3py
6fb669dd07e9a8433631b64b08213f5f38606ca1
[ "MIT" ]
1
2015-11-20T05:43:15.000Z
2015-11-20T05:43:15.000Z
c3py/regions.py
h0s/c3py
6fb669dd07e9a8433631b64b08213f5f38606ca1
[ "MIT" ]
null
null
null
c3py/regions.py
h0s/c3py
6fb669dd07e9a8433631b64b08213f5f38606ca1
[ "MIT" ]
null
null
null
from .chart_component import ChartComponentList class Regions(ChartComponentList): """ Highlight selected regions on the chart. Parameters ---------- axes : c3py.axes.Axes The chart's Axes object. """ def __init__(self, axes): super(Regions, self).__init__() se...
24.878378
116
0.516567
1,791
0.972841
0
0
0
0
0
0
1,026
0.557306
2072be0c4aa28bf08e6acf94dbe34fa893e5ddc8
4,420
py
Python
projects/2project/NeuralNetwork/SolutionNNRegressionKeras.py
fridtjrg/FYS-STK4155
071a039c9c9994c0d125b9432c05ddb08991bca9
[ "MIT" ]
null
null
null
projects/2project/NeuralNetwork/SolutionNNRegressionKeras.py
fridtjrg/FYS-STK4155
071a039c9c9994c0d125b9432c05ddb08991bca9
[ "MIT" ]
1
2021-10-03T15:16:07.000Z
2021-10-03T15:16:07.000Z
projects/2project/NeuralNetwork/SolutionNNRegressionKeras.py
fridtjrg/FYS-STK4155
071a039c9c9994c0d125b9432c05ddb08991bca9
[ "MIT" ]
null
null
null
import tensorflow as tf import numpy as np from tensorflow.keras.layers import Dense, Activation from tensorflow.keras.models import Sequential import matplotlib.pyplot as plt import seaborn as sns sns.set() #====================== DATA import sys sys.path.append("../Data") from DataRegression import X, X_test, X_trai...
30.482759
139
0.597285
0
0
0
0
0
0
0
0
1,405
0.317873
20737648d812b6fad6bec05c7ca144f99ca2d842
2,551
py
Python
src/tf_imgaug/sequential.py
Marselliy/tf-aug
478a632e1822722a74397a169b0b63bd0c5692e7
[ "MIT" ]
1
2019-01-11T15:36:24.000Z
2019-01-11T15:36:24.000Z
src/tf_imgaug/sequential.py
Marselliy/tf-aug
478a632e1822722a74397a169b0b63bd0c5692e7
[ "MIT" ]
null
null
null
src/tf_imgaug/sequential.py
Marselliy/tf-aug
478a632e1822722a74397a169b0b63bd0c5692e7
[ "MIT" ]
null
null
null
import random import tensorflow as tf class Sequential: def __init__(self, augments, seed=random.randint(0, 2 ** 32), n_augments=1, keypoints_format='xy', bboxes_format='xyxy'): self.augments = augments for aug in augments: aug._set_formats(keypoints_format, bboxes_format) self....
39.859375
141
0.531164
2,510
0.983928
0
0
0
0
0
0
31
0.012152
20752a68676d3d8a6893e798673529b3ef5ebcf1
6,585
py
Python
ifitwala_ed/school_settings/doctype/school_calendar/school_calendar.py
mohsinalimat/ifitwala_ed
8927695ed9dee36e56571c442ebbe6e6431c7d46
[ "MIT" ]
13
2020-09-02T10:27:57.000Z
2022-03-11T15:28:46.000Z
ifitwala_ed/school_settings/doctype/school_calendar/school_calendar.py
mohsinalimat/ifitwala_ed
8927695ed9dee36e56571c442ebbe6e6431c7d46
[ "MIT" ]
43
2020-09-02T07:00:42.000Z
2021-07-05T13:22:58.000Z
ifitwala_ed/school_settings/doctype/school_calendar/school_calendar.py
mohsinalimat/ifitwala_ed
8927695ed9dee36e56571c442ebbe6e6431c7d46
[ "MIT" ]
6
2020-10-19T01:02:18.000Z
2022-03-11T15:28:47.000Z
# -*- coding: utf-8 -*- # Copyright (c) 2020, ifitwala and contributors # For license information, please see license.txt from __future__ import unicode_literals import frappe import json from frappe import _ from frappe.utils import get_link_to_form, today, getdate, formatdate, date_diff, cint from frappe.model.docum...
44.795918
202
0.672134
5,745
0.872437
0
0
2,474
0.375702
0
0
1,189
0.180562
20779422059fa5a2638b842b8fa63f7290a8df78
2,824
py
Python
inbm/cloudadapter-agent/cloudadapter/cloudadapter.py
ahameedx/intel-inb-manageability
aca445fa4cef0b608e6e88e74476547e10c06073
[ "Apache-2.0" ]
5
2021-12-13T21:19:31.000Z
2022-01-18T18:29:43.000Z
inbm/cloudadapter-agent/cloudadapter/cloudadapter.py
ahameedx/intel-inb-manageability
aca445fa4cef0b608e6e88e74476547e10c06073
[ "Apache-2.0" ]
45
2021-12-30T17:21:09.000Z
2022-03-29T22:47:32.000Z
inbm/cloudadapter-agent/cloudadapter/cloudadapter.py
ahameedx/intel-inb-manageability
aca445fa4cef0b608e6e88e74476547e10c06073
[ "Apache-2.0" ]
4
2022-01-26T17:42:54.000Z
2022-03-30T04:48:04.000Z
#!/usr/bin/python """ Agent that monitors and reports the state of critical components of the framework """ import platform from typing import Optional, List from cloudadapter.client import Client from cloudadapter.constants import LOGGERCONFIG from cloudadapter.exceptions import BadConfigError from cloudadapter.uti...
27.417476
99
0.642351
1,813
0.641997
0
0
0
0
0
0
642
0.227337
2077e6ee17f7f602136cebfbf7dc6c070eaa7ba8
4,106
py
Python
utils/LandFire_TAW/ndvi_processing.py
NMTHydro/Recharge
bbc1a05add92064acffeffb19f04e370b99a7918
[ "Apache-2.0" ]
7
2016-08-30T15:18:11.000Z
2021-08-22T00:28:10.000Z
utils/LandFire_TAW/ndvi_processing.py
NMTHydro/Recharge
bbc1a05add92064acffeffb19f04e370b99a7918
[ "Apache-2.0" ]
2
2016-06-08T06:41:45.000Z
2016-06-23T20:47:26.000Z
utils/LandFire_TAW/ndvi_processing.py
NMTHydro/Recharge
bbc1a05add92064acffeffb19f04e370b99a7918
[ "Apache-2.0" ]
1
2018-09-18T10:38:08.000Z
2018-09-18T10:38:08.000Z
# =============================================================================== # Copyright 2018 gabe-parrish # # 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/licen...
39.480769
107
0.681442
0
0
0
0
0
0
0
0
1,877
0.457136
207a7db873682c7d633f14d1d74adaba1fed2784
5,947
py
Python
prometheus_network_exporter/config/functions/junos.py
networkmess/prometheus-network-exporter
4e7febb7e13447fd3612e591fbb2f634f97a5101
[ "MIT" ]
11
2018-12-13T05:39:24.000Z
2022-01-07T16:59:59.000Z
prometheus_network_exporter/config/functions/junos.py
networkmess/prometheus-network-exporter
4e7febb7e13447fd3612e591fbb2f634f97a5101
[ "MIT" ]
11
2018-11-29T20:43:44.000Z
2020-11-14T22:33:50.000Z
prometheus_network_exporter/config/functions/junos.py
networkmess/prometheus-network-exporter
4e7febb7e13447fd3612e591fbb2f634f97a5101
[ "MIT" ]
2
2021-09-11T22:28:56.000Z
2021-09-11T22:43:19.000Z
from typing import Union import logging from ...utitlities import create_list_from_dict from ..configuration import LabelConfiguration, MetricConfiguration def default(value) -> float: if isinstance(value, list): return default(value[0]) return 0 if value is None else float(value) def is_ok(boolean:...
34.375723
87
0.669077
0
0
0
0
0
0
0
0
631
0.106104
207ab28606db0bcb88724f2edd658e5f7978954f
1,492
py
Python
lib-python/io/proxies/fragment.py
geoffxy/tandem
81e76f675634f1b42c8c3070c73443f3f68f8624
[ "Apache-2.0" ]
732
2018-03-11T03:35:17.000Z
2022-01-06T12:22:03.000Z
lib-python/io/proxies/fragment.py
geoffxy/tandem
81e76f675634f1b42c8c3070c73443f3f68f8624
[ "Apache-2.0" ]
21
2018-03-11T02:28:22.000Z
2020-08-30T15:36:40.000Z
plugin/tandem_lib/agent/tandem/shared/io/proxies/fragment.py
typeintandem/vim
e076a9954d73ccb60cd6828e53adf8da76462fc6
[ "Apache-2.0" ]
24
2018-03-14T05:37:17.000Z
2022-01-18T14:44:42.000Z
from tandem.shared.io.proxies.base import ProxyBase from tandem.shared.utils.fragment import FragmentUtils class FragmentProxy(ProxyBase): def __init__(self, max_message_length=512): self._max_message_length = max_message_length def pre_generate_io_data(self, params): args, kwargs = params ...
30.44898
75
0.586461
1,382
0.926273
0
0
0
0
0
0
0
0
207b5782368cc522ab6d38370f4b51ed010dc707
8,888
py
Python
integresql_client_python/__init__.py
msztolcman/integresql-client-python
8636434f20ab771ac66885f3bdfe819a7e9ebbfe
[ "MIT" ]
2
2021-05-20T18:38:41.000Z
2021-06-26T23:10:27.000Z
integresql_client_python/__init__.py
msztolcman/integresql-client-python
8636434f20ab771ac66885f3bdfe819a7e9ebbfe
[ "MIT" ]
null
null
null
integresql_client_python/__init__.py
msztolcman/integresql-client-python
8636434f20ab771ac66885f3bdfe819a7e9ebbfe
[ "MIT" ]
2
2021-06-02T13:39:56.000Z
2021-06-14T02:11:05.000Z
__all__ = ['IntegreSQL', 'DBInfo', 'Database', 'Template'] import hashlib import http.client import os import pathlib import sys from typing import Optional, NoReturn, Union, List import requests from . import errors __version__ = '0.9.2' ENV_INTEGRESQL_CLIENT_BASE_URL = 'INTEGRESQL_CLIENT_BASE_URL' ENV_INTEGRESQL_...
33.923664
121
0.6259
8,403
0.945432
0
0
1,197
0.134676
0
0
1,290
0.14514
207b985f54a451ba05a83c7321110571f9b36581
97
py
Python
aws_resources/tests/test_dynamo.py
jottenlips/tinyauth
2c7e5e65e08627795748656f5b3d4122f836d6cd
[ "MIT" ]
3
2020-06-07T18:43:25.000Z
2021-03-30T14:42:40.000Z
aws_resources/tests/test_dynamo.py
jottenlips/tinyauth
2c7e5e65e08627795748656f5b3d4122f836d6cd
[ "MIT" ]
2
2021-04-30T21:09:00.000Z
2021-05-11T11:10:14.000Z
aws_resources/tests/test_dynamo.py
jottenlips/tinyauth
2c7e5e65e08627795748656f5b3d4122f836d6cd
[ "MIT" ]
1
2020-04-26T16:24:52.000Z
2020-04-26T16:24:52.000Z
from aws_resources.dynamo import table def test_table(): db = table() assert db != None
16.166667
38
0.680412
0
0
0
0
0
0
0
0
0
0
207bb34267342365082bfa8ac841a3deb5a45c41
1,653
py
Python
src/euler_python_package/euler_python/medium/p265.py
wilsonify/euler
5214b776175e6d76a7c6d8915d0e062d189d9b79
[ "MIT" ]
null
null
null
src/euler_python_package/euler_python/medium/p265.py
wilsonify/euler
5214b776175e6d76a7c6d8915d0e062d189d9b79
[ "MIT" ]
null
null
null
src/euler_python_package/euler_python/medium/p265.py
wilsonify/euler
5214b776175e6d76a7c6d8915d0e062d189d9b79
[ "MIT" ]
null
null
null
# In this problem we look at 2^n-digit binary strings and the n-digit substrings of these. # We are given that n = 5, so we are looking at windows of 5 bits in 32-bit strings. # # There are of course 32 possible cyclic windows in a 32-bit string. # We want each of these windows to be a unique 5-bit string. There are ex...
44.675676
91
0.69026
0
0
0
0
0
0
0
0
1,142
0.690865
207ca71d5a53e255c1c332a5b53aede5e33b9205
17,727
py
Python
scripts/mapping4SNP_v2.0_multipleMaps.py
PerisD/Sac2.0
274aeca4f6298b2d1d816e5640bf3f67bb5dd729
[ "CC0-1.0" ]
null
null
null
scripts/mapping4SNP_v2.0_multipleMaps.py
PerisD/Sac2.0
274aeca4f6298b2d1d816e5640bf3f67bb5dd729
[ "CC0-1.0" ]
null
null
null
scripts/mapping4SNP_v2.0_multipleMaps.py
PerisD/Sac2.0
274aeca4f6298b2d1d816e5640bf3f67bb5dd729
[ "CC0-1.0" ]
null
null
null
__author__ = 'Peris' #!/usr/bin/env python #coding: utf-8 import argparse from subprocess import call import os import shutil import glob from Bio import SeqIO helptext=""" This script is to map reads to a reference assembly to generate an alignment for population genomics. The output requires to convert N sites to ...
67.660305
499
0.690416
0
0
0
0
0
0
0
0
6,780
0.382467
207f20ff7bc96059db1255846744ebb0c03d9e3f
25,099
py
Python
lib/geomet/wkb.py
davasqueza/eriskco_conector_CloudSQL
99304b5eed06e9bba3646535a82d7fc98b0838b7
[ "Apache-2.0" ]
null
null
null
lib/geomet/wkb.py
davasqueza/eriskco_conector_CloudSQL
99304b5eed06e9bba3646535a82d7fc98b0838b7
[ "Apache-2.0" ]
null
null
null
lib/geomet/wkb.py
davasqueza/eriskco_conector_CloudSQL
99304b5eed06e9bba3646535a82d7fc98b0838b7
[ "Apache-2.0" ]
null
null
null
# Copyright 2013 Lars Butler & individual contributors # # 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 applicab...
31.217662
79
0.620742
0
0
0
0
0
0
0
0
9,272
0.369417
207f55f29edfdd3fe87e918760b34c1f86506336
292
py
Python
algorithms/sorting/bubble_sort.py
Byung-June/coding_test_study
aca82da72ba4a6147e35af3749844dc53de682a3
[ "MIT" ]
null
null
null
algorithms/sorting/bubble_sort.py
Byung-June/coding_test_study
aca82da72ba4a6147e35af3749844dc53de682a3
[ "MIT" ]
null
null
null
algorithms/sorting/bubble_sort.py
Byung-June/coding_test_study
aca82da72ba4a6147e35af3749844dc53de682a3
[ "MIT" ]
null
null
null
nums = [5,2,31,2,5,7, 9, 10] def bubble_sort(nums): for i in range(len(nums)-1, 0, -1): for j in range(i): if nums[j] > nums[j+1]: temp = nums[j] nums[j] = nums[j+1] nums[j+1] = temp return nums bubble_sort(nums)
20.857143
39
0.455479
0
0
0
0
0
0
0
0
0
0
20803faf55678d4849c7071017ef34216a20319c
2,104
py
Python
tests/test_can_delete.py
Jesse-Yung/jsonclasses
d40c52aec42bcb978a80ceb98b93ab38134dc790
[ "MIT" ]
50
2021-08-18T08:08:04.000Z
2022-03-20T07:23:26.000Z
tests/test_can_delete.py
Jesse-Yung/jsonclasses
d40c52aec42bcb978a80ceb98b93ab38134dc790
[ "MIT" ]
1
2021-02-21T03:18:09.000Z
2021-03-08T01:07:52.000Z
tests/test_can_delete.py
Jesse-Yung/jsonclasses
d40c52aec42bcb978a80ceb98b93ab38134dc790
[ "MIT" ]
8
2021-07-01T02:39:15.000Z
2021-12-10T02:20:18.000Z
from __future__ import annotations from unittest import TestCase from jsonclasses.excs import UnauthorizedActionException from tests.classes.gs_product import GSProduct, GSProductUser, GSTProduct from tests.classes.gm_product import GMProduct, GMProductUser class TestCanDelete(TestCase): def test_guards_raises_i...
39.698113
75
0.687738
1,843
0.875951
0
0
0
0
0
0
63
0.029943
2080689aca7d1f7a58ef8c5ff65a1a1fdd0f61ff
715
py
Python
3-longest-substring-without-repeating-characters.py
XianwuLin/leetcode
87f3c26f1cf16876a01585857aed6c524c8b31b8
[ "MIT" ]
null
null
null
3-longest-substring-without-repeating-characters.py
XianwuLin/leetcode
87f3c26f1cf16876a01585857aed6c524c8b31b8
[ "MIT" ]
null
null
null
3-longest-substring-without-repeating-characters.py
XianwuLin/leetcode
87f3c26f1cf16876a01585857aed6c524c8b31b8
[ "MIT" ]
null
null
null
# encoding=utf-8 # 解题思路: # 依旧用了空间换时间的思路,记录找到的每个没有重复的子串的长度,然后求这些长度的最大值。 # 这里需要注意发现字符a已经在上一个子串中的时候,下一个子串应该是从上一个子串的a的下一位开始,而不是从a开始。 class Solution(object): def lengthOfLongestSubstring(self, s): """ :type s: str :rtype: int """ first = [0] now = "" for index, ...
22.34375
65
0.513287
433
0.473224
0
0
0
0
0
0
407
0.444809
208118ac1558f15291a466df173c06353392d5a4
2,112
py
Python
scripts/matplot_hardware_comparison.py
shenweihai1/rolis-eurosys2022
59b3fd58144496a9b13415e30b41617b34924323
[ "MIT" ]
null
null
null
scripts/matplot_hardware_comparison.py
shenweihai1/rolis-eurosys2022
59b3fd58144496a9b13415e30b41617b34924323
[ "MIT" ]
null
null
null
scripts/matplot_hardware_comparison.py
shenweihai1/rolis-eurosys2022
59b3fd58144496a9b13415e30b41617b34924323
[ "MIT" ]
null
null
null
import matplotlib import matplotlib.pyplot as plt import numpy as np from matplotlib.ticker import FuncFormatter def millions(x, pos): return '%1.1fM' % (x * 1e-6) formatter = FuncFormatter(millions) txt = """ 4 381682 159258 1.61E+06 8 773030 366397 3.00E+06 12 1103917 519834 4.30E+06 16 1358805 740740 5.67E+06 ...
34.622951
148
0.676136
0
0
0
0
0
0
0
0
750
0.355114
208258846b51fff8cd031222e2f3da0eb301099e
11,741
py
Python
bintray-cleanup/bintray_cleanup/main.py
openzipkin/zipkin-release
4508fca409783e62169382aff06fd7c32ad20a63
[ "Apache-2.0" ]
2
2017-08-07T10:00:52.000Z
2019-06-25T01:59:22.000Z
bintray-cleanup/bintray_cleanup/main.py
openzipkin/zipkin-release
4508fca409783e62169382aff06fd7c32ad20a63
[ "Apache-2.0" ]
3
2017-04-11T05:20:11.000Z
2019-07-24T23:22:16.000Z
bintray-cleanup/bintray_cleanup/main.py
openzipkin/zipkin-release
4508fca409783e62169382aff06fd7c32ad20a63
[ "Apache-2.0" ]
1
2017-09-19T08:38:07.000Z
2017-09-19T08:38:07.000Z
#!/usr/bin/env python3 import json import textwrap from collections import defaultdict from dataclasses import dataclass from datetime import datetime, timedelta, timezone from typing import Callable, Dict, List, Optional import click import pygments import pygments.formatters import pygments.lexers import requests_ca...
31.226064
87
0.638106
1,652
0.140704
0
0
4,266
0.363342
0
0
2,469
0.210289
2082b1a4f9ffc658b8fe8bd47773012afce06769
688
py
Python
backup_nanny/ami_cleanup.py
ForwardLine/backup-nanny
67c687f43d732c60ab2e569e50bc40cc5e696b25
[ "Apache-2.0" ]
1
2019-11-13T04:15:41.000Z
2019-11-13T04:15:41.000Z
backup_nanny/ami_cleanup.py
ForwardLine/backup-nanny
67c687f43d732c60ab2e569e50bc40cc5e696b25
[ "Apache-2.0" ]
null
null
null
backup_nanny/ami_cleanup.py
ForwardLine/backup-nanny
67c687f43d732c60ab2e569e50bc40cc5e696b25
[ "Apache-2.0" ]
1
2019-10-25T21:24:20.000Z
2019-10-25T21:24:20.000Z
#!/usr/bin/env python from backup_nanny.util.env_loader import ENVLoader from backup_nanny.util.log import Log from backup_nanny.util.backup_helper import BackupHelper def handler(event, context): main(event) def main(event): log = Log() try: backup_helper = BackupHelper(log=log) backup_...
25.481481
69
0.700581
0
0
0
0
0
0
0
0
38
0.055233
208372cd97ff6cd39df211ced3240a7c03da900d
4,179
py
Python
msn/tests/test_events.py
mleger45/turnex
2b805c3681fe6ce3ddad403270c09ac9900fbe7d
[ "MIT" ]
null
null
null
msn/tests/test_events.py
mleger45/turnex
2b805c3681fe6ce3ddad403270c09ac9900fbe7d
[ "MIT" ]
1
2021-04-12T05:14:28.000Z
2021-04-12T05:14:28.000Z
msn/tests/test_events.py
mleger45/turnex
2b805c3681fe6ce3ddad403270c09ac9900fbe7d
[ "MIT" ]
null
null
null
# -*- coding:utf-8 -*- import json from django.test import TestCase from unittest.mock import patch, MagicMock from msn.events import EventTurnex class EventTurnexTest(TestCase): def setUp(self): self.events = EventTurnex() @patch('msn.events.EventTurnex.valid') def test_process_with_v...
29.85
74
0.589375
4,028
0.963867
0
0
1,013
0.242402
0
0
518
0.123953
208521b0cff34706ddce62eebc847a4ed84c31d5
1,044
py
Python
tests/test_no_identity.py
iexg/aiohttp-security
225b0c989e397bc741159e0ccc6b54eb7add3f94
[ "Apache-2.0" ]
null
null
null
tests/test_no_identity.py
iexg/aiohttp-security
225b0c989e397bc741159e0ccc6b54eb7add3f94
[ "Apache-2.0" ]
null
null
null
tests/test_no_identity.py
iexg/aiohttp-security
225b0c989e397bc741159e0ccc6b54eb7add3f94
[ "Apache-2.0" ]
null
null
null
from aiohttp import web from aiohttp_security import remember, forget async def test_remember(loop, test_client): async def do_remember(request): response = web.Response() await remember(request, response, 'Andrew') app = web.Application(loop=loop) app.router.add_route('POST', '/', do_re...
29.828571
57
0.64751
0
0
0
0
0
0
968
0.927203
194
0.185824
208788b7bd11e361a5d176ed481e96bc882babed
5,385
py
Python
create_TFRecords.py
LemonLov/Create_TFRecords
4274b3c2bfd2c041d0a8189f63b394b79edcf025
[ "BSD-2-Clause" ]
2
2020-09-12T03:10:30.000Z
2020-09-13T06:18:00.000Z
create_TFRecords.py
LemonLov/Create_TFRecords
4274b3c2bfd2c041d0a8189f63b394b79edcf025
[ "BSD-2-Clause" ]
null
null
null
create_TFRecords.py
LemonLov/Create_TFRecords
4274b3c2bfd2c041d0a8189f63b394b79edcf025
[ "BSD-2-Clause" ]
null
null
null
# *-* coding:utf-8 *-* import tensorflow as tf import numpy as np import os import cv2 import random # 生成整数型的属性 def _int64_feature(value): return tf.train.Feature(int64_list=tf.train.Int64List(value=[value])) # 生成字符串型的属性 def _bytes_feature(value): return tf.train.Feature(bytes_list=tf.train.BytesList(value=[...
34.299363
125
0.659239
0
0
0
0
0
0
0
0
2,636
0.424545
2087a291b6146f0ef00a3da950e1b29854405f84
9,694
py
Python
curses_interface.py
danomagnum/rpncalc
0c1242f3716b9bd2bd27cb80b9471ae843c1ee74
[ "MIT" ]
null
null
null
curses_interface.py
danomagnum/rpncalc
0c1242f3716b9bd2bd27cb80b9471ae843c1ee74
[ "MIT" ]
null
null
null
curses_interface.py
danomagnum/rpncalc
0c1242f3716b9bd2bd27cb80b9471ae843c1ee74
[ "MIT" ]
null
null
null
import rpncalc #import readline import curses import sys import os import math import pkgutil import settings STACK = 0 GRAPH_XY = 1 GRAPH_X = 2 mode = STACK screen = curses.initscr() screen.keypad(1) YMAX, XMAX = screen.getmaxyx() curses.noecho() stackbox = curses.newwin(YMAX-4,XMAX -1,0,0) inputbox = curses.newwi...
24.356784
80
0.657726
78
0.008046
299
0.030844
0
0
0
0
608
0.062719
208912d6f6d0a9d6a2c0d77936e735ebc5845e01
452
py
Python
ex081.py
BrianBeyer/pythonExercicios
062e2c6a9e6e6f513185f1fb1d4269d8ca1d9e89
[ "MIT" ]
null
null
null
ex081.py
BrianBeyer/pythonExercicios
062e2c6a9e6e6f513185f1fb1d4269d8ca1d9e89
[ "MIT" ]
null
null
null
ex081.py
BrianBeyer/pythonExercicios
062e2c6a9e6e6f513185f1fb1d4269d8ca1d9e89
[ "MIT" ]
null
null
null
valores = [] c = 0 resp = 'S' cinco = 0 while resp in 'Ss': v = valores.append(int(input('Digite um valor:'))) resp = str(input('Quer continuar? [S/N]:')).upper().strip()[0] c+=1 print(f'Você digitou {c} valores')# ou len(valores) valores.sort(reverse=True) print(f'Os valores em ordem decrescente são {valor...
30.133333
66
0.652655
0
0
0
0
0
0
0
0
224
0.492308
2089574d1cedb0d9edbb6825a3a98e6d9859fb54
6,649
py
Python
config/settings/base.py
SimeonAleksov/shawty
9c51c0c0d64950045d5b7edf8bf86c4e084e5920
[ "Apache-2.0" ]
null
null
null
config/settings/base.py
SimeonAleksov/shawty
9c51c0c0d64950045d5b7edf8bf86c4e084e5920
[ "Apache-2.0" ]
3
2022-02-28T12:04:19.000Z
2022-03-02T12:05:29.000Z
config/settings/base.py
SimeonAleksov/shawty
9c51c0c0d64950045d5b7edf8bf86c4e084e5920
[ "Apache-2.0" ]
null
null
null
""" Base settings to build other settings files upon. """ import os from pathlib import Path import environ # ROOT_DIR = Path(__file__).resolve(strict=True).parent.parent.parent ROOT_DIR = (environ.Path(__file__) - 3) APPS_DIR = ROOT_DIR.path("shawty") NUXT_APP_DIR = ROOT_DIR.path('client') env = environ.Env() READ_...
30.360731
90
0.676342
0
0
0
0
0
0
0
0
4,163
0.626109
2089e701f232686bde232f252421fe8e4203a707
7,468
py
Python
clairmeta/settings.py
Kariboupseudo/ClairMeta
e0a26073935f07abda84d9abf0f194716854292f
[ "BSD-3-Clause" ]
null
null
null
clairmeta/settings.py
Kariboupseudo/ClairMeta
e0a26073935f07abda84d9abf0f194716854292f
[ "BSD-3-Clause" ]
null
null
null
clairmeta/settings.py
Kariboupseudo/ClairMeta
e0a26073935f07abda84d9abf0f194716854292f
[ "BSD-3-Clause" ]
null
null
null
# Clairmeta - (C) YMAGIS S.A. # See LICENSE for more information LOG_SETTINGS = { 'level': 'INFO', 'enable_console': True, 'enable_file': True, 'file_name': '~/Library/Logs/clairmeta.log', 'file_size': 1e6, 'file_count': 10, } DCP_SETTINGS = { # ISDCF Naming Convention enforced 'naming...
39.935829
99
0.573246
0
0
0
0
0
0
0
0
5,184
0.694162
208ab0efab1a44dca566c2b25386582351d6f44f
1,465
py
Python
examples/tf/reps_gym_cartpole.py
thanhkaist/garage
1d840df357282a675b8fce839bb0e5f72a8abba9
[ "MIT" ]
7
2022-02-01T03:02:24.000Z
2022-02-10T12:54:05.000Z
examples/tf/reps_gym_cartpole.py
thanhkaist/garage
1d840df357282a675b8fce839bb0e5f72a8abba9
[ "MIT" ]
null
null
null
examples/tf/reps_gym_cartpole.py
thanhkaist/garage
1d840df357282a675b8fce839bb0e5f72a8abba9
[ "MIT" ]
2
2022-02-03T03:33:25.000Z
2022-02-10T12:54:07.000Z
#!/usr/bin/env python3 """This is an example to train a task with REPS algorithm. Here it runs gym CartPole env with 100 iterations. Results: AverageReturn: 100 +/- 40 RiseTime: itr 10 +/- 5 """ import gym from garage import wrap_experiment from garage.envs import GarageEnv from garage.experiment import Lo...
27.641509
79
0.690102
0
0
0
0
916
0.625256
0
0
517
0.352901
208b5a19512f2c1942088dd7f08d4f5e98808037
869
py
Python
examples/python_in_cpp/python_src/py_display.py
aff3ct/py_aff3ct
8afb7e6b1db1b621db0ae4153b29a2e848e09fcf
[ "MIT" ]
15
2021-01-24T11:59:04.000Z
2022-03-23T07:23:44.000Z
examples/python_in_cpp/python_src/py_display.py
aff3ct/py_aff3ct
8afb7e6b1db1b621db0ae4153b29a2e848e09fcf
[ "MIT" ]
8
2021-05-24T18:22:45.000Z
2022-03-11T09:48:05.000Z
examples/python_in_cpp/python_src/py_display.py
aff3ct/py_aff3ct
8afb7e6b1db1b621db0ae4153b29a2e848e09fcf
[ "MIT" ]
4
2021-01-26T19:18:21.000Z
2021-12-07T17:02:34.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- import sys sys.path.insert(0, '../../../build/lib') import numpy as np import matplotlib.pyplot as plt from py_aff3ct.module.py_module import Py_Module class Display(Py_Module): def plot(self, x): if self.i_plt % 50 == 0: self.line.set_data(x[0,::2], x[0,1::2]) ...
24.828571
59
0.654776
667
0.767549
0
0
0
0
0
0
105
0.120829
208b826ac073ffc78e9fc4a4daa39a825a8767d0
3,906
py
Python
tests/_dao/TestRTKEnvironment.py
rakhimov/rtk
adc35e218ccfdcf3a6e3082f6a1a1d308ed4ff63
[ "BSD-3-Clause" ]
null
null
null
tests/_dao/TestRTKEnvironment.py
rakhimov/rtk
adc35e218ccfdcf3a6e3082f6a1a1d308ed4ff63
[ "BSD-3-Clause" ]
null
null
null
tests/_dao/TestRTKEnvironment.py
rakhimov/rtk
adc35e218ccfdcf3a6e3082f6a1a1d308ed4ff63
[ "BSD-3-Clause" ]
2
2020-04-03T04:14:42.000Z
2021-02-22T05:30:35.000Z
#!/usr/bin/env python -O # -*- coding: utf-8 -*- # # tests.unit._dao.TestRTKEnvironment.py is part of The RTK Project # # All rights reserved. """ This is the test class for testing the RTKEnvironment module algorithms and models. """ import sys from os.path import dirname sys.path.insert( 0, dirname(d...
31.248
111
0.647465
3,158
0.8085
0
0
2,214
0.56682
0
0
1,409
0.360727
208d55bf2af77c0581700d580f1805b2e51b5213
30,297
py
Python
model/dualposenet.py
wx-b/DualPoseNet
393f786a28f857eee36d913f335912da72b28371
[ "MIT" ]
14
2021-08-19T09:12:23.000Z
2022-03-22T06:58:58.000Z
model/dualposenet.py
wx-b/DualPoseNet
393f786a28f857eee36d913f335912da72b28371
[ "MIT" ]
4
2021-09-16T05:48:53.000Z
2022-02-28T16:23:40.000Z
model/dualposenet.py
wx-b/DualPoseNet
393f786a28f857eee36d913f335912da72b28371
[ "MIT" ]
7
2021-10-11T05:38:39.000Z
2022-01-04T03:22:57.000Z
# Copyright (c) Gorilla Lab, SCUT. # # This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. """ Dual Pose Network with Refined Learning of Pose Consistency. Author: Jiehong Lin """ import os import tensorflow as tf import numpy as np ...
48.243631
175
0.529491
29,626
0.977853
0
0
0
0
0
0
2,336
0.077103
208e001e2d8d189eee888e06083e153b859d3d35
1,652
py
Python
tests/friend/test_net.py
cloudboss/friend
3357e6ec849552e3ae9ed28017ff0926e4006e4e
[ "MIT" ]
null
null
null
tests/friend/test_net.py
cloudboss/friend
3357e6ec849552e3ae9ed28017ff0926e4006e4e
[ "MIT" ]
null
null
null
tests/friend/test_net.py
cloudboss/friend
3357e6ec849552e3ae9ed28017ff0926e4006e4e
[ "MIT" ]
null
null
null
# Copyright 2018 Joseph Wright <joseph@cloudboss.co> # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, mer...
44.648649
79
0.735472
452
0.273608
0
0
0
0
0
0
1,137
0.688257
20903497b848af034e0eb1186f088232c687e594
341
py
Python
Day 10 Binary Numbers.py
rajnish-13547/Hackerrank-30-day-Code
ef3a754e39b9902ac9b6b0b728e11296f22cd054
[ "Apache-2.0" ]
null
null
null
Day 10 Binary Numbers.py
rajnish-13547/Hackerrank-30-day-Code
ef3a754e39b9902ac9b6b0b728e11296f22cd054
[ "Apache-2.0" ]
null
null
null
Day 10 Binary Numbers.py
rajnish-13547/Hackerrank-30-day-Code
ef3a754e39b9902ac9b6b0b728e11296f22cd054
[ "Apache-2.0" ]
null
null
null
#!/bin/python3 import math import os import random import re import sys if __name__ == '__main__': n = int(input().strip()) out = bin(n)[2:].split('0') #bin binarizes into form '0b----' where ---- is binary representataion out = len(max(out)) # choosing maximum length of string as '11' > ...
20.058824
103
0.607038
0
0
0
0
0
0
0
0
149
0.43695
20914f481667d4d16d02db12f46ade70ba6a337e
836
py
Python
vim/del_mq_transfer.py
quentin-wang/audioset_classification
b21887484a94babd4613b01368edeb86706bdd37
[ "MIT" ]
2
2020-04-05T21:24:39.000Z
2021-06-04T09:03:58.000Z
vim/del_mq_transfer.py
quentin-wang/audioset_classification
b21887484a94babd4613b01368edeb86706bdd37
[ "MIT" ]
13
2020-01-28T22:01:40.000Z
2021-12-13T19:51:09.000Z
vim/del_mq_transfer.py
quentin-wang/audioset_classification
b21887484a94babd4613b01368edeb86706bdd37
[ "MIT" ]
1
2021-07-06T21:12:15.000Z
2021-07-06T21:12:15.000Z
# -*- coding=utf-8 -*- import pika import sys import numpy as np import pickle credentials = pika.PlainCredentials('myuser', 'mypassword') with pika.BlockingConnection( pika.ConnectionParameters('ice-P910',5672,'myvhost', credentials)) as connection: # connection = pika.BlockingConnection(pika.Connection...
32.153846
87
0.735646
0
0
0
0
0
0
0
0
289
0.345694
20915d22a85cdbcd4b2ea977314aae79038fd886
225
py
Python
api/base/serializers.py
felliott/SHARE
8fd60ff4749349c9b867f6188650d71f4f0a1a56
[ "Apache-2.0" ]
87
2015-01-06T18:24:45.000Z
2021-08-08T07:59:40.000Z
api/base/serializers.py
fortress-biotech/SHARE
9c5a05dd831447949fa6253afec5225ff8ab5d4f
[ "Apache-2.0" ]
442
2015-01-01T19:16:01.000Z
2022-03-30T21:10:26.000Z
api/base/serializers.py
fortress-biotech/SHARE
9c5a05dd831447949fa6253afec5225ff8ab5d4f
[ "Apache-2.0" ]
67
2015-03-10T16:32:58.000Z
2021-11-12T16:33:41.000Z
from rest_framework_json_api import serializers __all__ = ('ShareSerializer', ) class ShareSerializer(serializers.ModelSerializer): pass # Use as base for all serializers in case we need customizations in the future
25
88
0.795556
140
0.622222
0
0
0
0
0
0
95
0.422222
20920539583830803e507b6abeed56abf3e464c5
114
py
Python
config.py
hyhplus/FlaskFirstDemo
4db0a374b32e58bba841e5a499535a8aa34e9237
[ "Apache-2.0" ]
null
null
null
config.py
hyhplus/FlaskFirstDemo
4db0a374b32e58bba841e5a499535a8aa34e9237
[ "Apache-2.0" ]
null
null
null
config.py
hyhplus/FlaskFirstDemo
4db0a374b32e58bba841e5a499535a8aa34e9237
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- DATABASE = 'db/user.db' DEBUG = True SECRET_KEY = 'secret_key_1'
14.25
27
0.640351
0
0
0
0
0
0
0
0
71
0.622807
20943719a2fcad2a95774d69c03867118816c653
599
py
Python
txt2sh.py
pib/gpio_ssd1306
7897e117529a57df2ea810ae2dad2756b3ea193f
[ "MIT" ]
2
2016-05-24T14:16:37.000Z
2018-09-25T06:35:55.000Z
txt2sh.py
pib/gpio_ssd1306
7897e117529a57df2ea810ae2dad2756b3ea193f
[ "MIT" ]
null
null
null
txt2sh.py
pib/gpio_ssd1306
7897e117529a57df2ea810ae2dad2756b3ea193f
[ "MIT" ]
null
null
null
import sys lines = [l.rstrip() for l in open(sys.argv[1]).readlines() if len(l.rstrip()) > 0] if len(lines) > 64: print "Max 64 lines" sys.exit(1) lines.extend([""] * (64 % len(lines))) # Pad out to 64 lines cols = max(len(l) for l in lines) if cols > 128: print "Max 128 columns" sys.exit(1) for i in ...
28.52381
82
0.562604
0
0
0
0
0
0
0
0
80
0.133556
20947dad3cda2fd32b55ac90d29dde10b443304e
2,704
py
Python
models.py
RidleyLeisy/data-science-1
bdb0ce1d5b01e2ee0b6b455c9382638cce0027e2
[ "MIT" ]
null
null
null
models.py
RidleyLeisy/data-science-1
bdb0ce1d5b01e2ee0b6b455c9382638cce0027e2
[ "MIT" ]
3
2021-02-08T20:34:21.000Z
2021-06-02T00:21:00.000Z
models.py
RidleyLeisy/data-science-1
bdb0ce1d5b01e2ee0b6b455c9382638cce0027e2
[ "MIT" ]
1
2019-08-28T21:51:14.000Z
2019-08-28T21:51:14.000Z
import pandas as pd import numpy as np from sklearn.pipeline import Pipeline import category_encoders as ce from scipy.spatial.distance import cdist from sklearn.externals import joblib from db_helper import DbHelper cols = ['column_a', 'player', 'all_nba', 'all_star', 'draft_yr','pk','team', 'college', 'yrs', 'gam...
37.041096
120
0.640902
1,375
0.508506
0
0
0
0
0
0
966
0.357249
20955b537db28fcb9f49cbce39f463fbee44592c
5,692
py
Python
third_party/dimorphite_dl/acid_base_pairs.py
uta-smile/CD-MVGNN
b48f4cd14befed298980a83edb417ab6809f0af6
[ "MIT" ]
3
2022-02-06T09:13:51.000Z
2022-02-19T15:03:35.000Z
third_party/dimorphite_dl/acid_base_pairs.py
uta-smile/CD-MVGNN
b48f4cd14befed298980a83edb417ab6809f0af6
[ "MIT" ]
1
2022-02-14T23:16:27.000Z
2022-02-14T23:16:27.000Z
third_party/dimorphite_dl/acid_base_pairs.py
uta-smile/CD-MVGNN
b48f4cd14befed298980a83edb417ab6809f0af6
[ "MIT" ]
null
null
null
from third_party.molvs.charge import AcidBasePair from rdkit import Chem pair_string = """Nitro [C,c,N,n,O,o:1]-[NX3:2](=[O:3])-[O-1:4] [C,c,N,n,O,o:1]-[NX3:2](=[O:3])-[O:4]-[H] 3 Sulfate [SX4:1](=[O:2])(=[O:3])([O:4]-[C,c,N,n:5])-[O-1:6] [SX4:1](=[O:2])(=[O:3])([O:4]-[C,c,N,n:5])-[OX2:6]-[H] 5 Sulfonate [SX4:1](=[O:2...
56.356436
230
0.500703
1,319
0.231729
0
0
0
0
0
0
3,992
0.701335
2096856b33bf00dedb67422295e6927b9ab0e166
854
py
Python
aggregate/color_videos.py
isaiahnields/attention.ai
96fe8d738e4fc36f05e6c72e2f1fcdd7a4048261
[ "MIT" ]
8
2019-02-12T07:07:42.000Z
2022-03-02T08:13:01.000Z
aggregate/color_videos.py
isaiahnields/attention.ai
96fe8d738e4fc36f05e6c72e2f1fcdd7a4048261
[ "MIT" ]
7
2020-01-28T22:06:03.000Z
2022-02-09T23:29:48.000Z
aggregate/color_videos.py
isaiahnields/attention.ai
96fe8d738e4fc36f05e6c72e2f1fcdd7a4048261
[ "MIT" ]
8
2019-02-12T07:07:46.000Z
2021-09-21T13:37:19.000Z
import cv2 from os import listdir from os.path import isfile, join import numpy as np from math import sin, pi paths = [f for f in listdir('combined_videos') if isfile(join('combined_videos', f))] preds = np.load('agg_preds.npy') preds = np.sqrt(preds) for i in range(len(paths)): ps = preds[i, :] cap = cv2.V...
26.6875
85
0.533958
0
0
0
0
0
0
0
0
88
0.103044
2096b0b7ee6813ddc0e5f25a4499c5eee7710cfc
701
py
Python
phillydata/reversion_utils.py
ebrelsford/django-phillydata
444a3ff9d436cd276530534642dd092402278ba5
[ "BSD-3-Clause" ]
null
null
null
phillydata/reversion_utils.py
ebrelsford/django-phillydata
444a3ff9d436cd276530534642dd092402278ba5
[ "BSD-3-Clause" ]
null
null
null
phillydata/reversion_utils.py
ebrelsford/django-phillydata
444a3ff9d436cd276530534642dd092402278ba5
[ "BSD-3-Clause" ]
1
2020-01-23T04:59:36.000Z
2020-01-23T04:59:36.000Z
from django.utils.importlib import import_module from reversion import default_revision_manager class InitialRevisionManagerMixin(object): def _save_initial_revision(self, obj): # try to load admin try: import_module("%s.admin" % obj.__module__.rsplit('.', 1)[0]) except Impor...
29.208333
74
0.619116
601
0.857347
0
0
0
0
0
0
65
0.092725
2096bbd23d6d1eb8cd8c79333789419dd5da64b5
120
py
Python
bind/__init__.py
PowerOlive/bind
dca84228b43b0bf93580d5ae9c4fd1a79bce42c5
[ "MIT" ]
2
2018-07-18T11:37:37.000Z
2019-05-03T11:37:13.000Z
bind/__init__.py
PowerOlive/bind
dca84228b43b0bf93580d5ae9c4fd1a79bce42c5
[ "MIT" ]
3
2018-10-22T15:19:32.000Z
2019-06-01T15:06:26.000Z
bind/__init__.py
PowerOlive/bind
dca84228b43b0bf93580d5ae9c4fd1a79bce42c5
[ "MIT" ]
4
2019-05-03T11:37:21.000Z
2020-08-07T08:10:24.000Z
from .bind import bind # noqa __version__ = '3.0.0' # DO NOT EDIT THIS LINE MANUALLY. LET bump2version UTILITY DO IT
30
87
0.725
0
0
0
0
0
0
0
0
77
0.641667
2099d8a4a1df272a200a2b4774039e76e7ba0d00
5,909
py
Python
src/beansapplicationmgr.py
primroses/docklet
6c42a472a8b427496c03fad18b873cb4be219db3
[ "BSD-3-Clause" ]
null
null
null
src/beansapplicationmgr.py
primroses/docklet
6c42a472a8b427496c03fad18b873cb4be219db3
[ "BSD-3-Clause" ]
null
null
null
src/beansapplicationmgr.py
primroses/docklet
6c42a472a8b427496c03fad18b873cb4be219db3
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/python3 ''' This module consists of three parts: 1.send_beans_email: a function to send email to remind users of their beans. 2.ApplicationMgr: a class that will deal with users' requests about beans application. 3.ApprovalRobot: a automatic robot to examine and approve users' applications. ''' import t...
39.657718
137
0.616517
3,543
0.599594
0
0
1,073
0.181587
0
0
2,240
0.379083
209a7c9fd12e2cce719dba7f8f99eed34a7d71a3
863
py
Python
Chapter03/Cisco/cisco_nxapi_4.py
stavsta/Mastering-Python-Networking-Second-Edition
9999d2e415a1eb9c653ac3507500da7ddac2b556
[ "MIT" ]
107
2017-03-31T09:39:47.000Z
2022-01-10T17:43:12.000Z
Chapter03/Cisco/cisco_nxapi_4.py
muzhang90/Mastering-Python-Networking-Third-Edition
f8086fc9a28e441cf8c31099d16839c2e868c7fc
[ "MIT" ]
3
2020-03-29T14:14:43.000Z
2020-10-29T18:21:09.000Z
Chapter03/Cisco/cisco_nxapi_4.py
muzhang90/Mastering-Python-Networking-Third-Edition
f8086fc9a28e441cf8c31099d16839c2e868c7fc
[ "MIT" ]
98
2017-02-25T17:55:43.000Z
2022-02-20T19:06:06.000Z
#!/usr/bin/env python3 import requests import json url='http://172.16.1.90/ins' switchuser='cisco' switchpassword='cisco' myheaders={'content-type':'application/json-rpc'} payload=[ { "jsonrpc": "2.0", "method": "cli", "params": { "cmd": "interface ethernet 2/12", "version": 1.2 }, ...
15.981481
113
0.505214
0
0
0
0
0
0
0
0
375
0.434531
209acd05a3b02a15fcea937bc6fde4ebaf25e231
7,684
py
Python
poli/python/poli/modal.py
Humhu/percepto
4a45cce7dd294a8ce0b962bb68cae5c2b48c3b7f
[ "AFL-3.0" ]
1
2021-06-15T09:34:24.000Z
2021-06-15T09:34:24.000Z
poli/python/poli/modal.py
Humhu/percepto
4a45cce7dd294a8ce0b962bb68cae5c2b48c3b7f
[ "AFL-3.0" ]
null
null
null
poli/python/poli/modal.py
Humhu/percepto
4a45cce7dd294a8ce0b962bb68cae5c2b48c3b7f
[ "AFL-3.0" ]
null
null
null
"""This policy contains classes for modal policies. """ import numpy as np from sklearn.cluster import KMeans #from sklearn.svm import SVC, SVR #from sklearn.naive_bayes import GaussianNB from sklearn.neighbors import KNeighborsClassifier from sklearn.neighbors.kde import KernelDensity from poli import importance_sa...
34.769231
95
0.593441
7,225
0.940265
0
0
0
0
0
0
1,590
0.206923
209ba14e1d9e24a86fee89293a465d6242084374
1,510
py
Python
website/__init__.py
oforiwaasam/bookshub
5c83422971f4abdc5fe18d9b088ed3ca5a230636
[ "MIT" ]
null
null
null
website/__init__.py
oforiwaasam/bookshub
5c83422971f4abdc5fe18d9b088ed3ca5a230636
[ "MIT" ]
null
null
null
website/__init__.py
oforiwaasam/bookshub
5c83422971f4abdc5fe18d9b088ed3ca5a230636
[ "MIT" ]
null
null
null
from os import path, environ from flask import Flask from flask_sqlalchemy import SQLAlchemy from flask_login import LoginManager # Define a new database below db = SQLAlchemy() DB_NAME = "site.db" login_manager = LoginManager() def create_app(): # database configuration app = Flask(__name__) app.config['...
34.318182
154
0.72649
0
0
0
0
0
0
0
0
778
0.515232
209bcc7136e45237b3ef4f72a6a5d6341d1f6455
31
py
Python
ofdft_ml/statslib/data_loader/__init__.py
HamletWantToCode/ofdft-ml
4115405b6f530cdf8956d0b5b353569ce7c09496
[ "MIT" ]
6
2019-01-16T07:00:27.000Z
2022-03-18T07:09:25.000Z
ofdft_ml/statslib/data_loader/__init__.py
HamletWantToCode/ofdft-ml
4115405b6f530cdf8956d0b5b353569ce7c09496
[ "MIT" ]
null
null
null
ofdft_ml/statslib/data_loader/__init__.py
HamletWantToCode/ofdft-ml
4115405b6f530cdf8956d0b5b353569ce7c09496
[ "MIT" ]
null
null
null
from .dataloader import Dataset
31
31
0.870968
0
0
0
0
0
0
0
0
0
0
209bd889393f7e101ff66a22355ff5e0d930a797
1,230
py
Python
python/ql/test/experimental/query-tests/Security/CWE-079/smtplib_bad_subparts.py
RasmusWL/ql
298f4ab899dcb12414d4fd5112956b82effd140f
[ "MIT" ]
null
null
null
python/ql/test/experimental/query-tests/Security/CWE-079/smtplib_bad_subparts.py
RasmusWL/ql
298f4ab899dcb12414d4fd5112956b82effd140f
[ "MIT" ]
4
2022-02-17T06:25:43.000Z
2022-02-23T15:55:30.000Z
python/ql/test/experimental/query-tests/Security/CWE-079/smtplib_bad_subparts.py
jketema/codeql
09578015886a0c59c2d21c9d09d565742803a5a4
[ "MIT" ]
null
null
null
# This test checks that the developer doesn't pass a MIMEText instance to a MIMEMultipart initializer via the subparts parameter. from flask import Flask, request import json import smtplib import ssl from email.mime.text import MIMEText from email.mime.multipart import MIMEMultipart app = Flask(__name__) @app.route...
28.604651
129
0.710569
0
0
0
0
862
0.700813
0
0
496
0.403252
209d3f8143bb0c9a52bff1f3e1c1e5bf2dd136e1
1,072
py
Python
tests/testOptArg.py
miniufo/xinvert
5fec8586730ec16646304d3eedae1cd501f0673b
[ "MIT" ]
4
2021-05-29T14:56:24.000Z
2022-03-30T11:54:32.000Z
tests/testOptArg.py
miniufo/xinvert
5fec8586730ec16646304d3eedae1cd501f0673b
[ "MIT" ]
null
null
null
tests/testOptArg.py
miniufo/xinvert
5fec8586730ec16646304d3eedae1cd501f0673b
[ "MIT" ]
2
2021-11-22T10:27:21.000Z
2022-03-30T11:54:33.000Z
# -*- coding: utf-8 -*- """ Created on 2020.12.19 @author: MiniUFO Copyright 2018. All rights reserved. Use is subject to license terms. """ #%% load data import xarray as xr import numpy as np nx, ny = 100, 100 gridx = xr.DataArray(np.arange(nx), dims=['X'], coords={'X': np.arange(nx)}) gridy = xr.DataArray(np.aran...
22.808511
80
0.649254
0
0
0
0
0
0
0
0
242
0.225746
209db664ddb0050867ee984f6e1fa194d70e545b
867
py
Python
main/migrations/0007_auto_20210116_0038.py
Arts-Technology-Lab/exp_taste
291d26894c534a82379252d1af1b9b0b321fc71b
[ "MIT" ]
null
null
null
main/migrations/0007_auto_20210116_0038.py
Arts-Technology-Lab/exp_taste
291d26894c534a82379252d1af1b9b0b321fc71b
[ "MIT" ]
null
null
null
main/migrations/0007_auto_20210116_0038.py
Arts-Technology-Lab/exp_taste
291d26894c534a82379252d1af1b9b0b321fc71b
[ "MIT" ]
1
2021-09-01T03:16:10.000Z
2021-09-01T03:16:10.000Z
# Generated by Django 3.0.10 on 2021-01-16 00:38 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('main', '0006_auto_20201001_0931'), ] operations = [ migrations.AlterModelOptions( name='auctionlot', options={'orde...
30.964286
134
0.60323
773
0.89158
0
0
0
0
0
0
255
0.294118
209dd913bd69c44b411f4ac37d2ead791d37fb9b
1,451
py
Python
scripts/plot_solutions.py
sovrasov/linear_sde_solver
50a7248d9472889523e59c26b1c6448b8ce220da
[ "MIT" ]
null
null
null
scripts/plot_solutions.py
sovrasov/linear_sde_solver
50a7248d9472889523e59c26b1c6448b8ce220da
[ "MIT" ]
null
null
null
scripts/plot_solutions.py
sovrasov/linear_sde_solver
50a7248d9472889523e59c26b1c6448b8ce220da
[ "MIT" ]
null
null
null
import argparse import os import sys import json import pylab as pl import numpy as np def main(args): for solution_file in args.solution_files: with open(solution_file, 'r') as f: print(solution_file) data = json.load(f) t0 = data['t_0'] n_steps = data['n_s...
29.02
98
0.535493
0
0
0
0
0
0
0
0
177
0.121985
209ef0d114b6e2246d0313cca7bc6428bd8f1b6f
2,275
py
Python
lottery/db/MySqlUtil.py
DEAN-Lee/py_tools
96968a5c5be3fa5e293671588ad7ec75cb0910f8
[ "MIT" ]
null
null
null
lottery/db/MySqlUtil.py
DEAN-Lee/py_tools
96968a5c5be3fa5e293671588ad7ec75cb0910f8
[ "MIT" ]
1
2021-01-08T08:40:54.000Z
2021-01-08T08:40:54.000Z
lottery/db/MySqlUtil.py
DEAN-Lee/py_tools
96968a5c5be3fa5e293671588ad7ec75cb0910f8
[ "MIT" ]
null
null
null
import pymysql import time from lottery.conf import common_data class MySqlUtil: def __init__(self): try: config = common_data.readDBConf() self._conn = pymysql.connect(host=config[0], user=config[1], ...
30.743243
85
0.491429
2,327
0.971608
0
0
0
0
0
0
425
0.177453
20a178a7f03998c835263b3fd062485db5864e1a
398
py
Python
operacion/migrations/0005_remove_turno_hora_inicio.py
exildev/Rondax
a4a4cad4ec9c575a288f66a353e07e9a57362ede
[ "Apache-2.0" ]
null
null
null
operacion/migrations/0005_remove_turno_hora_inicio.py
exildev/Rondax
a4a4cad4ec9c575a288f66a353e07e9a57362ede
[ "Apache-2.0" ]
null
null
null
operacion/migrations/0005_remove_turno_hora_inicio.py
exildev/Rondax
a4a4cad4ec9c575a288f66a353e07e9a57362ede
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by Django 1.10.1 on 2016-09-08 15:20 from __future__ import unicode_literals from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('operacion', '0004_turno_hora_inicio'), ] operations = [ migrations.RemoveField( ...
19.9
48
0.61809
248
0.623116
0
0
0
0
0
0
126
0.316583
20a2e7e453f2ab360ec62bed41bb72c2802359a4
1,381
py
Python
utils/py_utils.py
KAIST-AILab/PyOpenDial
c9bca653c18ccc082dc8b86b4a8feee9ed00a75b
[ "MIT" ]
9
2019-09-23T01:56:43.000Z
2022-03-13T17:58:40.000Z
utils/py_utils.py
KAIST-AILab/PyOpenDial
c9bca653c18ccc082dc8b86b4a8feee9ed00a75b
[ "MIT" ]
2
2019-11-18T17:02:30.000Z
2021-07-14T15:47:08.000Z
utils/py_utils.py
KAIST-AILab/PyOpenDial
c9bca653c18ccc082dc8b86b4a8feee9ed00a75b
[ "MIT" ]
1
2022-02-08T06:41:19.000Z
2022-02-08T06:41:19.000Z
import time import threading def current_time_millis(): return int(round(time.time() * 1000)) def get_class(kls): parts = kls.split('.') module = ".".join(parts[:-1]) m = __import__(module) for comp in parts[1:]: m = getattr(m, comp) return m def get_class_name(instance): retur...
24.22807
116
0.616944
226
0.16365
0
0
0
0
0
0
53
0.038378
20a392002d1e2c2127d30a148baaa0e429a4ea95
2,493
py
Python
interestCalculatorNew.py
Heliodex/PythonCalculators
ab360d79b9e0a503fbb34adfdfa2e2e557097aad
[ "Unlicense" ]
null
null
null
interestCalculatorNew.py
Heliodex/PythonCalculators
ab360d79b9e0a503fbb34adfdfa2e2e557097aad
[ "Unlicense" ]
null
null
null
interestCalculatorNew.py
Heliodex/PythonCalculators
ab360d79b9e0a503fbb34adfdfa2e2e557097aad
[ "Unlicense" ]
null
null
null
# Heliodex 2021/08/24 # Last edited 2022/02/16 -- count number of steps and add reverse mode # edit of vatRemover # uses Short Method print("Calculates amount after adding a percentage a number of times") while True: c = input("1 for normal, 2 for reverse, 3 for catchup ") if c == "1": val =...
28.011236
71
0.441637
0
0
0
0
0
0
0
0
722
0.289611
20a3b0acfd3632b1e52670412907b6db19696003
2,623
py
Python
src/pylexibank/commands/init_profile.py
martino-vic/pylexibank
eefbfbb1754e85264a9fe98fefbcf5df254ad19a
[ "Apache-2.0" ]
6
2019-11-04T09:15:34.000Z
2022-02-19T23:02:51.000Z
src/pylexibank/commands/init_profile.py
martino-vic/pylexibank
eefbfbb1754e85264a9fe98fefbcf5df254ad19a
[ "Apache-2.0" ]
228
2018-04-13T09:39:20.000Z
2022-03-08T23:30:46.000Z
src/pylexibank/commands/init_profile.py
martino-vic/pylexibank
eefbfbb1754e85264a9fe98fefbcf5df254ad19a
[ "Apache-2.0" ]
5
2019-07-10T04:53:15.000Z
2022-03-07T01:43:23.000Z
""" Create an initial orthography profile, seeded from the forms created by a first run of lexibank.makecldf. """ from lingpy import Wordlist from lingpy.sequence import profile from cldfbench.cli_util import get_dataset, add_catalog_spec from csvw.dsv import UnicodeWriter from clldutils.clilib import ParserError from...
33.628205
97
0.629813
0
0
0
0
0
0
0
0
865
0.328897
20a60c00e978fa11291e28ff7b092caf77628614
9,537
py
Python
Source/ThirdParty/angle/testing/legion/lib/rpc/jsonrpclib.py
elix22/Urho3D
99902ae2a867be0d6dbe4c575f9c8c318805ec64
[ "MIT" ]
20
2019-04-18T07:37:34.000Z
2022-02-02T21:43:47.000Z
testing/legion/lib/rpc/jsonrpclib.py
lyapple2008/webrtc_simplify
c4f9bdc72d8e2648c4f4b1934d22ae94a793b553
[ "BSD-3-Clause" ]
11
2019-10-21T13:39:41.000Z
2021-11-05T08:11:54.000Z
testing/legion/lib/rpc/jsonrpclib.py
lyapple2008/webrtc_simplify
c4f9bdc72d8e2648c4f4b1934d22ae94a793b553
[ "BSD-3-Clause" ]
1
2021-12-03T18:11:36.000Z
2021-12-03T18:11:36.000Z
# Copyright 2014 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Module to implement the JSON-RPC protocol. This module uses xmlrpclib as the base and only overrides those portions that implement the XML-RPC protocol. ...
25.5
79
0.676838
4,309
0.451819
0
0
0
0
0
0
4,454
0.467023
20a8a073cd2c94b8099ac2c571da041af73d129b
21,838
py
Python
src/third_party/ffmpeg/chromium/scripts/build_ffmpeg.py
neeker/chromium_extract
0f9a0206a1876e98cf69e03869983e573138284c
[ "BSD-3-Clause" ]
27
2016-04-27T01:02:03.000Z
2021-12-13T08:53:19.000Z
src/third_party/ffmpeg/chromium/scripts/build_ffmpeg.py
neeker/chromium_extract
0f9a0206a1876e98cf69e03869983e573138284c
[ "BSD-3-Clause" ]
2
2017-03-09T09:00:50.000Z
2017-09-21T15:48:20.000Z
src/third_party/ffmpeg/chromium/scripts/build_ffmpeg.py
neeker/chromium_extract
0f9a0206a1876e98cf69e03869983e573138284c
[ "BSD-3-Clause" ]
17
2016-04-27T02:06:39.000Z
2019-12-18T08:07:00.000Z
#!/usr/bin/env python # # Copyright 2014 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. from __future__ import print_function import collections import multiprocessing import optparse import os import platform import re ...
34.773885
81
0.61512
0
0
0
0
0
0
0
0
10,937
0.500824
20ab340c51fea34db17694c288889d5ae11f982b
340
py
Python
res_cookie.py
HLRJ/py-crawler
326128f8aa8e83cb7a142a31efedc7d944dac4da
[ "MIT" ]
1
2022-03-29T16:01:41.000Z
2022-03-29T16:01:41.000Z
res_cookie.py
HLRJ/py-crawler
326128f8aa8e83cb7a142a31efedc7d944dac4da
[ "MIT" ]
null
null
null
res_cookie.py
HLRJ/py-crawler
326128f8aa8e83cb7a142a31efedc7d944dac4da
[ "MIT" ]
1
2022-03-29T16:02:10.000Z
2022-03-29T16:02:10.000Z
import requests # 处理cookie的一个模板 # 会话 session = requests.session() data = { "账号" : "########", "密码" : "########" } url = "" res = session.post(url, data=data) print(res.text) res = session.get(url) # resquests header = { "user-agent" : "dddd", "Cookie" : "url" } resp = requests.get(url,headers=heade...
14.166667
39
0.576471
0
0
0
0
0
0
0
0
118
0.322404
20af13f324e132c3a20d60cbd72a4f1adb5b9083
13,891
py
Python
Auto Scroller - Python/venv/lib/python3.8/site-packages/listener/daemon.py
Nischal200/Music-Lyrics-Auto-Scroller
92663e13451022a1500bfe56dff479dd0b3f1cac
[ "MIT" ]
null
null
null
Auto Scroller - Python/venv/lib/python3.8/site-packages/listener/daemon.py
Nischal200/Music-Lyrics-Auto-Scroller
92663e13451022a1500bfe56dff479dd0b3f1cac
[ "MIT" ]
null
null
null
Auto Scroller - Python/venv/lib/python3.8/site-packages/listener/daemon.py
Nischal200/Music-Lyrics-Auto-Scroller
92663e13451022a1500bfe56dff479dd0b3f1cac
[ "MIT" ]
null
null
null
#! /usr/bin/env python3 """process which runs inside the docker daemon the purpose of the doctor damon process is to allow the set up of an environment which will support the deep speech recognition engine to run on any recent nvidia Ubuntu host. the basic operation of the demon is to create a named pipe in the users...
35.346056
146
0.608452
2,208
0.158952
4,506
0.324383
0
0
0
0
5,247
0.377727
20b0cb026df5e39e3d7cf7213155978963ec27ea
314
py
Python
python/day05.py
narimiran/AdventOfCode2019
7ca324ab6f292a93e3ab2327e9377eae2e462004
[ "MIT" ]
2
2019-12-05T08:39:34.000Z
2019-12-26T15:45:10.000Z
python/day05.py
narimiran/AdventOfCode2019
7ca324ab6f292a93e3ab2327e9377eae2e462004
[ "MIT" ]
null
null
null
python/day05.py
narimiran/AdventOfCode2019
7ca324ab6f292a93e3ab2327e9377eae2e462004
[ "MIT" ]
null
null
null
from intcode import * def solve(instr, part): input_instruction = 1 if part == 1 else 5 comp = Computer(instr, len(instr)) comp.receive(input_instruction) comp.run() return comp.out_queue[-1] instructions = read_intcode_input(5) print(solve(instructions, 1)) print(solve(instructions, 2))
19.625
45
0.703822
0
0
0
0
0
0
0
0
0
0
20b1b21ec139b97e272ccfb76245282c96f81627
3,736
py
Python
client.py
NordCox/Nordcox-Bot
3ed83bfdc10523cdcbfd13a0f45d3d68f3df056c
[ "MIT" ]
7
2017-04-26T20:49:46.000Z
2017-06-02T01:08:00.000Z
client.py
NordCox/Nordcox-Bot
3ed83bfdc10523cdcbfd13a0f45d3d68f3df056c
[ "MIT" ]
9
2017-04-26T16:22:59.000Z
2018-07-16T18:21:50.000Z
client.py
NordCox/Nordcox-Bot
3ed83bfdc10523cdcbfd13a0f45d3d68f3df056c
[ "MIT" ]
11
2017-06-02T03:46:29.000Z
2019-02-27T21:20:06.000Z
import logging import threading import time import pinylib log = logging.getLogger(__name__) def main(): room_name = raw_input('Enter room name: ').strip() if pinylib.CONFIG.ACCOUNT and pinylib.CONFIG.PASSWORD: client = pinylib.TinychatRTCClient(room=room_name, account=pinylib.CONFIG.ACCOUNT, ...
38.122449
118
0.523287
0
0
0
0
0
0
0
0
472
0.126338
20b1e4ce9fc466a2b7e51f104d05fa8d81c11041
23,645
py
Python
nifpga/session.py
auchter/nifpga-python
d24ac338ec9b9d1bb94f1c8b8d06643670289e9e
[ "MIT" ]
null
null
null
nifpga/session.py
auchter/nifpga-python
d24ac338ec9b9d1bb94f1c8b8d06643670289e9e
[ "MIT" ]
null
null
null
nifpga/session.py
auchter/nifpga-python
d24ac338ec9b9d1bb94f1c8b8d06643670289e9e
[ "MIT" ]
1
2020-09-19T15:44:08.000Z
2020-09-19T15:44:08.000Z
""" Session, a convenient wrapper around the low-level _NiFpga class. Copyright (c) 2017 National Instruments """ from .nifpga import (_SessionType, _IrqContextType, _NiFpga, DataType, OPEN_ATTRIBUTE_NO_RUN, RUN_ATTRIBUTE_WAIT_UNTIL_DONE, CLOSE_ATTRIBUTE_NO_RESET_IF_LAST_SESS...
39.806397
102
0.587735
23,110
0.977374
0
0
1,231
0.052062
0
0
10,620
0.449144
20b1f01b27ef48f6d139f9138e4bcf3552657d52
1,822
py
Python
old/mael_dmg_calc.py
IronHeart7334/Maelstrom
aaea823c393a1cdc908b987ec5a27904322845ce
[ "MIT" ]
null
null
null
old/mael_dmg_calc.py
IronHeart7334/Maelstrom
aaea823c393a1cdc908b987ec5a27904322845ce
[ "MIT" ]
null
null
null
old/mael_dmg_calc.py
IronHeart7334/Maelstrom
aaea823c393a1cdc908b987ec5a27904322845ce
[ "MIT" ]
null
null
null
TOTAL = 1000 def calc_stats(defRat, eleRat, resRat, p = True): DEF = TOTAL * (0.75 + 0.025 * defRat) OFF = TOTAL - DEF ENE = OFF * (0.5 + 0.05 * eleRat) STR = OFF - ENE RES = DEF * (0.167 + 0.033 * resRat) HP = DEF - RES if p: print "" print "" print "HP: " + str(HP) print "STR: " + str(STR) pri...
18.039604
68
0.588913
0
0
0
0
0
0
0
0
457
0.250823
20b28d884d7b7314d9f1c0fd125fd2bca1b74c56
2,439
py
Python
in-app-payments-with-server-validation/backend-appengine/jwt/__init__.py
Acidburn0zzz/chrome-app-samples
53c3184d3ff210918a5d9c7420dd2a92c0870cf5
[ "Apache-2.0" ]
16
2019-08-08T02:04:54.000Z
2019-10-15T17:52:36.000Z
in-app-payments-with-server-validation/backend-appengine/jwt/__init__.py
Acidburn0zzz/chrome-app-samples
53c3184d3ff210918a5d9c7420dd2a92c0870cf5
[ "Apache-2.0" ]
null
null
null
in-app-payments-with-server-validation/backend-appengine/jwt/__init__.py
Acidburn0zzz/chrome-app-samples
53c3184d3ff210918a5d9c7420dd2a92c0870cf5
[ "Apache-2.0" ]
8
2015-07-04T07:24:08.000Z
2020-04-27T02:23:49.000Z
""" JSON Web Token implementation Minimum implementation based on this spec: http://self-issued.info/docs/draft-jones-json-web-token-01.html """ import base64 import hashlib import hmac try: import json except ImportError: import simplejson as json __all__ = ['encode', 'decode', 'DecodeError'] class Dec...
33.410959
89
0.678147
34
0.01394
0
0
0
0
0
0
412
0.168922
20b37fe078b398c2a89ecdde10b0aa1f69e2a0fc
4,931
py
Python
app/models/attribute.py
hack4impact/women-veterans-rock
7de5f5645819dbe67ba71a1f0b29f84a45e35789
[ "MIT" ]
16
2015-10-26T20:30:35.000Z
2017-02-01T01:45:35.000Z
app/models/attribute.py
hack4impact/women-veterans-rock
7de5f5645819dbe67ba71a1f0b29f84a45e35789
[ "MIT" ]
34
2015-10-21T02:58:42.000Z
2017-02-24T06:57:07.000Z
app/models/attribute.py
hack4impact/women-veterans-rock
7de5f5645819dbe67ba71a1f0b29f84a45e35789
[ "MIT" ]
1
2015-10-23T21:32:28.000Z
2015-10-23T21:32:28.000Z
from .. import db user_tag_associations_table = db.Table( 'user_tag_associations', db.Model.metadata, db.Column('tag_id', db.Integer, db.ForeignKey('tags.id')), db.Column('user_id', db.Integer, db.ForeignKey('users.id')) ) resource_tag_associations_table = db.Table( 'resource_tag_associations', db.Mod...
33.773973
78
0.608801
4,452
0.902859
0
0
2,993
0.606976
0
0
1,513
0.306834
20b557e25c85bd79516024b5db25efc8be4b20b6
2,631
py
Python
python/wlu_lr/CNN.py
GG-yuki/bugs
aabd576e9e57012a3390007af890b7c6ab6cdda8
[ "MIT" ]
null
null
null
python/wlu_lr/CNN.py
GG-yuki/bugs
aabd576e9e57012a3390007af890b7c6ab6cdda8
[ "MIT" ]
null
null
null
python/wlu_lr/CNN.py
GG-yuki/bugs
aabd576e9e57012a3390007af890b7c6ab6cdda8
[ "MIT" ]
null
null
null
import torch import torch.nn.functional as F import matplotlib.pyplot as plt import numpy x = torch.unsqueeze(torch.linspace(-1, 1, 300), dim=1) # x data (tensor), shape=(100, 1) print(x) y = x.pow(2) + 0.2 * torch.rand(x.size()) # noisy y data (tensor), shape=(100, 1) plt.scatter(x.data.numpy(), y.data.numpy()) plt...
32.085366
113
0.625618
660
0.222747
0
0
0
0
0
0
1,208
0.407695
20b5b58aed3d21c4c4915daa30f4e8dbda82f3a5
650
py
Python
4_PersistanceBugger.py
joanzhu728/Codewar
13d383957594c926ac5338a20d760f614271beab
[ "MIT" ]
null
null
null
4_PersistanceBugger.py
joanzhu728/Codewar
13d383957594c926ac5338a20d760f614271beab
[ "MIT" ]
null
null
null
4_PersistanceBugger.py
joanzhu728/Codewar
13d383957594c926ac5338a20d760f614271beab
[ "MIT" ]
null
null
null
import codewars_test as test def persistence(n): times = 0 if len(str(n)) == 1: return times else: while len(str(n)) > 1: multiple = 1 for x in str(n): multiple *= int(x) times += 1 n = multiple return times # import o...
23.214286
59
0.556923
0
0
0
0
0
0
0
0
167
0.256923
20b5d321129450b24c961028f4c4a899c4e5b34f
7,440
py
Python
mechanic/modifier.py
dl-stuff/dl9
1cbe98afc53a1de9d413797fb130946acc4b6ba4
[ "MIT" ]
null
null
null
mechanic/modifier.py
dl-stuff/dl9
1cbe98afc53a1de9d413797fb130946acc4b6ba4
[ "MIT" ]
null
null
null
mechanic/modifier.py
dl-stuff/dl9
1cbe98afc53a1de9d413797fb130946acc4b6ba4
[ "MIT" ]
null
null
null
""" kinds of modifiers 1. Ability Passive - stat mods - act damage up/down - punisher 2. Action condtion (and Aura) - there's a lot of crap here but they r all additive if same field - str aura is same as _RateAttack - certain fields (crit, crit dmg, punisher) are same bracket for w/e reason 3. hitattr - independent...
32.920354
135
0.562366
2,052
0.275806
0
0
0
0
0
0
3,886
0.522312
20b7cdbf4698fba9cb58486cf5f4749c946cfd11
4,154
py
Python
ino/argparsing.py
qguv/ino
f23ee5cb14edc30ec087d3eab7b301736da42362
[ "MIT" ]
558
2015-01-02T08:12:53.000Z
2022-03-08T17:13:26.000Z
ino/argparsing.py
jboone/ino
4798827272f6b3916f1fb887e42538a976789d90
[ "MIT" ]
84
2015-01-01T11:17:27.000Z
2021-02-11T02:40:23.000Z
ino/argparsing.py
jboone/ino
4798827272f6b3916f1fb887e42538a976789d90
[ "MIT" ]
176
2015-01-14T08:59:39.000Z
2021-06-24T07:41:31.000Z
# -*- coding: utf-8; -*- # Stolen from: http://bugs.python.org/issue12806 import argparse import re import textwrap class FlexiFormatter(argparse.RawTextHelpFormatter): """FlexiFormatter which respects new line formatting and wraps the rest Example: >>> parser = argparse.ArgumentParser(formatter_...
41.54
78
0.553683
3,303
0.795137
0
0
0
0
0
0
3,071
0.739287
20b85e774f4f333362b32f59f4d25bf560a3cebc
6,997
py
Python
NN_buildingblock/ConvNN.py
xupingxie/deep-learning-models
cc76aedf9631317452f9cd7df38998e2de727816
[ "MIT" ]
null
null
null
NN_buildingblock/ConvNN.py
xupingxie/deep-learning-models
cc76aedf9631317452f9cd7df38998e2de727816
[ "MIT" ]
null
null
null
NN_buildingblock/ConvNN.py
xupingxie/deep-learning-models
cc76aedf9631317452f9cd7df38998e2de727816
[ "MIT" ]
null
null
null
#!/usr/bin/env python2 # -*- coding: utf-8 -*- """ This script contains basic functions for Conv Neural Nets. foward conv and pooling backward conv and pooling @author: xuping """ import numpy as np import h5py import matplotlib.pyplot as plt def Conv_forward(A_prev, W, b, para): ''' This is the forward prop...
33.319048
103
0.489924
0
0
0
0
0
0
0
0
2,261
0.323138
20b8bb3fcf2671b92bff3531ad074b19f746b4aa
6,682
py
Python
00_core.py
DanyWind/fast_neptune
e07c354514df1debdff607584bb042f000f03f31
[ "Apache-2.0" ]
5
2020-01-28T22:28:36.000Z
2020-02-22T07:04:52.000Z
00_core.py
DanyWind/fast_neptune
e07c354514df1debdff607584bb042f000f03f31
[ "Apache-2.0" ]
2
2021-09-28T00:42:24.000Z
2022-02-26T06:26:10.000Z
00_core.py
dhuynh95/fast_neptune
e07c354514df1debdff607584bb042f000f03f31
[ "Apache-2.0" ]
2
2020-04-28T05:00:38.000Z
2020-12-04T09:08:03.000Z
#!/usr/bin/env python # coding: utf-8 # In[1]: #hide get_ipython().run_line_magic('load_ext', 'autoreload') get_ipython().run_line_magic('autoreload', '2') # In[2]: # default_exp core # In[3]: #export from nbdev.export import check_re,read_nb from pathlib import Path import re import os import platform # #...
20.623457
99
0.652649
0
0
1,206
0.180485
1,222
0.182879
0
0
2,888
0.432206
20b99c84a1d02922ac3d349c7b10e48dcaede0db
4,974
py
Python
nnf/dsharp.py
vishalbelsare/python-nnf
c2e81fd7851a3d11fff904bf5b4c5e521fde59ab
[ "0BSD" ]
14
2020-07-14T01:51:26.000Z
2021-12-17T22:45:47.000Z
nnf/dsharp.py
vishalbelsare/python-nnf
c2e81fd7851a3d11fff904bf5b4c5e521fde59ab
[ "0BSD" ]
26
2020-07-14T23:37:52.000Z
2021-11-04T18:06:38.000Z
nnf/dsharp.py
vishalbelsare/python-nnf
c2e81fd7851a3d11fff904bf5b4c5e521fde59ab
[ "0BSD" ]
7
2020-07-26T10:53:21.000Z
2021-09-19T00:35:30.000Z
"""Interoperability with `DSHARP <https://github.com/QuMuLab/dsharp>`_. ``load`` and ``loads`` can be used to parse files created by DSHARP's ``-Fnnf`` option. ``compile`` invokes DSHARP directly to compile a sentence. This requires having DSHARP installed. The parser was derived by studying DSHARP's output and sour...
32.090323
79
0.621431
0
0
0
0
0
0
0
0
1,925
0.387012
20ba293476d59761a6ef6fe44c77fac5699f68be
4,513
py
Python
stats/offense.py
wisarut-sirimart/Python-Baseball
f794455d4a217d7684bd86fdff19d1706bf7aab2
[ "MIT" ]
null
null
null
stats/offense.py
wisarut-sirimart/Python-Baseball
f794455d4a217d7684bd86fdff19d1706bf7aab2
[ "MIT" ]
null
null
null
stats/offense.py
wisarut-sirimart/Python-Baseball
f794455d4a217d7684bd86fdff19d1706bf7aab2
[ "MIT" ]
null
null
null
import pandas as pd import matplotlib.pyplot as plt from data import games # Select All Plays # In the file called offense.py in the stats folder you will find similar imports as the last module. # Import the games DataFrame from data. # Now that we have access to the games DataFrame. # Select all rows that have a type...
65.405797
239
0.731886
0
0
0
0
0
0
0
0
3,889
0.861733
20bada261f2bc5bee2c060bfdfd13f8adc62d780
2,156
py
Python
tests/gmprocess/io/read_test.py
baagaard-usgs/groundmotion-processing
6be2b4460d598bba0935135efa85af2655578565
[ "Unlicense" ]
54
2019-01-12T02:05:38.000Z
2022-03-29T19:43:56.000Z
tests/gmprocess/io/read_test.py
baagaard-usgs/groundmotion-processing
6be2b4460d598bba0935135efa85af2655578565
[ "Unlicense" ]
700
2018-12-18T19:44:31.000Z
2022-03-30T20:54:28.000Z
tests/gmprocess/io/read_test.py
baagaard-usgs/groundmotion-processing
6be2b4460d598bba0935135efa85af2655578565
[ "Unlicense" ]
41
2018-11-29T23:17:56.000Z
2022-03-31T04:04:23.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- # stdlib imports import os from gmprocess.io.read import read_data, _get_format, _validate_format from gmprocess.utils.test_utils import read_data_dir from gmprocess.utils.config import get_config def test_read(): config = get_config() cosmos_files, _ = read_dat...
35.344262
88
0.670223
0
0
0
0
0
0
0
0
484
0.22449
20be3885a4f5f899c0e126b28f81e284e4b6e23c
633
py
Python
tests/syft/lib/torch/device_test.py
JMLourier/PySyft
065a862ca061f9a526af81db5b3ee0d39d4f6407
[ "MIT" ]
2
2020-03-06T15:51:52.000Z
2020-03-08T13:14:24.000Z
tests/syft/lib/torch/device_test.py
JMLourier/PySyft
065a862ca061f9a526af81db5b3ee0d39d4f6407
[ "MIT" ]
5
2020-12-03T21:06:20.000Z
2020-12-31T03:46:57.000Z
tests/syft/lib/torch/device_test.py
JMLourier/PySyft
065a862ca061f9a526af81db5b3ee0d39d4f6407
[ "MIT" ]
1
2020-12-05T07:22:27.000Z
2020-12-05T07:22:27.000Z
# third party import torch as th # syft absolute import syft as sy from syft.core.common.uid import UID from syft.lib.python import String def test_device() -> None: device = th.device("cuda") assert device.type == "cuda" assert device.index is None def test_device_init() -> None: bob = sy.VirtualM...
23.444444
59
0.709321
0
0
0
0
0
0
0
0
68
0.107425
20bf152d1098acb69e542429f3dd7a20635a56bc
8,495
py
Python
clu/periodic_actions_test.py
andsteing/CommonLoopUtils
b39e992f60d041bc77809d859586027700a2c3a9
[ "Apache-2.0" ]
80
2020-10-11T17:37:52.000Z
2022-03-30T17:17:05.000Z
clu/periodic_actions_test.py
andsteing/CommonLoopUtils
b39e992f60d041bc77809d859586027700a2c3a9
[ "Apache-2.0" ]
22
2020-12-18T15:12:04.000Z
2021-09-24T08:10:23.000Z
clu/periodic_actions_test.py
andsteing/CommonLoopUtils
b39e992f60d041bc77809d859586027700a2c3a9
[ "Apache-2.0" ]
10
2020-10-13T16:35:30.000Z
2022-02-08T21:00:00.000Z
# Copyright 2021 The CLU Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writ...
30.339286
80
0.671218
7,668
0.902649
0
0
3,214
0.37834
0
0
1,781
0.209653
20c0713b32c4e888c8d8eba2e53d1e750e99ff54
570
py
Python
_scripts/tools/utils/frontmatter_getter.py
gogntao/gogntao.github.io
ee200345d39521652b8c1cf9d27bcc2a6e02f3ef
[ "MIT" ]
null
null
null
_scripts/tools/utils/frontmatter_getter.py
gogntao/gogntao.github.io
ee200345d39521652b8c1cf9d27bcc2a6e02f3ef
[ "MIT" ]
null
null
null
_scripts/tools/utils/frontmatter_getter.py
gogntao/gogntao.github.io
ee200345d39521652b8c1cf9d27bcc2a6e02f3ef
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- ''' Read the posts and return a tuple that consisting of Front Matter and its line number. © 2018-2019 Cotes Chung MIT License ''' def get_yaml(path): end = False yaml = "" num = 0 with open(path, 'r') as f: for line in f.readlines(): ...
18.387097
52
0.452632
0
0
0
0
0
0
0
0
185
0.323993
20c17791d1b4f3f9764ce5a02c3f17aa3c7d9e44
1,014
py
Python
main/cart.py
Dogechi/Me2U
0852600983dc1058ee347f4065ee801e16c1249e
[ "MIT" ]
null
null
null
main/cart.py
Dogechi/Me2U
0852600983dc1058ee347f4065ee801e16c1249e
[ "MIT" ]
9
2020-06-06T01:16:25.000Z
2021-06-04T23:20:37.000Z
main/cart.py
Me2U-Afrika/Me2U
aee054afedff1e6c87f87494eaddf044e217aa95
[ "MIT" ]
null
null
null
from django.conf import settings from django.db.models import Max from datetime import datetime, timedelta from me2ushop.models import Order, OrderItem def remove_old_cart_items(): print('Removing old carts') print('session age:', settings.SESSION_AGE_DAYS) # calculate date of session age days ago rem...
36.214286
90
0.708087
0
0
0
0
0
0
0
0
205
0.20217
20c351d08261a89f6671fb61ae44dfb0f32ca3f0
3,658
py
Python
tasks/python3/processTemporalLayer.py
greck2908/worldview
d17c463080218ce0a3d922be3dc8da5152860391
[ "NASA-1.3" ]
1
2021-03-01T22:10:14.000Z
2021-03-01T22:10:14.000Z
tasks/python3/processTemporalLayer.py
greck2908/worldview
d17c463080218ce0a3d922be3dc8da5152860391
[ "NASA-1.3" ]
4
2021-12-03T00:01:57.000Z
2022-03-22T21:01:34.000Z
tasks/python3/processTemporalLayer.py
greck2908/worldview
d17c463080218ce0a3d922be3dc8da5152860391
[ "NASA-1.3" ]
null
null
null
from datetime import datetime import isodate import re import traceback def to_list(val): return [val] if not hasattr(val, 'reverse') else val # Add duration to end date using # ISO 8601 duration keys def determine_end_date(key, date): return date + isodate.parse_duration(key) # This method takes a layer and...
49.432432
161
0.541006
0
0
0
0
0
0
0
0
714
0.195189
20c46aef8b21547d823f1dda228583f79f1a470c
1,162
py
Python
baal/active/__init__.py
llv22/baal_tf2.4_mac
6eed225f8b57e61d8d16b1868ea655384c566700
[ "Apache-2.0" ]
575
2019-09-30T20:44:28.000Z
2022-03-27T17:39:22.000Z
baal/active/__init__.py
llv22/baal_tf2.4_mac
6eed225f8b57e61d8d16b1868ea655384c566700
[ "Apache-2.0" ]
84
2019-10-01T15:58:55.000Z
2022-03-28T13:27:32.000Z
baal/active/__init__.py
llv22/baal_tf2.4_mac
6eed225f8b57e61d8d16b1868ea655384c566700
[ "Apache-2.0" ]
51
2019-10-08T23:05:39.000Z
2022-02-14T22:13:27.000Z
from typing import Union, Callable from . import heuristics from .active_loop import ActiveLearningLoop from .dataset import ActiveLearningDataset from .file_dataset import FileDataset def get_heuristic( name: str, shuffle_prop: float = 0.0, reduction: Union[str, Callable] = "none", **kwargs ) -> heuristics.Abst...
33.2
92
0.69191
0
0
0
0
0
0
0
0
445
0.38296
20c55612c6dde9a99bf02d10377bbecda4d7f7ce
1,916
py
Python
migrations/versions/e454b1597ab0_.py
Maybells/PostClassical
cbb45add86463deb942825d3c792bc8b6dcdd29b
[ "MIT" ]
null
null
null
migrations/versions/e454b1597ab0_.py
Maybells/PostClassical
cbb45add86463deb942825d3c792bc8b6dcdd29b
[ "MIT" ]
null
null
null
migrations/versions/e454b1597ab0_.py
Maybells/PostClassical
cbb45add86463deb942825d3c792bc8b6dcdd29b
[ "MIT" ]
null
null
null
"""empty message Revision ID: e454b1597ab0 Revises: Create Date: 2021-01-19 11:50:17.899068 """ from alembic import op import sqlalchemy as sa # revision identifiers, used by Alembic. revision = 'e454b1597ab0' down_revision = None branch_labels = None depends_on = None def upgrade(): # ### commands auto gene...
40.765957
86
0.693111
0
0
0
0
0
0
0
0
914
0.477035
20c5797dd314a61d66fc031c71f6307cee019dde
81
py
Python
miniquora/qac/apps.py
rochakgupta/miniquora
341722806c6d42c7cc1ecfe6ff0254f11e9370c7
[ "MIT" ]
null
null
null
miniquora/qac/apps.py
rochakgupta/miniquora
341722806c6d42c7cc1ecfe6ff0254f11e9370c7
[ "MIT" ]
6
2020-06-05T19:47:55.000Z
2022-03-11T23:38:53.000Z
miniquora/qac/apps.py
rochakgupta/miniquora
341722806c6d42c7cc1ecfe6ff0254f11e9370c7
[ "MIT" ]
null
null
null
from django.apps import AppConfig class QacConfig(AppConfig): name = 'qac'
13.5
33
0.728395
44
0.54321
0
0
0
0
0
0
5
0.061728
20c609aa615f44f48228ba80019cfecbd7a032e3
3,249
py
Python
config/application.py
dlsaavedra/Web-API
b3ad6d7d7dc7434c630ac4dcff3a805bba5e47a9
[ "MIT" ]
null
null
null
config/application.py
dlsaavedra/Web-API
b3ad6d7d7dc7434c630ac4dcff3a805bba5e47a9
[ "MIT" ]
null
null
null
config/application.py
dlsaavedra/Web-API
b3ad6d7d7dc7434c630ac4dcff3a805bba5e47a9
[ "MIT" ]
null
null
null
from os import getenv from pathlib import Path from dotenv import load_dotenv base_path = Path('.') # Fully qualified path to the project root env_path = base_path / '.env' # Fully qualified path to the enviroment file app_path = base_path.joinpath('app') # The fully qualified path to the app fold...
48.492537
100
0.492767
0
0
0
0
0
0
0
0
2,605
0.801785
20c6bab3994c954ecffd3763529c8895304de913
72,964
py
Python
versioned_hdf5/tests/test_api.py
Quansight/versioned-hdf5
e2d2eb2bbe2eed851239ee9d1ed7a9cf5cee3c55
[ "BSD-3-Clause" ]
9
2019-12-12T16:04:03.000Z
2020-06-09T05:18:21.000Z
versioned_hdf5/tests/test_api.py
Quansight/versioned-hdf5
e2d2eb2bbe2eed851239ee9d1ed7a9cf5cee3c55
[ "BSD-3-Clause" ]
64
2019-12-13T18:43:13.000Z
2020-06-11T15:58:07.000Z
versioned_hdf5/tests/test_api.py
Quansight/versioned-hdf5
e2d2eb2bbe2eed851239ee9d1ed7a9cf5cee3c55
[ "BSD-3-Clause" ]
3
2020-02-11T18:53:47.000Z
2020-03-10T21:52:43.000Z
import os import itertools from pytest import raises, mark import h5py import datetime import numpy as np from numpy.testing import assert_equal from .helpers import setup_vfile from ..backend import DEFAULT_CHUNK_SIZE from ..api import VersionedHDF5File from ..versions import TIMESTAMP_FMT from ..wrappers import ...
39.249059
118
0.638932
0
0
0
0
4,384
0.060084
0
0
18,115
0.248273