hexsha
stringlengths
40
40
size
int64
1
1.03M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
3
239
max_stars_repo_name
stringlengths
5
130
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
239
max_issues_repo_name
stringlengths
5
130
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
239
max_forks_repo_name
stringlengths
5
130
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
1
1.03M
avg_line_length
float64
1
958k
max_line_length
int64
1
1.03M
alphanum_fraction
float64
0
1
4a273f551d8225ab3bbd470297a52534408bc01e
35,624
py
Python
src/cogent3/app/data_store.py
u6052029/cogent3
ca0efcb7f60b715bcbfbecd924cdb98a53cefe20
[ "BSD-3-Clause" ]
null
null
null
src/cogent3/app/data_store.py
u6052029/cogent3
ca0efcb7f60b715bcbfbecd924cdb98a53cefe20
[ "BSD-3-Clause" ]
null
null
null
src/cogent3/app/data_store.py
u6052029/cogent3
ca0efcb7f60b715bcbfbecd924cdb98a53cefe20
[ "BSD-3-Clause" ]
null
null
null
import glob import json import os import pathlib import re import shutil import weakref import zipfile from collections import defaultdict from fnmatch import fnmatch, translate from io import TextIOWrapper from json import JSONDecodeError from pathlib import Path from pprint import pprint from warnings import warn f...
32.652612
88
0.583595
4a273fb3ef73b3ff8e1aa3b4c26ee5011bb7b8c9
2,894
py
Python
test1/test1/settings.py
435236402/dome
6c433c84b682475e2d2843c57ec5a847bc688405
[ "MIT" ]
null
null
null
test1/test1/settings.py
435236402/dome
6c433c84b682475e2d2843c57ec5a847bc688405
[ "MIT" ]
null
null
null
test1/test1/settings.py
435236402/dome
6c433c84b682475e2d2843c57ec5a847bc688405
[ "MIT" ]
null
null
null
""" Django settings for test1 project. Generated by 'django-admin startproject' using Django 1.8.2. For more information on this file, see https://docs.djangoproject.com/en/1.8/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/1.8/ref/settings/ """ # Build paths ...
24.735043
71
0.678645
4a27408c5113ac9308808830efa68fdd6ad58ea5
40,960
py
Python
imagenet/models/pre_resnet_CFandIN_temp.py
LongJin-lab/Nematode-Connectome-Neural-Network
c1fcef110df7d5cfb9fec6a0778b8340e5289ede
[ "MIT" ]
null
null
null
imagenet/models/pre_resnet_CFandIN_temp.py
LongJin-lab/Nematode-Connectome-Neural-Network
c1fcef110df7d5cfb9fec6a0778b8340e5289ede
[ "MIT" ]
null
null
null
imagenet/models/pre_resnet_CFandIN_temp.py
LongJin-lab/Nematode-Connectome-Neural-Network
c1fcef110df7d5cfb9fec6a0778b8340e5289ede
[ "MIT" ]
null
null
null
import torch.nn as nn import torch import torch.nn.functional as functional from torch.nn.parameter import Parameter import math from torch.autograd import Variable import numpy as np import torch.onnx import netron # from init import * from random import random import argparse # __all__ = ['pre_resnet18', 'pre_re...
46.439909
207
0.55293
4a2742170ed4fd25a7774bc7142b7a73d279b213
32,602
py
Python
old_projects/hilbert/section2.py
rorik/manim
1fa9ba56eabaf189ef40278ab6cd894fad257776
[ "MIT" ]
null
null
null
old_projects/hilbert/section2.py
rorik/manim
1fa9ba56eabaf189ef40278ab6cd894fad257776
[ "MIT" ]
null
null
null
old_projects/hilbert/section2.py
rorik/manim
1fa9ba56eabaf189ef40278ab6cd894fad257776
[ "MIT" ]
null
null
null
from big_ol_pile_of_manim_imports import * import displayer as disp from hilbert.curves import \ TransformOverIncreasingOrders, FlowSnake, HilbertCurve, \ SnakeCurve, PeanoCurve from hilbert.section1 import get_mathy_and_bubble from scipy.spatial.distance import cdist def get_time_line(): length = 2.6*FRA...
30.640977
134
0.555518
4a27422523ba02a996ae6f97dd7dde2c90b46fc3
193
py
Python
api/lambda_handler/get_random_color.py
dgimeno777/aws-api-demo
7ff2386737ba8e5e953dbe86e1afa41548c4efc1
[ "MIT" ]
null
null
null
api/lambda_handler/get_random_color.py
dgimeno777/aws-api-demo
7ff2386737ba8e5e953dbe86e1afa41548c4efc1
[ "MIT" ]
null
null
null
api/lambda_handler/get_random_color.py
dgimeno777/aws-api-demo
7ff2386737ba8e5e953dbe86e1afa41548c4efc1
[ "MIT" ]
null
null
null
import json from api.src.colors import get_random_color def lambda_handler(event, context): return { "statusCode": 200, "body": json.dumps(get_random_color().value) }
19.3
52
0.673575
4a274232edcedda9393b016fb72088fb5bf0d757
1,099
py
Python
cibyl/outputs/cli/ci/env/printer.py
rhos-infra/cibyl
842a993ddf3552d1b4f2e85025dcf928f76fe7fb
[ "Apache-2.0" ]
3
2022-02-17T18:07:07.000Z
2022-03-19T10:22:38.000Z
cibyl/outputs/cli/ci/env/printer.py
rhos-infra/cibyl
842a993ddf3552d1b4f2e85025dcf928f76fe7fb
[ "Apache-2.0" ]
58
2022-02-14T14:41:22.000Z
2022-03-31T10:54:28.000Z
cibyl/outputs/cli/ci/env/printer.py
rhos-infra/cibyl
842a993ddf3552d1b4f2e85025dcf928f76fe7fb
[ "Apache-2.0" ]
6
2022-02-14T19:21:26.000Z
2022-03-29T09:31:31.000Z
""" # Copyright 2022 Red Hat # # 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 agr...
32.323529
78
0.689718
4a27437f92548ec7ff55d69a520d4dd3412ea13a
6,440
py
Python
mlrun/frameworks/_ml_common/plans/roc_curve_plan.py
george0st/mlrun
6467d3a5ceadf6cd35512b84b3ddc3da611cf39a
[ "Apache-2.0" ]
null
null
null
mlrun/frameworks/_ml_common/plans/roc_curve_plan.py
george0st/mlrun
6467d3a5ceadf6cd35512b84b3ddc3da611cf39a
[ "Apache-2.0" ]
null
null
null
mlrun/frameworks/_ml_common/plans/roc_curve_plan.py
george0st/mlrun
6467d3a5ceadf6cd35512b84b3ddc3da611cf39a
[ "Apache-2.0" ]
null
null
null
from typing import Dict, List, Union import numpy as np import pandas as pd import plotly.graph_objects as go from sklearn.metrics import roc_auc_score, roc_curve from mlrun.artifacts import Artifact, PlotlyArtifact from ..._common import ModelType from ..plan import MLPlanStages, MLPlotPlan from ..utils import Data...
42.091503
119
0.612112
4a274490f468fdb36049590578a088584870be4b
382
py
Python
utilities/micro_utils/marshmallow/leading_zeros_integer_field.py
ndjuric93/MusicOrganizer
ef2e50abfeb1629325274b260f654935fd3f2740
[ "Apache-2.0" ]
1
2019-09-13T18:05:27.000Z
2019-09-13T18:05:27.000Z
utilities/micro_utils/marshmallow/leading_zeros_integer_field.py
ndjuric93/MusicOrganizer
ef2e50abfeb1629325274b260f654935fd3f2740
[ "Apache-2.0" ]
5
2021-03-09T00:49:53.000Z
2022-02-17T20:03:16.000Z
utilities/micro_utils/marshmallow/leading_zeros_integer_field.py
ndjuric93/MusicOrganizer
ef2e50abfeb1629325274b260f654935fd3f2740
[ "Apache-2.0" ]
null
null
null
from marshmallow import fields class LeadingZerosIntegerField(fields.Integer): def __init__(self, zeros_count, *args, **kwargs): super(LeadingZerosIntegerField, self).__init__(*args, **kwargs) self.zeros_count = zeros_count def _format_num(self, value): if value is None: ...
27.285714
71
0.685864
4a2744b9c5e65e3a966fecf05ad9a7c7e889f15c
840
py
Python
python/BFS/993. Cousins in Binary Tree.py
Nobodylesszb/LeetCode
0e902f6bff4834a93ce64cf9c57fd64297e63523
[ "MIT" ]
null
null
null
python/BFS/993. Cousins in Binary Tree.py
Nobodylesszb/LeetCode
0e902f6bff4834a93ce64cf9c57fd64297e63523
[ "MIT" ]
null
null
null
python/BFS/993. Cousins in Binary Tree.py
Nobodylesszb/LeetCode
0e902f6bff4834a93ce64cf9c57fd64297e63523
[ "MIT" ]
null
null
null
#In a binary tree, the root node is at depth 0, and children of each depth k node are at depth k+1. # Two nodes of a binary tree are cousins if they have the same depth, but have different parents. # We are given the root of a binary tree with unique values, and the values x and y of two different nodes in the tree. ...
49.411765
119
0.628571
4a27458679f341a6776b31d457ac77e5847b502f
8,089
py
Python
tests/full_flow_tests.py
FelixLorenz/distiller
08b5cd95704d850cfb845ed7785f739cbb57de54
[ "Apache-2.0" ]
3
2019-11-03T23:52:42.000Z
2020-05-07T09:08:32.000Z
tests/full_flow_tests.py
FelixLorenz/distiller
08b5cd95704d850cfb845ed7785f739cbb57de54
[ "Apache-2.0" ]
null
null
null
tests/full_flow_tests.py
FelixLorenz/distiller
08b5cd95704d850cfb845ed7785f739cbb57de54
[ "Apache-2.0" ]
1
2019-10-15T03:44:17.000Z
2019-10-15T03:44:17.000Z
# # Copyright (c) 2018 Intel Corporation # # 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...
34.716738
119
0.598714
4a2745a0fa61f5e8b66dec5985b1686a33f641bc
1,403
py
Python
python/pycylon/test/test_parquet.py
kaiyingshan/cylon
1a8c3d7efab000ec665eeba3c9a58dfac9531701
[ "Apache-2.0" ]
3
2019-11-18T23:59:03.000Z
2020-05-28T06:17:49.000Z
python/pycylon/test/test_parquet.py
DSC-SPIDAL/twisternet
773f11ff79648938dc5dd0678b786b97ed289b36
[ "Apache-2.0" ]
33
2019-10-17T15:59:48.000Z
2020-06-19T14:22:41.000Z
python/pycylon/test/test_parquet.py
DSC-SPIDAL/twisternet
773f11ff79648938dc5dd0678b786b97ed289b36
[ "Apache-2.0" ]
15
2019-10-17T02:09:55.000Z
2020-05-23T02:04:45.000Z
## # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the...
34.219512
90
0.729865
4a27460046cffe6cdeb324c5d5b67ebaa7e1457a
10,459
py
Python
poni/rcontrol_paramiko.py
saaros/poni
1d2a9982f7e934137ce1ee675f0e1373314df7c7
[ "Apache-2.0" ]
6
2015-05-11T12:21:53.000Z
2018-01-17T00:07:29.000Z
poni/rcontrol_paramiko.py
saaros/poni
1d2a9982f7e934137ce1ee675f0e1373314df7c7
[ "Apache-2.0" ]
null
null
null
poni/rcontrol_paramiko.py
saaros/poni
1d2a9982f7e934137ce1ee675f0e1373314df7c7
[ "Apache-2.0" ]
2
2015-02-27T10:14:26.000Z
2015-02-27T10:14:30.000Z
""" Remote node control using the Paramiko SSH library Copyright (c) 2010-2012 Mika Eloranta See LICENSE for details. """ import os import sys import socket import time from . import errors from . import rcontrol import select import termios import tty import errno import warnings try: with warnings.catch_warni...
34.068404
105
0.536571
4a27465b409074b2c4b003a44020bc92d0679e91
114,353
py
Python
tools/python/transform/transformer.py
juierror/mace
a2bcf2c98b410f75d38f2291585b0ad11b36d068
[ "Apache-2.0" ]
1
2020-07-22T08:12:24.000Z
2020-07-22T08:12:24.000Z
tools/python/transform/transformer.py
deadzq/mace
aec8421951390ee1dfec4db5c118805908776330
[ "Apache-2.0" ]
null
null
null
tools/python/transform/transformer.py
deadzq/mace
aec8421951390ee1dfec4db5c118805908776330
[ "Apache-2.0" ]
null
null
null
# Copyright 2018 The MACE 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 applicable la...
47.806438
128
0.51383
4a27466f957a497b4fccef8e529356b4647eeb1e
14,638
py
Python
eaitest.py
jrlevine/eaitesttools
b51d23db0f37235f32a1f88f7a5ff5b5e2c8cdf1
[ "BSD-2-Clause" ]
1
2020-12-13T20:25:15.000Z
2020-12-13T20:25:15.000Z
eaitest.py
jrlevine/eaitesttools
b51d23db0f37235f32a1f88f7a5ff5b5e2c8cdf1
[ "BSD-2-Clause" ]
null
null
null
eaitest.py
jrlevine/eaitesttools
b51d23db0f37235f32a1f88f7a5ff5b5e2c8cdf1
[ "BSD-2-Clause" ]
null
null
null
#!/usr/local/bin/python3 # # EAI feature tests from bottle import request, route, get, post, run, hook, app, template, view, \ static_file, redirect, HTTPResponse, BaseRequest from beaker.middleware import SessionMiddleware from eaidb import EAIdb import re, sys import base64 debug = False # allow large zones Ba...
27.776091
123
0.587785
4a27475926312ccb7a625df32634d6512bd2e976
436
py
Python
src/gpt_utils/location.py
nelsonlove/gpt-utils
1ce52a160c26b647f7674bf518a322b54b6080da
[ "MIT" ]
null
null
null
src/gpt_utils/location.py
nelsonlove/gpt-utils
1ce52a160c26b647f7674bf518a322b54b6080da
[ "MIT" ]
null
null
null
src/gpt_utils/location.py
nelsonlove/gpt-utils
1ce52a160c26b647f7674bf518a322b54b6080da
[ "MIT" ]
null
null
null
from . import GPT from .prompt import ConversionPrompt @GPT.requires_key def fix_location(in_text): """Accepts a string containing a location and formats it properly.""" prompt = ConversionPrompt( 'I', 'O', ("lenox ma", "Lenox, MA"), ("london", "London, U.K."), ("chicago", "Chi...
25.647059
73
0.591743
4a2748593c7ffd2811b7e0a1c9adcc5fcf3ca492
3,100
py
Python
doc/source/examples/usage_helper.py
mail2nsrajesh/oslo.log
33d76a5d296bc0685844a896970fb4f59cce5143
[ "Apache-2.0" ]
null
null
null
doc/source/examples/usage_helper.py
mail2nsrajesh/oslo.log
33d76a5d296bc0685844a896970fb4f59cce5143
[ "Apache-2.0" ]
null
null
null
doc/source/examples/usage_helper.py
mail2nsrajesh/oslo.log
33d76a5d296bc0685844a896970fb4f59cce5143
[ "Apache-2.0" ]
null
null
null
# Copyright (c) 2016 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 i...
29.807692
77
0.71871
4a2749b71895f0ebbc35caf4072935fd945d9167
22,404
py
Python
ucsmsdk/mometa/vm/VmLifeCyclePolicy.py
Kego/ucsmsdk
244f283a5c295cf746110bb96686d079b19927ce
[ "Apache-2.0" ]
78
2015-11-30T14:10:05.000Z
2022-02-13T00:29:08.000Z
ucsmsdk/mometa/vm/VmLifeCyclePolicy.py
Kego/ucsmsdk
244f283a5c295cf746110bb96686d079b19927ce
[ "Apache-2.0" ]
113
2015-11-20T09:42:46.000Z
2022-03-16T16:53:29.000Z
ucsmsdk/mometa/vm/VmLifeCyclePolicy.py
Kego/ucsmsdk
244f283a5c295cf746110bb96686d079b19927ce
[ "Apache-2.0" ]
86
2015-12-12T08:22:18.000Z
2022-01-23T03:56:34.000Z
"""This module contains the general information for VmLifeCyclePolicy ManagedObject.""" from ...ucsmo import ManagedObject from ...ucscoremeta import MoPropertyMeta, MoMeta from ...ucsmeta import VersionMeta class VmLifeCyclePolicyConsts: FSM_PREV_CONFIG_BEGIN = "configBegin" FSM_PREV_CONFIG_FAIL = "configFa...
89.975904
3,774
0.759373
4a2749e705a341088ce6e0bc3866ad36335e55f2
4,388
py
Python
network/predict_many.py
Neoleukin-Therapeutics/trRosetta
6a68c33e1c9834c24bd7aa010999d0e9e5279d4d
[ "MIT" ]
179
2019-11-07T06:53:34.000Z
2022-03-17T13:55:20.000Z
network/predict_many.py
Neoleukin-Therapeutics/trRosetta
6a68c33e1c9834c24bd7aa010999d0e9e5279d4d
[ "MIT" ]
11
2020-03-29T22:05:08.000Z
2021-05-12T17:03:26.000Z
network/predict_many.py
Neoleukin-Therapeutics/trRosetta
6a68c33e1c9834c24bd7aa010999d0e9e5279d4d
[ "MIT" ]
52
2019-10-21T23:42:18.000Z
2022-03-17T04:27:50.000Z
import warnings, logging, os, sys warnings.filterwarnings('ignore',category=FutureWarning) logging.disable(logging.WARNING) os.environ["TF_CPP_MIN_LOG_LEVEL"] = "3" import json import tensorflow as tf from utils import * from arguments import get_args_many args = get_args_many() MDIR = args.MDIR n2d_layers ...
32.264706
112
0.591613
4a2749ebffed0ee537968d7cdb32a8bc1cb54427
2,450
py
Python
domain_management/domainutil.py
IBM/api-samples
d69f7a7b74244012e835f023bceec2b0370be586
[ "Apache-2.0" ]
172
2015-02-18T21:18:31.000Z
2022-03-13T17:51:11.000Z
domain_management/domainutil.py
IBM/api-samples
d69f7a7b74244012e835f023bceec2b0370be586
[ "Apache-2.0" ]
15
2015-03-06T15:30:33.000Z
2021-03-05T09:20:34.000Z
domain_management/domainutil.py
IBM/api-samples
d69f7a7b74244012e835f023bceec2b0370be586
[ "Apache-2.0" ]
77
2015-03-06T13:14:06.000Z
2022-02-14T15:35:58.000Z
"""Domain utilities used by sample scripts for Domain API. """ import json import os import sys import uuid from importlib import import_module sys.path.append(os.path.realpath('../modules')) _RestApiClient = import_module('RestApiClient') _SampleUtilities = import_module('SampleUtilities') _client = _RestApiClient.R...
29.518072
76
0.64898
4a274a2db9c0c59ef0c85a11dc81fec3f77847b4
203
py
Python
2016/02/test_lavvy_lock.py
GeoffRiley/AdventOfCode
27fe8670a1923cb3b0675784f5e855ad18c29c93
[ "Unlicense" ]
2
2020-12-12T03:18:45.000Z
2021-12-17T00:35:33.000Z
2016/02/test_lavvy_lock.py
GeoffRiley/AdventOfCode
27fe8670a1923cb3b0675784f5e855ad18c29c93
[ "Unlicense" ]
null
null
null
2016/02/test_lavvy_lock.py
GeoffRiley/AdventOfCode
27fe8670a1923cb3b0675784f5e855ad18c29c93
[ "Unlicense" ]
null
null
null
from lavvy_lock import lavvy_decode def test_lavvy_decode(): test_code = '''ULL RRDDD LURDL UUUUD''' assert lavvy_decode(test_code) == '1985' assert lavvy_decode(test_code, True) == '5DB3'
18.454545
50
0.714286
4a274b652127e10dc02a8f78940f1ad1c2739737
1,870
py
Python
flask_reveal/tests/test_base.py
grupydf/flask-reveal
6a60c9db68db68d18eae9734ac809158157ed293
[ "MIT" ]
2
2015-04-23T14:16:08.000Z
2015-04-23T14:19:26.000Z
flask_reveal/tests/test_base.py
grupydf/flask-reveal
6a60c9db68db68d18eae9734ac809158157ed293
[ "MIT" ]
null
null
null
flask_reveal/tests/test_base.py
grupydf/flask-reveal
6a60c9db68db68d18eae9734ac809158157ed293
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- import os import unittest import tempfile from flask import current_app from flask_reveal.app import FlaskReveal from flask_reveal.config import REVEAL_CONFIG, REVEAL_META from flask_reveal.blueprints.reveal import reveal_blueprint class BaseAppTestCase(unittest.TestCase): def setUp(sel...
30.655738
69
0.615508
4a274b8640c1fd38bf0922dc720e98ebe27c8e6f
13,881
py
Python
tensorflow_probability/python/distributions/onehot_categorical_test.py
nbro/probability
07a6378155f0ed720b5aaccf5387e3f9a432bd10
[ "Apache-2.0" ]
null
null
null
tensorflow_probability/python/distributions/onehot_categorical_test.py
nbro/probability
07a6378155f0ed720b5aaccf5387e3f9a432bd10
[ "Apache-2.0" ]
null
null
null
tensorflow_probability/python/distributions/onehot_categorical_test.py
nbro/probability
07a6378155f0ed720b5aaccf5387e3f9a432bd10
[ "Apache-2.0" ]
null
null
null
# Copyright 2018 The TensorFlow Probability 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 o...
40.469388
80
0.670413
4a274c32ed647884f878b0eb041d24272785eeb6
39,591
py
Python
svg2mod/svg2mod.py
al3ph/svg2mod
a6fb251b99b048920a4d92a6558243bc5ee4af6c
[ "CC0-1.0" ]
null
null
null
svg2mod/svg2mod.py
al3ph/svg2mod
a6fb251b99b048920a4d92a6558243bc5ee4af6c
[ "CC0-1.0" ]
null
null
null
svg2mod/svg2mod.py
al3ph/svg2mod
a6fb251b99b048920a4d92a6558243bc5ee4af6c
[ "CC0-1.0" ]
null
null
null
#!/usr/bin/python from __future__ import absolute_import import argparse import datetime import os from pprint import pformat, pprint import re import svg2mod.svg as svg import sys #---------------------------------------------------------------------------- DEFAULT_DPI = 96 # 96 as of Inkscape 0.92 def main(): ...
27.135709
97
0.43131
4a274e454f34759f91e9b97175b1709948e54e7e
1,239
py
Python
contracts/contract_account.py
fabrice102/create-asa-with-ssc
616025599b54cc3cff94f5abb012535c7eebcf03
[ "MIT" ]
5
2021-06-17T18:17:52.000Z
2021-07-18T07:58:32.000Z
contracts/contract_account.py
fabrice102/create-asa-with-ssc
616025599b54cc3cff94f5abb012535c7eebcf03
[ "MIT" ]
null
null
null
contracts/contract_account.py
fabrice102/create-asa-with-ssc
616025599b54cc3cff94f5abb012535c7eebcf03
[ "MIT" ]
null
null
null
import sys from pyteal import * def contract_account(app_id): asset_close_to_check = Txn.asset_close_to() == Global.zero_address() rekey_check = Txn.rekey_to() == Global.zero_address() linked_with_app_call = And( Gtxn[0].type_enum() == TxnType.ApplicationCall, Gtxn[0].application_id() == ...
29.5
80
0.625504
4a274e9f499232b325635a993f9a963c9d2c20e9
7,750
py
Python
monitor-app-route-report-csv.py
ccie29824/viptela_application-route-policy
610f3a054a1bf5fae691845b7bc0d410609dc38e
[ "BSD-3-Clause" ]
6
2020-05-31T06:37:31.000Z
2020-11-18T03:14:38.000Z
monitor-app-route-report-csv.py
ccie29824/viptela_application-route-policy
610f3a054a1bf5fae691845b7bc0d410609dc38e
[ "BSD-3-Clause" ]
null
null
null
monitor-app-route-report-csv.py
ccie29824/viptela_application-route-policy
610f3a054a1bf5fae691845b7bc0d410609dc38e
[ "BSD-3-Clause" ]
4
2020-05-13T06:19:07.000Z
2021-03-08T03:55:52.000Z
import requests import sys import json import os import time import logging import tabulate import yaml from logging.handlers import TimedRotatingFileHandler requests.packages.urllib3.disable_warnings() from requests.packages.urllib3.exceptions import InsecureRequestWarning def get_logger(logfile, level): ''' ...
37.259615
180
0.454194
4a27500b6976d0a3ae283165b4b304c2596c149d
4,059
py
Python
benchmark/startCirq1426.py
UCLA-SEAL/QDiff
d968cbc47fe926b7f88b4adf10490f1edd6f8819
[ "BSD-3-Clause" ]
null
null
null
benchmark/startCirq1426.py
UCLA-SEAL/QDiff
d968cbc47fe926b7f88b4adf10490f1edd6f8819
[ "BSD-3-Clause" ]
null
null
null
benchmark/startCirq1426.py
UCLA-SEAL/QDiff
d968cbc47fe926b7f88b4adf10490f1edd6f8819
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- # @Time : 5/15/20 4:49 PM # @File : grover.py # qubit number=5 # total number=55 import cirq import cirq.google as cg from typing import Optional import sys from math import log2 import numpy as np #thatsNoCode from cirq.contrib.svg import SVGCircuit # Symbols for...
39.028846
77
0.646465
4a27506c3f62de61587af4f428faaa37a1a38dc8
3,567
py
Python
system/t04_mirror/edit.py
masselstine/aptly
3d2ccf1b2a02ea45eb0fa4fa7180b1809cb4590d
[ "MIT" ]
1,035
2015-01-05T00:37:30.000Z
2018-04-17T17:17:20.000Z
system/t04_mirror/edit.py
utopia-repository/aptly
799462acc46628f85ab1539c8866f864216edee5
[ "MIT" ]
502
2015-01-05T09:45:29.000Z
2018-04-18T01:37:33.000Z
system/t04_mirror/edit.py
utopia-repository/aptly
799462acc46628f85ab1539c8866f864216edee5
[ "MIT" ]
198
2015-01-02T03:08:20.000Z
2018-04-16T22:16:51.000Z
import re from lib import BaseTest class EditMirror1Test(BaseTest): """ edit mirror: enable filter & download sources """ fixtureDB = True runCmd = "aptly mirror edit -filter=nginx -filter-with-deps -with-sources wheezy-main" def check(self): self.check_output() self.check_cmd...
30.487179
152
0.662461
4a2750a66ec41830ed5b9b3e040f7b708af5c733
70,391
py
Python
sympy/tensor/tests/test_tensor.py
giorgosgiapis/sympy
6128b47aa008657715ce5c70b7c3fdd6bd3f1648
[ "BSD-3-Clause" ]
null
null
null
sympy/tensor/tests/test_tensor.py
giorgosgiapis/sympy
6128b47aa008657715ce5c70b7c3fdd6bd3f1648
[ "BSD-3-Clause" ]
null
null
null
sympy/tensor/tests/test_tensor.py
giorgosgiapis/sympy
6128b47aa008657715ce5c70b7c3fdd6bd3f1648
[ "BSD-3-Clause" ]
null
null
null
from functools import wraps from sympy import Matrix, eye, Integer, expand, Indexed, Sum from sympy.combinatorics import Permutation from sympy.core import S, Rational, Symbol, Basic, Add from sympy.core.containers import Tuple from sympy.core.symbol import symbols from sympy.functions.elementary.miscellaneous import ...
35.695233
171
0.55017
4a27516fed55d3054a4c4bf1821eb628c1b92edd
2,405
py
Python
src/firebolt/db/connection.py
firebolt-db/firebolt-python-sdk
35154a5ce070e71138d8573ce4c97891e212a939
[ "Apache-2.0" ]
4
2022-01-29T19:21:52.000Z
2022-03-25T20:48:14.000Z
src/firebolt/db/connection.py
firebolt-db/firebolt-python-sdk
35154a5ce070e71138d8573ce4c97891e212a939
[ "Apache-2.0" ]
92
2021-11-19T18:15:15.000Z
2022-03-30T11:52:06.000Z
src/firebolt/db/connection.py
firebolt-db/firebolt-python-sdk
35154a5ce070e71138d8573ce4c97891e212a939
[ "Apache-2.0" ]
6
2021-11-22T22:04:20.000Z
2022-02-18T15:30:23.000Z
from __future__ import annotations from functools import wraps from types import TracebackType from typing import Any from warnings import warn from readerwriterlock.rwlock import RWLockWrite from firebolt.async_db.connection import BaseConnection as AsyncBaseConnection from firebolt.async_db.connection import async...
32.066667
86
0.708524
4a27519c41792019a8bb0e1fd2709ef021c726b3
426
py
Python
data/scripts/templates/object/intangible/pet/shared_peko_peko_hue.py
obi-two/GameServer
7d37024e2291a97d49522610cd8f1dbe5666afc2
[ "MIT" ]
20
2015-02-23T15:11:56.000Z
2022-03-18T20:56:48.000Z
data/scripts/templates/object/intangible/pet/shared_peko_peko_hue.py
apathyboy/swganh
665128efe9154611dec4cb5efc61d246dd095984
[ "MIT" ]
null
null
null
data/scripts/templates/object/intangible/pet/shared_peko_peko_hue.py
apathyboy/swganh
665128efe9154611dec4cb5efc61d246dd095984
[ "MIT" ]
20
2015-04-04T16:35:59.000Z
2022-03-24T14:54:37.000Z
#### NOTICE: THIS FILE IS AUTOGENERATED #### MODIFICATIONS MAY BE LOST IF DONE IMPROPERLY #### PLEASE SEE THE ONLINE DOCUMENTATION FOR EXAMPLES from swgpy.object import * def create(kernel): result = Intangible() result.template = "object/intangible/pet/shared_peko_peko_hue.iff" result.attribute_template_id = -1...
25.058824
67
0.713615
4a275209c1a77420b2e277e438ceb78b3db7e5ae
1,730
py
Python
utils.py
cnguyen10/similarity_classification_tasks
a8ecf253ed1b23bc246ba5f8880a8a18e92f3bff
[ "MIT" ]
null
null
null
utils.py
cnguyen10/similarity_classification_tasks
a8ecf253ed1b23bc246ba5f8880a8a18e92f3bff
[ "MIT" ]
null
null
null
utils.py
cnguyen10/similarity_classification_tasks
a8ecf253ed1b23bc246ba5f8880a8a18e92f3bff
[ "MIT" ]
null
null
null
import torch import numpy as np import os import sys import pickle from PIL import Image import typing def list_dir(root: str, prefix: bool = False) -> typing.List[str]: """List all directories at a given root Args: root (str): Path to directory whose folders need to be listed prefix (bool, ...
39.318182
121
0.675145
4a27524cfec7a5568a1b5cb287a6322330bcea88
971
py
Python
xlsxwriter/test/comparison/test_table22.py
hugovk/XlsxWriter
e97cc66637d9895480ee32cfb5e561d652d3787b
[ "BSD-2-Clause" ]
null
null
null
xlsxwriter/test/comparison/test_table22.py
hugovk/XlsxWriter
e97cc66637d9895480ee32cfb5e561d652d3787b
[ "BSD-2-Clause" ]
null
null
null
xlsxwriter/test/comparison/test_table22.py
hugovk/XlsxWriter
e97cc66637d9895480ee32cfb5e561d652d3787b
[ "BSD-2-Clause" ]
null
null
null
############################################################################### # # Tests for XlsxWriter. # # SPDX-License-Identifier: BSD-2-Clause # Copyright (c), 2013-2022, John McNamara, jmcnamara@cpan.org # from ..excel_comparison_test import ExcelComparisonTest from ...workbook import Workbook class TestCompar...
23.119048
79
0.580844
4a2754a50ca140a14e986a0719ddb97e42260ecf
1,562
py
Python
kanshu/merge_txt_files.py
hustbill/python-crawler
7d736b9a3c6d031a9a7e37c74ae3bd417534fb06
[ "MIT" ]
null
null
null
kanshu/merge_txt_files.py
hustbill/python-crawler
7d736b9a3c6d031a9a7e37c74ae3bd417534fb06
[ "MIT" ]
null
null
null
kanshu/merge_txt_files.py
hustbill/python-crawler
7d736b9a3c6d031a9a7e37c74ae3bd417534fb06
[ "MIT" ]
null
null
null
import os import glob import re # Ref: https://stackoverflow.com/questions/5967500/how-to-correctly-sort-a-string-with-a-number-inside def atof(text): try: retval = float(text) except ValueError: retval = text return retval def natural_keys(text): ''' alist.sort(key=natural_keys)...
31.24
102
0.612036
4a2755168326d2d2e2f9c332581bcb8de167d5df
1,402
py
Python
library/books/book_descriptors.py
HoldYourBreath/Library
776d4e31beb3ce976c23dc423c88839435bf26ae
[ "MIT" ]
2
2017-04-29T07:27:04.000Z
2017-06-17T14:49:14.000Z
library/books/book_descriptors.py
HoldYourBreath/Library
776d4e31beb3ce976c23dc423c88839435bf26ae
[ "MIT" ]
45
2017-06-16T13:34:45.000Z
2022-03-08T22:46:52.000Z
library/books/book_descriptors.py
HoldYourBreath/Library
776d4e31beb3ce976c23dc423c88839435bf26ae
[ "MIT" ]
null
null
null
import library.database as database from library.books.book_descriptor import BookDescriptor class BookDescriptors: def __init__(self): self.books = [] def marshal(self): return [book.marshal() for book in self.books] @staticmethod def get(search_params={}): db = database.get...
34.195122
75
0.544936
4a2755b80c5c2cdeb9ae85e867ecee13ef8a0c99
2,544
py
Python
resources/migrations/0005_add_map_field.py
City-of-Helsinki/berth-reservations
a3b1a8c2176f132505527acdf6da3a62199401db
[ "MIT" ]
3
2020-10-13T07:58:48.000Z
2020-12-22T09:41:50.000Z
resources/migrations/0005_add_map_field.py
City-of-Helsinki/berth-reservations
a3b1a8c2176f132505527acdf6da3a62199401db
[ "MIT" ]
422
2018-10-25T10:57:05.000Z
2022-03-30T05:47:14.000Z
resources/migrations/0005_add_map_field.py
City-of-Helsinki/berth-reservations
a3b1a8c2176f132505527acdf6da3a62199401db
[ "MIT" ]
1
2020-04-03T07:38:03.000Z
2020-04-03T07:38:03.000Z
# Generated by Django 2.2.6 on 2020-03-06 08:44 import django.core.files.storage from django.db import migrations, models import django.db.models.deletion import resources.models import uuid class Migration(migrations.Migration): dependencies = [ ("resources", "0004_add_depth_to_berth_type"), ] ...
31.02439
78
0.387972
4a2755d462f429a54d8d093f181b2e4e0c348950
7,440
py
Python
test/client_test.py
mengibin/nacos-sdk-python
f929d983f62904efdbbda3b5dd148905478bfa08
[ "Apache-2.0" ]
null
null
null
test/client_test.py
mengibin/nacos-sdk-python
f929d983f62904efdbbda3b5dd148905478bfa08
[ "Apache-2.0" ]
null
null
null
test/client_test.py
mengibin/nacos-sdk-python
f929d983f62904efdbbda3b5dd148905478bfa08
[ "Apache-2.0" ]
1
2020-11-05T09:01:30.000Z
2020-11-05T09:01:30.000Z
# -*- coding: utf8 -*- from __future__ import print_function import unittest import nacos from nacos import files import time import shutil SERVER_1 = "100.69.207.65" SERVER_ADDRESSES = "%s:8848, 100.69.207.66:8848" % SERVER_1 NAMESPACE = "6cface1f-2f1b-4744-a59d-fd818b91a799" # Set the following values if authentic...
37.959184
135
0.624866
4a27563d132b3e77f97bdad802c5d4b9ad436078
1,893
py
Python
modules/tools/navigator/navigator.py
XiaoyuMo92/apollo
ee7bbef1b5afe9caa94bdc8033eed5d0ee3779aa
[ "Apache-2.0" ]
null
null
null
modules/tools/navigator/navigator.py
XiaoyuMo92/apollo
ee7bbef1b5afe9caa94bdc8033eed5d0ee3779aa
[ "Apache-2.0" ]
2
2022-01-27T16:14:38.000Z
2022-02-11T00:10:28.000Z
modules/tools/navigator/navigator.py
XiaoyuMo92/apollo
ee7bbef1b5afe9caa94bdc8033eed5d0ee3779aa
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python ############################################################################### # Copyright 2017 The Apollo 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 ...
35.055556
79
0.611199
4a275690686fae92756ab8a3eee6b1b4120cc9c0
1,209
py
Python
river/tree/_attribute_test/nominal_attribute_binary_test.py
brcharron/creme
25290780f6bba0eb030215194e81b120d0219389
[ "BSD-3-Clause" ]
1
2020-12-04T18:56:19.000Z
2020-12-04T18:56:19.000Z
river/tree/_attribute_test/nominal_attribute_binary_test.py
brcharron/creme
25290780f6bba0eb030215194e81b120d0219389
[ "BSD-3-Clause" ]
null
null
null
river/tree/_attribute_test/nominal_attribute_binary_test.py
brcharron/creme
25290780f6bba0eb030215194e81b120d0219389
[ "BSD-3-Clause" ]
null
null
null
from .instance_conditional_test import InstanceConditionalTest class NominalAttributeBinaryTest(InstanceConditionalTest): """Implement binary split tests for categorical features. The resulting test considers two branches: one encompassing a specific feature value, and another for the remaining c...
29.487805
78
0.630273
4a275706a79050b9179b731a6d0d84a6e13fbc93
2,289
py
Python
swmmio/__main__.py
jennwuu/swmmio
6918ecfb69c10333cbc65ce0ab6554f8a04ef8f9
[ "MIT" ]
76
2016-04-26T14:04:02.000Z
2022-03-24T10:10:29.000Z
swmmio/__main__.py
Kimi-Monica/swmmio
54dd6c1f7a3e47db5702b1f703beca0a8945a250
[ "MIT" ]
94
2016-05-06T15:32:51.000Z
2022-02-10T08:03:30.000Z
swmmio/__main__.py
Kimi-Monica/swmmio
54dd6c1f7a3e47db5702b1f703beca0a8945a250
[ "MIT" ]
26
2016-09-01T22:51:47.000Z
2022-02-09T09:13:23.000Z
from swmmio.run_models.run import run_simple, run_hot_start_sequence from swmmio.run_models import start_pool from swmmio import Model from itertools import chain import os import argparse from multiprocessing import Pool, cpu_count from datetime import datetime #parse the arguments parser = argparse.ArgumentParser(d...
38.79661
90
0.719965
4a2757df18c3a10db89c859de214132cdd08ef92
48
py
Python
tests/__init__.py
vishalbelsare/drug2ways
9ddac00c221e4c0c785dcce2e5360624ead1575b
[ "Apache-2.0" ]
21
2020-05-27T21:23:09.000Z
2022-02-09T13:42:29.000Z
tests/__init__.py
vishalbelsare/drug2ways
9ddac00c221e4c0c785dcce2e5360624ead1575b
[ "Apache-2.0" ]
8
2020-05-29T20:46:21.000Z
2021-10-13T13:35:59.000Z
tests/__init__.py
vishalbelsare/drug2ways
9ddac00c221e4c0c785dcce2e5360624ead1575b
[ "Apache-2.0" ]
6
2020-07-15T14:09:48.000Z
2022-03-30T12:27:53.000Z
# -*- coding: utf-8 -*- """drug2ways tests."""
12
23
0.5
4a275945fc5f750571e7af4f4e2d2d0eec387687
362
py
Python
never_saiddit/core/urls.py
Damgaard/Never-Saiddit
d2b0bac0a39da0f21d8a0e5ed46094786615c41f
[ "MIT" ]
null
null
null
never_saiddit/core/urls.py
Damgaard/Never-Saiddit
d2b0bac0a39da0f21d8a0e5ed46094786615c41f
[ "MIT" ]
null
null
null
never_saiddit/core/urls.py
Damgaard/Never-Saiddit
d2b0bac0a39da0f21d8a0e5ed46094786615c41f
[ "MIT" ]
null
null
null
from django.conf.urls import url from . import views urlpatterns = [ url(r'^get_job_status/$', views.get_job_status, name='get_job_status'), # Main pages url(r'^confirmation/(?P<pk>[\w-]*)/$', views.ConfirmationView.as_view(), name="confirmation"), url(r'^destruction/(?P<pk>[\w-]*)/$', views.Destruct...
30.166667
98
0.668508
4a275aac0f57032d51c557bd2190c036a2ccaa9c
4,676
py
Python
great_expectations/datasource/data_connector/configured_asset_filesystem_data_connector.py
OmriBromberg/great_expectations
60eb81ebfb08fef5d37d55c316dc962928beb165
[ "Apache-2.0" ]
1
2021-04-11T20:54:23.000Z
2021-04-11T20:54:23.000Z
great_expectations/datasource/data_connector/configured_asset_filesystem_data_connector.py
OmriBromberg/great_expectations
60eb81ebfb08fef5d37d55c316dc962928beb165
[ "Apache-2.0" ]
53
2021-10-02T02:26:51.000Z
2021-12-28T20:49:25.000Z
great_expectations/datasource/data_connector/configured_asset_filesystem_data_connector.py
OmriBromberg/great_expectations
60eb81ebfb08fef5d37d55c316dc962928beb165
[ "Apache-2.0" ]
1
2022-03-03T16:47:32.000Z
2022-03-03T16:47:32.000Z
import logging from pathlib import Path from typing import List, Optional from great_expectations.datasource.data_connector.asset import Asset from great_expectations.datasource.data_connector.configured_asset_file_path_data_connector import ( ConfiguredAssetFilePathDataConnector, ) from great_expectations.datasou...
41.75
130
0.69568
4a275af21d78e08a2e03aebd9e2c2fa65929698f
7,368
py
Python
src/repair/project.py
violetbingzhe/angelix
511c701a51522c0fceded153a9ec71a3695f8720
[ "MIT" ]
89
2016-02-19T10:11:47.000Z
2022-03-30T17:04:31.000Z
src/repair/project.py
violetbingzhe/angelix
511c701a51522c0fceded153a9ec71a3695f8720
[ "MIT" ]
29
2016-03-24T12:55:42.000Z
2022-01-13T21:41:16.000Z
src/repair/project.py
violetbingzhe/angelix
511c701a51522c0fceded153a9ec71a3695f8720
[ "MIT" ]
38
2016-02-21T15:39:38.000Z
2022-03-18T02:33:33.000Z
import copy import difflib import os from os.path import join, exists, relpath, basename, realpath import shutil import subprocess import json from utils import cd import logging import tempfile import sys import re import statistics import time from transformation import PrintfTransformer logger = logging.getLogger(...
38.375
99
0.605592
4a275af5c3d2c609c38a4ef1ab8da66221596ed5
225
py
Python
gail_airl_ppo/network/__init__.py
tarawa/imitation
409abfba1f60bca507c44de562bed135cc9f348f
[ "MIT" ]
null
null
null
gail_airl_ppo/network/__init__.py
tarawa/imitation
409abfba1f60bca507c44de562bed135cc9f348f
[ "MIT" ]
null
null
null
gail_airl_ppo/network/__init__.py
tarawa/imitation
409abfba1f60bca507c44de562bed135cc9f348f
[ "MIT" ]
null
null
null
from .policy import StateDependentPolicy, StateIndependentPolicy from .value import StateFunction, StateActionFunction, TwinnedStateActionFunction from .disc import GAILDiscrim, AIRLDiscrim, WGAILDiscrim, WGAILDiscrim_notanh
56.25
81
0.88
4a275b8cf8f7d35c1c0d28dca053cee66cae7da3
1,308
py
Python
py/test/i18n/test_ui.py
arccode/factory
a1b0fccd68987d8cd9c89710adc3c04b868347ec
[ "BSD-3-Clause" ]
3
2022-01-06T16:52:52.000Z
2022-03-07T11:30:47.000Z
py/test/i18n/test_ui.py
arccode/factory
a1b0fccd68987d8cd9c89710adc3c04b868347ec
[ "BSD-3-Clause" ]
null
null
null
py/test/i18n/test_ui.py
arccode/factory
a1b0fccd68987d8cd9c89710adc3c04b868347ec
[ "BSD-3-Clause" ]
1
2021-10-24T01:47:22.000Z
2021-10-24T01:47:22.000Z
# Copyright 2017 The Chromium OS 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 for methods of creating i18n UIs.""" from cros.factory.test.i18n import translation def MakeI18nLabel(label): """Make an i18n label. Arg...
26.693878
79
0.646789
4a275b90c1639cabf4cd659fc51b6857ad4fb938
491
py
Python
env/lib/python3.8/site-packages/plotly/validators/indicator/gauge/axis/_showticklabels.py
acrucetta/Chicago_COVI_WebApp
a37c9f492a20dcd625f8647067394617988de913
[ "MIT", "Unlicense" ]
76
2020-07-06T14:44:05.000Z
2022-02-14T15:30:21.000Z
env/lib/python3.8/site-packages/plotly/validators/indicator/gauge/axis/_showticklabels.py
acrucetta/Chicago_COVI_WebApp
a37c9f492a20dcd625f8647067394617988de913
[ "MIT", "Unlicense" ]
11
2020-08-09T02:30:14.000Z
2022-03-12T00:50:14.000Z
env/lib/python3.8/site-packages/plotly/validators/indicator/gauge/axis/_showticklabels.py
acrucetta/Chicago_COVI_WebApp
a37c9f492a20dcd625f8647067394617988de913
[ "MIT", "Unlicense" ]
11
2020-07-12T16:18:07.000Z
2022-02-05T16:48:35.000Z
import _plotly_utils.basevalidators class ShowticklabelsValidator(_plotly_utils.basevalidators.BooleanValidator): def __init__( self, plotly_name="showticklabels", parent_name="indicator.gauge.axis", **kwargs ): super(ShowticklabelsValidator, self).__init__( plotly_name=plotly_name...
32.733333
88
0.655804
4a275c02f45d63d24f83857f778a60186fe1bf1c
19,661
py
Python
station_lmc.py
andreww5au/PaSD-client
5ed7ff3e8b529c440fbfecb8c3159516285496c4
[ "MIT" ]
null
null
null
station_lmc.py
andreww5au/PaSD-client
5ed7ff3e8b529c440fbfecb8c3159516285496c4
[ "MIT" ]
null
null
null
station_lmc.py
andreww5au/PaSD-client
5ed7ff3e8b529c440fbfecb8c3159516285496c4
[ "MIT" ]
null
null
null
#!/usr/bin/env python """ Manage a single PaSD station - control and monitor the hardware via Modbus commands to the specified IP address, and update the relevant tables in the PaSD database. Monitor the port state tables in that database, and send updated information as needed to the hardware in the field. """ impor...
48.90796
156
0.641676
4a275c46532f4459879f3d271d24bb8e70571c0f
874
py
Python
data_science_layer/preprocessing/log_tranformation.py
nathangeology/cyclist_dataset
44ad4a3765e86cba934bfdbfb151a788eddfbead
[ "MIT" ]
null
null
null
data_science_layer/preprocessing/log_tranformation.py
nathangeology/cyclist_dataset
44ad4a3765e86cba934bfdbfb151a788eddfbead
[ "MIT" ]
null
null
null
data_science_layer/preprocessing/log_tranformation.py
nathangeology/cyclist_dataset
44ad4a3765e86cba934bfdbfb151a788eddfbead
[ "MIT" ]
null
null
null
from data_science_layer.preprocessing.abstract_pre_processor import AbstractPreProcessor import pandas as pd import numpy as np class LogTransformation(AbstractPreProcessor): def fit_transform(self, data, y=None): return self._process_data(data=data) def fit(self, data, y=None): return None...
28.193548
88
0.661327
4a275ccb627103219fac829dcd23cad8a7cedfe1
50,319
py
Python
BtS/Assets/Python/CvAdvisorUtils.py
f1rpo/Civ4CE
ba64c3545b479887739ad0ff78605b51b6fa57f9
[ "CNRI-Python" ]
null
null
null
BtS/Assets/Python/CvAdvisorUtils.py
f1rpo/Civ4CE
ba64c3545b479887739ad0ff78605b51b6fa57f9
[ "CNRI-Python" ]
null
null
null
BtS/Assets/Python/CvAdvisorUtils.py
f1rpo/Civ4CE
ba64c3545b479887739ad0ff78605b51b6fa57f9
[ "CNRI-Python" ]
null
null
null
## Sid Meier's Civilization 4 ## Copyright Firaxis Games 2005 ## ## CvAdvisorUtils from CvPythonExtensions import * import PyHelpers gc = CyGlobalContext() localText = CyTranslator() PyPlayer = PyHelpers.PyPlayer g_iAdvisorNags = 0 g_listNoLiberateCities = [] def resetAdvisorNags(): global...
49.722332
284
0.717522
4a275d87c5dba78fd0df02729a0ea463a2fab4f1
1,661
py
Python
tests/test_app.py
mpdude/thumbor
21799d4731ed0901dcd85a3025f6836412333e09
[ "MIT" ]
5
2018-09-15T07:57:21.000Z
2019-06-04T08:02:10.000Z
tests/test_app.py
mpdude/thumbor
21799d4731ed0901dcd85a3025f6836412333e09
[ "MIT" ]
3
2020-12-02T15:23:46.000Z
2021-04-13T15:44:34.000Z
tests/test_app.py
mpdude/thumbor
21799d4731ed0901dcd85a3025f6836412333e09
[ "MIT" ]
1
2021-07-29T19:14:53.000Z
2021-07-29T19:14:53.000Z
#!/usr/bin/python # -*- coding: utf-8 -*- # thumbor imaging service # https://github.com/thumbor/thumbor/wiki # Licensed under the MIT license: # http://www.opensource.org/licenses/mit-license # Copyright (c) 2011 globo.com thumbor@googlegroups.com from unittest import TestCase import mock from preggy import expect...
25.166667
56
0.606863
4a275fb0ba26af2f5482c9cc1ac99ae55dfc23c1
1,802
py
Python
tools/localtest.py
kinsaurralde/lights
a9673188875dbd91bb8822c1920002a4f1c2ec5b
[ "MIT" ]
null
null
null
tools/localtest.py
kinsaurralde/lights
a9673188875dbd91bb8822c1920002a4f1c2ec5b
[ "MIT" ]
null
null
null
tools/localtest.py
kinsaurralde/lights
a9673188875dbd91bb8822c1920002a4f1c2ec5b
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 import argparse import time import subprocess import atexit try: import yaml # 3.6 except: import ruamel.yaml as yaml # 3.7 parser = argparse.ArgumentParser() parser.add_argument( "-c", "--config", type=str, help="Path to config file", default="configs/localtest.yaml", ) parser.ad...
26.895522
109
0.649279
4a27610c0609c773eb34ba47872dac473af206b3
5,146
py
Python
sure_tosca-client_python_stubs/test/test_default_api.py
QCDIS/CONF
6ddb37b691754bbba97c85228d266ac050c4baa4
[ "Apache-2.0" ]
null
null
null
sure_tosca-client_python_stubs/test/test_default_api.py
QCDIS/CONF
6ddb37b691754bbba97c85228d266ac050c4baa4
[ "Apache-2.0" ]
null
null
null
sure_tosca-client_python_stubs/test/test_default_api.py
QCDIS/CONF
6ddb37b691754bbba97c85228d266ac050c4baa4
[ "Apache-2.0" ]
1
2021-04-05T09:49:03.000Z
2021-04-05T09:49:03.000Z
# coding: utf-8 """ tosca-sure TOSCA Simple qUeRy sErvice (SURE). # noqa: E501 OpenAPI spec version: 1.0.0 Contact: S.Koulouzis@uva.nl Generated by: https://github.com/swagger-api/swagger-codegen.git """ from __future__ import absolute_import import os import unittest from io import BytesIO ...
24.859903
117
0.613875
4a2761da4dd15cbe9bc532b45c460627b5e3ae36
1,618
py
Python
gw_bot/lambdas/gw/store/create_api_gw_api_key.py
atykhonov/GW-Bot
fb1d8584f229efe703f05aa0e44fa0924b90ca1d
[ "Apache-2.0" ]
null
null
null
gw_bot/lambdas/gw/store/create_api_gw_api_key.py
atykhonov/GW-Bot
fb1d8584f229efe703f05aa0e44fa0924b90ca1d
[ "Apache-2.0" ]
null
null
null
gw_bot/lambdas/gw/store/create_api_gw_api_key.py
atykhonov/GW-Bot
fb1d8584f229efe703f05aa0e44fa0924b90ca1d
[ "Apache-2.0" ]
null
null
null
import uuid from gw_bot.helpers.Lambda_Helpers import log_to_elk from osbot_aws.apis.API_Gateway import API_Gateway def create_key_in_policy(policy_name, key_name): api_gateway = API_Gateway() usage_plan_id = api_gateway.usage_plan_id(policy_name) new_key = api_gateway.api_key_create(key_name) k...
37.627907
73
0.662546
4a2762d79be63aca2854e3b0444cb625fa1b88ff
2,603
py
Python
gym_modular/wrappers/flatten_wrapper.py
TimSchneider42/mbpo
736ba90bbdaddb2a40a6233bc0b78da72235100a
[ "MIT" ]
null
null
null
gym_modular/wrappers/flatten_wrapper.py
TimSchneider42/mbpo
736ba90bbdaddb2a40a6233bc0b78da72235100a
[ "MIT" ]
null
null
null
gym_modular/wrappers/flatten_wrapper.py
TimSchneider42/mbpo
736ba90bbdaddb2a40a6233bc0b78da72235100a
[ "MIT" ]
null
null
null
from typing import Dict, Tuple import gym import numpy as np from .dict_flattener import DictFlattener class FlattenWrapper(gym.Env): """ A wrapper for gym environments that converts gym.spaces.Dict observation and action spaces to gym.spaces.Box. Needed since stable-baselines3 does not support Dict spa...
34.706667
119
0.711103
4a2762f99d42099aee67604c2d8319f8894a7bd8
449
py
Python
Strings/2087.py
LorranSutter/URI-Online-Judge
aef885b9a7caa83484cf172e29eea8ec92fc3627
[ "MIT" ]
null
null
null
Strings/2087.py
LorranSutter/URI-Online-Judge
aef885b9a7caa83484cf172e29eea8ec92fc3627
[ "MIT" ]
null
null
null
Strings/2087.py
LorranSutter/URI-Online-Judge
aef885b9a7caa83484cf172e29eea8ec92fc3627
[ "MIT" ]
null
null
null
while True: N = int(input()) if N == 0: break P = [input() for k in range(N)] ruim = False l_p = len(P) for k in range(l_p): l = len(P[k]) for w in range(l_p): if k != w and l <= len(P[w]): if P[k] == P[w][:l]: ruim = True ...
22.45
41
0.405345
4a276430d0e74badc9536fb9a55652f79bc19854
2,778
py
Python
dipy/denoise/non_local_means.py
omarocegueda/dipy
520b724041116a958892bee0068b057314a21cb2
[ "MIT" ]
null
null
null
dipy/denoise/non_local_means.py
omarocegueda/dipy
520b724041116a958892bee0068b057314a21cb2
[ "MIT" ]
null
null
null
dipy/denoise/non_local_means.py
omarocegueda/dipy
520b724041116a958892bee0068b057314a21cb2
[ "MIT" ]
null
null
null
from __future__ import division, print_function import numpy as np from dipy.denoise.nlmeans_block import nlmeans_block def non_local_means(arr, sigma, mask=None, patch_radius=1, block_radius=5, rician=True): r""" Non-local means for denoising 3D and 4D images, using blockwise averagi...
34.296296
83
0.593593
4a27643b985835407da85a54bb4ee65b8a29d1fa
1,994
py
Python
dota_webscraper/client_interface.py
alexpickering/dota_webscraper
930c17f5563e6c778a820097517e7bb37e36bfe8
[ "MIT" ]
null
null
null
dota_webscraper/client_interface.py
alexpickering/dota_webscraper
930c17f5563e6c778a820097517e7bb37e36bfe8
[ "MIT" ]
null
null
null
dota_webscraper/client_interface.py
alexpickering/dota_webscraper
930c17f5563e6c778a820097517e7bb37e36bfe8
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """Prompts user input, parses into a dictionary of heroes and corresponding levels """ import json import os import re import sys from argparse import ArgumentParser from gooey import Gooey, GooeyParser def import_hero_list(): # import hardcoded hero_list hero...
24.617284
106
0.594784
4a27644dd7940449724b856c7cc589e4790fba54
1,516
pyde
Python
processing_visualizations/Voronoi_Whirl/Voronoi_Whirl.pyde
COLOR-SKY/RecursiveVoronoi
24d98298bfcf52a7938557dda491e9d2b3dc9616
[ "MIT" ]
3
2021-01-25T17:27:35.000Z
2022-03-22T12:07:16.000Z
processing_visualizations/Voronoi_Whirl/Voronoi_Whirl.pyde
COLOR-SKY/RecursiveVoronoi
24d98298bfcf52a7938557dda491e9d2b3dc9616
[ "MIT" ]
null
null
null
processing_visualizations/Voronoi_Whirl/Voronoi_Whirl.pyde
COLOR-SKY/RecursiveVoronoi
24d98298bfcf52a7938557dda491e9d2b3dc9616
[ "MIT" ]
null
null
null
""" Author: colorsky Date: 2020/01/20 """ import sys # Replace with your environment dir sys.path.append('/Python Project/venv_2.7/lib/python2.7/site-packages/') import requests def setup(): size(800, 800) def draw(): background(0) noFill() num_points = 10 seed = 999 mask_polygon = [[20, 20],...
27.071429
75
0.566623
4a2764e86e7ce34f8609ce47fdf27d7a5be482cf
54,206
bzl
Python
tensorflow/workspace2.bzl
vadimVoloshanov/tensorflow
15c4071f8c2422dec79c17e5294969f0fdbd22a3
[ "Apache-2.0" ]
1
2021-06-17T17:07:40.000Z
2021-06-17T17:07:40.000Z
tensorflow/workspace2.bzl
vadimVoloshanov/tensorflow
15c4071f8c2422dec79c17e5294969f0fdbd22a3
[ "Apache-2.0" ]
2
2021-11-10T20:10:39.000Z
2022-02-10T05:15:31.000Z
tensorflow/workspace2.bzl
vadimVoloshanov/tensorflow
15c4071f8c2422dec79c17e5294969f0fdbd22a3
[ "Apache-2.0" ]
1
2021-04-20T18:26:18.000Z
2021-04-20T18:26:18.000Z
"""TensorFlow workspace initialization. Consult the WORKSPACE on how to use it.""" # Import third party config rules. load("//tensorflow:version_check.bzl", "check_bazel_version_at_least") load("//third_party/gpus:cuda_configure.bzl", "cuda_configure") load("//third_party/gpus:rocm_configure.bzl", "rocm_configure") lo...
48.571685
203
0.689241
4a27656913c0f9fe243e4673f96884d10712e2c3
3,964
py
Python
data/process_data.py
dariusgm/disasterresponse
cd7b8f93ff769f0581cf7c541a1f85af7543d844
[ "MIT" ]
null
null
null
data/process_data.py
dariusgm/disasterresponse
cd7b8f93ff769f0581cf7c541a1f85af7543d844
[ "MIT" ]
null
null
null
data/process_data.py
dariusgm/disasterresponse
cd7b8f93ff769f0581cf7c541a1f85af7543d844
[ "MIT" ]
null
null
null
import sys import pandas as pd import os from sqlalchemy import create_engine import sys class ETLPipeline: def __init__(self, messages_path: str, categories_path: str, sql_path: str): self.messages_path = messages_path self.categories_path = categories_path self.sql_path = sql_path ...
35.711712
93
0.631181
4a276779e36901e75eeac835583a5f142b2b1684
529
py
Python
venv/Exercises/ex062.py
jonassignoreti/Python-CursoemVideo
24f5932bed2fe98308321be7dd9326e65a942d4b
[ "MIT" ]
null
null
null
venv/Exercises/ex062.py
jonassignoreti/Python-CursoemVideo
24f5932bed2fe98308321be7dd9326e65a942d4b
[ "MIT" ]
null
null
null
venv/Exercises/ex062.py
jonassignoreti/Python-CursoemVideo
24f5932bed2fe98308321be7dd9326e65a942d4b
[ "MIT" ]
null
null
null
'''Melhore o DESAFIO 61, perguntando para o usuário se ele quer mostrar mais alguns termos. O programa encerra quando ele disser que quer mostrar 0 termos''' print('{:=^100}'.format(' Os 10 PRIMEIROS TERMOS DE UMA PA ')) p = int(input('Primeiro Termo: ')) r = int(input('Razão: ')) cont = 1 meta = 10 while cont != (meta...
35.266667
91
0.618147
4a2767ee85dc1db1e563b89771c652a5a38621c1
4,785
py
Python
test/functional/wallet_importprunedfunds.py
btc20/bitcoin2.0
e7a54b00ebd0e8d20f4d5315cc9a21c77ded25cd
[ "MIT" ]
null
null
null
test/functional/wallet_importprunedfunds.py
btc20/bitcoin2.0
e7a54b00ebd0e8d20f4d5315cc9a21c77ded25cd
[ "MIT" ]
null
null
null
test/functional/wallet_importprunedfunds.py
btc20/bitcoin2.0
e7a54b00ebd0e8d20f4d5315cc9a21c77ded25cd
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # Copyright (c) 2014-2018 The Bitcoin Core developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. """Test the importprunedfunds and removeprunedfunds RPCs.""" from decimal import Decimal from test_framew...
40.550847
117
0.681714
4a2769d33c0836f6b6cbb7ac9cb3d013cb356e56
11,431
py
Python
tests/mdts/tests/functional_tests/test_nat_router.py
yantarou/midonet
11fea2549416588a9170f6ce872790ad907d2a4b
[ "Apache-2.0" ]
2
2018-08-29T01:36:17.000Z
2018-11-22T16:57:25.000Z
tests/mdts/tests/functional_tests/test_nat_router.py
yantarou/midonet
11fea2549416588a9170f6ce872790ad907d2a4b
[ "Apache-2.0" ]
8
2018-05-24T13:36:03.000Z
2021-02-19T16:01:43.000Z
tests/mdts/tests/functional_tests/test_nat_router.py
yantarou/midonet
11fea2549416588a9170f6ce872790ad907d2a4b
[ "Apache-2.0" ]
null
null
null
# Copyright 2014 Midokura SARL # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing...
38.35906
89
0.652786
4a276b388a829dc6aaa6cd8623f0bc929eed7ea1
85
py
Python
assignment1/admin.py
patilpriyankaco/assignment-django-1
577ab25c3d698132b082e107dffd25d0a1a50305
[ "MIT" ]
null
null
null
assignment1/admin.py
patilpriyankaco/assignment-django-1
577ab25c3d698132b082e107dffd25d0a1a50305
[ "MIT" ]
null
null
null
assignment1/admin.py
patilpriyankaco/assignment-django-1
577ab25c3d698132b082e107dffd25d0a1a50305
[ "MIT" ]
null
null
null
from django.contrib import admin from .models import Quote admin.site.register(Quote)
28.333333
32
0.835294
4a276c9f3a42863221612d9bd649385f40a3e39e
3,090
py
Python
managefunds/settings.py
chiraag-kakar/managefunds
bf768ef90bde06d1b7877b14765d48e858d971c8
[ "MIT" ]
1
2022-01-24T13:49:03.000Z
2022-01-24T13:49:03.000Z
managefunds/settings.py
chiraag-kakar/managefunds
bf768ef90bde06d1b7877b14765d48e858d971c8
[ "MIT" ]
null
null
null
managefunds/settings.py
chiraag-kakar/managefunds
bf768ef90bde06d1b7877b14765d48e858d971c8
[ "MIT" ]
null
null
null
""" Django settings for managefunds project. Generated by 'django-admin startproject' using Django 3.1.7. For more information on this file, see https://docs.djangoproject.com/en/3.1/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/3.1/ref/settings/ """ from pat...
25.327869
91
0.695793
4a276db1d093593755987b35ccb0eb1e337a0052
26,050
py
Python
parsl/providers/aws/aws.py
gerrick/parsl
820c43d2e893a016139692a23cd93f99cde5cc8d
[ "Apache-2.0" ]
1
2020-11-21T17:32:09.000Z
2020-11-21T17:32:09.000Z
parsl/providers/aws/aws.py
raffmont/parsl
2f843b903a9008d230d42734db48317a40a2ad8e
[ "Apache-2.0" ]
null
null
null
parsl/providers/aws/aws.py
raffmont/parsl
2f843b903a9008d230d42734db48317a40a2ad8e
[ "Apache-2.0" ]
1
2022-03-09T10:51:12.000Z
2022-03-09T10:51:12.000Z
import json import logging import os import time from string import Template from parsl.dataflow.error import ConfigurationError from parsl.providers.aws.template import template_string from parsl.providers.provider_base import ExecutionProvider, JobState, JobStatus from parsl.providers.error import OptionalModuleMiss...
36.950355
117
0.587946
4a276e343345dc34e2d63fa1702c14a2a72af94e
882
py
Python
test/iqdb_test.py
Coder-Sakura/PicImageSearch
f947d0aa5648f39763f35295e7d67b9ec2eecca8
[ "MIT" ]
null
null
null
test/iqdb_test.py
Coder-Sakura/PicImageSearch
f947d0aa5648f39763f35295e7d67b9ec2eecca8
[ "MIT" ]
null
null
null
test/iqdb_test.py
Coder-Sakura/PicImageSearch
f947d0aa5648f39763f35295e7d67b9ec2eecca8
[ "MIT" ]
null
null
null
from loguru import logger from PicImageSearch import Iqdb _REQUESTS_KWARGS = { # 'proxies': { # 'https': 'http://127.0.0.1:10809', # } # 如果需要代理 } iqdb = Iqdb() res = iqdb.search(r"https://pixiv.cat/77702503-1.jpg") # logger.info(res.origin) # logger.info(res.raw) logger.info("说明: " + ...
32.666667
59
0.599773
4a276ee4adc4fcd9270ec436ef97aa86b0ccbb73
1,610
py
Python
src/server/oasisapi/files/viewsets.py
cdlhub/OasisPlatform
b9e23448f9ddb18ba589081ee9f702f5c50c2b78
[ "BSD-3-Clause" ]
null
null
null
src/server/oasisapi/files/viewsets.py
cdlhub/OasisPlatform
b9e23448f9ddb18ba589081ee9f702f5c50c2b78
[ "BSD-3-Clause" ]
null
null
null
src/server/oasisapi/files/viewsets.py
cdlhub/OasisPlatform
b9e23448f9ddb18ba589081ee9f702f5c50c2b78
[ "BSD-3-Clause" ]
null
null
null
from __future__ import absolute_import from django.utils.translation import ugettext_lazy as _ from django_filters import rest_framework as filters from rest_framework import viewsets, mixins from rest_framework.decorators import action from rest_framework.parsers import MultiPartParser from rest_framework.settings im...
32.2
100
0.706832
4a276f0f99cc640529418675c4f3e4ca3341a700
1,707
py
Python
src/backup.py
jpatnayk/i3wm-themer
8e2a63c690b2b08b0ef47ca4ad9397d570c51fab
[ "MIT" ]
1
2020-02-05T10:51:55.000Z
2020-02-05T10:51:55.000Z
src/backup.py
jpatnayk/i3wm-themer
8e2a63c690b2b08b0ef47ca4ad9397d570c51fab
[ "MIT" ]
null
null
null
src/backup.py
jpatnayk/i3wm-themer
8e2a63c690b2b08b0ef47ca4ad9397d570c51fab
[ "MIT" ]
null
null
null
import os.path from shutil import copyfile import fileutils as fileu import msgfunc as prnt def backup_file( config, back_file, destination): if(fileu.locate_file(config[back_file])): prnt.prnt( '-s', 'Located your '+config[back_file]+' file!') try: copyfile( config[back_file], destina...
33.470588
96
0.561219
4a276f2b334e648d3bb1b0a7886ecfed56b79597
882
py
Python
darts/__init__.py
amadejkocbek/darts
074be2a76eee11258da066878c564badf40834e9
[ "Apache-2.0" ]
null
null
null
darts/__init__.py
amadejkocbek/darts
074be2a76eee11258da066878c564badf40834e9
[ "Apache-2.0" ]
42
2021-10-04T17:11:50.000Z
2021-12-24T15:37:41.000Z
darts/__init__.py
amadejkocbek/darts
074be2a76eee11258da066878c564badf40834e9
[ "Apache-2.0" ]
null
null
null
""" darts ----- """ from .timeseries import TimeSeries, concatenate import matplotlib as mpl from matplotlib import cycler __version__ = "0.16.0" colors = cycler( color=["black", "003DFD", "b512b8", "11a9ba", "0d780f", "f77f07", "ba0f0f"] ) u8plots_mplstyle = { "font.family": "sans serif", "axes.edgeco...
21.512195
79
0.622449
4a276fae313692800c347880b9d90906557fa7a6
27,434
py
Python
src/graphepp/graphepp.py
jwallnoefer/graphepp
684b683d84ce8ccfb5c809e5aa3f4f1acb0f7048
[ "MIT" ]
null
null
null
src/graphepp/graphepp.py
jwallnoefer/graphepp
684b683d84ce8ccfb5c809e5aa3f4f1acb0f7048
[ "MIT" ]
null
null
null
src/graphepp/graphepp.py
jwallnoefer/graphepp
684b683d84ce8ccfb5c809e5aa3f4f1acb0f7048
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """Functions for multiparite entanglement purification on graph states. See README.md for an overview of the functionality. """ # All states are assumed to be diagonal in the graph state basis corresponding to # the graph state considered. # The noise should work for arbitrary graph states, whi...
29.690476
87
0.609645
4a27702a5d1fe3100025cc44bc4dcd2e38f79cc4
606
py
Python
src/statistics/dataset/utils.py
VincentXWD/CopyGirlsMoe
779838ad89d7def99ec74985919bcb0feaa6736c
[ "MIT" ]
68
2018-06-21T08:33:14.000Z
2019-12-05T13:31:13.000Z
src/statistics/dataset/utils.py
VincentXWD/CopyGirlsMoe
779838ad89d7def99ec74985919bcb0feaa6736c
[ "MIT" ]
5
2018-06-25T13:34:13.000Z
2019-09-19T11:42:33.000Z
src/statistics/dataset/utils.py
VincentXWD/CopyGirlsMoe
779838ad89d7def99ec74985919bcb0feaa6736c
[ "MIT" ]
11
2018-06-25T10:44:20.000Z
2019-10-08T12:14:55.000Z
__author__ = 'Wendong Xu' import os import re def get_image_path(raw_input_dir: str) -> list: """ get image path and id from root resource path. :return: a list contains all images' path. """ result = [] for root, dirs, files in os.walk(raw_input_dir): for file in files: result.append(os.path.jo...
20.2
62
0.665017
4a277032db9f6effd081629317aa01dd2b7dbc91
137,925
py
Python
datasets/multi_eurlex/multi_eurlex.py
WojciechKusa/datasets
1406a04c3e911cec2680d8bc513653e0cafcaaa4
[ "Apache-2.0" ]
10,608
2020-09-10T15:47:50.000Z
2022-03-31T22:51:47.000Z
datasets/multi_eurlex/multi_eurlex.py
realChainLife/datasets
98261e8b0b7be4dbaaa71ae188b950f7fbe51bbd
[ "Apache-2.0" ]
2,396
2020-09-10T14:55:31.000Z
2022-03-31T19:41:04.000Z
datasets/multi_eurlex/multi_eurlex.py
realChainLife/datasets
98261e8b0b7be4dbaaa71ae188b950f7fbe51bbd
[ "Apache-2.0" ]
1,530
2020-09-10T21:43:10.000Z
2022-03-31T01:59:12.000Z
# coding=utf-8 # Copyright 2020 The HuggingFace Datasets Authors and the current dataset script contributor. # # 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/lice...
16.609465
106
0.273736
4a2770aa34f9b4617811e836a5182a9d833a1fe3
68
py
Python
userplugins/AlphaMusic.py
AlphaEliasPY/VC-Bot-
088f8efcb70dab24f32349dcc52557786905382a
[ "MIT" ]
2
2021-08-28T10:36:27.000Z
2022-02-03T16:48:38.000Z
userplugins/AlphaMusic.py
AlphaEliasPY/VC-Bot-
088f8efcb70dab24f32349dcc52557786905382a
[ "MIT" ]
null
null
null
userplugins/AlphaMusic.py
AlphaEliasPY/VC-Bot-
088f8efcb70dab24f32349dcc52557786905382a
[ "MIT" ]
9
2021-08-25T07:27:08.000Z
2022-02-07T15:06:31.000Z
from utils import * from config import * from userplugins import *
13.6
25
0.764706
4a27713d43da514894f4cdf99c5a88ad364f75b9
5,400
py
Python
src/poetry/console/commands/install.py
ycechungAI/poetry
feb11b133af2e94d6c5239decb4e614426f2a299
[ "MIT" ]
null
null
null
src/poetry/console/commands/install.py
ycechungAI/poetry
feb11b133af2e94d6c5239decb4e614426f2a299
[ "MIT" ]
null
null
null
src/poetry/console/commands/install.py
ycechungAI/poetry
feb11b133af2e94d6c5239decb4e614426f2a299
[ "MIT" ]
null
null
null
from __future__ import annotations from cleo.helpers import option from poetry.console.commands.installer_command import InstallerCommand class InstallCommand(InstallerCommand): name = "install" description = "Installs the project dependencies." options = [ *InstallerCommand._group_dependency_...
32.727273
90
0.567037
4a277261a9eb3732f175b0d053d0bd8f2de98e5c
428
py
Python
myapp/migrations/0012_form_action.py
sharmin6630/Project-Distribution
32692653c309b417187ab0299f074a38d1a5bd3e
[ "MIT" ]
null
null
null
myapp/migrations/0012_form_action.py
sharmin6630/Project-Distribution
32692653c309b417187ab0299f074a38d1a5bd3e
[ "MIT" ]
1
2021-08-04T15:41:05.000Z
2021-08-04T15:41:05.000Z
myapp/migrations/0012_form_action.py
sharmin6630/Project-Distribution
32692653c309b417187ab0299f074a38d1a5bd3e
[ "MIT" ]
null
null
null
# Generated by Django 3.0.5 on 2021-06-26 00:55 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('myapp', '0011_form_assigned_supervisor_id'), ] operations = [ migrations.AddField( model_name='form', name='action',...
22.526316
89
0.61215
4a2773671dd150f445e8246b9beaf67905695aed
1,166
py
Python
pype/hosts/maya/plugins/publish/validate_mesh_non_manifold.py
simonebarbieri/pype
a6dc83aa1300738749cbe8e5e2e6d2d1794e0289
[ "MIT" ]
null
null
null
pype/hosts/maya/plugins/publish/validate_mesh_non_manifold.py
simonebarbieri/pype
a6dc83aa1300738749cbe8e5e2e6d2d1794e0289
[ "MIT" ]
null
null
null
pype/hosts/maya/plugins/publish/validate_mesh_non_manifold.py
simonebarbieri/pype
a6dc83aa1300738749cbe8e5e2e6d2d1794e0289
[ "MIT" ]
null
null
null
from maya import cmds import pyblish.api import pype.api import pype.hosts.maya.api.action class ValidateMeshNonManifold(pyblish.api.Validator): """Ensure that meshes don't have non-manifold edges or vertices To debug the problem on the meshes you can use Maya's modeling tool: "Mesh > Cleanup..." "...
27.116279
67
0.633791
4a27741b0fbb9c6c3548bc5de26bfc581ec23821
1,871
py
Python
python/MultiChannelBuildTool.py
SteamedBunZL/AndroidUtilByZFT
cecb7a165946babb29bb8bd2a8ead9fde8e60043
[ "Apache-2.0" ]
null
null
null
python/MultiChannelBuildTool.py
SteamedBunZL/AndroidUtilByZFT
cecb7a165946babb29bb8bd2a8ead9fde8e60043
[ "Apache-2.0" ]
null
null
null
python/MultiChannelBuildTool.py
SteamedBunZL/AndroidUtilByZFT
cecb7a165946babb29bb8bd2a8ead9fde8e60043
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 import zipfile import shutil import os import time #获取系统时间 def gainDateTime(): return time.strftime("%Y-%m-%d %H:%M:%S",time.localtime(time.time())) # 空文件 便于写入此空文件到apk包中作为channel文件 src_empty_file = 'info/chennel_empty.txt' # 创建一个空文件(不存在则创建) f = open(src_empty_file, 'w') f.close() # 获取当前目录中所有的apk源包...
28.784615
94
0.652058
4a2775cf59a76cd2573df4e50121c9a7d418a82d
928
py
Python
filibuster/logger/__init__.py
filibuster-testing/filibuster
b1df9d5100f8dbfc5ff07cd2ddc76ecbc49485fb
[ "Apache-2.0" ]
14
2021-10-16T21:49:14.000Z
2022-03-26T23:02:12.000Z
filibuster/logger/__init__.py
filibuster-testing/filibuster
b1df9d5100f8dbfc5ff07cd2ddc76ecbc49485fb
[ "Apache-2.0" ]
2
2022-03-17T05:48:04.000Z
2022-03-24T02:13:38.000Z
filibuster/logger/__init__.py
filibuster-testing/filibuster
b1df9d5100f8dbfc5ff07cd2ddc76ecbc49485fb
[ "Apache-2.0" ]
null
null
null
import os import sys class BColors: HEADER = '\033[95m' OKBLUE = '\033[94m' OKCYAN = '\033[96m' OKGREEN = '\033[92m' WARNING = '\033[93m' FAIL = '\033[91m' ENDC = '\033[0m' BOLD = '\033[1m' UNDERLINE = '\033[4m' def error(string): print(BColors.FAIL + "[FILIBUSTER] [FAIL]: " ...
25.777778
109
0.630388
4a2775d9bb62ccdf7b838610ae2f4036d0921077
445
py
Python
djangocon_2020/site/templatetags/markdown_extras.py
thibaudcolas/2021.djangocon.eu
7b2b4de2105f4c31369081f14c9777727a73244f
[ "MIT" ]
4
2021-04-29T22:11:39.000Z
2022-03-20T20:26:29.000Z
djangocon_2020/site/templatetags/markdown_extras.py
thibaudcolas/2021.djangocon.eu
7b2b4de2105f4c31369081f14c9777727a73244f
[ "MIT" ]
14
2022-03-09T16:30:03.000Z
2022-03-31T08:43:07.000Z
pycon_portugal_2022/site/templatetags/markdown_extras.py
pyconpt/2022
33019223a6138edfde0e23722cd054cdd1ad22c4
[ "MIT" ]
6
2021-03-12T09:48:38.000Z
2021-05-22T22:06:39.000Z
from django import template from django.template.defaultfilters import stringfilter import markdown as md register = template.Library() @register.filter() @stringfilter def markdown(value): r = {} f = open(value, 'r') f = f.read() m = md.Markdown(extensions = [ 'extra', 'nl2br', ...
17.8
55
0.570787
4a2775eb9108f09c34d5a6bed2449ee5a0bbecc1
47,982
py
Python
src/quadruped/quadruped/RL/gymVrka/gym_vrka/envs/vrka.py
BitsRobocon/AutonomousQuadruped
980d4a568c73c98093839f372e0db0193f51bb1d
[ "Apache-2.0" ]
null
null
null
src/quadruped/quadruped/RL/gymVrka/gym_vrka/envs/vrka.py
BitsRobocon/AutonomousQuadruped
980d4a568c73c98093839f372e0db0193f51bb1d
[ "Apache-2.0" ]
null
null
null
src/quadruped/quadruped/RL/gymVrka/gym_vrka/envs/vrka.py
BitsRobocon/AutonomousQuadruped
980d4a568c73c98093839f372e0db0193f51bb1d
[ "Apache-2.0" ]
null
null
null
""" CODE BASED ON EXAMPLE FROM: @misc{coumans2017pybullet, title={Pybullet, a python module for physics simulation in robotics, games and machine learning}, author={Coumans, Erwin and Bai, Yunfei}, url={www.pybullet.org}, year={2017}, } Example: minitaur.py https://github.com/bulletphysics/bullet3/blob/master/e...
42.424403
107
0.611208
4a2776c9d6a8bafe28dd7d343285d29019467a3d
3,909
py
Python
src/gesture_api.py
ShikharJ/Gestures-Alive
2a8c8a36400c3a7778c00fd76159a64f3a49a1e9
[ "BSD-3-Clause" ]
4
2017-12-28T20:26:51.000Z
2021-08-06T11:57:41.000Z
src/gesture_api.py
ShikharJ/Gestures-Alive
2a8c8a36400c3a7778c00fd76159a64f3a49a1e9
[ "BSD-3-Clause" ]
null
null
null
src/gesture_api.py
ShikharJ/Gestures-Alive
2a8c8a36400c3a7778c00fd76159a64f3a49a1e9
[ "BSD-3-Clause" ]
3
2019-02-22T18:52:14.000Z
2019-08-23T06:31:45.000Z
import numpy import math class Gesture(object): def __init__(self, name): self.name = name def get_name(self): return self.name def set_palm(self, hand_center, hand_radius): self.hand_center = hand_center self.hand_radius = hand_radius def set_finger_position(self, ...
36.877358
184
0.59913
4a277804f7a900ea1516bf5d0d530eab40f68a7c
2,700
py
Python
imu_test.py
anacsousa1/footLifter
df23db98759da66c874600651957e18b2416e676
[ "Apache-2.0" ]
null
null
null
imu_test.py
anacsousa1/footLifter
df23db98759da66c874600651957e18b2416e676
[ "Apache-2.0" ]
null
null
null
imu_test.py
anacsousa1/footLifter
df23db98759da66c874600651957e18b2416e676
[ "Apache-2.0" ]
null
null
null
# ###################################################################################################################### # ## imu_test.py # ## Description: testing the IMU # ## - We test the connection and print the pitch angle. # ## Library needed: imu, time, math, serial, sys libraries # ## Python inte...
31.764706
120
0.584444
4a27781bf259e265f2fcf3d32a578706cc732b31
1,523
py
Python
stonesoup/feeder/filter.py
dlast-dstl/Stone-Soup
033254add5adc00097b746f81d6640308a3e3319
[ "MIT" ]
1
2021-04-13T11:47:42.000Z
2021-04-13T11:47:42.000Z
stonesoup/feeder/filter.py
dlast-dstl/Stone-Soup
033254add5adc00097b746f81d6640308a3e3319
[ "MIT" ]
null
null
null
stonesoup/feeder/filter.py
dlast-dstl/Stone-Soup
033254add5adc00097b746f81d6640308a3e3319
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from operator import attrgetter from ..base import Property from .base import Feeder class MetadataReducer(Feeder): """Reduce detections so unique metadata value present at each time step. This allows to reduce detections so a single detection is returned, based on a particular m...
34.613636
77
0.633618
4a27787bd23387a673e48299f1c4b348941da986
34,525
py
Python
docs/3.0.0/_downloads/tutorial.py
sadielbartholomew/cf-python
98541d8e55c703eca9bfba4168fb3d42755267da
[ "MIT" ]
49
2019-10-08T12:46:39.000Z
2022-02-06T01:13:30.000Z
docs/3.0.0/_downloads/tutorial.py
sadielbartholomew/cf-python
98541d8e55c703eca9bfba4168fb3d42755267da
[ "MIT" ]
279
2019-10-07T11:14:37.000Z
2022-03-31T13:46:37.000Z
docs/3.0.0/_downloads/tutorial.py
sadielbartholomew/cf-python
98541d8e55c703eca9bfba4168fb3d42755267da
[ "MIT" ]
14
2019-10-25T08:54:06.000Z
2022-01-31T10:42:39.000Z
print("\n**Tutorial**\n") print("\n**Sample datasets**\n") print("\n**Import**\n") import cf cf.CF() print("\n**Field construct**\n") print("\n**Reading field constructs from datasets**\n") x = cf.read('file.nc') type(x) len(x) y = cf.read('*.nc') len(y) z = cf.read(['file.nc', 'precipitation_flux.nc']) len(z...
27.400794
95
0.656799
4a27790d060559740bc7576e9deaba8d430efab6
1,083
py
Python
api/logger.py
IFRCGo/go-api
6acd84df479f0cf46553029ababa1e7753f86550
[ "MIT" ]
11
2018-06-11T06:05:12.000Z
2022-03-25T09:31:44.000Z
api/logger.py
IFRCGo/go-api
6acd84df479f0cf46553029ababa1e7753f86550
[ "MIT" ]
498
2017-11-07T21:20:13.000Z
2022-03-31T14:37:18.000Z
api/logger.py
IFRCGo/go-api
6acd84df479f0cf46553029ababa1e7753f86550
[ "MIT" ]
6
2018-04-11T13:29:50.000Z
2020-07-16T16:52:11.000Z
import logging import sys import os from azure_storage_logging.handlers import BlobStorageTimedRotatingFileHandler as storage formatter = logging.Formatter(fmt='%(asctime)s %(levelname)-8s %(message)s', datefmt='%Y-%m-%d %H:%M:%S') screen_handler = logging.StreamHandler(stream=sys.stdout...
36.1
89
0.636196
4a27797083dfc1ed62152cbbd9ac1da9b521bc15
562
py
Python
Wrappers/Python/Testing/Functions/loadSBML.py
gregmedlock/roadrunnerwork
11f18f78ef3e381bc59c546a8d5e3ed46d8ab596
[ "Apache-2.0" ]
null
null
null
Wrappers/Python/Testing/Functions/loadSBML.py
gregmedlock/roadrunnerwork
11f18f78ef3e381bc59c546a8d5e3ed46d8ab596
[ "Apache-2.0" ]
null
null
null
Wrappers/Python/Testing/Functions/loadSBML.py
gregmedlock/roadrunnerwork
11f18f78ef3e381bc59c546a8d5e3ed46d8ab596
[ "Apache-2.0" ]
null
null
null
import rrPython import os import csv os.chdir('C:\\RoadRunner\\bin') function = 'loadSBML' file = open('C:\\RoadRunner\\Models\\feedback.xml','r').read() #rrPython.loadSBML(file) try: sbml = rrPython.loadSBML(file) if str(sbml) is not False: result = 'True' else: result = 'Fa...
23.416667
70
0.654804
4a27797eb2a704f0036582dbcb245ae770e1b82d
291
py
Python
lexrank/mappings/stopwords.py
Berndzz/lexrank
07bdd1579c408cf73cc822da303734d0a70cf3f7
[ "MIT" ]
99
2018-11-01T08:05:48.000Z
2022-03-09T17:45:07.000Z
lexrank/mappings/stopwords.py
Berndzz/lexrank
07bdd1579c408cf73cc822da303734d0a70cf3f7
[ "MIT" ]
4
2020-02-27T14:16:25.000Z
2022-02-16T14:38:49.000Z
lexrank/mappings/stopwords.py
Berndzz/lexrank
07bdd1579c408cf73cc822da303734d0a70cf3f7
[ "MIT" ]
33
2018-12-19T05:08:34.000Z
2022-02-09T17:29:52.000Z
import gzip import json from lexrank import settings file = settings.ASSETS_ROOT / 'stopwords.json.gz' with gzip.open(file, mode='rt', encoding='utf-8') as fp: _STOPWORDS = json.load(fp) STOPWORDS = {} for lang, stopwords in _STOPWORDS.items(): STOPWORDS[lang] = set(stopwords)
19.4
56
0.714777
4a27798ba3251ce8d5186df588c15db1b2904d7d
638
py
Python
decorator/annotation.py
guwenbo/DesignPattern-Python
3b7228595e9dd6ae5cb0df06b2b8a74ce2d774a9
[ "Apache-2.0" ]
null
null
null
decorator/annotation.py
guwenbo/DesignPattern-Python
3b7228595e9dd6ae5cb0df06b2b8a74ce2d774a9
[ "Apache-2.0" ]
null
null
null
decorator/annotation.py
guwenbo/DesignPattern-Python
3b7228595e9dd6ae5cb0df06b2b8a74ce2d774a9
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ 装饰器模式 (基于注解) """ from functools import wraps from datetime import datetime import time def decorate(func): @wraps(func) def wrapper(*args, **kwargs): begin = datetime.now() result = func(*args, **kwargs) end = datetime.now() ...
18.228571
95
0.595611
4a277a1412d025076b481251f5f043cfe0fbc5be
2,510
py
Python
simpleblog/models.py
jchoude/django-simple-blog
1081496ed0210691e27eab5c9ee3917ed08ebf7f
[ "BSD-2-Clause" ]
null
null
null
simpleblog/models.py
jchoude/django-simple-blog
1081496ed0210691e27eab5c9ee3917ed08ebf7f
[ "BSD-2-Clause" ]
null
null
null
simpleblog/models.py
jchoude/django-simple-blog
1081496ed0210691e27eab5c9ee3917ed08ebf7f
[ "BSD-2-Clause" ]
null
null
null
from __future__ import unicode_literals from django.conf import settings from django.core.urlresolvers import reverse from django.db import models from django.db.models.signals import post_save from django.utils.encoding import python_2_unicode_compatible from django.utils.translation import ugettext_lazy as _ from ....
32.597403
76
0.679283
4a277a3496b5bed9ed845782fca7b51080c30a17
6,045
py
Python
testscripts/RDKB/component/WIFIHAL/TS_WIFIHAL_5GHzGetApName.py
rdkcmf/rdkb-tools-tdkb
9f9c3600cd701d5fc90ac86a6394ebd28d49267e
[ "Apache-2.0" ]
null
null
null
testscripts/RDKB/component/WIFIHAL/TS_WIFIHAL_5GHzGetApName.py
rdkcmf/rdkb-tools-tdkb
9f9c3600cd701d5fc90ac86a6394ebd28d49267e
[ "Apache-2.0" ]
null
null
null
testscripts/RDKB/component/WIFIHAL/TS_WIFIHAL_5GHzGetApName.py
rdkcmf/rdkb-tools-tdkb
9f9c3600cd701d5fc90ac86a6394ebd28d49267e
[ "Apache-2.0" ]
null
null
null
########################################################################## # If not stated otherwise in this file or this component's Licenses.txt # file the following copyright and licenses apply: # # Copyright 2018 RDK Management # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use th...
39.509804
157
0.722746
4a277b1ddb3f786b5b077f938f37f6835c2cab55
1,168
py
Python
test2.py
ragulkesavan/Hand-Cricket
216822fa3a0d361bdd41d55b104b63664510d753
[ "MIT" ]
null
null
null
test2.py
ragulkesavan/Hand-Cricket
216822fa3a0d361bdd41d55b104b63664510d753
[ "MIT" ]
null
null
null
test2.py
ragulkesavan/Hand-Cricket
216822fa3a0d361bdd41d55b104b63664510d753
[ "MIT" ]
null
null
null
import cv2 # Camera 0 is the integrated web cam on my netbook camera_port = 0 # Number of frames to throw away while the camera adjusts to light levels ramp_frames = 30 # Now we can initialize the camera capture object with the cv2.VideoCapture class. # All it needs is the index to a camera port. camera = cv2.VideoC...
33.371429
82
0.755137
4a277b503c91c73bd2e8f935c9a849cffc1db871
1,327
py
Python
lib/ult/config.py
DirtyHarryLYL/DJ-RN
7f362693f433d49e2fb5c0fc6216218d464c612b
[ "Apache-2.0" ]
96
2020-03-07T09:23:56.000Z
2022-01-05T08:31:59.000Z
lib/ult/config.py
DirtyHarryLYL/DJ-RN
7f362693f433d49e2fb5c0fc6216218d464c612b
[ "Apache-2.0" ]
71
2020-04-21T07:25:51.000Z
2022-03-01T12:17:06.000Z
lib/ult/config.py
DirtyHarryLYL/DJ-RN
7f362693f433d49e2fb5c0fc6216218d464c612b
[ "Apache-2.0" ]
14
2020-04-20T08:53:10.000Z
2022-02-27T05:24:23.000Z
from __future__ import absolute_import from __future__ import division from __future__ import print_function import os import os.path as osp import numpy as np from easydict import EasyDict as edict __C = edict() cfg = __C __C.TRAIN = edict() __C.TRAIN_MODULE = 1 __C.TRAIN_MODULE_UPDATE = 1 __C.TRAIN_INIT_WEIGHT =...
26.019608
71
0.750565
4a277b62376927e17c525ee41b8fd28efd110544
163
py
Python
python/gen_randon_lst.py
torao-1892/testes
0452283355533ee68de0e84ad7d48c1aed03571c
[ "MIT" ]
null
null
null
python/gen_randon_lst.py
torao-1892/testes
0452283355533ee68de0e84ad7d48c1aed03571c
[ "MIT" ]
null
null
null
python/gen_randon_lst.py
torao-1892/testes
0452283355533ee68de0e84ad7d48c1aed03571c
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 import random num = 1 count = 0 while count < 1000: num = random.randint(1, 100000) print("BRI %03d" % num) count = count + 1
14.818182
35
0.613497
4a277bde34da8915fd8213c0bb37099246d3b91e
1,187
py
Python
hwt/hdl/types/integerCast.py
mgielda/hwt
e6c699fb154f93ac03523bfe40a3d4fc1912d28b
[ "MIT" ]
null
null
null
hwt/hdl/types/integerCast.py
mgielda/hwt
e6c699fb154f93ac03523bfe40a3d4fc1912d28b
[ "MIT" ]
null
null
null
hwt/hdl/types/integerCast.py
mgielda/hwt
e6c699fb154f93ac03523bfe40a3d4fc1912d28b
[ "MIT" ]
null
null
null
from hwt.hdl.operator import Operator from hwt.hdl.operatorDefs import AllOps from hwt.hdl.types.bits import Bits from hwt.hdl.types.boolVal import HBoolVal from hwt.hdl.types.defs import BOOL from hwt.hdl.types.hdlType import default_auto_cast_fn from hwt.hdl.value import Value from hwt.doc_markers import internal @i...
31.236842
73
0.604886
4a277be7714bdaa880c567474e8f5b5f484959de
6,780
py
Python
tools/train.py
LRY89757/mmdetection
8cd89a678fbde6c37eda3fa32af58b7b398abe41
[ "Apache-2.0" ]
2
2021-11-29T09:21:35.000Z
2021-12-19T10:14:32.000Z
tools/train.py
LRY89757/mmdetection
8cd89a678fbde6c37eda3fa32af58b7b398abe41
[ "Apache-2.0" ]
null
null
null
tools/train.py
LRY89757/mmdetection
8cd89a678fbde6c37eda3fa32af58b7b398abe41
[ "Apache-2.0" ]
null
null
null
# Copyright (c) OpenMMLab. All rights reserved. import argparse import copy import os import os.path as osp import time import warnings import mmcv import torch from mmcv import Config, DictAction from mmcv.runner import get_dist_info, init_dist from mmcv.utils import get_git_hash from mmdet import __version__ from m...
36.451613
79
0.652065
4a277c93788a707efe5c9ec2856ce8c6f9fc3dc0
856
py
Python
development/migrations/0059_auto_20170619_1150.py
stewardshiptools/stewardshiptools
ee5d27e7b0d5d4947f34ad02bdf63a06ad0a5c3e
[ "MIT" ]
null
null
null
development/migrations/0059_auto_20170619_1150.py
stewardshiptools/stewardshiptools
ee5d27e7b0d5d4947f34ad02bdf63a06ad0a5c3e
[ "MIT" ]
11
2020-03-24T15:29:46.000Z
2022-03-11T23:14:48.000Z
development/migrations/0059_auto_20170619_1150.py
stewardshiptools/stewardshiptools
ee5d27e7b0d5d4947f34ad02bdf63a06ad0a5c3e
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('development', '0058_delete_projectgroup'), ] operations = [ migrations.AlterModelOptions( ...
29.517241
140
0.641355
4a277c9a1db0d35aa294bbd4d51166b6a27a94f9
2,222
py
Python
tests/test_wsgi.py
ambrozic/http3
5442006a41f94a3e41186910d7a6e8546adf0f89
[ "BSD-3-Clause" ]
null
null
null
tests/test_wsgi.py
ambrozic/http3
5442006a41f94a3e41186910d7a6e8546adf0f89
[ "BSD-3-Clause" ]
null
null
null
tests/test_wsgi.py
ambrozic/http3
5442006a41f94a3e41186910d7a6e8546adf0f89
[ "BSD-3-Clause" ]
null
null
null
import sys import pytest import http3 def hello_world(environ, start_response): status = "200 OK" output = b"Hello, World!" response_headers = [ ("Content-type", "text/plain"), ("Content-Length", str(len(output))), ] start_response(status, response_headers) return [output]...
23.145833
70
0.645815
4a277d54479faf78b386d39381052129329ec959
1,446
py
Python
fields/validators.py
MilkBotttle/BFP
0753d8476b50a5b3342dc49b127712b545e417fd
[ "MIT" ]
null
null
null
fields/validators.py
MilkBotttle/BFP
0753d8476b50a5b3342dc49b127712b545e417fd
[ "MIT" ]
null
null
null
fields/validators.py
MilkBotttle/BFP
0753d8476b50a5b3342dc49b127712b545e417fd
[ "MIT" ]
null
null
null
import ipaddress from django.utils.translation import gettext_lazy as _, ngettext_lazy from django.core.exceptions import ValidationError def validate_ipv4_network(value): try: ipaddress.IPv4Network(value) except ValueError: raise ValidationError(_('Enter a valid IPv4 network.'), code='invalid'...
34.428571
91
0.690871
4a277e55a1170b50990d8a4af93e157163793224
6,599
py
Python
kali_extractor/kali_extractor/documents_processor.py
adipasquale/kali_dumps_scripts
3a340627169ba42c461fa914f68d7cc1f9458075
[ "Apache-2.0" ]
3
2019-09-12T06:44:17.000Z
2019-10-09T12:14:09.000Z
kali_extractor/kali_extractor/documents_processor.py
adipasquale/kali_dumps_scripts
3a340627169ba42c461fa914f68d7cc1f9458075
[ "Apache-2.0" ]
7
2019-01-16T16:25:32.000Z
2019-01-29T08:41:56.000Z
kali_extractor/kali_extractor/documents_processor.py
SocialGouv/kaligator
3a340627169ba42c461fa914f68d7cc1f9458075
[ "Apache-2.0" ]
2
2019-01-22T06:04:29.000Z
2019-01-23T07:49:30.000Z
from xml.etree import ElementTree import html from kali_extractor.custom_xml_parser import \ custom_xml_parser, custom_abdera_parser from kali_extractor.dict_utils import deep_get, deep_set class DocumentProcessor(object): def __init__( self, xml_path, html_fields=None, array_fields=None, **kwargs ...
35.67027
79
0.578421