hexsha
stringlengths
40
40
size
int64
5
2.06M
ext
stringclasses
11 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
3
251
max_stars_repo_name
stringlengths
4
130
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
3
251
max_issues_repo_name
stringlengths
4
130
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
116k
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
251
max_forks_repo_name
stringlengths
4
130
max_forks_repo_head_hexsha
stringlengths
40
78
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
1
1.05M
avg_line_length
float64
1
1.02M
max_line_length
int64
3
1.04M
alphanum_fraction
float64
0
1
c63f482692dd12b350a874c1c7c682e900b1dc60
2,672
py
Python
mt_driver_train.py
pulkit10251/Machine-Translation
61eeea8d28702167c80ee3c75c42fd51165db310
[ "Apache-2.0" ]
null
null
null
mt_driver_train.py
pulkit10251/Machine-Translation
61eeea8d28702167c80ee3c75c42fd51165db310
[ "Apache-2.0" ]
null
null
null
mt_driver_train.py
pulkit10251/Machine-Translation
61eeea8d28702167c80ee3c75c42fd51165db310
[ "Apache-2.0" ]
null
null
null
from factoryModel.config import mt_config as confFile from factoryModel.preprocessing import SentenceSplit, cleanData, TrainMaker, Embedding from factoryModel.dataLoaders import textLoader from factoryModel.models import ModelBuilding from tensorflow.keras.callbacks import ModelCheckpoint from tensorflow.keras.models i...
38.171429
215
0.834955
c63fc87211a0b0ac8dafc9a918fe1b9060f2bfe9
4,357
py
Python
backend/app/templates/processor.py
joparram/openDataCleaner
527fac1a830142fc05cb3f99509d042a8bcea549
[ "Apache-2.0" ]
null
null
null
backend/app/templates/processor.py
joparram/openDataCleaner
527fac1a830142fc05cb3f99509d042a8bcea549
[ "Apache-2.0" ]
9
2020-12-22T10:24:29.000Z
2020-12-23T13:38:56.000Z
backend/app/templates/processor.py
joparram/openDataCleaner
527fac1a830142fc05cb3f99509d042a8bcea549
[ "Apache-2.0" ]
null
null
null
from ..api import _v1 from pathlib import Path from app.error import Error import pandas as pd from app.components._data import dataframeHandler import numpy as np from sklearn.impute import KNNImputer from sklearn import preprocessing # ** ALL CONTENT COMENTED BETWEEN ASTERISCS MUST BE EDITED ** # ** Set the plugin ...
41.894231
163
0.631168
c64370f69c25b4b6ed9e2699666db61f7d61acc5
224
py
Python
bin/dist.py
soloproyectos-ts/matrix2
0f3713fbf45285ac35eb206dd0a091057c27405f
[ "MIT" ]
null
null
null
bin/dist.py
soloproyectos-ts/matrix2
0f3713fbf45285ac35eb206dd0a091057c27405f
[ "MIT" ]
null
null
null
bin/dist.py
soloproyectos-ts/matrix2
0f3713fbf45285ac35eb206dd0a091057c27405f
[ "MIT" ]
null
null
null
#!/usr/bin/env python """Creates or updates distribution files""" import subprocess print "Updates JavaScript and Type Definition files..." subprocess.call(['rm', 'dist', '-rf']) subprocess.call(['tsc', '--declaration'])
22.4
55
0.705357
c643e8c05150782afcd3003ad500909907489985
4,582
py
Python
capture.py
LEON6156SCOTT/Hand-Cricket
c5d66538446880966964eadc58e39fe03aecd1fc
[ "MIT" ]
3
2021-01-31T04:48:53.000Z
2021-02-17T05:15:10.000Z
capture.py
dpatel-8112/hand-cricket
e88dff33e2215c5e8a73690ce06b7c86309fd54d
[ "MIT" ]
null
null
null
capture.py
dpatel-8112/hand-cricket
e88dff33e2215c5e8a73690ce06b7c86309fd54d
[ "MIT" ]
3
2021-01-31T04:49:09.000Z
2021-05-03T15:59:48.000Z
import cv2 as cv import numpy as np import matplotlib.pyplot as plt import os
29.947712
103
0.410956
c6441687b7423cdb48a5dd89e58d428eb7ef3820
10,821
py
Python
tasks/islands.py
rampasek/HGNet
c6cc10d413270bde737d088cf2f0f66d8529abf3
[ "MIT" ]
10
2021-07-15T13:41:21.000Z
2022-03-11T12:59:42.000Z
tasks/islands.py
rampasek/HGNet
c6cc10d413270bde737d088cf2f0f66d8529abf3
[ "MIT" ]
null
null
null
tasks/islands.py
rampasek/HGNet
c6cc10d413270bde737d088cf2f0f66d8529abf3
[ "MIT" ]
null
null
null
import matplotlib.pyplot as plt import networkx as nx import numpy as np def read_graph_from_file(filename): num_nodes, num_edges = None, None edges = [] with open(filename, 'r') as f: for line in f: if num_nodes is None: # the first line of the file num_nodes, num_e...
34.906452
122
0.563811
c64493752d6819c758de070d0748122ddfa77926
12,136
py
Python
macdaily/core/brew.py
JarryShaw/MacDaily
853b841dd1f1f7e6aae7bf2c305ff008bc76055c
[ "BSD-3-Clause" ]
10
2018-09-20T19:57:56.000Z
2021-11-14T18:28:10.000Z
macdaily/core/brew.py
JarryShaw/jsdaily
3ca7aa7c75a12dc08ab44f78af2b089e1ed41d3d
[ "BSD-3-Clause" ]
2
2020-05-31T08:49:47.000Z
2021-12-28T16:57:42.000Z
macdaily/core/brew.py
JarryShaw/MacDaily
853b841dd1f1f7e6aae7bf2c305ff008bc76055c
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- import abc import contextlib import glob import os import re import shutil import sys import traceback from macdaily.cls.command import Command from macdaily.util.compat import pathlib, subprocess from macdaily.util.const.term import (bold, flash, green, purple_bg, red, red_bg, reset, under, ...
41.419795
136
0.553395
c644f0ddcd2301b8bf29ad85fabec4ff05aa6d7d
576
py
Python
wagtail_blog/admin.py
pizzapanther/wagtail-blog-app
ba8984a9ab7ff7d91927ba70b85bec40c3dbc025
[ "MIT" ]
null
null
null
wagtail_blog/admin.py
pizzapanther/wagtail-blog-app
ba8984a9ab7ff7d91927ba70b85bec40c3dbc025
[ "MIT" ]
null
null
null
wagtail_blog/admin.py
pizzapanther/wagtail-blog-app
ba8984a9ab7ff7d91927ba70b85bec40c3dbc025
[ "MIT" ]
null
null
null
from wagtail.admin.edit_handlers import FieldPanel from wagtail.images.edit_handlers import ImageChooserPanel from wagtail_blog.models import BlogPage, BlogIndexPage # Add your Wagtail panels here. BlogIndexPage.content_panels = [ FieldPanel('title', classname="full title"), FieldPanel('headline'), ] BlogPa...
26.181818
58
0.732639
c6471cf21e085429384f240ab5d07f728b47b354
35,664
py
Python
test/kb_Amplicon_server_2_test.py
Tianhao-Gu/kb_Amplicon
34ed79f44bd69ea3755dd6cc3c659d216522408e
[ "MIT" ]
null
null
null
test/kb_Amplicon_server_2_test.py
Tianhao-Gu/kb_Amplicon
34ed79f44bd69ea3755dd6cc3c659d216522408e
[ "MIT" ]
6
2021-11-10T02:45:51.000Z
2022-02-19T03:41:20.000Z
test/kb_Amplicon_server_2_test.py
Tianhao-Gu/kb_Amplicon
34ed79f44bd69ea3755dd6cc3c659d216522408e
[ "MIT" ]
1
2021-11-09T20:10:09.000Z
2021-11-09T20:10:09.000Z
# -*- coding: utf-8 -*- import os import time import unittest import inspect from mock import patch import requests from configparser import ConfigParser from kb_Amplicon.kb_AmpliconImpl import kb_Amplicon from kb_Amplicon.kb_AmpliconServer import MethodContext from installed_clients.authclient import KBaseAuth as _KB...
50.731152
98
0.561519
c648d8fd74da259a86ffa3550e7915f6fc46a110
507
py
Python
maxcube/thermostat.py
copyrights/python-maxcube-api
b933c11b00e335120729fb46e66b63baa273fbc0
[ "MIT" ]
2
2020-09-28T05:57:11.000Z
2021-03-12T14:32:53.000Z
maxcube/thermostat.py
copyrights/python-maxcube-api
b933c11b00e335120729fb46e66b63baa273fbc0
[ "MIT" ]
null
null
null
maxcube/thermostat.py
copyrights/python-maxcube-api
b933c11b00e335120729fb46e66b63baa273fbc0
[ "MIT" ]
1
2021-03-14T13:53:52.000Z
2021-03-14T13:53:52.000Z
from maxcube.wallthermostat import MaxWallThermostat
31.6875
52
0.696252
c649dc4595c9480a761243a1c0ec1cc44641dc1f
4,179
py
Python
aio_graphite_api/carbon/pool.py
yunstanford/aio-graphite-api
819b82c451c23ce5928e711202bde79a5399c3da
[ "Apache-2.0" ]
1
2016-12-09T04:14:16.000Z
2016-12-09T04:14:16.000Z
aio_graphite_api/carbon/pool.py
yunstanford/aio-graphite-api
819b82c451c23ce5928e711202bde79a5399c3da
[ "Apache-2.0" ]
1
2017-02-06T22:15:07.000Z
2017-02-06T23:01:04.000Z
aio_graphite_api/carbon/pool.py
yunstanford/aio-graphite-api
819b82c451c23ce5928e711202bde79a5399c3da
[ "Apache-2.0" ]
null
null
null
import asyncio import random from aio_graphite_web.hashing.keyfunc import key_func from aio_graphite_web.hashing.hashingring import ConsistentHashRing from .connection import CarbonConn def _parse_hosts_and_ports(self, carbon_hosts): """ Example: 127.0.0.1:7003:a () """ ...
29.429577
94
0.56425
c64c4f277af041d8aeb16dbe3c13bb988f53c35b
27,520
py
Python
explore/helper_functions.py
polosecki/ton_rfmri_repo
bfa0313c83865045bd0fb36ec43349164b065f69
[ "BSD-3-Clause" ]
1
2020-07-14T15:21:27.000Z
2020-07-14T15:21:27.000Z
explore/helper_functions.py
polosecki/ton_rfmri_repo
bfa0313c83865045bd0fb36ec43349164b065f69
[ "BSD-3-Clause" ]
null
null
null
explore/helper_functions.py
polosecki/ton_rfmri_repo
bfa0313c83865045bd0fb36ec43349164b065f69
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- """ Helper functions to organize CHDI imaging data Created on Fri Jan 15 11:07:53 2016 @author: Pablo Polosecki Python Version: Python 3.5.1 |Anaconda 2.4.1 (64-bit) """ import glob as gl import pandas as pd import numpy as np import os from functools import partial def scan_year(visit, stud...
42.866044
94
0.546621
c64d5aefda831f460240cc7efaa87ebfc9ade60c
5,514
py
Python
DLA Lorenzo/Walker.py
Naroloal/dlaCluster
0a0990e332068670069ed5a2621cf25c9065c0c6
[ "MIT" ]
null
null
null
DLA Lorenzo/Walker.py
Naroloal/dlaCluster
0a0990e332068670069ed5a2621cf25c9065c0c6
[ "MIT" ]
null
null
null
DLA Lorenzo/Walker.py
Naroloal/dlaCluster
0a0990e332068670069ed5a2621cf25c9065c0c6
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Fri Nov 30 10:57:10 2018 @author: lorenzo """ import numpy as np import matplotlib.pyplot as plt from matplotlib import colors import imageio import os import time import pickle import copy as cp start = time.time() Radio = 80#Tamanio de la red Tamanio = in...
38.027586
311
0.589046
c64e11a98e45581f789ae12c34c82c81fafbec85
183
py
Python
Python/Ex013.py
renato-rt/Python
ba033094e1da5b55cf9ce4c8a5cf2cd90247db36
[ "MIT" ]
null
null
null
Python/Ex013.py
renato-rt/Python
ba033094e1da5b55cf9ce4c8a5cf2cd90247db36
[ "MIT" ]
null
null
null
Python/Ex013.py
renato-rt/Python
ba033094e1da5b55cf9ce4c8a5cf2cd90247db36
[ "MIT" ]
1
2021-11-30T17:34:33.000Z
2021-11-30T17:34:33.000Z
s = float(input('\033[1;24;3mQual o salrio do funcionrio? \033[m')) print('Um funcionrio que ganhava R${:.2f} com 15% de aumento agora ganhar R${:.2f}.'.format(s, s+(s*15/100)))
91.5
111
0.672131
c64ebda6bcd0d45c5627cb3fe84e1a39f78d0dcd
7,064
py
Python
t128_aap_logscanner.py
rshtirmer/aap_log_scanner
e109daa8209e9cd598324f340ecb4bfa60d97fde
[ "MIT" ]
1
2021-07-20T18:05:55.000Z
2021-07-20T18:05:55.000Z
t128_aap_logscanner.py
rshtirmer/aap_log_scanner
e109daa8209e9cd598324f340ecb4bfa60d97fde
[ "MIT" ]
null
null
null
t128_aap_logscanner.py
rshtirmer/aap_log_scanner
e109daa8209e9cd598324f340ecb4bfa60d97fde
[ "MIT" ]
null
null
null
import sys import os import requests from datetime import datetime, timedelta import argparse import json files = ["t128_aap.1.log", "t128_aap.log"] patterns = ["Attempting to add config for stores", "Attempting to remove route filter for these stores"] if __name__== "__main__": main()
34.970297
302
0.609287
c64f1dc22175bdb827ddb012fc48215e9e45a903
1,719
py
Python
ondewo/t2s/client/services/text_to_speech.py
ondewo/ondewo-t2s-client-python
c580c934c7e0e703f81bbddeee3831919fd5f0a2
[ "Apache-2.0" ]
null
null
null
ondewo/t2s/client/services/text_to_speech.py
ondewo/ondewo-t2s-client-python
c580c934c7e0e703f81bbddeee3831919fd5f0a2
[ "Apache-2.0" ]
null
null
null
ondewo/t2s/client/services/text_to_speech.py
ondewo/ondewo-t2s-client-python
c580c934c7e0e703f81bbddeee3831919fd5f0a2
[ "Apache-2.0" ]
null
null
null
from google.protobuf.empty_pb2 import Empty from ondewo.utils.base_services_interface import BaseServicesInterface from ondewo.t2s.text_to_speech_pb2 import ( ListT2sPipelinesRequest, ListT2sPipelinesResponse, SynthesizeRequest, SynthesizeResponse, T2sPipelineId, Text2SpeechConfig, ) from ondew...
34.38
95
0.745782
c64f2ead205e047db3ac675807a272541e170338
451
py
Python
BMI.py
wangwanglulu/python2
71ba58b188a2a05a633566c931555da961b3b63e
[ "MIT" ]
1
2020-07-27T23:11:19.000Z
2020-07-27T23:11:19.000Z
BMI.py
wangwanglulu/python2
71ba58b188a2a05a633566c931555da961b3b63e
[ "MIT" ]
null
null
null
BMI.py
wangwanglulu/python2
71ba58b188a2a05a633566c931555da961b3b63e
[ "MIT" ]
null
null
null
print("BMI\n") inp_1 = input('(kg):\n') inp_2 = input('(cm):\n') try: weight = float(inp_1) except: print('Please enter a number') try: height = float(inp_2) except: print('Please enter a number') BMI = weight/(height/100)**2 if BMI<18.5: print("") elif BMI<24 and BMI>=18.5: print("") elif BMI<28 and ...
20.5
34
0.654102
c64f55716ff3ebdc7f9eb5cc702e60a1b4447f4f
9,793
py
Python
SMFSWcolor/colCIELab.py
SMFSW/SMFSWcolor
a158bfc0f2ccc2bd2dfb1d68028b804e3dcc5117
[ "BSD-3-Clause" ]
null
null
null
SMFSWcolor/colCIELab.py
SMFSW/SMFSWcolor
a158bfc0f2ccc2bd2dfb1d68028b804e3dcc5117
[ "BSD-3-Clause" ]
null
null
null
SMFSWcolor/colCIELab.py
SMFSW/SMFSWcolor
a158bfc0f2ccc2bd2dfb1d68028b804e3dcc5117
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- """ colCIEObsLab.py Author: SMFSW Copyright (c) 2016-2021 SMFSW Description: CIE-L*ab color space class """ from math import * from colorConv import * from colBase import ColBase as cB from colorFuncs import ColorChecker import colCIELCHab as cCIELCHab import colXYZ as cXYZ if __name__ == ...
37.810811
113
0.499847
c6509454f8ee4295dfb01cbdb4b9e84ff49bf2a1
52
py
Python
setup.py
piotrantosz/siege-engine
aca9193aa72d9b899bef4da613b99e75136f49b1
[ "MIT" ]
null
null
null
setup.py
piotrantosz/siege-engine
aca9193aa72d9b899bef4da613b99e75136f49b1
[ "MIT" ]
null
null
null
setup.py
piotrantosz/siege-engine
aca9193aa72d9b899bef4da613b99e75136f49b1
[ "MIT" ]
null
null
null
from setuptools import setup setup(version='1.5')
10.4
28
0.75
c6540ea94ce0990b9d2edbebbc960a355956e134
1,638
py
Python
draw fractal/Fern/Fern__PIL.py
DazEB2/SimplePyScripts
1dde0a42ba93fe89609855d6db8af1c63b1ab7cc
[ "CC-BY-4.0" ]
117
2015-12-18T07:18:27.000Z
2022-03-28T00:25:54.000Z
draw fractal/Fern/Fern__PIL.py
DazEB2/SimplePyScripts
1dde0a42ba93fe89609855d6db8af1c63b1ab7cc
[ "CC-BY-4.0" ]
8
2018-10-03T09:38:46.000Z
2021-12-13T19:51:09.000Z
draw fractal/Fern/Fern__PIL.py
DazEB2/SimplePyScripts
1dde0a42ba93fe89609855d6db8af1c63b1ab7cc
[ "CC-BY-4.0" ]
28
2016-08-02T17:43:47.000Z
2022-03-21T08:31:12.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- __author__ = 'ipetrash' """ / Fern """ # : http://www.cyberforum.ru/pascalabc/thread994987.html # uses GraphABC,Utils; # # const # n=255; # max=10; # # var # x,y,x1,y1,cx,cy: real; # i,ix,iy: integer; # // z=z^2+c # begin # SetWindowCaption(': '); # SetW...
20.475
66
0.5
c654ac6a8e3810439a710fb8c2a9a5ed154d3f1c
5,304
py
Python
PyPowerFlex/objects/system.py
dell/python-powerflex
8167377756f7dfcbf72dc6dceb1c7f7cb8784ed0
[ "Apache-2.0" ]
5
2021-01-28T14:27:04.000Z
2021-07-07T16:02:31.000Z
PyPowerFlex/objects/system.py
dell/python-powerflex
8167377756f7dfcbf72dc6dceb1c7f7cb8784ed0
[ "Apache-2.0" ]
1
2021-09-16T09:44:11.000Z
2021-09-16T09:44:11.000Z
PyPowerFlex/objects/system.py
dell/python-powerflex
8167377756f7dfcbf72dc6dceb1c7f7cb8784ed0
[ "Apache-2.0" ]
2
2021-01-01T21:07:59.000Z
2021-09-17T14:16:28.000Z
# Copyright (c) 2020 Dell Inc. or its subsidiaries. # 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 requi...
33.783439
77
0.550339
c654f5ae59070403ebdc7935ff1f233ada73a274
10,928
py
Python
cube.py
allala0/rubiks-cube.py
763093b455566ffcf8fa86262d42c81093b2a3ab
[ "MIT" ]
1
2022-02-11T20:25:30.000Z
2022-02-11T20:25:30.000Z
cube.py
allala0/rubiks-cube.py
763093b455566ffcf8fa86262d42c81093b2a3ab
[ "MIT" ]
null
null
null
cube.py
allala0/rubiks-cube.py
763093b455566ffcf8fa86262d42c81093b2a3ab
[ "MIT" ]
null
null
null
import copy import random from termcolor import colored from colorama import init # colorama init init()
42.854902
115
0.408858
c6552fec5dddcac5e5cc8d95e1a81f16cf186dbf
149
py
Python
adrian/cgen/includes.py
adrian-lang/paka.cgen
bedb7ebf559c03c732b48a6d018bacaca0bc343e
[ "BSD-3-Clause" ]
1
2017-03-31T14:56:23.000Z
2017-03-31T14:56:23.000Z
adrian/cgen/includes.py
adrian-lang/paka.cgen
bedb7ebf559c03c732b48a6d018bacaca0bc343e
[ "BSD-3-Clause" ]
null
null
null
adrian/cgen/includes.py
adrian-lang/paka.cgen
bedb7ebf559c03c732b48a6d018bacaca0bc343e
[ "BSD-3-Clause" ]
null
null
null
from adrian.cgen import Include stdlib = Include("stdlib.h") stdint = Include("stdint.h") stdio = Include("stdio.h") assert_ = Include("assert.h")
18.625
31
0.711409
c65871b38acc227abc7a75c247d2cc76f142300f
1,722
py
Python
gg/game.py
willieLjohnson/pygg
b204e4b6ab01a5156f7b38e99e8077875d038c86
[ "MIT" ]
null
null
null
gg/game.py
willieLjohnson/pygg
b204e4b6ab01a5156f7b38e99e8077875d038c86
[ "MIT" ]
null
null
null
gg/game.py
willieLjohnson/pygg
b204e4b6ab01a5156f7b38e99e8077875d038c86
[ "MIT" ]
null
null
null
from dataclasses import dataclass import pygame import pymunk import pymunk.pygame_util from . import style from . import display from . import structures
27.774194
133
0.598142
c6590aaf2d2dffbad1dc3622668b97cfa3f432d8
834
py
Python
notebooks/src/code/__init__.py
verdimrc/amazon-textract-transformer-pipeline
f3ae99ec3b8808d9edf7bc5ac003494cf1548293
[ "MIT-0" ]
22
2021-11-10T17:16:10.000Z
2022-03-31T19:39:50.000Z
notebooks/src/code/__init__.py
verdimrc/amazon-textract-transformer-pipeline
f3ae99ec3b8808d9edf7bc5ac003494cf1548293
[ "MIT-0" ]
4
2021-11-03T03:45:51.000Z
2022-01-28T03:30:57.000Z
notebooks/src/code/__init__.py
verdimrc/amazon-textract-transformer-pipeline
f3ae99ec3b8808d9edf7bc5ac003494cf1548293
[ "MIT-0" ]
4
2021-12-14T22:41:40.000Z
2022-02-04T15:30:10.000Z
# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. # SPDX-License-Identifier: MIT-0 """Amazon Textract + LayoutLM model training and inference code package for SageMaker Why the extra level of nesting? Because the src folder (even if __init__ is present) is not loaded as a Python module during traini...
55.6
98
0.780576
d65d0c73215abff7c88e992f9d59aa792ae03fe9
968
py
Python
porcupine/dirs.py
rscales02/porcupine
91b3c90d19d2291c0a60ddb9dffac931147cde3c
[ "MIT" ]
null
null
null
porcupine/dirs.py
rscales02/porcupine
91b3c90d19d2291c0a60ddb9dffac931147cde3c
[ "MIT" ]
null
null
null
porcupine/dirs.py
rscales02/porcupine
91b3c90d19d2291c0a60ddb9dffac931147cde3c
[ "MIT" ]
null
null
null
# TODO: move this to __init__.py? this was in a separate file because # setup.py used to import porcupine but it doesn't do it anymore import os import platform import appdirs from porcupine import __author__ as _author if platform.system() in {'Windows', 'Darwin'}: # these platforms like path names like "Prog...
29.333333
73
0.743802
d65d91b8a2397d7feb79871e5a4342930d4bd9bd
3,903
py
Python
parser.py
Darksidis/justiva-script
439368e3be677c6551d5d077c24dc5f6d10cafc0
[ "Apache-2.0" ]
null
null
null
parser.py
Darksidis/justiva-script
439368e3be677c6551d5d077c24dc5f6d10cafc0
[ "Apache-2.0" ]
null
null
null
parser.py
Darksidis/justiva-script
439368e3be677c6551d5d077c24dc5f6d10cafc0
[ "Apache-2.0" ]
null
null
null
import re import requests from bs4 import BeautifulSoup import urllib3 import schedule import time import regexp as r from const import login, password urllib3.disable_warnings() s = requests.Session() LOGIN_URL = 'https://justiva.ru/login' headers = { 'accept': 'text/html,application/xhtml+xml,application/xml'...
30.732283
124
0.611325
d65eb69cc6131a1ea66929f067f402bb71f7ee53
11,355
py
Python
vnpy/app/cta_strategy/strategies/tsmyo_orb_strategy.py
TheSuperMyo/vnpy
e38b7f4de879f1756aa664d5dfe7e0bec65c9a1b
[ "MIT" ]
null
null
null
vnpy/app/cta_strategy/strategies/tsmyo_orb_strategy.py
TheSuperMyo/vnpy
e38b7f4de879f1756aa664d5dfe7e0bec65c9a1b
[ "MIT" ]
null
null
null
vnpy/app/cta_strategy/strategies/tsmyo_orb_strategy.py
TheSuperMyo/vnpy
e38b7f4de879f1756aa664d5dfe7e0bec65c9a1b
[ "MIT" ]
null
null
null
from datetime import time from vnpy.app.cta_strategy import ( CtaTemplate, StopOrder, TickData, BarData, TradeData, OrderData, BarGenerator, ArrayManager ) from vnpy.app.cta_strategy.base import ( EngineType, STOPORDER_PREFIX, StopOrder, StopOrderStatus, ) from vnpy.app.c...
34.724771
127
0.536856
d65f018fcb0821a57a56ab3e485502208a6829fa
4,799
py
Python
powderday/sph_tributary.py
mccbc/powderday
604b4a242216db0e93dc2e50a77bc20dc5cfb10f
[ "BSD-3-Clause" ]
null
null
null
powderday/sph_tributary.py
mccbc/powderday
604b4a242216db0e93dc2e50a77bc20dc5cfb10f
[ "BSD-3-Clause" ]
null
null
null
powderday/sph_tributary.py
mccbc/powderday
604b4a242216db0e93dc2e50a77bc20dc5cfb10f
[ "BSD-3-Clause" ]
null
null
null
from __future__ import print_function import numpy as np import yt from hyperion.model import Model import matplotlib as mpl mpl.use('Agg') import powderday.config as cfg from powderday.grid_construction import yt_octree_generate from powderday.find_order import find_order import powderday.powderday_test_octree as pt...
33.326389
97
0.625755
d65f5b582b2cb0f35e7f62119567aa744e3f46a6
695
py
Python
api/v1/utilities/su.py
UCCNetsoc/cloud
d3f87c7868ef7615a5836a2a3ba09bfd1dffed1d
[ "BSD-3-Clause" ]
9
2021-02-07T19:49:49.000Z
2021-12-05T20:52:25.000Z
api/v1/utilities/su.py
UCCNetsoc/admin
d3f87c7868ef7615a5836a2a3ba09bfd1dffed1d
[ "BSD-3-Clause" ]
18
2020-09-07T16:04:40.000Z
2020-11-05T01:50:14.000Z
api/v1/utilities/su.py
UCCNetsoc/admin
d3f87c7868ef7615a5836a2a3ba09bfd1dffed1d
[ "BSD-3-Clause" ]
4
2020-09-29T12:03:22.000Z
2020-10-17T21:33:16.000Z
import os
22.419355
49
0.57554
d6640f8ee223b280541ac802e7de4ff0c34b7a1d
7,562
py
Python
backup-23.09.2021/core/data_compression.py
ComputerSystemsLaboratory/Code-Size-Prediction
591c2d2be8365e5816579698670cd02a503a02e7
[ "MIT" ]
null
null
null
backup-23.09.2021/core/data_compression.py
ComputerSystemsLaboratory/Code-Size-Prediction
591c2d2be8365e5816579698670cd02a503a02e7
[ "MIT" ]
null
null
null
backup-23.09.2021/core/data_compression.py
ComputerSystemsLaboratory/Code-Size-Prediction
591c2d2be8365e5816579698670cd02a503a02e7
[ "MIT" ]
null
null
null
import yaml import pickle import argparse import pandas as pd import numpy as np from os import listdir from os.path import isfile, join if __name__ == '__main__': Main()
32.594828
83
0.508067
d665e98d061e1012c4c524dbf33a91e2ae2de401
9,878
py
Python
utils/sen2cor_prepare.py
Zac-HD/datacube-core
ebc2025b6fb9d22fb406cdf5f79eba6d144c57e3
[ "Apache-2.0" ]
2
2018-12-02T11:33:50.000Z
2021-04-24T11:42:42.000Z
utils/sen2cor_prepare.py
Zac-HD/datacube-core
ebc2025b6fb9d22fb406cdf5f79eba6d144c57e3
[ "Apache-2.0" ]
103
2018-03-21T15:00:05.000Z
2020-06-04T05:40:25.000Z
utils/sen2cor_prepare.py
roarmstrong/datacube-core
5e38638dabd9e5112e92b503fae6a83c8dcc4902
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 """ Ingest data from the command-line. """ from __future__ import absolute_import import uuid import logging from xml.etree import ElementTree from pathlib import Path import yaml import click from osgeo import osr import os # image boundary imports from rasterio import crs from rasterio.errors import ...
36.72119
116
0.585746
d66645abc0c9dca87c1142c4568eb368bbd055bf
219
py
Python
Python3_Mundo1_Aula7/Desafio009.py
AgladeJesus/python
16e4e5cc43aa987858a4719748708d6d5327d75d
[ "MIT" ]
null
null
null
Python3_Mundo1_Aula7/Desafio009.py
AgladeJesus/python
16e4e5cc43aa987858a4719748708d6d5327d75d
[ "MIT" ]
null
null
null
Python3_Mundo1_Aula7/Desafio009.py
AgladeJesus/python
16e4e5cc43aa987858a4719748708d6d5327d75d
[ "MIT" ]
null
null
null
a = int(input('Construa a tabuada do Nmero: ')) aux = 0 print('*' * 18) print('Trabuada de {}'.format(a)) print('*' * 18) while (aux <= 10): print('{} X {:2} = {:4}'.format(a, aux, (a * aux))) aux = aux + 1
18.25
55
0.511416
d666594e9acd3e2abe5048a044fd91e0649d967d
11,692
py
Python
ceilometerclient/tests/unit/test_shell.py
mail2nsrajesh/python-ceilometerclient
3b4e35abada626ce052f20d55c71fe12ab77052a
[ "Apache-2.0" ]
null
null
null
ceilometerclient/tests/unit/test_shell.py
mail2nsrajesh/python-ceilometerclient
3b4e35abada626ce052f20d55c71fe12ab77052a
[ "Apache-2.0" ]
null
null
null
ceilometerclient/tests/unit/test_shell.py
mail2nsrajesh/python-ceilometerclient
3b4e35abada626ce052f20d55c71fe12ab77052a
[ "Apache-2.0" ]
null
null
null
# 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 # distribu...
40.597222
78
0.660024
d666e5c0b1764a0c9c6554fd01d5f7393cd16740
1,130
py
Python
coder_news/dataUpdate/Java/ibm.py
shixuan163556/CoderNewsDjango
edc9a12961ce102c211642c45c708d9ac1a30c08
[ "MIT" ]
2
2019-07-04T15:28:09.000Z
2019-07-07T13:53:07.000Z
coder_news/dataUpdate/Java/ibm.py
shixuan163556/CoderNewsDjango
edc9a12961ce102c211642c45c708d9ac1a30c08
[ "MIT" ]
null
null
null
coder_news/dataUpdate/Java/ibm.py
shixuan163556/CoderNewsDjango
edc9a12961ce102c211642c45c708d9ac1a30c08
[ "MIT" ]
null
null
null
from bs4 import BeautifulSoup from coder_news.dataUpdate.dataModel import dataModel import requests
36.451613
82
0.628319
d66755e7fbe9cf593005694d5208e20074f57d42
6,890
py
Python
second/run_bev_det.py
hankeceli/3D-Object-Detection-for-AV
b6c17a4a3ecc9c32418baafa5b82cfd4704ed880
[ "Apache-2.0" ]
null
null
null
second/run_bev_det.py
hankeceli/3D-Object-Detection-for-AV
b6c17a4a3ecc9c32418baafa5b82cfd4704ed880
[ "Apache-2.0" ]
null
null
null
second/run_bev_det.py
hankeceli/3D-Object-Detection-for-AV
b6c17a4a3ecc9c32418baafa5b82cfd4704ed880
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # coding: utf-8 import argparse import os import sys from pathlib import Path import matplotlib.pyplot as plt import pytorch_lightning as pl from src.config.config import SEED from src.dataset.seg_datamodule import Lyft3DdetSegDatamodule from src.modeling.seg_pl_model import LitModel from src.ut...
31.461187
88
0.607547
d667b11e070212e9dadf1c11643176e447a7dce0
1,345
py
Python
custom_components/hue_sync_box/const.py
nitobuendia/hue-sync-box-custom-component
c8496a7776017dbf56dafec6cd9c411829e4a6ef
[ "Apache-2.0" ]
8
2020-06-03T21:49:45.000Z
2022-01-21T22:20:09.000Z
custom_components/hue_sync_box/const.py
nitobuendia/hue-sync-box-custom-component
c8496a7776017dbf56dafec6cd9c411829e4a6ef
[ "Apache-2.0" ]
3
2020-06-03T12:33:10.000Z
2020-11-04T01:34:04.000Z
custom_components/hue_sync_box/const.py
nitobuendia/hue-sync-box-custom-component
c8496a7776017dbf56dafec6cd9c411829e4a6ef
[ "Apache-2.0" ]
2
2020-06-06T04:16:57.000Z
2020-07-10T17:31:33.000Z
"""Constants and common variables for Philips Hue Sync Box.""" from homeassistant import const # Set up. DOMAIN = 'hue_sync_box' PLATFORMS = ['remote'] TOKEN_FILE = 'hue-sync-box-token-cache-{}' # Platform config. CONF_ENTITY_ID = const.CONF_ENTITY_ID CONF_IP_ADDRESS = const.CONF_IP_ADDRESS CONF_NAME = const.CONF_NA...
29.23913
77
0.777695
d667c7e9cffe0e8ebddb738da85243c80be72c1b
1,566
py
Python
maskpw.py
harmony5/maskpw
8672d338af03a7497dcb1bcedf860e26c4371d45
[ "MIT" ]
null
null
null
maskpw.py
harmony5/maskpw
8672d338af03a7497dcb1bcedf860e26c4371d45
[ "MIT" ]
null
null
null
maskpw.py
harmony5/maskpw
8672d338af03a7497dcb1bcedf860e26c4371d45
[ "MIT" ]
null
null
null
"""A simple library to ask the user for a password. Similar to getpass.getpass() but allows to specify a default mask (like '*' instead of blank).""" __version__ = "0.5.5" from sys import platform, stdin if platform == "win32": from msvcrt import getch as __getch else: # taken from https://stackoverflow.co...
25.672131
149
0.57599
d6687922bf42aa533dfa4ed7fba3a27695479b32
2,227
py
Python
evaluation/__init__.py
Leinadh/PeruvianImageGenerator
9bf11125f4ea3090e217cf15866ec19ce944f9c6
[ "Apache-2.0" ]
3
2020-06-30T04:44:31.000Z
2020-06-30T04:44:55.000Z
evaluation/__init__.py
Leinadh/PeruvianImageGenerator
9bf11125f4ea3090e217cf15866ec19ce944f9c6
[ "Apache-2.0" ]
null
null
null
evaluation/__init__.py
Leinadh/PeruvianImageGenerator
9bf11125f4ea3090e217cf15866ec19ce944f9c6
[ "Apache-2.0" ]
null
null
null
import numpy as np import pandas as pd from sklearn.preprocessing import StandardScaler from .utils_tsne import apply_tsne, generate_scatter # distance_threshold, stats_df = calc_jaccard_index(df) # logger.info("stats %s", stats_df) # stats_df.to_csv(os.path.join(output_dir, "stats.csv"), index=False)...
42.018868
188
0.709026
d66ac9bbed52cc97398c2e00fdb14a0c9b408fc1
8,428
py
Python
smartlingApiSdk/api/EstimatesApi.py
Smartling/api-sdk-python
85e937c3ad0abcf5022688a476ac2edb34ab33ac
[ "Apache-2.0" ]
8
2015-01-08T21:31:17.000Z
2021-01-07T07:50:31.000Z
smartlingApiSdk/api/EstimatesApi.py
Smartling/api-sdk-python
85e937c3ad0abcf5022688a476ac2edb34ab33ac
[ "Apache-2.0" ]
8
2015-05-18T21:43:03.000Z
2020-05-19T06:12:17.000Z
smartlingApiSdk/api/EstimatesApi.py
Smartling/api-sdk-python
85e937c3ad0abcf5022688a476ac2edb34ab33ac
[ "Apache-2.0" ]
14
2015-07-24T08:52:27.000Z
2022-03-05T06:36:45.000Z
#!/usr/bin/python # -*- coding: utf-8 -*- """ Copyright 2012-2021 Smartling, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this work except in compliance with the License. * You may obtain a copy of the License in the LICENSE file, or at: * * http://www.apache.org/l...
41.722772
218
0.621262
d66b603c5235740e7b922611dbd005dfe0a0db9f
3,132
py
Python
Cracking the Coding Interview/ctci-solutions-master/ch-08-recursion-and-dynamic-programming/09-parens.py
nikku1234/Code-Practise
94eb6680ea36efd10856c377000219285f77e5a4
[ "Apache-2.0" ]
9
2020-07-02T06:06:17.000Z
2022-02-26T11:08:09.000Z
Cracking the Coding Interview/ctci-solutions-master/ch-08-recursion-and-dynamic-programming/09-parens.py
nikku1234/Code-Practise
94eb6680ea36efd10856c377000219285f77e5a4
[ "Apache-2.0" ]
1
2021-11-04T17:26:36.000Z
2021-11-04T17:26:36.000Z
Cracking the Coding Interview/ctci-solutions-master/ch-08-recursion-and-dynamic-programming/09-parens.py
nikku1234/Code-Practise
94eb6680ea36efd10856c377000219285f77e5a4
[ "Apache-2.0" ]
8
2021-01-31T10:31:12.000Z
2022-03-13T09:15:55.000Z
# List all valid strings containing n opening and n closing parenthesis. # Note that parens1 happens to be faster and more space efficient than parens2, # which is faster than parens3. The slowest is parens4 only because it is not # memoized. import unittest if __name__ == "__main__": unittest.main()
32.28866
80
0.593231
d66bc0464e4375612c9203812ed0b15fe93bf6f0
3,094
py
Python
aiida_ase3/calculations.py
sudarshanv01/aiida-ase-test
3fb7028a31b81654a1e4502fbb791b215b75ed69
[ "MIT" ]
null
null
null
aiida_ase3/calculations.py
sudarshanv01/aiida-ase-test
3fb7028a31b81654a1e4502fbb791b215b75ed69
[ "MIT" ]
null
null
null
aiida_ase3/calculations.py
sudarshanv01/aiida-ase-test
3fb7028a31b81654a1e4502fbb791b215b75ed69
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Calculations provided by aiida_ase3. Register calculations via the "aiida.calculations" entry point in setup.json. """ from aiida.common import datastructures from aiida.engine import CalcJob from aiida.orm import SinglefileData, Str from aiida.plugins import DataFactory DiffParameters = D...
39.164557
124
0.678087
d66df299c7b74899a4ee30dbd5d0c659c580427a
1,928
py
Python
pygomas/bdisoldier.py
sfp932705/pygomas
8cdd7e973b8b4e8de467803c106ec44ca6b8bd03
[ "MIT" ]
3
2019-06-20T08:55:36.000Z
2019-07-04T14:10:40.000Z
pygomas/bdisoldier.py
sfp932705/pygomas
8cdd7e973b8b4e8de467803c106ec44ca6b8bd03
[ "MIT" ]
null
null
null
pygomas/bdisoldier.py
sfp932705/pygomas
8cdd7e973b8b4e8de467803c106ec44ca6b8bd03
[ "MIT" ]
null
null
null
from collections import deque from .vector import Vector3D from .bditroop import BDITroop, CLASS_SOLDIER from .config import BACKUP_SERVICE, DESTINATION, VELOCITY, HEADING from agentspeak import Actions from agentspeak import grounded from agentspeak.stdlib import actions as asp_action
42.844444
119
0.631743
d66e98b2d4b4a2f5b11596b7aad6bd253b7b49c7
190
py
Python
ghostwriter/reporting/tests/factories.py
fastlorenzo/Ghostwriter
8acb2a824fc487d51ff6be845fe874d91ec74bb6
[ "BSD-3-Clause" ]
null
null
null
ghostwriter/reporting/tests/factories.py
fastlorenzo/Ghostwriter
8acb2a824fc487d51ff6be845fe874d91ec74bb6
[ "BSD-3-Clause" ]
null
null
null
ghostwriter/reporting/tests/factories.py
fastlorenzo/Ghostwriter
8acb2a824fc487d51ff6be845fe874d91ec74bb6
[ "BSD-3-Clause" ]
null
null
null
# 3rd Party Libraries import factory
21.111111
56
0.710526
d66f44f2eb17ad9f2cc6383fe1cc7e6f4a144df4
888
py
Python
api/serializers.py
choi-jiwoo/capstone-project-django
fd6ab61da4f636dc6192de3c298a474342ffa371
[ "MIT" ]
null
null
null
api/serializers.py
choi-jiwoo/capstone-project-django
fd6ab61da4f636dc6192de3c298a474342ffa371
[ "MIT" ]
null
null
null
api/serializers.py
choi-jiwoo/capstone-project-django
fd6ab61da4f636dc6192de3c298a474342ffa371
[ "MIT" ]
null
null
null
from rest_framework.serializers import ModelSerializer from api.models import Stay, Cafe, Res, CafeTag, ResTag, CafeKwrd, ResKwrd
19.304348
74
0.658784
d66fe93e5c39bd8dd0c410226d1acb239ec76cc6
2,356
py
Python
scrapers/scrape_sg.py
andreasamsler/covid_19
fdc42747d4f70cdb23a08dcd6cfecbfcc758db96
[ "CC-BY-4.0" ]
null
null
null
scrapers/scrape_sg.py
andreasamsler/covid_19
fdc42747d4f70cdb23a08dcd6cfecbfcc758db96
[ "CC-BY-4.0" ]
null
null
null
scrapers/scrape_sg.py
andreasamsler/covid_19
fdc42747d4f70cdb23a08dcd6cfecbfcc758db96
[ "CC-BY-4.0" ]
1
2020-08-25T06:45:56.000Z
2020-08-25T06:45:56.000Z
#!/usr/bin/env python3 import re import datetime import sys from bs4 import BeautifulSoup import scrape_common as sc url = 'https://www.sg.ch/tools/informationen-coronavirus.html' d = sc.download(url, silent=True) d = d.replace('&nbsp;', ' ') soup = BeautifulSoup(d, 'html.parser') # hospitalized dd_hosp = sc.DayDa...
33.657143
127
0.705008
d6706592b831e6c0c5181fd86f1fc01c8186dcab
47
py
Python
main.py
clitic/up-to-pypi
aa4ca670172402b022e442cc773c7f0f1da2a321
[ "MIT" ]
null
null
null
main.py
clitic/up-to-pypi
aa4ca670172402b022e442cc773c7f0f1da2a321
[ "MIT" ]
null
null
null
main.py
clitic/up-to-pypi
aa4ca670172402b022e442cc773c7f0f1da2a321
[ "MIT" ]
null
null
null
import up_to_pypi.main up_to_pypi.main.main()
11.75
22
0.808511
d670d5aa50884e432ae6064493a3517e18d5845d
577
py
Python
saleor/core/migrations/0005_alter_eventdelivery_webhook.py
eanknd/saleor
08aa724176be00d7aaf654f14e9ae99dd4327f97
[ "CC-BY-4.0" ]
1,392
2021-10-06T15:54:28.000Z
2022-03-31T20:50:55.000Z
saleor/core/migrations/0005_alter_eventdelivery_webhook.py
eanknd/saleor
08aa724176be00d7aaf654f14e9ae99dd4327f97
[ "CC-BY-4.0" ]
888
2021-10-06T10:48:54.000Z
2022-03-31T11:00:30.000Z
saleor/core/migrations/0005_alter_eventdelivery_webhook.py
eanknd/saleor
08aa724176be00d7aaf654f14e9ae99dd4327f97
[ "CC-BY-4.0" ]
538
2021-10-07T16:21:27.000Z
2022-03-31T22:58:57.000Z
# Generated by Django 3.2.12 on 2022-04-08 12:37 from django.db import migrations, models import django.db.models.deletion
25.086957
81
0.622184
d67155021b306149a63c2d55ca90e812dcc37392
65
py
Python
src/visualization/config.py
charity-sotero/apartment_atmosphere
c3147c15e3cf3020f14da0bd88ebaa196fc974c7
[ "MIT" ]
null
null
null
src/visualization/config.py
charity-sotero/apartment_atmosphere
c3147c15e3cf3020f14da0bd88ebaa196fc974c7
[ "MIT" ]
null
null
null
src/visualization/config.py
charity-sotero/apartment_atmosphere
c3147c15e3cf3020f14da0bd88ebaa196fc974c7
[ "MIT" ]
null
null
null
GOOGLE_PLACES_API_KEY = 'AIzaSyCfOAU3yAeFisvLFwNCjI4bujevR29cYm0'
65
65
0.923077
d673c897a97167e0234738305af2c88177b02037
339
py
Python
ExpenseProject/ExpenseApp/migrations/0016_remove_expensemodel_expenses.py
cs-fullstack-fall-2018/project3-django-psanon19
4df4459265c5d0b560dc4fa26b7da2c1b3bf9cff
[ "Apache-2.0" ]
null
null
null
ExpenseProject/ExpenseApp/migrations/0016_remove_expensemodel_expenses.py
cs-fullstack-fall-2018/project3-django-psanon19
4df4459265c5d0b560dc4fa26b7da2c1b3bf9cff
[ "Apache-2.0" ]
null
null
null
ExpenseProject/ExpenseApp/migrations/0016_remove_expensemodel_expenses.py
cs-fullstack-fall-2018/project3-django-psanon19
4df4459265c5d0b560dc4fa26b7da2c1b3bf9cff
[ "Apache-2.0" ]
null
null
null
# Generated by Django 2.0.6 on 2018-10-27 04:42 from django.db import migrations
18.833333
50
0.60472
d675f6f9d4cc85cb82ade7351a4c882f764248ac
494
py
Python
Python 基础教程/1.5.7 lamda应用.py
shao1chuan/pythonbook
cd9877d04e1e11422d38cc051e368d3d9ce2ab45
[ "MulanPSL-1.0" ]
95
2020-10-11T04:45:46.000Z
2022-02-25T01:50:40.000Z
Python 基础教程/1.5.7 lamda应用.py
shao1chuan/pythonbook
cd9877d04e1e11422d38cc051e368d3d9ce2ab45
[ "MulanPSL-1.0" ]
null
null
null
Python 基础教程/1.5.7 lamda应用.py
shao1chuan/pythonbook
cd9877d04e1e11422d38cc051e368d3d9ce2ab45
[ "MulanPSL-1.0" ]
30
2020-11-05T09:01:00.000Z
2022-03-08T05:58:55.000Z
# https://blog.csdn.net/zjuxsl/article/details/77104382 # lambda print(f(4)) # Pythonlambda g = lambda x : x**2 print (g(4)) # lambda # lambda from functools import reduce reduce(lambda x,y:x+y, [1,2,3]) #6 reduce(lambda x,y:x * y, [1,2,4]) #8 reduce(lambda x,y: x and y, [True,False,True]) #False reduce(lambda x, y: f...
18.296296
55
0.661943
d679831901f6560d6b6dd77a3a26fc23cb236301
3,989
py
Python
fb_messenger/webhooks.py
shananin/fb_messanger
450330d6460cc7c38a3683830f1f7d415d0d24e0
[ "MIT" ]
2
2016-07-27T12:01:19.000Z
2016-08-16T23:27:41.000Z
fb_messenger/webhooks.py
shananin/Fb_messanger
450330d6460cc7c38a3683830f1f7d415d0d24e0
[ "MIT" ]
null
null
null
fb_messenger/webhooks.py
shananin/Fb_messanger
450330d6460cc7c38a3683830f1f7d415d0d24e0
[ "MIT" ]
1
2017-03-20T11:22:52.000Z
2017-03-20T11:22:52.000Z
""" Callbacks parser """ from __future__ import unicode_literals from . import webhook_attachments from .types import webhook_types
29.768657
100
0.671096
d6799d986976a1b84a33fedb84a399bf29e93685
2,463
py
Python
turbustat/statistics/convolve_wrapper.py
CFD-UTSA/Turbulence-stars
354d02e38d15e3b0d1f751b43f430dbd3a14c250
[ "MIT" ]
42
2016-04-07T20:49:59.000Z
2022-03-28T12:54:13.000Z
turbustat/statistics/convolve_wrapper.py
CFD-UTSA/Turbulence-stars
354d02e38d15e3b0d1f751b43f430dbd3a14c250
[ "MIT" ]
131
2015-03-05T21:42:27.000Z
2021-07-22T14:59:04.000Z
turbustat/statistics/convolve_wrapper.py
CFD-UTSA/Turbulence-stars
354d02e38d15e3b0d1f751b43f430dbd3a14c250
[ "MIT" ]
21
2015-06-10T17:10:06.000Z
2022-02-28T15:59:42.000Z
# Licensed under an MIT open source license - see LICENSE from __future__ import (print_function, absolute_import, division, unicode_literals) try: from pyfftw.interfaces.numpy_fft import fftn, ifftn PYFFTW_FLAG = True except ImportError: PYFFTW_FLAG = False from astropy.convolutio...
31.987013
82
0.590743
d67a6d48bda1725e87198a5ecec1ebc8d1b78943
3,018
py
Python
app.py
Akali27/15-Interactive-Visualizations-and-Dashboards
2390661358edc1c91aa15d38ee415818803e190b
[ "ADSL" ]
null
null
null
app.py
Akali27/15-Interactive-Visualizations-and-Dashboards
2390661358edc1c91aa15d38ee415818803e190b
[ "ADSL" ]
null
null
null
app.py
Akali27/15-Interactive-Visualizations-and-Dashboards
2390661358edc1c91aa15d38ee415818803e190b
[ "ADSL" ]
null
null
null
import json from flask import Flask from flask import render_template import csv import os import pandas as pd APP_ROOT = os.path.dirname(os.path.abspath(__file__)) APP_STATIC = os.path.join(APP_ROOT, 'static') app = Flask(__name__) if __name__ == '__main__': app.run()
25.794872
114
0.594102
d67b60f619cf001107ad4b8b006d530b985cdcc1
16,121
py
Python
HRRR/neural_network_interp.py
ahijevyc/NSC_objects
322728a71ec011b681b0038e9dcd86df1f73b2fd
[ "MIT" ]
null
null
null
HRRR/neural_network_interp.py
ahijevyc/NSC_objects
322728a71ec011b681b0038e9dcd86df1f73b2fd
[ "MIT" ]
null
null
null
HRRR/neural_network_interp.py
ahijevyc/NSC_objects
322728a71ec011b681b0038e9dcd86df1f73b2fd
[ "MIT" ]
null
null
null
#!/usr/bin/env python import matplotlib matplotlib.use('Agg') import matplotlib.pyplot as plt from matplotlib.colors import LogNorm, ListedColormap,BoundaryNorm import numpy as np import datetime as dt import sys, os, pickle, time from scipy.ndimage.filters import gaussian_filter import pandas as pd from mpl_toolkits....
42.989333
236
0.676261
d67e26cf9d7b63bc40b5de73cff1c0248ad963d6
4,515
py
Python
22爬虫提高/day04/basic01.py
HaoZhang95/PythonAndMachineLearning
b897224b8a0e6a5734f408df8c24846a98c553bf
[ "MIT" ]
937
2019-05-08T08:46:25.000Z
2022-03-31T12:56:07.000Z
22爬虫提高/day04/basic01.py
HaoZhang95/PythonAndMachineLearning
b897224b8a0e6a5734f408df8c24846a98c553bf
[ "MIT" ]
47
2019-09-17T10:06:02.000Z
2022-03-11T23:46:52.000Z
22爬虫提高/day04/basic01.py
HaoZhang95/PythonAndMachineLearning
b897224b8a0e6a5734f408df8c24846a98c553bf
[ "MIT" ]
354
2019-05-10T02:15:26.000Z
2022-03-30T05:52:57.000Z
import json import time import requests from PIL import Image from pytesseract import pytesseract from selenium import webdriver """ seleniumxpath seleniumheaderswebdriver.Chrome().get(url)find_xxx_by_xpath xpath xpathetree.Html(url),html.xpath(xxx) """ headers = { "User-Agent": "Mozilla/5....
26.558824
145
0.572536
d6823a832aea816c2f48825bcf38e6f4d87d49cc
2,588
py
Python
b3/guess_type.py
oddy/b3
5d295588389ce6873b087ceff24aa949c9f9ffc4
[ "MIT" ]
5
2020-06-25T02:24:29.000Z
2020-07-06T15:23:26.000Z
b3/guess_type.py
oddy/b3
5d295588389ce6873b087ceff24aa949c9f9ffc4
[ "MIT" ]
null
null
null
b3/guess_type.py
oddy/b3
5d295588389ce6873b087ceff24aa949c9f9ffc4
[ "MIT" ]
null
null
null
# Python-Obj to B3-Type guesser for composite_dynamic (pack) import datetime, decimal from six import PY2 from b3.datatypes import * # Policy: Currently guessed types are fixed and 1:1 with python types. # - There is/was an idea to have guess_type select the 'best' type based on value (e.g. SVARINT or UVARINT depe...
41.741935
135
0.668083
d6826000c0a3b0ee797f22772d829d88679013b0
101
py
Python
office365/directory/applications/spa_application.py
rikeshtailor/Office365-REST-Python-Client
ca7bfa1b22212137bb4e984c0457632163e89a43
[ "MIT" ]
544
2016-08-04T17:10:16.000Z
2022-03-31T07:17:20.000Z
office365/directory/applications/spa_application.py
rikeshtailor/Office365-REST-Python-Client
ca7bfa1b22212137bb4e984c0457632163e89a43
[ "MIT" ]
438
2016-10-11T12:24:22.000Z
2022-03-31T19:30:35.000Z
office365/directory/applications/spa_application.py
rikeshtailor/Office365-REST-Python-Client
ca7bfa1b22212137bb4e984c0457632163e89a43
[ "MIT" ]
202
2016-08-22T19:29:40.000Z
2022-03-30T20:26:15.000Z
from office365.runtime.client_value import ClientValue
16.833333
54
0.821782
d682b75ed77e306a31960fd2f05b18dec13b96bd
200
py
Python
problem/01000~09999/02862/2862.py3.py
njw1204/BOJ-AC
1de41685725ae4657a7ff94e413febd97a888567
[ "MIT" ]
1
2019-04-19T16:37:44.000Z
2019-04-19T16:37:44.000Z
problem/01000~09999/02862/2862.py3.py
njw1204/BOJ-AC
1de41685725ae4657a7ff94e413febd97a888567
[ "MIT" ]
1
2019-04-20T11:42:44.000Z
2019-04-20T11:42:44.000Z
problem/01000~09999/02862/2862.py3.py
njw1204/BOJ-AC
1de41685725ae4657a7ff94e413febd97a888567
[ "MIT" ]
3
2019-04-19T16:37:47.000Z
2021-10-25T00:45:00.000Z
fib=[1]*100 for i in range(2,100): fib[i]=fib[i-1]+fib[i-2] n=int(input()) print(ans(n))
18.181818
37
0.6
d68419a429e9ce74826f1dd0b468241c52fd6e58
3,478
py
Python
porcupine/plugins/run/__init__.py
ThePhilgrim/porcupine
4b0d5a4be0a41d031674d7e3525e82bdee1bff9a
[ "MIT" ]
null
null
null
porcupine/plugins/run/__init__.py
ThePhilgrim/porcupine
4b0d5a4be0a41d031674d7e3525e82bdee1bff9a
[ "MIT" ]
null
null
null
porcupine/plugins/run/__init__.py
ThePhilgrim/porcupine
4b0d5a4be0a41d031674d7e3525e82bdee1bff9a
[ "MIT" ]
null
null
null
"""Compile, run and lint files.""" import dataclasses import logging import os import pathlib import shlex import sys from functools import partial from typing import List, Optional if sys.version_info >= (3, 8): from typing import Literal else: from typing_extensions import Literal from porcupine import get...
30.778761
98
0.661012
d684e2a6f1a8b1aae17eeb957d82a419425fab31
521
py
Python
price_picker/models/shop.py
M0r13n/price_picker
aaa4e79496753bc3b61afbde6324868ee5c46aa5
[ "MIT" ]
3
2019-08-03T16:52:36.000Z
2020-04-13T10:06:38.000Z
price_picker/models/shop.py
M0r13n/price_picker
aaa4e79496753bc3b61afbde6324868ee5c46aa5
[ "MIT" ]
null
null
null
price_picker/models/shop.py
M0r13n/price_picker
aaa4e79496753bc3b61afbde6324868ee5c46aa5
[ "MIT" ]
1
2021-01-02T11:31:25.000Z
2021-01-02T11:31:25.000Z
from price_picker.common.database import CRUDMixin from price_picker import db
24.809524
87
0.658349
d684faf373d0fce5837ccb0a1cfd9787102e4791
6,086
py
Python
scripts/colorize/las_colorize.py
SPINLab/rijkswaterstaat-data-tools
cbf46ae1446401b3f8351ca049c266a694a91d58
[ "MIT" ]
1
2018-10-22T12:35:10.000Z
2018-10-22T12:35:10.000Z
scripts/colorize/las_colorize.py
SPINLab/rijkswaterstaat-data-tools
cbf46ae1446401b3f8351ca049c266a694a91d58
[ "MIT" ]
null
null
null
scripts/colorize/las_colorize.py
SPINLab/rijkswaterstaat-data-tools
cbf46ae1446401b3f8351ca049c266a694a91d58
[ "MIT" ]
1
2018-04-09T09:51:38.000Z
2018-04-09T09:51:38.000Z
# -*- coding: utf-8 -*- """ Python3 @author: Chris Lucas """ import sys import os import argparse import subprocess import json import math def process_files(input_path, output_path, las_srs, wms_url, wms_layer, wms_srs, wms_version, wms_format, wms_ppm, wms_ma...
44.101449
141
0.526454
d68539671b8fab2289527b39766c18a09b89fa67
1,285
py
Python
lib/paramsweep_w2_deltaT_counterfactual.py
benlansdell/deep-rdd
2f1443aa9800d0e0f3a4ce9051c1b8b9ed8c2ae9
[ "MIT" ]
4
2019-01-21T18:21:07.000Z
2021-04-30T16:31:12.000Z
lib/paramsweep_w2_deltaT_counterfactual.py
benlansdell/deep-rdd
2f1443aa9800d0e0f3a4ce9051c1b8b9ed8c2ae9
[ "MIT" ]
null
null
null
lib/paramsweep_w2_deltaT_counterfactual.py
benlansdell/deep-rdd
2f1443aa9800d0e0f3a4ce9051c1b8b9ed8c2ae9
[ "MIT" ]
null
null
null
import numpy as np from lib.lif import LIF, ParamsLIF from lib.causal import causaleffect #Set x = 0, sigma = 10 #wvals = 2..20 sigma = 10 mu = 1 tau = 1 t = 500 params = ParamsLIF(sigma = sigma, mu = mu, tau = tau) lif = LIF(params, t = t) lif.x = 0 #Simulate for a range of $W$ values. N = 19 nsims = 1 wmax = 20 n =...
27.934783
100
0.598444
d6855a43a2ccf3a81f181c755f6b6e16d0e11895
7,462
py
Python
bridgeClient.py
omega3love/BridgeProject
35ba6d96f584dc11874cb053dda5bed0a47cd347
[ "FTL" ]
null
null
null
bridgeClient.py
omega3love/BridgeProject
35ba6d96f584dc11874cb053dda5bed0a47cd347
[ "FTL" ]
null
null
null
bridgeClient.py
omega3love/BridgeProject
35ba6d96f584dc11874cb053dda5bed0a47cd347
[ "FTL" ]
null
null
null
#! /usr/bin/python import socket import threading from time import sleep import sys, os import inputbox import pygame from bridgeSprites import Button def myIPaddress(): try: s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM) s.connect(("gmail.com",80)) myip = s.getsockname()[0] s.close() return...
27.535055
113
0.64728
d685af112d81faa0f634d5f48b27e861166261c2
2,812
py
Python
class3/exercise2.py
befthimi/be_pynet_course
d5e384baf4d8ddbb99e348a66e8b688c82098f59
[ "Apache-2.0" ]
null
null
null
class3/exercise2.py
befthimi/be_pynet_course
d5e384baf4d8ddbb99e348a66e8b688c82098f59
[ "Apache-2.0" ]
null
null
null
class3/exercise2.py
befthimi/be_pynet_course
d5e384baf4d8ddbb99e348a66e8b688c82098f59
[ "Apache-2.0" ]
1
2020-06-03T08:50:12.000Z
2020-06-03T08:50:12.000Z
#!/usr/bin/env python """ Script that graphs interface stats """ import time import snmp_helper import pygal intfInOctets_fa4 = '1.3.6.1.2.1.2.2.1.10.5' intfInUcastPkts_fa4 = '1.3.6.1.2.1.2.2.1.11.5' intfOutOctets_fa4 = '1.3.6.1.2.1.2.2.1.16.5' intfOutUcastPkts_fa4 = '1.3.6.1.2.1.2.2.1.17.5' router1 = ('50.76.53.27', ...
30.565217
97
0.698435
d686499fa79e594e85a706dad4ff13ce847aaa79
88
py
Python
obliv/__init__.py
dsroche/obliv
7a7c72e7dcc05d9a30656a501a952d722027dbc3
[ "Unlicense" ]
2
2020-11-21T00:18:12.000Z
2020-11-24T02:20:17.000Z
obliv/__init__.py
dsroche/obliv
7a7c72e7dcc05d9a30656a501a952d722027dbc3
[ "Unlicense" ]
null
null
null
obliv/__init__.py
dsroche/obliv
7a7c72e7dcc05d9a30656a501a952d722027dbc3
[ "Unlicense" ]
null
null
null
__all__ = ["hirb", "voram", "skipstash", "fstore", "mt_ssh_store", "ssh_info", "idstr"]
44
87
0.636364
d6868f951f29d45d5b4f95f292682caa39c1abd7
930
py
Python
Python/OsFileSystem/list_files.py
Gjacquenot/training-material
16b29962bf5683f97a1072d961dd9f31e7468b8d
[ "CC-BY-4.0" ]
115
2015-03-23T13:34:42.000Z
2022-03-21T00:27:21.000Z
Python/OsFileSystem/list_files.py
Gjacquenot/training-material
16b29962bf5683f97a1072d961dd9f31e7468b8d
[ "CC-BY-4.0" ]
56
2015-02-25T15:04:26.000Z
2022-01-03T07:42:48.000Z
Python/OsFileSystem/list_files.py
Gjacquenot/training-material
16b29962bf5683f97a1072d961dd9f31e7468b8d
[ "CC-BY-4.0" ]
59
2015-11-26T11:44:51.000Z
2022-03-21T00:27:22.000Z
#!/usr/bin/env python from argparse import ArgumentParser import os import sys if __name__ == '__main__': arg_parser = ArgumentParser(description='list all files with given ' 'extension in directory') arg_parser.add_argument('--dir', default='.', ...
37.2
72
0.582796
d6889b61554d788bc43d1d4a886ba1e6ea609e32
348
py
Python
tests/test_graph.py
ssube/redesigned-barnacle
314ea415b6f725c798cc97d6e619fbedc7f8bd21
[ "MIT" ]
null
null
null
tests/test_graph.py
ssube/redesigned-barnacle
314ea415b6f725c798cc97d6e619fbedc7f8bd21
[ "MIT" ]
1
2021-11-04T16:00:15.000Z
2021-11-04T16:00:15.000Z
tests/test_graph.py
ssube/redesigned-barnacle
314ea415b6f725c798cc97d6e619fbedc7f8bd21
[ "MIT" ]
null
null
null
from redesigned_barnacle.buffer import CircularBuffer from redesigned_barnacle.graph import Sparkline from redesigned_barnacle.mock import MockFramebuffer from unittest import TestCase
29
53
0.775862
d68931defee18e31e403efa7119fcbbcac29b44e
893
py
Python
testapp/wagtail_wordpress_processor/management/commands/base_command.py
nickmoreton/wagtail_wordpress_importer
fbe6b60ae624edac3f42a62ce30af4a0c548b4ed
[ "MIT" ]
null
null
null
testapp/wagtail_wordpress_processor/management/commands/base_command.py
nickmoreton/wagtail_wordpress_importer
fbe6b60ae624edac3f42a62ce30af4a0c548b4ed
[ "MIT" ]
null
null
null
testapp/wagtail_wordpress_processor/management/commands/base_command.py
nickmoreton/wagtail_wordpress_importer
fbe6b60ae624edac3f42a62ce30af4a0c548b4ed
[ "MIT" ]
null
null
null
from django.core.management import BaseCommand from wagtail_wordpress_importer.utils import spinner
31.892857
71
0.6271
d68a536157f9fd7d4662b09af86a14b1f0e44990
5,503
py
Python
Labs/LineSweep/plots.py
jessicaleete/numerical_computing
cc71f51f35ca74d00e617af3d1a0223e19fb9a68
[ "CC-BY-3.0" ]
10
2016-10-18T19:54:25.000Z
2021-10-09T20:12:38.000Z
Labs/LineSweep/plots.py
jessicaleete/numerical_computing
cc71f51f35ca74d00e617af3d1a0223e19fb9a68
[ "CC-BY-3.0" ]
null
null
null
Labs/LineSweep/plots.py
jessicaleete/numerical_computing
cc71f51f35ca74d00e617af3d1a0223e19fb9a68
[ "CC-BY-3.0" ]
2
2017-05-14T16:07:59.000Z
2020-06-20T09:05:06.000Z
# This plotting file is rather old code. # It generates a full set of plots illustrating the two different linesweep # algorithms on randomly chosen points. # It should be updated at some point so that the random number generator # is seeded with some specifically chosen seed that generates plots that # illustrate the ...
36.443709
118
0.580774
d68cb0f8d2da0573c60e378449b75ad56b3f6ac1
1,224
py
Python
setup.py
rsp9u/stingconf
eb98f27dfb461c41e3045ae9cb819d9e17611bd8
[ "MIT" ]
null
null
null
setup.py
rsp9u/stingconf
eb98f27dfb461c41e3045ae9cb819d9e17611bd8
[ "MIT" ]
2
2019-04-05T14:28:19.000Z
2019-04-13T08:07:47.000Z
setup.py
rsp9u/stingconf
eb98f27dfb461c41e3045ae9cb819d9e17611bd8
[ "MIT" ]
null
null
null
import os import sys import codecs from setuptools import setup tests_require = [ 'pytest', 'pytest-mock', ] if sys.version_info < (3, 0): tests_require.append('mock') setup( name='stingconf', version='0.0.3', author='', author_email='', maintainer='rsp9u', maintainer_email='gc...
23.538462
62
0.626634
d68d7b1197ee7c4dce2f2971b053d4887af55db6
955
py
Python
setup.py
eshandas/simple_django_logger
a6d15ca1c1ded414ed8fe5cc0c4ca0c20a846582
[ "MIT" ]
null
null
null
setup.py
eshandas/simple_django_logger
a6d15ca1c1ded414ed8fe5cc0c4ca0c20a846582
[ "MIT" ]
5
2020-02-11T23:15:07.000Z
2021-06-10T20:52:39.000Z
setup.py
eshandas/simple_django_logger
a6d15ca1c1ded414ed8fe5cc0c4ca0c20a846582
[ "MIT" ]
null
null
null
from setuptools import find_packages, setup # Read more here: https://pypi.org/project/twine/ setup( name='simple_django_logger', # packages=[ # 'simple_django_logger', # this must be the same as the name above # 'simple_django_logger.middleware', # 'simple_django_logger.migrations'], ...
35.37037
115
0.657592
d68e4768714631ad02e49c87150e8aa5aa57316c
447
py
Python
sporting_webapp/nfl_package/urls.py
plopez9/chipy_sports_app_2.0
39b337238d0a55bfe842cb60ea9fe4724426fbf0
[ "MIT" ]
null
null
null
sporting_webapp/nfl_package/urls.py
plopez9/chipy_sports_app_2.0
39b337238d0a55bfe842cb60ea9fe4724426fbf0
[ "MIT" ]
null
null
null
sporting_webapp/nfl_package/urls.py
plopez9/chipy_sports_app_2.0
39b337238d0a55bfe842cb60ea9fe4724426fbf0
[ "MIT" ]
1
2019-10-08T17:39:08.000Z
2019-10-08T17:39:08.000Z
from django.urls import path, include from . import views from rest_framework import routers router = routers.DefaultRouter() router.register("NFLSummary", views.NFLSummaryView) router.register("NFLStats", views.NFLStatView) router.register("DefensiveSummary", views.DefensiveSummaryView) router.register("DefensiveStat...
27.9375
63
0.771812
d690b6c54e3e5a7fe695c60bb7a1ef69e9ce837f
7,154
py
Python
src/create_user.py
HcKide/ImageSetClassificationFramework
ebe3684984abdd554f85250cc9449cfb83c50784
[ "MIT" ]
null
null
null
src/create_user.py
HcKide/ImageSetClassificationFramework
ebe3684984abdd554f85250cc9449cfb83c50784
[ "MIT" ]
null
null
null
src/create_user.py
HcKide/ImageSetClassificationFramework
ebe3684984abdd554f85250cc9449cfb83c50784
[ "MIT" ]
null
null
null
"""Functions for creating users using the coco data. """ import random, os, shutil, time, json from constants import sub_sets
38.256684
114
0.727146
d6914231f325b2ca6e94895a1d75b16202747bde
6,474
py
Python
models.py
hash2430/pytorch_non_parallel_vc
ecdde28d6bc57afb81b274b8ec3a564fc84f6b53
[ "MIT" ]
1
2021-08-03T06:33:02.000Z
2021-08-03T06:33:02.000Z
models.py
hash2430/pytorch_non_parallel_vc
ecdde28d6bc57afb81b274b8ec3a564fc84f6b53
[ "MIT" ]
null
null
null
models.py
hash2430/pytorch_non_parallel_vc
ecdde28d6bc57afb81b274b8ec3a564fc84f6b53
[ "MIT" ]
null
null
null
import torch.nn as nn import modules2 as modules import torch.nn.functional as F from hparams import hparam as hp # Is it the right approach to have net1 and net2 as submodule of Net3?
46.913043
106
0.481155
d692c63662549a5451cd5f10534438beadbf49d1
401
py
Python
programs/pgm07_23.py
danielsunzhongyuan/python_practice
79bc88db1c52ee2f5607f6f9fec1bbacea2804ff
[ "Apache-2.0" ]
null
null
null
programs/pgm07_23.py
danielsunzhongyuan/python_practice
79bc88db1c52ee2f5607f6f9fec1bbacea2804ff
[ "Apache-2.0" ]
null
null
null
programs/pgm07_23.py
danielsunzhongyuan/python_practice
79bc88db1c52ee2f5607f6f9fec1bbacea2804ff
[ "Apache-2.0" ]
null
null
null
# # This file contains the Python code from Program 7.23 of # "Data Structures and Algorithms # with Object-Oriented Design Patterns in Python" # by Bruno R. Preiss. # # Copyright (c) 2003 by Bruno R. Preiss, P.Eng. All rights reserved. # # http://www.brpreiss.com/books/opus7/programs/pgm07_23.txt #
26.733333
69
0.723192
d692f8f38cc997b2f8bfdb6f4463f32491f25ba9
639
py
Python
rotas/serializers.py
fchevitarese/routecalc
4222d61511885acaad58595689af05eef5ef4218
[ "MIT" ]
null
null
null
rotas/serializers.py
fchevitarese/routecalc
4222d61511885acaad58595689af05eef5ef4218
[ "MIT" ]
null
null
null
rotas/serializers.py
fchevitarese/routecalc
4222d61511885acaad58595689af05eef5ef4218
[ "MIT" ]
null
null
null
# encoding: utf-8 from rest_framework import serializers from .models import Rota
29.045455
59
0.699531
d69854d081156c98d0d1672e25b45d5d7c8fd0d5
2,635
py
Python
fastapi_for_firebase/cache_control/strategic.py
attakei-sandbox/fastapi-with-firebase
fb21e06853c4de734cc475cb5ecaf1d82880fdb5
[ "Apache-2.0" ]
5
2020-04-08T20:02:54.000Z
2021-04-13T05:48:26.000Z
fastapi_for_firebase/cache_control/strategic.py
attakei/fastapi-for-firebase
fb21e06853c4de734cc475cb5ecaf1d82880fdb5
[ "Apache-2.0" ]
null
null
null
fastapi_for_firebase/cache_control/strategic.py
attakei/fastapi-for-firebase
fb21e06853c4de734cc475cb5ecaf1d82880fdb5
[ "Apache-2.0" ]
null
null
null
"""Strategic cache-control. Module usage: 1. Plan your cache-control storategy. (ex: "long" caches content until 3600 seconds) 2. Set storategy store to your app.state and add rules. 3. Set cache strategy as Depends to your path routing. .. code-block: python app = FastAPI() strategy = StrategyStore() stra...
31
84
0.694877
d6986e27cf802a59743b1e891aaab14d1df9b133
2,715
py
Python
backend/src/msg/jsonMsg.py
frost917/customer-manager
d7d4c16f99e1548989bff85c20c307a844711eda
[ "Apache-2.0" ]
null
null
null
backend/src/msg/jsonMsg.py
frost917/customer-manager
d7d4c16f99e1548989bff85c20c307a844711eda
[ "Apache-2.0" ]
1
2021-09-18T05:56:45.000Z
2021-09-18T05:56:45.000Z
backend/src/msg/jsonMsg.py
frost917/customer-manager
d7d4c16f99e1548989bff85c20c307a844711eda
[ "Apache-2.0" ]
null
null
null
import json from datetime import datetime # Dict in List
22.438017
63
0.632413
d69a8c1cb42d0e624e25596a015473f238993347
1,411
py
Python
tests/test_attr_chan.py
wonambi-python/wonambi
4e2834cdd799576d1a231ecb48dfe4da1364fe3a
[ "BSD-3-Clause" ]
63
2017-12-30T08:11:17.000Z
2022-01-28T10:34:20.000Z
tests/test_attr_chan.py
wonambi-python/wonambi
4e2834cdd799576d1a231ecb48dfe4da1364fe3a
[ "BSD-3-Clause" ]
23
2017-09-08T08:29:49.000Z
2022-03-17T08:19:13.000Z
tests/test_attr_chan.py
wonambi-python/wonambi
4e2834cdd799576d1a231ecb48dfe4da1364fe3a
[ "BSD-3-Clause" ]
12
2017-09-18T12:48:36.000Z
2021-09-22T07:16:07.000Z
from nibabel import load as nload from wonambi.attr import Channels, Freesurfer from wonambi.attr.chan import (find_channel_groups, create_sphere_around_elec, ) from .paths import (chan_path, fs_path, template_mri_pat...
26.622642
68
0.612332
d69c4203134525f91e4813de686a2e0b2fa65120
3,224
py
Python
Taller_Estructuras_de_Control_Selectivas/Ejercicio_15.py
LeonardoJimenezUbaque/Algoritmos_y_Programacion_C4_G2
7bb6fffa7d5d99ac2b5c0a3724f97a84e145bbb7
[ "MIT" ]
null
null
null
Taller_Estructuras_de_Control_Selectivas/Ejercicio_15.py
LeonardoJimenezUbaque/Algoritmos_y_Programacion_C4_G2
7bb6fffa7d5d99ac2b5c0a3724f97a84e145bbb7
[ "MIT" ]
null
null
null
Taller_Estructuras_de_Control_Selectivas/Ejercicio_15.py
LeonardoJimenezUbaque/Algoritmos_y_Programacion_C4_G2
7bb6fffa7d5d99ac2b5c0a3724f97a84e145bbb7
[ "MIT" ]
null
null
null
""" Ejercicio 15 Tomando como base los resultados obtenidos en un laboratorio de anlisis clnicos, un mdico determina si una persona tiene anemia o no, lo cual depende de su nivel de hemoglobina en la sangre, de su edad y de su sexo. Si el nivel de hemoglobina que tiene una persona es menor que el rango que le correspon...
31.300971
144
0.525434
d69cf55fbd60fd39b8d016cc293780b17de4dd17
485
py
Python
LBP15.py
Anandgowda18/LogicBasedPrograms
25baa9fbf19cd45229c87e099877e97281b0e76b
[ "MIT" ]
null
null
null
LBP15.py
Anandgowda18/LogicBasedPrograms
25baa9fbf19cd45229c87e099877e97281b0e76b
[ "MIT" ]
null
null
null
LBP15.py
Anandgowda18/LogicBasedPrograms
25baa9fbf19cd45229c87e099877e97281b0e76b
[ "MIT" ]
null
null
null
'''Program to read a number and check whether it is duck number or not. Hint: A duck number is a number which has zeros present in it, but no zero present in the begining of the number. Input Format a number from the user Constraints n>=0 Output Format Yes or No Sample Input 0 123 Sample Output 0 No Sample Inp...
12.763158
113
0.690722
d69d1427809e16ff71adf65c1d277b74efb15e53
537
py
Python
village_api/migrations/0008_alter_relationship_people.py
roseDickinson/dnd-village-api
ddcaf2ab9c1d496f150160ef8638526634752368
[ "MIT" ]
1
2021-08-10T21:40:35.000Z
2021-08-10T21:40:35.000Z
village_api/migrations/0008_alter_relationship_people.py
roseDickinson/dnd-village-api
ddcaf2ab9c1d496f150160ef8638526634752368
[ "MIT" ]
null
null
null
village_api/migrations/0008_alter_relationship_people.py
roseDickinson/dnd-village-api
ddcaf2ab9c1d496f150160ef8638526634752368
[ "MIT" ]
null
null
null
# Generated by Django 3.2.6 on 2021-08-30 14:17 from django.db import migrations, models
23.347826
51
0.56797
d6a1b51f6f7f6e368716a768ac9d830e60dba224
5,457
py
Python
win/devkit/plug-ins/scripted/mathTableControl.py
leegoonz/Maya-devkit
b81fe799b58e854e4ef16435426d60446e975871
[ "ADSL" ]
10
2018-03-30T16:09:02.000Z
2021-12-07T07:29:19.000Z
win/devkit/plug-ins/scripted/mathTableControl.py
leegoonz/Maya-devkit
b81fe799b58e854e4ef16435426d60446e975871
[ "ADSL" ]
null
null
null
win/devkit/plug-ins/scripted/mathTableControl.py
leegoonz/Maya-devkit
b81fe799b58e854e4ef16435426d60446e975871
[ "ADSL" ]
9
2018-06-02T09:18:49.000Z
2021-12-20T09:24:35.000Z
#- # ========================================================================== # Copyright (C) 1995 - 2006 Autodesk, Inc. and/or its licensors. All # rights reserved. # # The coded instructions, statements, computer programs, and/or related # material (collectively the "Data") in these files contain unpublished...
30.486034
82
0.707165
d6a4cfd778b7662941d05402af430bcc1f571214
3,812
py
Python
probe/modules/antivirus/symantec_win/symantec_win.py
krisshol/bach-kmno
f40d85b3397bb340e26a671c54d4a753dbbb0d43
[ "Apache-2.0" ]
null
null
null
probe/modules/antivirus/symantec_win/symantec_win.py
krisshol/bach-kmno
f40d85b3397bb340e26a671c54d4a753dbbb0d43
[ "Apache-2.0" ]
null
null
null
probe/modules/antivirus/symantec_win/symantec_win.py
krisshol/bach-kmno
f40d85b3397bb340e26a671c54d4a753dbbb0d43
[ "Apache-2.0" ]
null
null
null
# # Copyright (c) 2013-2018 Quarkslab. # This file is part of IRMA project. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License in the top-level directory # of this distribution and at: # # http:...
36.304762
78
0.533316
d6a5613c0d93020357ebef9a8b8cdb6d84473de6
1,124
py
Python
main.py
snj830526/py_invest_helper
ae3240acbb68465b8987e5dda015ca020951ce6d
[ "BSD-2-Clause" ]
null
null
null
main.py
snj830526/py_invest_helper
ae3240acbb68465b8987e5dda015ca020951ce6d
[ "BSD-2-Clause" ]
null
null
null
main.py
snj830526/py_invest_helper
ae3240acbb68465b8987e5dda015ca020951ce6d
[ "BSD-2-Clause" ]
null
null
null
import time import conv from slack import WebClient if __name__ == '__main__': working()
28.1
111
0.592527
d6a5993a6817c5347b68c06b86ffd5a06087e17f
2,720
py
Python
array_cw1.py
cs-fullstack-2019-spring/python-arraycollections-cw-tdude0175
761b1269e92861957a0e636a56fbce0df7944e75
[ "Apache-2.0" ]
null
null
null
array_cw1.py
cs-fullstack-2019-spring/python-arraycollections-cw-tdude0175
761b1269e92861957a0e636a56fbce0df7944e75
[ "Apache-2.0" ]
null
null
null
array_cw1.py
cs-fullstack-2019-spring/python-arraycollections-cw-tdude0175
761b1269e92861957a0e636a56fbce0df7944e75
[ "Apache-2.0" ]
null
null
null
# Create a function with the variable below. After you create the variable do the instructions below that. # # arrayForProblem2 = ["Kenn", "Kevin", "Erin", "Meka"] # a) Print the 3rd element of the numberList. # # b) Print the size of the array # # c) Delete the second element. # # d) Print the 3rd element. ...
25.185185
114
0.647059
d6a64a5e7b5c1bb556cf4794767511558329ad0e
1,615
py
Python
Dep/lbol.py
scigeliu/ViaLacteaVisualAnalytics
2ac79301ceaaab0415ec7105b8267552262c7650
[ "Apache-2.0" ]
1
2021-12-15T15:15:50.000Z
2021-12-15T15:15:50.000Z
Dep/lbol.py
scigeliu/ViaLacteaVisualAnalytics
2ac79301ceaaab0415ec7105b8267552262c7650
[ "Apache-2.0" ]
null
null
null
Dep/lbol.py
scigeliu/ViaLacteaVisualAnalytics
2ac79301ceaaab0415ec7105b8267552262c7650
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Tue Nov 9 11:10:34 2021 @author: smordini """ import numpy as np from scipy import interpolate
27.844828
83
0.628483
d6a73b4f51ee405dcff8b521c7e25aaace010e74
247
py
Python
batch/twitter_setting.py
happou31/dora-stat
1405fff5d77fc01c4af7811388bc1003a840545d
[ "MIT" ]
null
null
null
batch/twitter_setting.py
happou31/dora-stat
1405fff5d77fc01c4af7811388bc1003a840545d
[ "MIT" ]
null
null
null
batch/twitter_setting.py
happou31/dora-stat
1405fff5d77fc01c4af7811388bc1003a840545d
[ "MIT" ]
null
null
null
consumer_key = "TSKf1HtYKBsnYU9qfpvbRJkxo" consumer_secret = "Y5lH7u6MDu5DjV5hUxEkwUpPwugYvEuqfpqyvP7y5ulen9XUML" access_token = '115029611-4TampaXbxHmUHcpK5Cll8h7rioP80SJMNneZiYCN' access_secret = 'wx4iaVvgvY5ZknCn6bOiKFiTzAU62R5PXC8b29RC6alwU'
41.166667
70
0.894737
d6aac7d65fbe2c8c093481966f78c83a462795c8
604
py
Python
scripts/bcf_sample_stats.py
jodyphelan/pathogenseq
2e04190f25063d722ef653e819b94eb66407ea8d
[ "MIT" ]
null
null
null
scripts/bcf_sample_stats.py
jodyphelan/pathogenseq
2e04190f25063d722ef653e819b94eb66407ea8d
[ "MIT" ]
null
null
null
scripts/bcf_sample_stats.py
jodyphelan/pathogenseq
2e04190f25063d722ef653e819b94eb66407ea8d
[ "MIT" ]
1
2018-05-11T14:54:51.000Z
2018-05-11T14:54:51.000Z
#! /usr/bin/env python import sys import pathogenseq as ps import json infile = sys.argv[1] ref = sys.argv[2] outfile = sys.argv[3] bcf = ps.bcf(infile) stats = bcf.load_stats(convert=True,ref=ref) genome_len = sum([len(x) for x in ps.fasta(ref).fa_dict.values()]) print("sample\tnRefHom\tnNonRefHom\tnHets\tnMissing")...
28.761905
92
0.677152
d6ac055475b911cfeae3618d813b4df9c1e9348b
441
py
Python
tests/factories/lti_user.py
robertknight/lms
634c78ad3f7d79a59b3edacdceaae6205ca319b4
[ "BSD-2-Clause" ]
null
null
null
tests/factories/lti_user.py
robertknight/lms
634c78ad3f7d79a59b3edacdceaae6205ca319b4
[ "BSD-2-Clause" ]
null
null
null
tests/factories/lti_user.py
robertknight/lms
634c78ad3f7d79a59b3edacdceaae6205ca319b4
[ "BSD-2-Clause" ]
null
null
null
from factory import Faker, make_factory from lms import models from tests.factories._attributes import OAUTH_CONSUMER_KEY, USER_ID LTIUser = make_factory( # pylint:disable=invalid-name models.LTIUser, user_id=USER_ID, oauth_consumer_key=OAUTH_CONSUMER_KEY, roles=Faker("random_element", elements=["Lea...
31.5
70
0.755102
d6ac3445e9752ddecb9abb253c9f94f7d63302db
4,452
py
Python
app/gws/gis/mpx/config.py
ewie/gbd-websuite
6f2814c7bb64d11cb5a0deec712df751718fb3e1
[ "Apache-2.0" ]
null
null
null
app/gws/gis/mpx/config.py
ewie/gbd-websuite
6f2814c7bb64d11cb5a0deec712df751718fb3e1
[ "Apache-2.0" ]
null
null
null
app/gws/gis/mpx/config.py
ewie/gbd-websuite
6f2814c7bb64d11cb5a0deec712df751718fb3e1
[ "Apache-2.0" ]
null
null
null
import re import yaml from mapproxy.wsgiapp import make_wsgi_app import gws import gws.config import gws.tools.os2 import gws.tools.json2 import gws.types as t
26.981818
140
0.482929
d6b063876a9be41e7ed553fff443124b3dd54143
955
py
Python
15_flask/projects/first-flask-app-lectures/2-returning-information/app.py
gdia/The-Complete-Python-Course
ed375b65242249bc749c3e292a6149f8528b9dcf
[ "MIT" ]
29
2019-09-02T21:15:59.000Z
2022-01-14T02:20:05.000Z
15_flask/projects/first-flask-app-lectures/2-returning-information/app.py
gdia/The-Complete-Python-Course
ed375b65242249bc749c3e292a6149f8528b9dcf
[ "MIT" ]
2
2020-08-20T05:48:36.000Z
2021-06-02T03:16:31.000Z
15_flask/projects/first-flask-app-lectures/2-returning-information/app.py
gdia/The-Complete-Python-Course
ed375b65242249bc749c3e292a6149f8528b9dcf
[ "MIT" ]
38
2019-10-20T14:29:12.000Z
2022-03-27T19:50:05.000Z
from flask import Flask app = Flask(__name__) posts = { 0: { 'title': 'Hello, world', 'content': 'This is my first blog post!' } } # This route expects to be in the format of /post/0 (for example). # Then it will pass 0 as argument to the post() function. if __name__ == '__main__': ap...
22.209302
120
0.617801
d6b22fdc51d86ccfb40fa796a0028614ac47e832
473
py
Python
desafios/desafio041.py
genisyskernel/cursoemvideo-python
dec301e33933388c886fe78010f38adfb24dae82
[ "MIT" ]
1
2020-10-26T04:33:14.000Z
2020-10-26T04:33:14.000Z
desafios/desafio041.py
genisyskernel/cursoemvideo-python
dec301e33933388c886fe78010f38adfb24dae82
[ "MIT" ]
null
null
null
desafios/desafio041.py
genisyskernel/cursoemvideo-python
dec301e33933388c886fe78010f38adfb24dae82
[ "MIT" ]
null
null
null
from datetime import date ano_nascimento = int(input("Informe seu ano de nascimento: ")) ano_atual = date.today().year idade = ano_atual - ano_nascimento if(idade <= 9): categoria = "MIRIM" elif(idade <= 14): categoria = "INFANTIL" elif(idade <= 19): categoria = "JUNIOR" elif(idade <= 20): categoria...
22.52381
108
0.67019
d6b2617ac4501dd9f309c3adb0b392ccd0c09209
8,402
py
Python
Algorithms/Searching/BFS_DFS.py
olgarozhdestvina/Python-Practice
bc4fa82ea9ddce085aff65e13db9af0213bd73b5
[ "MIT" ]
null
null
null
Algorithms/Searching/BFS_DFS.py
olgarozhdestvina/Python-Practice
bc4fa82ea9ddce085aff65e13db9af0213bd73b5
[ "MIT" ]
null
null
null
Algorithms/Searching/BFS_DFS.py
olgarozhdestvina/Python-Practice
bc4fa82ea9ddce085aff65e13db9af0213bd73b5
[ "MIT" ]
null
null
null
# Breadth First Search and Depth First Search if __name__ == '__main__': tree = BinarySearchTree() tree.insert(9) tree.insert(4) tree.insert(6) tree.insert(20) tree.insert(170) tree.insert(15) tree.insert(1) print('BFS', tree.breadth_first_seacrh()) print('BFS recursive', ...
32.440154
94
0.52059
d6b28e9c320ede94098fe9a203e88e1b2d2ee8fb
542
py
Python
bot/bot.py
Xithrius/Tabbot
3b499fbc7a58f84f612dec436a2396b47e4172d2
[ "MIT" ]
1
2021-11-14T04:13:06.000Z
2021-11-14T04:13:06.000Z
bot/bot.py
Xithrius/Tabbot
3b499fbc7a58f84f612dec436a2396b47e4172d2
[ "MIT" ]
null
null
null
bot/bot.py
Xithrius/Tabbot
3b499fbc7a58f84f612dec436a2396b47e4172d2
[ "MIT" ]
null
null
null
import random from discord import Game, Message, Status from discord.ext.commands import Bot
25.809524
75
0.640221
d6b2d831c8279558598bc5824ede22c12a555e25
16,204
py
Python
STED_analysis/pixel_detect.py
zhaoaite/dynamic_thresholding_algorithm
adcdfc7970098ab78c83d9aa86333f0a38d30bbb
[ "MIT" ]
3
2021-09-23T03:25:09.000Z
2022-03-11T15:23:18.000Z
STED_analysis/pixel_detect.py
zhaoaite/dynamic_thresholding_algorithm
adcdfc7970098ab78c83d9aa86333f0a38d30bbb
[ "MIT" ]
null
null
null
STED_analysis/pixel_detect.py
zhaoaite/dynamic_thresholding_algorithm
adcdfc7970098ab78c83d9aa86333f0a38d30bbb
[ "MIT" ]
null
null
null
import cv2 import numpy as np from matplotlib import pyplot as plt import os from scipy.stats.stats import pearsonr # #if HSV[2,3]==[178 ,255 ,204]: # # print("") # cv2.imshow("ex_HSV",ex_HSV) # cv2.imshow("HSV",HSV) # cv2.imshow('image',image)#img # #cv2.setMouseC...
39.715686
206
0.593989
d6b4c55f5a61a5f87b9b80c8d876610dc79b2561
800
py
Python
spot-oa/api/resources/impala_engine.py
maduhu/Apache-Spot-Incubator
208413c237bc54cf71792bf98f5ef2eef62b19f0
[ "Apache-2.0" ]
null
null
null
spot-oa/api/resources/impala_engine.py
maduhu/Apache-Spot-Incubator
208413c237bc54cf71792bf98f5ef2eef62b19f0
[ "Apache-2.0" ]
null
null
null
spot-oa/api/resources/impala_engine.py
maduhu/Apache-Spot-Incubator
208413c237bc54cf71792bf98f5ef2eef62b19f0
[ "Apache-2.0" ]
null
null
null
from impala.dbapi import connect import api.resources.configurator as Config
22.857143
71
0.68
d6b55b5caf47a3dab29dc3b05fc2f754488f7b0e
37,057
py
Python
ros/genpy/src/genpy/msg/_TestManyFields.py
numberen/apollo-platform
8f359c8d00dd4a98f56ec2276c5663cb6c100e47
[ "Apache-2.0" ]
742
2017-07-05T02:49:36.000Z
2022-03-30T12:55:43.000Z
ros/genpy/src/genpy/msg/_TestManyFields.py
numberen/apollo-platform
8f359c8d00dd4a98f56ec2276c5663cb6c100e47
[ "Apache-2.0" ]
73
2017-07-06T12:50:51.000Z
2022-03-07T08:07:07.000Z
ros/genpy/src/genpy/msg/_TestManyFields.py
numberen/apollo-platform
8f359c8d00dd4a98f56ec2276c5663cb6c100e47
[ "Apache-2.0" ]
425
2017-07-04T22:03:29.000Z
2022-03-29T06:59:06.000Z
"""autogenerated by genpy from genpy/TestManyFields.msg. Do not edit.""" import sys python3 = True if sys.hexversion > 0x03000000 else False import genpy import struct _struct_I = genpy.struct_I _struct_i = struct.Struct("<i") _struct_255i = struct.Struct("<255i")
32.735866
2,232
0.578487
d6b65d4115dcb823c97cd8a2465818354fb3a99d
2,352
py
Python
spacenetutilities/labeltools/geojsonPrepTools.py
Pandinosaurus/utilities
0a8ef43ff583eebcf28719d888de326ecfb7f69d
[ "Apache-2.0" ]
251
2016-09-09T09:39:05.000Z
2022-02-23T09:29:40.000Z
spacenetutilities/labeltools/geojsonPrepTools.py
Pandinosaurus/utilities
0a8ef43ff583eebcf28719d888de326ecfb7f69d
[ "Apache-2.0" ]
66
2016-09-09T14:08:24.000Z
2019-06-25T17:18:06.000Z
spacenetutilities/labeltools/geojsonPrepTools.py
Pandinosaurus/utilities
0a8ef43ff583eebcf28719d888de326ecfb7f69d
[ "Apache-2.0" ]
106
2016-10-01T03:49:46.000Z
2021-07-19T08:19:40.000Z
from spacenetutilities.labeltools import coreLabelTools import json import glob import argparse from datetime import datetime import os
31.783784
130
0.661565
d6b756077aa80cbde66d9fbcac2f9155733645a3
103
py
Python
xsdata/logger.py
nimish/xsdata
7afe2781b66982428cc1731f53c065086acd35c1
[ "MIT" ]
null
null
null
xsdata/logger.py
nimish/xsdata
7afe2781b66982428cc1731f53c065086acd35c1
[ "MIT" ]
null
null
null
xsdata/logger.py
nimish/xsdata
7afe2781b66982428cc1731f53c065086acd35c1
[ "MIT" ]
null
null
null
import logging import click_log logger = logging.getLogger(__name__) click_log.basic_config(logger)
12.875
36
0.825243