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
4707b4d7f941097b9eae2aa1a1af3bbf0a103d6c
3,350
py
Python
configr/test.py
ArneBachmann/configr
ed41d18467f370abcadf6f8661f10486ae1cfd00
[ "MIT" ]
1
2016-12-30T22:18:24.000Z
2016-12-30T22:18:24.000Z
configr/test.py
ArneBachmann/configr
ed41d18467f370abcadf6f8661f10486ae1cfd00
[ "MIT" ]
8
2017-05-15T12:11:04.000Z
2018-02-20T20:50:15.000Z
configr/test.py
ArneBachmann/configr
ed41d18467f370abcadf6f8661f10486ae1cfd00
[ "MIT" ]
null
null
null
import doctest, json, logging, os, unittest, sys sys.path.insert(0, "..") import configr class Tests(unittest.TestCase): ''' Test suite. ''' def tests_metadata(_): _.assertTrue(hasattr(configr, "version")) _.assertTrue(hasattr(configr.version, "__version__")) _.assertTrue(hasattr(configr.version, "_...
37.222222
136
0.64209
2,876
0.858507
0
0
0
0
0
0
829
0.247463
47082baa4e7989bb5b9aca7bfcf972c10b053741
1,640
py
Python
euler.py
Epitrochoid/biophys-class
622bc8c6cfd3e22abf2473115b878843545f29d3
[ "Zlib" ]
null
null
null
euler.py
Epitrochoid/biophys-class
622bc8c6cfd3e22abf2473115b878843545f29d3
[ "Zlib" ]
null
null
null
euler.py
Epitrochoid/biophys-class
622bc8c6cfd3e22abf2473115b878843545f29d3
[ "Zlib" ]
null
null
null
import numpy as np import matplotlib.pyplot as plt # define constants g_l = 2.0 g_ca = 4.0 g_k = 8.0 e_l = -50.0 e_ca = 100.0 e_k = -70.0 tau = 0.1 v1 = -1.2 v2 = 18.0 v3 = 2.0 v4 = 30.0 cap = 20.0 # steady state functions def m_ss(v): return (1.0/2.0) * (1.0 + np.tanh((v - v1)/v2)) def n_ss(v): return (1.0/...
21.298701
80
0.628049
0
0
0
0
0
0
0
0
266
0.162195
47082ce9e469b71dd433d3cc99431608afdc8cec
12,059
py
Python
prepare_data.py
ondrejklejch/acoustic_punctuation
a58b79d838ca0cdd82186189be290289ed70b106
[ "Apache-2.0" ]
10
2020-02-12T18:35:27.000Z
2021-06-09T03:28:44.000Z
prepare_data.py
choko/acoustic_punctuation
a58b79d838ca0cdd82186189be290289ed70b106
[ "Apache-2.0" ]
2
2020-03-30T07:58:33.000Z
2020-05-09T02:12:09.000Z
prepare_data.py
choko/acoustic_punctuation
a58b79d838ca0cdd82186189be290289ed70b106
[ "Apache-2.0" ]
4
2019-10-08T07:35:35.000Z
2020-10-16T08:33:19.000Z
import h5py import kaldi_io import numpy as np from collections import defaultdict from config import get_config from fuel.datasets.hdf5 import H5PYDataset from lexicon import create_dictionary_from_lexicon, create_dictionary_from_punctuation_marks def get_uttids_from_text_file(path): uttids = set() with open...
43.222222
195
0.623518
0
0
740
0.061365
0
0
0
0
1,019
0.084501
47083658578f509f29ab5750cc149c0842c89002
511
py
Python
TSSystem/apps/student/migrations/0013_auto_20180607_1924.py
LittleBai0606/TeachingSecretarySystem
c9067b83f8e1edaf06974db73b7cc47a5b49e0d4
[ "MIT" ]
null
null
null
TSSystem/apps/student/migrations/0013_auto_20180607_1924.py
LittleBai0606/TeachingSecretarySystem
c9067b83f8e1edaf06974db73b7cc47a5b49e0d4
[ "MIT" ]
5
2020-06-05T18:13:28.000Z
2022-02-11T03:39:14.000Z
TSSystem/apps/student/migrations/0013_auto_20180607_1924.py
WhiteBrownBottle/TeachingSecretarySystem
c9067b83f8e1edaf06974db73b7cc47a5b49e0d4
[ "MIT" ]
null
null
null
# Generated by Django 2.0.5 on 2018-06-07 19:24 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('student', '0012_auto_20180607_1916'), ] operations = [ migrations.AlterField( model_name='student', name='student_pa...
26.894737
164
0.665362
430
0.82218
0
0
0
0
0
0
208
0.397706
47092f96a5b0022e0fac79b527512d8f3952d111
3,409
py
Python
instagram/views.py
derrokip34/Instagram-Clone
63fdff902382b5e4986667566a901cca748b5731
[ "MIT" ]
null
null
null
instagram/views.py
derrokip34/Instagram-Clone
63fdff902382b5e4986667566a901cca748b5731
[ "MIT" ]
4
2020-06-02T13:03:34.000Z
2021-06-10T22:59:11.000Z
instagram/views.py
derrokip34/Instagram-Clone
63fdff902382b5e4986667566a901cca748b5731
[ "MIT" ]
null
null
null
from django.shortcuts import render,redirect from django.contrib.auth.models import User from django.contrib.auth.decorators import login_required from .models import Image,Profile,Comments from .forms import UpdateProfile,UpdateUser,PostImageForm,CommentForm from django.conf.urls import url # Create your views here. ...
37.054348
137
0.694045
0
0
0
0
2,921
0.85685
0
0
583
0.171018
4709430dc3111986d3531b884a393ec597c0e3c5
10,596
py
Python
wahltraud/bot/bot.py
wdr-data/wahltraud
0f972680f6cdbb66028aa8a39fc4a78a3e0ca08a
[ "RSA-MD" ]
7
2017-07-02T12:25:45.000Z
2019-05-27T10:39:41.000Z
wahltraud/bot/bot.py
wdr-data/wahltraud
0f972680f6cdbb66028aa8a39fc4a78a3e0ca08a
[ "RSA-MD" ]
null
null
null
wahltraud/bot/bot.py
wdr-data/wahltraud
0f972680f6cdbb66028aa8a39fc4a78a3e0ca08a
[ "RSA-MD" ]
null
null
null
import logging from threading import Thread from time import sleep import os import json import schedule #from django.utils.timezone import localtime, now from apiai import ApiAI from backend.models import Push, FacebookUser, Wiki from .fb import send_text, send_buttons, button_postback, PAGE_TOKEN from .handlers.pay...
40.288973
147
0.60806
0
0
0
0
0
0
0
0
2,274
0.214468
470e472fe7ae958fe62d97b5ce9dca8b55363b3a
4,994
py
Python
dbix/postgresql.py
alexbodn/python-dbix
769298cc510a95437d9d7e7641b616b6aec97ced
[ "Apache-2.0" ]
null
null
null
dbix/postgresql.py
alexbodn/python-dbix
769298cc510a95437d9d7e7641b616b6aec97ced
[ "Apache-2.0" ]
3
2021-03-25T21:40:41.000Z
2021-11-15T17:46:46.000Z
dbix/postgresql.py
alexbodn/python-dbix
769298cc510a95437d9d7e7641b616b6aec97ced
[ "Apache-2.0" ]
null
null
null
from .sqlschema import SQLSchema, SQLResultSet import psycopg2 import psycopg2.extensions as pe class POSTGRESQLResultSet(SQLResultSet): def perform_insert(self, script, param, pk_fields, table, new_key): script += u' returning %s' % u','. join ([ self.schema.render_name(field) for field in pk_fields ]) ...
25.222222
94
0.692231
4,890
0.979175
0
0
0
0
0
0
1,264
0.253104
470f91dbbbad1edd443e920c9753325697ced101
2,232
py
Python
datahub/cleanup/cleanup_config.py
Staberinde/data-hub-api
3d0467dbceaf62a47158eea412a3dba827073300
[ "MIT" ]
6
2019-12-02T16:11:24.000Z
2022-03-18T10:02:02.000Z
datahub/cleanup/cleanup_config.py
Staberinde/data-hub-api
3d0467dbceaf62a47158eea412a3dba827073300
[ "MIT" ]
1,696
2019-10-31T14:08:37.000Z
2022-03-29T12:35:57.000Z
datahub/cleanup/cleanup_config.py
Staberinde/data-hub-api
3d0467dbceaf62a47158eea412a3dba827073300
[ "MIT" ]
9
2019-11-22T12:42:03.000Z
2021-09-03T14:25:05.000Z
from datetime import datetime from typing import Any, Mapping, NamedTuple, Sequence, Union from dateutil.relativedelta import relativedelta from dateutil.utils import today from django.db.models import Q from django.utils.timezone import utc class DatetimeLessThanCleanupFilter(NamedTuple): """Represents a filter...
36
95
0.696237
1,983
0.888441
0
0
279
0.125
0
0
1,065
0.477151
47101f05f02766f88ec6f7f2f38dd2a79a508d4e
7,696
py
Python
script/balance_stream_weights.py
oliverwatts/snickery
6d7e0b48cbb21760089bbbe85f6d7bd206f89821
[ "Apache-2.0" ]
28
2018-06-26T02:57:45.000Z
2021-12-01T01:07:23.000Z
script/balance_stream_weights.py
oliverwatts/snickery
6d7e0b48cbb21760089bbbe85f6d7bd206f89821
[ "Apache-2.0" ]
1
2018-11-02T09:29:29.000Z
2018-11-02T10:20:28.000Z
script/balance_stream_weights.py
oliverwatts/snickery
6d7e0b48cbb21760089bbbe85f6d7bd206f89821
[ "Apache-2.0" ]
5
2018-12-21T08:05:06.000Z
2021-01-16T16:43:42.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- ## Project: ## Author: Oliver Watts - owatts@staffmail.ed.ac.uk import sys import os import glob import re import timeit import math from argparse import ArgumentParser import numpy as np from synth_halfphone import Synthesiser import copy # import pylab if __name__...
33.903084
124
0.588617
0
0
0
0
0
0
0
0
2,269
0.294828
4711f0f7f0f4b6e8dfb47ed59210af2da72647a5
39,693
py
Python
cinder/tests/unit/volume/drivers/test_hgst.py
rackerlabs/cinder
4295ff0a64f781c3546f6c6e0816dbb8100133cb
[ "Apache-2.0" ]
1
2019-02-08T05:24:58.000Z
2019-02-08T05:24:58.000Z
cinder/tests/unit/volume/drivers/test_hgst.py
rackerlabs/cinder
4295ff0a64f781c3546f6c6e0816dbb8100133cb
[ "Apache-2.0" ]
1
2021-03-21T11:38:29.000Z
2021-03-21T11:38:29.000Z
cinder/tests/unit/volume/drivers/test_hgst.py
rackerlabs/cinder
4295ff0a64f781c3546f6c6e0816dbb8100133cb
[ "Apache-2.0" ]
15
2017-01-12T10:35:10.000Z
2019-04-19T08:22:10.000Z
# Copyright (c) 2015 HGST Inc # 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 ...
42.407051
78
0.586149
32,479
0.818255
0
0
17,725
0.446552
0
0
16,654
0.41957
4712052d73125063f1e6bbdd64f996c9f81e1a5e
73
py
Python
tests/fixtures/custom_functions.py
helobinvn/zuul
dda840b82934c82b9783bdc29f2f0626883cc47e
[ "Apache-2.0" ]
null
null
null
tests/fixtures/custom_functions.py
helobinvn/zuul
dda840b82934c82b9783bdc29f2f0626883cc47e
[ "Apache-2.0" ]
84
2015-10-22T11:21:02.000Z
2022-03-31T02:24:54.000Z
tests/fixtures/custom_functions.py
helobinvn/zuul
dda840b82934c82b9783bdc29f2f0626883cc47e
[ "Apache-2.0" ]
21
2016-02-10T11:20:37.000Z
2022-01-05T02:53:37.000Z
def select_debian_node(item, params): params['ZUUL_NODE'] = 'debian'
24.333333
37
0.712329
0
0
0
0
0
0
0
0
19
0.260274
4712fd08313b612b844d6ece1a959125317b1b34
9,044
py
Python
usaspending_api/database_scripts/matview_generator/matview_sql_generator.py
Theyfeartruthfedgov2020/usaspending-api
579a981282302a0e6dc0f19bebf9d446d0a12e75
[ "CC0-1.0" ]
null
null
null
usaspending_api/database_scripts/matview_generator/matview_sql_generator.py
Theyfeartruthfedgov2020/usaspending-api
579a981282302a0e6dc0f19bebf9d446d0a12e75
[ "CC0-1.0" ]
null
null
null
usaspending_api/database_scripts/matview_generator/matview_sql_generator.py
Theyfeartruthfedgov2020/usaspending-api
579a981282302a0e6dc0f19bebf9d446d0a12e75
[ "CC0-1.0" ]
null
null
null
#!/usr/bin/env python3 import argparse import glob import hashlib import os from shared_sql_generator import ( COMPONENT_DIR, generate_uid, HERE, ingest_json, make_indexes_sql, make_matview_refresh, make_modification_sql, make_stats_sql, split_indexes_chunks, TEMPLATE, ) # Usa...
34.128302
118
0.685648
0
0
0
0
0
0
0
0
2,787
0.30816
47145db2bd97cca1e96b5c6c5f106f848f49e927
1,526
py
Python
p287m/find_duplicate.py
l33tdaima/l33tdaima
0a7a9573dc6b79e22dcb54357493ebaaf5e0aa90
[ "MIT" ]
1
2020-02-20T12:04:46.000Z
2020-02-20T12:04:46.000Z
p287m/find_duplicate.py
l33tdaima/l33tdaima
0a7a9573dc6b79e22dcb54357493ebaaf5e0aa90
[ "MIT" ]
null
null
null
p287m/find_duplicate.py
l33tdaima/l33tdaima
0a7a9573dc6b79e22dcb54357493ebaaf5e0aa90
[ "MIT" ]
null
null
null
from typing import List class Solution: def findDuplicate(self, nums: List[int]) -> int: lo, hi = 1, len(nums) - 1 while lo < hi: mid = (lo + hi) // 2 lt, eq = 0, 0 for n in nums: if n == mid: eq += 1 elif lo <...
25.433333
57
0.415465
1,038
0.68021
0
0
0
0
0
0
142
0.093054
471541a5cf52f118d9542ca2f78a5e604679f92d
194
py
Python
manager/integration/tests/cloudprovider.py
kaxing/longhorn-tests
e8e95f1446155f20cbbb9b47d8e139de09d567f0
[ "Apache-2.0" ]
10
2021-01-25T00:52:46.000Z
2022-02-20T01:49:56.000Z
manager/integration/tests/cloudprovider.py
kaxing/longhorn-tests
e8e95f1446155f20cbbb9b47d8e139de09d567f0
[ "Apache-2.0" ]
273
2019-06-12T17:43:49.000Z
2022-03-29T09:06:02.000Z
manager/integration/tests/cloudprovider.py
kaxing/longhorn-tests
e8e95f1446155f20cbbb9b47d8e139de09d567f0
[ "Apache-2.0" ]
24
2019-06-12T04:03:00.000Z
2022-03-21T08:08:47.000Z
class cloudprovider: def instance_id(self): pass def instance_stop(self): pass def instance_start(self): pass def instance_status(self): pass
13.857143
30
0.592784
193
0.994845
0
0
0
0
0
0
0
0
4715f519d8a21d72474f587c7da538635e521fe0
13,733
py
Python
examples/gaussian_processes/plot_sparse_log_cox_gaussian_process_keras.py
ltiao/scribbles
9f30ea92ee348154568a7791751634d1feaba774
[ "MIT" ]
1
2020-03-01T04:36:36.000Z
2020-03-01T04:36:36.000Z
examples/gaussian_processes/plot_sparse_log_cox_gaussian_process_keras.py
ltiao/scribbles
9f30ea92ee348154568a7791751634d1feaba774
[ "MIT" ]
3
2020-01-02T19:09:40.000Z
2020-01-02T19:11:02.000Z
examples/gaussian_processes/plot_sparse_log_cox_gaussian_process_keras.py
ltiao/scribbles
9f30ea92ee348154568a7791751634d1feaba774
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Variational Sparse Log Cox Gaussian Process =========================================== Here we fit the hyperparameters of a Gaussian Process by maximizing the (log) marginal likelihood. This is commonly referred to as empirical Bayes, or type-II maximum likelihood estimation. """ # sphinx_...
26.874755
82
0.675599
4,290
0.312386
0
0
1,787
0.130125
0
0
2,484
0.180878
4716481bbd0431d8beee38613c06cbb5f7bf0cd1
822
py
Python
material/week1/py/w1e1d.py
mpambasange/MachineLearning
8b813345264513a57934317b01e1311628dc5b01
[ "MIT" ]
16
2016-09-01T08:50:59.000Z
2022-02-15T20:56:07.000Z
material/week1/py/w1e1d.py
olehermanse/INF3490-PythonAI
8b813345264513a57934317b01e1311628dc5b01
[ "MIT" ]
2
2016-10-20T09:36:19.000Z
2017-08-29T00:28:54.000Z
material/week1/py/w1e1d.py
olehermanse/INF3490-PythonAI
8b813345264513a57934317b01e1311628dc5b01
[ "MIT" ]
15
2016-10-31T12:30:37.000Z
2021-03-15T12:12:50.000Z
#!/usr/bin/env python3 import numpy as np import matplotlib.pyplot as plt import random def f(x): return -x**4 + 2 * x**3 + 2 * x**2 - x def exhaustive(function, start, stop, step): x = start best = (x, function(x)) while x < stop: y = function(x) if y > best[1]: best = (x,...
25.6875
70
0.599757
0
0
0
0
0
0
0
0
71
0.086375
471654000ff572cf541ee8cb15531d2329efd52d
389
py
Python
06-sayi-tahmin-oyunu.py
omerkocadayi/WeWantEd--Python-a-Giris-
bedde84d0933d05a3a73b894c90c7d04736c3bba
[ "MIT" ]
2
2017-03-26T13:02:42.000Z
2017-04-03T00:50:19.000Z
06-sayi-tahmin-oyunu.py
omerkocadayi/WeWantEd--Python-a-Giris-
bedde84d0933d05a3a73b894c90c7d04736c3bba
[ "MIT" ]
null
null
null
06-sayi-tahmin-oyunu.py
omerkocadayi/WeWantEd--Python-a-Giris-
bedde84d0933d05a3a73b894c90c7d04736c3bba
[ "MIT" ]
null
null
null
import random sayi = random.randint(1,100) print ("Tahmin Oyununa Hos Geldiniz") sayac=0 while True: tahmin = int(input("Sayi Girin:")) sayac += 1 if tahmin == sayi: print ("\nTebrikler {} denemede bildiniz!" .format(sayac)) break elif tahmin < sayi: print ("Daha Buyuk Bir...
20.473684
66
0.604113
0
0
0
0
0
0
0
0
131
0.336761
4716e8dc731b778858ae5d8316051f6d4d545541
47
py
Python
src/zope/hookable/tests/__init__.py
prakritichauhan07/zope.hookable
3c4ae8ddc9c4a2819e4e8e0c4e23394daebb7669
[ "ZPL-2.1" ]
4
2021-02-20T06:00:01.000Z
2022-01-07T20:37:37.000Z
src/zope/hookable/tests/__init__.py
prakritichauhan07/zope.hookable
3c4ae8ddc9c4a2819e4e8e0c4e23394daebb7669
[ "ZPL-2.1" ]
2
2020-04-30T13:03:09.000Z
2021-05-05T10:20:15.000Z
src/zope/hookable/tests/__init__.py
prakritichauhan07/zope.hookable
3c4ae8ddc9c4a2819e4e8e0c4e23394daebb7669
[ "ZPL-2.1" ]
5
2020-05-07T08:14:36.000Z
2022-03-24T15:15:08.000Z
# This line required to prevent an empty file.
23.5
46
0.765957
0
0
0
0
0
0
0
0
46
0.978723
47170ca3654fffbe8da2a35f88340beab3b11a2b
3,333
py
Python
osm/parser.py
ChenZhongPu/osmRoad
5c4ce5e7476b6f35c2917efa835c4f1a0f308ebf
[ "MIT" ]
1
2019-05-02T21:33:05.000Z
2019-05-02T21:33:05.000Z
osm/parser.py
ChenZhongPu/osmRoad
5c4ce5e7476b6f35c2917efa835c4f1a0f308ebf
[ "MIT" ]
1
2019-05-02T22:55:43.000Z
2019-05-02T22:55:43.000Z
osm/parser.py
ChenZhongPu/osmRoad
5c4ce5e7476b6f35c2917efa835c4f1a0f308ebf
[ "MIT" ]
3
2019-05-02T22:37:42.000Z
2021-04-24T05:59:32.000Z
# -------------------------------------------------------------------- # The osmRoad is # # Copyright (c) 2018 by Zhongpu Chen (chenloveit@gmail.com) # # By obtaining, using, and/or copying this software and/or its # associated documentation, you agree that you have read, understood, # and will comply with the followin...
35.457447
94
0.643264
0
0
0
0
0
0
0
0
1,824
0.547255
4718c7e9cd589624b9835b0bd07e75e39f735f11
8,319
py
Python
cs-restaurant/input/devel/expand.py
stg880631/tgen
67db94bf3bfc851e673e50b84230ed9f533b2c23
[ "Apache-2.0" ]
null
null
null
cs-restaurant/input/devel/expand.py
stg880631/tgen
67db94bf3bfc851e673e50b84230ed9f533b2c23
[ "Apache-2.0" ]
null
null
null
cs-restaurant/input/devel/expand.py
stg880631/tgen
67db94bf3bfc851e673e50b84230ed9f533b2c23
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- from __future__ import unicode_literals import re import sys import codecs from argparse import ArgumentParser from util import load_dais, load_texts, write_das, write_texts, write_toks, DAI import kenlm import numpy as np from delexicalize import Delexicalizer from tgen.l...
40.383495
121
0.60464
6,549
0.787139
0
0
0
0
0
0
1,488
0.178846
471b858095fda906a1b28e6ede6d239359d69d10
532
py
Python
app/blueprints/bot_blueprint.py
jattoabdul/andela-genie-backend
62f49a3783a3dbf21f92449e83ca5c941053a690
[ "MIT" ]
null
null
null
app/blueprints/bot_blueprint.py
jattoabdul/andela-genie-backend
62f49a3783a3dbf21f92449e83ca5c941053a690
[ "MIT" ]
null
null
null
app/blueprints/bot_blueprint.py
jattoabdul/andela-genie-backend
62f49a3783a3dbf21f92449e83ca5c941053a690
[ "MIT" ]
null
null
null
from app.blueprints.base_blueprint import Blueprint, BaseBlueprint, request, Security, Auth from app.controllers.bot_controller import BotController url_prefix = '{}/bot'.format(BaseBlueprint.base_url_prefix) bot_blueprint = Blueprint('bot', __name__, url_prefix=url_prefix) bot_controller = BotController(request) @b...
31.294118
91
0.780075
0
0
0
0
210
0.394737
0
0
54
0.101504
471b8e5515166730fbb412862998cac37508651d
394
py
Python
ckanext/__init__.py
keitaroinc/ckanext-visualize
eb53fd00b6a99efd9d8924543ec3bb22774ec083
[ "MIT" ]
13
2019-10-29T22:50:42.000Z
2021-12-13T09:31:33.000Z
ckanext/__init__.py
keitaroinc/ckanext-visualize
eb53fd00b6a99efd9d8924543ec3bb22774ec083
[ "MIT" ]
10
2019-11-04T00:01:09.000Z
2021-04-23T10:59:04.000Z
ckanext/__init__.py
keitaroinc/ckanext-visualize
eb53fd00b6a99efd9d8924543ec3bb22774ec083
[ "MIT" ]
6
2020-02-17T15:29:29.000Z
2021-04-01T15:55:00.000Z
# encoding: utf-8 """ Copyright (c) 2019 Keitaro AB Use of this source code is governed by an MIT license that can be found in the LICENSE file or at https://opensource.org/licenses/MIT. """ # this is a namespace package try: import pkg_resources pkg_resources.declare_namespace(__name__) except ImportError: ...
21.888889
54
0.751269
0
0
0
0
0
0
0
0
219
0.555838
471ba427f7183a39af603bd2c7e5e3442783239a
3,908
py
Python
rpi-config/scripts/arduinoMotor.py
DiamondLightSource/rpi-config
617f5e176c0621e3ea1b567e9586e96ba0f8b5db
[ "Apache-2.0" ]
4
2016-08-23T12:13:21.000Z
2018-08-22T12:55:55.000Z
rpi-config/scripts/arduinoMotor.py
DiamondLightSource/rpi-config
617f5e176c0621e3ea1b567e9586e96ba0f8b5db
[ "Apache-2.0" ]
null
null
null
rpi-config/scripts/arduinoMotor.py
DiamondLightSource/rpi-config
617f5e176c0621e3ea1b567e9586e96ba0f8b5db
[ "Apache-2.0" ]
2
2016-09-15T19:17:30.000Z
2018-03-06T06:34:13.000Z
from gda.device.scannable import PseudoDevice from arduinoScannable import arduinoScannable import time from org.slf4j import LoggerFactory logger = LoggerFactory.getLogger(__name__ + '.py') class arduinoMotor(PseudoDevice): def __init__(self, name, stepsPerRotation, motorPin1, motorPin2, motorPin3, motorPin4): ...
39.877551
91
0.575486
3,715
0.950614
0
0
0
0
0
0
242
0.061924
471d1b188d910549e91d819995fe38aa8ba0edcd
809
py
Python
Tests/ChoreStartTime.py
lapstue/tm1py
a71886b0f96a3e270d5a39ef999e45b413ba4232
[ "MIT" ]
null
null
null
Tests/ChoreStartTime.py
lapstue/tm1py
a71886b0f96a3e270d5a39ef999e45b413ba4232
[ "MIT" ]
null
null
null
Tests/ChoreStartTime.py
lapstue/tm1py
a71886b0f96a3e270d5a39ef999e45b413ba4232
[ "MIT" ]
null
null
null
import unittest from TM1py import ChoreStartTime class TestChoreStartTime(unittest.TestCase): def test_start_time_string_happy_case(self): chore_start_time = ChoreStartTime(year=2020, month=11, day=26, hour=10, minute=11, second=2) self.assertEqual(chore_start_time.start_time_string, "2020-11-26...
42.578947
100
0.757726
756
0.934487
0
0
0
0
0
0
60
0.074166
471e1e651b0efcca16a531bc8067e597b5c516f6
2,986
py
Python
polling_stations/apps/data_collection/management/commands/import_torbay.py
alexsdutton/UK-Polling-Stations
01ec234fd4a832694870d5ed9de069a228397f53
[ "BSD-3-Clause" ]
null
null
null
polling_stations/apps/data_collection/management/commands/import_torbay.py
alexsdutton/UK-Polling-Stations
01ec234fd4a832694870d5ed9de069a228397f53
[ "BSD-3-Clause" ]
null
null
null
polling_stations/apps/data_collection/management/commands/import_torbay.py
alexsdutton/UK-Polling-Stations
01ec234fd4a832694870d5ed9de069a228397f53
[ "BSD-3-Clause" ]
null
null
null
from data_collection.management.commands import BaseXpressDemocracyClubCsvImporter class Command(BaseXpressDemocracyClubCsvImporter): council_id = "E06000027" addresses_name = "local.2019-05-02/Version 1/Democracy_Club__02May2019tor.tsv" stations_name = "local.2019-05-02/Version 1/Democracy_Club__02May201...
50.610169
100
0.630944
2,900
0.971199
0
0
0
0
0
0
1,762
0.590087
471f52f2f33824650411aa0f802cfadb11f387c5
179
py
Python
des050.py
LeonardoPereirajr/Curso_em_video_Python
9d8a97ba3389c8e86b37dfd089fab5d04adc146d
[ "MIT" ]
null
null
null
des050.py
LeonardoPereirajr/Curso_em_video_Python
9d8a97ba3389c8e86b37dfd089fab5d04adc146d
[ "MIT" ]
null
null
null
des050.py
LeonardoPereirajr/Curso_em_video_Python
9d8a97ba3389c8e86b37dfd089fab5d04adc146d
[ "MIT" ]
null
null
null
soma = 0 for c in range(0,6): c = int(input('Digite um numero : ')) if c%2==1 : soma = soma+c print(' A soma dos impares dara {}'.format(soma)) print('FIM ')
25.571429
50
0.541899
0
0
0
0
0
0
0
0
56
0.312849
47215d1dcdc8fe290f39a9541fde0fa54188307f
6,325
py
Python
scenic/projects/vivit/configs/epic_kitchens/vivit_large_factorised_encoder.py
NielsRogge/scenic
4418bf4c6954fffe61d9bafc802981baa9440e49
[ "Apache-2.0" ]
1
2022-02-17T18:48:43.000Z
2022-02-17T18:48:43.000Z
scenic/projects/vivit/configs/epic_kitchens/vivit_large_factorised_encoder.py
NielsRogge/scenic
4418bf4c6954fffe61d9bafc802981baa9440e49
[ "Apache-2.0" ]
null
null
null
scenic/projects/vivit/configs/epic_kitchens/vivit_large_factorised_encoder.py
NielsRogge/scenic
4418bf4c6954fffe61d9bafc802981baa9440e49
[ "Apache-2.0" ]
null
null
null
r"""ViViT Factorised Encoder model for Epic Kitchens. """ from absl import logging import ml_collections EPIC_TRAIN_SIZE = 67217 EPIC_VALID_SIZE = 9668 def get_config(): """Returns the base experiment configuration.""" config = ml_collections.ConfigDict() config.experiment_name = 'vivit_large_factorised_enc...
39.53125
129
0.784348
0
0
0
0
0
0
0
0
1,471
0.232569
472180e30875c4ac8339f38fa4c6fde5ae82de74
376
py
Python
nlp100/12.py
walkingmask/expr4-dm-2016
b62d4c9d57ea8e4efe044fc98e4bdc365e87666d
[ "MIT" ]
null
null
null
nlp100/12.py
walkingmask/expr4-dm-2016
b62d4c9d57ea8e4efe044fc98e4bdc365e87666d
[ "MIT" ]
null
null
null
nlp100/12.py
walkingmask/expr4-dm-2016
b62d4c9d57ea8e4efe044fc98e4bdc365e87666d
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # 12.py # 2016/10/11(火) # walkingmask # check # cut -f1 hightemp.txt # cut -f2 hightemp.txt col1f = open('col1.txt', 'w') col2f = open('col2.txt', 'w') for line in open('hightemp.txt', 'r'): raw = line.rstrip().replace("\t"," ").split(" ") col1f.write(raw[0]+"\n") ...
17.090909
50
0.590426
0
0
0
0
0
0
0
0
194
0.513228
47223575ffe3dacf450a360bb6f35695e71e393c
1,115
py
Python
libnd4j/include/graph/generated/nd4j/graph/DataType.py
nutonchain/Deeplearning
20f222c1eff95205c6c9c9b666b04402405e4442
[ "Apache-2.0" ]
1
2018-08-29T05:46:54.000Z
2018-08-29T05:46:54.000Z
libnd4j/include/graph/generated/nd4j/graph/DataType.py
nutonchain/Deeplearning
20f222c1eff95205c6c9c9b666b04402405e4442
[ "Apache-2.0" ]
null
null
null
libnd4j/include/graph/generated/nd4j/graph/DataType.py
nutonchain/Deeplearning
20f222c1eff95205c6c9c9b666b04402405e4442
[ "Apache-2.0" ]
1
2020-12-13T22:26:47.000Z
2020-12-13T22:26:47.000Z
################################################################################ # Copyright (c) 2015-2018 Skymind, Inc. # # This program and the accompanying materials are made available under the # terms of the Apache License, Version 2.0 which is available at # https://www.apache.org/licenses/LICENSE-2.0. # # Unless...
27.875
80
0.591031
273
0.244843
0
0
0
0
0
0
820
0.735426
47226c18564ce8f55f4fdb06c8ed33bfda9ac9a4
1,026
py
Python
tests/test_app.py
Habbie/stockbot
648e70604828d0ed762c243b4eb83122fd393b4d
[ "Apache-2.0" ]
null
null
null
tests/test_app.py
Habbie/stockbot
648e70604828d0ed762c243b4eb83122fd393b4d
[ "Apache-2.0" ]
16
2017-10-12T09:10:28.000Z
2021-05-20T20:30:15.000Z
tests/test_app.py
Habbie/stockbot
648e70604828d0ed762c243b4eb83122fd393b4d
[ "Apache-2.0" ]
1
2021-06-18T18:23:36.000Z
2021-06-18T18:23:36.000Z
import unittest import datetime from app import ScheduleHandler class TestScheduleHandler(unittest.TestCase): def test_timer(self): class PartialIrcBot(ScheduleHandler): pass t = PartialIrcBot() df = "%d/%m/%Y %H:%M:%S" for d in [9, 10, 11, 12, 13]: d_s...
31.090909
87
0.517544
958
0.933723
0
0
0
0
0
0
81
0.078947
47232224564cdd8a5caa75cbc4ac2385651ab18d
96
py
Python
venv/lib/python3.8/site-packages/cachecontrol/serialize.py
Retraces/UkraineBot
3d5d7f8aaa58fa0cb8b98733b8808e5dfbdb8b71
[ "MIT" ]
2
2022-03-13T01:58:52.000Z
2022-03-31T06:07:54.000Z
venv/lib/python3.8/site-packages/cachecontrol/serialize.py
DesmoSearch/Desmobot
b70b45df3485351f471080deb5c785c4bc5c4beb
[ "MIT" ]
19
2021-11-20T04:09:18.000Z
2022-03-23T15:05:55.000Z
venv/lib/python3.8/site-packages/cachecontrol/serialize.py
DesmoSearch/Desmobot
b70b45df3485351f471080deb5c785c4bc5c4beb
[ "MIT" ]
null
null
null
/home/runner/.cache/pip/pool/97/d1/9c/0ee9b4b39bafa05abf8cf04999afafcd584adf4911ee4f06c64e772d34
96
96
0.895833
0
0
0
0
0
0
0
0
0
0
47240275a74da00053f650b9e1be9d450a7288f2
6,150
py
Python
aiida_quantumespresso/cli/utils/validate.py
lin-cp/aiida-quantumespresso
55f2bc8c137a69be24709a119bc285c700997907
[ "MIT" ]
null
null
null
aiida_quantumespresso/cli/utils/validate.py
lin-cp/aiida-quantumespresso
55f2bc8c137a69be24709a119bc285c700997907
[ "MIT" ]
null
null
null
aiida_quantumespresso/cli/utils/validate.py
lin-cp/aiida-quantumespresso
55f2bc8c137a69be24709a119bc285c700997907
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """Utility functions for validation of command line interface parameter inputs.""" from aiida.cmdline.utils import decorators from aiida.common import exceptions import click @decorators.with_dbenv() def validate_kpoints_mesh(ctx, param, value): """Command line option validator for a kpoin...
39.423077
120
0.696585
0
0
0
0
3,647
0.593008
0
0
3,233
0.525691
47243b3e8295742da8d317aaf12c06c679cc0aca
972
py
Python
tests/trac/test-trac-0058.py
thorstenb/pyxb
634e86f61dfb73a2900f32fc3d819e9c25365a49
[ "Apache-2.0" ]
null
null
null
tests/trac/test-trac-0058.py
thorstenb/pyxb
634e86f61dfb73a2900f32fc3d819e9c25365a49
[ "Apache-2.0" ]
null
null
null
tests/trac/test-trac-0058.py
thorstenb/pyxb
634e86f61dfb73a2900f32fc3d819e9c25365a49
[ "Apache-2.0" ]
null
null
null
import pyxb.binding.generate import pyxb.binding.datatypes as xs import pyxb.binding.basis import pyxb.utils.domutils import os.path xsd=''' <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"> <xs:element name="iopt" nillable="true" type="xs:integer"/> </xs:schema> ''' #file('schema.xsd', 'w').write(xsd) code =...
27
98
0.696502
407
0.418724
0
0
0
0
0
0
325
0.334362
472541c1fb45432416447fbd232a3ef995de7235
35
py
Python
cstool/input_data/__init__.py
Nebula-simulator/cstool
4d8a6434fa0d05287876f656842257fbd5d196bd
[ "BSD-3-Clause" ]
null
null
null
cstool/input_data/__init__.py
Nebula-simulator/cstool
4d8a6434fa0d05287876f656842257fbd5d196bd
[ "BSD-3-Clause" ]
2
2021-08-05T12:36:13.000Z
2022-02-05T15:51:39.000Z
cstool/input_data/__init__.py
Nebula-simulator/cstool
4d8a6434fa0d05287876f656842257fbd5d196bd
[ "BSD-3-Clause" ]
1
2021-08-06T09:20:43.000Z
2021-08-06T09:20:43.000Z
from .param_file import param_file
17.5
34
0.857143
0
0
0
0
0
0
0
0
0
0
4725bdc2094e9f435b0639c37370a8daffc3e956
2,197
py
Python
src/Utils/Trade.py
andrebask/TradingMate
1b07c70cb6d911201c6983942353b3d70f1fc479
[ "MIT" ]
null
null
null
src/Utils/Trade.py
andrebask/TradingMate
1b07c70cb6d911201c6983942353b3d70f1fc479
[ "MIT" ]
null
null
null
src/Utils/Trade.py
andrebask/TradingMate
1b07c70cb6d911201c6983942353b3d70f1fc479
[ "MIT" ]
null
null
null
from enum import Enum import os import sys import inspect import logging import datetime currentdir = os.path.dirname(os.path.abspath( inspect.getfile(inspect.currentframe()))) parentdir = os.path.dirname(currentdir) sys.path.insert(0, parentdir) from Utils.Utils import Actions class Trade(): def __init__(s...
34.873016
171
0.578971
1,909
0.868912
0
0
451
0.20528
0
0
247
0.112426
472734dfa2d0143ee41b2ebd5310df9144aa63b2
497
py
Python
scorebot/players.py
cloudlinux/scorebot
e2a105a605e17bcdeee8493efaa66b29c434ca80
[ "MIT" ]
3
2017-06-15T17:42:20.000Z
2021-04-04T14:11:21.000Z
scorebot/players.py
cloudlinux/scorebot
e2a105a605e17bcdeee8493efaa66b29c434ca80
[ "MIT" ]
null
null
null
scorebot/players.py
cloudlinux/scorebot
e2a105a605e17bcdeee8493efaa66b29c434ca80
[ "MIT" ]
2
2017-02-14T08:05:25.000Z
2017-03-11T08:26:35.000Z
from collections import namedtuple from config.config import CONF PlayerInfo = namedtuple('PlayerInfo', ['team', 'slack_name']) class PlayerNotFound(Exception): def __init__(self, player): msg = "Player '{}' cannot be found in player-to-team " \ "mapping.".format(player) super(Playe...
26.157895
64
0.672032
219
0.440644
0
0
0
0
0
0
97
0.195171
4727ec432d8a9e9863602a7ee35cae1cb0d9b01d
1,862
py
Python
getHostsPerf.py
yungbyr/jri-spb
63b69ef7e842419d8346930b982b385224308a88
[ "Beerware" ]
null
null
null
getHostsPerf.py
yungbyr/jri-spb
63b69ef7e842419d8346930b982b385224308a88
[ "Beerware" ]
null
null
null
getHostsPerf.py
yungbyr/jri-spb
63b69ef7e842419d8346930b982b385224308a88
[ "Beerware" ]
null
null
null
#!/bin/env python import os import sys from XenServer import XenServer from GELF import GELF import traceback try: xs_session = XenServer().make_session() pool = xs_session.xenapi.pool.get_all()[0] pool_uuid = xs_session.xenapi.pool.get_uuid(pool) hosts = xs_session.xenapi.host.get_all() for ho...
32.103448
80
0.529538
0
0
0
0
0
0
0
0
322
0.172932
472b0a2f2e9b3fe1b62227a85d0dd389ed036ca6
18,590
py
Python
elm/elmr.py
ShubhamDiwan/elm
bf33f2498551fba3b2fd42d982feb0d22c031a71
[ "BSD-3-Clause" ]
84
2015-03-08T07:39:47.000Z
2022-03-06T03:41:23.000Z
elm/elmr.py
ShubhamDiwan/elm
bf33f2498551fba3b2fd42d982feb0d22c031a71
[ "BSD-3-Clause" ]
11
2015-09-10T04:01:26.000Z
2021-06-01T23:04:46.000Z
elm/elmr.py
ShubhamDiwan/elm
bf33f2498551fba3b2fd42d982feb0d22c031a71
[ "BSD-3-Clause" ]
70
2015-03-30T10:20:14.000Z
2022-03-06T03:41:24.000Z
# -*- coding: utf-8 -*- """ This file contains ELMKernel classes and all developed methods. """ # Python2 support from __future__ import unicode_literals from __future__ import division from __future__ import absolute_import from __future__ import print_function from .mltools import * import numpy as np import ...
35.75
83
0.537063
17,876
0.961592
0
0
383
0.020602
0
0
8,158
0.438838
472d943521309da5bdb5ecbc1180c718f5245c0f
1,561
py
Python
ctapipe/image/concentration.py
nbiederbeck/ctapipe
cdd2fe5205bd2747d2846cfc751c51868b4a0bdd
[ "BSD-3-Clause" ]
null
null
null
ctapipe/image/concentration.py
nbiederbeck/ctapipe
cdd2fe5205bd2747d2846cfc751c51868b4a0bdd
[ "BSD-3-Clause" ]
null
null
null
ctapipe/image/concentration.py
nbiederbeck/ctapipe
cdd2fe5205bd2747d2846cfc751c51868b4a0bdd
[ "BSD-3-Clause" ]
null
null
null
import numpy as np import astropy.units as u from ..instrument import CameraGeometry from ..containers import ConcentrationContainer from .hillas import camera_to_shower_coordinates from ..utils.quantities import all_to_value __all__ = ["concentration_parameters"] def concentration_parameters(geom: CameraGeometry, ...
30.607843
88
0.679052
0
0
0
0
0
0
0
0
351
0.224856
472df55e17729fcc47b160990f5f92d48d797df5
5,647
py
Python
config/settings.py
jochenklar/django-project
ae46a6bdaf7a7711a3862009754c27f953d5f8eb
[ "MIT" ]
null
null
null
config/settings.py
jochenklar/django-project
ae46a6bdaf7a7711a3862009754c27f953d5f8eb
[ "MIT" ]
null
null
null
config/settings.py
jochenklar/django-project
ae46a6bdaf7a7711a3862009754c27f953d5f8eb
[ "MIT" ]
null
null
null
import os from pathlib import Path import dj_database_url from django.utils.translation import gettext_lazy as _ BASE_DIR = Path(__file__).resolve().parent.parent SECRET_KEY = os.getenv('SECRET_KEY') DEBUG = (os.getenv('DEBUG', 'False').upper() == 'TRUE') DEBUG_TOOLBAR = (os.getenv('DEBUG_TOOLBAR', 'False').upper...
28.376884
79
0.556933
0
0
0
0
0
0
0
0
2,710
0.479901
472f5b894c74ee5cb53c8c6e4af3b516896e2691
2,682
py
Python
pyethapp/console_service.py
heikoheiko/pyethapp
17a560abe8f8742bf5e30fa8f7e5495faf3cb101
[ "BSD-3-Clause" ]
48
2015-12-23T14:38:14.000Z
2022-01-19T06:01:57.000Z
pyethapp/console_service.py
WEI-HE/pyethapp
17a560abe8f8742bf5e30fa8f7e5495faf3cb101
[ "BSD-3-Clause" ]
2
2016-05-08T02:27:47.000Z
2017-03-06T23:37:47.000Z
pyethapp/console_service.py
WEI-HE/pyethapp
17a560abe8f8742bf5e30fa8f7e5495faf3cb101
[ "BSD-3-Clause" ]
27
2015-04-05T05:26:14.000Z
2022-02-05T16:43:20.000Z
""" Essential parts borrowed from https://github.com/ipython/ipython/pull/1654 """ import signal from devp2p.service import BaseService import gevent from gevent.event import Event import IPython import IPython.core.shellapp from IPython.lib.inputhook import inputhook_manager, stdin_ready from ethereum import slogging ...
27.9375
84
0.637211
2,072
0.772558
0
0
960
0.357942
0
0
987
0.368009
472fb90bf8e9c1984e67a20df2a05e17dc5e6ff0
670
py
Python
adventure/migrations/0008_auto_20160320_2237.py
matthew-macgregor/eamon
e59d14e790fd8e95f5f1a91d1965f549c2b673ba
[ "MIT" ]
22
2016-03-22T07:28:42.000Z
2022-02-12T16:03:17.000Z
adventure/migrations/0008_auto_20160320_2237.py
matthew-macgregor/eamon
e59d14e790fd8e95f5f1a91d1965f549c2b673ba
[ "MIT" ]
103
2017-04-14T23:19:19.000Z
2022-01-27T03:05:36.000Z
adventure/migrations/0008_auto_20160320_2237.py
matthew-macgregor/eamon
e59d14e790fd8e95f5f1a91d1965f549c2b673ba
[ "MIT" ]
7
2019-04-09T16:12:10.000Z
2021-12-15T17:09:32.000Z
# -*- coding: utf-8 -*- # Generated by Django 1.9.2 on 2016-03-21 05:37 from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('adventure', '0007_auto_20160306_0055'), ] operations = [ migrations.RenameFi...
25.769231
127
0.604478
513
0.765672
0
0
0
0
0
0
217
0.323881
472fc2f3d672c86f9759f9ac2c9539102d5e1b0b
175
py
Python
src/metrics/__init__.py
Alicegaz/torchok
7b8f95df466a25b1ad8ee93bed1a3c7516440cf4
[ "Apache-2.0" ]
8
2021-10-12T05:39:20.000Z
2022-03-31T10:55:01.000Z
src/metrics/__init__.py
Alicegaz/torchok
7b8f95df466a25b1ad8ee93bed1a3c7516440cf4
[ "Apache-2.0" ]
1
2022-03-30T19:23:42.000Z
2022-03-30T19:23:42.000Z
src/metrics/__init__.py
Alicegaz/torchok
7b8f95df466a25b1ad8ee93bed1a3c7516440cf4
[ "Apache-2.0" ]
5
2021-11-17T07:38:28.000Z
2022-01-31T10:46:36.000Z
from .common import * from .classification import * from .segmentation import * from .verification import * from .retrieval import * from .metric_manager import MetricManager
25
41
0.8
0
0
0
0
0
0
0
0
0
0
4731fabfe155fe4caec4fa4a58fe927e97e941d4
4,935
py
Python
custom_components/magicstrip/light.py
elahd/ha-magicstrip
f33aeafc4a313d8674591e44c0d1d9c11c91e9cd
[ "MIT" ]
null
null
null
custom_components/magicstrip/light.py
elahd/ha-magicstrip
f33aeafc4a313d8674591e44c0d1d9c11c91e9cd
[ "MIT" ]
null
null
null
custom_components/magicstrip/light.py
elahd/ha-magicstrip
f33aeafc4a313d8674591e44c0d1d9c11c91e9cd
[ "MIT" ]
null
null
null
"""MagicStrip light implementation.""" from __future__ import annotations import logging from typing import Any, MutableMapping from homeassistant.components.light import ( ATTR_BRIGHTNESS, ATTR_EFFECT, ATTR_RGB_COLOR, COLOR_MODE_RGB, SUPPORT_BRIGHTNESS, SUPPORT_COLOR, SUPPORT_EFFECT, ...
32.9
119
0.674772
3,353
0.679433
0
0
910
0.184397
1,736
0.351773
665
0.134752
5b259cabbea070c2cb0e3c57684d6e4cf99916c1
1,069
py
Python
src/advanced_plot/vertical_bar.py
ikedaosushi/advanced-plot
8a2ef3f0fc7921cdfe990fdf1e2044af664dc7b0
[ "MIT" ]
null
null
null
src/advanced_plot/vertical_bar.py
ikedaosushi/advanced-plot
8a2ef3f0fc7921cdfe990fdf1e2044af664dc7b0
[ "MIT" ]
null
null
null
src/advanced_plot/vertical_bar.py
ikedaosushi/advanced-plot
8a2ef3f0fc7921cdfe990fdf1e2044af664dc7b0
[ "MIT" ]
null
null
null
import matplotlib.pyplot as plt import pandas as pd import seaborn as sns def vertical_bar(data: pd.DataFrame, label: str, value: str, ax=None, ratio=True, fontsize=14): if ax is None: n = data.shape[0] fig = plt.figure(figsize=(16, 1 * n)) ax = fig.add_subplot(1, 1, 1) labels = getatt...
32.393939
95
0.614593
0
0
0
0
0
0
0
0
99
0.09261
5b26a2989cc751d061fee5e02533b62c0199aa67
1,407
py
Python
matrix/spiralOrder.py
nishantml/100-days-of-code
fdbd7f8d195363467ab462bd4f0774a34379a769
[ "MIT" ]
1
2021-03-20T12:23:31.000Z
2021-03-20T12:23:31.000Z
matrix/spiralOrder.py
nishantml/100-days-of-code
fdbd7f8d195363467ab462bd4f0774a34379a769
[ "MIT" ]
null
null
null
matrix/spiralOrder.py
nishantml/100-days-of-code
fdbd7f8d195363467ab462bd4f0774a34379a769
[ "MIT" ]
null
null
null
""" Given an m x n matrix, return all elements of the matrix in spiral order. Example 1: Input: matrix = [[1,2,3],[4,5,6],[7,8,9]] Output: [1,2,3,6,9,8,7,4,5] Example 2: Input: matrix = [[1,2,3,4],[5,6,7,8],[9,10,11,12]] Output: [1,2,3,4,8,12,11,10,9,5,6,7] Constraints: m == matrix.length n == matrix[i].len...
22.693548
73
0.471215
1,006
0.714996
0
0
0
0
0
0
402
0.285714
5b2c78d7a80a1e068c05e2fcdde3201711ae2bcd
2,161
py
Python
telegram_ecommerce/database/db_wrapper.py
Anonylions/telegram_ecommerce
f5382886bbebf607c735e2f451774c56df8d6011
[ "MIT" ]
10
2020-11-20T20:55:52.000Z
2022-02-10T20:25:45.000Z
telegram_ecommerce/database/db_wrapper.py
Anonylions/telegram_ecommerce
f5382886bbebf607c735e2f451774c56df8d6011
[ "MIT" ]
1
2022-02-16T10:28:18.000Z
2022-02-16T10:35:31.000Z
telegram_ecommerce/database/db_wrapper.py
Anonylions/telegram_ecommerce
f5382886bbebf607c735e2f451774c56df8d6011
[ "MIT" ]
8
2021-05-01T01:13:09.000Z
2022-03-13T14:00:01.000Z
import mysql.connector as connector from ..utils.utils import get_sql_commands_from_a_file from ..utils.consts import db_credentials from ..utils.log import logger class DBWrapper(): def __init__(self, db_credentials): self.database_name = "telegram_ecommerce" self.connection = connector.connect...
29.202703
76
0.661731
1,894
0.876446
0
0
0
0
0
0
162
0.074965
5b2da810c7adee849036ab5f31a31b82ac508c08
5,346
py
Python
src/addnn/node/proto/neural_network_pb2.py
MatthiasJReisinger/addnn
1d68648e81faf478cfb1f7d9a3f944a014fa3867
[ "MIT" ]
4
2022-01-25T23:09:24.000Z
2022-03-30T20:57:18.000Z
src/addnn/node/proto/neural_network_pb2.py
MatthiasJReisinger/addnn
1d68648e81faf478cfb1f7d9a3f944a014fa3867
[ "MIT" ]
null
null
null
src/addnn/node/proto/neural_network_pb2.py
MatthiasJReisinger/addnn
1d68648e81faf478cfb1f7d9a3f944a014fa3867
[ "MIT" ]
1
2022-01-25T23:08:50.000Z
2022-01-25T23:08:50.000Z
# -*- coding: utf-8 -*- # Generated by the protocol buffer compiler. DO NOT EDIT! # source: addnn/node/proto/neural_network.proto """Generated protocol buffer code.""" from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf import reflection as _reflec...
35.403974
467
0.770857
0
0
0
0
0
0
0
0
1,616
0.302282
5b2dd18e1ecfbb5e9df7c4c7ce61b73c2c764de6
5,334
py
Python
satsense/extract.py
fossabot/satsense
6666dd01a6988a86319c71a8f8802bf4b096c550
[ "Apache-2.0" ]
22
2018-03-14T10:29:38.000Z
2022-03-29T10:54:51.000Z
satsense/extract.py
fdbesanto2/satsense
b0fa650193995a30328f26a36ebab2437c0e37ef
[ "Apache-2.0" ]
49
2018-05-25T13:28:07.000Z
2021-07-31T09:48:02.000Z
satsense/extract.py
fdbesanto2/satsense
b0fa650193995a30328f26a36ebab2437c0e37ef
[ "Apache-2.0" ]
11
2018-04-24T08:55:28.000Z
2021-02-17T22:32:05.000Z
"""Module for computing features.""" import logging from concurrent.futures import ProcessPoolExecutor from functools import partial from itertools import groupby from os import cpu_count from typing import Iterator import numpy as np from .features import Feature from .generators import FullGenerator from .image imp...
34.412903
79
0.630484
0
0
3,745
0.7021
0
0
0
0
2,586
0.484814
5b2e595b9f19bfb2e8967ee33be2a32475c6a58f
2,319
py
Python
main.py
lbellomo/mafalda_bot
a2037d266d3c7ba2129b65686d05c9611fd10c61
[ "MIT" ]
1
2021-02-20T16:33:37.000Z
2021-02-20T16:33:37.000Z
main.py
lbellomo/mafalda_bot
a2037d266d3c7ba2129b65686d05c9611fd10c61
[ "MIT" ]
null
null
null
main.py
lbellomo/mafalda_bot
a2037d266d3c7ba2129b65686d05c9611fd10c61
[ "MIT" ]
null
null
null
import os import sys import time from pathlib import Path from random import choice from codecs import decode from base64 import b64decode import tweepy max_errors_count = 5 CONSUMER_KEY = os.environ["CONSUMER_KEY"] CONSUMER_SECRET = os.environ["CONSUMER_SECRET"] ACCESS_TOKEN = os.environ["ACCESS_TOKEN"] ACCESS_TOKE...
24.670213
129
0.598103
0
0
0
0
0
0
0
0
470
0.202499
5b2f1506a9908854c576dc2669ef2013acbe7667
1,787
py
Python
steelpy/f2uModel/load/sqlite/main.py
svortega/steelpy
bef35eb8ab8728fc29f57b7070b5f3bac0b0e840
[ "MIT" ]
4
2021-09-28T12:52:01.000Z
2022-02-24T22:30:22.000Z
steelpy/f2uModel/load/sqlite/main.py
svortega/steelpy
bef35eb8ab8728fc29f57b7070b5f3bac0b0e840
[ "MIT" ]
null
null
null
steelpy/f2uModel/load/sqlite/main.py
svortega/steelpy
bef35eb8ab8728fc29f57b7070b5f3bac0b0e840
[ "MIT" ]
null
null
null
# # Copyright (c) 2009-2021 fem2ufo # # Python stdlib imports #from typing import NamedTuple, Dict, List, Iterable, Union # package imports from steelpy.f2uModel.load.sqlite.basic_load import BasicLoadSQL from steelpy.f2uModel.load.sqlite.combination import LoadCombSQL from steelpy.f2uModel.results.sqlite.operation....
29.783333
97
0.588137
1,406
0.786794
0
0
174
0.09737
0
0
878
0.491326
5b2f83d5cd93c073ad130cc113bab25a1d03255b
423
py
Python
wrap/pybind11/pybind11/__init__.py
xxiao-1/gtsam
8b1516f43ffdf6b5098fc282b566f2ee1edb50f6
[ "BSD-3-Clause" ]
84
2020-09-07T01:38:44.000Z
2022-03-31T16:05:11.000Z
wrap/pybind11/pybind11/__init__.py
xxiao-1/gtsam
8b1516f43ffdf6b5098fc282b566f2ee1edb50f6
[ "BSD-3-Clause" ]
39
2016-11-25T22:14:09.000Z
2022-01-13T21:44:51.000Z
wrap/pybind11/pybind11/__init__.py
xxiao-1/gtsam
8b1516f43ffdf6b5098fc282b566f2ee1edb50f6
[ "BSD-3-Clause" ]
22
2018-07-12T06:16:57.000Z
2022-01-15T03:38:51.000Z
# -*- coding: utf-8 -*- from ._version import version_info, __version__ # noqa: F401 imported but unused def get_include(user=False): import os d = os.path.dirname(__file__) if os.path.exists(os.path.join(d, "include")): # Package is installed return os.path.join(d, "include") else: ...
30.214286
81
0.64539
0
0
0
0
0
0
0
0
140
0.330969
5b2ff50acd81015198f76d11e3cd2e26119bee9b
990
py
Python
templates/event-source.py
mediatemple/ReC2
c4074050cad99ddc7b0190cbbc278e0d37c361c7
[ "MIT" ]
3
2016-12-17T02:19:36.000Z
2017-03-20T05:22:37.000Z
templates/event-source.py
mediatemple/ReC2
c4074050cad99ddc7b0190cbbc278e0d37c361c7
[ "MIT" ]
null
null
null
templates/event-source.py
mediatemple/ReC2
c4074050cad99ddc7b0190cbbc278e0d37c361c7
[ "MIT" ]
2
2016-07-29T22:40:11.000Z
2019-09-09T17:46:29.000Z
#!/usr/bin/env python from troposphere import Template, Output, GetAtt, Parameter, Ref, events, awslambda t = Template() lambda_arn = t.add_parameter(Parameter( 'LambdaArn', Type='String', Description='Lambda Arn' )) rule = t.add_resource( events.Rule( "ReC2Rule", Targets=[events.Tar...
20.204082
83
0.588889
0
0
0
0
0
0
0
0
224
0.226263
5b305aaea3f5ffab82ca7d9b11d0a932e9ea8b70
3,716
py
Python
errorguimonitor/report_retriever.py
imalkevich/errorguimonitor
73280bd81027949a11e3facd60a2fb41c2c4a1d1
[ "MIT" ]
null
null
null
errorguimonitor/report_retriever.py
imalkevich/errorguimonitor
73280bd81027949a11e3facd60a2fb41c2c4a1d1
[ "MIT" ]
null
null
null
errorguimonitor/report_retriever.py
imalkevich/errorguimonitor
73280bd81027949a11e3facd60a2fb41c2c4a1d1
[ "MIT" ]
null
null
null
#!/usr/bin/env python """ Report retriever module. Grab HTML from the url provided. """ import random import requests from urllib.parse import quote as url_quote from pyquery import PyQuery as pq USER_AGENTS = ('Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:11.0) Gecko/20100101 Firefox/11.0', 'Mo...
39.531915
134
0.640743
1,953
0.525565
0
0
0
0
0
0
1,622
0.436491
5b30d2a47cc806b49df80d10546f31a2ce91bf14
20,347
py
Python
h3/tree.py
rajatkapoor/pyh3
874b6aa94d61cd13b2d8e9232b1cc5971fc193f3
[ "MIT" ]
61
2015-08-11T00:44:58.000Z
2022-02-10T12:14:01.000Z
h3/tree.py
rajatkapoor/pyh3
874b6aa94d61cd13b2d8e9232b1cc5971fc193f3
[ "MIT" ]
3
2016-02-26T17:27:19.000Z
2016-08-12T03:04:12.000Z
h3/tree.py
rajatkapoor/pyh3
874b6aa94d61cd13b2d8e9232b1cc5971fc193f3
[ "MIT" ]
17
2015-08-10T20:32:55.000Z
2019-03-13T19:33:21.000Z
import logging import math from collections import deque from node import Node from operator import itemgetter from h3math import compute_radius, compute_hyperbolic_area, compute_delta_phi, compute_delta_theta import mpl_toolkits.mplot3d.art3d as art3d from matplotlib.patches import Circle import matplotlib.pyplot as ...
48.101655
120
0.57291
19,816
0.973903
1,131
0.055586
0
0
0
0
5,961
0.292967
5b317e57461183461d3c250ff021fc4851ed0c97
744
py
Python
researchutils/image/converter.py
yuishihara/researchutils
bb3ec467386d43a1e2282ec6d024216ce4dae841
[ "MIT" ]
1
2018-09-06T00:54:49.000Z
2018-09-06T00:54:49.000Z
researchutils/image/converter.py
yuishihara/researchutils
bb3ec467386d43a1e2282ec6d024216ce4dae841
[ "MIT" ]
28
2018-08-25T03:54:30.000Z
2018-10-14T12:09:47.000Z
researchutils/image/converter.py
yuishihara/researchutils
bb3ec467386d43a1e2282ec6d024216ce4dae841
[ "MIT" ]
null
null
null
def hwc2chw(image): """ Changes the order of image pixels from Height-Width-Color to Color-Height-Width Parameters ------- image : numpy.ndarray Image with pixels in Height-Width-Color order Returns ------- image : numpy.ndarray Image with pixels in Color-Height-Width o...
22.545455
83
0.620968
0
0
0
0
0
0
0
0
616
0.827957
5b31f0b330141ac44d0ebd212cbd8605bcb60314
1,530
py
Python
utils/plot_results.py
miniautonomous/trainer_ai
953b6c22b65e249a9d7595d15c78c24c12bc254e
[ "MIT" ]
1
2021-06-23T22:32:53.000Z
2021-06-23T22:32:53.000Z
utils/plot_results.py
miniautonomous/trainer_ai
953b6c22b65e249a9d7595d15c78c24c12bc254e
[ "MIT" ]
null
null
null
utils/plot_results.py
miniautonomous/trainer_ai
953b6c22b65e249a9d7595d15c78c24c12bc254e
[ "MIT" ]
null
null
null
import matplotlib.pyplot as plt def plot_results(model_name: str, history, history_keys: list, training_dictionary:dict): """ Plot the results of a simulation. Parameters ---------- model_name: (str) model name history: (tf history) result of a Keras model fit history_keys: (list) lis...
36.428571
89
0.66732
0
0
0
0
0
0
0
0
487
0.318301
5b3441a35ce26d50d34036f034d95f41123e550e
3,564
py
Python
003-longest-substring-without-repeating-characters.py
mvj3/leetcode
3111199beeaefbb3a74173e783ed21c9e53ab203
[ "MIT" ]
null
null
null
003-longest-substring-without-repeating-characters.py
mvj3/leetcode
3111199beeaefbb3a74173e783ed21c9e53ab203
[ "MIT" ]
null
null
null
003-longest-substring-without-repeating-characters.py
mvj3/leetcode
3111199beeaefbb3a74173e783ed21c9e53ab203
[ "MIT" ]
null
null
null
""" Question: Longest Substring Without Repeating Characters Given a string, find the length of the longest substring without repeating characters. For example, the longest substring without repeating letters for "abcabcbb" is "abc", which the length is 3. For "bbbbb" the longest substring is "b", with the len...
34.601942
263
0.614478
2,351
0.659652
0
0
0
0
0
0
1,146
0.321549
5b34aa1af56249ef97f4b6fdf0c203875ab7d112
1,971
py
Python
abel/tests/test_basex.py
Derollez/PyAbel
c8be4ed7e8e08ee026634b9e856fb473e58d7330
[ "MIT" ]
null
null
null
abel/tests/test_basex.py
Derollez/PyAbel
c8be4ed7e8e08ee026634b9e856fb473e58d7330
[ "MIT" ]
null
null
null
abel/tests/test_basex.py
Derollez/PyAbel
c8be4ed7e8e08ee026634b9e856fb473e58d7330
[ "MIT" ]
null
null
null
from __future__ import absolute_import from __future__ import division from __future__ import print_function import os.path import numpy as np from numpy.testing import assert_allclose import abel DATA_DIR = os.path.join(os.path.split(__file__)[0], 'data') def test_basex_basis_sets_cache(): # n_vert, n_horz =...
27.760563
93
0.690005
0
0
0
0
0
0
0
0
238
0.120751
5b3a8027dd21491237d65a61527430d014ff49a1
23,554
py
Python
shogi-main1.py
GudSirSnek/GameOfShogi
3961cdcba68561de9eb98d96dcc50df498cc9fcc
[ "Apache-2.0" ]
null
null
null
shogi-main1.py
GudSirSnek/GameOfShogi
3961cdcba68561de9eb98d96dcc50df498cc9fcc
[ "Apache-2.0" ]
null
null
null
shogi-main1.py
GudSirSnek/GameOfShogi
3961cdcba68561de9eb98d96dcc50df498cc9fcc
[ "Apache-2.0" ]
null
null
null
#main class handles user input and current gameState class import pygame as p import shogiEngine1 import os import copy import Piece import Menu height = 1057 #defines the board resolution width = 1920 sq_size = 66 x_offset = 459 y_offset = 243 scale = 1 p.font.init() myfont = p.font.SysFont('Comi...
43.537893
263
0.484164
0
0
0
0
0
0
0
0
3,175
0.134797
5b3cf373d640df91c859693048fae4d02399c861
2,848
py
Python
mqtt/mqtt.py
luchosr/dht11Streams
f51922257c4aa4703556f546e43cf3a3219d203f
[ "Apache-2.0" ]
1
2020-10-11T03:04:48.000Z
2020-10-11T03:04:48.000Z
mqtt/mqtt.py
luchosr/dht11Streams
f51922257c4aa4703556f546e43cf3a3219d203f
[ "Apache-2.0" ]
null
null
null
mqtt/mqtt.py
luchosr/dht11Streams
f51922257c4aa4703556f546e43cf3a3219d203f
[ "Apache-2.0" ]
1
2020-10-11T11:48:21.000Z
2020-10-11T11:48:21.000Z
from sense_hat import SenseHat #from collections import OrderedDict import paho.mqtt.client as mqttClient import time import config import json sense=SenseHat() sense.clear() def on_connect(client, userdata, flags, rc): if rc == 0: print("Connected to MQTT Broker") global Connected ...
27.921569
159
0.554424
0
0
0
0
0
0
0
0
704
0.247191
5b44f8f617dbbc8726355dc4049488c47d0b36f7
1,315
py
Python
ai_covid_19/utils/utils.py
nestauk/ai_covid_19
4367b1c7a110094f090167dbe02a1c47ce27e0e9
[ "MIT" ]
null
null
null
ai_covid_19/utils/utils.py
nestauk/ai_covid_19
4367b1c7a110094f090167dbe02a1c47ce27e0e9
[ "MIT" ]
14
2020-06-12T12:02:29.000Z
2020-06-28T12:45:14.000Z
ai_covid_19/utils/utils.py
nestauk/ai_covid_19
4367b1c7a110094f090167dbe02a1c47ce27e0e9
[ "MIT" ]
null
null
null
import numpy as np import re import random from toolz.curried import * def preview(df): '''Previews a dataframe Args: x (df) a dataframe ''' print(df.head()) return df def convert_var(var,lookup): return(var.map(lookup)) def convert_covid(var): out = convert_var(var,{True:'C...
23.482143
85
0.612167
0
0
0
0
0
0
0
0
253
0.192395
5b4664424009b5bcedec6cac5e139fe193b9a090
6,777
py
Python
train_bayes_nn.py
afcarl/Fall2017_Individual_Study
620dbeaa557105a7444fa01e6d78e4e59c646eac
[ "MIT" ]
1
2019-04-22T16:42:09.000Z
2019-04-22T16:42:09.000Z
train_bayes_nn.py
afcarl/Fall2017_Individual_Study
620dbeaa557105a7444fa01e6d78e4e59c646eac
[ "MIT" ]
null
null
null
train_bayes_nn.py
afcarl/Fall2017_Individual_Study
620dbeaa557105a7444fa01e6d78e4e59c646eac
[ "MIT" ]
null
null
null
import os from os.path import join as pjoin import cPickle as cp import numpy as np import tensorflow as tf from sklearn.metrics import accuracy_score from models.bnn import BNN # command line arguments flags = tf.flags flags.DEFINE_integer("batchSize", 128, "batch size.") flags.DEFINE_integer("nEpochs", 1500, "numb...
42.892405
231
0.645418
0
0
0
0
0
0
0
0
1,858
0.274163
5b4943551755f3bba451eb447ce7bcc2219f2a29
234
py
Python
webapp/build.py
DavidGeisel/machine-learning-lab
2d7a9ecae3780a5ecfe323e55b5d555ac41ce261
[ "Apache-2.0" ]
null
null
null
webapp/build.py
DavidGeisel/machine-learning-lab
2d7a9ecae3780a5ecfe323e55b5d555ac41ce261
[ "Apache-2.0" ]
null
null
null
webapp/build.py
DavidGeisel/machine-learning-lab
2d7a9ecae3780a5ecfe323e55b5d555ac41ce261
[ "Apache-2.0" ]
null
null
null
""" Build ML Lab React Webapp """ import os import subprocess import argparse # Wrapper to print out command def call(command): print("Executing: "+command) return subprocess.call(command, shell=True) call("npm run setup")
15.6
47
0.722222
0
0
0
0
0
0
0
0
91
0.388889
5b4adf85d7a1a04cebb1c8771aa76f2f5d18e037
505
py
Python
others/levenshtein.py
Mifour/Algorithms
77cfafc49bc0130da0f6041b169a15053f81af87
[ "MIT" ]
null
null
null
others/levenshtein.py
Mifour/Algorithms
77cfafc49bc0130da0f6041b169a15053f81af87
[ "MIT" ]
null
null
null
others/levenshtein.py
Mifour/Algorithms
77cfafc49bc0130da0f6041b169a15053f81af87
[ "MIT" ]
null
null
null
import numpy as np def levenshtein(first, second): """ O(nm) time & space for word of n and m characters """ n = len(first) m = len(second) matrix = np.array([np.arange(m)+i+1 for i in range(n)]) for i in range(1, n): for j in range(1, m): matrix[i,j] = min( matrix[i-1, j] +1, matrix[i, j-1] +1...
21.956522
56
0.592079
0
0
0
0
0
0
0
0
110
0.217822
5b4ffb37f9d334eb6f038c45f439a859439c4bcf
308
py
Python
algorithms/0001-FizzBuzz/fizzbuzz.py
ivamluz/Algorithms-and-Data-Structures
cffacd758adf134dabc63cdc107c8b485b00b1c1
[ "Apache-2.0" ]
1
2018-11-06T22:43:07.000Z
2018-11-06T22:43:07.000Z
algorithms/0001-FizzBuzz/fizzbuzz.py
ivamluz/Algorithms-and-Data-Structures
cffacd758adf134dabc63cdc107c8b485b00b1c1
[ "Apache-2.0" ]
null
null
null
algorithms/0001-FizzBuzz/fizzbuzz.py
ivamluz/Algorithms-and-Data-Structures
cffacd758adf134dabc63cdc107c8b485b00b1c1
[ "Apache-2.0" ]
null
null
null
def fizzbuzz(number): if number <= 0: return None is_multiple_of_3 = (number % 3 == 0) is_multiple_of_5 = (number % 5 == 0) if is_multiple_of_3 and is_multiple_of_5: return "FizzBuzz" if is_multiple_of_3: return "Fizz" if is_multiple_of_5: return "Buzz" return str(number)
17.111111
43
0.668831
0
0
0
0
0
0
0
0
22
0.071429
5b51125a1a090c9fc8cb4d27953bb17cb0175781
159
py
Python
ex005.py
juniorpedroso/Exercicios-CEV-Python
4adad3b6f3994cf61f9ead5564124b8b9c58d304
[ "MIT" ]
null
null
null
ex005.py
juniorpedroso/Exercicios-CEV-Python
4adad3b6f3994cf61f9ead5564124b8b9c58d304
[ "MIT" ]
null
null
null
ex005.py
juniorpedroso/Exercicios-CEV-Python
4adad3b6f3994cf61f9ead5564124b8b9c58d304
[ "MIT" ]
null
null
null
n = int(input('Digite um número: ')) #prox = n + 1 #ant = n -1 print ('Analizando o valor {}, seu antecessor é {} e o sucessor é {}.'.format(n, (n-1), (n+1)))
31.8
95
0.572327
0
0
0
0
0
0
0
0
110
0.679012
5b52819344cdd9b254cb63f54c8459751f763cd8
2,781
py
Python
dp_conceptual_search/ons/search/queries/ons_query_builders.py
flaxandteal/dp-conceptual-search
16c6383a61ba5b7069337c2626a0dc243bfe9d35
[ "MIT" ]
3
2018-05-10T16:49:27.000Z
2022-03-29T15:23:04.000Z
dp_conceptual_search/ons/search/queries/ons_query_builders.py
flaxandteal/dp-conceptual-search
16c6383a61ba5b7069337c2626a0dc243bfe9d35
[ "MIT" ]
2
2018-09-20T06:37:27.000Z
2018-11-12T12:05:08.000Z
dp_conceptual_search/ons/search/queries/ons_query_builders.py
flaxandteal/dp-conceptual-search
16c6383a61ba5b7069337c2626a0dc243bfe9d35
[ "MIT" ]
3
2018-06-25T10:48:43.000Z
2021-04-11T08:01:27.000Z
""" Defines a series of useful Elasticsearch queries for the ONS """ from typing import List from elasticsearch_dsl import query as Q from elasticsearch_dsl.aggs import A as Aggregation from dp_conceptual_search.ons.search.fields import AvailableFields from dp_conceptual_search.ons.search.content_type import ContentT...
36.116883
144
0.667026
0
0
0
0
0
0
0
0
641
0.230493
5b574f2296ecb2d56b23821c1097178c52787f98
1,486
py
Python
02_crowsnest/crowsnest.py
leszekgrechowicz/tiny_python_projects
792c21a9a56c1dbe35d1aa1d4959c030a7921acd
[ "MIT" ]
null
null
null
02_crowsnest/crowsnest.py
leszekgrechowicz/tiny_python_projects
792c21a9a56c1dbe35d1aa1d4959c030a7921acd
[ "MIT" ]
null
null
null
02_crowsnest/crowsnest.py
leszekgrechowicz/tiny_python_projects
792c21a9a56c1dbe35d1aa1d4959c030a7921acd
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 """ Author : Leszek Grechowicz <leszek_grechowicz@o2.pl> Date : 2021-06-13 Purpose: Choose the correct article """ import argparse # -------------------------------------------------- def get_args(): """Get command-line arguments""" parser = argparse.ArgumentParser( descript...
25.62069
75
0.514132
0
0
0
0
0
0
0
0
710
0.47651
5b59e0a9cb3bd76343fae397453413bc3b371849
68
py
Python
sublime-plugin/poli/sublime/__init__.py
egnartsms/poli
3a9eab2261688ed84b83808722360356b8e67522
[ "MIT" ]
1
2020-06-07T20:55:27.000Z
2020-06-07T20:55:27.000Z
sublime-plugin/poli/sublime/__init__.py
egnartsms/poli
3a9eab2261688ed84b83808722360356b8e67522
[ "MIT" ]
2
2021-01-22T08:45:48.000Z
2021-01-22T08:45:49.000Z
sublime-plugin/poli/sublime/__init__.py
egnartsms/poli
3a9eab2261688ed84b83808722360356b8e67522
[ "MIT" ]
null
null
null
from .edit import * from .regedit import * from .view_dict import *
17
24
0.735294
0
0
0
0
0
0
0
0
0
0
5b59e6ee04f97441e3d69e0a51c1f84e9553c272
4,233
py
Python
acl18/layers.py
tzshi/mh4-parser-acl18
20234703d6a2824fb6f76d45499db0a6ec6e27fb
[ "MIT" ]
4
2018-08-22T13:54:38.000Z
2021-05-16T16:22:36.000Z
acl18/layers.py
tzshi/mh4-parser-acl18
20234703d6a2824fb6f76d45499db0a6ec6e27fb
[ "MIT" ]
null
null
null
acl18/layers.py
tzshi/mh4-parser-acl18
20234703d6a2824fb6f76d45499db0a6ec6e27fb
[ "MIT" ]
1
2019-05-19T16:59:20.000Z
2019-05-19T16:59:20.000Z
#!/usr/bin/env python # encoding: utf-8 from dynet import parameter, transpose, dropout, rectify from dynet import layer_norm, affine_transform from dynet import concatenate, zeroes, dot_product from dynet import GlorotInitializer, ConstInitializer, SaxeInitializer import math class Dense(object): def __init__(...
29.601399
110
0.613749
3,906
0.92275
0
0
552
0.130404
0
0
38
0.008977
5b5aa95c7ad2759e3e5ddaf4a2bed48b5f164af1
222
py
Python
palindrome_number.py
I8PI/Blueberry
4b21fa170614cc15810e5aff6e8f6c0520ade078
[ "MIT" ]
1
2020-02-27T09:41:33.000Z
2020-02-27T09:41:33.000Z
palindrome_number.py
I8PI/Blueberry
4b21fa170614cc15810e5aff6e8f6c0520ade078
[ "MIT" ]
null
null
null
palindrome_number.py
I8PI/Blueberry
4b21fa170614cc15810e5aff6e8f6c0520ade078
[ "MIT" ]
null
null
null
n=int(input("enter the number: ")) temp=n rev=0 while n>0: dig=n%10 rev=rev*10+dig n=n//10 if temp==rev: print ("number is a palindrome", sep='a') else: print("number is not a palindrome")
17.076923
46
0.576577
0
0
0
0
0
0
0
0
75
0.337838
5b5ae9e5749ec7396c079711e82dc60783ccf32d
6,449
py
Python
interpreter-server/buzzcommander.py
Anglia-Ruskin-IoT-Labs/avs-device-sdk
68d4446b3ecbb81cab73d7701ec909f5f3603316
[ "Apache-2.0" ]
null
null
null
interpreter-server/buzzcommander.py
Anglia-Ruskin-IoT-Labs/avs-device-sdk
68d4446b3ecbb81cab73d7701ec909f5f3603316
[ "Apache-2.0" ]
null
null
null
interpreter-server/buzzcommander.py
Anglia-Ruskin-IoT-Labs/avs-device-sdk
68d4446b3ecbb81cab73d7701ec909f5f3603316
[ "Apache-2.0" ]
1
2018-08-22T14:35:08.000Z
2018-08-22T14:35:08.000Z
#!/usr/bin/python3 import socket # used for TCP/IP communication import smtplib # used to send email report import time # used to insert current date in email report import threading class Buzzbox(): # Constructor, saving constants def main(self, _ip: str, _port: int, _light: int, _led: int): self.BUZZ...
27.917749
86
0.609862
6,252
0.969453
0
0
0
0
0
0
1,640
0.254303
5b5b5de9cc4bb46f2ff5bbbe7a01860b9bf18703
17,997
py
Python
pointcloud_diff/scripts/PointCloudDiff.py
565353780/pytorch-voxblox-plus-plus
fd319495b36651cf8c0c9244e0f664fac1afd5ca
[ "BSD-3-Clause" ]
null
null
null
pointcloud_diff/scripts/PointCloudDiff.py
565353780/pytorch-voxblox-plus-plus
fd319495b36651cf8c0c9244e0f664fac1afd5ca
[ "BSD-3-Clause" ]
null
null
null
pointcloud_diff/scripts/PointCloudDiff.py
565353780/pytorch-voxblox-plus-plus
fd319495b36651cf8c0c9244e0f664fac1afd5ca
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- import os import numpy as np import open3d as o3d from time import time, sleep import rospy from sensor_msgs.point_cloud2 import read_points from vpp_msgs.srv import GetMap from tensorboard_logger_ros.msg import Scalar from tensorboard_logger_ros.srv import ScalarToBool ...
40.902273
97
0.64483
17,124
0.951492
0
0
0
0
0
0
1,982
0.110129
5b5bca6fb329af46502ecd4b3cff5294fef66f40
1,314
py
Python
tests/pup/sensors/color_color.py
cschlack/pybricks-micropython
0abfd2918267a4e6e7a04062976ac1bb3da1f4b1
[ "MIT" ]
115
2020-06-15T16:43:14.000Z
2022-03-21T21:11:57.000Z
tests/pup/sensors/color_color.py
cschlack/pybricks-micropython
0abfd2918267a4e6e7a04062976ac1bb3da1f4b1
[ "MIT" ]
83
2020-06-17T17:19:29.000Z
2022-03-08T18:50:35.000Z
tests/pup/sensors/color_color.py
BertLindeman/pybricks-micropython
8f22a99551100e66ddf08d014d9f442f22b33b4d
[ "MIT" ]
40
2020-06-15T18:36:39.000Z
2022-03-28T13:22:43.000Z
# SPDX-License-Identifier: MIT # Copyright (c) 2020 The Pybricks Authors """ Hardware Module: 1 Description: Verifies color sensing and calibration capability. """ from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor from pybricks.parameters import Port, Color # Initialize devices. motor = Motor(Por...
26.816327
92
0.702435
0
0
0
0
0
0
0
0
467
0.355403
5b5c888bbb8125ae3ac660dfc5ba639abf84f105
3,406
py
Python
software/firmware/data_dump.py
lab11/polypoint
0a21b19db7d00c0b0d9b523a54a6b243a5e64bac
[ "Apache-2.0" ]
132
2015-05-16T10:19:15.000Z
2022-03-17T22:11:49.000Z
software/module/firmware/data_dump.py
pinsonc/totternary
b938123bec8264927984740f7b435ab0b9ebdbd8
[ "Apache-2.0" ]
14
2015-05-27T07:55:43.000Z
2018-06-27T22:57:47.000Z
software/module/firmware/data_dump.py
pinsonc/totternary
b938123bec8264927984740f7b435ab0b9ebdbd8
[ "Apache-2.0" ]
56
2015-06-27T09:51:13.000Z
2022-01-22T17:02:42.000Z
#!/usr/bin/env python3 import argparse import binascii import os import struct import sys import serial import numpy as np import scipy.io as sio parser = argparse.ArgumentParser() parser.add_argument('-s', '--serial', default='/dev/tty.usbserial-AL00EZAS') parser.add_argument('-b', '--baudrate', default=3000000,...
24.328571
79
0.66882
0
0
0
0
0
0
0
0
1,004
0.294774
5b5d9409fdb39d2207c6932a117449e41deba2c3
15,427
py
Python
percolation/text/ks.py
ttm/percolate
cfdf5380c8d155424ab97bdab85edde8b6f0ec9f
[ "MIT" ]
1
2020-06-11T01:34:25.000Z
2020-06-11T01:34:25.000Z
percolation/text/ks.py
ttm/percolate
cfdf5380c8d155424ab97bdab85edde8b6f0ec9f
[ "MIT" ]
null
null
null
percolation/text/ks.py
ttm/percolate
cfdf5380c8d155424ab97bdab85edde8b6f0ec9f
[ "MIT" ]
null
null
null
__doc__="routines for selected Kolmogorov-Smirnov related statistics on text analysis" import numbers def ksComparisons(sectors_analysis): multigroup_measures=[] isnot_numeric_measures=[] detached_measures=[] ks_measures=P.utils.nestedDict() for measure_domain in sectors_analysis["peripherals"]: ...
82.497326
251
0.652168
0
0
0
0
0
0
0
0
2,566
0.166332
5b5f3d38d66083adf3fa27d5150cb13f0c26d96e
4,642
py
Python
venv/Lib/site-packages/pyshorteners/base.py
arturj9/encurtar-link
2e5bfdd2b2525f10f41942c79cb45cc4e43a24ee
[ "MIT" ]
null
null
null
venv/Lib/site-packages/pyshorteners/base.py
arturj9/encurtar-link
2e5bfdd2b2525f10f41942c79cb45cc4e43a24ee
[ "MIT" ]
null
null
null
venv/Lib/site-packages/pyshorteners/base.py
arturj9/encurtar-link
2e5bfdd2b2525f10f41942c79cb45cc4e43a24ee
[ "MIT" ]
null
null
null
import requests import re from .exceptions import BadURLException, ExpandingErrorException URL_RE = re.compile( r"(?i)\b((?:https?://|www\d{0,3}[.]|[a-z0-9.\-]+[.]" r"[a-z]{2,4}/)(?:[^\s()<>]+|\(([^\s()<>]+|(\([^\s()<>]+\)" r"))*\))+(?:\(([^\s()<>]+|(\([^\s()<>]+\)))*\)|[^\s`!()" r'\[\]{};:\'".,<>?«»“...
29.948387
122
0.554718
4,309
0.926268
0
0
397
0.08534
0
0
3,020
0.649183
5b5fb3612eed2c2c094b3078cd58aaf1ac0191cc
3,937
py
Python
walletUI/wallet/views.py
avinashshenoy97/brownie-points
27eb1e9a5ab685e72a5b701c0f76af44d9700960
[ "MIT" ]
1
2020-11-25T12:14:40.000Z
2020-11-25T12:14:40.000Z
walletUI/wallet/views.py
avinashshenoy97/brownie-points
27eb1e9a5ab685e72a5b701c0f76af44d9700960
[ "MIT" ]
null
null
null
walletUI/wallet/views.py
avinashshenoy97/brownie-points
27eb1e9a5ab685e72a5b701c0f76af44d9700960
[ "MIT" ]
null
null
null
from django.shortcuts import render from rest_framework import status from rest_framework.views import APIView from rest_framework.response import Response import requests import os,sys,inspect currentdir = os.path.dirname(os.path.abspath(inspect.getfile(inspect.currentframe()))) parentdir = os.path.dirname(currentdi...
40.173469
236
0.712217
3,429
0.870968
0
0
0
0
0
0
1,012
0.257049
5b62f118e2ffc9dd673f3068d8b01e2b12d22cc7
1,362
py
Python
tests/test_template.py
furbrain/CVExplorer
1283e3320ef7bb610b1044543614dd1b96740e52
[ "MIT" ]
null
null
null
tests/test_template.py
furbrain/CVExplorer
1283e3320ef7bb610b1044543614dd1b96740e52
[ "MIT" ]
null
null
null
tests/test_template.py
furbrain/CVExplorer
1283e3320ef7bb610b1044543614dd1b96740e52
[ "MIT" ]
null
null
null
from unittest import TestCase import os.path import cv2 from lxml import html from functions import ParameterTemplate from functions.template import FunctionTemplate FIXTURES_FILTER_HTML = "/usr/share/doc/opencv-doc/opencv4/html/d4/d86/group__imgproc__filter.html" FIXTURES_FRAGMENT_HTML = os.path.join(os.path.dirname...
32.428571
98
0.65859
993
0.729075
0
0
302
0.221733
0
0
183
0.134361
5b6372f2718a1820477d44a40467e6e54ef84811
3,662
py
Python
Eric/day3.py
efacks68/codingjuntos_advent2020
1d7ef6278616716ad62a5f3af3fa0419173b6dc1
[ "MIT" ]
1
2020-12-02T20:16:16.000Z
2020-12-02T20:16:16.000Z
Eric/day3.py
efacks68/codingjuntos_advent2020
1d7ef6278616716ad62a5f3af3fa0419173b6dc1
[ "MIT" ]
null
null
null
Eric/day3.py
efacks68/codingjuntos_advent2020
1d7ef6278616716ad62a5f3af3fa0419173b6dc1
[ "MIT" ]
null
null
null
#Day3: Toboggan Trajectory #Part1: Starting in Top-Left Corner, follow a slope of Right 3 and Down 1. f=open("input_day3.txt") lines=f.readlines() #read in each line f.close() #print("lines\n",lines) length=0 mnt=[] for row in lines: mnt.append(str(row)) #move into new list for easier manipulation length=leng...
19.902174
95
0.534134
0
0
0
0
0
0
0
0
2,577
0.703714
5b65b745e1b964b05f2af0b1c1dc9c88bdbc1879
235
py
Python
equipment_slots.py
BTmathic/game-template
77765b1340e51828cc9216b4239f558c251859ce
[ "MIT" ]
1
2019-09-01T20:15:52.000Z
2019-09-01T20:15:52.000Z
equipment_slots.py
BTmathic/game-template
77765b1340e51828cc9216b4239f558c251859ce
[ "MIT" ]
null
null
null
equipment_slots.py
BTmathic/game-template
77765b1340e51828cc9216b4239f558c251859ce
[ "MIT" ]
null
null
null
from enum import auto, Enum class EquipmentSlots(Enum): MAIN_HAND = auto() OFF_HAND = auto() HEAD = auto() BODY = auto() LEGS = auto() BOOTS = auto() L_RING = auto() R_RING = auto() CLOAK = auto()
16.785714
27
0.561702
204
0.868085
0
0
0
0
0
0
0
0
5b661a4cf2786a6eea1f2601c3dbb8569290c20d
1,130
py
Python
alembic/versions/452902fab185_added_auth_related_f.py
go-lab/appcomposer
c2468f11b8398edc9b16e1552ac8d609d8347677
[ "BSD-2-Clause" ]
1
2018-01-20T14:56:01.000Z
2018-01-20T14:56:01.000Z
alembic/versions/452902fab185_added_auth_related_f.py
go-lab/appcomposer
c2468f11b8398edc9b16e1552ac8d609d8347677
[ "BSD-2-Clause" ]
25
2015-01-21T09:16:26.000Z
2021-12-13T20:01:21.000Z
alembic/versions/452902fab185_added_auth_related_f.py
go-lab/appcomposer
c2468f11b8398edc9b16e1552ac8d609d8347677
[ "BSD-2-Clause" ]
3
2015-07-28T18:40:05.000Z
2017-03-28T08:14:37.000Z
"""Added auth-related fields to User Revision ID: 452902fab185 Revises: 501404b36cef Create Date: 2013-09-24 12:42:04.461000 """ # revision identifiers, used by Alembic. revision = '452902fab185' down_revision = '501404b36cef' from alembic import op import sqlalchemy as sa def upgrade(): ### ...
1,130
1,130
0.678761
0
0
0
0
0
0
0
0
1,126
0.99646
5b67bc4f2ecf30bc3a0aaebd74c2275fbbb3a19f
129
py
Python
POO/ex04/main.py
isachlopes/Python_Orientado_Objetos
d3b79eff0585cca0786e4c99d0c79d01ef515e61
[ "MIT" ]
null
null
null
POO/ex04/main.py
isachlopes/Python_Orientado_Objetos
d3b79eff0585cca0786e4c99d0c79d01ef515e61
[ "MIT" ]
null
null
null
POO/ex04/main.py
isachlopes/Python_Orientado_Objetos
d3b79eff0585cca0786e4c99d0c79d01ef515e61
[ "MIT" ]
null
null
null
class A: vc = 234 def __init__(self): vc = 456 a = A() b = A() a.vc = 432 print(a.vc) print(b.vc) print(A.vc)
12.9
23
0.503876
62
0.48062
0
0
0
0
0
0
0
0
5b67f1793b6c11e57fe44b1e696b1c4e3fffbe2b
343
py
Python
core/forms.py
olunx/xTrade
6d9c7651c46d8d53c4a6998b76f372802745c1f0
[ "Apache-2.0" ]
null
null
null
core/forms.py
olunx/xTrade
6d9c7651c46d8d53c4a6998b76f372802745c1f0
[ "Apache-2.0" ]
null
null
null
core/forms.py
olunx/xTrade
6d9c7651c46d8d53c4a6998b76f372802745c1f0
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- __author__ = 'olunx' from django.forms import ModelForm from core.models import ProductItem class ProductItemForm(ModelForm): class Meta: model = ProductItem fields = ['income_url', 'title', 'content', 'images', 'images_checked', 'purchasing_location', 'purchasing_price',...
28.583333
145
0.705539
223
0.650146
0
0
0
0
0
0
142
0.413994
5b6848b8710fcce4dc8ab6725a2afbe088dcdcab
1,200
py
Python
make_cache.py
jdh4/tigergpu_visualization
770697124e6c8e04432db08002107dbd694e233b
[ "CNRI-Python" ]
null
null
null
make_cache.py
jdh4/tigergpu_visualization
770697124e6c8e04432db08002107dbd694e233b
[ "CNRI-Python" ]
null
null
null
make_cache.py
jdh4/tigergpu_visualization
770697124e6c8e04432db08002107dbd694e233b
[ "CNRI-Python" ]
1
2020-05-26T15:13:15.000Z
2020-05-26T15:13:15.000Z
#!/usr/licensed/anaconda3/2020.11/bin/python base = "/home/jdh4/bin/gpus" import sys sys.path = list(filter(lambda p: p.startswith("/usr"), sys.path)) sys.path.append(base) import json import subprocess import pandas as pd from dossier import ldap_plus if 1: rows = [] with open(base + "/utilization.json") as f...
31.578947
75
0.675833
0
0
0
0
0
0
0
0
291
0.2425
5b68dabbc6ef27b5064c767d7bec2e0782be79bd
4,777
py
Python
test_of_inheritance_2.py
JRF-2018/simbd
7a453562331cf5b41187a8c69e18ec3378004dc1
[ "ClArtistic" ]
null
null
null
test_of_inheritance_2.py
JRF-2018/simbd
7a453562331cf5b41187a8c69e18ec3378004dc1
[ "ClArtistic" ]
10
2021-09-05T13:15:50.000Z
2022-02-10T06:48:46.000Z
test_of_inheritance_2.py
JRF-2018/simbd
7a453562331cf5b41187a8c69e18ec3378004dc1
[ "ClArtistic" ]
null
null
null
#!/usr/bin/python3 __version__ = '0.0.3' # Time-stamp: <2021-10-16T01:25:51Z> ## Language: Japanese/UTF-8 """相続のテスト""" ## ## License: ## ## Public Domain ## (Since this small code is close to be mathematically trivial.) ## ## Author: ## ## JRF ## http://jrf.cocolog-nifty.com/software/ ## (Th...
28.777108
78
0.515386
1,042
0.216857
0
0
0
0
0
0
1,082
0.225182
5b6b492e6ec14da57db531db52f34774d727d4cb
8,345
py
Python
detectron/ops/pcl.py
sisrfeng/NA-fWebSOD
49cb75a9a0d557b05968c6b11b0f17a7043f2077
[ "Apache-2.0" ]
23
2020-03-30T11:48:33.000Z
2022-03-11T06:34:31.000Z
detectron/ops/pcl.py
sisrfeng/NA-fWebSOD
49cb75a9a0d557b05968c6b11b0f17a7043f2077
[ "Apache-2.0" ]
9
2020-09-28T07:15:16.000Z
2022-03-25T08:11:06.000Z
detectron/ops/pcl.py
sisrfeng/NA-fWebSOD
49cb75a9a0d557b05968c6b11b0f17a7043f2077
[ "Apache-2.0" ]
10
2020-03-30T11:48:34.000Z
2021-06-02T06:12:36.000Z
import numpy as np from sklearn.cluster import KMeans from detectron.core.config import cfg import detectron.utils.boxes as box_utils try: xrange # Python 2 except NameError: xrange = range # Python 3 cfg_TRAIN_NUM_KMEANS_CLUSTER = 3 cfg_RNG_SEED = 3 cfg_TRAIN_GRAPH_IOU_THRESHOLD = 0.4 cfg_TRAIN_MA...
38.279817
119
0.637987
1,340
0.160575
0
0
0
0
0
0
1,124
0.134691
5b6b52bea6e9b40479b6ac3698397020ea08e793
19,109
py
Python
services/python-images/src/master/resources/distributions.py
hpi-epic/mpcsl
05361acb0c8da68ddfa21f9fc9cd32a59255dc5c
[ "MIT" ]
1
2021-11-21T13:52:36.000Z
2021-11-21T13:52:36.000Z
services/python-images/src/master/resources/distributions.py
hpi-epic/mpcsl
05361acb0c8da68ddfa21f9fc9cd32a59255dc5c
[ "MIT" ]
3
2021-10-06T13:23:43.000Z
2022-01-07T13:48:41.000Z
services/python-images/src/master/resources/distributions.py
hpi-epic/mpcsl
05361acb0c8da68ddfa21f9fc9cd32a59255dc5c
[ "MIT" ]
null
null
null
import numpy as np import pandas as pd from flask_restful import Resource from flask_restful_swagger_2 import swagger from marshmallow import fields, validates, Schema, ValidationError from src.master.helpers.database import get_db_session from src.master.helpers.io import marshal, load_data, InvalidInputData from src...
46.045783
120
0.55466
18,185
0.951646
0
0
16,371
0.856717
0
0
4,577
0.239521
5b6bb41cad09b43e1affc7f6d78a3d1d1f98f54b
567
py
Python
realtors/models.py
TonyKioko/PropertySasa
58182174e2ac3caacf2cc6623d184d165b20c70c
[ "MIT" ]
null
null
null
realtors/models.py
TonyKioko/PropertySasa
58182174e2ac3caacf2cc6623d184d165b20c70c
[ "MIT" ]
null
null
null
realtors/models.py
TonyKioko/PropertySasa
58182174e2ac3caacf2cc6623d184d165b20c70c
[ "MIT" ]
null
null
null
from django.db import models from datetime import datetime # Create your models here class Realtor(models.Model): name = models.CharField(max_length=200) photo = models.ImageField(upload_to='photos/%Y/%m/%d/',blank=True) description = models.TextField(max_length=400,blank=True) phone = models.Positive...
33.352941
70
0.742504
479
0.844797
0
0
0
0
0
0
43
0.075838
5b6d0b9a2cc4d233d101441bb10f47418da9b63d
472
py
Python
cookies/resources/set.py
ziransun/wpt
ab8f451eb39eb198584d547f5d965ef54df2a86a
[ "BSD-3-Clause" ]
8
2019-04-09T21:13:05.000Z
2021-11-23T17:25:18.000Z
cookies/resources/set.py
ziransun/wpt
ab8f451eb39eb198584d547f5d965ef54df2a86a
[ "BSD-3-Clause" ]
21
2021-03-31T19:48:22.000Z
2022-03-12T00:24:53.000Z
cookies/resources/set.py
ziransun/wpt
ab8f451eb39eb198584d547f5d965ef54df2a86a
[ "BSD-3-Clause" ]
11
2019-04-12T01:20:16.000Z
2021-11-23T17:25:02.000Z
import helpers import urllib def main(request, response): """Respond to `/cookie/set?{cookie}` by echoing `{cookie}` as a `Set-Cookie` header.""" headers = helpers.setNoCacheAndCORSHeaders(request, response) # Cookies may require whitespace (e.g. in the `Expires` attribute), so the # query string shou...
33.714286
91
0.699153
0
0
0
0
0
0
0
0
225
0.476695
5b6da9f79d2796f8456fd3c992ddac850201f870
18,233
py
Python
ginga/qtw/plugins/Pick.py
Rbeaty88/ginga
08451a81288b8defc54aa9f9e2af23a9ba32e985
[ "BSD-3-Clause" ]
1
2016-03-21T15:56:15.000Z
2016-03-21T15:56:15.000Z
ginga/qtw/plugins/Pick.py
Rbeaty88/ginga
08451a81288b8defc54aa9f9e2af23a9ba32e985
[ "BSD-3-Clause" ]
null
null
null
ginga/qtw/plugins/Pick.py
Rbeaty88/ginga
08451a81288b8defc54aa9f9e2af23a9ba32e985
[ "BSD-3-Clause" ]
null
null
null
# # Pick.py -- Pick plugin for Ginga fits viewer # # Eric Jeschke (eric@naoj.org) # # Copyright (c) Eric R. Jeschke. All rights reserved. # This is open-source software licensed under a BSD license. # Please see the file LICENSE.txt for details. # from ginga.qtw.QtHelp import QtGui, QtCore from ginga.qtw import QtHel...
34.401887
133
0.577744
17,601
0.965338
0
0
0
0
0
0
3,382
0.185488
5b6e37dbd3c20d60ef9b914f23cdbf88dd577984
208
py
Python
elastic/api/urls.py
deam91/elastic
f5fb20f9afb6669974567fd39e6e261c704d3c54
[ "MIT" ]
null
null
null
elastic/api/urls.py
deam91/elastic
f5fb20f9afb6669974567fd39e6e261c704d3c54
[ "MIT" ]
2
2021-06-09T18:42:49.000Z
2021-06-10T20:40:15.000Z
elastic/api/urls.py
deam91/elastic
f5fb20f9afb6669974567fd39e6e261c704d3c54
[ "MIT" ]
null
null
null
from django.urls import path from elastic.api.views import GoogleView, AppleView urlpatterns = [ path('auth/google/verify/', GoogleView.as_view()), path('auth/apple/verify/', AppleView.as_view()) ]
23.111111
54
0.725962
0
0
0
0
0
0
0
0
41
0.197115
5b6eeef2c71aa760c9baadb4c5a6e2140938fb6a
4,992
py
Python
iqa_common/executor/command_base.py
fgiorgetti/qpid-dispatch-tests
164c609d28db87692eed53d5361aa1ee5c97375c
[ "Apache-2.0" ]
1
2020-12-21T14:06:52.000Z
2020-12-21T14:06:52.000Z
iqa_common/executor/command_base.py
fgiorgetti/qpid-dispatch-tests
164c609d28db87692eed53d5361aa1ee5c97375c
[ "Apache-2.0" ]
6
2018-10-19T17:04:50.000Z
2019-05-20T19:54:40.000Z
iqa_common/executor/command_base.py
fgiorgetti/qpid-dispatch-tests
164c609d28db87692eed53d5361aa1ee5c97375c
[ "Apache-2.0" ]
1
2018-09-19T13:43:35.000Z
2018-09-19T13:43:35.000Z
""" Provides representation for Commands that can be executed against Executor instances. """ class Command(object): """ Represents a command that can be executed against different executors, behaving similarly across them. """ def __init__(self, args: list, stdout: bool=False, stderr: bool=False,...
37.253731
108
0.64984
4,895
0.980569
0
0
119
0.023838
0
0
3,276
0.65625
5b723c49946f52cdac915a09e27adab029ad9a35
715
py
Python
django2/simpleDemo/blog/views.py
Gozeon/code-collections
7304e2b9c4c91a809125198d22cf40dcbb45a23b
[ "MIT" ]
null
null
null
django2/simpleDemo/blog/views.py
Gozeon/code-collections
7304e2b9c4c91a809125198d22cf40dcbb45a23b
[ "MIT" ]
1
2020-07-17T09:25:42.000Z
2020-07-17T09:25:42.000Z
django2/simpleDemo/blog/views.py
Gozeon/code-collections
7304e2b9c4c91a809125198d22cf40dcbb45a23b
[ "MIT" ]
null
null
null
from django.shortcuts import render, redirect from .models import Comment from .forms import CommentForm def index(request): comments = Comment.objects.order_by('-create_at') context = {'comments': comments} return render(request, 'blog/index.html', context) def sign(request): if request.method == '...
28.6
66
0.622378
0
0
0
0
0
0
0
0
89
0.124476
5b72e1c67050eefbe47eb859b61a29f96962f2cb
2,668
py
Python
polls/models.py
vowatchka/fabrique_test_task
a876321c8c3c3197ce692f247af973432ebf84cf
[ "MIT" ]
null
null
null
polls/models.py
vowatchka/fabrique_test_task
a876321c8c3c3197ce692f247af973432ebf84cf
[ "MIT" ]
null
null
null
polls/models.py
vowatchka/fabrique_test_task
a876321c8c3c3197ce692f247af973432ebf84cf
[ "MIT" ]
null
null
null
from django.db import models class Choice(models.Model): """ Модель варианта ответа """ choice_text = models.CharField(max_length=100, verbose_name="Текст варианта ответа") question = models.ForeignKey("Question", on_delete=models.CASCADE, verbose_name="Вопрос") class Meta: verbose_na...
32.144578
133
0.688906
2,998
0.986184
0
0
194
0.063816
0
0
938
0.308553
5b73957f0a22b9435187079c42d5be88539e176e
2,572
py
Python
scripts/create_cluster.py
rnrbarbosa/CDPDCTrial
aecff49971ba35b6ec02d04846c1ff891d8bca45
[ "Apache-2.0" ]
7
2020-08-04T20:09:22.000Z
2022-01-09T05:05:39.000Z
scripts/create_cluster.py
rnrbarbosa/CDPDCTrial
aecff49971ba35b6ec02d04846c1ff891d8bca45
[ "Apache-2.0" ]
1
2020-12-09T13:18:45.000Z
2022-01-08T17:41:39.000Z
scripts/create_cluster.py
rnrbarbosa/CDPDCTrial
aecff49971ba35b6ec02d04846c1ff891d8bca45
[ "Apache-2.0" ]
14
2020-09-03T14:19:10.000Z
2022-02-21T20:03:31.000Z
from __future__ import print_function import cm_client from cm_client.rest import ApiException from collections import namedtuple from pprint import pprint import json import time import sys def wait(cmd, timeout=None): SYNCHRONOUS_COMMAND_ID = -1 if cmd.id == SYNCHRONOUS_COMMAND_ID: return cmd SL...
27.956522
115
0.692846
0
0
0
0
0
0
0
0
431
0.167574
5b73b791ebd04c2f9222a3d5b07d99e182af0ec3
447
py
Python
codefestival_2016_final_b.py
hythof/atc
12cb94ebe693e1f469ce0d982bc2924b586552cd
[ "CC0-1.0" ]
null
null
null
codefestival_2016_final_b.py
hythof/atc
12cb94ebe693e1f469ce0d982bc2924b586552cd
[ "CC0-1.0" ]
null
null
null
codefestival_2016_final_b.py
hythof/atc
12cb94ebe693e1f469ce0d982bc2924b586552cd
[ "CC0-1.0" ]
null
null
null
n=int(input()) def findMax(n): l=0 r=n while r-l>=2: m1=l+(r-l)//2 m2=m1+1 s1=(m1+1)*(m1/2) s2=(m2+1)*(m2/2) if s2 >= n > s1: return m2 elif s1 < n: l=m1 else: r=m1 return 1 def printLines(n,m): for i in rang...
17.88
28
0.373602
0
0
0
0
0
0
0
0
0
0
5b761dac9e8c8e3725ba145eacfb8d3f0a3908ed
4,914
py
Python
srcSim/model_neuronmodels.py
Olimaol/BOLDpaper2021
a5aaa7f69b6938b4c7b46446ce73e2967c08bbf6
[ "MIT" ]
1
2021-11-02T18:55:22.000Z
2021-11-02T18:55:22.000Z
srcSim/model_neuronmodels.py
hamkerlab/Maith2021_ANNarchyBOLDmonitor
e50af332703ee257a0cd8e30437cdfa4f44893aa
[ "MIT" ]
null
null
null
srcSim/model_neuronmodels.py
hamkerlab/Maith2021_ANNarchyBOLDmonitor
e50af332703ee257a0cd8e30437cdfa4f44893aa
[ "MIT" ]
null
null
null
from ANNarchy import * from ANNarchy.extensions.bold.PredefinedModels import balloon_two_inputs from ANNarchy.extensions.bold import BoldModel from parameters import params, rng setup(dt=params['dt']) setup(num_threads=params['num_threads']) setup(seed=params['seed']) Constant('RS_v_r',params['RS_v_r']) Constant('FS_v...
32.328947
132
0.47558
0
0
0
0
0
0
0
0
3,979
0.809727
5b7674325078da66bb522f08c9f888feac4e3166
483
py
Python
test/test_pre_flight.py
gregbanks/atlascli
381966c4a042c3769d14167d5db7b5abb9a7c6e0
[ "Apache-2.0" ]
null
null
null
test/test_pre_flight.py
gregbanks/atlascli
381966c4a042c3769d14167d5db7b5abb9a7c6e0
[ "Apache-2.0" ]
null
null
null
test/test_pre_flight.py
gregbanks/atlascli
381966c4a042c3769d14167d5db7b5abb9a7c6e0
[ "Apache-2.0" ]
null
null
null
import unittest from atlascli.commands import Commands from atlascli.atlasmap import AtlasMap class TestPreFlight(unittest.TestCase): def test_preflight(self): map = AtlasMap() map.authenticate() c = Commands(map) with self.assertRaises(SystemExit) as e: c.preflight_clu...
24.15
48
0.652174
340
0.703934
0
0
0
0
0
0
42
0.086957