hexsha
stringlengths
40
40
size
int64
5
2.06M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
3
248
max_stars_repo_name
stringlengths
5
125
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
3
248
max_issues_repo_name
stringlengths
5
125
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
67k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
3
248
max_forks_repo_name
stringlengths
5
125
max_forks_repo_head_hexsha
stringlengths
40
78
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
5
2.06M
avg_line_length
float64
1
1.02M
max_line_length
int64
3
1.03M
alphanum_fraction
float64
0
1
count_classes
int64
0
1.6M
score_classes
float64
0
1
count_generators
int64
0
651k
score_generators
float64
0
1
count_decorators
int64
0
990k
score_decorators
float64
0
1
count_async_functions
int64
0
235k
score_async_functions
float64
0
1
count_documentation
int64
0
1.04M
score_documentation
float64
0
1
bd7f5d02897acbff32966f7928ccfc825cfa419a
3,548
py
Python
apartmentbot/services/listing_service.py
sgarfield/ApartmentBot
327a47e879998fbb40bd26f84510467f4757d330
[ "MIT" ]
null
null
null
apartmentbot/services/listing_service.py
sgarfield/ApartmentBot
327a47e879998fbb40bd26f84510467f4757d330
[ "MIT" ]
null
null
null
apartmentbot/services/listing_service.py
sgarfield/ApartmentBot
327a47e879998fbb40bd26f84510467f4757d330
[ "MIT" ]
null
null
null
""" apartmentbot.services.listing_service """ import logging from dataclasses import dataclass from typing import List from dataclasses_json import dataclass_json from apartmentbot.geolocation.geolocation import distance_finder, neighborhood_locator, place_locator from apartmentbot.models import Listing, Place, Prefe...
45.487179
101
0.698985
3,076
0.866967
0
0
3,103
0.874577
0
0
855
0.240981
bd7f8e09909844b7662e6b08100c7c6fbbff9197
6,016
py
Python
stocky.py
Naphtha/stocky
04e51b4270b28a1aa23597c07d67a2a99e4710cf
[ "MIT" ]
null
null
null
stocky.py
Naphtha/stocky
04e51b4270b28a1aa23597c07d67a2a99e4710cf
[ "MIT" ]
null
null
null
stocky.py
Naphtha/stocky
04e51b4270b28a1aa23597c07d67a2a99e4710cf
[ "MIT" ]
null
null
null
import requests import json BASE_URL = "https://api.stockfighter.io/ob/api/" class StockMinion(object): '''Handles all API related requests for stock/order functionality''' def __init__(self, api_key, account, venue, stock): # use sessions to persist the HTTP connection # this will preve...
30.231156
126
0.617686
4,292
0.713431
0
0
533
0.088597
0
0
1,633
0.271443
bd8031a5c133b457ce688112eb2e76fc2cc5af7d
54
py
Python
test.py
periclescy/research-qre
7fafbc7120235fe6cb75a2f5477922d813c31066
[ "OLDAP-2.3" ]
null
null
null
test.py
periclescy/research-qre
7fafbc7120235fe6cb75a2f5477922d813c31066
[ "OLDAP-2.3" ]
null
null
null
test.py
periclescy/research-qre
7fafbc7120235fe6cb75a2f5477922d813c31066
[ "OLDAP-2.3" ]
null
null
null
for i in range(4): print(i) print("Hello world")
10.8
20
0.611111
0
0
0
0
0
0
0
0
13
0.240741
bd80d005cadf2946180d02a5ee8eb0ce0d0f3e91
6,481
py
Python
crawlers/ucsc_old/ucsc/spiders/registrar_courses.py
coursegraph/CourseGraph
9f05cd912b393ba14721411fe77f3856812c000f
[ "MIT" ]
5
2018-07-01T15:48:11.000Z
2020-07-31T17:06:10.000Z
crawlers/ucsc_old/ucsc/spiders/registrar_courses.py
coursegraph/CourseGraph
9f05cd912b393ba14721411fe77f3856812c000f
[ "MIT" ]
7
2018-07-09T21:17:19.000Z
2018-07-25T17:05:33.000Z
crawlers/ucsc_old/ucsc/spiders/registrar_courses.py
coursegraph/CourseGraph
9f05cd912b393ba14721411fe77f3856812c000f
[ "MIT" ]
4
2018-07-01T19:45:23.000Z
2019-03-17T21:12:03.000Z
# -*- coding: utf-8 -*- import scrapy import os from ucsc.items import FacultyItem, ProgramStatementItem, CourseDescriptionItem def path_components (path): if '://' in path: path = path.split('://')[1] parts = path.split('/') while parts and parts[0] == '': parts = parts[1:] while part...
39.760736
117
0.583552
4,783
0.738003
2,911
0.449159
0
0
0
0
1,907
0.294245
bd82bc5f657a9986b7a9b6aa8522cff06f897b1e
9,528
py
Python
yui/migrations/versions/0e7bdd5c7473_refactor_datetime_fields.py
item4/yui
8628d0d54b94ada3cbe7d1b0f624063258bad10a
[ "MIT" ]
36
2017-06-12T01:09:46.000Z
2021-01-31T17:57:41.000Z
yui/migrations/versions/0e7bdd5c7473_refactor_datetime_fields.py
item4/yui
8628d0d54b94ada3cbe7d1b0f624063258bad10a
[ "MIT" ]
145
2017-06-21T13:31:29.000Z
2021-06-20T01:01:30.000Z
yui/migrations/versions/0e7bdd5c7473_refactor_datetime_fields.py
item4/yui
8628d0d54b94ada3cbe7d1b0f624063258bad10a
[ "MIT" ]
21
2017-07-24T15:53:19.000Z
2021-12-23T04:18:31.000Z
"""Refactor datetime fields Revision ID: 0e7bdd5c7473 Revises: Create Date: 2020-05-10 17:28:07.620112 """ import enum from alembic import op import sqlalchemy as sa from sqlalchemy_utils import ChoiceType from sqlalchemy_utils import URLType from yui.apps.info.toranoana.models import Stock from yui.apps.info.to...
33.787234
75
0.592149
36
0.003778
0
0
49
0.005143
0
0
2,014
0.211377
bd82c29e5bee15a3671a883151076960c6a72038
1,937
py
Python
gradient_free_optimizers/optimizers/exp_opt/local_bayes_opt.py
Wollala/Gradient-Free-Optimizers
8fb1608c264431b87f66fd2d233b76a0fa75316c
[ "MIT" ]
1
2022-02-25T03:14:48.000Z
2022-02-25T03:14:48.000Z
gradient_free_optimizers/optimizers/exp_opt/local_bayes_opt.py
Wollala/Gradient-Free-Optimizers
8fb1608c264431b87f66fd2d233b76a0fa75316c
[ "MIT" ]
null
null
null
gradient_free_optimizers/optimizers/exp_opt/local_bayes_opt.py
Wollala/Gradient-Free-Optimizers
8fb1608c264431b87f66fd2d233b76a0fa75316c
[ "MIT" ]
null
null
null
# Author: Simon Blanke # Email: simon.blanke@yahoo.com # License: MIT License import time import random import numpy as np from ..base_optimizer import BaseOptimizer from ...search import Search from ._sub_search_spaces import SubSearchSpaces from ..smb_opt import BayesianOptimizer class LocalBayesianOptimizer(Base...
27.671429
82
0.665978
1,649
0.851316
0
0
181
0.093443
0
0
101
0.052142
bd83ed580ee241d7bccf7170f916c7c26cd0e7da
2,235
py
Python
storage.py
computer-micro-mangangement/cmm_hub
1ec4ed8c86edcbbd5624396a4be1d6aa7e6132fb
[ "MIT" ]
null
null
null
storage.py
computer-micro-mangangement/cmm_hub
1ec4ed8c86edcbbd5624396a4be1d6aa7e6132fb
[ "MIT" ]
null
null
null
storage.py
computer-micro-mangangement/cmm_hub
1ec4ed8c86edcbbd5624396a4be1d6aa7e6132fb
[ "MIT" ]
null
null
null
import psutil from appJar import gui import config import requests as req import json import platform import sysInfo app = gui(title="CMM Hub", showIcon=False) navBarElements = [] navBarElementsCallName = [] currentContainer = "" def get_size(bytes, suffix="B"): """ Scale bytes to its proper format e.g: ...
28.653846
88
0.630425
0
0
0
0
0
0
0
0
388
0.173602
bd85a5016f4253e00cc44d9424523f4276b499b6
128
py
Python
python/testData/completion/heavyStarPropagation/lib/_pkg0/_pkg0_1/_pkg0_1_0/_pkg0_1_0_1/_pkg0_1_0_1_0/_mod0_1_0_1_0_4.py
jnthn/intellij-community
8fa7c8a3ace62400c838e0d5926a7be106aa8557
[ "Apache-2.0" ]
2
2019-04-28T07:48:50.000Z
2020-12-11T14:18:08.000Z
python/testData/completion/heavyStarPropagation/lib/_pkg0/_pkg0_1/_pkg0_1_0/_pkg0_1_0_1/_pkg0_1_0_1_0/_mod0_1_0_1_0_4.py
jnthn/intellij-community
8fa7c8a3ace62400c838e0d5926a7be106aa8557
[ "Apache-2.0" ]
173
2018-07-05T13:59:39.000Z
2018-08-09T01:12:03.000Z
python/testData/completion/heavyStarPropagation/lib/_pkg0/_pkg0_1/_pkg0_1_0/_pkg0_1_0_1/_pkg0_1_0_1_0/_mod0_1_0_1_0_4.py
jnthn/intellij-community
8fa7c8a3ace62400c838e0d5926a7be106aa8557
[ "Apache-2.0" ]
2
2020-03-15T08:57:37.000Z
2020-04-07T04:48:14.000Z
name0_1_0_1_0_4_0 = None name0_1_0_1_0_4_1 = None name0_1_0_1_0_4_2 = None name0_1_0_1_0_4_3 = None name0_1_0_1_0_4_4 = None
14.222222
24
0.820313
0
0
0
0
0
0
0
0
0
0
bd86643159f81b1a7609b03844ed56a6c9324674
1,988
py
Python
teste.py
yagopessoa/extrator-caracteristicas
8fb54359836f2a7063fb34849bfdb1b4c88188b1
[ "MIT" ]
null
null
null
teste.py
yagopessoa/extrator-caracteristicas
8fb54359836f2a7063fb34849bfdb1b4c88188b1
[ "MIT" ]
4
2021-03-19T01:36:12.000Z
2022-01-13T01:21:07.000Z
teste.py
yagopessoa/extrator-caracteristicas
8fb54359836f2a7063fb34849bfdb1b4c88188b1
[ "MIT" ]
null
null
null
#!/usr/bin/python3 import cv2 import numpy as np import sys import os import pickle import datetime import base64 import io from matplotlib import pyplot as plt from PIL import Image import extract_feature # x = np.random.randint(25,100,25) # y = np.random.randint(175,255,25) # z = np.hstack((x,y)) # z = z.reshape((...
30.121212
145
0.71328
0
0
0
0
0
0
0
0
1,335
0.671529
bd87f0189f7348f8a469b192ca7c10a825cc2fa1
95
py
Python
lampions/__init__.py
Lampions/lampions
dac00e739b6361820f400a3a439dadd5d265c0d7
[ "BSD-3-Clause" ]
null
null
null
lampions/__init__.py
Lampions/lampions
dac00e739b6361820f400a3a439dadd5d265c0d7
[ "BSD-3-Clause" ]
null
null
null
lampions/__init__.py
Lampions/lampions
dac00e739b6361820f400a3a439dadd5d265c0d7
[ "BSD-3-Clause" ]
null
null
null
from . import console from .version import __version__ # noqa def main(): console.run()
13.571429
40
0.694737
0
0
0
0
0
0
0
0
6
0.063158
bd884de362569f988f5fe329cd6525259b1ae410
1,840
py
Python
lawliet/mono/resample.py
Ryuk17/lawliet
ba4734557260b255896707210fca3e2fff311e87
[ "Apache-2.0" ]
2
2021-04-20T03:51:32.000Z
2021-06-16T11:48:06.000Z
lawliet/mono/resample.py
Ryuk17/lawliet
ba4734557260b255896707210fca3e2fff311e87
[ "Apache-2.0" ]
null
null
null
lawliet/mono/resample.py
Ryuk17/lawliet
ba4734557260b255896707210fca3e2fff311e87
[ "Apache-2.0" ]
null
null
null
""" @FileName: resample.py @Description: Implement resample @Author: Ryuk @CreateDate: 2021/06/27 @LastEditTime: 2021/06/27 @LastEditors: Please set LastEditors @Version: v0.1 """ import numpy as np import math __all__ = [ "direct_interpolation", "lagrange_interpolation", "sine_interpolation", ] def dir...
23.589744
54
0.490761
0
0
0
0
0
0
0
0
424
0.230435
bd89d14addd7fd9824eb02e80c4487068be6700a
1,432
py
Python
data/get_stats.py
joamatab/angler
d54d3718bfc8564f0a97faf89a8de747709be6b9
[ "MIT" ]
102
2018-11-06T16:11:58.000Z
2022-03-29T03:10:08.000Z
data/get_stats.py
bencbartlett/angler
db9eca35adc4708425de8e2e2ad7a06516966814
[ "MIT" ]
17
2018-11-06T15:53:15.000Z
2020-07-21T20:20:30.000Z
data/get_stats.py
bencbartlett/angler
db9eca35adc4708425de8e2e2ad7a06516966814
[ "MIT" ]
41
2018-11-21T08:43:03.000Z
2022-03-22T21:21:42.000Z
import numpy as np from device_saver import load_device """ Opens a device and prints its stored stats for the paper""" def get_stats(fname): print("\n============================================================") D = load_device(fname) print('input power of {:.4f} mW/um'.format(D.W_in*1000)) if ha...
36.717949
95
0.569134
0
0
0
0
0
0
0
0
624
0.435754
bd8b0ea4d67316a57577ad9cd394adb4172f74c1
2,130
py
Python
src/demo.py
lhcezx/Graph-FPN
55eb9283a7df83e003c84eede65a2700bb9fa45c
[ "MIT" ]
19
2021-11-16T05:32:45.000Z
2022-01-27T09:29:50.000Z
src/demo.py
lhcezx/Graph-FPN
55eb9283a7df83e003c84eede65a2700bb9fa45c
[ "MIT" ]
1
2021-11-15T15:44:45.000Z
2021-12-13T04:26:26.000Z
src/demo.py
lhcezx/Graph-FPN
55eb9283a7df83e003c84eede65a2700bb9fa45c
[ "MIT" ]
1
2022-01-04T14:10:58.000Z
2022-01-04T14:10:58.000Z
import os import zipfile import tensorflow as tf import tensorflow_datasets as tfds import init_path from configs.configs import parse_configs from detection.utils.Label import * from detection.utils.preprocess import * from model.network import DecodePredictions from model.get_model import backbone, models config = p...
39.444444
99
0.656338
0
0
0
0
0
0
0
0
252
0.11831
bd8b4af603fe82e4afc80393a64f4cdf97c3311e
337
py
Python
dfmbot/fb_dfmbot/models.py
acjh/dfm-bot
34a7d53861acea6a7287c9b4816806db864adb31
[ "MIT" ]
null
null
null
dfmbot/fb_dfmbot/models.py
acjh/dfm-bot
34a7d53861acea6a7287c9b4816806db864adb31
[ "MIT" ]
null
null
null
dfmbot/fb_dfmbot/models.py
acjh/dfm-bot
34a7d53861acea6a7287c9b4816806db864adb31
[ "MIT" ]
null
null
null
from __future__ import unicode_literals from django.db import models # Create your models here. class Person(models.Model): first_name = models.CharField(max_length=30) last_name = models.CharField(max_length=30) fbid = models.CharField(max_length=64, primary_key=True) last_message = models.CharField...
28.083333
60
0.774481
237
0.703264
0
0
0
0
0
0
26
0.077151
bd8bd77a5f4099e04b2c3dc2363a8eb44444ab90
16,569
py
Python
routelift_api/stops/tests.py
BitMask-Technologies/route-lift-api
7ac78c6cce523fc5a3852dca7b289fe3a5f3afa8
[ "MIT" ]
null
null
null
routelift_api/stops/tests.py
BitMask-Technologies/route-lift-api
7ac78c6cce523fc5a3852dca7b289fe3a5f3afa8
[ "MIT" ]
7
2021-06-24T16:12:09.000Z
2021-08-05T16:09:22.000Z
routelift_api/stops/tests.py
BitMask-Technologies/route-lift-api
7ac78c6cce523fc5a3852dca7b289fe3a5f3afa8
[ "MIT" ]
null
null
null
from datetime import datetime from django.contrib.auth.hashers import make_password from Logistics.models import LogisticCompanies from roles_and_permissions.operations import Operations from roles_and_permissions.resource_categories import ResourceCategories from roles_and_permissions.utils import createStaffRole fr...
41.735516
124
0.5153
15,977
0.964271
0
0
5,282
0.318788
0
0
5,034
0.30382
bd8ea1d2de449075397b869d74b1b5b0f41e34e1
550
py
Python
exercicios-python/ex042.py
DaviStalleiken/codigos-de-desafios
e9ec388022b5f4bb2a5ab170c17969154ceaece3
[ "MIT" ]
null
null
null
exercicios-python/ex042.py
DaviStalleiken/codigos-de-desafios
e9ec388022b5f4bb2a5ab170c17969154ceaece3
[ "MIT" ]
null
null
null
exercicios-python/ex042.py
DaviStalleiken/codigos-de-desafios
e9ec388022b5f4bb2a5ab170c17969154ceaece3
[ "MIT" ]
null
null
null
r1 = float(input('Primeiro segmento: ')) r2 = float(input('Segundo segmento: ')) r3 = float(input('Terceiro segmento: ')) if r1 < r2 + r3 and r2 < r1 + r3 and r3 < r2 + r3: print('Você \033[32mpode\033[m formar um triângulo. ', end='') if r1 == r2 == r3: print(f'Seu triângulo é \033[36mequilátero\033[m...
36.666667
66
0.612727
0
0
0
0
0
0
0
0
303
0.538188
bd8fec37c8f22bdce7067ff7cbd8f9c6cdace31b
1,158
py
Python
mimic/GUI/MainWindow.py
link00000000/mimic
9452f4311e70deb23286504d9b02c64b9a76e14c
[ "MIT" ]
2
2021-07-29T04:30:34.000Z
2021-08-06T04:58:39.000Z
mimic/GUI/MainWindow.py
link00000000/mimic
9452f4311e70deb23286504d9b02c64b9a76e14c
[ "MIT" ]
20
2021-04-02T17:03:53.000Z
2021-08-07T11:04:09.000Z
mimic/GUI/MainWindow.py
link00000000/mimic
9452f4311e70deb23286504d9b02c64b9a76e14c
[ "MIT" ]
null
null
null
"""Mimic main window.""" import tkinter as tk from mimic.EventEmitter import EventEmitter from mimic.GUI.AbstractTkinterWindow import AbstractTkinterWindow from mimic.GUI.Widgets.QRCode import QRCodeImage from mimic.Utils.Host import resolve_host class MainWindow(AbstractTkinterWindow, EventEmitter): """Mimic ma...
27.571429
70
0.644214
907
0.783247
0
0
0
0
0
0
490
0.423143
bd910c797a7c02460f8f88af118cb92f19b632c2
1,857
py
Python
generate_30000.py
mikamai/uwsgi.it
d2f11ae850efda43532454ab70aa50540df0011b
[ "MIT" ]
null
null
null
generate_30000.py
mikamai/uwsgi.it
d2f11ae850efda43532454ab70aa50540df0011b
[ "MIT" ]
null
null
null
generate_30000.py
mikamai/uwsgi.it
d2f11ae850efda43532454ab70aa50540df0011b
[ "MIT" ]
null
null
null
from django.conf import settings from django.template.loader import render_to_string import ConfigParser from collections import OrderedDict import sys from Crypto.PublicKey import RSA class AllowsSameKeys(OrderedDict): def __setitem__(self, key, value): if isinstance(value, list) and key in self: ...
32.578947
111
0.653204
627
0.337641
0
0
0
0
0
0
502
0.270328
bd91ba13b85667cd92a61109fae15aca6df3f93b
3,561
py
Python
LoveDA/uda/baseline_train.py
edornd/ProDA
ffb092afbbde95e4ca29cb1ec199f9685f6601fb
[ "MIT" ]
null
null
null
LoveDA/uda/baseline_train.py
edornd/ProDA
ffb092afbbde95e4ca29cb1ec199f9685f6601fb
[ "MIT" ]
null
null
null
LoveDA/uda/baseline_train.py
edornd/ProDA
ffb092afbbde95e4ca29cb1ec199f9685f6601fb
[ "MIT" ]
null
null
null
import argparse import os import os.path as osp import torch import torch.nn as nn import torch.optim as optim from eval import evaluate from ever.core.iterator import Iterator from module.deeplabv2 import Deeplab from torch.nn import functional as fn from tqdm import tqdm from data.loveda import LoveDALoader from uti...
33.914286
114
0.627352
0
0
0
0
0
0
0
0
886
0.248807
bd964ac6777bf26c9cd2e0c8102f286788f8ac58
201
py
Python
lab/db/utils.py
ParanoiaSYT/Qulab-backup
09ec5457145b3789d4c1ac02c43dd3e6dfafc96f
[ "MIT" ]
null
null
null
lab/db/utils.py
ParanoiaSYT/Qulab-backup
09ec5457145b3789d4c1ac02c43dd3e6dfafc96f
[ "MIT" ]
null
null
null
lab/db/utils.py
ParanoiaSYT/Qulab-backup
09ec5457145b3789d4c1ac02c43dd3e6dfafc96f
[ "MIT" ]
null
null
null
import os def beforeSaveFile(fname): '''makesure the path exists before save file''' dirname = os.path.dirname(fname) if not os.path.exists(dirname): os.makedirs(dirname)
22.333333
52
0.651741
0
0
0
0
0
0
0
0
47
0.233831
bd979067fb3d0b6a4ab0071970a4c14f2b400d8d
1,478
py
Python
terra/estimators/migrations/0001_initial.py
dymaxionlabs/platform
98fe893d4632d62fea3e2357f16d970014037cdf
[ "BSD-3-Clause" ]
null
null
null
terra/estimators/migrations/0001_initial.py
dymaxionlabs/platform
98fe893d4632d62fea3e2357f16d970014037cdf
[ "BSD-3-Clause" ]
null
null
null
terra/estimators/migrations/0001_initial.py
dymaxionlabs/platform
98fe893d4632d62fea3e2357f16d970014037cdf
[ "BSD-3-Clause" ]
null
null
null
# Generated by Django 2.2 on 2019-04-22 13:45 import django.contrib.postgres.fields.jsonb from django.db import migrations, models import django.db.models.deletion import uuid class Migration(migrations.Migration): initial = True dependencies = [ ('projects', '0030_allow_null_in_projects_groups_and...
42.228571
150
0.631258
1,298
0.878214
0
0
0
0
0
0
344
0.232747
bd97ac57a2038b6973c0d833aeb1a199dd43dec5
1,607
py
Python
d16/p1.py
Jamie-Chang/advent2019
130ccdc2a320d0a8d926a781a41fd74389e403a9
[ "Apache-2.0" ]
null
null
null
d16/p1.py
Jamie-Chang/advent2019
130ccdc2a320d0a8d926a781a41fd74389e403a9
[ "Apache-2.0" ]
null
null
null
d16/p1.py
Jamie-Chang/advent2019
130ccdc2a320d0a8d926a781a41fd74389e403a9
[ "Apache-2.0" ]
null
null
null
from pathlib import Path from typing import Callable, Iterable, Iterator, List from itertools import chain, cycle, islice, repeat import numpy as np BASE_PATTERN = [0, 1, 0, -1] def read_lines() -> Iterator[str]: with (Path(__file__).parent / "input.txt").open("r") as f: for line in f: yiel...
26.344262
86
0.657747
0
0
259
0.16117
0
0
0
0
243
0.151213
bd98c615b517218be23b4c4fa061f1bb81f35762
925
py
Python
1_extract_story.py
varsh6/weekcode
4e5eb0ff0bd8af5b2fed24faeed50733c4a00551
[ "MIT" ]
2
2015-03-25T18:05:50.000Z
2016-05-05T09:49:45.000Z
1_extract_story.py
varsh6/weekcode
4e5eb0ff0bd8af5b2fed24faeed50733c4a00551
[ "MIT" ]
null
null
null
1_extract_story.py
varsh6/weekcode
4e5eb0ff0bd8af5b2fed24faeed50733c4a00551
[ "MIT" ]
null
null
null
from bs4 import BeautifulSoup import urllib2 start_url="https://www.fictionpress.com/s/2780124/1/Rise-From-The-Ashes-OLD" #start url end =False split_url=start_url.split("/") new_url="" for i in range(5): new_url=new_url+split_url[i]+"/" i=1 while not (end): url=new_url+"/"+str(i)+"/" i=i+1 response...
21.511628
87
0.566486
0
0
0
0
0
0
0
0
260
0.281081
bd9906411d0902be3e6498e5a1a56da473448736
2,161
py
Python
tests/tensorflow/pruning/test_flops_pruning.py
sarthakpati/nncf
29ad62c664c1dd53b3c8c50fc001a1b36bd1e8ac
[ "Apache-2.0" ]
1
2021-12-30T05:49:10.000Z
2021-12-30T05:49:10.000Z
tests/tensorflow/pruning/test_flops_pruning.py
sarthakpati/nncf
29ad62c664c1dd53b3c8c50fc001a1b36bd1e8ac
[ "Apache-2.0" ]
1
2021-07-23T07:46:52.000Z
2021-07-23T07:46:52.000Z
tests/tensorflow/pruning/test_flops_pruning.py
sarthakpati/nncf
29ad62c664c1dd53b3c8c50fc001a1b36bd1e8ac
[ "Apache-2.0" ]
null
null
null
""" Copyright (c) 2021 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 in writin...
44.102041
96
0.745951
0
0
0
0
1,342
0.621009
0
0
890
0.411846
bd99509849b2119597bc329227a6d9a8957453fc
61
py
Python
text/_geometry/boxing/_line/__init__.py
jedhsu/text
8525b602d304ac571a629104c48703443244545c
[ "Apache-2.0" ]
null
null
null
text/_geometry/boxing/_line/__init__.py
jedhsu/text
8525b602d304ac571a629104c48703443244545c
[ "Apache-2.0" ]
null
null
null
text/_geometry/boxing/_line/__init__.py
jedhsu/text
8525b602d304ac571a629104c48703443244545c
[ "Apache-2.0" ]
null
null
null
from .style import LineStyle __all__ = [ "LineStyle", ]
10.166667
28
0.655738
0
0
0
0
0
0
0
0
11
0.180328
bd99e09ac29cee3774d16f59b6db9c324075e704
9,812
py
Python
HCI/emotions.py
shinkansan/2019-UGRP-DPoom
eedee93b47e068f22bf420140d869a43f7551876
[ "Apache-2.0" ]
33
2020-07-16T06:31:38.000Z
2022-03-23T18:34:58.000Z
HCI/emotions.py
shinkansan/2019-UGRP-DPoom
eedee93b47e068f22bf420140d869a43f7551876
[ "Apache-2.0" ]
5
2020-08-27T08:06:21.000Z
2022-02-23T12:34:09.000Z
HCI/emotions.py
shinkansan/2019-UGRP-DPoom
eedee93b47e068f22bf420140d869a43f7551876
[ "Apache-2.0" ]
10
2020-08-05T15:05:58.000Z
2021-11-19T10:20:44.000Z
""" Dpoom Face Expression Windows 2019 """ from PyQt5.QtCore import * from PyQt5.QtWidgets import * from PyQt5.QtGui import * from PyQt5.QtWebEngineWidgets import * from PyQt5.QtPrintSupport import * import fall_body_1013 as fall_body import os import sys import numpy as np import argparse import imutils import time i...
30.190769
112
0.614248
8,806
0.897472
0
0
0
0
0
0
2,384
0.242968
bd9a1dd2de3b7a992cf45cfd0f9ad879ed786bb2
16,444
py
Python
src/sentry/plugins/base/manager.py
commonlims/commonlims
36a02ed244c7b59ee1f2523e64e4749e404ab0f7
[ "BSD-3-Clause" ]
4
2019-05-27T13:55:07.000Z
2021-03-30T07:05:09.000Z
src/sentry/plugins/base/manager.py
commonlims/commonlims
36a02ed244c7b59ee1f2523e64e4749e404ab0f7
[ "BSD-3-Clause" ]
99
2019-05-20T14:16:33.000Z
2021-01-19T09:25:15.000Z
src/sentry/plugins/base/manager.py
commonlims/commonlims
36a02ed244c7b59ee1f2523e64e4749e404ab0f7
[ "BSD-3-Clause" ]
1
2020-08-10T07:55:40.000Z
2020-08-10T07:55:40.000Z
""" sentry.plugins.base.manager ~~~~~~~~~~~~~~~~~~~~~~~~~~~ :copyright: (c) 2010-2013 by the Sentry Team, see AUTHORS for more details. :license: BSD, see LICENSE for more details. """ from __future__ import absolute_import, print_function __all__ = ('PluginManager', ) import sys import os import six import logging ...
39.245823
114
0.633666
15,796
0.960594
3,575
0.217405
0
0
0
0
5,820
0.353928
bd9a2a22106cfdf6f802047a7e11b687baf754c4
4,522
py
Python
datasets/pasval_voc_writer.py
jiabaocui/SEGS
c03d3bcb6fdcc4e6e6e13767bed8eae754beb726
[ "MIT" ]
null
null
null
datasets/pasval_voc_writer.py
jiabaocui/SEGS
c03d3bcb6fdcc4e6e6e13767bed8eae754beb726
[ "MIT" ]
null
null
null
datasets/pasval_voc_writer.py
jiabaocui/SEGS
c03d3bcb6fdcc4e6e6e13767bed8eae754beb726
[ "MIT" ]
null
null
null
import os import random import xml.etree.ElementTree as ET import tensorflow as tf def int64_feature(value): """Wrapper for inserting int64 features into Example proto. """ if not isinstance(value, list): value = [value] return tf.train.Feature(int64_list=tf.train.Int64List(value=value)) de...
34.784615
103
0.623176
2,857
0.6318
0
0
0
0
0
0
1,225
0.270898
bd9b25df86c49c5c34262d4d2399058530c129b1
296
py
Python
backend/commands/remove_expired_tokens.py
KSodowska/codeforpoznan.pl_v3
ddb079db90eda869940f4467832ef96f70591055
[ "MIT" ]
8
2019-08-12T22:10:48.000Z
2020-09-13T17:46:10.000Z
backend/commands/remove_expired_tokens.py
KSodowska/codeforpoznan.pl_v3
ddb079db90eda869940f4467832ef96f70591055
[ "MIT" ]
326
2018-11-07T20:29:28.000Z
2022-02-10T08:53:42.000Z
backend/commands/remove_expired_tokens.py
KSodowska/codeforpoznan.pl_v3
ddb079db90eda869940f4467832ef96f70591055
[ "MIT" ]
49
2018-11-14T17:50:27.000Z
2021-04-20T22:40:29.000Z
import click from flask.cli import with_appcontext from backend.models import JWTToken @click.command() @with_appcontext def remove_expired_tokens(): """Remove expired tokens from database.""" click.echo("Removing expired tokens") JWTToken.remove_expired() click.echo("Done!")
21.142857
46
0.75
0
0
0
0
205
0.692568
0
0
74
0.25
bd9b69dd642e70dfb29c6adbdfeea6b8fd4c082f
200
py
Python
tests/cases/examples/skip_track/gen_playlist.py
aarongaut/nextsong
05639d3aba2ef31721fd2533ca804a0d32e64ebf
[ "MIT" ]
null
null
null
tests/cases/examples/skip_track/gen_playlist.py
aarongaut/nextsong
05639d3aba2ef31721fd2533ca804a0d32e64ebf
[ "MIT" ]
null
null
null
tests/cases/examples/skip_track/gen_playlist.py
aarongaut/nextsong
05639d3aba2ef31721fd2533ca804a0d32e64ebf
[ "MIT" ]
null
null
null
from nextsong import Playlist as p p( "01.mp3", p( p("02.mp3", weight=1 / 4), p(weight=3 / 4), count=1, ), "03.mp3", "04.mp3", loop=True, ).save_xml()
14.285714
34
0.455
0
0
0
0
0
0
0
0
32
0.16
bd9ca71b402899675dbdc36257c37a8b3b2984d6
861
py
Python
pelican/plugins/issues/__init__.py
GlowstoneMC/glowstonemc.github.io
1d1a453251816ef90fb8aaa63a689c81aaad4848
[ "Artistic-2.0" ]
6
2016-07-30T00:44:10.000Z
2021-07-09T02:24:36.000Z
pelican/plugins/issues/__init__.py
GlowstoneMC/glowstonemc.github.io
1d1a453251816ef90fb8aaa63a689c81aaad4848
[ "Artistic-2.0" ]
16
2016-07-30T01:01:30.000Z
2021-07-09T21:33:51.000Z
pelican/plugins/issues/__init__.py
GlowstoneMC/glowstonemc.github.io
1d1a453251816ef90fb8aaa63a689c81aaad4848
[ "Artistic-2.0" ]
10
2015-01-21T19:57:43.000Z
2017-09-01T22:15:21.000Z
import itertools import re from pelican import signals ISSUE_REGEX = re.compile(r"([\s(])(#[\d]+)([\s),.])") ISSUE_URL = "https://github.com/GlowstoneMC/Glowstone/issues/{}" ISSUE_HTML = """{}<a href="{}">{}</a>{}""" def process_content(article): done_tags = set() for start, tag, end in ISSUE_REGEX.findal...
24.6
70
0.637631
0
0
0
0
0
0
0
0
116
0.134727
bd9d44c68b6bd8ea2a3e03df9da24659e42178bb
17,295
py
Python
athena/layers/commons.py
iou2much/athena
156dfceb0267e8c105e5d040aac017e2d8b9ad9d
[ "Apache-2.0" ]
null
null
null
athena/layers/commons.py
iou2much/athena
156dfceb0267e8c105e5d040aac017e2d8b9ad9d
[ "Apache-2.0" ]
null
null
null
athena/layers/commons.py
iou2much/athena
156dfceb0267e8c105e5d040aac017e2d8b9ad9d
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 # Copyright (C) 2019 ATHENA AUTHORS; Xiangang Li # # 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 appli...
34.179842
123
0.6244
15,753
0.910841
0
0
0
0
0
0
3,042
0.175889
bd9d5067373dbf69f5799fe7d45b1985b89fc18a
381
py
Python
tickets/migrations/0012_auto_20180830_1028.py
SpenserPorter/automate_reporting
59a0a9ff8776a7e14cd66575fc8ad7da7ec66087
[ "MIT" ]
1
2019-02-06T12:40:02.000Z
2019-02-06T12:40:02.000Z
tickets/migrations/0012_auto_20180830_1028.py
SpenserPorter/automate_reporting
59a0a9ff8776a7e14cd66575fc8ad7da7ec66087
[ "MIT" ]
null
null
null
tickets/migrations/0012_auto_20180830_1028.py
SpenserPorter/automate_reporting
59a0a9ff8776a7e14cd66575fc8ad7da7ec66087
[ "MIT" ]
null
null
null
# Generated by Django 2.1 on 2018-08-30 15:28 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('tickets', '0011_auto_20180830_0828'), ] operations = [ migrations.AlterField( model_name='ticket', name='dttm_updated'...
20.052632
47
0.598425
290
0.761155
0
0
0
0
0
0
101
0.265092
bd9d807e7a31d0445e4cb5f019e63d43a7bf4018
12,879
py
Python
oscar/data/mars.py
IntelLabs/OSCAR
25d1dea35727379117e11b7238b5a0d1ed19acad
[ "BSD-3-Clause" ]
13
2021-02-12T18:41:53.000Z
2022-01-14T07:17:15.000Z
oscar/data/mars.py
IntelLabs/OSCAR
25d1dea35727379117e11b7238b5a0d1ed19acad
[ "BSD-3-Clause" ]
null
null
null
oscar/data/mars.py
IntelLabs/OSCAR
25d1dea35727379117e11b7238b5a0d1ed19acad
[ "BSD-3-Clause" ]
2
2021-03-05T18:27:23.000Z
2021-03-05T23:16:09.000Z
# # Copyright (C) 2020 Intel Corporation # # SPDX-License-Identifier: BSD-3-Clause # import logging from collections import Counter import torch from torch.utils.data import DataLoader from torchvision.transforms import transforms as T from torchvision.transforms import functional as TF import pytorch_lightning as p...
45.508834
202
0.601444
12,212
0.94821
0
0
1,717
0.133318
0
0
2,080
0.161503
bd9dc0e3438ed94163bddc922821b2e616468b1a
2,704
py
Python
bin/changes.py
kcrca/clarity
84acb9b17bd8b84222bf25e3bb32fc578832e37f
[ "CC-BY-4.0" ]
1
2016-08-25T02:17:47.000Z
2016-08-25T02:17:47.000Z
bin/changes.py
kcrca/clarity
84acb9b17bd8b84222bf25e3bb32fc578832e37f
[ "CC-BY-4.0" ]
null
null
null
bin/changes.py
kcrca/clarity
84acb9b17bd8b84222bf25e3bb32fc578832e37f
[ "CC-BY-4.0" ]
2
2016-08-01T05:02:30.000Z
2022-01-14T12:58:14.000Z
#!/usr/bin/env python3 # Generate the animations and images needed to provide the "changes" texture pack. __author__ = 'arnold' import os import random import json import collections from PIL import Image import clip weeks_in_year = 52 timings = collections.OrderedDict() timings['autumn'] = 2 timings['winter'] = ...
29.075269
118
0.651257
0
0
0
0
0
0
0
0
599
0.221524
bd9ea740497b5430ed79706f049d86c226916d0f
8,929
py
Python
exp2.py
jdrugo/LCSBookCode
ce9b8f35919e7dd959d007e6543d1479bbe2a26a
[ "MIT" ]
1
2020-11-25T14:57:49.000Z
2020-11-25T14:57:49.000Z
exp2.py
jdrugo/LCSBookCode
ce9b8f35919e7dd959d007e6543d1479bbe2a26a
[ "MIT" ]
null
null
null
exp2.py
jdrugo/LCSBookCode
ce9b8f35919e7dd959d007e6543d1479bbe2a26a
[ "MIT" ]
null
null
null
"""Trains a Bayesian LCS with a GA on the Waterhouse (1996) test function. """ import sys from numpy import double, array, ones, empty, arange, empty, hstack, \ sqrt, exp, sort, sum, inf, power, dot, linspace, sin, pi from numpy.random import random, randn, binomial, uniform, normal import Gnuplot from ga import...
33.317164
80
0.579348
0
0
0
0
0
0
0
0
2,351
0.263299
bd9f9949e13417fd14f6292afebf26ca964e5be3
9,439
py
Python
test/test_live_tv_service_api.py
stanionascu/python-embyapi
a3f7aa49aea4052277cc43605c0d89bc6ff21913
[ "BSD-3-Clause" ]
null
null
null
test/test_live_tv_service_api.py
stanionascu/python-embyapi
a3f7aa49aea4052277cc43605c0d89bc6ff21913
[ "BSD-3-Clause" ]
null
null
null
test/test_live_tv_service_api.py
stanionascu/python-embyapi
a3f7aa49aea4052277cc43605c0d89bc6ff21913
[ "BSD-3-Clause" ]
null
null
null
# coding: utf-8 """ Emby Server API Explore the Emby Server API # noqa: E501 OpenAPI spec version: 4.1.1.0 Generated by: https://github.com/swagger-api/swagger-codegen.git """ from __future__ import absolute_import import unittest import embyapi from embyapi.api.live_tv_service_api import Li...
23.896203
78
0.637144
9,000
0.953491
0
0
0
0
0
0
5,168
0.547516
bda0ee2b60b3089f82bfd69b9afe911afcc77e80
4,454
py
Python
dolfyn/tests/test_vs_nortek.py
jklymak/dolfyn
eea98fe0021886cf654e25293c385c5c3707ff8d
[ "BSD-3-Clause" ]
null
null
null
dolfyn/tests/test_vs_nortek.py
jklymak/dolfyn
eea98fe0021886cf654e25293c385c5c3707ff8d
[ "BSD-3-Clause" ]
null
null
null
dolfyn/tests/test_vs_nortek.py
jklymak/dolfyn
eea98fe0021886cf654e25293c385c5c3707ff8d
[ "BSD-3-Clause" ]
null
null
null
from dolfyn.tests import test_read_adp as tr from dolfyn.tests import base from dolfyn.rotate.api import rotate2 from numpy.testing import assert_allclose import numpy as np import scipy.io as sio """ Testing against velocity and bottom-track velocity data in Nortek mat files exported from SignatureDeployment. inst2...
35.632
79
0.606646
0
0
0
0
0
0
0
0
1,237
0.277728
bda2bb0b49a3956bff9896df11bb2cfb1702c6a1
1,022
py
Python
vscode/extensions/magicstack.magicpython-1.0.12/test/regexp/python2.py
nlimpid/dotfiles
b78d08707992f742f984f556fa58349c2ccd095d
[ "MIT" ]
5
2017-02-22T10:17:39.000Z
2021-04-06T16:36:13.000Z
test/regexp/python2.py
Setonas/MagicSetonas
ef76da5f27a0506b194c58072b81424e3ce985d7
[ "MIT" ]
4
2019-06-16T09:52:03.000Z
2019-08-18T02:11:35.000Z
vscode/extensions/magicstack.magicpython-1.0.12/test/regexp/python2.py
nlimpid/dotfiles
b78d08707992f742f984f556fa58349c2ccd095d
[ "MIT" ]
1
2020-08-29T02:30:52.000Z
2020-08-29T02:30:52.000Z
a = r' (?x) foo ' a : source.python : source.python = : keyword.operator.assignment.python, source.python : source.python r : source.python, storage.type.string.python, string.regexp.quoted.single.python ' : punctuation.definitio...
42.583333
112
0.622309
0
0
0
0
0
0
0
0
0
0
bda33f238048fa796ed848c9125688fdcab82f49
1,331
py
Python
backend/flaskr/formula.py
jyyang42/RobinOptionCalculator
be3f06f6ae54c7e2dd4badc258a9888e3e240a4a
[ "MIT" ]
1
2020-11-19T19:47:48.000Z
2020-11-19T19:47:48.000Z
backend/flaskr/formula.py
jyyang42/RobinOptionCalculater
be3f06f6ae54c7e2dd4badc258a9888e3e240a4a
[ "MIT" ]
7
2020-06-23T07:07:10.000Z
2020-08-24T23:43:53.000Z
backend/flaskr/formula.py
jyyang42/RobinOptionCalculater
be3f06f6ae54c7e2dd4badc258a9888e3e240a4a
[ "MIT" ]
2
2020-08-25T02:45:10.000Z
2020-11-19T19:47:38.000Z
import math def get_d1(p0, X, t, sigma, Rho): # P0 stock price 62 # X exercise Price 60 # t time to expiration days/365 40 # sigma Volatility 0.32 # Rho Risk-Free Rate 0.04 # d1 = {ln(62/60) + [0.04 + 0.5 * 0.32 ^ 2] * (40/365)} / 0.32 * sqrt(40/365) a = math.log(p0/X) + (Rho + 0.5 * ...
25.596154
81
0.552968
0
0
0
0
0
0
0
0
292
0.219219
bda34ec056c93e4918c1bc75e8154a348bc2e5e2
932
py
Python
bot/modules/magnet.py
AliAryanTech/Nyaa-Telegram-Bot
d1614ed218fd9f413d046eec61978df269b325b6
[ "MIT" ]
12
2020-12-01T04:40:37.000Z
2022-01-22T14:19:04.000Z
bot/modules/magnet.py
AliAryanTech/Nyaa-Telegram-Bot
d1614ed218fd9f413d046eec61978df269b325b6
[ "MIT" ]
null
null
null
bot/modules/magnet.py
AliAryanTech/Nyaa-Telegram-Bot
d1614ed218fd9f413d046eec61978df269b325b6
[ "MIT" ]
19
2021-02-09T19:20:59.000Z
2022-03-18T12:05:08.000Z
from .get_response import nyaa_id, sukebei_id from bot import NYAA, botname from pyrogram import Client, filters from pyrogram.types import InlineKeyboardButton, InlineKeyboardMarkup, CallbackQuery INVALID_TEXT = """ No ID found! """ @NYAA.on_message(filters.command(["magnet", f"magnet@{botname}"], prefixes ...
40.521739
137
0.637339
0
0
0
0
687
0.737124
585
0.627682
136
0.145923
bda3f5b55352390d17d7c5c49807550e4e3deac1
297
py
Python
factory-ai-vision/EdgeSolution/modules/WebModule/backend/vision_on_edge/images/api/serializers.py
kaka-lin/azure-intelligent-edge-patterns
766833c7c25d2458cec697937be288202d1763bc
[ "MIT" ]
176
2019-07-03T00:20:15.000Z
2022-03-14T07:51:22.000Z
factory-ai-vision/EdgeSolution/modules/WebModule/backend/vision_on_edge/images/api/serializers.py
kaka-lin/azure-intelligent-edge-patterns
766833c7c25d2458cec697937be288202d1763bc
[ "MIT" ]
121
2019-06-24T20:47:27.000Z
2022-03-28T02:16:18.000Z
factory-ai-vision/EdgeSolution/modules/WebModule/backend/vision_on_edge/images/api/serializers.py
kaka-lin/azure-intelligent-edge-patterns
766833c7c25d2458cec697937be288202d1763bc
[ "MIT" ]
144
2019-06-18T18:48:43.000Z
2022-03-31T12:14:46.000Z
"""App API serializers. """ import logging from rest_framework import serializers from ..models import Image logger = logging.getLogger(__name__) class ImageSerializer(serializers.ModelSerializer): """ImageSerializer.""" class Meta: model = Image fields = "__all__"
15.631579
51
0.703704
144
0.484848
0
0
0
0
0
0
58
0.195286
bda4133fe40f05627ed065666e33a64ba888ab8f
18,060
py
Python
fhir/resources/DSTU2/implementationguide.py
cstoltze/fhir.resources
52f99738935b7313089d89daf94d73ce7d167c9d
[ "BSD-3-Clause" ]
144
2019-05-08T14:24:43.000Z
2022-03-30T02:37:11.000Z
fhir/resources/DSTU2/implementationguide.py
cstoltze/fhir.resources
52f99738935b7313089d89daf94d73ce7d167c9d
[ "BSD-3-Clause" ]
82
2019-05-13T17:43:13.000Z
2022-03-30T16:45:17.000Z
fhir/resources/DSTU2/implementationguide.py
cstoltze/fhir.resources
52f99738935b7313089d89daf94d73ce7d167c9d
[ "BSD-3-Clause" ]
48
2019-04-04T14:14:53.000Z
2022-03-30T06:07:31.000Z
# -*- coding: utf-8 -*- """ Profile: https://www.hl7.org/fhir/DSTU2/implementationguide.html Release: DSTU2 Version: 1.0.2 Revision: 7202 """ from typing import Any, Dict from typing import List as ListType from pydantic import Field, root_validator from . import backboneelement, domainresource, fhirtypes class Imp...
34.334601
92
0.612901
17,730
0.981728
0
0
1,828
0.101218
0
0
9,704
0.53732
bda5541d8519516c1c651c498c62fb368ec8e19e
2,796
py
Python
Decorator Foundation.py
Enthuisasticpessimist/Small-exercise
b169000023c3863f9e30d2cfc7c0f6e228f612f7
[ "MIT" ]
null
null
null
Decorator Foundation.py
Enthuisasticpessimist/Small-exercise
b169000023c3863f9e30d2cfc7c0f6e228f612f7
[ "MIT" ]
null
null
null
Decorator Foundation.py
Enthuisasticpessimist/Small-exercise
b169000023c3863f9e30d2cfc7c0f6e228f612f7
[ "MIT" ]
null
null
null
##-----------Non parametric decorator---------------- ####initialization ##name = 'a' ##password = '1' ##user_status = False ## ####decorator ##def login(func): ## def inner(): ## global name,password,user_status ## if user_status == True: ## pass ## else: ## n = input('nam...
26.377358
79
0.508941
0
0
0
0
117
0.041845
0
0
2,035
0.727825
bda5691ceabca9d9b32498222c4155793f52475a
2,325
py
Python
src/mnkgame.py
isihya/minimax_algorithm_MNKgame
9876c12d065422334d87bf24c6d82171c7ace89e
[ "MIT" ]
null
null
null
src/mnkgame.py
isihya/minimax_algorithm_MNKgame
9876c12d065422334d87bf24c6d82171c7ace89e
[ "MIT" ]
null
null
null
src/mnkgame.py
isihya/minimax_algorithm_MNKgame
9876c12d065422334d87bf24c6d82171c7ace89e
[ "MIT" ]
null
null
null
import numpy as np from game import Game class MNKgame(Game): """ https://en.wikipedia.org/wiki/M,n,k-game If m=3, n=3, k=3. This is TicTakToe and default """ def __init__(self, n=3, m=3, k=3, field=None): self.n = n self.m = m self.k = k self.field = field ...
28.012048
59
0.44129
2,281
0.981075
0
0
0
0
0
0
143
0.061505
bda5f88b1ed70dd6d4320c4922009e7031b24847
2,721
py
Python
memoit/main/forms.py
Szymon-I/Memo-IT-App
f435331c4fbd68d34a5fb1d1f6b54117bab6b864
[ "MIT" ]
null
null
null
memoit/main/forms.py
Szymon-I/Memo-IT-App
f435331c4fbd68d34a5fb1d1f6b54117bab6b864
[ "MIT" ]
14
2019-08-06T02:06:17.000Z
2022-03-11T23:49:01.000Z
memoit/main/forms.py
Szymon-I/Memo-IT-App
f435331c4fbd68d34a5fb1d1f6b54117bab6b864
[ "MIT" ]
null
null
null
from django import forms from django.contrib.auth.forms import UserCreationForm from django.contrib.auth.models import User from .choices import * from django.contrib.auth.forms import AuthenticationForm from django.core.exceptions import ObjectDoesNotExist from django.forms import ValidationError # override basic au...
37.791667
117
0.669974
2,105
0.773613
0
0
0
0
0
0
595
0.21867
bda7487b706cb9a94241cf9262532248e9f7dfec
4,617
py
Python
tests/export_traces_test.py
galizia-lab/pyview
07bef637b0c60fae8830c1b3947e4a7bcd14bb2c
[ "BSD-3-Clause" ]
2
2021-11-07T10:17:16.000Z
2021-11-07T10:17:19.000Z
tests/export_traces_test.py
galizia-lab/pyview
07bef637b0c60fae8830c1b3947e4a7bcd14bb2c
[ "BSD-3-Clause" ]
5
2021-11-03T12:43:03.000Z
2021-12-16T10:34:52.000Z
tests/export_traces_test.py
galizia-lab/pyview
07bef637b0c60fae8830c1b3947e4a7bcd14bb2c
[ "BSD-3-Clause" ]
1
2021-09-23T15:46:26.000Z
2021-09-23T15:46:26.000Z
from common import initialize_test_yml_list_measurement from view import VIEW import pathlib as pl import shutil from view.python_core.ctvs import get_all_available_ctvs from view.python_core.gdm_generation.gdm_data_classes import GDMFile class TraceExporter(object): def __init__(self): super().__init__...
27.981818
98
0.65627
1,776
0.384665
0
0
0
0
0
0
1,271
0.275287
bda7fb3776a5d1e908f28700d29753c520db4037
2,551
py
Python
app/entries/forms.py
singh-prashant/blog
7c4d2e2d6890d3f0b48741b1090e41a990cad1de
[ "MIT" ]
null
null
null
app/entries/forms.py
singh-prashant/blog
7c4d2e2d6890d3f0b48741b1090e41a990cad1de
[ "MIT" ]
null
null
null
app/entries/forms.py
singh-prashant/blog
7c4d2e2d6890d3f0b48741b1090e41a990cad1de
[ "MIT" ]
null
null
null
from wtforms import Form, StringField, TextAreaField,SelectField, FileField,HiddenField from wtforms.validators import DataRequired, Optional, Email, URL, Length from models import Entry, Tag class TagField(StringField): def _value(self): if self.data: #Display tags as a comma-separated list. ...
31.109756
89
0.633477
2,349
0.920815
0
0
0
0
0
0
404
0.158369
bda9a1746f79218c2ab9314175f0e74a63028e6b
11,323
py
Python
cloudsmith_cli/cli/commands/tags.py
ThomasAdam/cloudsmith-cli
c335645bf947381a8f5c287bcc0ca6de7a809bdd
[ "Apache-2.0" ]
19
2018-02-14T23:48:27.000Z
2022-03-12T20:58:09.000Z
cloudsmith_cli/cli/commands/tags.py
ThomasAdam/cloudsmith-cli
c335645bf947381a8f5c287bcc0ca6de7a809bdd
[ "Apache-2.0" ]
68
2017-12-03T04:16:55.000Z
2022-03-03T09:45:48.000Z
cloudsmith_cli/cli/commands/tags.py
ThomasAdam/cloudsmith-cli
c335645bf947381a8f5c287bcc0ca6de7a809bdd
[ "Apache-2.0" ]
10
2017-12-25T14:36:24.000Z
2021-12-10T11:10:59.000Z
# -*- coding: utf-8 -*- """CLI/Commands - List objects.""" from __future__ import absolute_import, print_function, unicode_literals from operator import itemgetter import click from ...core.api.packages import ( get_package_tags as api_get_package_tags, tag_package as api_tag_package, ) from .. import comman...
31.192837
87
0.666078
0
0
0
0
9,669
0.853926
0
0
4,532
0.400247
bdaa3c35e12cb6be60fdc05cc2cfe86bb78ba70c
764
py
Python
tests/test_correct_pesel.py
matee911/pypesel
393e4bf4891b4bbb94cd077b26161dd2e94eed31
[ "Apache-2.0" ]
null
null
null
tests/test_correct_pesel.py
matee911/pypesel
393e4bf4891b4bbb94cd077b26161dd2e94eed31
[ "Apache-2.0" ]
null
null
null
tests/test_correct_pesel.py
matee911/pypesel
393e4bf4891b4bbb94cd077b26161dd2e94eed31
[ "Apache-2.0" ]
null
null
null
from pesel import Pesel import pytest @pytest.fixture(scope='session', params=["65432101239"]) def pesel_value(request): return request.param @pytest.fixture(scope='session') def pesel_obj(pesel_value): return Pesel(pesel_value) def test_correct_pesel(pesel_obj, pesel_value): pytest.assume(pesel_obj.v...
20.648649
56
0.764398
0
0
0
0
197
0.257853
0
0
37
0.048429
bdab079e812edf7ae50cfd1cbee57eb0f820a648
5,978
py
Python
oidc/endpoints/authorize.py
didx-xyz/yoma-oidc-bridge
7e3ff6ab3ea4fed01cd7d4c113c7c3b3244356eb
[ "Apache-2.0" ]
null
null
null
oidc/endpoints/authorize.py
didx-xyz/yoma-oidc-bridge
7e3ff6ab3ea4fed01cd7d4c113c7c3b3244356eb
[ "Apache-2.0" ]
null
null
null
oidc/endpoints/authorize.py
didx-xyz/yoma-oidc-bridge
7e3ff6ab3ea4fed01cd7d4c113c7c3b3244356eb
[ "Apache-2.0" ]
null
null
null
from aca.client import ACAClient from aries_cloudcontroller.aries_controller import AriesAgentController from asgiref.sync import sync_to_async, async_to_sync from django.utils import timezone from datetime import timedelta from aca.models import PresentationFactory from oidc.utils.shortener import create_short_url fr...
42.7
146
0.761124
0
0
0
0
788
0.131817
3,098
0.518234
1,251
0.209267
bdad84b4bff0650ac95c00b90cecccaf57a977f3
425
py
Python
BOJ17207.py
INYEONGKIM/BOJ
5e83d77a92d18b0d20d26645c7cfe4ba3e2d25bc
[ "MIT" ]
2
2019-03-05T15:42:46.000Z
2019-07-24T15:52:36.000Z
BOJ17207.py
INYEONGKIM/BOJ
5e83d77a92d18b0d20d26645c7cfe4ba3e2d25bc
[ "MIT" ]
null
null
null
BOJ17207.py
INYEONGKIM/BOJ
5e83d77a92d18b0d20d26645c7cfe4ba3e2d25bc
[ "MIT" ]
null
null
null
a=[];b=[];t=[];task=[0]*5;n=['Youngki','Jinwoo','Jungwoo','Junsuk','Inseo'] for _ in range(5): a.append([int(i) for i in input().split()]) t.append([0]*5) for _ in range(5): b.append([int(i) for i in input().split()]) for i in range(5): for j in range(5): for k in range(5): t[i][j]+=...
28.333333
75
0.531765
0
0
0
0
0
0
0
0
41
0.096471
bdae540df0f84f457e5404b4e6682360e4f75f83
5,163
py
Python
psana/psana/graphqt/IVSpectrum.py
ZLLentz/lcls2
3edbea556779f619944ee9b97fb33cd815a19a37
[ "BSD-3-Clause-LBNL" ]
null
null
null
psana/psana/graphqt/IVSpectrum.py
ZLLentz/lcls2
3edbea556779f619944ee9b97fb33cd815a19a37
[ "BSD-3-Clause-LBNL" ]
null
null
null
psana/psana/graphqt/IVSpectrum.py
ZLLentz/lcls2
3edbea556779f619944ee9b97fb33cd815a19a37
[ "BSD-3-Clause-LBNL" ]
null
null
null
"""Class :py:class:`IVSpectrum` is a QWidget with histogram, two axes, and color bar ==================================================================================== Usage :: # Run test: python lcls2/psana/psana/graphqt/IVSpectrum.py from psana.graphqt.IVSpectrum import IVSpectrum w = IVSpectrum() ...
32.88535
114
0.650978
3,832
0.742204
0
0
0
0
0
0
938
0.181677
bdb6b56e79718d96881ce563456b6ed24e5bfc35
2,912
py
Python
saige/load_results.py
Nealelab/ukb_common
ee063971d48e15ea4c525d26cf6745930d7106dc
[ "MIT" ]
8
2020-03-06T12:32:44.000Z
2021-11-17T18:00:13.000Z
saige/load_results.py
Nealelab/ukb_common
ee063971d48e15ea4c525d26cf6745930d7106dc
[ "MIT" ]
1
2021-11-02T20:09:05.000Z
2021-11-03T13:10:05.000Z
saige/load_results.py
Nealelab/ukb_common
ee063971d48e15ea4c525d26cf6745930d7106dc
[ "MIT" ]
3
2020-07-27T04:14:52.000Z
2021-09-15T13:43:23.000Z
#!/usr/bin/env python3 __author__ = 'konradk' from ukb_common import * import argparse import tempfile PHENO_KEY_FIELDS = ('trait_type', 'phenocode', 'pheno_sex', 'coding', 'modifier') def main(args): hl.init(master=f'local[{args.n_threads}]', log=hl.utils.timestamp_path(os.path.join(tempfile.gette...
56
164
0.736607
0
0
0
0
0
0
0
0
891
0.305975
bdb72defd6c6f62fdddbb438cb6348c91bc60611
4,981
py
Python
app/db/crud/recipeBewertung.py
baldur132/essensfindung
e1a8106d8a1de857340229a5fe36ca6910c55b35
[ "MIT" ]
1
2022-01-29T20:33:30.000Z
2022-01-29T20:33:30.000Z
app/db/crud/recipeBewertung.py
baldur132/essensfindung
e1a8106d8a1de857340229a5fe36ca6910c55b35
[ "MIT" ]
2
2022-03-08T06:41:22.000Z
2022-03-09T11:52:06.000Z
app/db/crud/recipeBewertung.py
baldur132/essensfindung
e1a8106d8a1de857340229a5fe36ca6910c55b35
[ "MIT" ]
6
2022-01-06T15:02:59.000Z
2022-02-02T08:08:56.000Z
"""All DB functions for the Bewertung table""" from typing import List from typing import Union import sqlalchemy from sqlalchemy.orm import Session from db.base import BewertungRecipe from db.base import Person from db.crud.user import get_user_by_mail from schemes import scheme_recipe from schemes import scheme_use...
34.116438
119
0.700863
0
0
0
0
0
0
0
0
1,942
0.389882
bdb88a765d8bc6b5e477b1b64ee817472716d342
66,946
py
Python
tests/pyoozie/test_client.py
Shopify/pyoozie
6dcbcb8249820dc40b5a9bbbc04b0370240fd706
[ "MIT" ]
9
2017-03-16T15:30:23.000Z
2019-08-07T03:35:59.000Z
tests/pyoozie/test_client.py
Shopify/pyoozie
6dcbcb8249820dc40b5a9bbbc04b0370240fd706
[ "MIT" ]
43
2017-02-01T22:20:52.000Z
2020-08-10T08:48:20.000Z
tests/pyoozie/test_client.py
Shopify/pyoozie
6dcbcb8249820dc40b5a9bbbc04b0370240fd706
[ "MIT" ]
5
2017-02-08T17:59:06.000Z
2020-11-12T11:29:08.000Z
# Copyright (c) 2017 "Shopify inc." All rights reserved. # Use of this source code is governed by a MIT-style license that can be found in the LICENSE file. from __future__ import unicode_literals import copy import mock import pytest import requests_mock import requests from pyoozie import exceptions from pyoozie im...
47.045678
118
0.647776
63,062
0.941983
401
0.00599
8,395
0.1254
0
0
10,531
0.157306
bdb903aa24f6b049c642dc46fbe0678bd7b992ac
35,706
py
Python
modules/tbc_mage.py
ClawDoctor/TBC_GUI_sim
ebdb40ef348f5b00b10f6323f07260f47e8aab74
[ "MIT" ]
null
null
null
modules/tbc_mage.py
ClawDoctor/TBC_GUI_sim
ebdb40ef348f5b00b10f6323f07260f47e8aab74
[ "MIT" ]
null
null
null
modules/tbc_mage.py
ClawDoctor/TBC_GUI_sim
ebdb40ef348f5b00b10f6323f07260f47e8aab74
[ "MIT" ]
null
null
null
import fns import numpy as np import sys def eprint(*args, **kwargs): print(*args, file=sys.stderr, **kwargs) from .libs import tbc_mage_backend as bck import importlib importlib.reload(bck) def read_stat_file(location, file, stats): loc = '/'.join(location.split('/')[:-1])+'/'+file with open(loc) as f: #print('st...
42.406176
183
0.651711
18,509
0.518372
0
0
0
0
0
0
12,802
0.358539
bdb9e345a7126b6fc13fd0106c741d7ab14d3f93
36,682
py
Python
PyPixel/SkyBlockStats.py
M4axim/PyPixel
8f77773a6e4c1541a41c98fd8edb86b4bb2aba67
[ "MIT" ]
2
2021-03-25T16:52:22.000Z
2021-09-22T16:42:57.000Z
PyPixel/SkyBlockStats.py
M4axim/PyPixel
8f77773a6e4c1541a41c98fd8edb86b4bb2aba67
[ "MIT" ]
null
null
null
PyPixel/SkyBlockStats.py
M4axim/PyPixel
8f77773a6e4c1541a41c98fd8edb86b4bb2aba67
[ "MIT" ]
2
2021-03-23T18:40:19.000Z
2022-01-03T18:17:08.000Z
# -*- coding: utf-8 -*- """ MIT License Copyright (c) 2021 plun1331 Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, mod...
73.955645
120
0.733684
35,378
0.964451
0
0
0
0
0
0
14,301
0.389864
bdba7af199ee6c2c990e85c3f998b299c41d4413
604
py
Python
nicos_virt_mlz/reseda/setups/guidehall.py
jkrueger1/nicos
5f4ce66c312dedd78995f9d91e8a6e3c891b262b
[ "CC-BY-3.0", "Apache-2.0", "CC-BY-4.0" ]
12
2019-11-06T15:40:36.000Z
2022-01-01T16:23:00.000Z
nicos_virt_mlz/reseda/setups/guidehall.py
jkrueger1/nicos
5f4ce66c312dedd78995f9d91e8a6e3c891b262b
[ "CC-BY-3.0", "Apache-2.0", "CC-BY-4.0" ]
91
2020-08-18T09:20:26.000Z
2022-02-01T11:07:14.000Z
nicos_virt_mlz/reseda/setups/guidehall.py
jkrueger1/nicos
5f4ce66c312dedd78995f9d91e8a6e3c891b262b
[ "CC-BY-3.0", "Apache-2.0", "CC-BY-4.0" ]
6
2020-01-11T10:52:30.000Z
2022-02-25T12:35:23.000Z
description = 'FRM II Neutron guide hall west infrastructure devices' group = 'lowlevel' devices = dict( Sixfold = device('nicos.devices.generic.ManualSwitch', description = 'Sixfold shutter status', states = ('closed', 'open'), pollinterval = 60, maxage = 120, ), Crane = d...
27.454545
69
0.584437
0
0
0
0
0
0
0
0
261
0.432119
bdbb22ba6b4c3c39c0c15a90a8c254569dd0c0be
74
py
Python
tinycord/models/message/gateway/__init__.py
tinycord/tinycord
9e817452c1f2357878f07f8622f6240687470cad
[ "MIT" ]
8
2022-01-08T20:04:29.000Z
2022-03-21T19:12:19.000Z
tinycord/models/message/gateway/__init__.py
tinycord/tinycord
9e817452c1f2357878f07f8622f6240687470cad
[ "MIT" ]
null
null
null
tinycord/models/message/gateway/__init__.py
tinycord/tinycord
9e817452c1f2357878f07f8622f6240687470cad
[ "MIT" ]
1
2022-01-02T21:42:53.000Z
2022-01-02T21:42:53.000Z
from .reaction import ReactionGateway __all__ = [ "ReactionGateway" ]
14.8
37
0.743243
0
0
0
0
0
0
0
0
17
0.22973
bdbb658871214d92211c98f23c493a5bef0ef8d6
2,366
py
Python
papermerge/core/management/commands/checkaccess.py
MinchinWeb/papermerge
8a5f73207413a3ea8989d277e140d448baa35ca4
[ "Apache-2.0" ]
null
null
null
papermerge/core/management/commands/checkaccess.py
MinchinWeb/papermerge
8a5f73207413a3ea8989d277e140d448baa35ca4
[ "Apache-2.0" ]
null
null
null
papermerge/core/management/commands/checkaccess.py
MinchinWeb/papermerge
8a5f73207413a3ea8989d277e140d448baa35ca4
[ "Apache-2.0" ]
null
null
null
import logging from django.core.management.base import BaseCommand try: from django_tenants.utils import get_tenant_model except: get_tenant_model = None from django.db import connection from papermerge.core.models import ( BaseTreeNode, Access ) from papermerge.core.auth import ( create_access_p...
24.645833
73
0.554522
1,998
0.844463
0
0
0
0
0
0
364
0.153846
bdbde2d938f424e96e16facd89ad398cdbed2930
46,214
py
Python
pysnmp-with-texts/CISCO-LISP-EXT-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
8
2019-05-09T17:04:00.000Z
2021-06-09T06:50:51.000Z
pysnmp-with-texts/CISCO-LISP-EXT-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
4
2019-05-31T16:42:59.000Z
2020-01-31T21:57:17.000Z
pysnmp-with-texts/CISCO-LISP-EXT-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
10
2019-04-30T05:51:36.000Z
2022-02-16T03:33:41.000Z
# # PySNMP MIB module CISCO-LISP-EXT-MIB (http://snmplabs.com/pysmi) # ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/CISCO-LISP-EXT-MIB # Produced by pysmi-0.3.4 at Wed May 1 12:04:38 2019 # On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4 # Using Python version 3.7.3 (default, ...
175.05303
5,644
0.825378
0
0
0
0
0
0
0
0
17,713
0.383282
bdbe3e3e964d3de239112acfd757c2553c93386b
678
py
Python
11.dumbo-octopus/py/part1.py
rolandbernard/adventofcode-2021
9249815af62d0fcf79b71357330a1456ea3be1ed
[ "BSD-2-Clause" ]
null
null
null
11.dumbo-octopus/py/part1.py
rolandbernard/adventofcode-2021
9249815af62d0fcf79b71357330a1456ea3be1ed
[ "BSD-2-Clause" ]
null
null
null
11.dumbo-octopus/py/part1.py
rolandbernard/adventofcode-2021
9249815af62d0fcf79b71357330a1456ea3be1ed
[ "BSD-2-Clause" ]
null
null
null
import sys import numpy as np raw = sys.stdin.read() map = np.array([[c for c in l] for l in raw.split('\n') if len(l) != 0], dtype=int) def energize(map, i, j): if i >= 0 and j >= 0 and i < map.shape[0] and j < map.shape[1] and map[i, j] < 10: map[i, j] += 1 if map[i, j] >= 10: for d...
26.076923
105
0.513274
0
0
0
0
0
0
0
0
13
0.019174
bdbe6b219cb1418af34e685a56c258fed902050b
10,853
py
Python
rlb/utils.py
jaekyeom/drop-bottleneck
85b64ce72ac22af56e167da2817c295b79a03eb7
[ "Apache-2.0", "MIT" ]
8
2021-03-16T05:37:41.000Z
2021-06-18T05:15:15.000Z
rlb/utils.py
jaekyeom/drop-bottleneck
85b64ce72ac22af56e167da2817c295b79a03eb7
[ "Apache-2.0", "MIT" ]
null
null
null
rlb/utils.py
jaekyeom/drop-bottleneck
85b64ce72ac22af56e167da2817c295b79a03eb7
[ "Apache-2.0", "MIT" ]
2
2021-06-23T08:15:16.000Z
2021-08-30T14:13:58.000Z
from __future__ import print_function from collections import OrderedDict, defaultdict import numpy as np import random import copy #from mpi_util import mpi_moments #def fc(x, scope, nh, *, init_scale=1.0, init_bias=0.0): # with tf.variable_scope(scope): # nin = x.get_shape()[1].value # w = tf.get_...
36.789831
155
0.609417
3,059
0.281858
0
0
0
0
0
0
4,691
0.432231
bdbe72b5112056466b1083e545acb1c1e6dff2bb
901
py
Python
client/model.py
firmanmm/tic-tac-royale
83c3bb88cd31a34eeceeac3d42aaa302598f52e9
[ "MIT" ]
null
null
null
client/model.py
firmanmm/tic-tac-royale
83c3bb88cd31a34eeceeac3d42aaa302598f52e9
[ "MIT" ]
null
null
null
client/model.py
firmanmm/tic-tac-royale
83c3bb88cd31a34eeceeac3d42aaa302598f52e9
[ "MIT" ]
null
null
null
class Location: def __init__(self, x : int, y : int): self.x = x self.y = y def getX(self) -> int: return self.x def getY(self) -> int: return self.y def __eq__(self, value): return self.x == value.x and self.y == value.y def __hash__(self): retu...
22.525
68
0.54717
897
0.99556
0
0
0
0
0
0
16
0.017758
bdbebeb76abb18683215eb78cded4e0d06667190
191
py
Python
adapters/lumi/WXCJKG13LM.py
russdan/domoticz-zigbee2mqtt-plugin
d47895eab44bc87fc19ce151698d2afe9554fadc
[ "MIT" ]
146
2018-09-19T11:38:48.000Z
2022-03-21T11:54:12.000Z
adapters/lumi/WXCJKG13LM.py
russdan/domoticz-zigbee2mqtt-plugin
d47895eab44bc87fc19ce151698d2afe9554fadc
[ "MIT" ]
783
2018-09-28T17:07:14.000Z
2022-03-31T10:18:27.000Z
adapters/lumi/WXCJKG13LM.py
russdan/domoticz-zigbee2mqtt-plugin
d47895eab44bc87fc19ce151698d2afe9554fadc
[ "MIT" ]
147
2018-09-25T18:39:51.000Z
2022-03-01T19:31:27.000Z
from adapters.lumi.aqara_opple_switch import AqaraOppleSwitch class WXCJKG13LM(AqaraOppleSwitch): def __init__(self): buttons_count = 6 super().__init__(buttons_count)
21.222222
61
0.743455
125
0.65445
0
0
0
0
0
0
0
0
bdc046b158b884fea2bcbaf2bb1204d34d3b4b00
4,565
py
Python
pydtnsim/routing/cgr_utils.py
ducktec/pydtnsim
916b0ebfa2b65b7a80af293dd4c39f862eadeae3
[ "MIT" ]
8
2018-12-11T17:39:44.000Z
2021-05-07T10:24:03.000Z
pydtnsim/routing/cgr_utils.py
Elianelin/pydtnsim
916b0ebfa2b65b7a80af293dd4c39f862eadeae3
[ "MIT" ]
13
2019-01-14T14:08:15.000Z
2021-06-12T17:03:43.000Z
pydtnsim/routing/cgr_utils.py
Elianelin/pydtnsim
916b0ebfa2b65b7a80af293dd4c39f862eadeae3
[ "MIT" ]
4
2019-03-20T15:12:40.000Z
2022-02-22T06:16:24.000Z
"""Module of commonly shared functions of various flavours of CGR.""" import math def cgr_neighbor_function(contact_graph, node, destination, current_distance, set_visited, suppressed_contacts, lookahead_time): """Neighbor function of CGR used by the Dijkstra algorithm. Used to det...
42.268519
79
0.660241
0
0
0
0
0
0
0
0
3,117
0.682804
bdc04f43fced1ed2108de24776b9c054870c3a6d
785
py
Python
rxbp/multicast/multicastobservers/mapmulticastobserver.py
MichaelSchneeberger/rx_backpressure
16173827498bf1bbee3344933cb9efbfd19699f5
[ "Apache-2.0" ]
24
2018-11-22T21:04:49.000Z
2021-11-08T11:18:09.000Z
rxbp/multicast/multicastobservers/mapmulticastobserver.py
MichaelSchneeberger/rx_backpressure
16173827498bf1bbee3344933cb9efbfd19699f5
[ "Apache-2.0" ]
1
2019-02-06T15:58:46.000Z
2019-02-12T20:31:50.000Z
rxbp/multicast/multicastobservers/mapmulticastobserver.py
MichaelSchneeberger/rx_backpressure
16173827498bf1bbee3344933cb9efbfd19699f5
[ "Apache-2.0" ]
1
2021-01-26T12:41:37.000Z
2021-01-26T12:41:37.000Z
from dataclasses import dataclass from typing import Callable from rxbp.multicast.multicastobserver import MultiCastObserver from rxbp.multicast.typing import MultiCastItem @dataclass class MapMultiCastObserver(MultiCastObserver): source: MultiCastObserver func: Callable[[MultiCastItem], MultiCastItem] ...
27.068966
62
0.650955
598
0.761783
310
0.394904
609
0.775796
0
0
0
0
bdc1c2924b490c44031d1301da774e5f85923904
112
py
Python
Unit 5/5.2/5.2.8 Average Test Score.py
shashwat73/cse
60e49307e57105cf9916c7329f53f891c5e81fdb
[ "MIT" ]
1
2021-04-08T14:02:49.000Z
2021-04-08T14:02:49.000Z
Unit 5/5.2/5.2.8 Average Test Score.py
shashwat73/cse
60e49307e57105cf9916c7329f53f891c5e81fdb
[ "MIT" ]
null
null
null
Unit 5/5.2/5.2.8 Average Test Score.py
shashwat73/cse
60e49307e57105cf9916c7329f53f891c5e81fdb
[ "MIT" ]
null
null
null
Score = 0 for For3Scores in range(1,4): Average = int(input()) Score += Average print((Score/3))
12.444444
30
0.589286
0
0
0
0
0
0
0
0
0
0
bdc3d024640dd15b38deac97c8ed950cc5cf3909
415
py
Python
main/rsa_encryption/settings.py
Risoko/RSA-Encryption
1bea1ef3a7609541578d784b7315c73e1e6a481b
[ "MIT" ]
null
null
null
main/rsa_encryption/settings.py
Risoko/RSA-Encryption
1bea1ef3a7609541578d784b7315c73e1e6a481b
[ "MIT" ]
null
null
null
main/rsa_encryption/settings.py
Risoko/RSA-Encryption
1bea1ef3a7609541578d784b7315c73e1e6a481b
[ "MIT" ]
null
null
null
from decouple import config RANGE_OF_PRIME_NUMBERS = { "min": 10, "max": 190 } DATABASE = { 'type': config("TYPE"), 'user': config("USER"), 'password': config("PASSWORD"), 'localhost': config("LOCALHOST"), 'database_name': config("DATABASE_NAME") } PATH_FOR_PUBLIC_KEY = "/home/...
18.863636
54
0.6
0
0
0
0
0
0
0
0
162
0.390361
bdc402ae42475915911f7485b03af5085a350424
2,413
py
Python
clean-up-pdf.py
spider-walker/reading-pdf-files-mongo
3a7b5346bd8e5bedfba388ea9a0053cd8330d332
[ "Apache-2.0" ]
null
null
null
clean-up-pdf.py
spider-walker/reading-pdf-files-mongo
3a7b5346bd8e5bedfba388ea9a0053cd8330d332
[ "Apache-2.0" ]
null
null
null
clean-up-pdf.py
spider-walker/reading-pdf-files-mongo
3a7b5346bd8e5bedfba388ea9a0053cd8330d332
[ "Apache-2.0" ]
null
null
null
with open('./data/data2017.txt') as f: lines = f.readlines() for ln in lines: ln = ln.replace(',', '').replace(':', '').replace('int64', '') \ .replace('Name', '').replace('dtype', '').replace('/', ' ') \ .replace('object', '').replace('float64', ' ') \ .replace('NaN'...
30.544304
98
0.426855
0
0
0
0
0
0
0
0
396
0.164111
bdc63bfed4044eff802e2301570d6c7de4fbc7e5
1,423
py
Python
cv_workshops/7-day/9-clazz.py
afterloe/opencv-practice
83d76132d004ebbc96d99d34a0fd3fc37a044f9f
[ "MIT" ]
5
2020-03-13T07:34:30.000Z
2021-10-01T03:03:05.000Z
cv_workshops/7-day/9-clazz.py
afterloe/Opencv-practice
83d76132d004ebbc96d99d34a0fd3fc37a044f9f
[ "MIT" ]
null
null
null
cv_workshops/7-day/9-clazz.py
afterloe/Opencv-practice
83d76132d004ebbc96d99d34a0fd3fc37a044f9f
[ "MIT" ]
1
2020-03-01T12:35:02.000Z
2020-03-01T12:35:02.000Z
#!/usr/bin/env python3 # -*- coding=utf-8 -*- import cv2 as cv """ 形态学分析应用 - 使用基本梯度对轮廓进行分析处理 使用形态学的二值化处理,对是别内容进行轮廓分析,在OCR上是其处理的手段之一,相比于threshold的二值化而言,对图像会有更好的分割效 果,技术路线如下: 1 图像形态学梯度 2 灰度 3 全局阈值二值化 4 轮廓分析 """ def main(): src = cv.imread("../../pic...
31.622222
121
0.598032
0
0
0
0
0
0
0
0
708
0.419183
bdc6adac6ca6afd61c4934fbf7cff6d47b19bb9a
1,118
py
Python
vaccibot/__main__.py
fsoubelet/vaccibot
f0956ddbf9f0ac712d3e6e10d9fb5f3edb3dda11
[ "MIT" ]
null
null
null
vaccibot/__main__.py
fsoubelet/vaccibot
f0956ddbf9f0ac712d3e6e10d9fb5f3edb3dda11
[ "MIT" ]
null
null
null
vaccibot/__main__.py
fsoubelet/vaccibot
f0956ddbf9f0ac712d3e6e10d9fb5f3edb3dda11
[ "MIT" ]
null
null
null
import sys from loguru import logger from rich.console import Console, RenderGroup from rich.panel import Panel from vaccibot.constants import LOGURU_FORMAT from vaccibot.parsing import ARGS from vaccibot.process import retrieve_all_suitable_appointments from vaccibot.render import make_department_table logger.remov...
30.216216
93
0.674419
0
0
0
0
676
0.604651
0
0
191
0.170841
bdc6c6cba8f42afd0b986c47d1d40853cdff8c8c
4,618
py
Python
buuctf/107-hitcon_ctf_2019_one_punch/exp.py
RoderickChan/ctf_tasks
a021c6d86cade26448d099933f3caa856ed28360
[ "MIT" ]
null
null
null
buuctf/107-hitcon_ctf_2019_one_punch/exp.py
RoderickChan/ctf_tasks
a021c6d86cade26448d099933f3caa856ed28360
[ "MIT" ]
null
null
null
buuctf/107-hitcon_ctf_2019_one_punch/exp.py
RoderickChan/ctf_tasks
a021c6d86cade26448d099933f3caa856ed28360
[ "MIT" ]
null
null
null
from pwncli import * cli_script() p:tube = gift['io'] elf:ELF = gift['elf'] libc: ELF = gift['libc'] pop_rdi_ret = 0x26542 pop_rsi_ret = 0x26f9e pop_rdx_ret = 0x12bda6 pop_rax_ret = 0x47cf8 syscall_ret = 0xcf6c5 def debut(idx, size, name="a"): if isinstance(name, str): pad = "a" else: pad =...
22.637255
83
0.586618
0
0
0
0
0
0
0
0
745
0.161325
bdc856fc9ff913efd9003763250b43ae605b0ec6
1,277
py
Python
pi4home/components/text_sensor/custom.py
khzd/pi4home
937bcdcf77bab111cca10af1fe45c63a55c29aae
[ "MIT" ]
1
2019-05-16T02:52:12.000Z
2019-05-16T02:52:12.000Z
pi4home/components/text_sensor/custom.py
khzd/pi4home
937bcdcf77bab111cca10af1fe45c63a55c29aae
[ "MIT" ]
null
null
null
pi4home/components/text_sensor/custom.py
khzd/pi4home
937bcdcf77bab111cca10af1fe45c63a55c29aae
[ "MIT" ]
null
null
null
import voluptuous as vol from pi4home.components import text_sensor import pi4home.config_validation as cv from pi4home.const import CONF_ID, CONF_LAMBDA, CONF_NAME, CONF_TEXT_SENSORS from pi4home.cpp_generator import add, process_lambda, variable from pi4home.cpp_types import std_vector CustomTextSensorConstructor =...
36.485714
96
0.750196
0
0
479
0.375098
0
0
0
0
55
0.04307
bdc8d13384d848da3326a2122e88d0a41453ccdd
4,589
py
Python
rolling_measures/rolling_measures/__init__.py
marketler/GFW_vessel_scoring
16a141e78258dcc9bab458d5ebd8fad6d2721816
[ "Apache-2.0" ]
null
null
null
rolling_measures/rolling_measures/__init__.py
marketler/GFW_vessel_scoring
16a141e78258dcc9bab458d5ebd8fad6d2721816
[ "Apache-2.0" ]
null
null
null
rolling_measures/rolling_measures/__init__.py
marketler/GFW_vessel_scoring
16a141e78258dcc9bab458d5ebd8fad6d2721816
[ "Apache-2.0" ]
null
null
null
import math import operator import six class NegativePopulationSize(ValueError): def __init__(self, typename): self.typename = typename ValueError.__init__(self) def __str__(self): return str(str(self)) def __unicode__(self): return "More calls to %(type)s.remove() than to %...
28.503106
102
0.568098
4,527
0.986489
0
0
0
0
0
0
662
0.144258
bdcbad672362d3c6fe25962d2ca5b1424db44011
1,186
py
Python
lib/python2.7/site-packages/braintree/transparent_redirect.py
ervinpepic/E-commerce
2c15255d1730728cf35c166b9f88cffcb99f5323
[ "MIT" ]
3
2015-11-05T08:57:12.000Z
2016-07-17T18:10:55.000Z
lib/python2.7/site-packages/braintree/transparent_redirect.py
ervinpepic/E-commerce
2c15255d1730728cf35c166b9f88cffcb99f5323
[ "MIT" ]
13
2020-03-24T17:53:51.000Z
2022-02-10T20:01:14.000Z
lib/python2.7/site-packages/braintree/transparent_redirect.py
ervinpepic/E-commerce
2c15255d1730728cf35c166b9f88cffcb99f5323
[ "MIT" ]
2
2019-04-29T14:16:10.000Z
2020-07-23T12:04:17.000Z
import braintree from braintree.configuration import Configuration class TransparentRedirect: """ A class used for Transparent Redirect operations """ class Kind(object): CreateCustomer = "create_customer" UpdateCustomer = "update_customer" CreatePaymentMethod = "create_payment...
31.210526
93
0.693929
1,116
0.940978
0
0
734
0.618887
0
0
522
0.440135
bdcc6ad7468791c7a47fc038f3016e03c535f1fc
197
py
Python
fluentogram/src/abc/__init__.py
Arustinal/fluentogram
c3d7b307b40d520ef1db5e2a0945f3d7fe269b78
[ "MIT" ]
null
null
null
fluentogram/src/abc/__init__.py
Arustinal/fluentogram
c3d7b307b40d520ef1db5e2a0945f3d7fe269b78
[ "MIT" ]
null
null
null
fluentogram/src/abc/__init__.py
Arustinal/fluentogram
c3d7b307b40d520ef1db5e2a0945f3d7fe269b78
[ "MIT" ]
null
null
null
# coding=utf-8 from .misc import AbstractAttribTracer from .transformer import AbstractDataTransformer from .translator import AbstractTranslator from .translator_hub import AbstractTranslatorsHub
32.833333
50
0.873096
0
0
0
0
0
0
0
0
14
0.071066
bdcc6e536cb58033fe61c7df47d8e2e7c55ae4c2
1,902
py
Python
awsume/autoawsume/process.py
ignatenkobrain/awsume
8191c35e8d60495e608c77801698c0a1a332d76f
[ "MIT" ]
654
2016-04-05T16:51:22.000Z
2022-03-28T21:07:30.000Z
awsume/autoawsume/process.py
ignatenkobrain/awsume
8191c35e8d60495e608c77801698c0a1a332d76f
[ "MIT" ]
149
2016-12-01T17:30:58.000Z
2022-03-29T23:49:50.000Z
awsume/autoawsume/process.py
ignatenkobrain/awsume
8191c35e8d60495e608c77801698c0a1a332d76f
[ "MIT" ]
90
2016-04-12T00:50:04.000Z
2022-03-30T20:44:45.000Z
import argparse import psutil from ..awsumepy.lib.aws_files import delete_section, get_aws_files, read_aws_file from ..awsumepy.lib.logger import logger def kill_autoawsume(): logger.debug('Killing autoawsume') for proc in psutil.process_iter(): try: for command_string in proc.cmdline(): ...
41.347826
101
0.664038
0
0
0
0
0
0
0
0
308
0.161935
bdcd63c3f87c9cdba74f8e75512a7d40eef94fd9
8,787
py
Python
engine/sprite.py
amirgeva/retroupy
1ee19b36a72c5f592cce150d1d0382a00ccdc4a0
[ "BSD-3-Clause" ]
null
null
null
engine/sprite.py
amirgeva/retroupy
1ee19b36a72c5f592cce150d1d0382a00ccdc4a0
[ "BSD-3-Clause" ]
null
null
null
engine/sprite.py
amirgeva/retroupy
1ee19b36a72c5f592cce150d1d0382a00ccdc4a0
[ "BSD-3-Clause" ]
null
null
null
import json import os import gc from .app import get_screen from .utils import Rect from .bitmatrix import BitMatrix class SpritesManager: def __init__(self): self.free_indices = [] self.last_used = -1 self.limit = 160 def clear(self): self.free_indices = [] self.last...
27.719243
100
0.561739
7,930
0.90247
0
0
477
0.054285
0
0
348
0.039604
bdcdd065ac669fb99de9c3ef2f470429acaafd67
1,562
py
Python
models/room.py
kwahalf/data-structures
19ebcbee6108e9b843bace4e7264e5e9e5c5c6fd
[ "MIT" ]
1
2018-12-28T23:56:08.000Z
2018-12-28T23:56:08.000Z
models/room.py
kwahalf/data-structures
19ebcbee6108e9b843bace4e7264e5e9e5c5c6fd
[ "MIT" ]
null
null
null
models/room.py
kwahalf/data-structures
19ebcbee6108e9b843bace4e7264e5e9e5c5c6fd
[ "MIT" ]
null
null
null
from abc import ABCMeta, abstractmethod class Room(object): """class Room""" __metaclass__ = ABCMeta room_count = 0 def __init__(self, name=None, max_capacity=None): self.room_id = self.room_count self.room_count += 1 self.name = name self.max_capacity = max_cap...
27.892857
65
0.599232
1,493
0.955826
0
0
0
0
0
0
127
0.081306
bdcde9db518399671885520f0ddbde248285fab9
3,972
py
Python
tools/checker/file_format/c1visualizer/parser.py
lifansama/xposed_art_n
ec3fbe417d74d4664cec053d91dd4e3881176374
[ "MIT" ]
234
2017-07-18T05:30:27.000Z
2022-01-07T02:21:31.000Z
tools/checker/file_format/c1visualizer/parser.py
lifansama/xposed_art_n
ec3fbe417d74d4664cec053d91dd4e3881176374
[ "MIT" ]
21
2017-07-18T04:56:09.000Z
2018-08-10T17:32:16.000Z
tools/checker/file_format/c1visualizer/parser.py
lifansama/xposed_art_n
ec3fbe417d74d4664cec053d91dd4e3881176374
[ "MIT" ]
56
2017-07-18T10:37:10.000Z
2022-01-07T02:19:22.000Z
# Copyright (C) 2014 The Android Open Source Project # # 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 ...
43.648352
83
0.716012
209
0.052618
0
0
0
0
0
0
1,750
0.440584
bdcfa69692cd0e84e62228bc835f2c497955444e
10,882
py
Python
natcap/versioner/versioning.py
natcap/versioner
65e4c1cf38115dcfec260f0d186cedca192b0b2e
[ "BSD-3-Clause" ]
null
null
null
natcap/versioner/versioning.py
natcap/versioner
65e4c1cf38115dcfec260f0d186cedca192b0b2e
[ "BSD-3-Clause" ]
null
null
null
natcap/versioner/versioning.py
natcap/versioner
65e4c1cf38115dcfec260f0d186cedca192b0b2e
[ "BSD-3-Clause" ]
null
null
null
from __future__ import absolute_import import logging import os import re import subprocess import six LOGGER = logging.getLogger('natcap.versioner.versioning') LOGGER.setLevel(logging.ERROR) class VCSQuerier(object): name = 'VCS' is_archive = False repo_data_location = '' def __init__(self, repo_pa...
32.195266
86
0.609355
8,998
0.82687
0
0
3,863
0.35499
0
0
3,661
0.336427
bdd0adc5de287fb179800281e8709f5913da7913
878
py
Python
tests/utils/init_test.py
swinton/mopidy
c32c73f5112c29ef7ccccf36a508c571adb39759
[ "Apache-2.0" ]
null
null
null
tests/utils/init_test.py
swinton/mopidy
c32c73f5112c29ef7ccccf36a508c571adb39759
[ "Apache-2.0" ]
null
null
null
tests/utils/init_test.py
swinton/mopidy
c32c73f5112c29ef7ccccf36a508c571adb39759
[ "Apache-2.0" ]
null
null
null
from mopidy import utils from tests import unittest class GetClassTest(unittest.TestCase): def test_loading_module_that_does_not_exist(self): with self.assertRaises(ImportError): utils.get_class('foo.bar.Baz') def test_loading_class_that_does_not_exist(self): with self.assertRais...
31.357143
69
0.6959
822
0.936219
0
0
0
0
0
0
99
0.112756
bdd18a04d17e95c0953ca2e0c3d8db5c195b7e67
1,054
py
Python
src/two_level_aspect_entity_embedding_generation/clusterd_knowledge_graph_statistics.py
mainuliitkgp/AR-BERT
d6d5e8542a3a1c76edac49cec9e99ebda6395725
[ "MIT" ]
4
2022-03-06T17:41:57.000Z
2022-03-22T08:42:58.000Z
src/two_level_aspect_entity_embedding_generation/clusterd_knowledge_graph_statistics.py
mainuliitkgp/AR-BERT
d6d5e8542a3a1c76edac49cec9e99ebda6395725
[ "MIT" ]
null
null
null
src/two_level_aspect_entity_embedding_generation/clusterd_knowledge_graph_statistics.py
mainuliitkgp/AR-BERT
d6d5e8542a3a1c76edac49cec9e99ebda6395725
[ "MIT" ]
1
2022-03-19T14:04:42.000Z
2022-03-19T14:04:42.000Z
from __future__ import print_function import numpy as np import random import json import sys import os import networkx as nx from networkx.readwrite import json_graph version_info = list(map(int, nx.__version__.split('.'))) major = version_info[0] minor = version_info[1] assert (major <= 1) and (minor <= 11), "netwo...
28.486486
84
0.651803
0
0
0
0
0
0
0
0
92
0.087287
bdd1f5712640c660f6739b854770d7e695f1c4d4
8,167
py
Python
src/aioros/tcpros/topic.py
mgrrx/aioros
9bd750020d0d5fb466891346f61b6f083cbb8f05
[ "Apache-2.0" ]
8
2020-08-27T17:16:59.000Z
2022-02-02T13:39:41.000Z
src/aioros/tcpros/topic.py
mgrrx/aioros
9bd750020d0d5fb466891346f61b6f083cbb8f05
[ "Apache-2.0" ]
3
2022-02-09T19:18:12.000Z
2022-03-08T21:12:00.000Z
src/aioros/tcpros/topic.py
mgrrx/aioros
9bd750020d0d5fb466891346f61b6f083cbb8f05
[ "Apache-2.0" ]
null
null
null
from asyncio import AbstractEventLoop from asyncio import iscoroutinefunction from asyncio import Event from asyncio import IncompleteReadError from asyncio import Queue from asyncio import open_connection from asyncio import open_unix_connection from typing import Dict from typing import List from typing import Set fr...
32.40873
75
0.628872
7,511
0.919677
0
0
808
0.098935
3,769
0.461491
114
0.013959
bdd325e14189de11da8187eeb203eba8b96feec5
1,911
py
Python
tests/core/test_local.py
riddopic/opta
25fa6435fdc7e2ea9c7963ed74100fffb0743063
[ "Apache-2.0" ]
595
2021-05-21T22:30:48.000Z
2022-03-31T15:40:25.000Z
tests/core/test_local.py
riddopic/opta
25fa6435fdc7e2ea9c7963ed74100fffb0743063
[ "Apache-2.0" ]
463
2021-05-24T21:32:59.000Z
2022-03-31T17:12:33.000Z
tests/core/test_local.py
riddopic/opta
25fa6435fdc7e2ea9c7963ed74100fffb0743063
[ "Apache-2.0" ]
29
2021-05-21T22:27:52.000Z
2022-03-28T16:43:45.000Z
import json import os import unittest from opta.core.local import Local from opta.layer import Layer class LocalTests(unittest.TestCase): def setUp(self) -> None: self.layer = Layer( name="testname", org_name="testorg", providers={"local": {"path": "/tmp"}}, ...
30.333333
65
0.529042
1,806
0.945055
0
0
0
0
0
0
384
0.200942
bdd3722beee7f3a9735cf08fa0cf57f708146d63
132
py
Python
train/antpush/environments/ant_maze_env.py
MIMUW-RL/spp-rl
86b96cdd220cc4eae86f7cfd26924c69b498dcc6
[ "MIT" ]
7
2020-06-15T12:25:53.000Z
2021-11-03T01:08:47.000Z
train/antpush/environments/ant_maze_env.py
MIMUW-RL/spp-rl
86b96cdd220cc4eae86f7cfd26924c69b498dcc6
[ "MIT" ]
null
null
null
train/antpush/environments/ant_maze_env.py
MIMUW-RL/spp-rl
86b96cdd220cc4eae86f7cfd26924c69b498dcc6
[ "MIT" ]
1
2020-12-21T11:21:22.000Z
2020-12-21T11:21:22.000Z
from environments.maze_env import MazeEnv from environments.ant import AntEnv class AntMazeEnv(MazeEnv): MODEL_CLASS = AntEnv
18.857143
41
0.810606
51
0.386364
0
0
0
0
0
0
0
0
bdd3ab9d894a791877cd5b110bbcf4db48bff423
7,943
py
Python
test/test_state.py
bjornaa/ladim2
f6c1be9028ca54370ce33dde25b005d5b0bb4677
[ "MIT" ]
null
null
null
test/test_state.py
bjornaa/ladim2
f6c1be9028ca54370ce33dde25b005d5b0bb4677
[ "MIT" ]
null
null
null
test/test_state.py
bjornaa/ladim2
f6c1be9028ca54370ce33dde25b005d5b0bb4677
[ "MIT" ]
null
null
null
import numpy as np # type: ignore import pytest from ladim2.state import State # ------------ # __init__ # ------------ def test_init_minimal(): """Init State with no arguments""" S = State() assert len(S) == 0 assert S.npid == 0 assert set(S.variables) == {"pid", "X", "Y", "Z", "active", "aliv...
27.675958
85
0.590583
0
0
0
0
0
0
0
0
1,548
0.194889
bdd4db2e43df9f7b67e7a41de13b7d8d81ab3b7c
220
py
Python
mysite/myinviteapi/models.py
datha88/rest-api-sample-friend-invite
1880837f4831c2d867a5a4ac1a176953838fab0d
[ "MIT" ]
null
null
null
mysite/myinviteapi/models.py
datha88/rest-api-sample-friend-invite
1880837f4831c2d867a5a4ac1a176953838fab0d
[ "MIT" ]
null
null
null
mysite/myinviteapi/models.py
datha88/rest-api-sample-friend-invite
1880837f4831c2d867a5a4ac1a176953838fab0d
[ "MIT" ]
null
null
null
from django.db import models # Create your models here. class Friend(models.Model): name = models.CharField(max_length=60) email = models.CharField(max_length=60) def __str__(self): return self.name
24.444444
43
0.713636
162
0.736364
0
0
0
0
0
0
26
0.118182
bdd62727280cef056fc775786f12ebffe8812748
28,253
py
Python
tiknib/feature/asm_const.py
SoftSec-KAIST/tiknib
5f1e25df0ff652cf35574dae3e6a3cfb3b163e63
[ "MIT" ]
null
null
null
tiknib/feature/asm_const.py
SoftSec-KAIST/tiknib
5f1e25df0ff652cf35574dae3e6a3cfb3b163e63
[ "MIT" ]
null
null
null
tiknib/feature/asm_const.py
SoftSec-KAIST/tiknib
5f1e25df0ff652cf35574dae3e6a3cfb3b163e63
[ "MIT" ]
null
null
null
from tiknib.feature.asm_ppc import PPC_GRP_MAP # ==================== x86 32 ============================================= # data transfer X86_GRP_DTRANSFER = [ # general purpose instructions "CMOV", "CMOVA", "CMOVAE", "CMOVB", "CMOVBE", "CMOVC", "CMOVE", "CMOVG", "CMOVGE", "...
14.753525
88
0.455952
0
0
0
0
0
0
0
0
13,772
0.487453
bdd65fd304b42fd5e57669cf829df3d843fd24ed
814
py
Python
dwi/patient.py
jupito/dwilib
6655eea21037977ed528b992b3a8471393127b77
[ "MIT" ]
9
2018-02-02T07:26:06.000Z
2021-07-28T11:27:38.000Z
dwi/patient.py
jupito/dwilib
6655eea21037977ed528b992b3a8471393127b77
[ "MIT" ]
null
null
null
dwi/patient.py
jupito/dwilib
6655eea21037977ed528b992b3a8471393127b77
[ "MIT" ]
4
2017-02-22T03:23:44.000Z
2021-12-10T10:32:08.000Z
"""Routines for handling patient lists.""" # TODO: Some functions from dwi.compat should be replaced with something better # here, they're still used by tools/{roc_auc,correlation}.py. from .types import GleasonScore def label_lesions(patients, thresholds=None): """Label lesions according to score groups.""" ...
33.916667
79
0.697789
0
0
0
0
0
0
0
0
362
0.444717
bdd6f392de5f9a7829a76f27096203708e20bfc0
79
py
Python
2017/12.12/python/lsh-get-github-user.py
mksweetlife/study
0786a4bd7901ac0d1aa5efdae5b755693eee5cd3
[ "MIT" ]
1
2017-10-24T08:19:15.000Z
2017-10-24T08:19:15.000Z
2017/12.12/python/lsh-get-github-user.py
mksweetlife/study
0786a4bd7901ac0d1aa5efdae5b755693eee5cd3
[ "MIT" ]
31
2017-10-31T11:09:44.000Z
2018-12-04T07:47:46.000Z
2017/12.12/python/lsh-get-github-user.py
mksweetlife/study
0786a4bd7901ac0d1aa5efdae5b755693eee5cd3
[ "MIT" ]
5
2017-10-26T02:13:08.000Z
2018-07-05T04:58:47.000Z
def getUser(): return "Sanghak,Lee / http://sanghaklee.tistory.com" #FIXME:
39.5
64
0.696203
0
0
0
0
0
0
0
0
52
0.658228
bdd8443fccc1ae0affec98253387eaf4b0c3a80b
5,039
py
Python
runNum.py
NuPatchara/gitCV
68d1ecf3150cc819051a3bb718fae160da0ddcf9
[ "Apache-2.0" ]
null
null
null
runNum.py
NuPatchara/gitCV
68d1ecf3150cc819051a3bb718fae160da0ddcf9
[ "Apache-2.0" ]
null
null
null
runNum.py
NuPatchara/gitCV
68d1ecf3150cc819051a3bb718fae160da0ddcf9
[ "Apache-2.0" ]
null
null
null
import sys import cv2 import os, os.path import ColorClustering import numpy as np from PIL import Image from pytesser import * from sklearn.cluster import KMeans from sklearn.externals import joblib def find_most_Color(im, clusters): imBodyRGB = cv2.cvtColor(im, cv2.COLOR_BGR2RGB) imBodyRGB = imBodyRGB.reshap...
41.991667
118
0.519944
0
0
0
0
0
0
0
0
189
0.037507
bdd85f75dbf5d4102a25ebc2445a8a860dd88729
4,920
py
Python
networkunit/scores/score_kl_divergence.py
morales-gregorio/NetworkUnit
b858c3b2698fe3c0a7324ae8b8b388b74fd13c4d
[ "BSD-3-Clause" ]
8
2017-11-16T08:45:48.000Z
2021-11-29T16:51:45.000Z
networkunit/scores/score_kl_divergence.py
morales-gregorio/NetworkUnit
b858c3b2698fe3c0a7324ae8b8b388b74fd13c4d
[ "BSD-3-Clause" ]
17
2017-11-16T07:53:26.000Z
2021-05-07T10:27:34.000Z
networkunit/scores/score_kl_divergence.py
russelljjarvis/NetworkUnit
32179371d3a0ba354e6637cf4f97ba70522d4054
[ "BSD-3-Clause" ]
5
2019-03-23T00:55:33.000Z
2020-01-24T10:12:11.000Z
import numpy as np from scipy.stats import entropy import matplotlib.pyplot as plt import matplotlib.colors as colors import seaborn as sns import sciunit class kl_divergence(sciunit.Score): """ Kullback-Leibner Divergence D_KL(P||Q) Calculates the difference of two sampled distributions P and Q in form ...
35.912409
80
0.570732
4,763
0.968089
0
0
3,459
0.703049
0
0
1,141
0.231911
bdd862ba88395be8cb418cfab8ce408473323919
635
py
Python
kikyo/config.py
jadbin/kikyo
98d875e85a28b4141cbd6616bba3d397a4219dc9
[ "MIT" ]
null
null
null
kikyo/config.py
jadbin/kikyo
98d875e85a28b4141cbd6616bba3d397a4219dc9
[ "MIT" ]
null
null
null
kikyo/config.py
jadbin/kikyo
98d875e85a28b4141cbd6616bba3d397a4219dc9
[ "MIT" ]
null
null
null
import base64 import io import requests import yaml from kikyo import Kikyo, Settings def configure_by_consul(config_url: str, **kwargs) -> Kikyo: """从Consul拉取YAML格式的配置文件 :param config_url: 获取配置项的URL地址 """ resp = requests.get(config_url) resp.raise_for_status() settings = Settings() f...
19.84375
60
0.617323
0
0
0
0
0
0
0
0
124
0.184799
bdd932ec045f92a204fc0462b20bc5fe9de822e1
5,077
py
Python
tests/ep_canvas_test.py
PytLab/catplot
63ad46218b17d5cdffdd026dad7d775cf4caa50b
[ "MIT" ]
35
2015-12-23T08:01:15.000Z
2021-11-03T01:34:20.000Z
tests/ep_canvas_test.py
PytLab/catplot
63ad46218b17d5cdffdd026dad7d775cf4caa50b
[ "MIT" ]
1
2015-11-25T05:52:43.000Z
2017-04-11T14:06:00.000Z
tests/ep_canvas_test.py
PytLab/catplot
63ad46218b17d5cdffdd026dad7d775cf4caa50b
[ "MIT" ]
10
2015-11-06T20:23:32.000Z
2020-05-16T19:18:38.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- """ Test case for Energy Profle Canvas. """ import unittest import matplotlib.pyplot as plt from catplot.ep_components.ep_canvas import EPCanvas from catplot.ep_components.ep_lines import ElementaryLine from catplot.ep_components.ep_chain import EPChain class EPCanvas...
30.769697
84
0.623203
4,617
0.909395
0
0
0
0
0
0
914
0.180028
bdd9723808bf563a488aa0b07c42aceeac435545
458
py
Python
Leetcode/medium/bitwise-and-of-numbers-range.py
jen-sjen/data-structures-basics-leetcode
addac32974b16e0a37aa60c210ab7820b349b279
[ "MIT" ]
6
2021-07-29T03:26:20.000Z
2022-01-28T15:11:45.000Z
Leetcode/medium/bitwise-and-of-numbers-range.py
jen-sjen/data-structures-basics-leetcode
addac32974b16e0a37aa60c210ab7820b349b279
[ "MIT" ]
2
2021-09-30T09:47:23.000Z
2022-01-31T03:08:24.000Z
Leetcode/medium/bitwise-and-of-numbers-range.py
jen-sjen/data-structures-basics-leetcode
addac32974b16e0a37aa60c210ab7820b349b279
[ "MIT" ]
5
2021-08-10T06:41:11.000Z
2022-01-29T17:50:20.000Z
""" # BITWISE AND OF NUMBERS RANGE Given a range [m, n] where 0 <= m <= n <= 2147483647, return the bitwise AND of all numbers in this range, inclusive. Example 1: Input: [5,7] Output: 4 Example 2: Input: [0,1] Output: 0 """ class Solution: def rangeBitwiseAnd(self, m: int, n: int) -> int: ...
17.615385
117
0.508734
225
0.491266
0
0
0
0
0
0
231
0.504367
bddccaa847cf3d70df32c8b547be9368dbd1d908
20
py
Python
api/views/consts.py
tarikyayla/reddit_dashboard
e5ecf3349a5c9333793c3ae5375bc4a0e501a16c
[ "MIT" ]
null
null
null
api/views/consts.py
tarikyayla/reddit_dashboard
e5ecf3349a5c9333793c3ae5375bc4a0e501a16c
[ "MIT" ]
null
null
null
api/views/consts.py
tarikyayla/reddit_dashboard
e5ecf3349a5c9333793c3ae5375bc4a0e501a16c
[ "MIT" ]
1
2020-11-27T23:24:09.000Z
2020-11-27T23:24:09.000Z
GET_FROM_REDDIT = 1
10
19
0.8
0
0
0
0
0
0
0
0
0
0
bddd1a20f636344c19e0119a658dd15a4909a0a2
2,955
py
Python
match_rcnn/mmdetection/mmdet/pretrained_models/cocopth.py
201419/taobao-live-product-recognition
1f5de5917b43b2b58f4387a77272fc7c587a1051
[ "Apache-2.0" ]
null
null
null
match_rcnn/mmdetection/mmdet/pretrained_models/cocopth.py
201419/taobao-live-product-recognition
1f5de5917b43b2b58f4387a77272fc7c587a1051
[ "Apache-2.0" ]
null
null
null
match_rcnn/mmdetection/mmdet/pretrained_models/cocopth.py
201419/taobao-live-product-recognition
1f5de5917b43b2b58f4387a77272fc7c587a1051
[ "Apache-2.0" ]
1
2021-05-14T03:30:29.000Z
2021-05-14T03:30:29.000Z
import torch import numpy as np num_classes = 25 model_coco = torch.load(r"/media/alvinai/Documents/model/faster_rcnn_r50_fpn_1x_20190610-bf0ea559.pth") # print(model_coco) # print(model_coco["state_dict"]["rpn_head.rpn_cls.weight"].shape) # a = model_coco["state_dict"]["rpn_head.rpn_cls.weight"][0] # model_co...
75.769231
140
0.706937
0
0
0
0
0
0
0
0
2,493
0.843655