hexsha
stringlengths
40
40
size
int64
4
1.02M
ext
stringclasses
8 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
209
max_stars_repo_name
stringlengths
5
121
max_stars_repo_head_hexsha
stringlengths
40
40
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
4
209
max_issues_repo_name
stringlengths
5
121
max_issues_repo_head_hexsha
stringlengths
40
40
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
4
209
max_forks_repo_name
stringlengths
5
121
max_forks_repo_head_hexsha
stringlengths
40
40
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
4
1.02M
avg_line_length
float64
1.07
66.1k
max_line_length
int64
4
266k
alphanum_fraction
float64
0.01
1
921d87ebd3a06e264af37b57c15f3b426169fe5a
5,667
py
Python
novaclient/tests/unit/v2/contrib/fakes.py
alvarolopez/python-novaclient
ef7cb1d44d47a1273810603fd96d982d7f0bd7d6
[ "Apache-1.1" ]
null
null
null
novaclient/tests/unit/v2/contrib/fakes.py
alvarolopez/python-novaclient
ef7cb1d44d47a1273810603fd96d982d7f0bd7d6
[ "Apache-1.1" ]
null
null
null
novaclient/tests/unit/v2/contrib/fakes.py
alvarolopez/python-novaclient
ef7cb1d44d47a1273810603fd96d982d7f0bd7d6
[ "Apache-1.1" ]
null
null
null
# Copyright 2012 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 in writ...
36.095541
75
0.470796
1fbcee968bba97eac0cc9b13eadb31d2449e671d
1,005
py
Python
taiga/events/backends/__init__.py
threefoldtech/Threefold-Circles
cbc433796b25cf7af9a295af65d665a4a279e2d6
[ "Apache-2.0" ]
null
null
null
taiga/events/backends/__init__.py
threefoldtech/Threefold-Circles
cbc433796b25cf7af9a295af65d665a4a279e2d6
[ "Apache-2.0" ]
12
2019-11-25T14:08:32.000Z
2021-06-24T10:35:51.000Z
taiga/events/backends/__init__.py
threefoldtech/Threefold-Circles
cbc433796b25cf7af9a295af65d665a4a279e2d6
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright (C) 2014-2017 Andrey Antukh <niwi@niwi.nz> # Copyright (C) 2014-2017 Jesús Espino <jespinog@gmail.com> # Copyright (C) 2014-2017 David Barragán <bameda@dbarragan.com> # Copyright (C) 2014-2017 Alejandro Alonso <alejandro.alonso@kaleidos.net> # This program is free software: you can r...
45.681818
74
0.760199
d779c3961dd291860b45df97f1726d3f0fea09a9
7,960
py
Python
src/pytkdocs/serializer.py
shashankrnr32/pytkdocs
bf04764f1608970643932329c9f6c8c63a0c5632
[ "0BSD" ]
1
2021-04-30T23:34:03.000Z
2021-04-30T23:34:03.000Z
src/pytkdocs/serializer.py
shashankrnr32/pytkdocs
bf04764f1608970643932329c9f6c8c63a0c5632
[ "0BSD" ]
null
null
null
src/pytkdocs/serializer.py
shashankrnr32/pytkdocs
bf04764f1608970643932329c9f6c8c63a0c5632
[ "0BSD" ]
null
null
null
""" This module defines function to serialize objects. These functions simply take objects as parameters and return dictionaries that can be dumped by `json.dumps`. """ import inspect import re from typing import Any, Match, Optional, Pattern from pytkdocs.objects import Object, Source from pytkdocs.parsers.docstrin...
32.757202
112
0.66407
d66f088619ab3c18978d4063fc454570ddc6728e
984
py
Python
timus/1013.py
nurseiit/compete
7e36898860a279e397bcb51308d0aef0860cc448
[ "MIT" ]
3
2019-06-28T17:12:44.000Z
2021-07-22T01:16:01.000Z
timus/1013.py
nurseiit/compete
7e36898860a279e397bcb51308d0aef0860cc448
[ "MIT" ]
null
null
null
timus/1013.py
nurseiit/compete
7e36898860a279e397bcb51308d0aef0860cc448
[ "MIT" ]
null
null
null
def matmulmod(a, b, mod): n = len(a) m = len(a[0]) p = len(b[0]) c = [[0 for i in range(p)] for j in range(n)] for i in range(n): for j in range(m): for k in range(p): c[i][k] = (c[i][k] + a[i][j] * b[j][k]) % mod return c def matpowmod(a, n, mod): res =...
18.566038
61
0.386179
cf82c2b7848a3dc07ff73d7ae8929ad3ed1d8bc4
10,378
py
Python
dataloader/loader.py
Jvictor97/AWR-Adaptive-Weighting-Regression
2c29f8ac3d824edfff07465232ffed8e4d837ebf
[ "MIT" ]
90
2020-03-16T15:18:57.000Z
2022-03-16T10:02:52.000Z
dataloader/loader.py
Jvictor97/AWR-Adaptive-Weighting-Regression
2c29f8ac3d824edfff07465232ffed8e4d837ebf
[ "MIT" ]
16
2020-05-01T03:11:44.000Z
2021-12-14T13:03:38.000Z
dataloader/loader.py
Jvictor97/AWR-Adaptive-Weighting-Regression
2c29f8ac3d824edfff07465232ffed8e4d837ebf
[ "MIT" ]
16
2020-05-21T09:07:04.000Z
2022-02-22T13:00:19.000Z
from torch.utils.data import Dataset import numpy as np import cv2 from util.util import uvd2xyz, xyz2uvd from scipy.sparse import coo_matrix class Loader(Dataset): def __init__(self, root, phase, img_size, dataset_name): assert phase in ['train', 'test'] self.seed = np.random.RandomState(23455) ...
39.610687
148
0.581422
5892dca5bef621824f52a62ad9f5d1dc476200bd
1,071
py
Python
tests/math/unary/test_scipy_mirror.py
kw-0/MyGrad
307f1bb5f2391e7f4df49fe43a7acf9d1e8ea141
[ "MIT" ]
147
2018-07-14T01:37:35.000Z
2022-03-29T06:37:58.000Z
tests/math/unary/test_scipy_mirror.py
kw-0/MyGrad
307f1bb5f2391e7f4df49fe43a7acf9d1e8ea141
[ "MIT" ]
223
2018-05-31T14:13:18.000Z
2022-02-27T18:53:49.000Z
tests/math/unary/test_scipy_mirror.py
kw-0/MyGrad
307f1bb5f2391e7f4df49fe43a7acf9d1e8ea141
[ "MIT" ]
27
2018-06-17T14:42:05.000Z
2021-10-31T00:21:09.000Z
import hypothesis.extra.numpy as hnp import hypothesis.strategies as st import numpy as np import pytest from hypothesis import given, settings from numpy.testing import assert_array_equal from scipy import special from mygrad.math._special import logsumexp from tests.custom_strategies import valid_axes @settings(de...
30.6
75
0.727358
f1faca6c9b464f026432ddbb22e7958eeb485dd3
7,529
py
Python
tests/test_optic.py
dkirkby/batoid
734dccc289eb7abab77a62cdc14563ed5981753b
[ "BSD-2-Clause" ]
null
null
null
tests/test_optic.py
dkirkby/batoid
734dccc289eb7abab77a62cdc14563ed5981753b
[ "BSD-2-Clause" ]
null
null
null
tests/test_optic.py
dkirkby/batoid
734dccc289eb7abab77a62cdc14563ed5981753b
[ "BSD-2-Clause" ]
null
null
null
import batoid import numpy as np import os from test_helpers import timer, do_pickle, all_obj_diff import time import yaml @timer def test_optic(): if __name__ == '__main__': nside = 128 else: nside = 32 rays = batoid.rayGrid(20, 12.0, 0.005, 0.005, -1.0, nside, 500e-9, 1.0, batoid.ConstM...
31.767932
105
0.644441
26e8e46ad104701dba3bb3458d78f98f21b1be6d
1,584
py
Python
profiles_PROJECT/profiles_api/serializers.py
TheKinng96/rest-api
7835651547d82504e9e764eaa44ff00c73b9dbf3
[ "MIT" ]
null
null
null
profiles_PROJECT/profiles_api/serializers.py
TheKinng96/rest-api
7835651547d82504e9e764eaa44ff00c73b9dbf3
[ "MIT" ]
1
2020-04-28T10:35:49.000Z
2020-04-28T10:35:49.000Z
profiles_PROJECT/profiles_api/serializers.py
TheKinng96/rest-api
7835651547d82504e9e764eaa44ff00c73b9dbf3
[ "MIT" ]
null
null
null
from rest_framework import serializers from profiles_api.models import UserProfile from profiles_api.models import ProfileFeedItem class HelloSerializer(serializers.Serializer): """Serializes a name field for testing our APIView""" name = serializers.CharField(max_length=10) #serializer function for post cl...
32.326531
77
0.645202
eb789a0d8e6489c75467d86f35fa2b311ed7fdbf
18,580
py
Python
mmt/featureExtractor.py
Montimage/acas
49c345cee5eabbda4833119de5403316139031b5
[ "Apache-2.0" ]
null
null
null
mmt/featureExtractor.py
Montimage/acas
49c345cee5eabbda4833119de5403316139031b5
[ "Apache-2.0" ]
null
null
null
mmt/featureExtractor.py
Montimage/acas
49c345cee5eabbda4833119de5403316139031b5
[ "Apache-2.0" ]
null
null
null
import numpy import pandas as pd from scipy.stats import entropy """ Deals with calculation of actual ML features. feature_names - predefined col names for the final ML feature dataframe """ feature_names = ['ip.pkts_per_flow', 'duration', 'ip.header_len', 'ip.payload_len', 'ip.avg_bytes_tot_len...
56.132931
181
0.636598
a76c81ca157c4e88a20827feb9460ccada22e47b
5,572
py
Python
tests/test_precision_recall_metrics.py
michaelwang123/PaddleRec
4feb0a7f962e918bdfa4f7289a9ddfd08d459824
[ "Apache-2.0" ]
2,739
2020-04-28T05:12:48.000Z
2022-03-31T16:01:49.000Z
tests/test_precision_recall_metrics.py
michaelwang123/PaddleRec
4feb0a7f962e918bdfa4f7289a9ddfd08d459824
[ "Apache-2.0" ]
205
2020-05-14T13:29:14.000Z
2022-03-31T13:01:50.000Z
tests/test_precision_recall_metrics.py
michaelwang123/PaddleRec
4feb0a7f962e918bdfa4f7289a9ddfd08d459824
[ "Apache-2.0" ]
545
2020-05-14T13:19:13.000Z
2022-03-24T07:53:05.000Z
# Copyright (c) 2018 PaddlePaddle Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by app...
34.184049
79
0.611989
92c9e1100f6ea8f99947cec4a0929343375fdd9a
6,447
py
Python
solvers/lasso_utils/celebA_estimators.py
mjsong32/GlowRED
5189b299452e39b99e63ad2d024d2754d66cf3d5
[ "MIT" ]
2
2019-08-30T12:10:55.000Z
2021-07-08T20:50:44.000Z
solvers/lasso_utils/celebA_estimators.py
mjsong32/GlowRED
5189b299452e39b99e63ad2d024d2754d66cf3d5
[ "MIT" ]
null
null
null
solvers/lasso_utils/celebA_estimators.py
mjsong32/GlowRED
5189b299452e39b99e63ad2d024d2754d66cf3d5
[ "MIT" ]
1
2021-05-12T17:15:31.000Z
2021-05-12T17:15:31.000Z
"""Estimators for compressed sensing""" # pylint: disable = C0301, C0103, C0111, R0914 import copy import heapq import numpy as np from . import utils #import utils import scipy.fftpack as fftpack import pywt def dct2(image_channel): return fftpack.dct(fftpack.dct(image_channel.T, norm='ortho').T, norm='ortho') ...
33.578125
144
0.557934
e98a4c2646cab1799d4d936415b4fc3d15e7c1b1
9,978
py
Python
config/scratch/mask_r50v1b_fpn_gn_scratch_2x.py
happywu/simpledet-1
5d1de1edfbe745b05b49d9c19eca1e496ded11b7
[ "Apache-2.0" ]
3,195
2019-01-29T09:08:46.000Z
2022-03-29T08:20:44.000Z
config/scratch/mask_r50v1b_fpn_gn_scratch_2x.py
happywu/simpledet-1
5d1de1edfbe745b05b49d9c19eca1e496ded11b7
[ "Apache-2.0" ]
275
2019-01-29T10:16:12.000Z
2022-03-15T17:56:39.000Z
config/scratch/mask_r50v1b_fpn_gn_scratch_2x.py
happywu/simpledet-1
5d1de1edfbe745b05b49d9c19eca1e496ded11b7
[ "Apache-2.0" ]
563
2019-01-29T09:32:07.000Z
2022-03-22T06:58:01.000Z
from symbol.builder import add_anchor_to_arg from symbol.builder import ResNetV1bFPN as Backbone from models.FPN.builder import FPNNeck as Neck from models.FPN.builder import FPNRoiAlign as RoiExtractor from models.FPN.builder import FPNBbox2fcHead as BboxHead from mxnext.complicate import normalizer_factory from mode...
29.696429
147
0.592704
a71c78de72a2115f3c0cc23e020102d4420b8309
3,912
py
Python
blobDetectorParameters.py
qenops/dDisplay
3a7846378733d95c17b6274cc3ebe775bbd8f758
[ "Apache-2.0" ]
null
null
null
blobDetectorParameters.py
qenops/dDisplay
3a7846378733d95c17b6274cc3ebe775bbd8f758
[ "Apache-2.0" ]
null
null
null
blobDetectorParameters.py
qenops/dDisplay
3a7846378733d95c17b6274cc3ebe775bbd8f758
[ "Apache-2.0" ]
null
null
null
import cv2 import numpy as np # Generate and display the images def update(dummy=None): params = cv2.SimpleBlobDetector_Params() params.minThreshold = max(cv2.getTrackbarPos('Min Threshold', 'Blob Detector'),1) params.maxThreshold = cv2.getTrackbarPos('Max Threshold', 'Blob Detector') params.thresholdS...
49.518987
122
0.704499
de704ed20294488b0219ab22b985451e51b62bc7
7,956
py
Python
examples/catalyst_rl/dqn.py
Thiefwerty/catalyst
58c4e0e3ca3928f7402cfc750fbc9a77e44a2b66
[ "Apache-2.0" ]
2,693
2019-01-23T19:16:12.000Z
2022-03-31T02:12:42.000Z
examples/catalyst_rl/dqn.py
Thiefwerty/catalyst
58c4e0e3ca3928f7402cfc750fbc9a77e44a2b66
[ "Apache-2.0" ]
763
2019-01-22T20:12:56.000Z
2022-03-27T18:36:10.000Z
examples/catalyst_rl/dqn.py
Thiefwerty/catalyst
58c4e0e3ca3928f7402cfc750fbc9a77e44a2b66
[ "Apache-2.0" ]
445
2019-01-23T17:07:09.000Z
2022-03-30T05:38:45.000Z
# flake8: noqa from typing import Sequence import os from buffer import OffpolicyReplayBuffer from db import RedisDB from misc import GameCallback, soft_update, Trajectory import numpy as np from sampler import ISampler import gym import torch import torch.nn as nn from torch.utils.data import DataLoader from cataly...
32.080645
94
0.619532
b777e28f1a899ec4019e29d7680545dec9e50a1b
924
py
Python
geometry/ib3shapes.py
matinraayai/ibex
7792d1299a04da360faa1cd8a16a4c5a3990b48c
[ "MIT" ]
3
2018-08-10T21:11:09.000Z
2019-07-26T13:47:24.000Z
geometry/ib3shapes.py
matinraayai/ibex
7792d1299a04da360faa1cd8a16a4c5a3990b48c
[ "MIT" ]
null
null
null
geometry/ib3shapes.py
matinraayai/ibex
7792d1299a04da360faa1cd8a16a4c5a3990b48c
[ "MIT" ]
6
2018-03-05T20:14:11.000Z
2020-07-23T18:39:16.000Z
from copy import deepcopy from ibex.utilities.constants import * class IBBox: def __init__(self, mins, maxs): self.mins = list(mins) self.maxs = list(maxs) def __str__(self): return '({},{},{})-({},{},{})'.format(self.mins[IB_X], self.mins[IB_Y], self.mins[IB_Z], self.maxs[IB_X], self....
46.2
147
0.62013
410b9567103e14643c532178552c0b61c56e2b73
16,843
py
Python
sysroot/usr/lib/python3/dist-packages/urllib3/poolmanager.py
219-design/sysroot_qt5.15.0_binaries_armv6zk_rpizero
c3ad917b65b970c451148391ef1c2483593702ed
[ "MIT" ]
null
null
null
sysroot/usr/lib/python3/dist-packages/urllib3/poolmanager.py
219-design/sysroot_qt5.15.0_binaries_armv6zk_rpizero
c3ad917b65b970c451148391ef1c2483593702ed
[ "MIT" ]
null
null
null
sysroot/usr/lib/python3/dist-packages/urllib3/poolmanager.py
219-design/sysroot_qt5.15.0_binaries_armv6zk_rpizero
c3ad917b65b970c451148391ef1c2483593702ed
[ "MIT" ]
null
null
null
from __future__ import absolute_import import collections import functools import logging from ._collections import RecentlyUsedContainer from .connectionpool import HTTPConnectionPool, HTTPSConnectionPool from .connectionpool import port_by_scheme from .exceptions import LocationValueError, MaxRetryError, ProxyScheme...
37.345898
92
0.643531
63bc39c2475de1798a07474cae5eca4c30949561
4,228
py
Python
robot/Player.py
1509098778/wukong-robot
0c80bdc885a04a2e33051ddf4be119e5f8a9c194
[ "MIT" ]
1
2019-02-25T06:05:22.000Z
2019-02-25T06:05:22.000Z
robot/Player.py
1509098778/wukong-robot
0c80bdc885a04a2e33051ddf4be119e5f8a9c194
[ "MIT" ]
null
null
null
robot/Player.py
1509098778/wukong-robot
0c80bdc885a04a2e33051ddf4be119e5f8a9c194
[ "MIT" ]
1
2019-02-20T15:21:18.000Z
2019-02-20T15:21:18.000Z
# -*- coding: utf-8-*- import subprocess import tempfile import threading import os import wave from . import utils import pyaudio from robot import logging from ctypes import CFUNCTYPE, c_char_p, c_int, cdll from contextlib import contextmanager logger = logging.getLogger(__name__) def py_error_handler(filename, lin...
25.166667
80
0.592479
3f6a047327235f152897369d97cf2e4fc8e4c61d
348
py
Python
2018/01 - chronical calibration/01.py
Stannislav/Advent-of-Code
b9571e71e1acedf74be3bb32f03c9877f57c48dd
[ "MIT" ]
2
2020-12-12T17:06:47.000Z
2021-12-15T04:06:57.000Z
2018/01 - chronical calibration/01.py
Stannislav/Advent-of-Code
b9571e71e1acedf74be3bb32f03c9877f57c48dd
[ "MIT" ]
null
null
null
2018/01 - chronical calibration/01.py
Stannislav/Advent-of-Code
b9571e71e1acedf74be3bb32f03c9877f57c48dd
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # Read input dfs = [int(line) for line in open('01_input.txt', 'r')] # Part 1 print(f"Part 1: {sum(dfs)}") # Part 2 f = 0 seen = {f} found = False while not found: for df in dfs: f += df if f in seen: print(f"Part 2: {f}") found = True ...
13.92
55
0.497126
63bc715cc386e7ebb4a38dbe65276152c6662832
40,551
py
Python
schema_utils_test.py
prayutsu/oppia
e82da7653f7bbfb9ded0e1ba16cd9f481ff5a786
[ "Apache-2.0" ]
2
2020-03-28T18:32:45.000Z
2021-02-07T18:29:31.000Z
schema_utils_test.py
prayutsu/oppia
e82da7653f7bbfb9ded0e1ba16cd9f481ff5a786
[ "Apache-2.0" ]
35
2019-02-23T20:31:21.000Z
2019-08-19T12:32:13.000Z
schema_utils_test.py
prayutsu/oppia
e82da7653f7bbfb9ded0e1ba16cd9f481ff5a786
[ "Apache-2.0" ]
1
2021-01-28T05:20:56.000Z
2021-01-28T05:20:56.000Z
# coding: utf-8 # # Copyright 2014 The Oppia Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless requi...
38.546578
80
0.56445
4f527119f3a8b5389a67b1a79de362ebfe605725
3,879
py
Python
golem/report/utils.py
Racerinorbit/golem
b02c7acaed6e84ff565e34e8626e835ec451e2e4
[ "MIT" ]
null
null
null
golem/report/utils.py
Racerinorbit/golem
b02c7acaed6e84ff565e34e8626e835ec451e2e4
[ "MIT" ]
null
null
null
golem/report/utils.py
Racerinorbit/golem
b02c7acaed6e84ff565e34e8626e835ec451e2e4
[ "MIT" ]
null
null
null
import os from io import BytesIO from golem import execution from golem.browser import get_browser def save_screenshot(reportdir, image_name, format='PNG', quality=None, width=None, height=None, resize=None): """Modify screenshot format, size and quality before saving. Pillow must be inst...
36.59434
99
0.617685
4ba9ce0a53ea794bfd769ba779bce030e089a3e4
3,085
py
Python
pontoon/checks/migrations/0001_initial.py
Tratty/pontoon
ecb903d72f9274f02137b16669cc3c5859f6329c
[ "BSD-3-Clause" ]
3
2020-01-27T12:26:20.000Z
2022-02-03T09:56:02.000Z
pontoon/checks/migrations/0001_initial.py
texnoman/pontoon-src
6b40ac229605e99966c3bdd1510b772c89d4de24
[ "BSD-3-Clause" ]
1
2021-03-24T12:33:03.000Z
2021-03-24T12:50:19.000Z
pontoon/checks/migrations/0001_initial.py
texnoman/pontoon-src
6b40ac229605e99966c3bdd1510b772c89d4de24
[ "BSD-3-Clause" ]
4
2020-01-26T21:28:43.000Z
2021-06-10T15:25:19.000Z
# -*- coding: utf-8 -*- # Generated by Django 1.11.11 on 2018-05-23 10:25 from __future__ import unicode_literals from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): initial = True dependencies = [ ("base", "0121_bug_1453999_disable_sync"...
31.479592
87
0.363371
632601df1f2de2c100a4faeeae3b47a71261b520
2,026
py
Python
towel/templatetags/modelview_list.py
enterstudio/towel
6892788527b8a111cbf5963e909964aabc96d740
[ "BSD-3-Clause" ]
null
null
null
towel/templatetags/modelview_list.py
enterstudio/towel
6892788527b8a111cbf5963e909964aabc96d740
[ "BSD-3-Clause" ]
null
null
null
towel/templatetags/modelview_list.py
enterstudio/towel
6892788527b8a111cbf5963e909964aabc96d740
[ "BSD-3-Clause" ]
null
null
null
from __future__ import absolute_import, unicode_literals from django import template from django.db import models from django.utils.safestring import mark_safe from django.utils.translation import ugettext as _ from towel.templatetags import towel_resources register = template.Library() register.inclusion_tag('to...
27.753425
76
0.563179
1fb4a2b6a285fe430c120cba4cd1dc6973abb739
1,464
py
Python
submissions/Hess/myLegos.py
WhittKinley/Legos
861a2651f481d0463003007694c895d3df3b0fee
[ "MIT" ]
null
null
null
submissions/Hess/myLegos.py
WhittKinley/Legos
861a2651f481d0463003007694c895d3df3b0fee
[ "MIT" ]
null
null
null
submissions/Hess/myLegos.py
WhittKinley/Legos
861a2651f481d0463003007694c895d3df3b0fee
[ "MIT" ]
null
null
null
from ev3dev.auto import OUTPUT_A, OUTPUT_B, OUTPUT_C, LargeMotor, MediumMotor from ev3dev.auto import INPUT_1, INPUT_2, INPUT_3, TouchSensor, ColorSensor import time import ev3dev.ev3 as ev3 baseTouch = TouchSensor(INPUT_1) armTouch = TouchSensor(INPUT_2) colorSensor = ColorSensor(INPUT_3) clawMotor = MediumMotor(OUTP...
27.111111
77
0.757514
d0e9379344716925dbfcf863a0bf6be249146425
139
py
Python
test_data/parse/unexpected/method_definitions/argument_with_final/meta_model.py
gillistephan/aas-core-codegen
5b89ea2ee35aecaca9a1bed7ac81d420cc560f29
[ "MIT" ]
5
2021-12-29T12:55:34.000Z
2022-03-01T17:57:21.000Z
test_data/parse/unexpected/method_definitions/argument_with_final/meta_model.py
gillistephan/aas-core-codegen
5b89ea2ee35aecaca9a1bed7ac81d420cc560f29
[ "MIT" ]
10
2021-12-29T02:15:55.000Z
2022-03-09T11:04:22.000Z
test_data/parse/unexpected/method_definitions/argument_with_final/meta_model.py
gillistephan/aas-core-codegen
5b89ea2ee35aecaca9a1bed7ac81d420cc560f29
[ "MIT" ]
2
2021-12-29T01:42:12.000Z
2022-02-15T13:46:33.000Z
class Something: def do_something(self, x: List[Final[int]]) -> None: pass __book_url__ = "dummy" __book_version__ = "dummy"
17.375
56
0.661871
cabce6916c464edf3b8767e6a6282db43ddd035f
3,056
py
Python
scripts/tests/py_onnx/keras/export_scripts/upsample2D_enc_dec_mnist_keras_export.py
lauracanalini/eddl
c5efac642e8e1f99b31dfaaacd0a5a058b09923b
[ "MIT" ]
30
2019-10-11T21:03:43.000Z
2022-02-17T19:56:15.000Z
scripts/tests/py_onnx/keras/export_scripts/upsample2D_enc_dec_mnist_keras_export.py
lauracanalini/eddl
c5efac642e8e1f99b31dfaaacd0a5a058b09923b
[ "MIT" ]
151
2019-10-16T06:47:23.000Z
2022-03-07T15:15:58.000Z
scripts/tests/py_onnx/keras/export_scripts/upsample2D_enc_dec_mnist_keras_export.py
lauracanalini/eddl
c5efac642e8e1f99b31dfaaacd0a5a058b09923b
[ "MIT" ]
20
2019-10-16T09:37:37.000Z
2022-02-22T09:47:14.000Z
import argparse from tensorflow.keras.models import Sequential from tensorflow.keras.layers import Input, Conv2D, UpSampling2D, MaxPooling2D from tensorflow.keras.datasets import mnist import keras2onnx # Training settings parser = argparse.ArgumentParser(description='Keras Conv+Upsample encoder decoder MNIST Example...
36.819277
99
0.697644
e1d8dd311c2168f5e230816b35a1a02b960900d6
4,284
py
Python
client.py
mikepage/salto
84161e417d406d10ead0977786553f202def8896
[ "MIT" ]
3
2021-02-02T15:46:56.000Z
2021-04-28T06:55:33.000Z
client.py
mikepage/salto
84161e417d406d10ead0977786553f202def8896
[ "MIT" ]
null
null
null
client.py
mikepage/salto
84161e417d406d10ead0977786553f202def8896
[ "MIT" ]
1
2021-01-18T11:57:38.000Z
2021-01-18T11:57:38.000Z
import io import socket from logging import Logger from time import sleep from typing import Optional from salto import common from salto.message import Message from salto.response import Response class Client: MAX_RETRIES = 3 CONNECT_TIMEOUT = 10 # seconds to connect the server WRITE_TIMEOUT = 10 # s...
35.404959
113
0.626984
b59cd576dcadf57bebff93646287cb059ac4c492
2,141
py
Python
main.py
igorplyukhin/Cloudy
d4acb2fe6e992a9ec95518ab2a3d240c610043a8
[ "MIT" ]
null
null
null
main.py
igorplyukhin/Cloudy
d4acb2fe6e992a9ec95518ab2a3d240c610043a8
[ "MIT" ]
null
null
null
main.py
igorplyukhin/Cloudy
d4acb2fe6e992a9ec95518ab2a3d240c610043a8
[ "MIT" ]
null
null
null
import click from config import STORAGE from ApiError import ApiError # TODO UnitTests @click.group() def cli(): pass @cli.command() @click.option('-lp', '--local_path', default='.', help='Path to save file') @click.argument('cloud_path') def download_file(local_path, cloud_path): click.secho('Downloading....
26.432099
93
0.677254
456142d237684f67a52f370e2720a880665b4f25
1,844
py
Python
smooth_edge.py
Derek-Wds/training_CartoonGAN
fb7f75cc389833fd5eb08bdb56f9d6e44ecc5dac
[ "MIT" ]
2
2019-07-07T14:57:23.000Z
2019-07-14T04:11:15.000Z
smooth_edge.py
Derek-Wds/training_CartoonGAN
fb7f75cc389833fd5eb08bdb56f9d6e44ecc5dac
[ "MIT" ]
10
2019-10-23T05:44:51.000Z
2022-03-11T23:52:00.000Z
smooth_edge.py
Derek-Wds/training_CartoonGAN
fb7f75cc389833fd5eb08bdb56f9d6e44ecc5dac
[ "MIT" ]
null
null
null
import numpy as np import cv2, os from tqdm import tqdm # edge smoothing def smooth_edge(path, img_size=256): file_list = os.listdir(path) save_path = 'dataset/smooth_cartoon_imgs' if not os.path.exists(os.path.abspath()+'/'+save_path): os.mkdir(save_path) kernel_size = 5 kernel = np....
40.086957
154
0.61551
99ef11f3111487434dba651fe48e4c0e623de25d
5,269
py
Python
setup.py
QihongL/brainiak
cdc53fa15eb779c7b3ac7c3e237e403b3237c73e
[ "Apache-2.0" ]
2
2019-07-04T20:10:26.000Z
2020-09-23T13:22:06.000Z
setup.py
QihongL/brainiak
cdc53fa15eb779c7b3ac7c3e237e403b3237c73e
[ "Apache-2.0" ]
1
2021-04-09T15:31:27.000Z
2021-04-09T15:31:27.000Z
setup.py
QihongL/brainiak
cdc53fa15eb779c7b3ac7c3e237e403b3237c73e
[ "Apache-2.0" ]
1
2018-07-11T13:04:22.000Z
2018-07-11T13:04:22.000Z
from distutils import sysconfig from setuptools import setup, Extension, find_packages from setuptools.command.build_ext import build_ext import os import sys import setuptools from copy import deepcopy assert sys.version_info >= (3, 5), ( "Please use Python version 3.5 or higher, " "lower versions are not su...
31.363095
77
0.607705
0929653f3d7fdf2e2ae8981d87d12144242b7828
6,444
py
Python
qa/rpc-tests/bip65-cltv-p2p.py
danielaTorrezE/BCH
704a5115998b68c662440b9fdd232579dd884d20
[ "MIT" ]
null
null
null
qa/rpc-tests/bip65-cltv-p2p.py
danielaTorrezE/BCH
704a5115998b68c662440b9fdd232579dd884d20
[ "MIT" ]
null
null
null
qa/rpc-tests/bip65-cltv-p2p.py
danielaTorrezE/BCH
704a5115998b68c662440b9fdd232579dd884d20
[ "MIT" ]
null
null
null
#!/usr/bin/env python2 # # Distributed under the MIT/X11 software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. # from test_framework.test_framework import ComparisonTestFramework from test_framework.util import * from test_framework.mininode import CTransaction, N...
36.822857
100
0.630975
313143a66ae5548ce4c264a7489e3ee3a41d570a
11,642
py
Python
MetamorphicTests/all_mutants/sales_forecasting_file/142.py
anuragbms/Sales-forecasting-with-RNNs
22b4639ecbb48381af53326ace94a3538201b586
[ "Apache-2.0" ]
null
null
null
MetamorphicTests/all_mutants/sales_forecasting_file/142.py
anuragbms/Sales-forecasting-with-RNNs
22b4639ecbb48381af53326ace94a3538201b586
[ "Apache-2.0" ]
null
null
null
MetamorphicTests/all_mutants/sales_forecasting_file/142.py
anuragbms/Sales-forecasting-with-RNNs
22b4639ecbb48381af53326ace94a3538201b586
[ "Apache-2.0" ]
1
2022-02-06T14:59:43.000Z
2022-02-06T14:59:43.000Z
def gen_mutants(): import tensorflow as tf import pandas import numpy as np DATAFILE_TRAIN = 'mock_kaggle_edit_train.csv' DATAFILE_VALIDATE = 'mock_kaggle_edit_...
31.211796
232
0.629531
474ce80e19de8d37e960e7b121c0439e28a01a30
325
py
Python
mpfmonitor/_version.py
kylenahas/mpf-monitor
e3cc22064ebb709788c770a8940d0b0f742a8741
[ "MIT" ]
null
null
null
mpfmonitor/_version.py
kylenahas/mpf-monitor
e3cc22064ebb709788c770a8940d0b0f742a8741
[ "MIT" ]
null
null
null
mpfmonitor/_version.py
kylenahas/mpf-monitor
e3cc22064ebb709788c770a8940d0b0f742a8741
[ "MIT" ]
null
null
null
# mpf-monitor __version__ = '0.54.0-dev.1' __short_version__ = '0.54' __bcp_version__ = '1.1' __config_version__ = '5' __mpf_version_required__ = '0.54.0-dev.0' version = "MPF Monitor v{} (config_version={}, BCP v{}, Requires MPF v{})".format( __version__, __config_version__, __bcp_version__, __mpf_version_require...
32.5
82
0.735385
25aba7a39e6450ac047bd8cf5fbd9b2c23753a23
3,189
py
Python
tests/pytests/unit/states/test_composer.py
markgras/salt
d66cd3c935533c63870b83228b978ce43e0ef70d
[ "Apache-2.0" ]
1
2015-04-01T21:38:46.000Z
2015-04-01T21:38:46.000Z
tests/pytests/unit/states/test_composer.py
markgras/salt
d66cd3c935533c63870b83228b978ce43e0ef70d
[ "Apache-2.0" ]
9
2021-03-31T20:25:25.000Z
2021-07-04T05:33:46.000Z
tests/pytests/unit/states/test_composer.py
markgras/salt
d66cd3c935533c63870b83228b978ce43e0ef70d
[ "Apache-2.0" ]
null
null
null
""" :codeauthor: Jayesh Kariya <jayeshk@saltstack.com> """ import pytest import salt.states.composer as composer from salt.exceptions import SaltException from tests.support.mock import MagicMock, patch @pytest.fixture def configure_loader_modules(): return {composer: {}} def test_installed(): """ ...
38.421687
95
0.60301
05292a09b53bbabdd8aef52620515b8e69c2e1b3
2,156
py
Python
assets/ctfFiles/2021/idek2021/crypto/nameless/nameless.py
Angmar2722/Angmar2722.github.io
6d79cfeeb6681b32d62caba167e14c2f4eeb2569
[ "MIT" ]
null
null
null
assets/ctfFiles/2021/idek2021/crypto/nameless/nameless.py
Angmar2722/Angmar2722.github.io
6d79cfeeb6681b32d62caba167e14c2f4eeb2569
[ "MIT" ]
null
null
null
assets/ctfFiles/2021/idek2021/crypto/nameless/nameless.py
Angmar2722/Angmar2722.github.io
6d79cfeeb6681b32d62caba167e14c2f4eeb2569
[ "MIT" ]
9
2021-06-30T07:57:08.000Z
2022-01-03T09:22:35.000Z
#!/usr/bin/env python3 from Crypto.Util.number import getPrime, bytes_to_long flag = bytes_to_long(open("flag.txt", "rb").read()) p = getPrime(1024) q = getPrime(1024) n = p*q e = 65537 c = pow(flag, e, n) print(f"{n = }") print(f"{p**2 + q**2 = }") print(f"{c = }") # n = 1703935390757730443533506426340401455487...
98
633
0.938312
7fb0034c9e297c6866730de21fccd50f239e2da7
2,046
py
Python
symphony/cli/pyinventory/graphql/mutation/add_customer.py
idoshveki/magma
8022267bd8b8d94913fbb9a0836880361d785446
[ "BSD-3-Clause" ]
null
null
null
symphony/cli/pyinventory/graphql/mutation/add_customer.py
idoshveki/magma
8022267bd8b8d94913fbb9a0836880361d785446
[ "BSD-3-Clause" ]
null
null
null
symphony/cli/pyinventory/graphql/mutation/add_customer.py
idoshveki/magma
8022267bd8b8d94913fbb9a0836880361d785446
[ "BSD-3-Clause" ]
1
2021-05-18T06:54:58.000Z
2021-05-18T06:54:58.000Z
#!/usr/bin/env python3 # @generated AUTOGENERATED file. Do not Change! from dataclasses import dataclass from datetime import datetime from gql.gql.datetime_utils import DATETIME_FIELD from gql.gql.graphql_client import GraphqlClient from gql.gql.client import OperationException from gql.gql.reporter import FailedOper...
32.47619
113
0.699413
8f625d4e5e84840037d548b8b541b3093dab8cbd
3,219
py
Python
example1/automata_example1.py
sebras/berkeman-accelerator-project_skeleton
ec71dee81bc511ee78cd3158847797537bf1c6c5
[ "Apache-2.0" ]
15
2018-04-20T18:49:33.000Z
2020-07-31T04:50:16.000Z
example1/automata_example1.py
sebras/berkeman-accelerator-project_skeleton
ec71dee81bc511ee78cd3158847797537bf1c6c5
[ "Apache-2.0" ]
1
2018-05-25T06:56:00.000Z
2018-06-05T17:56:47.000Z
example1/automata_example1.py
sebras/berkeman-accelerator-project_skeleton
ec71dee81bc511ee78cd3158847797537bf1c6c5
[ "Apache-2.0" ]
11
2018-04-20T18:49:41.000Z
2021-01-15T10:58:36.000Z
############################################################################ # # # Copyright (c) 2018 eBay Inc. # # # # Licensed u...
40.746835
76
0.543026
3e111acecf3a12432b238613f021f393b294523a
959
py
Python
tasks/__init__.py
ssfdust/smorest-sfs
139f6817989ab041c81761d183169de20a26597e
[ "Apache-2.0" ]
8
2020-05-11T07:11:03.000Z
2022-03-25T01:58:18.000Z
tasks/__init__.py
ssfdust/smorest-sfs
139f6817989ab041c81761d183169de20a26597e
[ "Apache-2.0" ]
null
null
null
tasks/__init__.py
ssfdust/smorest-sfs
139f6817989ab041c81761d183169de20a26597e
[ "Apache-2.0" ]
2
2020-05-11T03:53:38.000Z
2021-03-25T01:11:15.000Z
# encoding: utf-8 # pylint: disable=invalid-name,wrong-import-position """ 本项目Invoke Task的入口 基本上是frol/flask-restplus-server-example的一个翻版, 很多都是沿用的frol的配置,然后做了优化与汉化。 出处:https://github.com/frol/flask-restplus-server-example """ import os import platform from invoke import Collection from invoke.executor import Executor...
22.302326
88
0.68196
366a799ddfcc2bf8bb387e248143f17a87bbf047
9,655
py
Python
pypy/jit/tool/traceviewer.py
benoitc/pypy
a3e1b12d1d01dc29056b7badc051ffc034297658
[ "MIT" ]
1
2020-01-21T11:10:51.000Z
2020-01-21T11:10:51.000Z
pypy/jit/tool/traceviewer.py
benoitc/pypy
a3e1b12d1d01dc29056b7badc051ffc034297658
[ "MIT" ]
null
null
null
pypy/jit/tool/traceviewer.py
benoitc/pypy
a3e1b12d1d01dc29056b7badc051ffc034297658
[ "MIT" ]
null
null
null
#!/usr/bin/env python """ Usage: traceviewer.py [--use-threshold] loopfile """ import optparse import sys import re import math import py import autopath from pypy.translator.tool.graphpage import GraphPage from pypy.translator.tool.make_dot import DotGen from pypy.tool import logparser from pypy.tool import progress...
33.877193
83
0.567478
6f2a0109512e0716106e805c16b2fd3114fcfac7
2,681
py
Python
day04/day04.py
imrehg/AdventOfCode2020
6aa5bf122fdff33f2ff97b1652ecea7f3fbb679c
[ "MIT" ]
null
null
null
day04/day04.py
imrehg/AdventOfCode2020
6aa5bf122fdff33f2ff97b1652ecea7f3fbb679c
[ "MIT" ]
null
null
null
day04/day04.py
imrehg/AdventOfCode2020
6aa5bf122fdff33f2ff97b1652ecea7f3fbb679c
[ "MIT" ]
null
null
null
import sys import re required_fields = {"byr", "iyr", "eyr", "hgt", "hcl", "ecl", "pid"} def basic_validate(passports, required_fields): count = 0 for passport in passports: fields = set(passport.keys()) missing_required_fields = required_fields - fields count += 1 if not missing_requ...
26.284314
88
0.490862
ca156ef5783f48914def1592feaf5a7219aa8baf
1,972
py
Python
Rust/Hangperson/h04.py
lerina/drills
d7f374adec683a699c4dfd100985482e6717fda2
[ "MIT" ]
null
null
null
Rust/Hangperson/h04.py
lerina/drills
d7f374adec683a699c4dfd100985482e6717fda2
[ "MIT" ]
null
null
null
Rust/Hangperson/h04.py
lerina/drills
d7f374adec683a699c4dfd100985482e6717fda2
[ "MIT" ]
null
null
null
#Step 4 import random stages = [''' +---+ | | O | /|\ | / \ | | ========= ''', ''' +---+ | | O | /|\ | / | | ========= ''', ''' +---+ | | O | /|\ | | | ========= ''', ''' +---+ | | O | /| | | | =========''', ''' +---+ | |...
17.607143
122
0.49645
98eab368f575087ab5b51209fedc08e55ca61e58
837
py
Python
30_day_leetcoding_challenge/2021_09/30-Partition_to_K_Equal_Sum_Subsets.py
QuenLo/leecode
ce861103949510dc54fd5cb336bd992c40748de2
[ "MIT" ]
6
2018-06-13T06:48:42.000Z
2020-11-25T10:48:13.000Z
30_day_leetcoding_challenge/2021_09/30-Partition_to_K_Equal_Sum_Subsets.py
QuenLo/leecode
ce861103949510dc54fd5cb336bd992c40748de2
[ "MIT" ]
null
null
null
30_day_leetcoding_challenge/2021_09/30-Partition_to_K_Equal_Sum_Subsets.py
QuenLo/leecode
ce861103949510dc54fd5cb336bd992c40748de2
[ "MIT" ]
null
null
null
class Solution: def canPartitionKSubsets(self, nums: List[int], k: int) -> bool: total = sum(nums) if (total % k) > 0: return False sub_total = total // 4 visited = [False]*len(nums) nums = sorted(nums) return self.calling( nums, visited, 0,...
33.48
92
0.53644
d5a77f40a3cd7488e91f28933388bc257e634e1a
4,687
py
Python
ShoeStore/authen/forms.py
TrongPhuCBL49/Shoe-Store-Django
6dff4cf34783fe3504d06504a00022ccce06cb88
[ "bzip2-1.0.6" ]
null
null
null
ShoeStore/authen/forms.py
TrongPhuCBL49/Shoe-Store-Django
6dff4cf34783fe3504d06504a00022ccce06cb88
[ "bzip2-1.0.6" ]
null
null
null
ShoeStore/authen/forms.py
TrongPhuCBL49/Shoe-Store-Django
6dff4cf34783fe3504d06504a00022ccce06cb88
[ "bzip2-1.0.6" ]
null
null
null
from django import forms from django.forms import ModelForm from django.contrib.auth import get_user_model from .models import CustomerUser from django.utils.translation import gettext_lazy as _ from django.core.exceptions import NON_FIELD_ERRORS User = get_user_model() class LoginForm(forms.Form): username = fo...
30.633987
74
0.546192
089138ad89274d7bc2778c69157ced27ae8329f4
3,255
py
Python
pytorch_toolbelt/modules/agn.py
ternaus/pytorch-toolbelt
a952882bae1ded4f9a583cbdf87ba6f335ef3abf
[ "MIT" ]
3
2019-10-02T04:05:57.000Z
2020-01-13T02:26:09.000Z
pytorch_toolbelt/modules/agn.py
ternaus/pytorch-toolbelt
a952882bae1ded4f9a583cbdf87ba6f335ef3abf
[ "MIT" ]
null
null
null
pytorch_toolbelt/modules/agn.py
ternaus/pytorch-toolbelt
a952882bae1ded4f9a583cbdf87ba6f335ef3abf
[ "MIT" ]
1
2019-12-02T05:40:03.000Z
2019-12-02T05:40:03.000Z
import torch import torch.nn as nn import torch.nn.functional as functional from pytorch_toolbelt.modules.activations import ACT_LEAKY_RELU, ACT_NONE, \ ACT_HARD_SIGMOID, ACT_HARD_SWISH, ACT_SWISH, ACT_SELU, ACT_ELU, ACT_RELU6, \ ACT_RELU, hard_swish, hard_sigmoid, swish __all__ = ['AGN'] class AGN(nn.Module...
36.573034
87
0.603379
fa531f150f2d30304c34da181a2b2bdd277f8f39
5,446
py
Python
wrapper/gf.py
sniemi/SamPy
e048756feca67197cf5f995afd7d75d8286e017b
[ "BSD-2-Clause" ]
5
2016-05-28T14:12:28.000Z
2021-04-22T10:23:12.000Z
wrapper/gf.py
sniemi/SamPy
e048756feca67197cf5f995afd7d75d8286e017b
[ "BSD-2-Clause" ]
null
null
null
wrapper/gf.py
sniemi/SamPy
e048756feca67197cf5f995afd7d75d8286e017b
[ "BSD-2-Clause" ]
2
2015-07-13T10:04:10.000Z
2021-04-22T10:23:23.000Z
""" This little wrapper can be used to run GF (R. Somerville's SAMs program) using threading. :author: Sami-Matias Niemi :contact: niemi@stsci.edu :note: Threading is not really the best way to do this. Instead, one should use multiprocessing to launch several processes. """ import glob as g import os i...
32.035294
115
0.560779
092a144b7b05d6b74a74b7b4551e7dd59dbe7d13
2,295
py
Python
phantasy/tests/test_miscutils.py
archman/phantasy
ac362cd3a80f7d1cfc68c0722f8a4aad504d1edd
[ "BSD-3-Clause" ]
null
null
null
phantasy/tests/test_miscutils.py
archman/phantasy
ac362cd3a80f7d1cfc68c0722f8a4aad504d1edd
[ "BSD-3-Clause" ]
1
2017-07-11T12:30:58.000Z
2018-01-04T19:39:59.000Z
phantasy/tests/test_miscutils.py
archman/phantasy
ac362cd3a80f7d1cfc68c0722f8a4aad504d1edd
[ "BSD-3-Clause" ]
1
2018-09-27T17:03:32.000Z
2018-09-27T17:03:32.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- """ Unittest for miscutils module :author: Tong Zhang <zhangt@frib.msu.edu> :date: 2016-11-22 11:52:21 AM EST """ import unittest import numpy as np from phantasy.library.misc import miscutils import os curdir = os.path.abspath(os.path.dirname(__file__)) class TestMisc...
27
67
0.525926
ba0685f4f2ec8ce113818b63f2b2d5e92653ab63
19,368
py
Python
utils.py
Neukiru/spell-checkr
6a3892d9d8a0268005d3f82c288e460fbb15f035
[ "MIT" ]
null
null
null
utils.py
Neukiru/spell-checkr
6a3892d9d8a0268005d3f82c288e460fbb15f035
[ "MIT" ]
null
null
null
utils.py
Neukiru/spell-checkr
6a3892d9d8a0268005d3f82c288e460fbb15f035
[ "MIT" ]
null
null
null
import re import io import os import regex as re from itertools import islice import numpy as np from keras.models import Model, load_model from keras.layers import Input from model import truncated_acc, truncated_loss np.random.seed(1234) SOS = '\t' # start of sequence. EOS = '*' # end of sequence. CHARS = list('...
40.947146
135
0.62562
c66d0b1d0d2b245e6f10b5df4f61336b26f1d1dc
5,402
py
Python
src/dashboard/app_animation.py
drblahdblah/covid-19-analysis
abd6ed23a49bd1277708163cad0741c5b9f9698a
[ "MIT" ]
3
2020-04-20T11:10:23.000Z
2020-04-22T08:06:04.000Z
src/dashboard/app_animation.py
drblahdblah/covid-19-analysis
abd6ed23a49bd1277708163cad0741c5b9f9698a
[ "MIT" ]
null
null
null
src/dashboard/app_animation.py
drblahdblah/covid-19-analysis
abd6ed23a49bd1277708163cad0741c5b9f9698a
[ "MIT" ]
null
null
null
import plotly.graph_objects as go from datetime import datetime import pandas as pd pd.set_option("display.max_columns", 500) pd.set_option("display.max_rows", 1000) pd.set_option("display.width", 1000) url = "https://raw.githubusercontent.com/plotly/datasets/master/gapminderDataFiveYear.csv" dataset = pd.read_csv(u...
30.178771
92
0.501851
5178ca2dd39c4543a89f3c0d8d72afd987d5ad22
10,618
py
Python
graphslam/pose/se2.py
Golbstein/python-graphslam
cccc022b2f5d797f6511bda9e7dd3a24af403016
[ "MIT" ]
97
2020-02-24T00:34:56.000Z
2022-03-23T11:43:19.000Z
graphslam/pose/se2.py
Golbstein/python-graphslam
cccc022b2f5d797f6511bda9e7dd3a24af403016
[ "MIT" ]
3
2020-02-18T15:46:40.000Z
2022-03-17T02:01:51.000Z
graphslam/pose/se2.py
Golbstein/python-graphslam
cccc022b2f5d797f6511bda9e7dd3a24af403016
[ "MIT" ]
13
2020-06-09T08:27:27.000Z
2021-11-23T14:05:14.000Z
# Copyright (c) 2020 Jeff Irion and contributors r"""Representation of a pose in :math:`SE(2)`. """ import math import numpy as np from .base_pose import BasePose from ..util import neg_pi_to_pi class PoseSE2(BasePose): r"""A representation of a pose in :math:`SE(2)`. Parameters ---------- posi...
32.07855
224
0.437559
6a48cbd9786f026192a575a75f3b5e933e8faeae
110,112
py
Python
python/ray/data/dataset.py
spillai/ray
8b4cb45088a170e37d7d92c2e8a3dacddf67e1bc
[ "Apache-2.0" ]
1
2021-09-20T15:47:07.000Z
2021-09-20T15:47:07.000Z
python/ray/data/dataset.py
spillai/ray
8b4cb45088a170e37d7d92c2e8a3dacddf67e1bc
[ "Apache-2.0" ]
52
2021-06-12T07:06:44.000Z
2022-03-26T07:09:10.000Z
python/ray/data/dataset.py
spillai/ray
8b4cb45088a170e37d7d92c2e8a3dacddf67e1bc
[ "Apache-2.0" ]
null
null
null
import logging import time from typing import List, Any, Callable, Iterator, Iterable, Generic, \ Dict, Optional, Union, TYPE_CHECKING, Tuple from uuid import uuid4 if TYPE_CHECKING: import pyarrow import pandas import mars import modin import dask import pyspark import ray.util.sgd ...
40.964286
100
0.572308
b3e830905ac98e64a2097d47f31529f05cdea50f
1,772
py
Python
preprocess.py
Dumbledore-on-Strive/goodreads
0de57174de4ee88399e71c4061d3dec3dd6480ae
[ "MIT" ]
null
null
null
preprocess.py
Dumbledore-on-Strive/goodreads
0de57174de4ee88399e71c4061d3dec3dd6480ae
[ "MIT" ]
null
null
null
preprocess.py
Dumbledore-on-Strive/goodreads
0de57174de4ee88399e71c4061d3dec3dd6480ae
[ "MIT" ]
2
2021-04-13T07:57:57.000Z
2021-04-14T16:39:00.000Z
import pandas as pd import numpy as np from sklearn.preprocessing import MinMaxScaler df = pd.read_csv("testing.csv") df.columns df = df.drop(['Unnamed: 0', 'place', 'url'], axis=1) df = df.dropna() df['num_pages'] = pd.to_numeric(df['num_pages'], downcast='integer') df.head() # Step 1: find min(avg_rating) minValue...
20.604651
86
0.638826
460f379ce9164b30f2cda4beffdc1a65bec47df0
14,494
py
Python
test/test_librosa_compatibility.py
f0k/audio
b457cb711a9a849b1226ede93ae247cd1e06eddf
[ "BSD-2-Clause" ]
2
2021-03-13T08:24:36.000Z
2021-05-06T15:50:00.000Z
test/test_librosa_compatibility.py
f0k/audio
b457cb711a9a849b1226ede93ae247cd1e06eddf
[ "BSD-2-Clause" ]
null
null
null
test/test_librosa_compatibility.py
f0k/audio
b457cb711a9a849b1226ede93ae247cd1e06eddf
[ "BSD-2-Clause" ]
1
2021-08-03T20:41:15.000Z
2021-08-03T20:41:15.000Z
"""Test suites for numerical compatibility with librosa""" import os import unittest import torch import torchaudio import torchaudio.functional as F from torchaudio.common_utils import IMPORT_LIBROSA if IMPORT_LIBROSA: import numpy as np import librosa import scipy import pytest import common_utils c...
41.411429
118
0.647854
71c23fb66112c537460c6b6d208dbe089a22542d
3,582
py
Python
opentmi_client/api/event/Event.py
OpenTMI/opentmi-pyclient
034c539d36fe13a2d6538ea421e4c01f00f5687d
[ "MIT" ]
null
null
null
opentmi_client/api/event/Event.py
OpenTMI/opentmi-pyclient
034c539d36fe13a2d6538ea421e4c01f00f5687d
[ "MIT" ]
36
2018-06-18T10:03:58.000Z
2022-03-30T00:16:31.000Z
opentmi_client/api/event/Event.py
OpenTMI/opentmi-pyclient
034c539d36fe13a2d6538ea421e4c01f00f5687d
[ "MIT" ]
1
2019-04-17T08:49:24.000Z
2019-04-17T08:49:24.000Z
""" OpenTMI module for Event """ from opentmi_client.utils.Base import BaseApi from opentmi_client.utils.decorators import setter_rules from opentmi_client.api.event.Priority import Priority from opentmi_client.api.event.Ref import Ref class Event(BaseApi): """ Event Class """ def __init__(self): ...
20.011173
67
0.507259
0b56825f95d65b1e0278a1819cae0c9fe7baee3b
76
py
Python
test/really_simple_test.py
Ark-kun/strip-hints
aa2e217506f16999872439b03aaadf9a517e7389
[ "MIT" ]
29
2017-09-29T15:51:51.000Z
2022-03-18T16:47:04.000Z
test/really_simple_test.py
Ark-kun/strip-hints
aa2e217506f16999872439b03aaadf9a517e7389
[ "MIT" ]
16
2018-06-18T19:54:36.000Z
2021-12-04T01:37:52.000Z
test/really_simple_test.py
Ark-kun/strip-hints
aa2e217506f16999872439b03aaadf9a517e7389
[ "MIT" ]
4
2019-06-17T19:32:50.000Z
2022-02-08T13:11:52.000Z
def simp(x, y) -> int \ : def q(x: int=4): z: list=[3]
8.444444
23
0.355263
a4f27e0d4290ba6755a747beb08abc3695fc25e9
15,385
py
Python
wtServer.py
jimboca/udi-WirelessSensorTags-poly
0232c5df5b957b7675141965ebb732aa745a5dd5
[ "MIT" ]
null
null
null
wtServer.py
jimboca/udi-WirelessSensorTags-poly
0232c5df5b957b7675141965ebb732aa745a5dd5
[ "MIT" ]
25
2022-02-13T17:00:59.000Z
2022-03-22T14:22:48.000Z
wtServer.py
jimboca/udi-WirelessSensorTags-poly
0232c5df5b957b7675141965ebb732aa745a5dd5
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 """ Simple GET handler with BaseHTTPServer """ from http.server import HTTPServer,BaseHTTPRequestHandler from urllib import parse from urllib.parse import parse_qsl import socket, threading, sys, requests, json, time import netifaces as ni class wtHandler(BaseHTTPRequestHandler): def do...
38.4625
119
0.578941
d73a51efc45fefc2e09c5662c7c6238c54372085
2,632
py
Python
experiments/shakespeare_experiments/shakespeare_fedavg_hs.py
M4rukku/impact_of_non_iid_data_in_federated_learning
c818db03699c82e42217d56f8ddd4cc2081c8bb1
[ "MIT" ]
null
null
null
experiments/shakespeare_experiments/shakespeare_fedavg_hs.py
M4rukku/impact_of_non_iid_data_in_federated_learning
c818db03699c82e42217d56f8ddd4cc2081c8bb1
[ "MIT" ]
null
null
null
experiments/shakespeare_experiments/shakespeare_fedavg_hs.py
M4rukku/impact_of_non_iid_data_in_federated_learning
c818db03699c82e42217d56f8ddd4cc2081c8bb1
[ "MIT" ]
null
null
null
import functools import math from pathlib import Path from sources.simulators.serial_execution_simulator import \ SerialExecutionSimulator from experiments.shakespeare_experiments.shakespeare_metadata_providers import \ SHAKESPEARE_BASE_METADATA_HYPERPARAMETER_SEARCH_PROVIDER from sources.datasets.shakespeare...
37.070423
96
0.789894
6b8466ed14255cedad0298cdedffb7eec0da4db7
2,416
py
Python
test.py
ygs1985ygs/pyalgotrade3
5481c214891b7bd8ca76fee4e3f5cfcbb9f9de4e
[ "Apache-2.0" ]
23
2017-06-07T04:36:38.000Z
2021-11-09T10:39:54.000Z
test.py
ygs1985ygs/pyalgotrade3
5481c214891b7bd8ca76fee4e3f5cfcbb9f9de4e
[ "Apache-2.0" ]
1
2018-03-29T16:25:54.000Z
2018-03-29T16:25:54.000Z
test.py
ygs1985ygs/pyalgotrade3
5481c214891b7bd8ca76fee4e3f5cfcbb9f9de4e
[ "Apache-2.0" ]
12
2017-03-29T08:35:32.000Z
2020-02-08T04:01:03.000Z
from pyalgotrade import strategy from pyalgotrade.barfeed import yahoofeed from pyalgotrade.technical import ma class MyStrategy(strategy.BacktestingStrategy): def __init__(self, feed, instrument, smaPeriod): super(MyStrategy, self).__init__(feed, 1000) self.__position = None self.__instru...
38.967742
183
0.662252
afaf2ff40dc4ae1f06e92e447db61ea01724ac36
6,183
py
Python
tests/contrib/hooks/test_azure_container_instance_hook.py
FlyrInc/airflow-1
74b22337b45a1eb25585d52e35694e6b0eb81f03
[ "Apache-2.0" ]
2
2019-01-26T06:04:11.000Z
2019-01-26T12:54:21.000Z
tests/contrib/hooks/test_azure_container_instance_hook.py
FlyrInc/airflow-1
74b22337b45a1eb25585d52e35694e6b0eb81f03
[ "Apache-2.0" ]
6
2020-07-07T20:21:26.000Z
2021-09-29T17:29:29.000Z
tests/contrib/hooks/test_azure_container_instance_hook.py
FlyrInc/airflow-1
74b22337b45a1eb25585d52e35694e6b0eb81f03
[ "Apache-2.0" ]
2
2020-04-24T10:51:17.000Z
2020-05-26T01:50:29.000Z
# -*- coding: utf-8 -*- # # Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the #...
49.464
102
0.652434
ad466882c542ecefeda831dfda72cf230172ee42
65
py
Python
pychord/constants/__init__.py
hejops/pychord
ae5d0585c5df95c98517c1fb5351b8b2815c8b8c
[ "MIT" ]
1
2021-10-08T00:18:38.000Z
2021-10-08T00:18:38.000Z
pychord/constants/__init__.py
hejops/pychord
ae5d0585c5df95c98517c1fb5351b8b2815c8b8c
[ "MIT" ]
null
null
null
pychord/constants/__init__.py
hejops/pychord
ae5d0585c5df95c98517c1fb5351b8b2815c8b8c
[ "MIT" ]
null
null
null
from .scales import NOTE_VAL_DICT, VAL_NOTE_DICT, SCALE_VAL_DICT
32.5
64
0.861538
3fee8f27ad05c3a2477364cdf051b81be65e05f7
3,177
py
Python
src/primaires/joueur/masques/encodage/__init__.py
stormi/tsunami
bdc853229834b52b2ee8ed54a3161a1a3133d926
[ "BSD-3-Clause" ]
null
null
null
src/primaires/joueur/masques/encodage/__init__.py
stormi/tsunami
bdc853229834b52b2ee8ed54a3161a1a3133d926
[ "BSD-3-Clause" ]
null
null
null
src/primaires/joueur/masques/encodage/__init__.py
stormi/tsunami
bdc853229834b52b2ee8ed54a3161a1a3133d926
[ "BSD-3-Clause" ]
null
null
null
# -*-coding:Utf-8 -* # Copyright (c) 2010 LE GOFF Vincent # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # # * Redistributions of source code must retain the above copyright notice, this # l...
38.743902
79
0.696569
d42f95971fc1011f089b30b114160d78763e0e10
5,627
py
Python
hs_geographic_feature_resource/forms.py
hydroshare/hydroshare
bf9888bbe61507aff070b1dfcec2fdec1921468d
[ "BSD-3-Clause" ]
178
2015-01-08T23:03:36.000Z
2022-03-03T13:56:45.000Z
hs_geographic_feature_resource/forms.py
hydroshare/hydroshare
bf9888bbe61507aff070b1dfcec2fdec1921468d
[ "BSD-3-Clause" ]
4,125
2015-01-01T14:26:15.000Z
2022-03-31T16:38:55.000Z
hs_geographic_feature_resource/forms.py
hydroshare/hydroshare
bf9888bbe61507aff070b1dfcec2fdec1921468d
[ "BSD-3-Clause" ]
53
2015-03-15T17:56:51.000Z
2022-03-17T00:32:16.000Z
from django import forms from crispy_forms.layout import Layout from hs_core.forms import BaseFormHelper, get_crispy_form_fields class OriginalCoverageFormHelper(BaseFormHelper): def __init__(self, allow_edit=True, res_short_id=None, element_id=None, element_name=None, *args, **kwargs): #...
48.508621
98
0.638884
53c4f4ceb71c01a3fdf458233c57b5b7ba00823f
7,027
py
Python
src/GrainGenerator_noInterseptions.py
dkagramanyan/dkagramanyan-WC-Co_computer_vision
74eece7ded37d33ff6cb38cf50d1c99ea27d7468
[ "MIT" ]
null
null
null
src/GrainGenerator_noInterseptions.py
dkagramanyan/dkagramanyan-WC-Co_computer_vision
74eece7ded37d33ff6cb38cf50d1c99ea27d7468
[ "MIT" ]
null
null
null
src/GrainGenerator_noInterseptions.py
dkagramanyan/dkagramanyan-WC-Co_computer_vision
74eece7ded37d33ff6cb38cf50d1c99ea27d7468
[ "MIT" ]
null
null
null
import bpy from random import random from mathutils import Vector, Euler import math #единицы измерения - метры #checks if 2 cubes are intersepting using their coordinates and rotations def ifIntersept(loc1, loc2, rot1, rot2, size): #creates a list of coordinates of every vertice coord_list_1 = [] coord_...
34.787129
132
0.59556
985e5025870be87e21427b8e8be741ea2078eb6e
3,916
py
Python
recipes/h5pp/all/conanfile.py
dyndrite/conan-center-index
106b5c2f532d5129e7ca1997e29e4e105bb3018c
[ "MIT" ]
null
null
null
recipes/h5pp/all/conanfile.py
dyndrite/conan-center-index
106b5c2f532d5129e7ca1997e29e4e105bb3018c
[ "MIT" ]
null
null
null
recipes/h5pp/all/conanfile.py
dyndrite/conan-center-index
106b5c2f532d5129e7ca1997e29e4e105bb3018c
[ "MIT" ]
null
null
null
from conan.tools.microsoft import is_msvc from conans import ConanFile, tools from conans.errors import ConanInvalidConfiguration import os required_conan_version = ">=1.45.0" class H5ppConan(ConanFile): name = "h5pp" description = "A C++17 wrapper for HDF5 with focus on simplicity" url = "https://github...
46.070588
125
0.658069
0216067a03dfff688458571df3f4aec893a04b4c
209
py
Python
totall/totall/doctype/caja/test_caja.py
dacosta2213/totall
c64420bb8d35ccf423fe8ea66321b34431f79660
[ "MIT" ]
null
null
null
totall/totall/doctype/caja/test_caja.py
dacosta2213/totall
c64420bb8d35ccf423fe8ea66321b34431f79660
[ "MIT" ]
null
null
null
totall/totall/doctype/caja/test_caja.py
dacosta2213/totall
c64420bb8d35ccf423fe8ea66321b34431f79660
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright (c) 2017, C0D1G0 B1NAR10 and Contributors # See license.txt from __future__ import unicode_literals import frappe import unittest class TestCaja(unittest.TestCase): pass
19
53
0.76555
0952b004ec00f1f61b90453daa249ca61209696e
264,328
py
Python
lib/GUI/ScrolledPanels/Management.py
Connor22/hydrus
d0ae4a8898742a0d13601e1167d5ba697b31c395
[ "WTFPL" ]
null
null
null
lib/GUI/ScrolledPanels/Management.py
Connor22/hydrus
d0ae4a8898742a0d13601e1167d5ba697b31c395
[ "WTFPL" ]
null
null
null
lib/GUI/ScrolledPanels/Management.py
Connor22/hydrus
d0ae4a8898742a0d13601e1167d5ba697b31c395
[ "WTFPL" ]
null
null
null
from . import ClientCaches from . import ClientConstants as CC from . import ClientData from . import ClientDefaults from . import ClientDownloading from . import ClientGUIACDropdown from . import ClientGUICommon from . import ClientGUIControls from . import ClientGUIDialogs from . import ClientGUIDialogsQuick from . i...
45.184274
536
0.555526
4b5c4d092833d03034b30338774f18b90ce1f956
3,592
py
Python
data_handler/LLD.py
demetoir/ALLGANS
2f972db5e9a65f18aee0695d817f4acc221e54da
[ "MIT" ]
11
2018-01-25T15:31:54.000Z
2019-12-17T06:12:57.000Z
data_handler/LLD.py
demetoir/ALLGANs
2f972db5e9a65f18aee0695d817f4acc221e54da
[ "MIT" ]
19
2018-01-29T16:12:09.000Z
2018-02-15T15:56:48.000Z
data_handler/LLD.py
demetoir/ALLGANs
2f972db5e9a65f18aee0695d817f4acc221e54da
[ "MIT" ]
2
2018-02-06T00:31:55.000Z
2018-02-19T15:29:10.000Z
from __future__ import division from glob import glob from PIL import Image from data_handler.AbstractDataset import AbstractDataset, DownloadInfo, AbstractDatasetHelper from dict_keys.dataset_batch_keys import * from env_settting import LLD_PATH from dict_keys.input_shape_keys import * import _pickle as cPickle...
34.873786
121
0.583241
4f1e69a286802c88a746ec1fc519c38b59bb6b16
2,363
py
Python
basic/list2.py
tyagow/google-python-exercises
7036293c5f2b1740ce646b300267b71e6d3d642a
[ "Apache-2.0" ]
1
2019-07-05T12:24:15.000Z
2019-07-05T12:24:15.000Z
basic/list2.py
tyagow/google-python-exercises
7036293c5f2b1740ce646b300267b71e6d3d642a
[ "Apache-2.0" ]
null
null
null
basic/list2.py
tyagow/google-python-exercises
7036293c5f2b1740ce646b300267b71e6d3d642a
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/python -tt # Copyright 2010 Google Inc. # Licensed under the Apache License, Version 2.0 # http://www.apache.org/licenses/LICENSE-2.0 # Google's Python Class # http://code.google.com/edu/languages/google-python-class/ # Additional basic list exercises # D. Given a list of numbers, return a list where # a...
32.819444
79
0.646212
03427b2e5d016a10246c195dbab951874618b4aa
2,177
py
Python
twint/storage/write.py
recurrence/twint
c434115d21fd244f8fcfd987ae048a1a4fac6f74
[ "MIT" ]
null
null
null
twint/storage/write.py
recurrence/twint
c434115d21fd244f8fcfd987ae048a1a4fac6f74
[ "MIT" ]
null
null
null
twint/storage/write.py
recurrence/twint
c434115d21fd244f8fcfd987ae048a1a4fac6f74
[ "MIT" ]
null
null
null
from . import write_meta as meta import csv import json import os def outputExt(objType, fType): if objType == "str": objType = "username" outExt = f"/{objType}s.{fType}" return outExt def addExt(base, objType, fType): if len(base.split('.')) == 1: createDirIfMissing(base) bas...
27.910256
85
0.625172
7bfc51bceb2edf6f217cb2066adea045231daf11
5,738
py
Python
PythonAPI/carissma_project/lib/python3.5/site-packages/matplotlib/backends/backend_mixed.py
AbdulHoffmann/carla_carissma
8d382769ffa02a6c61a22c57160285505f5ff0a4
[ "MIT" ]
445
2019-01-26T13:50:26.000Z
2022-03-18T05:17:38.000Z
venv/lib/python3.7/site-packages/matplotlib/backends/backend_mixed.py
John1001Song/Big-Data-Robo-Adviser
9444dce96954c546333d5aecc92a06c3bfd19aa5
[ "MIT" ]
242
2019-01-29T15:48:27.000Z
2022-03-31T22:09:21.000Z
venv/lib/python3.7/site-packages/matplotlib/backends/backend_mixed.py
John1001Song/Big-Data-Robo-Adviser
9444dce96954c546333d5aecc92a06c3bfd19aa5
[ "MIT" ]
64
2018-04-25T08:51:57.000Z
2022-01-29T14:13:57.000Z
import numpy as np from matplotlib.backends.backend_agg import RendererAgg from matplotlib.tight_bbox import process_figure_for_rasterizing class MixedModeRenderer(object): """ A helper class to implement a renderer that switches between vector and raster drawing. An example may be a PDF writer, where ...
38
79
0.623736
98436138ed4e5cd91b990b7c928fa465393531af
863
py
Python
p_library/admin.py
StalingradTeam/my_library
ec9f43acb548a1552c8f64785d3a040390e91ae1
[ "MIT" ]
null
null
null
p_library/admin.py
StalingradTeam/my_library
ec9f43acb548a1552c8f64785d3a040390e91ae1
[ "MIT" ]
null
null
null
p_library/admin.py
StalingradTeam/my_library
ec9f43acb548a1552c8f64785d3a040390e91ae1
[ "MIT" ]
null
null
null
from django.contrib import admin # Register your models here. from django.contrib import admin from p_library.models import Book, Author, Publisher @admin.register(Author) class BookAdmin(admin.ModelAdmin): fields = ('full_name', 'birth_year', 'country', ) @staticmethod def author_full_name(...
25.382353
110
0.677868
9a24a278b13ec83fa9bdba924f62afa00a9dd766
11,478
py
Python
waveorder/io/multipagetiff.py
mehta-lab/waveorder
9892c20955d3487778fd440a0d7f4f86334e7b8e
[ "Unlicense" ]
2
2020-12-19T02:55:09.000Z
2022-02-24T19:40:26.000Z
waveorder/io/multipagetiff.py
mehta-lab/waveorder
9892c20955d3487778fd440a0d7f4f86334e7b8e
[ "Unlicense" ]
42
2021-01-20T22:34:14.000Z
2022-03-31T00:13:37.000Z
waveorder/io/multipagetiff.py
mehta-lab/waveorder
9892c20955d3487778fd440a0d7f4f86334e7b8e
[ "Unlicense" ]
null
null
null
import numpy as np import os import zarr from tifffile import TiffFile import tifffile as tiff from copy import copy import glob import warnings from waveorder.io.reader_interface import ReaderInterface class MicromanagerOmeTiffReader(ReaderInterface): def __init__(self, folder: str, extract_data: bool = False):...
30.205263
112
0.533368
d3dde661949bde9817a393e00bab0a0cf7acfe41
779
py
Python
cws/node.py
mattianeroni/clarke-wright-savings
b418bfbef060f662b09f73b70b8a5e7d03612bc2
[ "MIT" ]
1
2022-03-31T07:16:14.000Z
2022-03-31T07:16:14.000Z
cws/node.py
mattianeroni/clarke-wright-savings
b418bfbef060f662b09f73b70b8a5e7d03612bc2
[ "MIT" ]
null
null
null
cws/node.py
mattianeroni/clarke-wright-savings
b418bfbef060f662b09f73b70b8a5e7d03612bc2
[ "MIT" ]
null
null
null
import abc class Node (abc.ABC): """ The class that inherits from this one inherits all the attributes and methods needed to work as an Node of the graph on which the Clarke Wright Savings heuristic is going to be computed. """ def __init__(self, id, dn_edge, nd_edge): """ ...
26.862069
72
0.599487
5d720a24663bfe1abbe39f12e5e54e0d8cbcf606
261
py
Python
pibackbone/__init__.py
anarkiwi/pibackbone
8677da0a7fb93fe86cd4459b0ad8ce3c5d5af90f
[ "Apache-2.0" ]
null
null
null
pibackbone/__init__.py
anarkiwi/pibackbone
8677da0a7fb93fe86cd4459b0ad8ce3c5d5af90f
[ "Apache-2.0" ]
29
2022-03-22T20:20:50.000Z
2022-03-31T23:12:51.000Z
pibackbone/__init__.py
anarkiwi/pibackbone
8677da0a7fb93fe86cd4459b0ad8ce3c5d5af90f
[ "Apache-2.0" ]
2
2022-03-22T16:24:59.000Z
2022-03-31T20:25:27.000Z
import pkg_resources from pbr.version import VersionInfo pkg_resources.declare_namespace(__name__) # TODO: 3.8+ and later, use importlib: https://pypi.org/project/importlib-metadata/ __version__ = VersionInfo('pibackbone').semantic_version().release_string()
32.625
83
0.812261
edd5f00d3d06e4d8d3b626fd9279d39c271e964c
10,881
py
Python
mmdet3d/core/bbox/structures/coord_3d_mode.py
gopi231091/mmdetection3d
1b2e64cd75c8d1c238c61a3bc1e3c62a7d403b53
[ "Apache-2.0" ]
217
2021-12-10T09:44:33.000Z
2022-03-31T16:17:35.000Z
mmdet3d/core/bbox/structures/coord_3d_mode.py
gopi231091/mmdetection3d
1b2e64cd75c8d1c238c61a3bc1e3c62a7d403b53
[ "Apache-2.0" ]
22
2021-12-29T08:57:31.000Z
2022-03-31T11:21:53.000Z
mmdet3d/core/bbox/structures/coord_3d_mode.py
gopi231091/mmdetection3d
1b2e64cd75c8d1c238c61a3bc1e3c62a7d403b53
[ "Apache-2.0" ]
23
2021-12-13T06:56:38.000Z
2022-03-28T02:02:13.000Z
import numpy as np import torch from enum import IntEnum, unique from mmdet3d.core.points import (BasePoints, CameraPoints, DepthPoints, LiDARPoints) from .base_box3d import BaseInstance3DBoxes from .cam_box3d import CameraInstance3DBoxes from .depth_box3d import DepthInstance3DBoxes f...
38.72242
79
0.531201
6a93f9fa560ce7397320678a35a7325cfd3731dd
362
py
Python
unittests/__init__.py
xinranduan/mpc-forest
e93bee948daeda80d956df210b2057db41698ac9
[ "BSD-3-Clause" ]
null
null
null
unittests/__init__.py
xinranduan/mpc-forest
e93bee948daeda80d956df210b2057db41698ac9
[ "BSD-3-Clause" ]
null
null
null
unittests/__init__.py
xinranduan/mpc-forest
e93bee948daeda80d956df210b2057db41698ac9
[ "BSD-3-Clause" ]
null
null
null
""" Copyright (c) 2017 Eric Shook. All rights reserved. Use of this source code is governed by a BSD-style license that can be found in the LICENSE file. @author: eshook (Eric Shook, eshook@gmail.edu) @contributors: <Contribute and add your name here!> """ # Import unittests from .test_Bob import * from .test_Bobs imp...
32.909091
97
0.759669
56145a865723ea952cb0e4370da40229117d4716
11,607
py
Python
magenta/models/performance_rnn/performance_rnn_generate.py
fanzhiyan/magenta
622c47c19bb84c6f57b286ed03b738516b2f27d6
[ "Apache-2.0" ]
16
2016-09-02T04:59:30.000Z
2022-01-11T10:38:29.000Z
magenta/models/performance_rnn/performance_rnn_generate.py
fanzhiyan/magenta
622c47c19bb84c6f57b286ed03b738516b2f27d6
[ "Apache-2.0" ]
2
2016-09-25T16:39:59.000Z
2016-11-18T17:43:41.000Z
magenta/models/performance_rnn/performance_rnn_generate.py
fanzhiyan/magenta
622c47c19bb84c6f57b286ed03b738516b2f27d6
[ "Apache-2.0" ]
10
2016-09-02T04:59:32.000Z
2021-09-29T06:57:24.000Z
# Copyright 2019 The Magenta 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 ...
39.479592
80
0.740329
fd481f2c805f7187ebc0b5e0ca4c28fa8d5ca5f9
13,343
py
Python
processes.py
GNUBrinux/pilot
18d0ef3ea9822df7877fbe39b191f56a6288ada5
[ "Apache-2.0" ]
13
2015-02-19T17:17:10.000Z
2021-12-22T06:48:02.000Z
processes.py
GNUBrinux/pilot
18d0ef3ea9822df7877fbe39b191f56a6288ada5
[ "Apache-2.0" ]
85
2015-01-06T15:01:51.000Z
2018-11-29T09:03:35.000Z
processes.py
GNUBrinux/pilot
18d0ef3ea9822df7877fbe39b191f56a6288ada5
[ "Apache-2.0" ]
22
2015-06-09T12:08:29.000Z
2018-11-20T10:07:01.000Z
import commands import os import signal import time import re import pUtil def findProcessesInGroup(cpids, pid): """ recursively search for the children processes belonging to pid and return their pids here pid is the parent pid for all the children to be found cpids is a list that has to be initialized be...
36.159892
187
0.548452
d0229a51c8b27cbf4a71fbf5779655d0d139d539
32,451
py
Python
lib/flows/general/collectors.py
scudette/grr
d4257c5259af881e28a7d62e9837fa13352e2bf6
[ "Apache-2.0" ]
6
2015-04-03T02:25:28.000Z
2021-11-17T21:42:59.000Z
lib/flows/general/collectors.py
scudette/grr
d4257c5259af881e28a7d62e9837fa13352e2bf6
[ "Apache-2.0" ]
null
null
null
lib/flows/general/collectors.py
scudette/grr
d4257c5259af881e28a7d62e9837fa13352e2bf6
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python """Flows for handling the collection for artifacts.""" import logging from grr.lib import aff4 from grr.lib import artifact from grr.lib import artifact_lib from grr.lib import config_lib from grr.lib import flow from grr.lib import parsers from grr.lib import rdfvalue class ArtifactCollectorF...
40.921816
80
0.669286
38843947bb127403d90cd881f92aded85f9c6458
1,394
py
Python
renmin/renmin/pipelines.py
dumin199101/Scrapy-Project
b4135beb73a2c5aad1728f747c1856266af649dd
[ "Apache-2.0" ]
1
2019-07-11T03:28:25.000Z
2019-07-11T03:28:25.000Z
renmin/renmin/pipelines.py
dumin199101/Scrapy-Project
b4135beb73a2c5aad1728f747c1856266af649dd
[ "Apache-2.0" ]
null
null
null
renmin/renmin/pipelines.py
dumin199101/Scrapy-Project
b4135beb73a2c5aad1728f747c1856266af649dd
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Define your item pipelines here # # Don't forget to add your pipeline to the ITEM_PIPELINES setting # See: https://doc.scrapy.org/en/latest/topics/item-pipeline.html import codecs import json import pymysql class RenminPipeline(object): # 1.数据写入json文件 # def __init__(self): # ...
32.418605
119
0.609756
d1142e294c2da2f32fde9900f5b85be9ec93cfe4
1,576
py
Python
scripts/show_states.py
andrewjunyoung/symboard
51591c0aaac8b5394fde8d97470bf584437a3842
[ "MIT" ]
5
2020-02-09T21:56:26.000Z
2021-11-17T10:41:03.000Z
scripts/show_states.py
andrewjunyoung/symboard
51591c0aaac8b5394fde8d97470bf584437a3842
[ "MIT" ]
2
2020-03-24T18:11:14.000Z
2020-03-31T10:54:02.000Z
scripts/show_states.py
andrewjunyoung/symboard
51591c0aaac8b5394fde8d97470bf584437a3842
[ "MIT" ]
1
2021-11-27T14:02:01.000Z
2021-11-27T14:02:01.000Z
# Imports from third party packages. from argparse import ArgumentParser from tabulate import tabulate from typing import List import logging # Imports from the local package. from symboard.states import load_yaml def get_arg_parser() -> ArgumentParser: """ Returns: ArgumentParser: An ArgumentParser ...
26.711864
80
0.686548
fc462e14150472acf9ae11e4322cacb78c89baf2
10,835
py
Python
marketplaces/apps/market/migrations/0013_auto__add_field_marketsubcategory_image__add_field_marketcategory_imag.py
diassor/CollectorCity-Market-Place
892ad220b8cf1c0fc7433f625213fe61729522b2
[ "Apache-2.0" ]
135
2015-03-19T13:28:18.000Z
2022-03-27T06:41:42.000Z
marketplaces/apps/market/migrations/0013_auto__add_field_marketsubcategory_image__add_field_marketcategory_imag.py
dfcoding/CollectorCity-Market-Place
e59acec3d600c049323397b17cae14fdcaaaec07
[ "Apache-2.0" ]
null
null
null
marketplaces/apps/market/migrations/0013_auto__add_field_marketsubcategory_image__add_field_marketcategory_imag.py
dfcoding/CollectorCity-Market-Place
e59acec3d600c049323397b17cae14fdcaaaec07
[ "Apache-2.0" ]
83
2015-01-30T01:00:15.000Z
2022-03-08T17:25:10.000Z
# encoding: utf-8 import datetime from south.db import db from south.v2 import SchemaMigration from django.db import models class Migration(SchemaMigration): def forwards(self, orm): # Adding field 'MarketSubCategory.image' db.add_column('market_marketsubcategory', 'image', self.gf('core....
69.455128
181
0.563359
2a1b63f0a2a9a6e0c4058ada0a02adbf1ae1e953
957
py
Python
partnerships/forms.py
cforlando/intake
a5233d5c0f862f28ee265b9b4831405aabeec7e2
[ "MIT" ]
51
2016-07-20T02:26:57.000Z
2021-07-07T14:45:06.000Z
partnerships/forms.py
enterstudio/intake
793a8935914fdc8356321ec46e54d9ae1eeeee04
[ "MIT" ]
1,091
2016-04-29T18:07:45.000Z
2021-04-19T18:39:39.000Z
partnerships/forms.py
enterstudio/intake
793a8935914fdc8356321ec46e54d9ae1eeeee04
[ "MIT" ]
24
2016-06-14T18:10:43.000Z
2021-11-14T20:26:39.000Z
from django.forms import ModelForm, widgets from partnerships.models import PartnershipLead def with_classes(widget_class, *classes, **kwargs): attrs = kwargs.get('attrs', {}) class_ = attrs.get('class', '') class_ += ' '.join(classes) attrs.update({'class': class_}) kwargs.update({'attrs': attrs}...
33
70
0.600836
657e45fe30c9a949aee6ae7d09eb7bd7c4b7c70d
1,934
py
Python
saver.py
Kirkados/DeepCube
cc6b8d402a47ea0c7ecde8e4c5ed2d361c539ad5
[ "MIT" ]
3
2019-01-10T01:06:04.000Z
2021-10-31T18:19:50.000Z
saver.py
Kirkados/DeepCube
cc6b8d402a47ea0c7ecde8e4c5ed2d361c539ad5
[ "MIT" ]
null
null
null
saver.py
Kirkados/DeepCube
cc6b8d402a47ea0c7ecde8e4c5ed2d361c539ad5
[ "MIT" ]
null
null
null
""" This script saves and loads neural network parameters """ import os import tensorflow as tf from settings import Settings class Saver: def __init__(self, sess, filename): self.sess = sess self.filename = filename def save(self, n_iteration): # Save all the tensorflow...
40.291667
130
0.59152
11d430a65df017caf3e08db3c96ef3215a6e801a
11,736
py
Python
virtual/lib/python3.6/site-packages/astroid/arguments.py
edithamadi/pitch_one
40c8d1c67c77e483b29bd326721dde7f4a20120d
[ "Unlicense" ]
3
2018-10-21T14:01:01.000Z
2018-10-22T14:42:22.000Z
virtual/lib/python3.6/site-packages/astroid/arguments.py
edithamadi/pitch_one
40c8d1c67c77e483b29bd326721dde7f4a20120d
[ "Unlicense" ]
12
2018-10-03T19:45:36.000Z
2022-03-11T23:54:25.000Z
virtual/lib/python3.6/site-packages/astroid/arguments.py
edithamadi/pitch_one
40c8d1c67c77e483b29bd326721dde7f4a20120d
[ "Unlicense" ]
3
2020-01-19T21:26:14.000Z
2020-11-04T08:37:38.000Z
# Copyright (c) 2015-2016, 2018 Claudiu Popa <pcmanticore@gmail.com> # Copyright (c) 2015-2016 Ceridwen <ceridwenv@gmail.com> # Copyright (c) 2018 Bryce Guinta <bryce.paul.guinta@gmail.com> # Copyright (c) 2018 Nick Drozd <nicholasdrozd@gmail.com> # Copyright (c) 2018 Anthony Sottile <asottile@umich.edu> # Licensed un...
44.793893
85
0.565099
36d563f984bf57abb771f8be3c8694da44a53597
1,783
py
Python
wbia_pie_v2/losses/hard_mine_triplet_loss.py
dylanirion/wbia-plugin-pie-v2
8ae37c2ad218e5e888bb1aea039f1b04a3fe9d8d
[ "Apache-2.0" ]
null
null
null
wbia_pie_v2/losses/hard_mine_triplet_loss.py
dylanirion/wbia-plugin-pie-v2
8ae37c2ad218e5e888bb1aea039f1b04a3fe9d8d
[ "Apache-2.0" ]
null
null
null
wbia_pie_v2/losses/hard_mine_triplet_loss.py
dylanirion/wbia-plugin-pie-v2
8ae37c2ad218e5e888bb1aea039f1b04a3fe9d8d
[ "Apache-2.0" ]
1
2021-04-05T23:46:11.000Z
2021-04-05T23:46:11.000Z
# -*- coding: utf-8 -*- from __future__ import division, absolute_import import torch import torch.nn as nn class TripletLoss(nn.Module): """Triplet loss with hard positive/negative mining. Reference: Hermans et al. In Defense of the Triplet Loss for Person Re-Identification. arXiv:1703.07737. I...
35.66
101
0.626472
3d57792202f8057f39aa2a13fb39ca53efbb673b
366
py
Python
americas.py
4bic-attic/data_viz
db1ef07712d7deaccea6d5509d5a281a5484ac0b
[ "MIT" ]
null
null
null
americas.py
4bic-attic/data_viz
db1ef07712d7deaccea6d5509d5a281a5484ac0b
[ "MIT" ]
null
null
null
americas.py
4bic-attic/data_viz
db1ef07712d7deaccea6d5509d5a281a5484ac0b
[ "MIT" ]
null
null
null
import pygal from pygal.maps.world import World wm = World() wm.title = 'North, Central and South America' wm.add('North America', ['ca', 'mx', 'us']) wm.add('Cental America', ['bx', 'cr', 'gt', 'hn', 'ni', 'pa', 'sv']) wm.add('South America', ['ar', 'bo', 'br', 'cl', 'co', 'ec', 'gf', 'gy', 'pe', 'py', 'sr', '...
24.4
72
0.562842
76bb9ed328bc72991b306d0e4e0ebeaba1c7cb4f
3,655
py
Python
Scripts/simulation/drama_scheduler/club_gathering_drama_node.py
velocist/TS4CheatsInfo
b59ea7e5f4bd01d3b3bd7603843d525a9c179867
[ "Apache-2.0" ]
null
null
null
Scripts/simulation/drama_scheduler/club_gathering_drama_node.py
velocist/TS4CheatsInfo
b59ea7e5f4bd01d3b3bd7603843d525a9c179867
[ "Apache-2.0" ]
null
null
null
Scripts/simulation/drama_scheduler/club_gathering_drama_node.py
velocist/TS4CheatsInfo
b59ea7e5f4bd01d3b3bd7603843d525a9c179867
[ "Apache-2.0" ]
null
null
null
# uncompyle6 version 3.7.4 # Python bytecode 3.7 (3394) # Decompiled from: Python 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:58:18) [MSC v.1900 64 bit (AMD64)] # Embedded file name: T:\InGame\Gameplay\Scripts\Server\drama_scheduler\club_gathering_drama_node.py # Compiled at: 2020-02-07 22:50:40 # Size of source mod...
52.214286
132
0.697674
f8f83137f20a0abfac4233c1350174e3bc30dfeb
4,219
py
Python
ibmsecurity/isam/base/network/felb/attributes/advanced_tuning.py
mtrinh20/ibmsecurity
c084ac14322a03f582a31984ecfa9b4d6433f252
[ "Apache-2.0" ]
2
2019-12-05T13:51:10.000Z
2019-12-20T08:02:35.000Z
ibmsecurity/isam/base/network/felb/attributes/advanced_tuning.py
harshalchemate/ibmsecurity
e3dd3f930bcd9f151e30eff0a394c50f98d3eccb
[ "Apache-2.0" ]
null
null
null
ibmsecurity/isam/base/network/felb/attributes/advanced_tuning.py
harshalchemate/ibmsecurity
e3dd3f930bcd9f151e30eff0a394c50f98d3eccb
[ "Apache-2.0" ]
null
null
null
import logging from ibmsecurity.utilities import tools logger = logging.getLogger(__name__) module_uri = "/isam/felb/configuration/attributes" requires_modules = None requires_version = None def add(isamAppliance, name, value, check_mode=False, force=False): """ Creates attribute """ if force is Tr...
34.024194
117
0.624556
2def34c6b84cfe64dc6c7a5a2c3bda2a704467c2
3,642
py
Python
searchs/RealBestTeams.py
iamtrex/TeamGenerator
fbfadb4ed78efb26e0358443a08d38353c2d7392
[ "MIT" ]
1
2020-07-21T06:37:45.000Z
2020-07-21T06:37:45.000Z
searchs/RealBestTeams.py
iamtrex/TeamGenerator
fbfadb4ed78efb26e0358443a08d38353c2d7392
[ "MIT" ]
1
2020-07-21T06:43:07.000Z
2020-07-21T06:43:07.000Z
searchs/RealBestTeams.py
iamtrex/TeamGenerator
fbfadb4ed78efb26e0358443a08d38353c2d7392
[ "MIT" ]
null
null
null
from data import Const as C from model import TeamSet as TS, Team as T import itertools import time '''Class Def Player - Represents a Player with name, preferred roles, and rating at each role.''' def get_score(obj): return obj.score def calc_best_n_team_sets(n): # Track Time execution time_start = t...
33.722222
121
0.563152
3032b27d6768cd20ea4bc8270216bb29471113ce
2,896
py
Python
openmdao/test_suite/test_examples/beam_optimization/beam_group.py
naylor-b/blue
d7d7e8d63212c047a7a9b0625da98aa29ddc39b4
[ "Apache-2.0" ]
null
null
null
openmdao/test_suite/test_examples/beam_optimization/beam_group.py
naylor-b/blue
d7d7e8d63212c047a7a9b0625da98aa29ddc39b4
[ "Apache-2.0" ]
null
null
null
openmdao/test_suite/test_examples/beam_optimization/beam_group.py
naylor-b/blue
d7d7e8d63212c047a7a9b0625da98aa29ddc39b4
[ "Apache-2.0" ]
null
null
null
from __future__ import division import numpy as np import openmdao.api as om from openmdao.test_suite.test_examples.beam_optimization.components.moment_comp import MomentOfInertiaComp from openmdao.test_suite.test_examples.beam_optimization.components.local_stiffness_matrix_comp import LocalStiffnessMatrixComp from o...
39.135135
127
0.706492
23a3bae65bfa7b4b4888b40642f0506cc7173b75
1,097
py
Python
kubernetes/test/test_v2beta1_cross_version_object_reference.py
L3T/python
b6e4ae81a2afb49f668a142eb7d1c6e2571ef478
[ "Apache-2.0" ]
2
2020-06-21T08:03:18.000Z
2020-06-21T09:53:29.000Z
kubernetes/test/test_v2beta1_cross_version_object_reference.py
L3T/python
b6e4ae81a2afb49f668a142eb7d1c6e2571ef478
[ "Apache-2.0" ]
null
null
null
kubernetes/test/test_v2beta1_cross_version_object_reference.py
L3T/python
b6e4ae81a2afb49f668a142eb7d1c6e2571ef478
[ "Apache-2.0" ]
1
2020-12-10T07:28:08.000Z
2020-12-10T07:28:08.000Z
# coding: utf-8 """ Kubernetes No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 OpenAPI spec version: release-1.16 Generated by: https://openapi-generator.tech """ from __future__ import absolute_import import unittest import...
27.425
132
0.758432
66c51ba021842b8169287c7f5684d4f32bcea963
698
py
Python
Chapter03/mysite/blog/admin.py
HankSerg/Django-2-by-Example
15409eda3ba99e53fc4e8d53793398f924d3fefe
[ "MIT" ]
639
2018-05-31T22:28:21.000Z
2022-03-21T16:49:47.000Z
Chapter03/mysite/blog/admin.py
HankSerg/Django-2-by-Example
15409eda3ba99e53fc4e8d53793398f924d3fefe
[ "MIT" ]
43
2018-06-26T06:56:28.000Z
2022-03-31T18:32:57.000Z
Chapter03/mysite/blog/admin.py
HankSerg/Django-2-by-Example
15409eda3ba99e53fc4e8d53793398f924d3fefe
[ "MIT" ]
644
2018-06-10T22:37:24.000Z
2022-03-04T18:34:01.000Z
from django.contrib import admin from .models import Post, Comment @admin.register(Post) class PostAdmin(admin.ModelAdmin): list_display = ('title', 'slug', 'author', 'publish', 'status') list_filter = ('status', 'created', 'publish', 'author') search_fields = ('title', 'body') ...
31.727273
66
0.624642
bb8d7b8c63503b755b01ec4d6bd263ac17d97bc0
52,813
py
Python
eucaconsole/views/scalinggroups.py
gholms/eucaconsole
4629c961c90e3aae27e3a869a7f157bafeda6489
[ "BSD-2-Clause" ]
null
null
null
eucaconsole/views/scalinggroups.py
gholms/eucaconsole
4629c961c90e3aae27e3a869a7f157bafeda6489
[ "BSD-2-Clause" ]
null
null
null
eucaconsole/views/scalinggroups.py
gholms/eucaconsole
4629c961c90e3aae27e3a869a7f157bafeda6489
[ "BSD-2-Clause" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright 2013-2016 Hewlett Packard Enterprise Development LP # # Redistribution and use of this software in source and binary forms, # with or without modification, are permitted provided that the following # conditions are met: # # Redistributions of source code must retain the above copyrig...
49.823585
120
0.650143
d0bb662aa320551d72fe0100b8a030fc72b47934
2,701
py
Python
calm/fix-missing-src-hint.py
jon-turney/calm
a9db642904aa406f08dddb06798b576ec14949b8
[ "MIT" ]
5
2016-03-18T22:12:31.000Z
2022-02-02T16:01:52.000Z
calm/fix-missing-src-hint.py
jon-turney/calm
a9db642904aa406f08dddb06798b576ec14949b8
[ "MIT" ]
null
null
null
calm/fix-missing-src-hint.py
jon-turney/calm
a9db642904aa406f08dddb06798b576ec14949b8
[ "MIT" ]
3
2016-03-21T12:54:16.000Z
2022-03-06T09:41:06.000Z
#!/usr/bin/env python3 # # Copyright (c) 2020 Jon Turney # # 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,...
33.7625
173
0.664198
6fb2783b26fe7b38c3e1cd535a7dff15f5df1f97
971
py
Python
recipe_scrapers/foodrepublic.py
huskywhale/recipe-scraper
d5570d1d5203cfd8dca29f4f6e5f81e10997fdd2
[ "MIT" ]
14
2017-04-06T18:30:04.000Z
2021-09-04T16:10:34.000Z
recipe_scrapers/foodrepublic.py
huskywhale/recipe-scraper
d5570d1d5203cfd8dca29f4f6e5f81e10997fdd2
[ "MIT" ]
null
null
null
recipe_scrapers/foodrepublic.py
huskywhale/recipe-scraper
d5570d1d5203cfd8dca29f4f6e5f81e10997fdd2
[ "MIT" ]
12
2018-02-21T00:53:31.000Z
2021-07-20T02:44:50.000Z
from ._abstract import AbstractScraper from ._utils import get_minutes, normalize_string class FoodRepublic(AbstractScraper): @classmethod def host(self): return 'foodrepublic.com' def title(self): return self.soup.find('h3', {'class': 'recipe-title'}).get_text() def total_time(self...
29.424242
88
0.625129
047798f6dc1450c40817218fe921e97a486f6e59
58,736
py
Python
Lib/logging/handlers.py
CraftSpider/cpython
0f2f35e15f9fbee44ce042b724348419d8136bc5
[ "CNRI-Python-GPL-Compatible" ]
2
2020-10-23T02:42:10.000Z
2020-10-23T02:50:48.000Z
Lib/logging/handlers.py
CraftSpider/cpython
0f2f35e15f9fbee44ce042b724348419d8136bc5
[ "CNRI-Python-GPL-Compatible" ]
2
2021-05-31T13:39:43.000Z
2021-06-01T12:00:13.000Z
Lib/logging/handlers.py
CraftSpider/cpython
0f2f35e15f9fbee44ce042b724348419d8136bc5
[ "CNRI-Python-GPL-Compatible" ]
2
2020-02-24T03:23:47.000Z
2020-02-24T07:45:37.000Z
# Copyright 2001-2016 by Vinay Sajip. All Rights Reserved. # # Permission to use, copy, modify, and distribute this software and its # documentation for any purpose and without fee is hereby granted, # provided that the above copyright notice appear in all copies and that # both that copyright notice and this permissio...
38.41465
120
0.578827
7cfc7099fe9481fed969b14fb697e14c8cde9d44
5,428
py
Python
gdpr_assist/anonymiser.py
mopitz199/django-gdpr-assist
c7428d64bee85558541eceff1f42ecb44fc14c75
[ "BSD-3-Clause" ]
null
null
null
gdpr_assist/anonymiser.py
mopitz199/django-gdpr-assist
c7428d64bee85558541eceff1f42ecb44fc14c75
[ "BSD-3-Clause" ]
null
null
null
gdpr_assist/anonymiser.py
mopitz199/django-gdpr-assist
c7428d64bee85558541eceff1f42ecb44fc14c75
[ "BSD-3-Clause" ]
1
2019-12-11T13:31:57.000Z
2019-12-11T13:31:57.000Z
""" Anonymisation functionality """ import datetime import uuid from django.db import models from django.utils.timezone import now from .deletion import ANONYMISE from .exceptions import AnonymiseError from .registry import registry anonymisers = {} def register(*field_classes): def outer(fn): # Regis...
21.203125
77
0.66857
02f0f4f5133fe5f5c604e72817e1c6e11c788a8e
173
py
Python
tasks.py
vlcinsky/python-fastapi-github-timeline
e066dc5811fde884af9ddf8f01d14675a9fef302
[ "MIT" ]
4
2021-08-03T09:32:41.000Z
2022-03-25T23:06:49.000Z
tasks.py
vlcinsky/python-fastapi-github-timeline
e066dc5811fde884af9ddf8f01d14675a9fef302
[ "MIT" ]
null
null
null
tasks.py
vlcinsky/python-fastapi-github-timeline
e066dc5811fde884af9ddf8f01d14675a9fef302
[ "MIT" ]
1
2021-11-09T08:57:39.000Z
2021-11-09T08:57:39.000Z
from invoke import task @task def app_run(c): """Run web app in development mode""" c.run( "uvicorn app:app --reload --port=8000", pty=True, )
15.727273
47
0.572254
81c96a61ab11f16f369f572e8938e8fa363bfec5
4,276
py
Python
tests/test_cityhash.py
yujiaao/python-cityhash
bc99c439fd642adce0cf336aee7f6e4c4c9ba81e
[ "MIT" ]
2
2021-03-03T08:42:46.000Z
2021-03-06T18:07:30.000Z
tests/test_cityhash.py
yujiaao/python-cityhash
bc99c439fd642adce0cf336aee7f6e4c4c9ba81e
[ "MIT" ]
null
null
null
tests/test_cityhash.py
yujiaao/python-cityhash
bc99c439fd642adce0cf336aee7f6e4c4c9ba81e
[ "MIT" ]
1
2021-03-03T08:43:53.000Z
2021-03-03T08:43:53.000Z
import array import unittest import random import string import sys from cityhash import ( CityHash32, CityHash64, CityHash64WithSeed, CityHash64WithSeeds, CityHash128, CityHash128WithSeed, ) if sys.version_info[0] >= 3: long = int def random_string(n, alphabet=string.ascii_lowercase): return '...
35.932773
110
0.656221
c8df3be2dab9921691bd4d2d51525873b99e6cf9
427
py
Python
articles/migrations/old/0007_author_slug.py
JClubb3/johnj.club
a10bb4e15da38a5bf2e265790fe2bf7603e5474c
[ "MIT" ]
null
null
null
articles/migrations/old/0007_author_slug.py
JClubb3/johnj.club
a10bb4e15da38a5bf2e265790fe2bf7603e5474c
[ "MIT" ]
null
null
null
articles/migrations/old/0007_author_slug.py
JClubb3/johnj.club
a10bb4e15da38a5bf2e265790fe2bf7603e5474c
[ "MIT" ]
null
null
null
# Generated by Django 2.0 on 2018-02-16 15:39 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('articles', '0006_auto_20180216_0947'), ] operations = [ migrations.AddField( model_name='author', name='slug', ...
22.473684
96
0.604215
a6f24509ca1f20fb06b3bcbe4ed5f804a04bc039
2,392
bzl
Python
tools/sass_bundle.bzl
MarkArranz/material2
3255cf3c3675037725ea579fcdfa373d06977fb4
[ "MIT" ]
4
2017-09-12T16:12:28.000Z
2018-05-02T21:16:55.000Z
tools/sass_bundle.bzl
MarkArranz/material2
3255cf3c3675037725ea579fcdfa373d06977fb4
[ "MIT" ]
2
2018-07-12T23:57:08.000Z
2018-07-13T00:15:06.000Z
tools/sass_bundle.bzl
MarkArranz/material2
3255cf3c3675037725ea579fcdfa373d06977fb4
[ "MIT" ]
3
2017-11-23T04:20:48.000Z
2018-05-02T21:17:13.000Z
# Implementation of sass_bundle that performs an action def _sass_bundle(ctx): # Define arguments that will be passed to the underlying nodejs script. args = ctx.actions.args() # The entry-point scss file for the bundle. args.add("--entry") args.add(ctx.attr.entry_point.files) # The list of files that can...
37.375
79
0.704013