hexsha
stringlengths
40
40
size
int64
4
1.02M
ext
stringclasses
8 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
209
max_stars_repo_name
stringlengths
5
121
max_stars_repo_head_hexsha
stringlengths
40
40
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
⌀
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
⌀
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
⌀
max_issues_repo_path
stringlengths
4
209
max_issues_repo_name
stringlengths
5
121
max_issues_repo_head_hexsha
stringlengths
40
40
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
67k
⌀
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
⌀
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
⌀
max_forks_repo_path
stringlengths
4
209
max_forks_repo_name
stringlengths
5
121
max_forks_repo_head_hexsha
stringlengths
40
40
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
⌀
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
⌀
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
⌀
content
stringlengths
4
1.02M
avg_line_length
float64
1.07
66.1k
max_line_length
int64
4
266k
alphanum_fraction
float64
0.01
1
d519e7ab872d6d0e8040581266da93ac46993f8e
305
py
Python
pythran/tests/rosetta/happy_numbers.py
davidbrochart/pythran
24b6c8650fe99791a4091cbdc2c24686e86aa67c
[ "BSD-3-Clause" ]
1,647
2015-01-13T01:45:38.000Z
2022-03-28T01:23:41.000Z
pythran/tests/rosetta/happy_numbers.py
davidbrochart/pythran
24b6c8650fe99791a4091cbdc2c24686e86aa67c
[ "BSD-3-Clause" ]
1,116
2015-01-01T09:52:05.000Z
2022-03-18T21:06:40.000Z
pythran/tests/rosetta/happy_numbers.py
davidbrochart/pythran
24b6c8650fe99791a4091cbdc2c24686e86aa67c
[ "BSD-3-Clause" ]
180
2015-02-12T02:47:28.000Z
2022-03-14T10:28:18.000Z
#from http://rosettacode.org/wiki/Happy_numbers#Python #pythran export happy(int) #runas [x for x in range(500) if happy(x)][:8] def happy(n): past = set() while n != 1: n = sum(int(i)**2 for i in str(n)) if n in past: return False past.add(n) return True
23.461538
54
0.57377
fadad45072e2a5c9252d6930214180fc187f2ef7
2,016
py
Python
docs/src/full_mongodb.py
sondrelg/fastapi-users
058f86717bf3da72da1c45bf19e99ff85c071baa
[ "MIT" ]
1
2021-09-16T22:32:05.000Z
2021-09-16T22:32:05.000Z
docs/src/full_mongodb.py
sondrelg/fastapi-users
058f86717bf3da72da1c45bf19e99ff85c071baa
[ "MIT" ]
9
2021-11-05T13:56:06.000Z
2022-03-07T04:29:57.000Z
docs/src/full_mongodb.py
sondrelg/fastapi-users
058f86717bf3da72da1c45bf19e99ff85c071baa
[ "MIT" ]
null
null
null
import motor.motor_asyncio from fastapi import FastAPI, Request from fastapi_users import FastAPIUsers, models from fastapi_users.authentication import JWTAuthentication from fastapi_users.db import MongoDBUserDatabase DATABASE_URL = "mongodb://localhost:27017" SECRET = "SECRET" class User(models.BaseUser): pass...
24.888889
88
0.748512
a2f2baa9867ee8dbfb9a9c157cd9ea28a077455d
56,964
py
Python
nova/tests/unit/objects/test_objects.py
bopopescu/nova-16
85a26f727d34d3dc3b13ddf6fbf80d7c34fb3206
[ "Apache-2.0" ]
null
null
null
nova/tests/unit/objects/test_objects.py
bopopescu/nova-16
85a26f727d34d3dc3b13ddf6fbf80d7c34fb3206
[ "Apache-2.0" ]
null
null
null
nova/tests/unit/objects/test_objects.py
bopopescu/nova-16
85a26f727d34d3dc3b13ddf6fbf80d7c34fb3206
[ "Apache-2.0" ]
1
2020-07-24T00:41:49.000Z
2020-07-24T00:41:49.000Z
# Copyright 2013 IBM Corp. # # 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 agree...
41.398256
79
0.6357
bf31553c50948c1fe89cc0c008c0e3233af2bf27
8,301
py
Python
django_cloud_deploy/cloudlib/service_account.py
di/django-cloud-deploy
2ee99bcabbbb5224280c0977415ae4bdab9ab7e2
[ "Apache-2.0" ]
null
null
null
django_cloud_deploy/cloudlib/service_account.py
di/django-cloud-deploy
2ee99bcabbbb5224280c0977415ae4bdab9ab7e2
[ "Apache-2.0" ]
null
null
null
django_cloud_deploy/cloudlib/service_account.py
di/django-cloud-deploy
2ee99bcabbbb5224280c0977415ae4bdab9ab7e2
[ "Apache-2.0" ]
null
null
null
# Copyright 2018 Google LLC # # 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 # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, ...
40.101449
104
0.614022
d7d659dfef0621038e019ef56f183df69834e8f6
25,635
py
Python
numba/targets/codegen.py
SPIRV/NUMBA
6b93f44c923e7bf8cd9f95cc5188bba3aea4e75d
[ "BSD-2-Clause", "MIT" ]
4
2017-06-30T14:22:30.000Z
2021-01-11T16:47:23.000Z
numba/targets/codegen.py
SPIRV/NUMBA
6b93f44c923e7bf8cd9f95cc5188bba3aea4e75d
[ "BSD-2-Clause", "MIT" ]
1
2017-12-21T23:31:59.000Z
2017-12-29T16:56:05.000Z
numba/targets/codegen.py
SPIRV/NUMBA
6b93f44c923e7bf8cd9f95cc5188bba3aea4e75d
[ "BSD-2-Clause", "MIT" ]
null
null
null
from __future__ import print_function, division, absolute_import import warnings import functools import locale import weakref from collections import defaultdict import ctypes import llvmlite.llvmpy.core as lc import llvmlite.llvmpy.passes as lp import llvmlite.binding as ll import llvmlite.ir as llvmir from numba ...
33.953642
87
0.61771
3fe2e63b5b6203237e8d3eb186740a511f0c82bf
360
py
Python
src/RIOT/tests/libc_newlib/tests/01-run.py
ARte-team/ARte
19f17f57522e1b18ba390718fc94be246451837b
[ "MIT" ]
2
2020-04-30T08:17:45.000Z
2020-05-23T08:46:54.000Z
src/RIOT/tests/libc_newlib/tests/01-run.py
ARte-team/ARte
19f17f57522e1b18ba390718fc94be246451837b
[ "MIT" ]
null
null
null
src/RIOT/tests/libc_newlib/tests/01-run.py
ARte-team/ARte
19f17f57522e1b18ba390718fc94be246451837b
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # Copyright (C) 2018 Freie Universität Berlin # # This file is subject to the terms and conditions of the GNU Lesser # General Public License v2.1. See the file LICENSE in the top level # directory for more details. import sys from testrunner import run_check_unittests if __name__ == "__main_...
24
68
0.761111
f62d85a1765f65d7e4081f6db8eae5af2c5fa2be
5,384
py
Python
optax/_src/lookahead_test.py
eserie/optax
28f9627092ffa08f0637422b90d62b83239d728e
[ "Apache-2.0" ]
null
null
null
optax/_src/lookahead_test.py
eserie/optax
28f9627092ffa08f0637422b90d62b83239d728e
[ "Apache-2.0" ]
null
null
null
optax/_src/lookahead_test.py
eserie/optax
28f9627092ffa08f0637422b90d62b83239d728e
[ "Apache-2.0" ]
null
null
null
# Lint as: python3 # Copyright 2019 DeepMind Technologies Limited. 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 # # ...
37.915493
80
0.695208
4c322abd207ac7b33b3233a334c9309a6b8fb2fa
843
py
Python
gram/migrations/0004_auto_20200102_0832.py
Nyakinyua/instagram
6c03c04f8324a2d0f687e8c87aafa366cf1fff92
[ "MIT" ]
1
2020-04-10T16:00:02.000Z
2020-04-10T16:00:02.000Z
gram/migrations/0004_auto_20200102_0832.py
Nyakinyua/instagram
6c03c04f8324a2d0f687e8c87aafa366cf1fff92
[ "MIT" ]
10
2020-02-12T03:17:30.000Z
2022-02-10T11:31:30.000Z
gram/migrations/0004_auto_20200102_0832.py
Nyakinyua/instagram
6c03c04f8324a2d0f687e8c87aafa366cf1fff92
[ "MIT" ]
null
null
null
# Generated by Django 2.2.4 on 2020-01-02 05:32 from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('gram', '0003_auto_20191231_1102'), ] operations = [ migrations.AddField( model_name='comment', ...
28.1
113
0.601423
762cac01ca8781774f0adc1443dafb0206430e3b
6,569
py
Python
components/aws/sagemaker/train/src/train.py
kevinbache/pipelines
02f5bc08ffb17ab955d497fde6fbbc1a5d6fcde6
[ "Apache-2.0" ]
3
2019-09-18T01:33:27.000Z
2021-06-09T08:19:10.000Z
components/aws/sagemaker/train/src/train.py
kevinbache/pipelines
02f5bc08ffb17ab955d497fde6fbbc1a5d6fcde6
[ "Apache-2.0" ]
12
2020-09-26T01:03:09.000Z
2022-03-03T23:12:24.000Z
components/aws/sagemaker/train/src/train.py
kevinbache/pipelines
02f5bc08ffb17ab955d497fde6fbbc1a5d6fcde6
[ "Apache-2.0" ]
5
2020-08-31T08:48:46.000Z
2021-11-26T07:29:04.000Z
# Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the Li...
85.311688
223
0.75019
4d1b5ad18021f3078b343115ad9584f9d5b23bec
3,496
py
Python
bindings/python/ensmallen/datasets/string/choanephoracucurbitarum.py
AnacletoLAB/ensmallen_graph
b2c1b18fb1e5801712852bcc239f239e03076f09
[ "MIT" ]
5
2021-02-17T00:44:45.000Z
2021-08-09T16:41:47.000Z
bindings/python/ensmallen/datasets/string/choanephoracucurbitarum.py
AnacletoLAB/ensmallen_graph
b2c1b18fb1e5801712852bcc239f239e03076f09
[ "MIT" ]
18
2021-01-07T16:47:39.000Z
2021-08-12T21:51:32.000Z
bindings/python/ensmallen/datasets/string/choanephoracucurbitarum.py
AnacletoLAB/ensmallen
b2c1b18fb1e5801712852bcc239f239e03076f09
[ "MIT" ]
3
2021-01-14T02:20:59.000Z
2021-08-04T19:09:52.000Z
""" This file offers the methods to automatically retrieve the graph Choanephora cucurbitarum. The graph is automatically retrieved from the STRING repository. References --------------------- Please cite the following if you use the data: ```bib @article{szklarczyk2019string, title={STRING v11: protein--prote...
33.295238
223
0.67992
7c31e36fdeb14a5c312bed973db38b8f9fcd42da
8,277
py
Python
utils.py
tsigalko18/udacity-self-driving-car
71db9cf63f2e2eb6f294f422c3eb430a7bce556b
[ "MIT" ]
2
2019-08-22T18:06:58.000Z
2020-02-10T12:58:27.000Z
utils.py
tsigalko18/udacity-self-driving-car
71db9cf63f2e2eb6f294f422c3eb430a7bce556b
[ "MIT" ]
6
2020-03-26T19:17:27.000Z
2022-02-10T01:41:45.000Z
utils.py
tsigalko18/udacity-self-driving-car
71db9cf63f2e2eb6f294f422c3eb430a7bce556b
[ "MIT" ]
2
2019-09-11T07:31:59.000Z
2020-10-26T04:38:19.000Z
import csv import os import shutil import cv2 import matplotlib.image as mpimg import numpy as np import pandas as pd from keras import backend as K # IMAGE_HEIGHT, IMAGE_WIDTH, IMAGE_CHANNELS = 66, 200, 3 IMAGE_HEIGHT, IMAGE_WIDTH, IMAGE_CHANNELS = 160, 320, 3 INPUT_SHAPE = (IMAGE_HEIGHT, IMAGE_WIDTH, IMAGE_CHANNELS...
33.240964
113
0.6332
ee68eb5179cee1fa613b242d28a3e0444de56fed
1,159
py
Python
graph_p.py
thompsonm-ANL/cdc_2017_viz
56bff382037898d805829095e4d68fc3f58398d1
[ "MIT" ]
null
null
null
graph_p.py
thompsonm-ANL/cdc_2017_viz
56bff382037898d805829095e4d68fc3f58398d1
[ "MIT" ]
null
null
null
graph_p.py
thompsonm-ANL/cdc_2017_viz
56bff382037898d805829095e4d68fc3f58398d1
[ "MIT" ]
null
null
null
import graph import matplotlib.pyplot as plt import networkx as nx try: import pygraphviz from networkx.drawing.nx_agraph import graphviz_layout except ImportError: try: import pydotplus from networkx.drawing.nx_pydot import graphviz_layout except ImportError: raise ImportError("...
38.633333
86
0.741156
d19980203183b78afaf7a71fd6c0fa192708c104
2,889
py
Python
neptune/internal/backends/credentials.py
eriknil-onehot/neptune-client
104e1da51297a6e9f6e2d127e9df87dc3d6108de
[ "Apache-2.0" ]
null
null
null
neptune/internal/backends/credentials.py
eriknil-onehot/neptune-client
104e1da51297a6e9f6e2d127e9df87dc3d6108de
[ "Apache-2.0" ]
null
null
null
neptune/internal/backends/credentials.py
eriknil-onehot/neptune-client
104e1da51297a6e9f6e2d127e9df87dc3d6108de
[ "Apache-2.0" ]
null
null
null
# # Copyright (c) 2019, Neptune Labs Sp. z o.o. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agr...
31.064516
117
0.709242
4ee3a7ffa95b5f25a4eed0d92ddd9c0c969b4042
288
py
Python
social/admin.py
vsantacoloma/usb-bts
597cf6af3bfe2e207e99890c26a74125433109df
[ "MIT" ]
null
null
null
social/admin.py
vsantacoloma/usb-bts
597cf6af3bfe2e207e99890c26a74125433109df
[ "MIT" ]
null
null
null
social/admin.py
vsantacoloma/usb-bts
597cf6af3bfe2e207e99890c26a74125433109df
[ "MIT" ]
null
null
null
from social.models import Message from django.contrib import admin class MessageAdmin(admin.ModelAdmin): search_fields = ['content'] list_display = ('content','date_sent') list_filter = ['date_sent'] date_hierarchy = 'date_sent' admin.site.register(Message,MessageAdmin)
28.8
42
0.75
7533729cb42c523d8eac5d1ce0f43de42b941b12
1,073
py
Python
src/threads/termsThread.py
Alopex4/spruce
2bf0bae18fe9b0d13691f2ee926071635cbe7c6f
[ "MIT" ]
1
2019-07-04T10:32:07.000Z
2019-07-04T10:32:07.000Z
src/threads/termsThread.py
Alopex4/spruce
2bf0bae18fe9b0d13691f2ee926071635cbe7c6f
[ "MIT" ]
null
null
null
src/threads/termsThread.py
Alopex4/spruce
2bf0bae18fe9b0d13691f2ee926071635cbe7c6f
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- import requests from PyQt5 import QtCore # class QueryThread(QtCore.QObject): class TermsThread(QtCore.QThread): finishSignal = QtCore.pyqtSignal(bool) htmlSignal = QtCore.pyqtSignal(str) infoSignal = QtCore.pyqtSignal(str, str) def __init__(self, term)...
29.805556
75
0.621622
521366b62bbe5831f9d9e4a6d78bd2c63ef82827
1,833
py
Python
src/ralph/lib/custom_fields/api/viewsets.py
DoNnMyTh/ralph
97b91639fa68965ad3fd9d0d2652a6545a2a5b72
[ "Apache-2.0" ]
1
2021-09-14T01:52:23.000Z
2021-09-14T01:52:23.000Z
src/ralph/lib/custom_fields/api/viewsets.py
hq-git/ralph
e2448caf02d6e5abfd81da2cff92aefe0a534883
[ "Apache-2.0" ]
1
2019-05-27T11:57:15.000Z
2019-05-27T11:57:15.000Z
src/ralph/lib/custom_fields/api/viewsets.py
hq-git/ralph
e2448caf02d6e5abfd81da2cff92aefe0a534883
[ "Apache-2.0" ]
null
null
null
from django.contrib.contenttypes.models import ContentType from rest_framework import viewsets from ..models import CustomFieldValue from .serializers import ( CustomFieldValueSaveSerializer, CustomFieldValueSerializer ) class ObjectCustomFieldsViewSet(viewsets.ModelViewSet): """ Mixin viewset for ne...
33.944444
75
0.687398
3178c20161717dfd4c6263e3e169e231d4d250a5
74,663
py
Python
python/mxnet/gluon/block.py
pioy/incubator-mxnet
9d432079f489327ec6daab61326a3e4f3c7cb8b3
[ "Apache-2.0" ]
null
null
null
python/mxnet/gluon/block.py
pioy/incubator-mxnet
9d432079f489327ec6daab61326a3e4f3c7cb8b3
[ "Apache-2.0" ]
null
null
null
python/mxnet/gluon/block.py
pioy/incubator-mxnet
9d432079f489327ec6daab61326a3e4f3c7cb8b3
[ "Apache-2.0" ]
null
null
null
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
42.518793
118
0.583301
dfada886994cc66278badd8ec94b9a5d9f6de3ea
501
py
Python
packages/python/plotly/plotly/validators/parcoords/line/colorbar/_orientation.py
mastermind88/plotly.py
efa70710df1af22958e1be080e105130042f1839
[ "MIT" ]
null
null
null
packages/python/plotly/plotly/validators/parcoords/line/colorbar/_orientation.py
mastermind88/plotly.py
efa70710df1af22958e1be080e105130042f1839
[ "MIT" ]
null
null
null
packages/python/plotly/plotly/validators/parcoords/line/colorbar/_orientation.py
mastermind88/plotly.py
efa70710df1af22958e1be080e105130042f1839
[ "MIT" ]
null
null
null
import _plotly_utils.basevalidators class OrientationValidator(_plotly_utils.basevalidators.EnumeratedValidator): def __init__( self, plotly_name="orientation", parent_name="parcoords.line.colorbar", **kwargs ): super(OrientationValidator, self).__init__( plotly_name=plotly_name, ...
33.4
88
0.648703
7149bedc9e899c481dd4678cb4c2431078ad67d5
1,545
py
Python
examples/apps/django_multi_apps/sliders/pn_model.py
datalayer-contrib/holoviz-panel
c97b57e8eaff4b5f542add41f496395da2483b23
[ "BSD-3-Clause" ]
1,130
2019-11-23T09:53:37.000Z
2022-03-31T11:30:07.000Z
examples/apps/django_multi_apps/sliders/pn_model.py
datalayer-contrib/holoviz-panel
c97b57e8eaff4b5f542add41f496395da2483b23
[ "BSD-3-Clause" ]
2,265
2019-11-20T17:09:09.000Z
2022-03-31T22:09:38.000Z
examples/apps/django_multi_apps/sliders/pn_model.py
datalayer-contrib/holoviz-panel
c97b57e8eaff4b5f542add41f496395da2483b23
[ "BSD-3-Clause" ]
215
2019-11-26T11:49:04.000Z
2022-03-30T10:23:11.000Z
import numpy as np import param from bokeh.models import ColumnDataSource from bokeh.plotting import figure class SineWave(param.Parameterized): offset = param.Number(default=0.0, bounds=(-5.0, 5.0)) amplitude = param.Number(default=1.0, bounds=(-5.0, 5.0)) phase = param.Number(default=0.0, bounds=(0.0, 2...
42.916667
102
0.616181
abdd76fbaaf19e27c529286db74256ab588160ce
3,218
py
Python
src/tests/base/__init__.py
prereg/prereg
5000c279a801fa2260009b15dd90e3bd4f447785
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
src/tests/base/__init__.py
prereg/prereg
5000c279a801fa2260009b15dd90e3bd4f447785
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
src/tests/base/__init__.py
prereg/prereg
5000c279a801fa2260009b15dd90e3bd4f447785
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
from bs4 import BeautifulSoup from django.test import TestCase class SoupTestMixin: def get_doc(self, *args, **kwargs): response = self.client.get(*args, **kwargs) return BeautifulSoup(response.render().content, "lxml") def post_doc(self, *args, **kwargs): kwargs['follow'] = True ...
34.602151
79
0.551896
a35852f753c52d787d892bc45f2ba08b376da3cf
2,435
py
Python
datalad/customremotes/__init__.py
AKSoo/datalad
dbc34478980c808a86b5531316c986abac953e37
[ "MIT" ]
null
null
null
datalad/customremotes/__init__.py
AKSoo/datalad
dbc34478980c808a86b5531316c986abac953e37
[ "MIT" ]
1
2020-12-01T20:13:51.000Z
2020-12-01T20:13:51.000Z
datalad/customremotes/__init__.py
jwodder/datalad
2b92a764fdc64b750dad68eb51c817218a1ec153
[ "MIT" ]
null
null
null
# emacs: -*- mode: python; py-indent-offset: 4; indent-tabs-mode: nil -*- # vi: set ft=python sts=4 ts=4 sw=4 et: ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ## # # See COPYING file distributed along with the datalad package for the # copyright and license terms. # ### ### ### ### ##...
33.356164
79
0.57577
2c409b7073a6925dcda36d18bd678bfdd52f741f
92
py
Python
backend/sql_text/admin.py
ManishBachhu/editsql
c046dfbee72d3b54ebc7a2326b1eb7797b23d10e
[ "MIT" ]
1
2021-09-29T13:52:50.000Z
2021-09-29T13:52:50.000Z
backend/sql_text/admin.py
ManishBachhu/editsql
c046dfbee72d3b54ebc7a2326b1eb7797b23d10e
[ "MIT" ]
null
null
null
backend/sql_text/admin.py
ManishBachhu/editsql
c046dfbee72d3b54ebc7a2326b1eb7797b23d10e
[ "MIT" ]
null
null
null
from django.contrib import admin from .models import EditSQL admin.site.register(EditSQL)
15.333333
32
0.815217
f246ce256fdc1816a5bf66d75cdf98ff8fb86d32
12,782
py
Python
other_libs_for_reference/LCD_1in8/RaspberryPi/python/LCD_1in8.py
xp-soaring/cambridge_coffee_pot
477864aa3a0c0a2d31c2c18342e804109b2e9bbf
[ "Apache-2.0" ]
9
2019-10-31T14:05:54.000Z
2021-06-14T11:08:14.000Z
other_libs_for_reference/LCD_1in8/RaspberryPi/python/LCD_1in8.py
xp-soaring/cambridge_coffee_pot
477864aa3a0c0a2d31c2c18342e804109b2e9bbf
[ "Apache-2.0" ]
null
null
null
other_libs_for_reference/LCD_1in8/RaspberryPi/python/LCD_1in8.py
xp-soaring/cambridge_coffee_pot
477864aa3a0c0a2d31c2c18342e804109b2e9bbf
[ "Apache-2.0" ]
5
2019-11-23T10:38:49.000Z
2020-06-24T18:59:11.000Z
# -*- coding:UTF-8 -*- ## # | file : LCD_1IN44.py # | version : V1.0 # | date : 2017-08-16 # | function : On the ST7735S chip driver and clear screen, drawing lines, drawing, writing # and other functions to achieve # # Permission is hereby granted, free of charge, to any person obtaining ...
35.904494
140
0.605226
c1deb508d31d87be7ad52a7a931d19871dfc73a9
120
py
Python
run_tests.py
kodi42/currency-symbols
9c45881ff5ecf993df84848c02d2eb44a0202d08
[ "MIT" ]
null
null
null
run_tests.py
kodi42/currency-symbols
9c45881ff5ecf993df84848c02d2eb44a0202d08
[ "MIT" ]
null
null
null
run_tests.py
kodi42/currency-symbols
9c45881ff5ecf993df84848c02d2eb44a0202d08
[ "MIT" ]
null
null
null
import unittest from currency_symbols.test import * # noqa: F403 F401 if __name__ == "__main__": unittest.main()
17.142857
54
0.716667
189a5470e2ddc3ba06b326ee7ad4214d979a1d32
7,059
py
Python
dicom_wsi/isyntax/libtiff_interface.py
Steven-N-Hart/dicom_wsi
254fc404193594e9b321fdefa2aeefb56a42e99a
[ "MIT" ]
6
2020-12-23T01:20:38.000Z
2022-01-13T09:06:20.000Z
dicom_wsi/isyntax/libtiff_interface.py
Steven-N-Hart/dicom_wsi
254fc404193594e9b321fdefa2aeefb56a42e99a
[ "MIT" ]
5
2020-01-10T21:24:52.000Z
2020-08-18T20:04:39.000Z
dicom_wsi/isyntax/libtiff_interface.py
Steven-N-Hart/dicom_wsi
254fc404193594e9b321fdefa2aeefb56a42e99a
[ "MIT" ]
6
2019-11-25T16:03:58.000Z
2021-09-25T11:42:16.000Z
# !/usr/bin/python # -*- coding: utf-8 -*- # Copyright © 2019 Koninklijke Philips N.V. All Rights Reserved. # A copyright license is hereby granted for redistribution and use of the # Software in source and binary forms, with or without modification, provided # that the following conditions are met: # • Redistributio...
37.152632
96
0.688766
c75c2021afc22228edddaf2a9c828ca3f9d206cf
3,582
py
Python
ExamplesAndTests_Wimp_reach/params_reach_Gypsum_HE_Gauss_0.py
sbaum90/paleoSens
0f501780858059bac5e563b60250947e28416109
[ "MIT" ]
null
null
null
ExamplesAndTests_Wimp_reach/params_reach_Gypsum_HE_Gauss_0.py
sbaum90/paleoSens
0f501780858059bac5e563b60250947e28416109
[ "MIT" ]
null
null
null
ExamplesAndTests_Wimp_reach/params_reach_Gypsum_HE_Gauss_0.py
sbaum90/paleoSens
0f501780858059bac5e563b60250947e28416109
[ "MIT" ]
null
null
null
# ------------------------------------------------ # output file name # ------------------------------------------------ fout_name = "ExamplesAndTests_Wimp_reach/reach_HE_Gauss_0" # ------------------------------------------------ # parameter block for sample and read-out info # --------------------------------------...
44.222222
143
0.674204
886f01b286f3e06835c853c41a63e73ad440ec02
1,268
py
Python
google/ads/googleads/v8/services/types/ad_group_ad_asset_view_service.py
wxxlouisa/google-ads-python
f24137966f6bfcb765a9b1fae79f2d23041825fe
[ "Apache-2.0" ]
285
2018-10-05T16:47:58.000Z
2022-03-31T00:58:39.000Z
google/ads/googleads/v8/services/types/ad_group_ad_asset_view_service.py
wxxlouisa/google-ads-python
f24137966f6bfcb765a9b1fae79f2d23041825fe
[ "Apache-2.0" ]
425
2018-09-10T13:32:41.000Z
2022-03-31T14:50:05.000Z
google/ads/googleads/v8/services/types/ad_group_ad_asset_view_service.py
wxxlouisa/google-ads-python
f24137966f6bfcb765a9b1fae79f2d23041825fe
[ "Apache-2.0" ]
369
2018-11-28T07:01:00.000Z
2022-03-28T09:53:22.000Z
# -*- coding: utf-8 -*- # Copyright 2020 Google LLC # # 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...
31.7
136
0.734227
0657db83d3b2f553cba55162049acd1292fcd6cb
74,410
py
Python
testsuite/driver/testlib.py
llelf/ghc
a6c3200c6702afc2e740139b2352bae047ee4a9e
[ "BSD-3-Clause" ]
null
null
null
testsuite/driver/testlib.py
llelf/ghc
a6c3200c6702afc2e740139b2352bae047ee4a9e
[ "BSD-3-Clause" ]
null
null
null
testsuite/driver/testlib.py
llelf/ghc
a6c3200c6702afc2e740139b2352bae047ee4a9e
[ "BSD-3-Clause" ]
null
null
null
# # (c) Simon Marlow 2002 # # This allows us to use the "with X:" syntax with python 2.5: from __future__ import with_statement import shutil import sys import os import errno import string import re import traceback import time import datetime import copy import glob import types from math import ceil, trunc have_s...
33.233586
187
0.586117
4bbe7b8c84747a7b84b697e45bbd3b162ff9de08
1,655
py
Python
tests/DeviceVolume1Test.py
bazwilliams/openhomedevice
8733a7ca016296c19416c4029937b46fd5067521
[ "MIT" ]
9
2017-04-22T03:28:58.000Z
2022-02-19T21:13:21.000Z
tests/DeviceVolume1Test.py
bazwilliams/openhomedevice
8733a7ca016296c19416c4029937b46fd5067521
[ "MIT" ]
13
2017-04-06T15:24:15.000Z
2021-04-22T23:41:30.000Z
tests/DeviceVolume1Test.py
bazwilliams/openhomedevice
8733a7ca016296c19416c4029937b46fd5067521
[ "MIT" ]
4
2017-04-25T12:53:02.000Z
2021-04-03T22:06:36.000Z
import unittest import os import asyncio from openhomedevice.device import Device from aioresponses import aioresponses def async_test(coro): def wrapper(*args, **kwargs): loop = asyncio.new_event_loop() try: return loop.run_until_complete(coro(*args, **kwargs)) finally: ...
31.826923
121
0.591541
ec4edbf82e92ba09dfa06353e5d7627f3eaaf4bf
9,149
py
Python
docx/oxml/__init__.py
BUDDI-AI/python-docx
beb5080e12853814b3ba1ac9536f02817d81d418
[ "MIT" ]
null
null
null
docx/oxml/__init__.py
BUDDI-AI/python-docx
beb5080e12853814b3ba1ac9536f02817d81d418
[ "MIT" ]
null
null
null
docx/oxml/__init__.py
BUDDI-AI/python-docx
beb5080e12853814b3ba1ac9536f02817d81d418
[ "MIT" ]
null
null
null
# encoding: utf-8 """ Initializes oxml sub-package, including registering custom element classes corresponding to Open XML elements. """ from __future__ import absolute_import from lxml import etree from .ns import NamespacePrefixedTag, nsmap # configure XML parser element_class_lookup = etree.ElementNamespaceCla...
36.162055
81
0.724341
ac92238d57b10d6c20a310aa22191f172a2c0c02
49,645
py
Python
tensorflow/python/training/distribute.py
igorcadelima/tensorflow
fe01657f67220fc4e4708e579077157e8f525fc1
[ "Apache-2.0" ]
3
2019-03-14T12:11:03.000Z
2019-07-22T08:23:27.000Z
tensorflow/python/training/distribute.py
tkgkh2020/tensorflow
b7c2e7872c737dd87e48469fc977237819cb8809
[ "Apache-2.0" ]
null
null
null
tensorflow/python/training/distribute.py
tkgkh2020/tensorflow
b7c2e7872c737dd87e48469fc977237819cb8809
[ "Apache-2.0" ]
2
2019-02-07T15:33:54.000Z
2019-03-29T17:44:31.000Z
# Copyright 2018 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
40.559641
112
0.709699
dd47515b56d18eea9cb83fa91986b8f95a8c3e89
39,529
py
Python
Allura/allura/model/auth.py
isabella232/allura
04f14f15a9a9364e18c61f68acdaa241a470186b
[ "Apache-2.0" ]
null
null
null
Allura/allura/model/auth.py
isabella232/allura
04f14f15a9a9364e18c61f68acdaa241a470186b
[ "Apache-2.0" ]
1
2021-10-17T11:32:56.000Z
2021-10-17T11:32:56.000Z
Allura/allura/model/auth.py
isabella232/allura
04f14f15a9a9364e18c61f68acdaa241a470186b
[ "Apache-2.0" ]
null
null
null
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (t...
36.198718
118
0.61102
959bdfac67350d3a2fd6a834c3840d12c5e439e8
2,599
py
Python
gdsfactory/simulation/simphony/components/mzi.py
thomasdorch/gdsfactory
26dccc90d1df9c4b8f2f3c7ceccb385aaf237aff
[ "MIT" ]
null
null
null
gdsfactory/simulation/simphony/components/mzi.py
thomasdorch/gdsfactory
26dccc90d1df9c4b8f2f3c7ceccb385aaf237aff
[ "MIT" ]
null
null
null
gdsfactory/simulation/simphony/components/mzi.py
thomasdorch/gdsfactory
26dccc90d1df9c4b8f2f3c7ceccb385aaf237aff
[ "MIT" ]
null
null
null
from typing import Callable, Optional from gdsfactory.simulation.simphony.components.mmi1x2 import mmi1x2 from gdsfactory.simulation.simphony.components.straight import ( straight as straight_function, ) def mzi( delta_length: float = 10.0, length_y: float = 4.0, length_x: float = 0.1, splitter: ...
26.520408
73
0.623701
764cf2e6c0458e3ef6b117adf18958050096da35
1,078
py
Python
tests/conftest.py
CaptXiong/pytextrank
8f6de5f1d9eeee95712c350c855d3a12f174cfe3
[ "MIT" ]
899
2019-02-12T12:50:23.000Z
2022-03-31T09:58:26.000Z
tests/conftest.py
CaptXiong/pytextrank
8f6de5f1d9eeee95712c350c855d3a12f174cfe3
[ "MIT" ]
108
2019-02-12T14:02:59.000Z
2022-03-08T09:30:25.000Z
tests/conftest.py
CaptXiong/pytextrank
8f6de5f1d9eeee95712c350c855d3a12f174cfe3
[ "MIT" ]
163
2019-02-12T07:30:46.000Z
2022-03-19T12:06:53.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- # type: ignore """Shared fixture functions.""" import pathlib import pytest # pylint: disable=E0401 import spacy # pylint: disable=E0401 from spacy.language import Language # pylint: disable=E0401 from spacy.tokens import Doc # pylint: disable=E0401 @pytest.fixture(s...
23.434783
63
0.666976
afc537edb4b22299ddbfb01aa227823b63079997
756
py
Python
exercises/en/exc_03_24b.py
betatim/MCL-DSCI-011-programming-in-python
b51f43a6bb1bedf0db028613d48d6566309ec44a
[ "MIT" ]
1
2020-06-26T20:15:44.000Z
2020-06-26T20:15:44.000Z
exercises/en/exc_03_24b.py
betatim/MCL-DSCI-011-programming-in-python
b51f43a6bb1bedf0db028613d48d6566309ec44a
[ "MIT" ]
20
2020-06-15T23:05:20.000Z
2020-09-01T22:07:45.000Z
exercises/en/exc_03_24b.py
betatim/MCL-DSCI-011-programming-in-python
b51f43a6bb1bedf0db028613d48d6566309ec44a
[ "MIT" ]
1
2020-06-25T20:53:13.000Z
2020-06-25T20:53:13.000Z
import pandas as pd # We are loading in lego_stock from the last cell and the # lego_sets dataframe lego_stock = pd.read_csv('data/lego_stock.csv') lego_sets = pd.read_csv('data/lego-sets.csv') # Use groupby and agg to sum up the quantity of each set # Save this as store_inventory # ____ = (____.____(____) # ...
27
83
0.706349
b639774321ed1d24aa1ff4219047f99561b571d9
1,506
py
Python
Desensitization.py
SplitGemini/Clash_configuration
964297e8fd34bca8696b5ce0cad77e3eb70245c5
[ "MIT" ]
17
2021-01-18T12:47:06.000Z
2022-03-22T01:16:46.000Z
Desensitization.py
SplitGemini/Clash_configuration
964297e8fd34bca8696b5ce0cad77e3eb70245c5
[ "MIT" ]
null
null
null
Desensitization.py
SplitGemini/Clash_configuration
964297e8fd34bca8696b5ce0cad77e3eb70245c5
[ "MIT" ]
4
2021-09-08T12:04:24.000Z
2022-03-29T11:45:21.000Z
import re import os import shutil """ 数据脱敏 """ # HOME Directory path path = "../" # files name yaml = "parser.yaml" setting = "cfw-settings.yaml" # patterns user = (r"(C:(\\\\|\\|/)Users(\\\\|\\|/))[^\\/]*(?=(\\\\|\\|/)\.config)",r"\1YOURNAME") # 删除被'##delete start'和'##end'包围的内容 delete = (r"\s*##\s?delete\s?start((?!...
32.73913
103
0.612882
21813fdddec79d5cf185748c12699f0455a68e04
8,199
py
Python
HTML/Humpback HTML5.py
orcasound/signal-catalogue
08c248837d63444c7dd332db06f7806f6a0a45ad
[ "MIT" ]
null
null
null
HTML/Humpback HTML5.py
orcasound/signal-catalogue
08c248837d63444c7dd332db06f7806f6a0a45ad
[ "MIT" ]
null
null
null
HTML/Humpback HTML5.py
orcasound/signal-catalogue
08c248837d63444c7dd332db06f7806f6a0a45ad
[ "MIT" ]
null
null
null
#!/usr/bin/env python # coding: utf-8 # In[ ]: <h3>Whup</h3> <div class="wp-block-columns are-vertically-aligned-center"> <div class="wp-block-cloumn is-vertically-aligned-center" style="flex-basis:66.66%"> <figure class="wp-block-image size-full"><img src="https://www.orcasound.net/wp2017/wp-content/uploads/2022/02...
53.940789
264
0.750213
e239b501da5bd87c5bb9875c100344515374d88f
437
py
Python
Machine Learning/rl/plot_rl_rewards.py
Ashleshk/Machine-Learning-Data-Science-Deep-Learning
03357ab98155bf73b8f1d2fd53255cc16bea2333
[ "MIT" ]
1
2020-05-24T06:55:31.000Z
2020-05-24T06:55:31.000Z
Machine Learning/rl/plot_rl_rewards.py
Ashleshk/Machine-Learning-Data-Science-Deep-Learning
03357ab98155bf73b8f1d2fd53255cc16bea2333
[ "MIT" ]
null
null
null
Machine Learning/rl/plot_rl_rewards.py
Ashleshk/Machine-Learning-Data-Science-Deep-Learning
03357ab98155bf73b8f1d2fd53255cc16bea2333
[ "MIT" ]
null
null
null
import matplotlib.pyplot as plt import numpy as np import argparse parser = argparse.ArgumentParser() parser.add_argument('-m', '--mode', type=str, required=True, help='either "train" or "test"') args = parser.parse_args() a = np.load(f'linear_rl_trader_rewards/{args.mode}.npy') print(f"average r...
27.3125
80
0.665904
92fcabbab7d8d7e2c21fa239802b0228a05ed816
1,078
py
Python
section_5/6_excel/read.py
hgohel/Python-for-Everyday-Life
957963e67dca8c2d20a86fc7e66e818c80d013aa
[ "MIT" ]
43
2018-04-09T11:59:11.000Z
2022-01-29T14:27:37.000Z
section_5/6_excel/read.py
hgohel/Python-for-Everyday-Life
957963e67dca8c2d20a86fc7e66e818c80d013aa
[ "MIT" ]
12
2019-11-03T16:50:39.000Z
2021-09-07T23:52:37.000Z
section_5/6_excel/read.py
hgohel/Python-for-Everyday-Life
957963e67dca8c2d20a86fc7e66e818c80d013aa
[ "MIT" ]
45
2018-05-10T21:40:46.000Z
2022-03-01T05:50:07.000Z
# -*- coding: utf-8 -*- # !/usr/bin/env python3 import pathlib import openpyxl import pprint if __name__ == '__main__': src = pathlib.Path('composers.xlsx').resolve() print('Loading workbook...') workbook = openpyxl.load_workbook(str(src)) # Sheets in the workbook sheets = workbook.get_sheet_na...
31.705882
76
0.669759
fa09293937e6f0d5816bb4b230eb310d794c8305
6,717
py
Python
edition/block_holder.py
Manu343726/biicode-common
91b32c6fd1e4a72ce5451183f1766d313cd0e420
[ "MIT" ]
17
2015-04-15T09:40:23.000Z
2017-05-17T20:34:49.000Z
edition/block_holder.py
Manu343726/biicode-common
91b32c6fd1e4a72ce5451183f1766d313cd0e420
[ "MIT" ]
2
2015-04-22T11:29:36.000Z
2018-09-25T09:31:09.000Z
edition/block_holder.py
bowlofstew/common
45e9ca902be7bbbdd73dafe3ab8957bc4a006020
[ "MIT" ]
22
2015-04-15T09:46:00.000Z
2020-09-29T17:03:31.000Z
from biicode.common.model.cells import SimpleCell from biicode.common.model.dependency_set import DependencySet from biicode.common.model.brl.block_name import BlockName from biicode.common.model.symbolic.block_version_table import BlockVersionTable from biicode.common.model.blob import Blob from biicode.common.model.r...
33.924242
96
0.618282
55324dc9d47094246f473d3098560bbc2cca2181
7,096
py
Python
aioflask/cli.py
rperesy/aioflask
446c34671fe2d7084815e2639cf416534ac1a5e8
[ "MIT" ]
null
null
null
aioflask/cli.py
rperesy/aioflask
446c34671fe2d7084815e2639cf416534ac1a5e8
[ "MIT" ]
null
null
null
aioflask/cli.py
rperesy/aioflask
446c34671fe2d7084815e2639cf416534ac1a5e8
[ "MIT" ]
null
null
null
from functools import wraps from inspect import iscoroutinefunction import os import sys from flask.cli import * from flask.cli import AppGroup, ScriptInfo, update_wrapper, \ SeparatedPathType, pass_script_info, get_debug_flag from flask.cli import _validate_key from flask.globals import _app_ctx_stack from flask....
29.690377
78
0.620913
8d071e8e64d7928eaf2171117e06c7d9167ce93b
10,655
py
Python
src/practice_problem2.py
Zdanavz/13-Exam2Practice
6c65a2a9a506bf4fff38eb5c014940765eafd97d
[ "MIT" ]
null
null
null
src/practice_problem2.py
Zdanavz/13-Exam2Practice
6c65a2a9a506bf4fff38eb5c014940765eafd97d
[ "MIT" ]
null
null
null
src/practice_problem2.py
Zdanavz/13-Exam2Practice
6c65a2a9a506bf4fff38eb5c014940765eafd97d
[ "MIT" ]
null
null
null
""" PRACTICE Exam 2, practice_problem 2. Authors: David Mutchler, Vibha Alangar, Matt Boutell, Dave Fisher, Mark Hays, Amanda Stouder, Aaron Wilkin, their colleagues, and Zack Z. """ # Done: 1. PUT YOUR NAME IN THE ABOVE LINE. ########################################################################...
38.053571
79
0.528766
ef978b1341d6c5d5f3129e9244bedb2f75765eb8
996
py
Python
blog/viewmixins.py
pincoin/rakmai
d9daa399aff50712a86b2dec9d94e622237b25b0
[ "MIT" ]
11
2018-04-02T16:36:19.000Z
2019-07-10T05:54:58.000Z
blog/viewmixins.py
pincoin/rakmai
d9daa399aff50712a86b2dec9d94e622237b25b0
[ "MIT" ]
22
2019-01-01T20:40:21.000Z
2022-02-10T08:06:39.000Z
blog/viewmixins.py
pincoin/rakmai
d9daa399aff50712a86b2dec9d94e622237b25b0
[ "MIT" ]
4
2019-03-12T14:24:37.000Z
2022-01-07T16:20:22.000Z
import logging from .forms import PostSearchForm from .models import Blog class BlogContextMixin(object): logger = logging.getLogger(__name__) def dispatch(self, *args, **kwargs): self.blog = Blog.objects.get(slug=self.kwargs['blog']) self.block_size = self.blog.block_size self.chun...
27.666667
77
0.684739
7dd9f9d87ac14ab679332e3d970aaeb43a57bfb3
492
py
Python
tests/integration/rolling_update/yaml/custom.py
slettner/jina
4140961c62359e3acd540a6d88931665c6313824
[ "Apache-2.0" ]
null
null
null
tests/integration/rolling_update/yaml/custom.py
slettner/jina
4140961c62359e3acd540a6d88931665c6313824
[ "Apache-2.0" ]
null
null
null
tests/integration/rolling_update/yaml/custom.py
slettner/jina
4140961c62359e3acd540a6d88931665c6313824
[ "Apache-2.0" ]
null
null
null
from typing import Tuple, Iterable, Optional import numpy as np from jina.executors.indexers.vector import NumpyIndexer class MockVectorIndexer(NumpyIndexer): def query( self, vectors: 'np.ndarray', top_k: int, *args, **kwargs ) -> Tuple['np.ndarray', 'np.ndarray']: return np.array([[0]]), ...
25.894737
64
0.640244
2a104387ae09cff8336a4f75434170dbbed7ae17
494
py
Python
app/gui_components/button_components.py
crazcalm/photo-booth
c3c7a919721431479a0341905aaba8a6c354ba23
[ "MIT" ]
null
null
null
app/gui_components/button_components.py
crazcalm/photo-booth
c3c7a919721431479a0341905aaba8a6c354ba23
[ "MIT" ]
null
null
null
app/gui_components/button_components.py
crazcalm/photo-booth
c3c7a919721431479a0341905aaba8a6c354ba23
[ "MIT" ]
null
null
null
from tkinter import * from tkinter.ttk import * from tkinter import messagebox def helloCallBack(): messagebox.showinfo("Hello Python", "Hello World") class ButtonComponent(Button): def __init__(self, root, text="testing"): super().__init__(master=root, text=text, command=helloCallBack) # S...
23.52381
71
0.665992
eb5b3b7f7c3b73fb48d6b6789d2186b1af571af3
2,423
py
Python
src/config.py
dhruv100691/commonsense-rc
b1cffc00a3fcb1f1cc60224a01695cb63fea873a
[ "MIT" ]
null
null
null
src/config.py
dhruv100691/commonsense-rc
b1cffc00a3fcb1f1cc60224a01695cb63fea873a
[ "MIT" ]
null
null
null
src/config.py
dhruv100691/commonsense-rc
b1cffc00a3fcb1f1cc60224a01695cb63fea873a
[ "MIT" ]
null
null
null
import os import argparse import logging logger = logging.getLogger(__name__) def str2bool(v): return v.lower() in ('yes', 'true', 't', '1', 'y') parser = argparse.ArgumentParser() parser.register('type', 'bool', str2bool) parser.add_argument('--gpu', type=str, default='0', help='GPU to use') parser.add_argument...
62.128205
126
0.742468
b731c89d091546e6060bdd4f05cf04a87182a516
1,654
py
Python
RecoParticleFlow/PFProducer/python/simPFProducer_cfi.py
nistefan/cmssw
ea13af97f7f2117a4f590a5e654e06ecd9825a5b
[ "Apache-2.0" ]
null
null
null
RecoParticleFlow/PFProducer/python/simPFProducer_cfi.py
nistefan/cmssw
ea13af97f7f2117a4f590a5e654e06ecd9825a5b
[ "Apache-2.0" ]
null
null
null
RecoParticleFlow/PFProducer/python/simPFProducer_cfi.py
nistefan/cmssw
ea13af97f7f2117a4f590a5e654e06ecd9825a5b
[ "Apache-2.0" ]
null
null
null
import FWCore.ParameterSet.Config as cms simPFProducer = cms.EDProducer( 'SimPFProducer', superClusterThreshold = cms.double(4.0), neutralEMThreshold = cms.double(0.250), neutralHADThreshold = cms.double(0.250), pfRecTrackSrc = cms.InputTag("hgcalTrackCollection:TracksInHGCal"), trackSrc = cms....
48.647059
131
0.802902
49d4c5124dc0eed6160ce6cb35a30799b4a3533f
1,910
py
Python
backend/pollutionbot/db_sqlite.py
Artagok/HackUPC2017-HemisBot
2a78eb3a82021f8d936a28bad3b2525d5c98aecf
[ "Unlicense" ]
null
null
null
backend/pollutionbot/db_sqlite.py
Artagok/HackUPC2017-HemisBot
2a78eb3a82021f8d936a28bad3b2525d5c98aecf
[ "Unlicense" ]
null
null
null
backend/pollutionbot/db_sqlite.py
Artagok/HackUPC2017-HemisBot
2a78eb3a82021f8d936a28bad3b2525d5c98aecf
[ "Unlicense" ]
null
null
null
import sqlite3 class DB_SQLite: def __init__(self, dbname="pollutionbot.sqlite"): self.dbname = dbname self.conn = sqlite3.connect(dbname) def setup(self): table_statement = "CREATE TABLE IF NOT EXISTS records (description text, user text)" # pure_url = "CREATE TABLE IF NOT EX...
40.638298
92
0.646073
433b447485aa695c69b260d74c0faf2672678615
938
py
Python
539_minTimeDifference.py
stuti-rastogi/leetcode-python-solutions
73593fe642a06a83cde974ba5e6de3a7b396ec84
[ "MIT" ]
4
2018-07-24T08:36:42.000Z
2019-08-25T17:48:47.000Z
539_minTimeDifference.py
stuti-rastogi/leetcodesolutions
73593fe642a06a83cde974ba5e6de3a7b396ec84
[ "MIT" ]
null
null
null
539_minTimeDifference.py
stuti-rastogi/leetcodesolutions
73593fe642a06a83cde974ba5e6de3a7b396ec84
[ "MIT" ]
null
null
null
# class Solution: # def findMinDifference(self, timePoints: List[str]) -> int: # def convert(time): # return int(time[:2]) * 60 + int(time[3:]) # minutes = list(map(convert, timePoints)) # minutes.sort() # return min((y - x) % (24 * 60) for x, y in zip(minutes, minutes[1...
32.344828
110
0.576759
3bddf3aad5ef90bf827a97b722c4053664b1c8ed
748
py
Python
6002x/noReplacementSimulation.py
CarlosEduardoAS/MITx
532695d69c77581b6df80c145283b349b75e4973
[ "MIT" ]
null
null
null
6002x/noReplacementSimulation.py
CarlosEduardoAS/MITx
532695d69c77581b6df80c145283b349b75e4973
[ "MIT" ]
null
null
null
6002x/noReplacementSimulation.py
CarlosEduardoAS/MITx
532695d69c77581b6df80c145283b349b75e4973
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Mon May 3 14:03:46 2021 @author: caear """ import random def noReplacementSimulation(numTrials): ''' Runs numTrials trials of a Monte Carlo simulation of drawing 3 balls out of a bucket containing 3 red and 3 green balls. Balls are not replaced once drawn. R...
25.793103
59
0.610963
f3bdee2e7561b4e684354f68c6b689cf761566ec
7,287
py
Python
ADPTC_LIB/cluster.py
SuilandCoder/ADPTC_LIB
ef5c2b7fcf117c8c90a3841489471289ecbf4562
[ "MIT" ]
null
null
null
ADPTC_LIB/cluster.py
SuilandCoder/ADPTC_LIB
ef5c2b7fcf117c8c90a3841489471289ecbf4562
[ "MIT" ]
null
null
null
ADPTC_LIB/cluster.py
SuilandCoder/ADPTC_LIB
ef5c2b7fcf117c8c90a3841489471289ecbf4562
[ "MIT" ]
null
null
null
''' Description: Author: SongJ Date: 2020-12-28 10:23:45 LastEditTime: 2021-04-12 10:33:11 LastEditors: SongJ ''' #%% from sklearn.utils import check_array import time from . import myutil from . import visual from . import prepare class ADPTC: def __init__(self, X, lon_index=0, lat_index=1, time_index=2, attrs_i...
42.864706
173
0.624674
36beafc514529244fa36861e151c740e29c8c5a6
1,091
py
Python
Company_Based_Questions/Intuit/Number_of_islands.py
Satyam-Bhalla/Competitive-Coding
5814f5f60572f1e76495efe751b94bf4d2845198
[ "MIT" ]
1
2021-12-09T10:36:48.000Z
2021-12-09T10:36:48.000Z
Company_Based_Questions/Intuit/Number_of_islands.py
Satyam-Bhalla/Competitive-Coding
5814f5f60572f1e76495efe751b94bf4d2845198
[ "MIT" ]
null
null
null
Company_Based_Questions/Intuit/Number_of_islands.py
Satyam-Bhalla/Competitive-Coding
5814f5f60572f1e76495efe751b94bf4d2845198
[ "MIT" ]
null
null
null
def getRegionSize(matrix,row,column): if row < 0 or column < 0 or row >= len(matrix) or column >= len(matrix[row]): return 0 if matrix[row][column] == 0: return 0 matrix[row][column] = 0 size = 1 for r in range(row-1,row+2): for c in range(column-1,column+2): if r...
30.305556
81
0.505041
4c8a8cec34d2f7702a3fd1d06880b0f4e15c67e5
698
py
Python
test/files/file_stream.py
lesteve/tensorwatch
32832b162cab6e05671f4f50c51a8a693d0636b8
[ "MIT" ]
3,453
2019-05-22T15:01:23.000Z
2022-03-31T07:50:41.000Z
test/files/file_stream.py
wgxcow/tensorwatch
142f83a7cb8c54e47e9bab06cb3a1ef8ae225422
[ "MIT" ]
69
2019-05-22T17:11:20.000Z
2022-03-03T09:32:38.000Z
test/files/file_stream.py
wgxcow/tensorwatch
142f83a7cb8c54e47e9bab06cb3a1ef8ae225422
[ "MIT" ]
375
2019-05-22T17:10:33.000Z
2022-03-24T07:43:07.000Z
from tensorwatch.watcher_base import WatcherBase from tensorwatch.stream import Stream from tensorwatch.file_stream import FileStream from tensorwatch import LinePlot from tensorwatch.image_utils import plt_loop import tensorwatch as tw def file_write(): watcher = WatcherBase() stream = watcher.create_stream(e...
24.068966
75
0.704871
b2fbc27720963df1027cf63856d6e273be4ddbcd
2,087
py
Python
src/airfly/_vendor/airflow/providers/google/cloud/operators/dataflow.py
ryanchao2012/airfly
230ddd88885defc67485fa0c51f66c4a67ae98a9
[ "MIT" ]
7
2021-09-27T11:38:48.000Z
2022-02-01T06:06:24.000Z
src/airfly/_vendor/airflow/providers/google/cloud/operators/dataflow.py
ryanchao2012/airfly
230ddd88885defc67485fa0c51f66c4a67ae98a9
[ "MIT" ]
null
null
null
src/airfly/_vendor/airflow/providers/google/cloud/operators/dataflow.py
ryanchao2012/airfly
230ddd88885defc67485fa0c51f66c4a67ae98a9
[ "MIT" ]
null
null
null
# Auto generated by 'inv collect-airflow' from airfly._vendor.airflow.models.baseoperator import BaseOperator class DataflowCreateJavaJobOperator(BaseOperator): jar: "str" job_name: "str" dataflow_default_options: "typing.Union[dict, NoneType]" options: "typing.Union[dict, NoneType]" project_id: "...
37.267857
84
0.717777
785fa2d9b6bf87cd6c8f9d499a4122d68b5ba759
6,624
py
Python
kubernetes_asyncio/client/models/v1_pod_list.py
dineshsonachalam/kubernetes_asyncio
d57e9e9be11f6789e1ce8d5b161acb64d29acf35
[ "Apache-2.0" ]
1
2021-02-25T04:36:18.000Z
2021-02-25T04:36:18.000Z
kubernetes_asyncio/client/models/v1_pod_list.py
hubo1016/kubernetes_asyncio
d57e9e9be11f6789e1ce8d5b161acb64d29acf35
[ "Apache-2.0" ]
null
null
null
kubernetes_asyncio/client/models/v1_pod_list.py
hubo1016/kubernetes_asyncio
d57e9e9be11f6789e1ce8d5b161acb64d29acf35
[ "Apache-2.0" ]
null
null
null
# coding: utf-8 """ Kubernetes No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) # noqa: E501 OpenAPI spec version: v1.12.4 Generated by: https://github.com/swagger-api/swagger-codegen.git """ import pprint import re # noqa: F401 import si...
32.955224
295
0.611262
f23347e8f915fd9916d203822709880c26b404fa
4,373
py
Python
nmoo/denoisers/knnavg.py
altaris/noisy-moo
86fd5972c8bf9216357cca3abaa0268ff04b1cc0
[ "MIT" ]
1
2022-03-17T09:03:17.000Z
2022-03-17T09:03:17.000Z
nmoo/denoisers/knnavg.py
altaris/noisy-moo
86fd5972c8bf9216357cca3abaa0268ff04b1cc0
[ "MIT" ]
5
2021-09-13T02:08:12.000Z
2021-10-12T03:41:15.000Z
nmoo/denoisers/knnavg.py
altaris/noisy-moo
86fd5972c8bf9216357cca3abaa0268ff04b1cc0
[ "MIT" ]
null
null
null
""" A denoiser tries to cancel noise. (also water is wet) """ __docformat__ = "google" from scipy.spatial.distance import cdist import numpy as np import pandas as pd from nmoo.wrapped_problem import WrappedProblem class KNNAvg(WrappedProblem): """ Implementation of the KNN-Avg algorithm of Klikovits and Ar...
36.140496
129
0.561171
bfd02617b6d9b2a8ad3136c2713a5ab216b96ae9
20,072
py
Python
sib_api_v3_sdk/api/attributes_api.py
Danilka/APIv3-python-library
c96472f47d652d2e09e8b4a48a80e33fde06e7f1
[ "MIT" ]
null
null
null
sib_api_v3_sdk/api/attributes_api.py
Danilka/APIv3-python-library
c96472f47d652d2e09e8b4a48a80e33fde06e7f1
[ "MIT" ]
null
null
null
sib_api_v3_sdk/api/attributes_api.py
Danilka/APIv3-python-library
c96472f47d652d2e09e8b4a48a80e33fde06e7f1
[ "MIT" ]
null
null
null
# coding: utf-8 """ SendinBlue API SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at h...
44.114286
820
0.637505
7846923533caefb63d4408afe3ecc0457c723e12
9,721
py
Python
JMOSS/visualization.py
SaguaroAerospaceResearch/JMOSS
a81fd17ca63d531b0ec34aa19e68ca41a45c3af9
[ "MIT" ]
1
2020-01-25T07:51:11.000Z
2020-01-25T07:51:11.000Z
JMOSS/visualization.py
SaguaroAerospaceResearch/JMOSS
a81fd17ca63d531b0ec34aa19e68ca41a45c3af9
[ "MIT" ]
null
null
null
JMOSS/visualization.py
SaguaroAerospaceResearch/JMOSS
a81fd17ca63d531b0ec34aa19e68ca41a45c3af9
[ "MIT" ]
null
null
null
""" JMOSS Air Data Visualization Written by Juan Jurado, Clark McGehee Based on: Jurado, Juan D., and Clark C. McGehee. "Complete Online Algorithm for Air Data System Calibration." Journal of Aircraft 56.2 (2019): 517-528. Erb, Russell E. "Pitot-Statics Textbook." US Air Force Test Pilot ...
47.651961
119
0.592223
065285a83c2f46210533f1ea6f8f4cfc535703b1
3,224
py
Python
src/python/grpcio_tests/tests/unit/_server_wait_for_termination_test.py
warlock135/grpc
81e13e4fa9c0cdf7dc131ce548e1604c895b738c
[ "Apache-2.0" ]
36,552
2015-02-26T17:30:13.000Z
2022-03-31T22:41:33.000Z
src/python/grpcio_tests/tests/unit/_server_wait_for_termination_test.py
SanjanaSingh897/grpc
2d858866eb95ce5de8ccc8c35189a12733d8ca79
[ "Apache-2.0" ]
23,536
2015-02-26T17:50:56.000Z
2022-03-31T23:39:42.000Z
src/python/grpcio_tests/tests/unit/_server_wait_for_termination_test.py
SanjanaSingh897/grpc
2d858866eb95ce5de8ccc8c35189a12733d8ca79
[ "Apache-2.0" ]
11,050
2015-02-26T17:22:10.000Z
2022-03-31T10:12:35.000Z
# Copyright 2019 The gRPC Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writ...
34.666667
78
0.616315
3660459d38e54bff5799258625992e702bf44ad7
13,524
py
Python
colorvalidator.py
peteroupc/colorvalidator
64398e72c2603a5a0f6de0a028cc88ec05d20611
[ "CC0-1.0" ]
2
2015-12-22T16:20:37.000Z
2020-10-26T19:11:06.000Z
colorvalidator.py
peteroupc/colorvalidator
64398e72c2603a5a0f6de0a028cc88ec05d20611
[ "CC0-1.0" ]
null
null
null
colorvalidator.py
peteroupc/colorvalidator
64398e72c2603a5a0f6de0a028cc88ec05d20611
[ "CC0-1.0" ]
null
null
null
# This file is in the public domain. Peter O., 2012. http://upokecenter.dreamhosters.com # Any copyright to this work is released to the Public Domain. In case this is not possible, this work is also licensed under Creative Commons Zero: http://creativecommons.org/publicdomain/zero/1.0/ # # This file converts between...
40.491018
199
0.554274
2d1ad41b5f26a4ce011fbed7ffbc3c2f41480abb
9,853
py
Python
slack_bot.py
HaithemSouala/slackernetes
010edfb4659d8de33a62250e45b481888d48a3a1
[ "Apache-2.0" ]
null
null
null
slack_bot.py
HaithemSouala/slackernetes
010edfb4659d8de33a62250e45b481888d48a3a1
[ "Apache-2.0" ]
null
null
null
slack_bot.py
HaithemSouala/slackernetes
010edfb4659d8de33a62250e45b481888d48a3a1
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python3 from slackernetes import k, send_file, send_message, register, run import logging import re @register(r"(?:get|list) images in namespace (\S+)") def list_images(**payload): """ List images used in a namespace """ namespace = re.search(payload["regex"], payload["data"]["text"]).gr...
32.411184
153
0.590277
e50518669af57e82341638d1c9e64c8960614e8f
836
py
Python
VI/ch28/person.py
skellykiernan/pylearn
b3576a087c8005e57b8415d63dc75d6975b3480f
[ "BSD-3-Clause" ]
null
null
null
VI/ch28/person.py
skellykiernan/pylearn
b3576a087c8005e57b8415d63dc75d6975b3480f
[ "BSD-3-Clause" ]
null
null
null
VI/ch28/person.py
skellykiernan/pylearn
b3576a087c8005e57b8415d63dc75d6975b3480f
[ "BSD-3-Clause" ]
null
null
null
from classtools import AttrDisplay class Person(AttrDisplay): """record for a person""" def __init__(self, name, job=None, pay=0): super(Person, self).__init__() self.name = name self.job = job self.pay = pay def lastName(self): """get last name""" return se...
23.222222
64
0.563397
e8d51d0b54b31665950079cedfd3aa9852cc9329
179
py
Python
Leetcode/0412. Fizz Buzz/0412.py
Next-Gen-UI/Code-Dynamics
a9b9d5e3f27e870b3e030c75a1060d88292de01c
[ "MIT" ]
null
null
null
Leetcode/0412. Fizz Buzz/0412.py
Next-Gen-UI/Code-Dynamics
a9b9d5e3f27e870b3e030c75a1060d88292de01c
[ "MIT" ]
null
null
null
Leetcode/0412. Fizz Buzz/0412.py
Next-Gen-UI/Code-Dynamics
a9b9d5e3f27e870b3e030c75a1060d88292de01c
[ "MIT" ]
null
null
null
class Solution: def fizzBuzz(self, n: int) -> List[str]: d = {3: 'Fizz', 5: 'Buzz'} return [''.join([d[k] for k in d if i % k == 0]) or str(i) for i in range(1, n + 1)]
35.8
88
0.52514
087185d1c34ce5af305079813e0a6f43dd4e1a7c
5,248
py
Python
src/scs_dfe/gps/sam_m8q.py
south-coast-science/scs_dfe_edu
076554e1b85d8fea05ee5aa5bca0cdad58f00226
[ "MIT" ]
1
2018-10-08T10:39:24.000Z
2018-10-08T10:39:24.000Z
src/scs_dfe/gps/sam_m8q.py
south-coast-science/scs_dfe_edu
076554e1b85d8fea05ee5aa5bca0cdad58f00226
[ "MIT" ]
null
null
null
src/scs_dfe/gps/sam_m8q.py
south-coast-science/scs_dfe_edu
076554e1b85d8fea05ee5aa5bca0cdad58f00226
[ "MIT" ]
2
2019-03-07T00:25:11.000Z
2020-02-28T13:45:55.000Z
""" Created on 31 Jan 2019 @author: Bruno Beloff (bruno.beloff@southcoastscience.com) https://www.u-blox.com/en/product/sam-m8q-module example sentences: PAM7... $GPRMC,103228.00,A,5049.37823,N,00007.37872,W,0.104,,301216,,,D*64 $GPVTG,,T,,M,0.104,N,0.193,K,D*28 $GPGGA,103228.00,5049.37823,N,00007.37872,W,2,07,1.85,...
29.988571
118
0.530678
b12fbc2942badd784239386c4e70a3a3cac7aa00
20,957
py
Python
nest_elephant_tvb/Tvb/simulation_Zerlaut.py
w-klijn/TVB-NEST
f3a4e18c9c6aab9d39d7ab45097d2fa98418cc1e
[ "Apache-2.0" ]
2
2020-10-21T11:45:19.000Z
2020-12-01T09:32:53.000Z
nest_elephant_tvb/Tvb/simulation_Zerlaut.py
w-klijn/TVB-NEST
f3a4e18c9c6aab9d39d7ab45097d2fa98418cc1e
[ "Apache-2.0" ]
10
2020-11-17T09:33:19.000Z
2022-01-11T17:00:40.000Z
nest_elephant_tvb/Tvb/simulation_Zerlaut.py
w-klijn/TVB-NEST
f3a4e18c9c6aab9d39d7ab45097d2fa98418cc1e
[ "Apache-2.0" ]
9
2020-11-17T08:52:51.000Z
2021-12-10T12:25:04.000Z
# Copyright 2020 Forschungszentrum Jülich GmbH and Aix-Marseille Université # "Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements; and to You under the Apache License, Version 2.0. " import logging logging.getLogger('numba').setLevel(logging.WARNING) logging.getLogger('t...
44.12
153
0.668082
4deba1865326ee4b600c9f5a8cff2e2619b8135c
12,645
py
Python
bob/db/base/database.py
bioidiap/bob.db.base
714d2f7b605aa6480f447b92127678444971ca64
[ "BSD-3-Clause" ]
null
null
null
bob/db/base/database.py
bioidiap/bob.db.base
714d2f7b605aa6480f447b92127678444971ca64
[ "BSD-3-Clause" ]
4
2016-06-17T11:57:43.000Z
2016-07-28T18:13:19.000Z
bob/db/base/database.py
bioidiap/bob.db.base
714d2f7b605aa6480f447b92127678444971ca64
[ "BSD-3-Clause" ]
2
2016-03-08T11:14:51.000Z
2016-07-28T16:12:55.000Z
#!/usr/bin/env python # vim: set fileencoding=utf-8 : import os import warnings import logging from . import utils from .file import File from .utils import check_parameters_for_validity, \ check_parameter_for_validity, \ convert_names_to_highlevel, \ convert_names_to_lowlevel, \ file_names, \ so...
33.452381
79
0.648794
5b17e6ad360d6057eb61f1d9395c3758997feaf4
43,858
py
Python
tests/serialization/test_dag_serialization.py
raspberryfield/airflow
3eb67af7a3fab61b7f691da66129c228af27d95e
[ "Apache-2.0", "BSD-2-Clause", "MIT", "ECL-2.0", "BSD-3-Clause" ]
3
2021-07-30T16:46:46.000Z
2021-10-19T07:18:47.000Z
tests/serialization/test_dag_serialization.py
raspberryfield/airflow
3eb67af7a3fab61b7f691da66129c228af27d95e
[ "Apache-2.0", "BSD-2-Clause", "MIT", "ECL-2.0", "BSD-3-Clause" ]
6
2019-03-16T02:09:30.000Z
2019-06-27T03:27:34.000Z
tests/serialization/test_dag_serialization.py
raspberryfield/airflow
3eb67af7a3fab61b7f691da66129c228af27d95e
[ "Apache-2.0", "BSD-2-Clause", "MIT", "ECL-2.0", "BSD-3-Clause" ]
1
2021-05-12T13:17:37.000Z
2021-05-12T13:17:37.000Z
# # Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not...
40.163004
110
0.59818
3f0e5fcd13571126a49ab1a8969339e7798f2c5e
7,469
py
Python
neuralmt/zipout.py
anoopsarkar/nlp-class-hw
3b6e1ae3dca85b6fd9e68f60b9e7dc019d71729c
[ "Apache-2.0" ]
7
2016-09-14T21:08:03.000Z
2020-10-16T17:06:18.000Z
neuralmt/zipout.py
anoopsarkar/nlp-class-hw
3b6e1ae3dca85b6fd9e68f60b9e7dc019d71729c
[ "Apache-2.0" ]
null
null
null
neuralmt/zipout.py
anoopsarkar/nlp-class-hw
3b6e1ae3dca85b6fd9e68f60b9e7dc019d71729c
[ "Apache-2.0" ]
14
2016-09-18T07:04:23.000Z
2021-09-15T00:47:18.000Z
""" First make sure you have a Python3 program for your answer in ./answer/ Then run: python3 zipout.py This will create a file `output.zip`. To customize the files used by default, run: python3 zipout.py -h """ import sys, os, optparse, logging, tempfile, subprocess, shutil import iocollect class ZipOut...
46.104938
169
0.62177
3acd8cc7ba379cebb0963698bf55a2117e393b9c
12,245
py
Python
src/lockdown/lockdown.py
trashvin/lockdown_game_witty
b18fb259ce11f67f751c71a53faf822626d5a906
[ "MIT" ]
null
null
null
src/lockdown/lockdown.py
trashvin/lockdown_game_witty
b18fb259ce11f67f751c71a53faf822626d5a906
[ "MIT" ]
null
null
null
src/lockdown/lockdown.py
trashvin/lockdown_game_witty
b18fb259ce11f67f751c71a53faf822626d5a906
[ "MIT" ]
1
2021-08-19T00:43:28.000Z
2021-08-19T00:43:28.000Z
from logging import exception import pygame as pg import lockdown.library import lockdown.constants from lockdown.constants import * from lockdown.logger import Logger from lockdown.screens.opening_screen import OpeningScreen from lockdown.screens.game_screen import GameScreen from lockdown.elements.paddle import Pad...
43.576512
122
0.481013
d63615ef74758b336da88da3d78affacef87a218
2,662
py
Python
coro/http/demo/grid.py
amitdev/shrapnel
e9032fe6c906d8ebe55164c91a263c1ee7d7b045
[ "BSD-2-Clause" ]
98
2015-01-09T05:35:59.000Z
2021-11-22T17:38:58.000Z
coro/http/demo/grid.py
amitdev/shrapnel
e9032fe6c906d8ebe55164c91a263c1ee7d7b045
[ "BSD-2-Clause" ]
22
2015-02-10T23:57:53.000Z
2020-01-31T01:14:55.000Z
coro/http/demo/grid.py
amitdev/shrapnel
e9032fe6c906d8ebe55164c91a263c1ee7d7b045
[ "BSD-2-Clause" ]
22
2015-03-07T20:59:32.000Z
2021-07-22T09:23:52.000Z
# -*- Mode: Python -*- import coro import coro.http import coro.backdoor # toy: move an X through a grid. # tests: POST data, compression, persistent connections, shared state import sys W = sys.stderr.write class grid_handler: def __init__ (self, w, h): self.w = w self.h = h self.grid ...
33.275
69
0.476709
b1872f5811354437c104f9804acffd350baa9de5
9,612
py
Python
general.py
slsfi/digital_edition_events
29284c6d1ba1cd99b95a74303631af99703bf784
[ "MIT" ]
null
null
null
general.py
slsfi/digital_edition_events
29284c6d1ba1cd99b95a74303631af99703bf784
[ "MIT" ]
null
null
null
general.py
slsfi/digital_edition_events
29284c6d1ba1cd99b95a74303631af99703bf784
[ "MIT" ]
null
null
null
from setup import * def removeOldSubjectConnections(): e_update_sql = """ UPDATE event_connection SET subject_id = NULL, date_modified=now() WHERE subject_id IN ( select id from subject where project_id = %s and type = 'person' ) AND work_manifestation_id is NULL AND type='publication-subject-occurrence' """ v...
45.126761
258
0.700062
5d643950db3d0af95a1c2383dbdd425574b22572
8,533
py
Python
sdk/python/pulumi_azure_nextgen/containerregistry/v20170601preview/registry.py
test-wiz-sec/pulumi-azure-nextgen
20a695af0d020b34b0f1c336e1b69702755174cc
[ "Apache-2.0" ]
null
null
null
sdk/python/pulumi_azure_nextgen/containerregistry/v20170601preview/registry.py
test-wiz-sec/pulumi-azure-nextgen
20a695af0d020b34b0f1c336e1b69702755174cc
[ "Apache-2.0" ]
null
null
null
sdk/python/pulumi_azure_nextgen/containerregistry/v20170601preview/registry.py
test-wiz-sec/pulumi-azure-nextgen
20a695af0d020b34b0f1c336e1b69702755174cc
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi SDK Generator. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union from ... import _utilities, _tables from...
42.452736
508
0.647369
afade20265a01fe01de455831b9e82de23db465c
3,224
py
Python
docs/seaman/seaman_symbol.py
martinlarsalbert/wPCC
16e0d4cc850d503247916c9f5bd9f0ddb07f8930
[ "MIT" ]
null
null
null
docs/seaman/seaman_symbol.py
martinlarsalbert/wPCC
16e0d4cc850d503247916c9f5bd9f0ddb07f8930
[ "MIT" ]
null
null
null
docs/seaman/seaman_symbol.py
martinlarsalbert/wPCC
16e0d4cc850d503247916c9f5bd9f0ddb07f8930
[ "MIT" ]
null
null
null
""" The classes in this module extends the Sympy Symbol class, to also carry description, unit and bis denominator """ import sympy as sp from collections import OrderedDict # my custom class with description attribute class Symbol(sp.Symbol): def __new__(self, name, description='', unit=''): obj = sp.Sym...
29.577982
121
0.633685
4de94382e4e5ac05242ed022a788fb4c86fd4117
68
py
Python
code/abc131_a_08.py
KoyanagiHitoshi/AtCoder
731892543769b5df15254e1f32b756190378d292
[ "MIT" ]
3
2019-08-16T16:55:48.000Z
2021-04-11T10:21:40.000Z
code/abc131_a_08.py
KoyanagiHitoshi/AtCoder
731892543769b5df15254e1f32b756190378d292
[ "MIT" ]
null
null
null
code/abc131_a_08.py
KoyanagiHitoshi/AtCoder
731892543769b5df15254e1f32b756190378d292
[ "MIT" ]
null
null
null
S = input() print("Good" if S[0] != S[1] != S[2] != S[3] else "Bad")
34
56
0.470588
5059c6252ab55977a722bda79ce3504a0f4b849a
2,229
py
Python
tests/integration/modules/test_locale.py
jubrad/salt
7960334fb726cfde45e6409da79a65535c626685
[ "Apache-2.0" ]
1
2021-08-14T13:48:38.000Z
2021-08-14T13:48:38.000Z
tests/integration/modules/test_locale.py
jubrad/salt
7960334fb726cfde45e6409da79a65535c626685
[ "Apache-2.0" ]
3
2015-03-31T14:44:05.000Z
2015-06-18T19:02:24.000Z
tests/integration/modules/test_locale.py
jubrad/salt
7960334fb726cfde45e6409da79a65535c626685
[ "Apache-2.0" ]
1
2020-01-02T09:03:24.000Z
2020-01-02T09:03:24.000Z
# -*- coding: utf-8 -*- # Import Python libs from __future__ import absolute_import # Import Salt Testing libs from tests.support.case import ModuleCase from tests.support.unit import skipIf from tests.support.helpers import ( requires_salt_modules, destructiveTest, ) # Import Salt libs import salt.utils.pla...
36.540984
81
0.688201
665fe1ff135b71ea729362b807eb0b43c23d47f4
7,058
py
Python
feature_engine/imputation/categorical.py
kylegilde/feature_engine
39bc2ff328d7b2eecba0e5d385d603a39992b092
[ "BSD-3-Clause" ]
196
2021-08-06T21:49:52.000Z
2022-03-30T13:59:59.000Z
feature_engine/imputation/categorical.py
kylegilde/feature_engine
39bc2ff328d7b2eecba0e5d385d603a39992b092
[ "BSD-3-Clause" ]
97
2021-08-06T12:03:40.000Z
2022-03-31T06:37:30.000Z
feature_engine/imputation/categorical.py
kylegilde/feature_engine
39bc2ff328d7b2eecba0e5d385d603a39992b092
[ "BSD-3-Clause" ]
28
2021-08-09T12:02:49.000Z
2022-03-28T15:48:06.000Z
# Authors: Soledad Galli <solegalli@protonmail.com> # License: BSD 3 clause from typing import List, Optional, Union import pandas as pd from feature_engine.dataframe_checks import _is_dataframe from feature_engine.imputation.base_imputer import BaseImputer from feature_engine.variable_manipulation import ( _che...
37.743316
88
0.657127
454fcac037f45cec48e244b3260ab9b694ac80a5
6,169
py
Python
nilearn/plotting/glass_brain.py
ctw/nilearn
932eee9c69cd8fbf40ee6af5cee77f8f93b25da3
[ "BSD-2-Clause" ]
null
null
null
nilearn/plotting/glass_brain.py
ctw/nilearn
932eee9c69cd8fbf40ee6af5cee77f8f93b25da3
[ "BSD-2-Clause" ]
null
null
null
nilearn/plotting/glass_brain.py
ctw/nilearn
932eee9c69cd8fbf40ee6af5cee77f8f93b25da3
[ "BSD-2-Clause" ]
null
null
null
""" Brain schematics plotting for glass brain functionality """ import json import os from nilearn.version import _compare_version import matplotlib from matplotlib.path import Path from matplotlib import patches from matplotlib import colors from matplotlib import transforms def _codes_bezier(pts): bezier_num...
32.130208
75
0.59491
7a4b4998cb7c12c22fc0fd2557286d1748d035ad
9,618
py
Python
library/azure_rm_mysqlfirewallrule.py
hmcts/azure_preview_modules
c7bd9a8f11d36e9f2a9875701d34b312dfc34c38
[ "MIT" ]
null
null
null
library/azure_rm_mysqlfirewallrule.py
hmcts/azure_preview_modules
c7bd9a8f11d36e9f2a9875701d34b312dfc34c38
[ "MIT" ]
null
null
null
library/azure_rm_mysqlfirewallrule.py
hmcts/azure_preview_modules
c7bd9a8f11d36e9f2a9875701d34b312dfc34c38
[ "MIT" ]
1
2021-04-10T23:10:06.000Z
2021-04-10T23:10:06.000Z
#!/usr/bin/python # # Copyright (c) 2017 Zim Kalinowski, <zikalino@microsoft.com> # # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) from __future__ import absolute_import, division, print_function __metaclass__ = type ANSIBLE_METADATA = {'metadata_version': '1.1', ...
34.847826
158
0.579226
4129ff0ae5b0e8f7bf6c5d06f935901fc118cf32
1,837
py
Python
Python/phonenumbers/data/region_MG.py
skykisl/uberbruns2
26933efce04dba700d93cc75c7b74e069fb02d26
[ "Unlicense" ]
5
2015-04-27T20:10:56.000Z
2018-06-14T18:19:09.000Z
python/phonenumbers/data/region_MG.py
vemel/python-phonenumbers
595c322bf12106a3b95e3f202e948a7c6b6c15b8
[ "Apache-2.0" ]
2
2017-06-08T16:11:13.000Z
2018-05-07T11:50:13.000Z
python/phonenumbers/data/region_MG.py
vemel/python-phonenumbers
595c322bf12106a3b95e3f202e948a7c6b6c15b8
[ "Apache-2.0" ]
6
2015-02-19T11:11:04.000Z
2022-03-15T19:38:31.000Z
"""Auto-generated file, do not edit by hand. MG metadata""" from ..phonemetadata import NumberFormat, PhoneNumberDesc, PhoneMetadata PHONE_METADATA_MG = PhoneMetadata(id='MG', country_code=261, international_prefix='00', general_desc=PhoneNumberDesc(national_number_pattern='[23]\\d{8}', possible_number_pattern='\\...
87.47619
211
0.757213
7e4c5f0eeafc6fa34687733abccb6dec2a787159
316
py
Python
pyhogs-code/example-scripts/sys_argv_example.py
zszuts/pyhogs.github.io
954fa74487779c07c042981c14a7b1b7f131c991
[ "MIT" ]
null
null
null
pyhogs-code/example-scripts/sys_argv_example.py
zszuts/pyhogs.github.io
954fa74487779c07c042981c14a7b1b7f131c991
[ "MIT" ]
null
null
null
pyhogs-code/example-scripts/sys_argv_example.py
zszuts/pyhogs.github.io
954fa74487779c07c042981c14a7b1b7f131c991
[ "MIT" ]
null
null
null
#!/usr/bin/env/python from __future__ import print_function import sys # Get the total number of arguments total = len(sys.argv) - 1 # Subtract 1 for the script name # Print it print("{:d} arguments passed to the script".format(total)) for i, a in enumerate(sys.argv): print("Argument #{:d}: {} ".format(i, a))
28.727273
58
0.702532
349d854f717ebaba89c67c7134679cae82bc990c
13,477
py
Python
docusign_esign/models/direct_debit_processor_information.py
joekohlsdorf/docusign-esign-python-client
40407544f79c88716d36fabf36f65c3ef1a5c3ba
[ "MIT" ]
58
2017-10-18T23:06:57.000Z
2021-04-15T23:14:58.000Z
docusign_esign/models/direct_debit_processor_information.py
joekohlsdorf/docusign-esign-python-client
40407544f79c88716d36fabf36f65c3ef1a5c3ba
[ "MIT" ]
49
2017-10-27T05:54:09.000Z
2021-04-29T22:06:17.000Z
docusign_esign/models/direct_debit_processor_information.py
joekohlsdorf/docusign-esign-python-client
40407544f79c88716d36fabf36f65c3ef1a5c3ba
[ "MIT" ]
49
2017-09-16T07:23:41.000Z
2021-05-07T20:21:20.000Z
# coding: utf-8 """ DocuSign REST API The DocuSign REST API provides you with a powerful, convenient, and simple Web services API for interacting with DocuSign. # noqa: E501 OpenAPI spec version: v2.1 Contact: devcenter@docusign.com Generated by: https://github.com/swagger-api/swagger-codegen.gi...
31.936019
140
0.634711
df3486a9287acde7f3d9c442f4706758f8fe64c4
15,034
py
Python
scripts/tensor.py
JIC-Image-Analysis/leaf-cell-polarisation-tensors
cf5495a77a0bb77aa99206146267e41995ee5ebd
[ "MIT" ]
null
null
null
scripts/tensor.py
JIC-Image-Analysis/leaf-cell-polarisation-tensors
cf5495a77a0bb77aa99206146267e41995ee5ebd
[ "MIT" ]
null
null
null
scripts/tensor.py
JIC-Image-Analysis/leaf-cell-polarisation-tensors
cf5495a77a0bb77aa99206146267e41995ee5ebd
[ "MIT" ]
null
null
null
"""Module for creating, storing and editing tensors.""" import os import os.path import copy import json import logging from utils import marker_cell_identifier class Tensor(object): """Class for managing individual tensors.""" def __init__(self, tensor_id, centroid, marker, creation_type): self._d...
32.753813
137
0.616735
5cc9fa8de3e6b7f0627ac10c5842116d1fb5e2f0
831
py
Python
benchmark/visualizer.py
gwarmstrong/faiths-pd-benchmarking
c39ca5f07c08d2f829dd89909b029735b4fc2c1e
[ "BSD-3-Clause" ]
1
2022-03-11T20:19:05.000Z
2022-03-11T20:19:05.000Z
benchmark/visualizer.py
knightlab-analyses/faiths-pd-benchmarking
c39ca5f07c08d2f829dd89909b029735b4fc2c1e
[ "BSD-3-Clause" ]
null
null
null
benchmark/visualizer.py
knightlab-analyses/faiths-pd-benchmarking
c39ca5f07c08d2f829dd89909b029735b4fc2c1e
[ "BSD-3-Clause" ]
1
2021-08-28T17:05:58.000Z
2021-08-28T17:05:58.000Z
import seaborn as sns import matplotlib.pyplot as plt import pandas as pd def read_results_table(file_path): return pd.read_csv(file_path, sep='\t', index_col=0) def speed_lineplot(results_table, *args, **kwargs): plot = sns.lineplot(x='num_otus', #plot = sns.pointplot(x='num_otus', y='ti...
28.655172
62
0.626955
77ba464b3cef71909ee912bcdd8af2ba03b74b69
5,060
py
Python
components/electronics/electronics.py
skilkis/KBE
e34ac4aede3e0ab59349fcb467332025b50fa3a2
[ "MIT" ]
6
2019-01-08T13:53:33.000Z
2022-02-25T09:56:46.000Z
components/electronics/electronics.py
skilkis/KBE
e34ac4aede3e0ab59349fcb467332025b50fa3a2
[ "MIT" ]
null
null
null
components/electronics/electronics.py
skilkis/KBE
e34ac4aede3e0ab59349fcb467332025b50fa3a2
[ "MIT" ]
2
2019-03-28T15:06:39.000Z
2022-02-25T09:56:57.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- # Required Modules from parapy.core import * from parapy.geom import * from definitions import * from directories import * from flightcontroller import FlightController from speedcontroller import SpeedController from components import Motor from collections import Iterab...
32.435897
120
0.649605
098c21f0765f7ae9fb0ab86f15cfcabc59cc1fa9
4,057
py
Python
requests/__init__.py
tmshn/requests
a6cd380c640087218695bc7c62311a4843777e43
[ "Apache-2.0" ]
1
2018-10-13T11:41:08.000Z
2018-10-13T11:41:08.000Z
requests/__init__.py
tmshn/requests
a6cd380c640087218695bc7c62311a4843777e43
[ "Apache-2.0" ]
1
2019-02-26T19:23:08.000Z
2019-02-26T19:30:13.000Z
requests/__init__.py
tmshn/requests
a6cd380c640087218695bc7c62311a4843777e43
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # __ # /__) _ _ _ _ _/ _ # / ( (- (/ (/ (- _) / _) # / """ Requests HTTP Library ~~~~~~~~~~~~~~~~~~~~~ Requests is an HTTP library, written in Python, for human beings. Basic GET usage: >>> import requests >>> r = requests.get('https://www.python.org') >>> ...
29.613139
102
0.691644
ef5524dd0906f3813a60ce0d437b4d40c593afb8
8,654
py
Python
typeclasses/objects.py
macorvalan/MyGame
29a14bcb1ffb11b158d325112d5698107d8f1188
[ "Unlicense" ]
null
null
null
typeclasses/objects.py
macorvalan/MyGame
29a14bcb1ffb11b158d325112d5698107d8f1188
[ "Unlicense" ]
null
null
null
typeclasses/objects.py
macorvalan/MyGame
29a14bcb1ffb11b158d325112d5698107d8f1188
[ "Unlicense" ]
null
null
null
""" Object The Object is the "naked" base class for things in the game world. Note that the default Character, Room and Exit does not inherit from this Object, but from their respective default implementations in the evennia library. If you want to use this class as a parent to change the other types, you can do so b...
50.608187
81
0.640744
242de55b9033a2919fd0189ba82c71e658a76431
790
py
Python
utils.py
zhuhegege1995/CryptoDataAPIs
9b48b870f9ad11a088e329599e74023aa36f032f
[ "MIT" ]
null
null
null
utils.py
zhuhegege1995/CryptoDataAPIs
9b48b870f9ad11a088e329599e74023aa36f032f
[ "MIT" ]
null
null
null
utils.py
zhuhegege1995/CryptoDataAPIs
9b48b870f9ad11a088e329599e74023aa36f032f
[ "MIT" ]
null
null
null
from datetime import datetime class TimeManager: def __init__(self): pass @staticmethod def str_to_milliseconds(datetime_str="2020-01-01 08:30:00"): datetime_obj = datetime.strptime(datetime_str, "%Y-%m-%d %H:%M:%S") return TimeManager.datetime_to_milliseconds(datetime...
31.6
96
0.692405
b66b9586c04a0e8c259d70e90a9f89c93cf20bb8
4,183
py
Python
setup.py
MaxChangInnodisk/py2so
367da6a0a371da71489e24c055aedf869cbdec6a
[ "MIT" ]
null
null
null
setup.py
MaxChangInnodisk/py2so
367da6a0a371da71489e24c055aedf869cbdec6a
[ "MIT" ]
null
null
null
setup.py
MaxChangInnodisk/py2so
367da6a0a371da71489e24c055aedf869cbdec6a
[ "MIT" ]
null
null
null
import sys, os, glob, shutil from distutils.core import setup from Cython.Build import cythonize from datetime import datetime, timezone, timedelta # we'd better have Cython installed, or it's a no-go try: from Cython.Distutils import build_ext except: print("You don't seem to have Cython installed. Please get...
37.017699
131
0.632799
fa0277d57a4697b4424a68f88b14c189986c6989
9,859
py
Python
tests/test_augmentations.py
GeorgeMironov/albumentations
fe3f36a0285bce9abb6496c410ba672f53f15be6
[ "MIT" ]
5
2019-04-22T11:43:18.000Z
2019-11-17T01:59:37.000Z
tests/test_augmentations.py
GeorgeMironov/albumentations
fe3f36a0285bce9abb6496c410ba672f53f15be6
[ "MIT" ]
null
null
null
tests/test_augmentations.py
GeorgeMironov/albumentations
fe3f36a0285bce9abb6496c410ba672f53f15be6
[ "MIT" ]
null
null
null
import pytest import numpy as np try: import torch import torchvision from albumentations.torch import ToTensor torch_available = True except ImportError: torch_available = False from albumentations import RandomCrop, PadIfNeeded, VerticalFlip, HorizontalFlip, Flip, Transpose, RandomRotate90, \ ...
30.809375
117
0.61771
180ba78ab1781a35af18617e7ad29e4fc55f24c4
13,889
py
Python
zaqar/tests/unit/transport/wsgi/v2_0/test_flavors.py
mail2nsrajesh/zaqar
a68a03a228732050b33c2a7f35d1caa9f3467718
[ "Apache-2.0" ]
null
null
null
zaqar/tests/unit/transport/wsgi/v2_0/test_flavors.py
mail2nsrajesh/zaqar
a68a03a228732050b33c2a7f35d1caa9f3467718
[ "Apache-2.0" ]
null
null
null
zaqar/tests/unit/transport/wsgi/v2_0/test_flavors.py
mail2nsrajesh/zaqar
a68a03a228732050b33c2a7f35d1caa9f3467718
[ "Apache-2.0" ]
null
null
null
# Copyright (c) 2014 Red Hat, Inc. # # 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 wri...
39.91092
79
0.637123
4340361faab9213dcd982b19cad8a3ea62005194
1,749
py
Python
ebayoauthclient/model/util.py
hosseinamin/ebay-oauth-python-client
2ab07a58ea9a0f0544a6742d1e6003e8c9348830
[ "Apache-2.0" ]
42
2019-04-22T18:03:14.000Z
2021-12-17T10:39:05.000Z
ebayoauthclient/model/util.py
hosseinamin/ebay-oauth-python-client
2ab07a58ea9a0f0544a6742d1e6003e8c9348830
[ "Apache-2.0" ]
9
2019-08-22T07:40:45.000Z
2022-03-03T17:13:30.000Z
ebayoauthclient/model/util.py
hosseinamin/ebay-oauth-python-client
2ab07a58ea9a0f0544a6742d1e6003e8c9348830
[ "Apache-2.0" ]
43
2019-06-24T02:39:25.000Z
2022-02-18T00:44:31.000Z
# -*- coding: utf-8 -*- """ Copyright 2019 eBay Inc. 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 ag...
28.672131
101
0.65809
32d9b3739241f05fe20ff8f0a2100a8b95dda9a7
168
py
Python
common_migration/tests/migration_files/new/central/migrations/0004_hide.py
Wazoku/django-common-migration
51bbb4d3a5a5c76fc5dcf569da9eb7751b82c9eb
[ "BSD-2-Clause" ]
1
2021-06-03T13:49:50.000Z
2021-06-03T13:49:50.000Z
common_migration/tests/migration_files/old/central/migrations/0004_hide.py
Wazoku/django-common-migration
51bbb4d3a5a5c76fc5dcf569da9eb7751b82c9eb
[ "BSD-2-Clause" ]
1
2020-11-20T09:17:47.000Z
2020-11-20T09:17:47.000Z
common_migration/tests/migration_files/old/central/migrations/0004_hide.py
Wazoku/django-common-migration
51bbb4d3a5a5c76fc5dcf569da9eb7751b82c9eb
[ "BSD-2-Clause" ]
1
2020-11-16T16:09:22.000Z
2020-11-16T16:09:22.000Z
from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('central', '0003_stage_team'), ] operations = [ ]
14
39
0.625
5c63aa84655d0806adff7f6d712e966cd309cdf0
6,530
py
Python
liff/liff.py
CyberTKR/Simple-LINELIB
8596afb6b201b13675a0ed6314b3151f6bbf208b
[ "BSD-3-Clause" ]
4
2022-02-20T11:27:29.000Z
2022-03-05T00:50:05.000Z
liff/liff.py
CyberTKR/Simple-LINELIB
8596afb6b201b13675a0ed6314b3151f6bbf208b
[ "BSD-3-Clause" ]
null
null
null
liff/liff.py
CyberTKR/Simple-LINELIB
8596afb6b201b13675a0ed6314b3151f6bbf208b
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- from akad.ttypes import ( LiffViewRequest, LiffContext, LiffChatContext, LiffSquareChatContext, RevokeTokenRequest, LiffException, ) import requests, json, time def loggedIn(func): def checkLogin(*args, **kwargs): if args[0].isLogin: return func(*...
38.869048
199
0.575498
e62f703ad42c8301b19738f1cf2618a32d7a3328
235
py
Python
map.py
DFrye333/DynamicMaze
aefc751f67c39d86a8efd747260366f86f42b5c3
[ "MIT" ]
null
null
null
map.py
DFrye333/DynamicMaze
aefc751f67c39d86a8efd747260366f86f42b5c3
[ "MIT" ]
null
null
null
map.py
DFrye333/DynamicMaze
aefc751f67c39d86a8efd747260366f86f42b5c3
[ "MIT" ]
null
null
null
''' Module: map Author: David Frye Description: Contains the Map class. ''' import maze import player class Map: ''' ''' def __init__(self, maze=Maze(), player=Player()): ''' ''' self.m_maze = maze self.m_player = player
12.368421
50
0.642553
e9984170515d2421abeadc61bd7024b04d076b2a
2,702
py
Python
nikola/plugins/compile/bbcode.py
Proteus-tech/nikola
2862a8c6bf80709d69b1cb344c8ae8b73c29b353
[ "MIT" ]
null
null
null
nikola/plugins/compile/bbcode.py
Proteus-tech/nikola
2862a8c6bf80709d69b1cb344c8ae8b73c29b353
[ "MIT" ]
1
2019-08-18T13:37:20.000Z
2019-08-18T16:09:08.000Z
nikola/plugins/compile/bbcode.py
Proteus-tech/nikola
2862a8c6bf80709d69b1cb344c8ae8b73c29b353
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright © 2012-2013 Roberto Alsina and others. # 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 t...
35.090909
72
0.65507
e1677d44b29b5665f42cfa0f83728ac0cb837b37
171
py
Python
app.py
yackoa/flask_sandbox
3ceb32f7d73accc7c360ec02d47b2158abe37573
[ "MIT" ]
null
null
null
app.py
yackoa/flask_sandbox
3ceb32f7d73accc7c360ec02d47b2158abe37573
[ "MIT" ]
null
null
null
app.py
yackoa/flask_sandbox
3ceb32f7d73accc7c360ec02d47b2158abe37573
[ "MIT" ]
null
null
null
from flask import Flask app = Flask(__name__) @app.route("/api/v1/hello") def print_hello(): return "hello world" if __name__== '__main__': app.run(debug=True)
15.545455
27
0.684211
bfa4b1faa5b2320e57ef5ac7533ea2ca19d4cef7
12,052
py
Python
pi-series/scenes.py
TravorLZH/math-videos
023ed0b4a4c3c078a9a26d302d86e3021f7577a1
[ "MIT" ]
3
2020-01-18T22:45:08.000Z
2021-10-18T09:03:08.000Z
pi-series/scenes.py
TravorLZH/math-videos
023ed0b4a4c3c078a9a26d302d86e3021f7577a1
[ "MIT" ]
null
null
null
pi-series/scenes.py
TravorLZH/math-videos
023ed0b4a4c3c078a9a26d302d86e3021f7577a1
[ "MIT" ]
1
2020-01-18T22:45:25.000Z
2020-01-18T22:45:25.000Z
from manimlib.imports import * import numpy as np class PiSeriesIntro(Scene): def construct(self): pi_logo=TexMobject(r"\pi",color=BLUE).scale(10) pi_title=TextMobject(r"How to create a series for", tex_to_color_map={ "Create":GREEN, "series":YELLOW, ...
38.018927
82
0.538998
c543d4a29a9b248384d37a86b7f02c7c7894fd95
1,158
py
Python
B/test_pasted_from_page.py
staguchi0703/ABC175
17fdd070a5fbba7dab9b13edfe5d29df7fb6806f
[ "MIT" ]
null
null
null
B/test_pasted_from_page.py
staguchi0703/ABC175
17fdd070a5fbba7dab9b13edfe5d29df7fb6806f
[ "MIT" ]
null
null
null
B/test_pasted_from_page.py
staguchi0703/ABC175
17fdd070a5fbba7dab9b13edfe5d29df7fb6806f
[ "MIT" ]
null
null
null
# from resolve import resolve #################################### #################################### # 以下にプラグインの内容をペーストする # import sys from io import StringIO import unittest class TestClass(unittest.TestCase): def assertIO(self, input, output): stdout, stdin = sys.stdout, sys.stdin sys.stdou...
22.269231
59
0.503454
73b3c59b3b488073c5ffb63a0c9ae044e8f34b26
3,317
py
Python
Driving/gen_gauge.py
maligulzar/deepxplore-CS239
56168e1d80c926620350843da08d10d1ed8752a0
[ "MIT" ]
1
2022-01-10T16:38:52.000Z
2022-01-10T16:38:52.000Z
Driving/gen_gauge.py
maligulzar/deepxplore-CS239
56168e1d80c926620350843da08d10d1ed8752a0
[ "MIT" ]
null
null
null
Driving/gen_gauge.py
maligulzar/deepxplore-CS239
56168e1d80c926620350843da08d10d1ed8752a0
[ "MIT" ]
3
2019-04-04T16:39:43.000Z
2021-08-25T13:15:17.000Z
''' usage: python gen_diff.py -h ''' from __future__ import print_function import argparse from scipy.misc import imsave from driving_models import * from utils import * import pickle parser = argparse.ArgumentParser( description='Main function for difference-inducing input generation in Driving dataset') par...
34.915789
112
0.677118
b84ce894a6fd8905e1acdbc44bdd1b0033cf1b2b
414
py
Python
trinity/tools/factories/common.py
dendisuhubdy/trinity
001664781259c7dd0779a0ef6f822451b608ded4
[ "MIT" ]
1
2021-04-07T07:33:28.000Z
2021-04-07T07:33:28.000Z
trinity/tools/factories/common.py
dendisuhubdy/trinity
001664781259c7dd0779a0ef6f822451b608ded4
[ "MIT" ]
2
2019-04-30T06:22:12.000Z
2019-06-14T04:27:18.000Z
trinity/tools/factories/common.py
dendisuhubdy/trinity
001664781259c7dd0779a0ef6f822451b608ded4
[ "MIT" ]
null
null
null
try: import factory except ImportError: raise ImportError( "The p2p.tools.factories module requires the `factory_boy` and `faker` libraries." ) from trinity.protocol.common.payloads import BlockHeadersQuery class BlockHeadersQueryFactory(factory.Factory): class Meta: model = BlockHe...
19.714286
90
0.710145