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
7988ad5e953f9b71a6e3614fb9de4b553b7100b7
11,287
py
Python
beatmap_collections/models.py
Siraphop4Nene/beattosetto
78911428092c9c157c835e70d8abd4a08c48da8b
[ "MIT" ]
null
null
null
beatmap_collections/models.py
Siraphop4Nene/beattosetto
78911428092c9c157c835e70d8abd4a08c48da8b
[ "MIT" ]
14
2021-11-12T06:38:40.000Z
2022-03-09T02:25:47.000Z
beatmap_collections/models.py
Siraphop4Nene/beattosetto
78911428092c9c157c835e70d8abd4a08c48da8b
[ "MIT" ]
null
null
null
"""Models for the beatmap collections app.""" from django.db import models from django.core.validators import FileExtensionValidator from django.contrib.auth.models import User from PIL import Image from django.utils import timezone from taggit.managers import TaggableManager FALLBACK_USER_KEY = 1 class Collection(...
45.882114
121
0.682024
7988adcd116bd93c400492b550b44e6ab7e8d77a
1,302
py
Python
checkov/kubernetes/checks/ApiServerEncryptionProviders.py
kylelaker/checkov
6eada26030a87f397a6bf1831827b3dc6c5dad2d
[ "Apache-2.0" ]
5
2021-07-29T18:08:40.000Z
2022-03-21T04:39:32.000Z
checkov/kubernetes/checks/ApiServerEncryptionProviders.py
kylelaker/checkov
6eada26030a87f397a6bf1831827b3dc6c5dad2d
[ "Apache-2.0" ]
16
2021-03-09T07:38:38.000Z
2021-06-09T03:53:55.000Z
checkov/kubernetes/checks/ApiServerEncryptionProviders.py
kylelaker/checkov
6eada26030a87f397a6bf1831827b3dc6c5dad2d
[ "Apache-2.0" ]
2
2021-08-23T13:25:36.000Z
2021-11-05T21:44:52.000Z
from checkov.common.models.enums import CheckCategories, CheckResult from checkov.kubernetes.base_spec_check import BaseK8Check class ApiServerEncryptionProviders(BaseK8Check): def __init__(self): id = "CKV_K8S_104" name = "Ensure that encryption providers are appropriately configured" ca...
33.384615
104
0.588326
7988ae53e44bc1fd92489449202643d369491bcf
17,440
py
Python
tensorpack/train/trainers.py
qiuchenqqb/tp091
94446122fc3d592101518c615583e2c6396bfe97
[ "Apache-2.0" ]
null
null
null
tensorpack/train/trainers.py
qiuchenqqb/tp091
94446122fc3d592101518c615583e2c6396bfe97
[ "Apache-2.0" ]
null
null
null
tensorpack/train/trainers.py
qiuchenqqb/tp091
94446122fc3d592101518c615583e2c6396bfe97
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # File: trainers.py import multiprocessing as mp import os import sys import tensorflow as tf from ..callbacks import CallbackFactory, RunOp from ..graph_builder.distributed import DistributedParameterServerBuilder, DistributedReplicatedBuilder from ..graph_builder.training import ( AsyncM...
39.279279
120
0.659289
7988af8f77a085159899419e1b4d2eafae9c414f
396
py
Python
test.py
idaly666/Li-7000
7757e15906e3b26f6c02fda396a786208dc13c40
[ "FSFAP" ]
null
null
null
test.py
idaly666/Li-7000
7757e15906e3b26f6c02fda396a786208dc13c40
[ "FSFAP" ]
7
2016-10-06T07:34:40.000Z
2016-12-20T10:14:00.000Z
test.py
idaly666/Li-7000
7757e15906e3b26f6c02fda396a786208dc13c40
[ "FSFAP" ]
null
null
null
#!/usr/bin/python import time from class_li7000 import li7000 """ Assignments """ LI7000_USB = '/dev/ttyUSB2' baudrate = 115200 f1 = open('li7000.txt', 'a') """ Routine """ test = li7000('/dev/ttyUSB2', 115200) test.li7000_matchH2O() """while 1: units = raw_input("Key in units\n") h2o = input("key in h2o\n") ...
15.84
45
0.661616
7988b01af8c481ea19f0bf521110fda9d6fdbb41
28,803
py
Python
pandas/tseries/frequencies.py
clarkfitzg/pandas
a71ede374a019ea40321d8c1cfd13258b45ff58d
[ "PSF-2.0", "Apache-2.0", "BSD-2-Clause", "BSD-3-Clause" ]
1
2019-05-21T21:07:03.000Z
2019-05-21T21:07:03.000Z
pandas/tseries/frequencies.py
josericardo/pandas
fe9aa125c19ce2b22a0c4aabedd68b24df6cb98e
[ "PSF-2.0", "Apache-2.0", "BSD-2-Clause", "BSD-3-Clause" ]
null
null
null
pandas/tseries/frequencies.py
josericardo/pandas
fe9aa125c19ce2b22a0c4aabedd68b24df6cb98e
[ "PSF-2.0", "Apache-2.0", "BSD-2-Clause", "BSD-3-Clause" ]
null
null
null
from datetime import datetime from pandas.compat import range, long, zip from pandas import compat import re import numpy as np from pandas.core.algorithms import unique from pandas.tseries.offsets import DateOffset from pandas.util.decorators import cache_readonly import pandas.tseries.offsets as offsets import pand...
27.936954
116
0.553137
7988b07a8f4ea6f7408843416613d81f8a9ba05f
2,054
py
Python
postladim/cellcount.py
pnsaevik/ladim
967728b291631dd5a83cb0ee041770a0a9b08313
[ "MIT" ]
null
null
null
postladim/cellcount.py
pnsaevik/ladim
967728b291631dd5a83cb0ee041770a0a9b08313
[ "MIT" ]
null
null
null
postladim/cellcount.py
pnsaevik/ladim
967728b291631dd5a83cb0ee041770a0a9b08313
[ "MIT" ]
null
null
null
import numpy as np # type:ignore import xarray as xr # type: ignore from typing import Union, Optional, Tuple, List Array = Union[List[float], np.ndarray, xr.DataArray] Limits = Union[Tuple[int, int], Tuple[int, int, int, int]] def cellcount( X: Array, Y: Array, W: Optional[Array] = None, grid_limits: Optional...
29.342857
88
0.600779
7988b144098ad811867057d0eec48194749cfdb2
273
py
Python
CursoEmVideo/curso em video/ex63.py
elisio-ricardo/ExerciciosPythonCursoEmVideo
47a10b2118a76f4f95a762876ef9ab90e92f4fd3
[ "MIT" ]
null
null
null
CursoEmVideo/curso em video/ex63.py
elisio-ricardo/ExerciciosPythonCursoEmVideo
47a10b2118a76f4f95a762876ef9ab90e92f4fd3
[ "MIT" ]
null
null
null
CursoEmVideo/curso em video/ex63.py
elisio-ricardo/ExerciciosPythonCursoEmVideo
47a10b2118a76f4f95a762876ef9ab90e92f4fd3
[ "MIT" ]
null
null
null
print('Sequencia de fibonacci') n = int(input('quantos termos você quer mostrar? ')) t1 = 0 t2 = 1 print('{} - {}'.format(t1, t2), end= ' ') cont = 3 while cont <= n: t3 = t1 + t2 print('- {}'.format(t3),end=' ') t1 = t2 t2 = t3 cont += 1 print(' FIM')
19.5
52
0.527473
7988b1733df6e92d874963b506ebd0ec6fca6562
741
py
Python
src/sw/allotmentclub/alembic/versions/add_iban_and_bic_to_account_bookings_41e271c4e3e8.py
sweh/sw.allotmentclub.backend
77344045e29c2b173d635e9e20a0ca556161888e
[ "ZPL-2.1" ]
1
2019-11-12T08:13:18.000Z
2019-11-12T08:13:18.000Z
src/sw/allotmentclub/alembic/versions/add_iban_and_bic_to_account_bookings_41e271c4e3e8.py
sweh/sw.allotmentclub.backend
77344045e29c2b173d635e9e20a0ca556161888e
[ "ZPL-2.1" ]
26
2020-05-16T12:08:25.000Z
2022-03-12T00:53:57.000Z
src/sw/allotmentclub/alembic/versions/add_iban_and_bic_to_account_bookings_41e271c4e3e8.py
sweh/sw.allotmentclub.backend
77344045e29c2b173d635e9e20a0ca556161888e
[ "ZPL-2.1" ]
null
null
null
"""Add iban and bic to account bookings. Revision ID: 41e271c4e3e8 Revises: 411ca2f55194 Create Date: 2015-03-30 18:59:16.733989 """ # revision identifiers, used by Alembic. from alembic import op import sqlalchemy as sa revision = '41e271c4e3e8' down_revision = '411ca2f55194' def upgrade(): op.add_column( ...
23.903226
74
0.684211
7988b17fa77942fbfbbca16bec6e3e5587ea74e1
2,499
py
Python
mta-python/snag.py
availabs/gtfsr2siri
8f6c517c7cbbf7800ead3b84ee12892cb5ae696b
[ "MIT" ]
1
2017-06-22T05:32:35.000Z
2017-06-22T05:32:35.000Z
mta-python/snag.py
availabs/gtfsr2siri
8f6c517c7cbbf7800ead3b84ee12892cb5ae696b
[ "MIT" ]
null
null
null
mta-python/snag.py
availabs/gtfsr2siri
8f6c517c7cbbf7800ead3b84ee12892cb5ae696b
[ "MIT" ]
null
null
null
#!/usr/bin/env python import os, sys, json, sys, time, csv, urllib2, pymongo from rates import RateCalc sys.path.extend(['../protobuf-json-read-only','./pb']) import protobuf_json import nyct_subway_pb2 as nyct import gtfs_realtime_pb2 as gtfs from pymongo import MongoClient client = MongoClient('localhost',27017)...
28.724138
122
0.510204
7988b2d4f5687cd47e1ea737564f8d8ab4462bb2
1,567
py
Python
ethernet/[01] - ethernet_socket.py
stalyatech/upython-samples
1a28e09bef278532eda7a5ab1a80b3f80f525e63
[ "MIT" ]
null
null
null
ethernet/[01] - ethernet_socket.py
stalyatech/upython-samples
1a28e09bef278532eda7a5ab1a80b3f80f525e63
[ "MIT" ]
null
null
null
ethernet/[01] - ethernet_socket.py
stalyatech/upython-samples
1a28e09bef278532eda7a5ab1a80b3f80f525e63
[ "MIT" ]
1
2020-11-15T09:00:59.000Z
2020-11-15T09:00:59.000Z
import utime import usocket import network import _thread # --------------------------------------------------------------- # Ethernet based socket interface # --------------------------------------------------------------- # Configure the network interface card (Ethernet) nic = network.LAN() # ---------------------...
25.274194
72
0.539885
7988b34ee7e5343896841cb633444129c1632a72
1,620
py
Python
config/wsgi.py
joannne/aggregator
d13392ffe5f2885f93b8c817c2144c828a5ba68a
[ "BSD-3-Clause" ]
null
null
null
config/wsgi.py
joannne/aggregator
d13392ffe5f2885f93b8c817c2144c828a5ba68a
[ "BSD-3-Clause" ]
null
null
null
config/wsgi.py
joannne/aggregator
d13392ffe5f2885f93b8c817c2144c828a5ba68a
[ "BSD-3-Clause" ]
null
null
null
""" WSGI config for aggregator project. This module contains the WSGI application used by Django's development server and any production WSGI deployments. It should expose a module-level variable named ``application``. Django's ``runserver`` and ``runfcgi`` commands discover this application via the ``WSGI_APPLICATION...
41.538462
79
0.806173
7988b3560b85301ff2ebacac3a8e54cb399035b9
1,408
py
Python
app/core/models.py
alokKumarSingh89/recipe-app-api
91c8ce21ad10e9099b039deceb2ef8ecea084374
[ "MIT" ]
null
null
null
app/core/models.py
alokKumarSingh89/recipe-app-api
91c8ce21ad10e9099b039deceb2ef8ecea084374
[ "MIT" ]
null
null
null
app/core/models.py
alokKumarSingh89/recipe-app-api
91c8ce21ad10e9099b039deceb2ef8ecea084374
[ "MIT" ]
null
null
null
from django.db import models from django.contrib.auth.models import AbstractBaseUser, BaseUserManager, PermissionsMixin from django.conf import settings class UserManager(BaseUserManager): def create_user(self, email, password=None, **extra_field): """Create and Save user""" if not email: ...
30.608696
90
0.681818
7988b3e111e6fef4f940993cb066c609263a191e
22,402
py
Python
src/dispatch/plugins/dispatch_slack/commands.py
roor0/dispatch
12c4f567096411abe62abaf61c7c124496764346
[ "Apache-2.0" ]
null
null
null
src/dispatch/plugins/dispatch_slack/commands.py
roor0/dispatch
12c4f567096411abe62abaf61c7c124496764346
[ "Apache-2.0" ]
null
null
null
src/dispatch/plugins/dispatch_slack/commands.py
roor0/dispatch
12c4f567096411abe62abaf61c7c124496764346
[ "Apache-2.0" ]
null
null
null
import base64 import logging from typing import List from pydantic.error_wrappers import ErrorWrapper, ValidationError from pydantic.main import BaseModel from sqlalchemy.orm import Session from dispatch.exceptions import NotFoundError from dispatch.conversation import service as conversation_service from dispatch.c...
35.785942
141
0.633158
7988b4258e2e109034eca8786d491e5d8eb0b996
1,805
py
Python
python/infer_video.py
safdark/SDC-Semantic-Segmentation
36c92ebe53025d00065d3dffbd8d593c713583fe
[ "MIT" ]
null
null
null
python/infer_video.py
safdark/SDC-Semantic-Segmentation
36c92ebe53025d00065d3dffbd8d593c713583fe
[ "MIT" ]
null
null
null
python/infer_video.py
safdark/SDC-Semantic-Segmentation
36c92ebe53025d00065d3dffbd8d593c713583fe
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 import tensorflow as tf import input_utils import warnings from distutils.version import LooseVersion # Check TensorFlow Version assert LooseVersion(tf.__version__) >= LooseVersion('1.0'), 'Please use TensorFlow version 1.0 or newer. You are using {}'.format(tf.__version__) print('TensorFlow Ve...
34.711538
146
0.648753
7988b45294a359c2d5ac328412643bc5ab2e32f2
4,805
py
Python
release/scripts/addons_contrib/amaranth/animation/motion_paths.py
noorbeast/BlenderSource
65ebecc5108388965678b04b43463b85f6c69c1d
[ "Naumen", "Condor-1.1", "MS-PL" ]
3
2019-09-16T10:29:19.000Z
2022-02-11T14:43:18.000Z
engine/2.80/scripts/addons_contrib/amaranth/animation/motion_paths.py
byteinc/Phasor
f7d23a489c2b4bcc3c1961ac955926484ff8b8d9
[ "Unlicense" ]
null
null
null
engine/2.80/scripts/addons_contrib/amaranth/animation/motion_paths.py
byteinc/Phasor
f7d23a489c2b4bcc3c1961ac955926484ff8b8d9
[ "Unlicense" ]
1
2019-11-24T18:43:42.000Z
2019-11-24T18:43:42.000Z
# This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. # # This program is distributed in the hope that it will be useful,...
33.137931
89
0.682414
7988b4709fd471ae1ce99a8c9f496219b68f417a
8,232
py
Python
ppocr/utils/save_load.py
zhiminzhang0830/FCENet_Paddle
b39a8bf5d2ad76685634e94d997be43af0e15ece
[ "Apache-2.0" ]
2
2021-12-29T06:04:47.000Z
2022-01-25T11:10:26.000Z
ppocr/utils/save_load.py
zhiminzhang0830/FCENet_Paddle
b39a8bf5d2ad76685634e94d997be43af0e15ece
[ "Apache-2.0" ]
3
2021-12-31T06:55:47.000Z
2022-03-18T07:58:25.000Z
ppocr/utils/save_load.py
zhiminzhang0830/FCENet_Paddle
b39a8bf5d2ad76685634e94d997be43af0e15ece
[ "Apache-2.0" ]
null
null
null
# Copyright (c) 2020 PaddlePaddle Authors. All Rights Reserve. # # 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 applica...
39.768116
145
0.60605
7988b4a7b197cf9ebe10c8bb7835ecd9c4b071e0
169
py
Python
xarray/tests/conftest.py
jhamman/xarray-test-docs
c54123772817875678ec7ad769e6d4d6612aeb92
[ "Apache-2.0" ]
2,257
2016-01-06T01:52:47.000Z
2022-03-30T10:36:31.000Z
xarray/tests/conftest.py
jhamman/xarray-test-docs
c54123772817875678ec7ad769e6d4d6612aeb92
[ "Apache-2.0" ]
4,934
2016-01-05T00:06:37.000Z
2022-03-31T23:57:36.000Z
xarray/tests/conftest.py
jhamman/xarray-test-docs
c54123772817875678ec7ad769e6d4d6612aeb92
[ "Apache-2.0" ]
925
2016-01-07T12:18:45.000Z
2022-03-28T07:42:09.000Z
import pytest from . import requires_dask @pytest.fixture(params=["numpy", pytest.param("dask", marks=requires_dask)]) def backend(request): return request.param
18.777778
76
0.751479
7988b4a8071cf632e5ccb83b43908f3e23761c98
647
py
Python
examples/randomly_assemble_bricks_1_2.py
POSTECH-CVLab/Geometric-Primitives
e4b16d8930f4a9d1c906d06255988d02f54a6deb
[ "MIT" ]
1
2022-03-16T13:01:33.000Z
2022-03-16T13:01:33.000Z
examples/randomly_assemble_bricks_1_2.py
POSTECH-CVLab/Geometric-Primitives
e4b16d8930f4a9d1c906d06255988d02f54a6deb
[ "MIT" ]
null
null
null
examples/randomly_assemble_bricks_1_2.py
POSTECH-CVLab/Geometric-Primitives
e4b16d8930f4a9d1c906d06255988d02f54a6deb
[ "MIT" ]
null
null
null
import time import copy from geometric_primitives import brick from geometric_primitives import bricks from geometric_primitives import rules from geometric_primitives import utils_io from geometric_primitives import utils_meshes brick_ = brick.Brick(size_upper=[1, 2], size_lower=[1, 2]) brick_.set_position([0, 0, 0...
25.88
67
0.777434
7988b4ec9c219bba149dae959df1e2461da3bf4d
13,707
py
Python
lib/sqlalchemy/testing/assertsql.py
ewengillies/sqlalchemy
cbfa1363d7201848a56e7209146e81b9c51aa8af
[ "MIT" ]
6
2019-02-18T12:42:44.000Z
2020-11-11T23:10:17.000Z
lib/sqlalchemy/testing/assertsql.py
oladimejiala/sqlalchemy
cbfa1363d7201848a56e7209146e81b9c51aa8af
[ "MIT" ]
null
null
null
lib/sqlalchemy/testing/assertsql.py
oladimejiala/sqlalchemy
cbfa1363d7201848a56e7209146e81b9c51aa8af
[ "MIT" ]
2
2021-06-12T01:38:00.000Z
2021-09-05T21:18:29.000Z
# testing/assertsql.py # Copyright (C) 2005-2020 the SQLAlchemy authors and contributors # <see AUTHORS file> # # This module is part of SQLAlchemy and is released under # the MIT License: http://www.opensource.org/licenses/mit-license.php import collections import contextlib import re from .. import event from .. im...
32.176056
77
0.579266
7988b52da4f431b4e2146926c09c6ac3484ae2ff
33,629
py
Python
tests/forms_tests/tests/test_extra.py
AlexHill/django
fe1389e911b0cdc487e5547c09c920c12f4e1ce0
[ "BSD-3-Clause" ]
1
2017-02-21T09:06:04.000Z
2017-02-21T09:06:04.000Z
tests/forms_tests/tests/test_extra.py
amit2014/django
072e25eee70c0e629fcbb37f0485a6c6694b6856
[ "BSD-3-Clause" ]
null
null
null
tests/forms_tests/tests/test_extra.py
amit2014/django
072e25eee70c0e629fcbb37f0485a6c6694b6856
[ "BSD-3-Clause" ]
1
2020-12-24T01:28:30.000Z
2020-12-24T01:28:30.000Z
# -*- coding: utf-8 -*- from __future__ import unicode_literals import datetime import warnings from django.forms import ( CharField, DateField, EmailField, FileField, Form, GenericIPAddressField, HiddenInput, ImageField, IPAddressField, MultipleChoiceField, MultiValueField, MultiWidget, PasswordInput, Se...
41.827114
175
0.634155
7988b699c1264f9c78651cf99ea4ff9d6bcdb3f2
4,483
py
Python
homeassistant/components/google_translate/tts.py
fanta759/core
fcdb54d8780900fb85e6c20d5382cfd13b69a0b3
[ "Apache-2.0" ]
null
null
null
homeassistant/components/google_translate/tts.py
fanta759/core
fcdb54d8780900fb85e6c20d5382cfd13b69a0b3
[ "Apache-2.0" ]
52
2020-07-14T14:12:26.000Z
2022-03-31T06:24:02.000Z
homeassistant/components/google_translate/tts.py
fanta759/core
fcdb54d8780900fb85e6c20d5382cfd13b69a0b3
[ "Apache-2.0" ]
1
2018-08-03T20:06:38.000Z
2018-08-03T20:06:38.000Z
"""Support for the Google speech service.""" import asyncio import logging import re import aiohttp from aiohttp.hdrs import REFERER, USER_AGENT import async_timeout from gtts_token import gtts_token import voluptuous as vol from homeassistant.components.tts import CONF_LANG, PLATFORM_SCHEMA, Provider from homeassist...
24.497268
82
0.533794
7988b6dc120a3ec6899570df82df14afb4b6861e
1,302
py
Python
utils/fly/make_file_name_safe.py
flywheel-apps/GRP-14b
93b5d6ac116e073f5978deb32150dc2ba47f5c1b
[ "Apache-2.0" ]
null
null
null
utils/fly/make_file_name_safe.py
flywheel-apps/GRP-14b
93b5d6ac116e073f5978deb32150dc2ba47f5c1b
[ "Apache-2.0" ]
null
null
null
utils/fly/make_file_name_safe.py
flywheel-apps/GRP-14b
93b5d6ac116e073f5978deb32150dc2ba47f5c1b
[ "Apache-2.0" ]
null
null
null
# If you edit this file, please consider updating bids-app-template import logging import re log = logging.getLogger(__name__) def make_file_name_safe(input_basename, replace_str=''): """ removes non-safe characters from a filename and returns a filename with these characters replaced with replace_str ...
33.384615
118
0.711982
7988b97b7f30e7388df5c36bfd7c7406b075fb91
334
py
Python
lang_dynmcs/cli.py
spectrumtouch/lang_dynmcs
e05ac8ac1dfe87773a57b0365e27bb40676cea49
[ "MIT" ]
null
null
null
lang_dynmcs/cli.py
spectrumtouch/lang_dynmcs
e05ac8ac1dfe87773a57b0365e27bb40676cea49
[ "MIT" ]
253
2016-12-29T03:06:30.000Z
2021-01-21T03:47:28.000Z
lang_dynmcs/cli.py
spectrumtouch/lang_dynmcs
e05ac8ac1dfe87773a57b0365e27bb40676cea49
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- import click @click.command() def main(args=None): """Console script for lang_dynmcs""" click.echo("Replace this message by putting your code into " "lang_dynmcs.cli.main") click.echo("See click documentation at http://click.pocoo.org/") #if __name__ == "__main__"...
20.875
68
0.634731
7988b9907de654b9b7716ecef895e6ec0fca9767
306
py
Python
scripts/fundamentals/scrp_Lambda_function.py
duttashi/learnpy
c08b76b173b06d66187e51a6939d55d5dd12cb5a
[ "MIT" ]
null
null
null
scripts/fundamentals/scrp_Lambda_function.py
duttashi/learnpy
c08b76b173b06d66187e51a6939d55d5dd12cb5a
[ "MIT" ]
77
2019-04-20T06:54:19.000Z
2022-01-16T08:15:20.000Z
scripts/fundamentals/scrp_Lambda_function.py
duttashi/learnpy
c08b76b173b06d66187e51a6939d55d5dd12cb5a
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Wed Jul 15 15:34:24 2020 @author: Ashish Objective: Lambda basics Aim: Use map() in lambda to make the code readable """ sequence = [1,2,3,4,5] #doubled = [(lambda x: x*2)(x) for x in sequence] doubled = map(lambda x: x*2, sequence) print(doubled)
19.125
51
0.624183
7988ba7a8ba7365b4650e9c2d8fdfda49ec5f14d
3,898
py
Python
agsearch/text.py
Viva-Lambda/agsearch-python
be2e8e7c62b321d56432e19ba050cd80eb60d835
[ "MIT" ]
null
null
null
agsearch/text.py
Viva-Lambda/agsearch-python
be2e8e7c62b321d56432e19ba050cd80eb60d835
[ "MIT" ]
null
null
null
agsearch/text.py
Viva-Lambda/agsearch-python
be2e8e7c62b321d56432e19ba050cd80eb60d835
[ "MIT" ]
null
null
null
# simple text object from typing import List, Dict import os import pdb import re from agsearch.textinfo import TextInfo from agsearch.terminfo import TermInfo from agsearch.utils import DATA_DIR from agsearch.utils import PUNCTUATIONS from greek_accentuation.characters import base from cltk.stop.greek.stops import S...
29.530303
85
0.58235
7988bb595494e24e00e443aa7c9922c4ff2e40e7
2,786
py
Python
gecko/geckolib/driver/protocol/packet.py
mmillmor/home_assistant-components
625f97413bd6516a2358220a80819b85cc8072c6
[ "Apache-2.0" ]
null
null
null
gecko/geckolib/driver/protocol/packet.py
mmillmor/home_assistant-components
625f97413bd6516a2358220a80819b85cc8072c6
[ "Apache-2.0" ]
null
null
null
gecko/geckolib/driver/protocol/packet.py
mmillmor/home_assistant-components
625f97413bd6516a2358220a80819b85cc8072c6
[ "Apache-2.0" ]
1
2022-03-07T20:04:05.000Z
2022-03-07T20:04:05.000Z
""" Gecko <PACKT> handlers """ import logging import re from ..udp_socket import GeckoUdpProtocolHandler PACKET_OPEN = b"<PACKT>" PACKET_CLOSE = b"</PACKT>" SRCCN_OPEN = b"<SRCCN>" SRCCN_CLOSE = b"</SRCCN>" DESCN_OPEN = b"<DESCN>" DESCN_CLOSE = b"</DESCN>" DATAS_OPEN = b"<DATAS>" DATAS_CLOSE = b"</DATAS>" _LOGGER =...
27.86
82
0.530151
7988bb957859d9373df9594470bb2f704a7ce85a
1,940
py
Python
bad_seeds/examples/tutorial_adaptive.py
bnl/pub-Maffettone_2021_02
4e324111915e9d613979801bb6f5d6153e1a2652
[ "BSD-3-Clause" ]
2
2021-03-27T07:48:25.000Z
2021-04-05T05:51:00.000Z
bad_seeds/examples/tutorial_adaptive.py
bnl/pub-Maffettone_2021_02
4e324111915e9d613979801bb6f5d6153e1a2652
[ "BSD-3-Clause" ]
null
null
null
bad_seeds/examples/tutorial_adaptive.py
bnl/pub-Maffettone_2021_02
4e324111915e9d613979801bb6f5d6153e1a2652
[ "BSD-3-Clause" ]
1
2021-09-28T13:58:33.000Z
2021-09-28T13:58:33.000Z
""" An example to produce the trained model used in the bluesky-adaptive tutorial: https://github.com/bluesky/tutorial-adaptive """ from bad_seeds.training.train_a2c_cartseed import set_up from pathlib import Path from tensorforce.execution import Runner def main( time_limit=None, scoring="default", ...
24.556962
78
0.625773
7988bc750909abbdf2aa534374c7568a8d635af7
4,550
py
Python
examples/UNet/massachusetts_road_dataset_utils.py
Pandinosaurus/Recipes
7b4516e722aab6055841d02168eba049a11fe6da
[ "MIT" ]
1,034
2015-05-21T12:47:50.000Z
2022-03-17T19:27:29.000Z
examples/UNet/massachusetts_road_dataset_utils.py
nestyme/Recipes
553f5cf671f164da71152e33253cd7ed737dd2ac
[ "MIT" ]
111
2015-07-04T11:38:59.000Z
2022-03-04T01:12:11.000Z
examples/UNet/massachusetts_road_dataset_utils.py
nestyme/Recipes
553f5cf671f164da71152e33253cd7ed737dd2ac
[ "MIT" ]
528
2015-07-03T22:15:02.000Z
2022-03-27T10:01:21.000Z
__author__ = 'Fabian Isensee' import os import sys import fnmatch import matplotlib.pyplot as plt sys.path.append("../../modelzoo/") from generators import * from multiprocessing.dummy import Pool from urllib import urlretrieve def prep_folders(): if not os.path.isdir("data"): os.mkdir("data") if not ...
40.265487
111
0.676264
7988bd3b5f0dca47b10f299a37a2a1298a7beb9a
18,054
py
Python
ambari-server/src/main/resources/stack-hooks/before-START/scripts/params.py
samyzh/ambari
ff73620da41697ed2ca9ece676f71ec9ba28a7d5
[ "Apache-2.0" ]
1,664
2015-01-03T09:35:21.000Z
2022-03-31T04:55:24.000Z
ambari-server/src/main/resources/stack-hooks/before-START/scripts/params.py
samyzh/ambari
ff73620da41697ed2ca9ece676f71ec9ba28a7d5
[ "Apache-2.0" ]
3,018
2015-02-19T20:16:10.000Z
2021-11-13T20:47:48.000Z
ambari-server/src/main/resources/stack-hooks/before-START/scripts/params.py
samyzh/ambari
ff73620da41697ed2ca9ece676f71ec9ba28a7d5
[ "Apache-2.0" ]
1,673
2015-01-06T14:14:42.000Z
2022-03-31T07:22:30.000Z
""" 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 "License"); you may not use this ...
47.138381
148
0.803977
7988be9f839a35277a84cb158737e02b16614173
3,646
py
Python
utilities/visualize_cycles.py
eudoxos/Aleph
874882c33a0e8429c74e567eb01525613fee0616
[ "MIT" ]
56
2019-04-24T22:11:15.000Z
2022-03-22T11:37:47.000Z
utilities/visualize_cycles.py
eudoxos/Aleph
874882c33a0e8429c74e567eb01525613fee0616
[ "MIT" ]
48
2016-11-30T09:37:13.000Z
2019-01-30T21:43:39.000Z
utilities/visualize_cycles.py
eudoxos/Aleph
874882c33a0e8429c74e567eb01525613fee0616
[ "MIT" ]
11
2019-05-02T11:54:31.000Z
2020-12-10T14:05:40.000Z
#!/usr/bin/env python3 # # This file is part of 'Aleph - A Library for Exploring Persistent # Homology'. It visualizes information about simple cycles in some # set of graphs, providing a sort of mean histogram visualization, # as the time or simulation parameter of the graph varies. # # Original author: Bastian Rieck ...
36.09901
123
0.630828
7988bf281d81d11d283d157ab92f1aef46960a63
22
py
Python
python/lsst/obs/vista/translators/__init__.py
raphaelshirley/obs_vista
69457409dcbeb856c174e4233d2dd5419602b93f
[ "Apache-2.0" ]
1
2020-07-16T16:20:00.000Z
2020-07-16T16:20:00.000Z
python/lsst/obs/vista/translators/__init__.py
raphaelshirley/obs_vista
69457409dcbeb856c174e4233d2dd5419602b93f
[ "Apache-2.0" ]
1
2020-07-16T10:17:07.000Z
2020-07-20T15:30:49.000Z
python/lsst/obs/vista/translators/__init__.py
raphaelshirley/obs_vista
69457409dcbeb856c174e4233d2dd5419602b93f
[ "Apache-2.0" ]
1
2021-06-07T10:09:03.000Z
2021-06-07T10:09:03.000Z
from .vircam import *
11
21
0.727273
7988bf7ab742628fbac03268701a19b3e7c02da8
7,857
py
Python
src/main/python/storytext/lib/storytext/gtktoolkit/describer/treeviews.py
emilybache/texttest-runner
2d5c42b8d37699a2cbcb8f19af7c271d6ad1024a
[ "MIT" ]
null
null
null
src/main/python/storytext/lib/storytext/gtktoolkit/describer/treeviews.py
emilybache/texttest-runner
2d5c42b8d37699a2cbcb8f19af7c271d6ad1024a
[ "MIT" ]
null
null
null
src/main/python/storytext/lib/storytext/gtktoolkit/describer/treeviews.py
emilybache/texttest-runner
2d5c42b8d37699a2cbcb8f19af7c271d6ad1024a
[ "MIT" ]
null
null
null
""" Logging TreeViews is complicated because there are several ways to set them up and little direct support for extracting information from them. So they get their own module. """ import gtk, logging from images import ImageDescriber from ..treeviewextract import getAllExtractors class ColourSpecMap(dict): def ...
37.061321
119
0.625557
7988bf84ecf546abe87f34c6ba1594ee02bde5d5
829
py
Python
1806axf/AXFDay/urls.py
jianghaiming0707/python1806homework
2509f75794ac0ef8711cb1d1c2c4378408619a75
[ "Apache-2.0" ]
null
null
null
1806axf/AXFDay/urls.py
jianghaiming0707/python1806homework
2509f75794ac0ef8711cb1d1c2c4378408619a75
[ "Apache-2.0" ]
null
null
null
1806axf/AXFDay/urls.py
jianghaiming0707/python1806homework
2509f75794ac0ef8711cb1d1c2c4378408619a75
[ "Apache-2.0" ]
null
null
null
"""AXFDay URL Configuration The `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/1.11/topics/http/urls/ Examples: Function views 1. Add an import: from my_app import views 2. Add a URL to urlpatterns: url(r'^$', views.home, name='home') Class-bas...
36.043478
79
0.696019
7988c02d7e730b8201276be9c95a2afc37e6619d
6,934
py
Python
astroquery/ipac/nexsci/nasa_exoplanet_archive/tests/test_nasa_exoplanet_archive_remote.py
mfisherlevine/astroquery
cda88ef18b308563e86ee79bcc78e4ac59874df1
[ "BSD-3-Clause" ]
577
2015-02-12T18:23:49.000Z
2022-03-22T21:38:58.000Z
astroquery/ipac/nexsci/nasa_exoplanet_archive/tests/test_nasa_exoplanet_archive_remote.py
mfisherlevine/astroquery
cda88ef18b308563e86ee79bcc78e4ac59874df1
[ "BSD-3-Clause" ]
1,812
2015-01-01T08:02:20.000Z
2022-03-31T13:03:52.000Z
astroquery/ipac/nexsci/nasa_exoplanet_archive/tests/test_nasa_exoplanet_archive_remote.py
mfisherlevine/astroquery
cda88ef18b308563e86ee79bcc78e4ac59874df1
[ "BSD-3-Clause" ]
322
2015-02-23T19:31:29.000Z
2022-03-25T18:51:30.000Z
# Licensed under a 3-clause BSD style license - see LICENSE.rst import pytest import numpy as np import astropy.units as u from astropy.coordinates import SkyCoord from astropy.tests.helper import assert_quantity_allclose from astroquery.exceptions import InputWarning, InvalidQueryError, NoResultsWarning from astro...
37.89071
167
0.729449
7988c048695d4e43b443b1e071d1326709acc692
11,310
py
Python
salt/modules/zpool.py
aletourneau/salt
d7013a2f64eb4b79592220d76274bc5dde609e08
[ "Apache-2.0" ]
1
2016-04-26T03:42:32.000Z
2016-04-26T03:42:32.000Z
salt/modules/zpool.py
apergos/salt
106c715d495a9c2bd747c8ca75745236b0d7fb41
[ "Apache-2.0" ]
null
null
null
salt/modules/zpool.py
apergos/salt
106c715d495a9c2bd747c8ca75745236b0d7fb41
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- ''' Module for running ZFS zpool command ''' from __future__ import absolute_import # Import Python libs import os import stat import logging # Import Salt libs import salt.utils import salt.utils.decorators as decorators log = logging.getLogger(__name__) __func_alias__ = { 'import_': 'i...
26.928571
158
0.578161
7988c1dc231a9f37dbe5f16b81803d3574df4c96
104,776
py
Python
python/pyspark/pandas/generic.py
asranasinghe/spark
6eee25b2d587016acdc49966510b50edc42053f5
[ "BSD-2-Clause", "Apache-2.0", "CC0-1.0", "MIT", "MIT-0", "ECL-2.0", "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
null
null
null
python/pyspark/pandas/generic.py
asranasinghe/spark
6eee25b2d587016acdc49966510b50edc42053f5
[ "BSD-2-Clause", "Apache-2.0", "CC0-1.0", "MIT", "MIT-0", "ECL-2.0", "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
3
2018-06-18T05:01:07.000Z
2020-08-03T10:09:57.000Z
python/pyspark/pandas/generic.py
asranasinghe/spark
6eee25b2d587016acdc49966510b50edc42053f5
[ "BSD-2-Clause", "Apache-2.0", "CC0-1.0", "MIT", "MIT-0", "ECL-2.0", "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
null
null
null
# # 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 "License"); you may not us...
32.762977
100
0.526428
7988c2874bcfd73021d7915c3a769a662f75321f
5,161
py
Python
examples/Cliner/CliNER/code/machine_learning/crf.py
swapnull7/forte
737a72afd440d40c3826c3a7c5e4e44235c0f701
[ "Apache-2.0" ]
null
null
null
examples/Cliner/CliNER/code/machine_learning/crf.py
swapnull7/forte
737a72afd440d40c3826c3a7c5e4e44235c0f701
[ "Apache-2.0" ]
null
null
null
examples/Cliner/CliNER/code/machine_learning/crf.py
swapnull7/forte
737a72afd440d40c3826c3a7c5e4e44235c0f701
[ "Apache-2.0" ]
null
null
null
###################################################################### # CliCon - crf.py # # # # Willie Boag wboag@cs.uml.edu # # ...
28.048913
77
0.540787
7988c2a32ead2704caf3342ea054cbca3a155614
4,496
py
Python
src/sentry/api/endpoints/organization_event_details.py
ttilberg/sentry
34a554c14b68285d8a8eb6c5c4c56dfc1db9a83a
[ "BSD-3-Clause" ]
null
null
null
src/sentry/api/endpoints/organization_event_details.py
ttilberg/sentry
34a554c14b68285d8a8eb6c5c4c56dfc1db9a83a
[ "BSD-3-Clause" ]
null
null
null
src/sentry/api/endpoints/organization_event_details.py
ttilberg/sentry
34a554c14b68285d8a8eb6c5c4c56dfc1db9a83a
[ "BSD-3-Clause" ]
null
null
null
from __future__ import absolute_import from rest_framework.response import Response import six from enum import Enum from sentry.api.bases import OrganizationEventsEndpointBase, OrganizationEventsError, NoProjects from sentry import eventstore, features from sentry.models import SnubaEvent from sentry.models.project ...
37.466667
96
0.669039
7988c3c7eef41f43354113fdb029a479641ad7b6
3,070
py
Python
api/data/Song.py
strategineer/lynchman
7b07c15c801841ad3f94734d6912d248c3f1bcbd
[ "MIT" ]
1
2019-04-12T23:49:01.000Z
2019-04-12T23:49:01.000Z
api/data/Song.py
KeikakuB/lynchman
7b07c15c801841ad3f94734d6912d248c3f1bcbd
[ "MIT" ]
null
null
null
api/data/Song.py
KeikakuB/lynchman
7b07c15c801841ad3f94734d6912d248c3f1bcbd
[ "MIT" ]
1
2021-08-15T13:15:07.000Z
2021-08-15T13:15:07.000Z
import os import json os.environ['LIBROSA_CACHE_DIR'] = '/tmp/librosa_cache' os.environ['LIBROSA_CACHE_LEVEL'] = '30' import librosa import api.data.Constants class Song: def __init__(self, audio_filepath): self._audio_filepath = audio_filepath # Load the audio as a waveform `y` and the sampling...
36.117647
101
0.625407
7988c3f86ad026631508d7c82c4134d9851608b6
35,064
py
Python
pytype/tests/test_import.py
CraftSpider/pytype
9e1fa17e56944df311f244281015ef1551fd38a2
[ "Apache-2.0" ]
1
2020-03-31T13:05:05.000Z
2020-03-31T13:05:05.000Z
pytype/tests/test_import.py
CraftSpider/pytype
9e1fa17e56944df311f244281015ef1551fd38a2
[ "Apache-2.0" ]
null
null
null
pytype/tests/test_import.py
CraftSpider/pytype
9e1fa17e56944df311f244281015ef1551fd38a2
[ "Apache-2.0" ]
null
null
null
"""Tests for import.""" from pytype import file_utils from pytype import imports_map_loader from pytype.tests import test_base class ImportTest(test_base.TargetIndependentTest): """Tests for import.""" def testBasicImport(self): ty = self.Infer("""\ import sys """) self.assertTypesMatchPytd...
29.098755
80
0.52253
7988c43528eefecb792c498230670c338164cc84
611
py
Python
actions/interface_channel_group.py
cognifloyd/stackstorm-vdx
0ae8b783cdc3e3fe467050268ea7d10de493e3ca
[ "Apache-2.0" ]
null
null
null
actions/interface_channel_group.py
cognifloyd/stackstorm-vdx
0ae8b783cdc3e3fe467050268ea7d10de493e3ca
[ "Apache-2.0" ]
null
null
null
actions/interface_channel_group.py
cognifloyd/stackstorm-vdx
0ae8b783cdc3e3fe467050268ea7d10de493e3ca
[ "Apache-2.0" ]
1
2021-01-28T17:48:12.000Z
2021-01-28T17:48:12.000Z
from pynos import device from st2common.runners.base_action import Action class interface_channel_group(Action): def run(self, **kwargs): conn = (str(kwargs.pop('ip')), str(kwargs.pop('port'))) auth = (str(kwargs.pop('username')), str(kwargs.pop('password'))) test = kwargs.pop('test', Fals...
32.157895
73
0.594108
7988c4988cb575ef08df53af5417e161a04ab0f6
540
py
Python
tutorials/pytorch/tut1_basics/tests/test_tuto_basics.py
plutasnyy/tutorials
6acf50e5a02ff2bcd14a316dd15ee57565dc564e
[ "MIT" ]
null
null
null
tutorials/pytorch/tut1_basics/tests/test_tuto_basics.py
plutasnyy/tutorials
6acf50e5a02ff2bcd14a316dd15ee57565dc564e
[ "MIT" ]
null
null
null
tutorials/pytorch/tut1_basics/tests/test_tuto_basics.py
plutasnyy/tutorials
6acf50e5a02ff2bcd14a316dd15ee57565dc564e
[ "MIT" ]
null
null
null
# Copyright (c) 2021 Graphcore Ltd. All rights reserved. from pathlib import Path import pytest from examples_tests.test_util import SubProcessChecker working_path = Path(__file__).parent.parent class TestComplete(SubProcessChecker): @pytest.mark.category2 @pytest.mark.ipus(1) def test_model(self): ...
27
74
0.692593
7988c5d75397e2bea775f157cd14ae766fa0324f
277
py
Python
ABC/058/b.py
fumiyanll23/AtCoder
362ca9fcacb5415c1458bc8dee5326ba2cc70b65
[ "MIT" ]
null
null
null
ABC/058/b.py
fumiyanll23/AtCoder
362ca9fcacb5415c1458bc8dee5326ba2cc70b65
[ "MIT" ]
null
null
null
ABC/058/b.py
fumiyanll23/AtCoder
362ca9fcacb5415c1458bc8dee5326ba2cc70b65
[ "MIT" ]
null
null
null
def main(): # input O = input() E = input() # compute ans = '' for i in range(len(O)+len(E)): if i%2 == 0: ans += O[i//2] else: ans += E[i//2] # output print(ans) if __name__ == '__main__': main()
13.85
34
0.397112
7988c66c1724042bb748e3785bc6dc7f17a759f3
6,418
py
Python
python/paddle/fluid/tests/unittests/test_fused_embedding_fc_lstm_op.py
zmxdream/Paddle
04f042a5d507ad98f7f2cfc3cbc44b06d7a7f45c
[ "Apache-2.0" ]
17,085
2016-11-18T06:40:52.000Z
2022-03-31T22:52:32.000Z
python/paddle/fluid/tests/unittests/test_fused_embedding_fc_lstm_op.py
zmxdream/Paddle
04f042a5d507ad98f7f2cfc3cbc44b06d7a7f45c
[ "Apache-2.0" ]
29,769
2016-11-18T06:35:22.000Z
2022-03-31T16:46:15.000Z
python/paddle/fluid/tests/unittests/test_fused_embedding_fc_lstm_op.py
zmxdream/Paddle
04f042a5d507ad98f7f2cfc3cbc44b06d7a7f45c
[ "Apache-2.0" ]
4,641
2016-11-18T07:43:33.000Z
2022-03-31T15:15:02.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...
29.305936
85
0.605796
7988c721e0cc25522b28ce48cf615258a65607e3
833
py
Python
migrations/versions/003__study_data_column.py
LCBRU/image_study_merge
53e201e1fb970ab5e568f49fe880fd8d052a926d
[ "MIT" ]
null
null
null
migrations/versions/003__study_data_column.py
LCBRU/image_study_merge
53e201e1fb970ab5e568f49fe880fd8d052a926d
[ "MIT" ]
null
null
null
migrations/versions/003__study_data_column.py
LCBRU/image_study_merge
53e201e1fb970ab5e568f49fe880fd8d052a926d
[ "MIT" ]
null
null
null
from sqlalchemy import ( MetaData, Table, Column, Integer, NVARCHAR, ForeignKey, DateTime, ) from lbrc_flask.security.migrations import get_audit_mixin_columns meta = MetaData() def upgrade(migrate_engine): meta.bind = migrate_engine sd = Table("study_data", meta, autoload=True) ...
21.921053
90
0.644658
7988c82f27630e5f27ecdb16c3c70792fc46099b
1,677
py
Python
primrose/readers/sklearn_dataset_reader.py
astro313/primrose
891f001e4e198096edb74eea951d27c9ae2a278f
[ "Apache-2.0" ]
38
2019-09-04T17:39:31.000Z
2021-11-09T21:20:24.000Z
primrose/readers/sklearn_dataset_reader.py
astro313/primrose
891f001e4e198096edb74eea951d27c9ae2a278f
[ "Apache-2.0" ]
66
2019-09-05T15:55:19.000Z
2021-11-21T05:36:54.000Z
primrose/readers/sklearn_dataset_reader.py
astro313/primrose
891f001e4e198096edb74eea951d27c9ae2a278f
[ "Apache-2.0" ]
6
2019-12-02T09:05:30.000Z
2021-12-09T16:12:36.000Z
"""Module to read canned datasets from sklearn Author(s): Carl Anderson (carl.anderson@weightwatchers.com) """ from primrose.base.sql_reader import AbstractReader from sklearn.datasets import * import pandas as pd class SklearnDatasetReader(AbstractReader): """Read data from sklearn.dataset into a pandas da...
28.423729
134
0.628503
7988c92cd496e3bc3738168fc4883e0a1f6ae0a5
1,537
py
Python
classifiers/nn.py
mjpcollins/spam-filter
4bb1da8391eebccb229c8e5faf935df402472d22
[ "MIT" ]
1
2022-01-20T17:48:08.000Z
2022-01-20T17:48:08.000Z
classifiers/nn.py
mjpcollins/spam-filter
4bb1da8391eebccb229c8e5faf935df402472d22
[ "MIT" ]
null
null
null
classifiers/nn.py
mjpcollins/spam-filter
4bb1da8391eebccb229c8e5faf935df402472d22
[ "MIT" ]
null
null
null
from numpy import genfromtxt from utils.neural_network import NeuralNetwork def train(): training_full_dataset = genfromtxt("data/training_spam.csv", delimiter=',') test_full_dataset = genfromtxt("data/testing_spam.csv", delimiter=',') training_dataset = training_full_dataset[:, 1:] training_labels = ...
37.487805
79
0.648666
7988ca5fe9e7bb8293d2212c4e0a86aca458d8f4
3,234
py
Python
prediction/src/algorithms/segment/src/models/simple_3d_model.py
swarm-ai/concept-to-clinic
d447cacf57cbbe84f7b744303497030b2a92a122
[ "MIT" ]
null
null
null
prediction/src/algorithms/segment/src/models/simple_3d_model.py
swarm-ai/concept-to-clinic
d447cacf57cbbe84f7b744303497030b2a92a122
[ "MIT" ]
null
null
null
prediction/src/algorithms/segment/src/models/simple_3d_model.py
swarm-ai/concept-to-clinic
d447cacf57cbbe84f7b744303497030b2a92a122
[ "MIT" ]
1
2019-09-01T00:14:09.000Z
2019-09-01T00:14:09.000Z
import numpy as np from keras.callbacks import ModelCheckpoint from keras.engine import Input, Model from keras.layers import Conv3D, MaxPooling3D, UpSampling3D, Activation from keras.optimizers import Adam from scipy.ndimage import zoom from .segmentation_model import SegmentationModel class Simple3DModel(Segmentat...
50.53125
117
0.643476
7988cac9c8b4a48f4ee70254aa8f81e5e707a2ac
2,355
py
Python
great_expectations/core/usage_statistics/anonymizers/anonymizer.py
kyleaton/great_expectations
a856513859445cdb1b254e0d90022bab6257b6a2
[ "Apache-2.0" ]
2
2020-05-07T18:16:17.000Z
2020-05-07T18:16:21.000Z
great_expectations/core/usage_statistics/anonymizers/anonymizer.py
tsanikgr/great_expectations
8f63566a0393904efa796679a0296ee91ab41d46
[ "Apache-2.0" ]
null
null
null
great_expectations/core/usage_statistics/anonymizers/anonymizer.py
tsanikgr/great_expectations
8f63566a0393904efa796679a0296ee91ab41d46
[ "Apache-2.0" ]
null
null
null
import logging from hashlib import md5 from great_expectations.util import load_class logger = logging.getLogger(__name__) class Anonymizer(object): """Anonymize string names in an optionally-consistent way.""" def __init__(self, salt=None): if salt is not None and not isinstance(salt, str): ...
37.983871
117
0.633121
7988cbb40d1d66c5621d1b8b20d0c13e385f81cf
1,876
py
Python
edgelm/tests/test_file_io.py
guotao0628/DeepNet
1ae74d8b44d715bf67c7d64a8efafff4b7c7937a
[ "MIT" ]
1
2021-11-07T00:30:05.000Z
2021-11-07T00:30:05.000Z
edgelm/tests/test_file_io.py
guotao0628/DeepNet
1ae74d8b44d715bf67c7d64a8efafff4b7c7937a
[ "MIT" ]
null
null
null
edgelm/tests/test_file_io.py
guotao0628/DeepNet
1ae74d8b44d715bf67c7d64a8efafff4b7c7937a
[ "MIT" ]
null
null
null
# This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. import os import shutil import sys import tempfile import unittest from typing import Optional from unittest.mock import MagicMock class TestFileIO(unittest.TestCase): _tmpdi...
31.79661
81
0.622068
7988cd91b008da714c6c1c9f847412117b2b444a
194
py
Python
checkio/electronic_station/restricted_sum.py
zoido/checkio_python_solutions
858cc7eafbbf55c8506e14cce260d17406fbf09c
[ "MIT" ]
null
null
null
checkio/electronic_station/restricted_sum.py
zoido/checkio_python_solutions
858cc7eafbbf55c8506e14cce260d17406fbf09c
[ "MIT" ]
2
2017-10-14T17:44:17.000Z
2018-04-06T18:53:37.000Z
checkio/electronic_station/restricted_sum.py
zoido/checkio_python_solutions
858cc7eafbbf55c8506e14cce260d17406fbf09c
[ "MIT" ]
null
null
null
def checkio(numbers): length = len(numbers) if length == 0: return 0 if length == 1: return numbers[0] else: return numbers[-1] + checkio(numbers[:-1])
17.636364
50
0.541237
7988ce022684ecb5e05f87ff7c310a276265e770
1,632
py
Python
Voice-conversion-evaluation/models/any2any/VQVC+/audioprocessor.py
ga642381/robust-vc
90c5c51007db4544885e903d755fb95fadd1fb71
[ "MIT" ]
12
2022-01-12T12:38:22.000Z
2022-02-14T02:25:48.000Z
Voice-conversion-evaluation/models/any2any/VQVC+/audioprocessor.py
ga642381/robust-vc
90c5c51007db4544885e903d755fb95fadd1fb71
[ "MIT" ]
null
null
null
Voice-conversion-evaluation/models/any2any/VQVC+/audioprocessor.py
ga642381/robust-vc
90c5c51007db4544885e903d755fb95fadd1fb71
[ "MIT" ]
null
null
null
#!python # -*- coding: utf-8 -*- """Preprocess audio files.""" from typing import Tuple, Optional import numpy as np from librosa import load, stft from librosa.filters import mel from librosa.effects import trim class AudioProcessor: """Process audio data.""" # hyperparameters sample_rate = 22050 n...
23.652174
86
0.602941
7988ce36a821d6248c5606ec8a8163d3ac4b12b1
2,515
py
Python
ndmapper/conftest.py
jehturner/quadpype
16a1f8cf7c126a948f0b0663c57f7399b044f9da
[ "BSD-3-Clause" ]
null
null
null
ndmapper/conftest.py
jehturner/quadpype
16a1f8cf7c126a948f0b0663c57f7399b044f9da
[ "BSD-3-Clause" ]
null
null
null
ndmapper/conftest.py
jehturner/quadpype
16a1f8cf7c126a948f0b0663c57f7399b044f9da
[ "BSD-3-Clause" ]
null
null
null
# This file is used to configure the behavior of pytest when using the Astropy # test infrastructure. from astropy.version import version as astropy_version if astropy_version < '3.0': # With older versions of Astropy, we actually need to import the pytest # plugins themselves in order to make them discoverabl...
43.362069
84
0.747913
7988ce4094b21b8e6adb818e3bab5a0ffbe5cecf
449
py
Python
run.py
ashvedula/labdcn2
1246d7162e0d83f6d68010da33630fc4ce4deb6d
[ "MIT" ]
null
null
null
run.py
ashvedula/labdcn2
1246d7162e0d83f6d68010da33630fc4ce4deb6d
[ "MIT" ]
null
null
null
run.py
ashvedula/labdcn2
1246d7162e0d83f6d68010da33630fc4ce4deb6d
[ "MIT" ]
null
null
null
from flask import Flask app = Flask(__name__) from datetime import datetime import pytz @app.route('/') def hello_world(): return 'Hello world!' @app.route('/time') def get_time(): ##now = datetime.now() ##return now.strftime("%H:%M:%S") tz_NY = pytz.timezone('America/New_York') datetime_NY = ...
18.708333
46
0.634744
7988cfdbfef4bdacbc05a46f23cc83e5b04b39f6
6,199
py
Python
src/interface/Python/setup/setup.py
ekourkchi/paramonte
15f8ea27cb514078a94d9c4ee4b60e4f45826f17
[ "MIT" ]
null
null
null
src/interface/Python/setup/setup.py
ekourkchi/paramonte
15f8ea27cb514078a94d9c4ee4b60e4f45826f17
[ "MIT" ]
null
null
null
src/interface/Python/setup/setup.py
ekourkchi/paramonte
15f8ea27cb514078a94d9c4ee4b60e4f45826f17
[ "MIT" ]
null
null
null
#################################################################################################################################### #################################################################################################################################### #### #### MIT License #### #### ParaMonte: plain p...
65.252632
132
0.407646
7988d053dda1359b0d955c8369ce03d2a34c9fb6
2,372
py
Python
applied_python/applied_python/lib/python2.7/site-packages/astroid/tests/resources.py
mith1979/ansible_automation
013dfa67c6d91720b787fadb21de574b6e023a26
[ "Apache-2.0" ]
35
2016-09-22T22:53:14.000Z
2020-02-13T15:12:21.000Z
sdks/python/.tox/lint/lib/python2.7/site-packages/astroid/tests/resources.py
axbaretto/presto
f137d2709db42b5c3e4d43a631832a8f74853065
[ "Apache-2.0" ]
28
2020-03-04T22:01:48.000Z
2022-03-12T00:59:47.000Z
sdks/python/.tox/lint/lib/python2.7/site-packages/astroid/tests/resources.py
axbaretto/presto
f137d2709db42b5c3e4d43a631832a8f74853065
[ "Apache-2.0" ]
88
2016-11-27T02:16:11.000Z
2020-02-28T05:10:26.000Z
# Copyright 2014 Google, Inc. All rights reserved. # contact http://www.logilab.fr/ -- mailto:contact@logilab.fr # # This file is part of astroid. # # astroid is free software: you can redistribute it and/or modify it # under the terms of the GNU Lesser General Public License as published by the # Free Software Foundat...
32.493151
80
0.72344
7988d173425e3f26cd84c872663c321c716b47b4
2,889
py
Python
icekit/utils/sequences.py
ic-labs/django-icekit
c507ea5b1864303732c53ad7c5800571fca5fa94
[ "MIT" ]
52
2016-09-13T03:50:58.000Z
2022-02-23T16:25:08.000Z
icekit/utils/sequences.py
ic-labs/django-icekit
c507ea5b1864303732c53ad7c5800571fca5fa94
[ "MIT" ]
304
2016-08-11T14:17:30.000Z
2020-07-22T13:35:18.000Z
icekit/utils/sequences.py
ic-labs/django-icekit
c507ea5b1864303732c53ad7c5800571fca5fa94
[ "MIT" ]
12
2016-09-21T18:46:35.000Z
2021-02-15T19:37:50.000Z
def dedupe_and_sort(sequence, first=None, last=None): """ De-dupe and partially sort a sequence. The `first` argument should contain all the items that might appear in `sequence` and for which the order (relative to each other) is important. The `last` argument is the same, but matching items will...
33.593023
92
0.668744
7988d1abaf795cd71f72a296d8b16ba1866ca1be
2,465
py
Python
tools/fewshot_exp/datasets/gen_fewlist_voc.py
JunhoPark0314/DCNet
4b8b11701ae05903ecae779cb72949d320f134a7
[ "MIT" ]
93
2021-03-20T13:48:47.000Z
2022-03-31T09:35:00.000Z
tools/fewshot_exp/datasets/gen_fewlist_voc.py
JunhoPark0314/DCNet
4b8b11701ae05903ecae779cb72949d320f134a7
[ "MIT" ]
19
2021-05-19T06:19:52.000Z
2022-03-26T07:56:24.000Z
tools/fewshot_exp/datasets/gen_fewlist_voc.py
JunhoPark0314/DCNet
4b8b11701ae05903ecae779cb72949d320f134a7
[ "MIT" ]
19
2021-05-29T09:36:56.000Z
2022-03-31T09:35:02.000Z
import argparse import random import os import numpy as np from os import path import sys seed = sys.argv[1] classes = ["aeroplane", "bicycle", "bird", "boat", "bottle", "bus", "car", "cat", "chair", "cow", "diningtable", "dog", "horse", "motorbike", "person", "pottedplant", "sheep", ...
29.698795
95
0.526572
7988d1e1f93e1f0dc0e707c55c1839fc7dc54914
76,567
py
Python
pysonos/core.py
gieljnssns/pysonos
dbd920a373a70d0ca02c40531fe0e9512212e2d5
[ "MIT" ]
null
null
null
pysonos/core.py
gieljnssns/pysonos
dbd920a373a70d0ca02c40531fe0e9512212e2d5
[ "MIT" ]
null
null
null
pysonos/core.py
gieljnssns/pysonos
dbd920a373a70d0ca02c40531fe0e9512212e2d5
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # pylint: disable=fixme, protected-access """The core module contains the SoCo class that implements the main entry to the SoCo functionality """ from __future__ import absolute_import, unicode_literals import datetime import logging import re import socket from functools import wraps from xml...
37.114397
79
0.590476
7988d209a87ec82e7f8fc2f3ade375ffd34fa91e
7,605
py
Python
examples/example_simple_GUI.py
Derollez/PyAbel
c8be4ed7e8e08ee026634b9e856fb473e58d7330
[ "MIT" ]
null
null
null
examples/example_simple_GUI.py
Derollez/PyAbel
c8be4ed7e8e08ee026634b9e856fb473e58d7330
[ "MIT" ]
null
null
null
examples/example_simple_GUI.py
Derollez/PyAbel
c8be4ed7e8e08ee026634b9e856fb473e58d7330
[ "MIT" ]
null
null
null
# Illustrative GUI driving a small subset of PyAbel methods # tkinter code adapted from # http://matplotlib.org/examples/user_interfaces/embedding_in_tk.html import numpy as np import abel from scipy.ndimage.interpolation import shift import sys if sys.version_info[0] < 3: import Tkinter as tk from tkFileD...
28.91635
112
0.641815
7988d37ebb4fe983a67715a31d875f0b0f9fd11a
1,353
py
Python
data/__init__.py
gwq2018/modified_SSD_pytorch
cfea2c0873c485d4e50d7465535cb647af066ef9
[ "MIT" ]
1
2021-09-08T08:51:51.000Z
2021-09-08T08:51:51.000Z
data/__init__.py
gwq2018/modified_SSD_pytorch
cfea2c0873c485d4e50d7465535cb647af066ef9
[ "MIT" ]
null
null
null
data/__init__.py
gwq2018/modified_SSD_pytorch
cfea2c0873c485d4e50d7465535cb647af066ef9
[ "MIT" ]
1
2021-09-08T08:49:59.000Z
2021-09-08T08:49:59.000Z
from .voc0712 import VOCDetection, VOCAnnotationTransform, VOC_CLASSES, VOC_ROOT, TEST_ROOT from .coco import COCODetection, COCOAnnotationTransform, COCO_CLASSES, COCO_ROOT, get_label_map from .config import * import torch import cv2 import numpy as np def detection_collate(batch): """Custom collate fn for deali...
30.75
96
0.669623
7988d3f5446a6256a9917cf2937b8f38997f276b
1,003
py
Python
isi_sdk_9_0_0/test/test_filepool_default_policy_action.py
mohitjain97/isilon_sdk_python
a371f438f542568edb8cda35e929e6b300b1177c
[ "Unlicense" ]
24
2018-06-22T14:13:23.000Z
2022-03-23T01:21:26.000Z
isi_sdk_9_0_0/test/test_filepool_default_policy_action.py
mohitjain97/isilon_sdk_python
a371f438f542568edb8cda35e929e6b300b1177c
[ "Unlicense" ]
46
2018-04-30T13:28:22.000Z
2022-03-21T21:11:07.000Z
isi_sdk_9_0_0/test/test_filepool_default_policy_action.py
mohitjain97/isilon_sdk_python
a371f438f542568edb8cda35e929e6b300b1177c
[ "Unlicense" ]
29
2018-06-19T00:14:04.000Z
2022-02-08T17:51:19.000Z
# coding: utf-8 """ Isilon SDK Isilon SDK - Language bindings for the OneFS API # noqa: E501 OpenAPI spec version: 10 Contact: sdk@isilon.com Generated by: https://github.com/swagger-api/swagger-codegen.git """ from __future__ import absolute_import import unittest import isi_sdk_9_0_0 from ...
24.463415
113
0.734796
7988d499b9d31ad3f2a48105b471f4cc58db1b3c
655
py
Python
utils/declare_queue.py
jdgillespie91/trackerSpend
1b8a6d6a8cf99cad3006118035a8ff3c54a4fcb6
[ "MIT" ]
3
2015-07-16T14:35:23.000Z
2015-12-16T23:14:48.000Z
utils/declare_queue.py
jdgillespie91/trackerSpend
1b8a6d6a8cf99cad3006118035a8ff3c54a4fcb6
[ "MIT" ]
null
null
null
utils/declare_queue.py
jdgillespie91/trackerSpend
1b8a6d6a8cf99cad3006118035a8ff3c54a4fcb6
[ "MIT" ]
5
2016-06-13T11:14:35.000Z
2020-11-13T00:15:22.000Z
import amqp from contextlib import closing def declare_queue(queue): """ Declare a queue. A queue is declared. If a queue with the same name is already declared, the properties of the queue are checked. If the declared queue has the same properties, the function exits quietly. If the declared queue has diffe...
31.190476
263
0.714504
7988d4aa74fa1755740d957487cf1e29bb724516
15,017
py
Python
workflow_ingestion/gui_utils.py
qbrc-cnap/cnap
624683e91a64c3b4934b578c59db850242d2f94c
[ "MIT" ]
1
2021-07-08T14:06:04.000Z
2021-07-08T14:06:04.000Z
workflow_ingestion/gui_utils.py
qbrc-cnap/cnap
624683e91a64c3b4934b578c59db850242d2f94c
[ "MIT" ]
12
2020-02-12T00:10:53.000Z
2021-06-10T21:24:45.000Z
workflow_ingestion/gui_utils.py
qbrc-cnap/cnap
624683e91a64c3b4934b578c59db850242d2f94c
[ "MIT" ]
null
null
null
import os import sys import json from jinja2 import Environment, FileSystemLoader # for easy reference, determine the directory we are currently in THIS_DIR = os.path.dirname(os.path.abspath(__file__)) APP_ROOT_DIR = os.path.dirname(THIS_DIR) # add the app root dir to the syspath sys.path.append(APP_ROOT_DIR) # nee...
38.211196
109
0.698475
7988d5828f6fa290b63500e2567f32bfa5a67c77
2,507
py
Python
schema_games/breakout/play.py
borea17/schema-games
d17cd33762294911e68b96cfe5a6e8ae603d72de
[ "MIT" ]
null
null
null
schema_games/breakout/play.py
borea17/schema-games
d17cd33762294911e68b96cfe5a6e8ae603d72de
[ "MIT" ]
null
null
null
schema_games/breakout/play.py
borea17/schema-games
d17cd33762294911e68b96cfe5a6e8ae603d72de
[ "MIT" ]
null
null
null
import argparse import numpy as np from collections import defaultdict from gym.utils.play import play import pygame from schema_games.breakout import games from schema_games.printing import blue ZOOM_FACTOR = 5 DEFAULT_DEBUG = True DEFAULT_CHEAT_MODE = False def play_game( environment_class, cheat_mode=DEFAUL...
25.581633
88
0.644994
7988d66861dd8cdad41d88058a1d8146439b4af4
9,308
py
Python
website/preprints/tasks.py
h-ci-user01/osf.h-test
a61db2c639a26031aa5b7f58c4dd719919aa5ece
[ "Apache-2.0" ]
null
null
null
website/preprints/tasks.py
h-ci-user01/osf.h-test
a61db2c639a26031aa5b7f58c4dd719919aa5ece
[ "Apache-2.0" ]
18
2020-03-24T15:26:02.000Z
2022-03-08T21:30:39.000Z
website/preprints/tasks.py
h-ci-user01/osf.h-test
a61db2c639a26031aa5b7f58c4dd719919aa5ece
[ "Apache-2.0" ]
null
null
null
from django.apps import apps import logging import urlparse import random import requests from framework.exceptions import HTTPError from framework.celery_tasks import app as celery_app from framework import sentry from website import settings, mails from website.util.share import GraphNode, format_contributor, form...
44.535885
213
0.702621
7988d99aa2be64e88fe8cd1e5c7aa0a5fa611e38
516
py
Python
regexlib/python_re_test_file/regexlib_228.py
yetingli/ReDoS-Benchmarks
f5b5094d835649e957bf3fec6b8bd4f6efdb35fc
[ "MIT" ]
1
2022-01-24T14:43:23.000Z
2022-01-24T14:43:23.000Z
regexlib/python_re_test_file/regexlib_228.py
yetingli/ReDoS-Benchmarks
f5b5094d835649e957bf3fec6b8bd4f6efdb35fc
[ "MIT" ]
null
null
null
regexlib/python_re_test_file/regexlib_228.py
yetingli/ReDoS-Benchmarks
f5b5094d835649e957bf3fec6b8bd4f6efdb35fc
[ "MIT" ]
null
null
null
# 228 # ^([A-Za-z]|[A-Za-z][0-9]*|[0-9]*[A-Za-z])+$ # EXPONENT # nums:4 # EXPONENT AttackString:""+"AA"*8+"!1 __EOD(ii2)" import re from time import perf_counter regex = """^([A-Za-z]|[A-Za-z][0-9]*|[0-9]*[A-Za-z])+$""" REGEX = re.compile(regex) for i in range(0, 150000): ATTACK = "" + "AA" * i * 1 + "!1 __EOD(ii...
27.157895
57
0.563953
7988db6bd2dd7fe97beb86ed8ca04cafa491d14f
477
py
Python
plotly/validators/violin/_points.py
faezs/plotly.py
6009b5b9c746e5d2a2849ad255a4eb234b551ed7
[ "MIT" ]
1
2018-07-16T01:51:47.000Z
2018-07-16T01:51:47.000Z
plotly/validators/violin/_points.py
faezs/plotly.py
6009b5b9c746e5d2a2849ad255a4eb234b551ed7
[ "MIT" ]
null
null
null
plotly/validators/violin/_points.py
faezs/plotly.py
6009b5b9c746e5d2a2849ad255a4eb234b551ed7
[ "MIT" ]
1
2019-02-18T04:12:56.000Z
2019-02-18T04:12:56.000Z
import _plotly_utils.basevalidators class PointsValidator(_plotly_utils.basevalidators.EnumeratedValidator): def __init__(self, plotly_name='points', parent_name='violin', **kwargs): super(PointsValidator, self).__init__( plotly_name=plotly_name, parent_name=parent_name, ...
31.8
77
0.645702
7988dc58caca209c0e57c1fcfb67aedef082f546
60,521
py
Python
python/ccxt/bitstamp.py
atoll6/ccxt
3c5fd65a32073bfbe1a7e0f5a02d7d3f93850780
[ "MIT" ]
null
null
null
python/ccxt/bitstamp.py
atoll6/ccxt
3c5fd65a32073bfbe1a7e0f5a02d7d3f93850780
[ "MIT" ]
null
null
null
python/ccxt/bitstamp.py
atoll6/ccxt
3c5fd65a32073bfbe1a7e0f5a02d7d3f93850780
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # PLEASE DO NOT EDIT THIS FILE, IT IS GENERATED AND WILL BE OVERWRITTEN: # https://github.com/ccxt/ccxt/blob/master/CONTRIBUTING.md#how-to-contribute-code from ccxt.base.exchange import Exchange # ----------------------------------------------------------------------------- try: basestri...
39.711942
174
0.466797
7988dc6c8d8a733fc129e27d8ce48fc2939043ab
3,080
py
Python
contrib/linearize/linearize-hashes.py
L00119483/TechSquad.io
3ebafca95c5b125f3dbe52d9d4cde29c61a48975
[ "MIT" ]
4
2018-06-16T20:08:19.000Z
2018-08-22T15:44:58.000Z
contrib/linearize/linearize-hashes.py
L00119483/TechSquad.io
3ebafca95c5b125f3dbe52d9d4cde29c61a48975
[ "MIT" ]
null
null
null
contrib/linearize/linearize-hashes.py
L00119483/TechSquad.io
3ebafca95c5b125f3dbe52d9d4cde29c61a48975
[ "MIT" ]
7
2018-06-06T18:51:07.000Z
2018-09-08T15:17:04.000Z
#!/usr/bin/python # # linearize-hashes.py: List blocks in a linear, no-fork version of the chain. # # Copyright (c) 2013-2014 The Bitcoin developers # Distributed under the MIT/X11 software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. # # Copyright (c) 2018 The Wa...
26.782609
90
0.683766
7988dd11edf7b3f0acf7faa9307be5151c285fff
2,765
py
Python
east/formatting.py
mikhaildubov/AST-text-analysis
055ad8d2492c100bbbaa25309ec1074bdf1dfaa5
[ "MIT" ]
11
2016-01-07T05:58:35.000Z
2021-05-25T15:43:41.000Z
east/formatting.py
msdubov/AST-text-analysis
055ad8d2492c100bbbaa25309ec1074bdf1dfaa5
[ "MIT" ]
1
2015-06-30T14:07:48.000Z
2015-07-06T11:50:03.000Z
east/formatting.py
msdubov/AST-text-analysis
055ad8d2492c100bbbaa25309ec1074bdf1dfaa5
[ "MIT" ]
5
2016-12-06T16:42:24.000Z
2020-11-21T05:30:22.000Z
# -*- coding: utf-8 -* def format_table(table, format): if format == "xml": return table2xml(keyphrases_table) elif format == "csv": return table2csv(keyphrases_table) else: raise Exception("Unknown table format: '%s'. " "Please use one of: 'xml', 'csv'." % ...
34.135802
89
0.555515
7988dd744f7afcb301f60466affd84b74920a5a4
35,091
py
Python
setup.py
scopatz/PyTables
05a74def785688abd802224a5ba44393a701ebc7
[ "BSD-3-Clause" ]
null
null
null
setup.py
scopatz/PyTables
05a74def785688abd802224a5ba44393a701ebc7
[ "BSD-3-Clause" ]
null
null
null
setup.py
scopatz/PyTables
05a74def785688abd802224a5ba44393a701ebc7
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- """Setup script for the tables package""" from __future__ import print_function import os import re import sys import ctypes import tempfile import textwrap import subprocess from os.path import exists, expanduser import glob # Using ``setuptools`` enables lots of goodi...
36.064748
99
0.615856
7988dda7d1fb7747dc5e7fb99db3e8e6028d1580
8,481
py
Python
python/advent_of_code/y2021/day04.py
stonecharioteer/advent-of-code
c18e47e378e82f82b77558a114e7d7c3a43c8429
[ "MIT" ]
null
null
null
python/advent_of_code/y2021/day04.py
stonecharioteer/advent-of-code
c18e47e378e82f82b77558a114e7d7c3a43c8429
[ "MIT" ]
null
null
null
python/advent_of_code/y2021/day04.py
stonecharioteer/advent-of-code
c18e47e378e82f82b77558a114e7d7c3a43c8429
[ "MIT" ]
null
null
null
"""--- Day 4: Giant Squid --- You're already almost 1.5km (almost a mile) below the surface of the ocean, already so deep that you can't see any sunlight. What you can see, however, is a giant squid that has attached itself to the outside of your submarine. Maybe it wants to play bingo? Bingo is played on a set of b...
39.263889
111
0.621153
7988de0df2eec8574e86d2946cb3d22b13c09e76
1,675
py
Python
madlibgame.py
Krraunak/madlibgame
4b21a1cab30cde9273d5740b5a23030c3d8fa435
[ "MIT" ]
null
null
null
madlibgame.py
Krraunak/madlibgame
4b21a1cab30cde9273d5740b5a23030c3d8fa435
[ "MIT" ]
null
null
null
madlibgame.py
Krraunak/madlibgame
4b21a1cab30cde9273d5740b5a23030c3d8fa435
[ "MIT" ]
null
null
null
# Developing game for heroku app # A script from hamlet # Taken from http://www.redkid.net/cgi-bin/madlibs/hamlet.pl print("Fill in the blanks below with whatever words you like.") print("When you're done, hit the See the Results! button, and your choices will be inserted into the story.") Celebrity = input("C...
45.27027
110
0.693731
7988de82a248777bb6c832797943f761161e772c
647
py
Python
IfxPy/tests/test_001_ConnDb.py
jaimundada/IfxPy
e6941d77051933dfe6affd3b096ea6d8f485ae9b
[ "Apache-2.0" ]
39
2017-09-25T00:10:23.000Z
2022-02-10T22:03:36.000Z
IfxPy/tests/test_001_ConnDb.py
jaimundada/IfxPy
e6941d77051933dfe6affd3b096ea6d8f485ae9b
[ "Apache-2.0" ]
58
2018-05-11T09:45:45.000Z
2022-03-10T10:27:01.000Z
IfxPy/tests/test_001_ConnDb.py
jaimundada/IfxPy
e6941d77051933dfe6affd3b096ea6d8f485ae9b
[ "Apache-2.0" ]
22
2018-02-02T12:41:18.000Z
2022-02-24T14:29:17.000Z
# # # import unittest, sys import IfxPy import config from testfunctions import IfxPyTestFunctions class IfxPyTestCase(unittest.TestCase): def test_001_ConnDb(self): obj = IfxPyTestFunctions() obj.assert_expect(self.run_test_001) def run_test_001(self): conn = IfxPy.connect(config.ConnStr, config...
17.972222
70
0.744977
7988dffbf581813cbda6369a63db63fbcbc8837b
422
py
Python
spyre/testing/holeburningsnspd.py
zhong-lab/optics
9de1942d9a128183ecb3d360b160b27126e7b8f0
[ "BSD-2-Clause" ]
1
2022-03-27T07:47:19.000Z
2022-03-27T07:47:19.000Z
spyre/testing/holeburningsnspd.py
zhong-lab/optics
9de1942d9a128183ecb3d360b160b27126e7b8f0
[ "BSD-2-Clause" ]
null
null
null
spyre/testing/holeburningsnspd.py
zhong-lab/optics
9de1942d9a128183ecb3d360b160b27126e7b8f0
[ "BSD-2-Clause" ]
4
2019-11-08T22:39:04.000Z
2021-11-05T02:39:37.000Z
##Config file for lifetime_spyrelet.py in spyre/spyre/spyrelet/ # Device List devices = { 'fungen':[ 'lantz.drivers.keysight.Keysight_33622A.Keysight_33622A', ['USB0::0x0957::0x5707::MY53801461::INSTR'], {} ] } # Experiment List spyrelets = { 'holeburningsnspd':[ 'spyre.spy...
22.210526
69
0.620853
7988e04618038ea217e66ee04ab04eaedf36d665
695
py
Python
bitmovin_api_sdk/encoding/filters/enhanced_watermark/enhanced_watermark_filter_list_query_params.py
jaythecaesarean/bitmovin-api-sdk-python
48166511fcb9082041c552ace55a9b66cc59b794
[ "MIT" ]
11
2019-07-03T10:41:16.000Z
2022-02-25T21:48:06.000Z
bitmovin_api_sdk/encoding/filters/enhanced_watermark/enhanced_watermark_filter_list_query_params.py
jaythecaesarean/bitmovin-api-sdk-python
48166511fcb9082041c552ace55a9b66cc59b794
[ "MIT" ]
8
2019-11-23T00:01:25.000Z
2021-04-29T12:30:31.000Z
bitmovin_api_sdk/encoding/filters/enhanced_watermark/enhanced_watermark_filter_list_query_params.py
jaythecaesarean/bitmovin-api-sdk-python
48166511fcb9082041c552ace55a9b66cc59b794
[ "MIT" ]
13
2020-01-02T14:58:18.000Z
2022-03-26T12:10:30.000Z
class EnhancedWatermarkFilterListQueryParams(object): def __init__(self, offset=None, limit=None, name=None): # type: (int, int, string_types) -> None super(EnhancedWatermarkFilterListQueryParams, self).__init__() self.offset = offset self.limit = limit self.name = name ...
23.965517
70
0.539568
7988e08612a10e3f19bea971398510d29a4ef9cf
56,098
py
Python
tests/mail/tests.py
doordash/django
2f0e0eee450775a71ac3eb42707dcd970ede42c8
[ "PSF-2.0", "BSD-3-Clause" ]
1
2016-05-22T08:25:51.000Z
2016-05-22T08:25:51.000Z
tests/mail/tests.py
doordash/django
2f0e0eee450775a71ac3eb42707dcd970ede42c8
[ "PSF-2.0", "BSD-3-Clause" ]
null
null
null
tests/mail/tests.py
doordash/django
2f0e0eee450775a71ac3eb42707dcd970ede42c8
[ "PSF-2.0", "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- from __future__ import unicode_literals import asyncore import mimetypes import os import shutil import smtpd import sys import tempfile import threading from email.header import Header from email.mime.text import MIMEText from smtplib import SMTP, SMTPException from ssl import SSLError from d...
41.83296
119
0.626083
7988e0ef543a811eb44e6a3e4fde9b754a355b4d
9,804
py
Python
data/microenv_params.py
rheiland/pc4nanobio
02e2d3247f37f0a91f769b8dc284ad52f608ffed
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
null
null
null
data/microenv_params.py
rheiland/pc4nanobio
02e2d3247f37f0a91f769b8dc284ad52f608ffed
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
null
null
null
data/microenv_params.py
rheiland/pc4nanobio
02e2d3247f37f0a91f769b8dc284ad52f608ffed
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
2
2019-04-12T19:24:01.000Z
2020-03-14T22:53:17.000Z
# This file is auto-generated from a Python script that parses a PhysiCell configuration (.xml) file. # # Edit at your own risk. # import os from ipywidgets import Label,Text,Checkbox,Button,HBox,VBox,FloatText,IntText,BoundedIntText,BoundedFloatText,Layout,Box class MicroenvTab(object): def __init__(self):...
51.0625
140
0.695022
7988e199d056f08482c97142fcc77dc670f391fc
1,802
py
Python
src/EnvCNN/Exec/compute_ranksum.py
toppic-suite/envcnn
142d150e65b7fe7018904fa4536d2f1a7ece989d
[ "Apache-2.0" ]
1
2020-05-26T22:54:55.000Z
2020-05-26T22:54:55.000Z
src/EnvCNN/Exec/compute_ranksum.py
toppic-suite/envcnn
142d150e65b7fe7018904fa4536d2f1a7ece989d
[ "Apache-2.0" ]
null
null
null
src/EnvCNN/Exec/compute_ranksum.py
toppic-suite/envcnn
142d150e65b7fe7018904fa4536d2f1a7ece989d
[ "Apache-2.0" ]
null
null
null
##Copyright (c) 2014 - 2020, The Trustees of Indiana University. ## ##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 a...
34.653846
74
0.748613
7988e46d07c1d1baa45c44ae2d4a2c89d2d4fadf
1,060
py
Python
core/ext/cache.py
wyapx/FlashDetector
782305de7cbbc304056a3b71f4ce50eba21c78ba
[ "MIT" ]
1
2020-08-16T07:27:37.000Z
2020-08-16T07:27:37.000Z
core/ext/cache.py
wyapx/FlashDetector
782305de7cbbc304056a3b71f4ce50eba21c78ba
[ "MIT" ]
null
null
null
core/ext/cache.py
wyapx/FlashDetector
782305de7cbbc304056a3b71f4ce50eba21c78ba
[ "MIT" ]
null
null
null
class LRUCached: def __init__(self, max_size=500): self.max_size = max_size self.mapper = dict() self.priority = list() def pop(self, index=-1): return self.mapper.pop( self.priority.pop(index) ) def release(self, count): if count > self.max_size...
27.179487
86
0.576415
7988e4bbfcdd55cd19c017fb37a9a5c3202e85f4
15,526
py
Python
ibmsecurity/isam/aac/access_control/policy_attachments.py
keiran-ibm/ibmsecurity
b1a77f7a1e8c3cce67e2c3af85c20626d42c0bbd
[ "Apache-2.0" ]
null
null
null
ibmsecurity/isam/aac/access_control/policy_attachments.py
keiran-ibm/ibmsecurity
b1a77f7a1e8c3cce67e2c3af85c20626d42c0bbd
[ "Apache-2.0" ]
null
null
null
ibmsecurity/isam/aac/access_control/policy_attachments.py
keiran-ibm/ibmsecurity
b1a77f7a1e8c3cce67e2c3af85c20626d42c0bbd
[ "Apache-2.0" ]
null
null
null
import logging from ibmsecurity.utilities import tools logger = logging.getLogger(__name__) # URI for this module uri = "/iam/access/v8/policyattachments" def get_all(isamAppliance, filter=None, sortBy=None, check_mode=False, force=False): """ Retrieve a list of configured resources """ return isamA...
39.506361
140
0.619348
7988e5620c77db9fbc2395b1476c10cad42d5a2f
1,780
py
Python
test/testers/winforms/printpreviewcontrol/__init__.py
ABEMBARKA/monoUI
5fda266ad2db8f89580a40b525973d86cd8de939
[ "MIT" ]
1
2019-08-13T15:22:12.000Z
2019-08-13T15:22:12.000Z
test/testers/winforms/printpreviewcontrol/__init__.py
ABEMBARKA/monoUI
5fda266ad2db8f89580a40b525973d86cd8de939
[ "MIT" ]
null
null
null
test/testers/winforms/printpreviewcontrol/__init__.py
ABEMBARKA/monoUI
5fda266ad2db8f89580a40b525973d86cd8de939
[ "MIT" ]
1
2019-08-13T15:22:17.000Z
2019-08-13T15:22:17.000Z
############################################################################## # Written by: Cachen Chen <cachen@novell.com> # Date: 01/13/2009 # Application wrapper for printpreviewcontrol.py # Used by the printpreviewcontrol-*.py tests ###############################################...
35.6
154
0.646067
7988e57e6522e6eba3da858ab111656f85a6a007
665
py
Python
manage.py
joigmz/que-comer
1efb6877ec4c30b30e2ae44d31f4b810db51972a
[ "MIT" ]
null
null
null
manage.py
joigmz/que-comer
1efb6877ec4c30b30e2ae44d31f4b810db51972a
[ "MIT" ]
null
null
null
manage.py
joigmz/que-comer
1efb6877ec4c30b30e2ae44d31f4b810db51972a
[ "MIT" ]
null
null
null
#!/usr/bin/env python """Django's command-line utility for administrative tasks.""" import os import sys def main(): """Run administrative tasks.""" os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'que_comer.settings') try: from django.core.management import execute_from_command_line except Im...
28.913043
73
0.679699
7988e5c22c5ad72bdb56a9400dfee2d2f9057b5b
597
py
Python
mac/urls.py
blaze2004/meet-attendance-collector-web
259fd1900f4632df31c147e41e070e85885cfba8
[ "MIT" ]
1
2022-01-30T08:46:03.000Z
2022-01-30T08:46:03.000Z
mac/urls.py
blaze2004/trackit
bbef5dd86360456ba4b42a10200d83cd83336c6f
[ "MIT" ]
null
null
null
mac/urls.py
blaze2004/trackit
bbef5dd86360456ba4b42a10200d83cd83336c6f
[ "MIT" ]
1
2022-01-08T07:39:29.000Z
2022-01-08T07:39:29.000Z
from django.urls import path, include from django.urls.resolvers import URLPattern from . import views urlpatterns = [ path('', views.index, name='index'), path('dashboard/', views.dashboard, name='dashboard'), path('save/', views.save, name='save'), path('save-attendance/', views.save_to_database, nam...
42.642857
77
0.698492
7988e5c33aa55a3fcb2f7678b663e6c181461018
187
py
Python
data/python/944d7464b4c5b73ae19decbd546d1447_manage.py
maxim5/code-inspector
14812dfbc7bac1d76c4d9e5be2cdf83fc1c391a1
[ "Apache-2.0" ]
5
2018-01-03T06:43:07.000Z
2020-07-30T13:15:29.000Z
data/python/944d7464b4c5b73ae19decbd546d1447_manage.py
maxim5/code-inspector
14812dfbc7bac1d76c4d9e5be2cdf83fc1c391a1
[ "Apache-2.0" ]
null
null
null
data/python/944d7464b4c5b73ae19decbd546d1447_manage.py
maxim5/code-inspector
14812dfbc7bac1d76c4d9e5be2cdf83fc1c391a1
[ "Apache-2.0" ]
2
2019-11-04T02:54:49.000Z
2020-04-24T17:50:46.000Z
# manage.py from flaskext.script import Manager from myapp import app from myojin.custom_script import Manager manager = Manager(app) if __name__ == "__main__": manager.run()
15.583333
40
0.737968
7988e6295a45e0fbf6b3c8b38164c8d89c4398e5
1,363
py
Python
setup.py
SeldonIO/MLServer
270f89a4172e56aac06b3e4f18eac803171dba1d
[ "ECL-2.0", "Apache-2.0", "BSD-2-Clause", "BSD-3-Clause" ]
191
2020-06-16T18:07:27.000Z
2022-03-29T05:56:23.000Z
setup.py
SeldonIO/MLServer
270f89a4172e56aac06b3e4f18eac803171dba1d
[ "ECL-2.0", "Apache-2.0", "BSD-2-Clause", "BSD-3-Clause" ]
347
2020-08-21T02:22:04.000Z
2022-03-31T12:27:26.000Z
setup.py
SeldonIO/MLServer
270f89a4172e56aac06b3e4f18eac803171dba1d
[ "ECL-2.0", "Apache-2.0", "BSD-2-Clause", "BSD-3-Clause" ]
56
2020-06-22T14:29:25.000Z
2022-03-25T21:58:48.000Z
import os from typing import Dict from setuptools import setup, find_packages ROOT_PATH = os.path.dirname(__file__) PKG_NAME = "mlserver" PKG_PATH = os.path.join(ROOT_PATH, PKG_NAME) def _load_version() -> str: version = "" version_path = os.path.join(PKG_PATH, "version.py") with open(version_path) as f...
25.716981
69
0.646368
7988e6a62a940b2a7b8dc1acc31c41c67fc3133b
4,076
py
Python
scripts/make_release.py
raspberrypieman/brython
2cc23d1da6acda604d4a56b4c9d464eb7e374eda
[ "BSD-3-Clause" ]
1
2021-02-08T12:00:26.000Z
2021-02-08T12:00:26.000Z
scripts/make_release.py
raspberrypieman/brython
2cc23d1da6acda604d4a56b4c9d464eb7e374eda
[ "BSD-3-Clause" ]
null
null
null
scripts/make_release.py
raspberrypieman/brython
2cc23d1da6acda604d4a56b4c9d464eb7e374eda
[ "BSD-3-Clause" ]
null
null
null
import os import re import tarfile import zipfile import shutil # generate html files that compare Brython and CPython distributions import make_stdlib_list from make_dist import run, pdir, vname, abs_path run() release_dir = os.path.join(pdir, "releases") # update package.json print("Update package.json...") pack...
32.870968
73
0.640579
7988e7899d2b9627cb8755c0d12730707ffc1b86
1,951
py
Python
test/test_niaapi_hardware_eol_all_of.py
sdnit-se/intersight-python
551f7685c0f76bb8af60ec83ffb6f9672d49a4ae
[ "Apache-2.0" ]
21
2018-03-29T14:20:35.000Z
2021-10-13T05:11:41.000Z
test/test_niaapi_hardware_eol_all_of.py
sdnit-se/intersight-python
551f7685c0f76bb8af60ec83ffb6f9672d49a4ae
[ "Apache-2.0" ]
14
2018-01-30T15:45:46.000Z
2022-02-23T14:23:21.000Z
test/test_niaapi_hardware_eol_all_of.py
sdnit-se/intersight-python
551f7685c0f76bb8af60ec83ffb6f9672d49a4ae
[ "Apache-2.0" ]
18
2018-01-03T15:09:56.000Z
2021-07-16T02:21:54.000Z
# coding: utf-8 """ Cisco Intersight Cisco Intersight is a management platform delivered as a service with embedded analytics for your Cisco and 3rd party IT infrastructure. This platform offers an intelligent level of management that enables IT organizations to analyze, simplify, and automate their environmen...
51.342105
1,052
0.784213
7988e81293c1b866688147265a66fe727c905ae6
5,980
py
Python
datasets/squad_adversarial/squad_adversarial.py
Hzfinfdu/DataLab
0da0226866f59ed2e535c346833f0797499b5174
[ "Apache-2.0" ]
null
null
null
datasets/squad_adversarial/squad_adversarial.py
Hzfinfdu/DataLab
0da0226866f59ed2e535c346833f0797499b5174
[ "Apache-2.0" ]
null
null
null
datasets/squad_adversarial/squad_adversarial.py
Hzfinfdu/DataLab
0da0226866f59ed2e535c346833f0797499b5174
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 # Copyright 2020 The HuggingFace Datasets Authors and DataLab 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 # # Un...
45.30303
943
0.632441
7988e9aaada21d1947a6c61cb764013e7613b04c
8,436
py
Python
ml/utils/load_data.py
saharshy29/altML
3c107af1c3b0416e7d78d612ac8254ccfdb1cc7a
[ "MIT" ]
5
2020-07-31T15:01:03.000Z
2020-08-16T12:38:02.000Z
ml/utils/load_data.py
saharshxyz/altML
3c107af1c3b0416e7d78d612ac8254ccfdb1cc7a
[ "MIT" ]
11
2020-07-30T22:49:46.000Z
2020-08-06T22:53:54.000Z
ml/utils/load_data.py
saharshxyz/altML
3c107af1c3b0416e7d78d612ac8254ccfdb1cc7a
[ "MIT" ]
2
2020-11-19T05:56:53.000Z
2020-11-19T05:57:49.000Z
import numpy as np from tensorflow import keras from utils.preprocessing import * from pickle import load, dump import random ''' *We have Flickr_8k.trainImages.txt and Flickr_8k.devImages.txt files which consist of unique identifiers(id) which can be used to filter the images and their descriptions *Load ...
41.352941
133
0.72155
7988e9d00228b90a96c4ca003dfd463c09cdefb0
114,361
py
Python
src/sentry/south_migrations/0437_auto__add_field_sentryapp_status.py
boblail/sentry
71127331e58791d4651e480b65dd66f06cadc1c8
[ "BSD-3-Clause" ]
1
2018-12-04T12:57:00.000Z
2018-12-04T12:57:00.000Z
src/sentry/south_migrations/0437_auto__add_field_sentryapp_status.py
boblail/sentry
71127331e58791d4651e480b65dd66f06cadc1c8
[ "BSD-3-Clause" ]
1
2021-05-09T11:43:43.000Z
2021-05-09T11:43:43.000Z
src/sentry/south_migrations/0437_auto__add_field_sentryapp_status.py
gaybro8777/sentry
4594f479db9a079d7f1ed41a9e07d8f36953319f
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- from south.utils import datetime_utils as datetime from south.db import db from south.v2 import SchemaMigration from django.db import models class Migration(SchemaMigration): # Flag to indicate if this migration is too risky # to run online and needs to be coordinated for offline ...
92.301049
236
0.590219
7988ea31d12fdbed14603444c8bd606446dffec2
1,260
py
Python
callblocker/blocker/api/text_search.py
gmega/callblocker
212ca8521ce53adb8c97acf06e03c1c5d291adf9
[ "BSD-3-Clause" ]
9
2019-12-02T23:59:44.000Z
2022-03-01T09:59:48.000Z
callblocker/blocker/api/text_search.py
gmega/callblocker
212ca8521ce53adb8c97acf06e03c1c5d291adf9
[ "BSD-3-Clause" ]
7
2021-04-08T19:25:38.000Z
2022-02-26T15:09:02.000Z
callblocker/blocker/api/text_search.py
gmega/callblocker
212ca8521ce53adb8c97acf06e03c1c5d291adf9
[ "BSD-3-Clause" ]
null
null
null
import logging from django.conf import settings from django.db import ProgrammingError logger = logging.getLogger(__name__) def handle_connection(**kwargs): with kwargs['connection'].cursor() as cursor: # Ideally, we'd do this as a migration. But set_limit has to be set on a session basis, so we ...
46.666667
109
0.684921
7988ed54918e24a62193f489e4fd145a772df90c
3,087
py
Python
ranger/plugins/service.py
J-HaleOf76/rnvimr
5877509cfdbf3a0382ff24198a3f730b476f8262
[ "BSD-3-Clause" ]
1
2021-10-09T13:51:28.000Z
2021-10-09T13:51:28.000Z
ranger/plugins/service.py
J-HaleOf76/rnvimr
5877509cfdbf3a0382ff24198a3f730b476f8262
[ "BSD-3-Clause" ]
null
null
null
ranger/plugins/service.py
J-HaleOf76/rnvimr
5877509cfdbf3a0382ff24198a3f730b476f8262
[ "BSD-3-Clause" ]
null
null
null
""" Build the service of ranger """ from ranger.core.loader import Loadable from ranger.core.shared import FileManagerAware class Service(FileManagerAware): """ Service called by neovim """ class Register(): # pylint: disable=too-few-public-methods """ Using a class to decorate the...
22.208633
80
0.568189
7988ed613333668e2e7812e3a9e2aec3f88023dc
1,442
py
Python
packages/watchmen-data-kernel/src/watchmen_data_kernel/cache/key_store_cache.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-data-kernel/src/watchmen_data_kernel/cache/key_store_cache.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-data-kernel/src/watchmen_data_kernel/cache/key_store_cache.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
from typing import List, Optional, Tuple from watchmen_model.common import TenantId from watchmen_model.system import KeyStore from .cache_manager import get_key_store_by_type_cache from .internal_cache import InternalCache class KeyStoreCache: """ key store cache will not impact other caches """ def __init__(s...
28.84
90
0.742025
7988ef916f120eed020d906a2bc619ef37bf99d4
12,048
py
Python
src/learners/max_q_learner.py
benellis3/pymarl2
0875995a0e0b9692ea64484478b369c7f6c0cf44
[ "Apache-2.0" ]
4
2022-03-17T05:01:30.000Z
2022-03-17T05:09:17.000Z
src/learners/max_q_learner.py
benellis3/pymarl2
0875995a0e0b9692ea64484478b369c7f6c0cf44
[ "Apache-2.0" ]
null
null
null
src/learners/max_q_learner.py
benellis3/pymarl2
0875995a0e0b9692ea64484478b369c7f6c0cf44
[ "Apache-2.0" ]
null
null
null
import copy from components.episode_buffer import EpisodeBatch from modules.mixers.vdn import VDNMixer from modules.mixers.qmix import QMixer from modules.mixers.qmix_central_no_hyper import QMixerCentralFF from utils.rl_utils import build_td_lambda_targets import torch as th from torch.optim import RMSprop from collec...
46.697674
195
0.641932
7988f098301446294c3165439740d397aae74072
3,908
py
Python
store_app/models.py
raresrusu38/OnlineShop
65bf984c3703c7f3fce8e3a6aea3a472c63c9f7d
[ "MIT" ]
null
null
null
store_app/models.py
raresrusu38/OnlineShop
65bf984c3703c7f3fce8e3a6aea3a472c63c9f7d
[ "MIT" ]
null
null
null
store_app/models.py
raresrusu38/OnlineShop
65bf984c3703c7f3fce8e3a6aea3a472c63c9f7d
[ "MIT" ]
null
null
null
from django.db import models from django.utils import timezone from ckeditor.fields import RichTextField # Create your models here. class Categories(models.Model): name = models.CharField(max_length=200) def __str__(self): return self.name class Meta: verbose_name = "Cat...
26.585034
103
0.595445
7988f0cafecebec83ba714de967b2f7b970d9f66
497
py
Python
tests/test_frameworks/test_plain_django.py
optimalstrategy/Qval
1843d0195bc8adb21ed3742eb505749d80b01c85
[ "MIT" ]
2
2018-11-17T08:46:33.000Z
2019-03-17T10:22:35.000Z
tests/test_frameworks/test_plain_django.py
OptimalStrategy/Qval
a1030228cf49ef43ae6d0103018798121a53a9a1
[ "MIT" ]
217
2018-12-14T22:00:31.000Z
2020-11-03T05:35:44.000Z
tests/test_frameworks/test_plain_django.py
optimalstrategy/Qval
1843d0195bc8adb21ed3742eb505749d80b01c85
[ "MIT" ]
null
null
null
# coding: utf-8 import time import pytest from tests.test_frameworks.common import start_server from tests.test_frameworks.api_test_functions import * # Common tests from `api_test_functions` will be ran on the django server @pytest.mark.plain_django @pytest.fixture(scope="module") def server(request): print("St...
26.157895
73
0.758551
7988f16c3a580d9001d38796ec2f67ad65a9bc45
7,282
py
Python
remo/reports/tasks.py
Mozilla-GitHub-Standards/6f6b18ac63685c6bf60fff95a3bbcc598378c77ceb14c7404172c570dd1e971d
23ca8d46496b491fbdb2b8a72c91e75372932f23
[ "BSD-3-Clause" ]
27
2015-01-02T18:47:56.000Z
2021-08-14T11:48:24.000Z
remo/reports/tasks.py
Mozilla-GitHub-Standards/6f6b18ac63685c6bf60fff95a3bbcc598378c77ceb14c7404172c570dd1e971d
23ca8d46496b491fbdb2b8a72c91e75372932f23
[ "BSD-3-Clause" ]
450
2015-01-02T12:29:50.000Z
2020-10-27T21:41:38.000Z
remo/reports/tasks.py
Mozilla-GitHub-Standards/6f6b18ac63685c6bf60fff95a3bbcc598378c77ceb14c7404172c570dd1e971d
23ca8d46496b491fbdb2b8a72c91e75372932f23
[ "BSD-3-Clause" ]
81
2015-01-10T23:59:32.000Z
2021-08-19T17:08:56.000Z
from datetime import datetime, timedelta from django.conf import settings from django.contrib.auth.models import User from django.contrib.contenttypes.models import ContentType from django.core.mail import send_mail from django.db.models import Q from django.template.loader import render_to_string from django.utils.ti...
38.941176
84
0.651195
7988f218ba032d4196b4e84ad13155938998f293
993
py
Python
ratelimit/hungryclient.py
DudkinON/securing
5af3e1d214b979ca5be2d870ddf32acc00f77cc2
[ "MIT" ]
null
null
null
ratelimit/hungryclient.py
DudkinON/securing
5af3e1d214b979ca5be2d870ddf32acc00f77cc2
[ "MIT" ]
null
null
null
ratelimit/hungryclient.py
DudkinON/securing
5af3e1d214b979ca5be2d870ddf32acc00f77cc2
[ "MIT" ]
null
null
null
from __future__ import division from time import sleep import httplib2 import json h = httplib2.Http() url = 'http://127.0.0.1:5000/rate-limited' req_per_minute = 100 #float(input("Please specify the number of requests per minute: ")) interval = (60.0 / req_per_minute) def SendRequests(url, req_per_minute): ...
27.583333
79
0.619335