blob_id
stringlengths
40
40
directory_id
stringlengths
40
40
path
stringlengths
2
283
content_id
stringlengths
40
40
detected_licenses
listlengths
0
91
license_type
stringclasses
2 values
repo_name
stringlengths
3
135
snapshot_id
stringlengths
40
40
revision_id
stringlengths
40
40
branch_name
stringlengths
4
68
visit_date
timestamp[ns]date
2015-07-25 20:53:29
2023-09-06 10:46:05
revision_date
timestamp[ns]date
1970-01-01 00:00:00
2037-05-03 13:00:00
committer_date
timestamp[ns]date
1970-01-01 00:00:00
2036-02-09 17:40:36
github_id
int64
1.61k
691M
⌀
star_events_count
int64
0
209k
fork_events_count
int64
0
110k
gha_license_id
stringclasses
24 values
gha_event_created_at
timestamp[ns]date
2012-06-03 10:21:33
2023-09-14 21:59:50
⌀
gha_created_at
timestamp[ns]date
2008-03-27 23:40:48
2023-09-13 22:40:33
⌀
gha_language
stringclasses
250 values
src_encoding
stringclasses
27 values
language
stringclasses
1 value
is_vendor
bool
2 classes
is_generated
bool
2 classes
length_bytes
int64
6
10M
extension
stringclasses
289 values
filename
stringlengths
1
218
content
stringlengths
6
10M
130080c8e6cec576c30050818c0cd85b51d8ca71
82b187e2bae5bb892e580c3b1969d1115757365d
/logfire.py
901bef4da197f214d6c12d8509510e581bd272af
[]
no_license
hjacobs/logfire
4b505a8376ccb51d9a8880cfa226cc5b31cc098b
20bb9bf3634310a2423558e8154f6a1905535aa3
refs/heads/master
2023-05-27T21:24:23.454035
2014-01-06T09:30:38
2014-01-06T09:30:38
2,410,334
2
0
null
2014-01-06T09:30:38
2011-09-18T16:54:00
Python
UTF-8
Python
false
false
20,276
py
logfire.py
#!/usr/bin/env python # -*- coding: utf-8 -*- import collections import heapq import itertools import json import logging import os import signal import sys import time from threading import Thread from argparse import ArgumentParser from common import LogLevel, LogFilter from logreader import LogReader try: imp...
90e97fbfc419eb638b85c8f8ce6484447b261a5d
7364f67ec30af26e02cf894124a60478fdb56df7
/make_pipeline_jobs.py
e886e4974674c64399bc8b36c1b569ffa2b8184b
[]
no_license
RaymondSimons/clear_local
b5430bbaf198654b190f7e41f261337389b6a209
dd5dfbabd0149ef8323750a887640407dc6d1477
refs/heads/master
2021-06-15T08:14:42.452049
2021-02-24T15:47:00
2021-02-24T15:47:00
147,576,608
0
0
null
null
null
null
UTF-8
Python
false
false
1,258
py
make_pipeline_jobs.py
from astropy.io import ascii import numpy as np outdir = '/user/rsimons/submit_scripts/jobs/grizli_pipeline' fields = ['GS1','GS2', 'GS3', 'GS4', 'GS5', 'GN1', 'GN2', 'GN3', 'GN4', 'GN5', 'GN7', 'ERSPRIME'] sub_all = open(outdir + '/submit_all.sh', 'w+') for field in fields: sub_all.write('qsub ' + outdir +...
4fe568597cbd074d451e46b3034f1152d0cf2759
66365c12f889f629a8f8f820fdf22815bf36d65b
/chapter-4/chinanews_crawler/chinanews_crawler/items.py
32822a1aeb60b8ff0dde94ebb1b0ab5733657c3c
[]
no_license
DanielisLearning/crawling_the_web
cb568d2b7a2e35b75f5d87252fc4365ea655e441
c1342ae4f538de58b32e6a92945992b185211b79
refs/heads/master
2020-06-24T05:06:22.526423
2018-07-22T15:32:13
2018-07-22T15:32:13
null
0
0
null
null
null
null
UTF-8
Python
false
false
234
py
items.py
# -*- coding: utf-8 -*- from scrapy.item import Item, Field class NewsFeedItem(Item): title = Field() # 标题 link = Field() # 新闻详情链接 desc = Field() # 新闻综述 pub_date = Field() # 发布日期
7e43063060195ab69d1e2c0b9d9d5a76725767d1
2a9883a40f38c8b07584a2fe03899f51b76a7d83
/03/animal.py
8fb8d78c7ce6abbbf1d39a5c5dfeaaf2864816ab
[ "MIT" ]
permissive
yuanxiaodu/python-class
5d6eb450d4436b1091c6d9f3bed5d602e0b86467
daf84a84f6c34db410e3f489f443acdc5b3df977
refs/heads/main
2023-02-26T04:33:55.793960
2021-01-30T01:53:09
2021-01-30T01:53:09
313,225,345
9
5
null
null
null
null
UTF-8
Python
false
false
5,972
py
animal.py
class Animal: # 这里是属性定义 actually = "animal" # 类属性 def __init__(self, name, age): # 定义实例时,放在括号里的才要指定 self.name = name # 普通属性,要在__init__方法中定义 self.age = age # 下面是方法的定义 def sleep(self): # 普通方法 print(self.name, "is sleeping") def eat(self, food): # 普通方...
fd16291884dd30b4f64419cfd9222a56b78e7912
6c6cedc25927f644a40307bfa219faa56970426a
/KNearest/KNearestClassification.py
44119a40772fc632bb2885ce978e447710eb1635
[]
no_license
Seraphim-lyx/DataAnalytics
b98538b1f0b4d2ef13f328f086ea108f4e9d4d07
2bf29f3aa746273c2c04265274a40799d088c7f4
refs/heads/master
2021-09-09T09:20:38.532849
2018-03-14T17:36:33
2018-03-14T17:36:33
118,963,055
0
0
null
null
null
null
UTF-8
Python
false
false
636
py
KNearestClassification.py
import KNearest import operator class KClassification(KNearest.KNearest): """docstring for ClassName""" def __init__(self): pass def voteResult(self, neighborSet): voteSet = {} result = None v = 0 for i in neighborSet: if i in voteSet: ...
29c67210008104512d48ece6952fdb13fe3a9f8a
4da8257ba36171e261425191700c931dbcd970cf
/Swan_Task/urls.py
fb39c9284570f4029e17bd3e16420d233a0b8691
[]
no_license
rahulprajapati-in/Python_Task
f447e30434e31bb92283fdf89ef2934ebd8cdf97
dc50fa3691ed59c959a8ff468a975f063c3a84f7
refs/heads/main
2023-02-17T22:57:06.807336
2021-01-20T07:54:07
2021-01-20T07:54:07
331,231,669
0
0
null
null
null
null
UTF-8
Python
false
false
1,781
py
urls.py
"""Swan_Task URL Configuration The `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/3.1/topics/http/urls/ Examples: Function views 1. Add an import: from my_app import views 2. Add a URL to urlpatterns: path('', views.home, name='home') Class-bas...
c5d24d53fbaa2502bb1c1de34a6d47b1bb808f4c
b4b451568e36374cd74830f5629f258259193336
/pytglib/api/types/payment_receipt.py
1507638bc24e87133b4a3af2ce68bfb6fbf85282
[ "MIT" ]
permissive
enodr/pytglib
a898342193eaf48c163f845de76c4846dd295ba7
e5e75e0a85f89b77762209b32a61b0a883c0ae61
refs/heads/master
2022-07-04T21:44:35.170736
2020-05-14T08:30:43
2020-05-14T08:30:43
null
0
0
null
null
null
null
UTF-8
Python
false
false
1,898
py
payment_receipt.py
from ..utils import Object class PaymentReceipt(Object): """ Contains information about a successful payment Attributes: ID (:obj:`str`): ``PaymentReceipt`` Args: date (:obj:`int`): Point in time (Unix timestamp) when the payment was made payments_provider_use...
af5012bc3bdaff7cde6b0ef84e5a6ad5953f1291
4206cd723cae48f66ecb4a56bd2616de6ffba803
/tKinter/Backend.py
64ff882b72de62f3558fedba0c09e5bc521c399a
[]
no_license
ufp1000/Python
f285ea6dd68b99dab327a51f423fbd887f3fcd47
b074f9f607d496bab25235e73bfea6efd3cdab4e
refs/heads/master
2020-03-27T02:58:37.237288
2020-02-21T16:17:46
2020-02-21T16:17:46
145,830,461
1
0
null
2019-11-06T07:56:09
2018-08-23T09:19:20
TeX
UTF-8
Python
false
false
1,625
py
Backend.py
# -*- coding: utf-8 -*- """ Created on Tue Sep 18 23:01:19 2018 @author: Rahul.Mishra1 """ import sqlite3 def connect(): conn=sqlite3.connect("books.db") cur=conn.cursor() cur.execute("CREATE TABLE IF NOT EXISTS BOOK(ID INTEGER PRIMARY KEY,TITLE TEXT,AUTHOR TEXT,YEAR INTEGER,ISBN INTEGER)") conn.comm...
915dd70bbcccd03c51edb619dee53597a186b36f
2b14edb8c362018d32f38c2c4e5c98168a8af4d6
/db.py
11961cf0f05b7fe2b59d730ff4a05895b0a15018
[]
no_license
hndrxrtrash/dimas123456789
3a17213a91fbfe10babd9fc68bb3df63f8aef24c
be699a7932765bcb187938d995f57150d8573461
refs/heads/master
2021-01-19T20:24:05.849726
2017-04-17T12:56:18
2017-04-17T12:56:18
88,502,300
0
0
null
null
null
null
UTF-8
Python
false
false
710
py
db.py
from sqlalchemy import Table, Column, Integer, String, MetaData, create_engine import os db = create_engine(os.environ['DATABASE_URL']) metadata = MetaData(db) ''' image_table = Table('images', metadata, Column('id', Integer, primary_key=True), Column('user', Integer), ...
2d95e68baa24ddd89765440dd5fd4ac95d1d7057
575f91e81238eeba0a114d2360a7a727440649ba
/sign_hunter_attention_attack/attack.py
e706989bb4ce07b3695f37d6de54f9207d28fb4d
[]
no_license
Lappuccino/SimulatorAttack
34075c2f5c6f424062a2e06ff32379c17e31f619
94d91639c55d594f1b9ee4212c3b99b1f0941a9c
refs/heads/master
2023-06-09T09:35:51.018553
2021-06-18T03:45:00
2021-06-18T03:45:00
null
0
0
null
null
null
null
UTF-8
Python
false
false
27,545
py
attack.py
""" Implements SignHunter """ import json import os import sys from collections import defaultdict from sign_hunter_attention_attack.grad_cam import GradCAM sys.path.append("/home1/machen/meta_perturbations_black_box_attack") import argparse from types import SimpleNamespace import glob import numpy as np import to...
23adcabd137e48761da0d88838cfda70cc83c703
b788c7d59bffbaf1c8f9782a3b0beb9fea209caa
/localff/localff4.py
4906d76c9c64e07d42d1b63631d60160dc76a18c
[]
no_license
maariolopezz/CS523
e1efacf0cdb86fa9abfad66c1dde6225dc7bb46b
357572c97c0227de4fdaaf4cd283ccf679299c0d
refs/heads/main
2023-02-08T13:48:20.557062
2020-12-17T01:52:19
2020-12-17T01:52:19
321,840,994
0
0
null
null
null
null
UTF-8
Python
false
false
746
py
localff4.py
import time import os import csv os.system('(echo 3 | sudo tee /proc/sys/vm/drop_caches) > /dev/null') time.sleep(1) tinit = time.time() os.system("ffmpeg -i /home/centos/movedFiles/Test\ Media/C0003-UHD.MP4 -c:v libx264 -b:v 25000k -vf scale=1920:1080 -framerate 60 /home/centos/movedFiles/sTrans1.mp4 -loglevel fata...
740e3c96b8502f9f8495fe739a4a4cd8838948a0
04a5ad514dd0e691808563fee7900087d03b7bc8
/test.py
ae076be48ac923542bd1d2eddf2761a2341d1395
[]
no_license
zhubinQAQ/codes_stuff
9275a6f4ddc15b93d7f8fc9871c5ed4f42f4dafd
973d45c01bd7e7c8e54cbae281d921971e56f2f9
refs/heads/master
2020-08-19T18:59:35.833609
2019-11-23T14:45:42
2019-11-23T14:45:42
215,945,231
0
0
null
null
null
null
UTF-8
Python
false
false
310
py
test.py
from codes_stuff.utils.misc import log_info from codes_stuff.test_data import test_data from codes_stuff.task import * def main(): log_info(' ===== start test =====') timers = test_8(test_data[8], (1, )) for timer in timers: log_info(timer.all()) if __name__ == '__main__': main()
20457c1ba97bd4c5f45451f05e468666c7ff37bd
eb1b07213b55e7646e0fcfb8e1190f84a102fca0
/tests/unit/bo/test_gpy_model.py
102a44aa1c6d69224121ebbb7070e51cf0cdf4f3
[ "BSD-3-Clause" ]
permissive
ashdtu/elfi
ddd14d44b9df0dcef73d41e238dea27b75f4b202
e06c9a3ff80c1e3b4a8899dcfab33738eeb96c74
refs/heads/master
2021-01-18T16:03:54.223497
2017-03-01T08:36:44
2017-03-01T08:36:44
null
0
0
null
null
null
null
UTF-8
Python
false
false
3,065
py
test_gpy_model.py
import numpy as np from elfi.bo.gpy_model import GPyModel class Test_GPyModel(): def test_default_init(self): gp = GPyModel(noise_var=0.) assert gp.n_observations == 0 assert gp.evaluate(np.random.uniform(0.0, 1.0, (1,))) == (0.0, 0.0, 0.0) def test_one_1d_sample(self): bounds...
17e6ad426821c0910127c910df95c9d6301f861e
1c795ab8cc61c843b4cb92d84ba5803fea494015
/src/jsbsim/actuators/directcontrol.py
0918d756e23a75eb03af6c99527039410cba04c2
[]
no_license
zhj149/morse-jsbsim
17c1702d46bf9487e1508b35403fd972705cb068
2d9aa1e3bf9fd1b8c811f09fbccb227aa5a30410
refs/heads/master
2020-10-02T10:14:45.334197
2015-11-24T11:42:07
2015-11-24T11:42:07
null
0
0
null
null
null
null
UTF-8
Python
false
false
1,012
py
directcontrol.py
import logging; logger = logging.getLogger("morse." + __name__) from morse.core.external_object import ExternalActuator from morse.helpers.components import add_data, add_property class DirectControl(ExternalActuator): """ The DirectControl actuator takes some control value, such as engine power and apply...
df7bf8402b674d7a285a4d8cd417387954f2c8f1
6def6ba9d018c898afd1e518ad66e1a67909ba73
/teamc_pipline/data_mapper_old.py
4f3ab73ca85a2120b6aeed86f0fca2a55702862b
[]
no_license
mediteamC/teamC
80676735058ea53063335564b9311758c4e009cf
62127bb4443a3d1edbb63dea5092dbcaa2fb61fa
refs/heads/master
2020-04-02T14:43:47.204797
2019-01-02T21:40:10
2019-01-02T21:40:10
154,536,380
3
1
null
null
null
null
UTF-8
Python
false
false
3,434
py
data_mapper_old.py
import pandas as pd import numpy as np import matplotlib.pyplot as plt import os import glob import json import tarfile import zipfile import nibabel as nib from nilearn import plotting from sklearn.preprocessing import normalize import torch import torch.utils.data class data_mapping(object): def _...
b435a2ac4a7c368a64b8f5627664e28770a0d79c
14460d0c67a2c3c8e8f172bdc10d68af911f4c7e
/fun/demo9.py
d30d954211c1a90ecdbdcf02a201c9aae756ad6e
[]
no_license
shri9098/Pythoin_list
b29524d20a5bfc4fe10c53a457f03e1a2f32319c
26de71c59e26dbf414485883936925ef232a2ac4
refs/heads/master
2020-09-07T02:23:24.244931
2019-11-09T10:59:59
2019-11-09T10:59:59
220,628,729
0
0
null
null
null
null
UTF-8
Python
false
false
151
py
demo9.py
def find_max(): l = [1, 3, 5, 21, 7, 9, 11, 13] max = l[0] for x in l: if x > max: max = x print(max) find_max()
d55f3e2e961b2dd85f35598632cd92502e15bf75
0775601c127a4805839dc4f4060522fe74b0edb5
/services/ingestion/googleSheets/tests/test_google_sheets_webhook_process_lambda.py
d25e5261556ea8f6806b2f9c09e90daa5e162c78
[]
no_license
knowit/Dataplattform
f6545a45ec63c5ce7b6ca3b8083cd8bb2b2c4f11
65948911c528e81ed9e4aeca93fd64c17093693e
refs/heads/main
2023-07-06T17:03:52.454216
2023-06-12T07:54:53
2023-06-12T07:54:53
232,749,580
3
1
null
2023-06-27T08:33:16
2020-01-09T07:32:49
Python
UTF-8
Python
false
false
4,365
py
test_google_sheets_webhook_process_lambda.py
from googlesheets.google_sheets_webhook_process_lambda import handler as process_handler from dataplattform.common import schema from json import load from os import path from pytest import fixture import pandas as pd @fixture def setup_queue_event(s3_bucket): def make_queue_event(data: schema.Data): s3_b...
a965db96c8675aa7457040c23f68b7bc8d707b68
34bee6d1c5e4b5c8ec3dc952e1e2d8c662581a88
/src/utils/views.py
fed732c05551171ca9347f16dbe0cb8028861f99
[]
no_license
sagarborse/comm-serv
ed9b9f6f8bab29bf508d0a6b1941055187243b99
fefc9c073dadbc2b180a1972a1b8101e688a5510
refs/heads/master
2022-09-27T08:41:31.581423
2019-05-31T12:59:54
2019-05-31T12:59:54
189,592,672
0
0
null
2022-09-13T23:02:43
2019-05-31T12:46:59
Python
UTF-8
Python
false
false
842
py
views.py
from django.shortcuts import render from rest_framework.exceptions import APIException from rest_framework import status from django.http import HttpResponse, JsonResponse # Create your views here. response = {} def handler404(request, exception): response['errors'] = str(exception) response['status'] = 400 return...
9d7267ac2af7cf8baf0599186fa69b8bf617c661
160a5d85277f47fc3a2b49a946683ca9e952a06f
/plotly/validators/scattergeo/marker/colorbar/_tickformatstops.py
d8f140c3cd7aa31fe18e4e6ae2dac79488e45b37
[ "MIT" ]
permissive
faezs/plotly.py
dbf6ce4825a9201980d820c22c6a6177e0b3d459
6009b5b9c746e5d2a2849ad255a4eb234b551ed7
refs/heads/master
2020-03-22T08:26:57.398689
2018-07-16T21:22:19
2018-07-16T21:22:19
139,767,048
0
0
MIT
2018-07-16T21:22:20
2018-07-04T21:24:01
Python
UTF-8
Python
false
false
870
py
_tickformatstops.py
import _plotly_utils.basevalidators class TickformatstopsValidator( _plotly_utils.basevalidators.CompoundArrayValidator ): def __init__( self, plotly_name='tickformatstops', parent_name='scattergeo.marker.colorbar', **kwargs ): super(TickformatstopsValidator, self)...
054c2a7a8b0e70437246fb511669a11fd91f9cfb
8b03bfa99cc496aeeedd1cff77d6e8d3f9111e64
/models/models.py
91a61c3b3caaf1ee528c3c8b767c480c00b52f13
[ "LicenseRef-scancode-warranty-disclaimer", "LicenseRef-scancode-unknown-license-reference", "MIT" ]
permissive
ZainabTalib29/MoCoGAN-HD
a054d425fc7a3e0d8f6c85f90775015b89961695
27356baa0518bc69507106d9c8817753520d2082
refs/heads/main
2023-07-25T11:27:34.190244
2021-09-09T18:09:39
2021-09-09T18:09:39
null
0
0
null
null
null
null
UTF-8
Python
false
false
4,207
py
models.py
""" Copyright Snap Inc. 2021. This sample code is made available by Snap Inc. for informational purposes only. No license, whether implied or otherwise, is granted in or to such code (including any rights to copy, modify, publish, distribute and/or commercialize such code), unless you have entered into a separate agree...
44705bfe1918ad19ed24cd36812de664b8930882
77ae773c5b872b78de10ad1c64db4e0c77bf6b4a
/LvyiNoKDJ/LvyiNoKDJ_Parameter.py
316bc07539d36d3c09ffd90878503d4d7f9480e5
[]
no_license
longfeiw07/LvyiWinCode
d46e22022f79d97c3bd898e138493d435f2a750c
a34b0a9fbaea48654072f430d57374f681488433
refs/heads/master
2021-05-20T19:49:21.872802
2018-08-16T10:01:02
2018-08-16T10:01:02
null
0
0
null
null
null
null
UTF-8
Python
false
false
1,740
py
LvyiNoKDJ_Parameter.py
# -*- coding: utf-8 -*- ''' 策略参数设置 ''' #参数设置 strategyName='LvyiNoKDJWin' exchange_id = 'SHFE' sec_id='RB' K_MIN = 600 startdate='2016-01-01' enddate = '2017-12-31' parasetname = 'ParameterOptSetNoKDJ.csv' #=============止损控制开关=================== calcDsl_close=False calcOwnl_close=True calcDslOwnl_close=False #dsl参数 dsl...
3858b1243d9af3fd4ae601ddbebc857c3240b55c
1eaebf26cf834e30af45d663c69b9927db987959
/data/write_yaml.py
b4271a6a7d820e4e86d33e29a5c6cd3ce00696f0
[]
no_license
yongxin-69/bj_app17_day09
70bf39a7e9ed53d1bca16008bab7c868e08959a5
294f1251c0d0d3181594a3a8058a7a03008aad58
refs/heads/master
2020-11-29T07:34:19.723988
2019-12-25T07:21:53
2019-12-25T07:21:53
230,059,016
0
0
null
null
null
null
UTF-8
Python
false
false
331
py
write_yaml.py
import os import yaml w = os.getcwd()+os.sep+"data.yml" # a 追加模式 w 覆盖模式 with open(os.getcwd()+os.sep+"data.yml","w",encoding="utf8") as f: data = {'info': {'name': '你好', 'phone': 's'}, 'add': {'name': '你好', 'phone': 's', 'detail': 'TBD'}} yaml.safe_dump(data,f,encoding="utf8",allow_unicode=True)
e007310bd8f4e1278d51769b3ecd23205fac9cbc
ff165a40e65711a798bc4bb87a0d572277c130ef
/speasy_proxy/routes.py
ef869eac388df43774405643030ca699e9200bfe
[]
no_license
SciQLop/speasy_proxy
925305ede33a3a9e86e1fb73d4e515351d5306a6
1a8f13c5f79f247c0d8a8308c3208ae3219725b6
refs/heads/main
2023-06-26T10:32:41.251582
2023-04-06T12:56:34
2023-04-06T12:56:34
226,547,856
1
2
null
2022-11-11T01:22:23
2019-12-07T17:05:51
Python
UTF-8
Python
false
false
479
py
routes.py
def includeme(config): config.add_static_view('static', 'speasy_proxy:static', cache_max_age=3600) config.add_route('home', '/') config.add_route('get_data', '/get_data') config.add_route('get_cache_entries', '/get_cache_entries') config.add_route('get_speasy_version', '/get_speasy_version') con...
6d094aa3f284b9ba2921a7731f551b269a9590f8
13a3ae1e532e38daae0ebab3d121d925ce7bee67
/parser.py
a80d5f2ed99e848e5cd551e35a1aed9559858be5
[]
no_license
andy-wagner/Thesaurus
dcfb907d1aa90a495878b4c212288952a26e2c84
37aaaf4a2fb9908b10e2b897964b79065d76eefd
refs/heads/master
2021-05-26T18:15:52.808317
2013-08-09T15:58:40
2013-08-09T15:58:40
null
0
0
null
null
null
null
UTF-8
Python
false
false
2,067
py
parser.py
import time dict = [[]] parsed = 0 def init(num_docs): global parsed global dict dict = [[]] try: parse_file() except: pass populate(num_docs) condense() write_to_file() #print_dict() def graph_string(): with open('graph_string.txt','w') as f: for list in dict: for (a,b) in list: for i in r...
9553d2433807ee8b03b18e98eabe3b0df06043d6
f13850e0a490e9dec7a9cb10f56b6c68c33f769f
/GMO/GMOAlgebra.spec
2664a8274b2cf6363e366c48894a5fb1b26aa8f8
[]
no_license
meraioth/IDMMO
497e5e2cca0185185b50be23f0d3724459f1085b
baa8771879f70ab24fc71c1c4b71e38d53be3998
refs/heads/master
2021-07-24T11:55:16.032938
2020-04-19T01:11:28
2020-04-19T01:19:42
144,625,053
0
0
null
2020-01-31T01:49:44
2018-08-13T19:33:27
C++
UTF-8
Python
false
false
988
spec
GMOAlgebra.spec
operator creategenericmpoint alias CREATEGENERICMPOINT pattern op ( _ , _ ) operator creategenericpoint alias CREATEGENERICPOINT pattern op ( _ , _ ) operator mapping alias MAPPING pattern op ( _ , _ ) operator map2fs alias MAP2FS pattern op ( _ ) operator map2network alias MAP2NETWORK pattern op ( _ , _ ) operator dis...
1758bfb12e565292ca315770ba62c4f2ae0d54b4
228c7003d5d2bd0d9f8fb0b24be2c946a204f0d6
/algorithms/198.House_Robber/House_Robber.py
a75932919b932300a6fe35b12eafeaf6c16451e8
[]
no_license
shitangdama/leetcode
ddb94acc91a67116215eefc4f688967c6848d87f
f8c2db40f74b2e7dd657b7f45c3922d33673bb46
refs/heads/master
2020-05-03T20:04:49.931596
2020-03-04T00:10:52
2020-03-04T00:10:52
33,526,926
9
2
null
null
null
null
UTF-8
Python
false
false
485
py
House_Robber.py
class Solution: # @param num, a list of integer # @return an integer def rob(self, num): if len(nums) == 0: return 0 if len(nums) == 1: return nums[0] dp = [0]*len(nums) dp[0] = nums[0] dp[1] = max(nums[1], nums[0]) for i in range(2,...
68346f8edb605ef3d79195c9d1c781e24e3e4b9f
6f1094c708ad217a4950daecd45b57efc9040bec
/tests/providers/test_pushbullet.py
3f7e640c6d4bc87007f9a1e275fd749ee18b6cb5
[ "MIT" ]
permissive
plunix/notifiers
602a3703e17ec576d5e1059c67d4028bc0eae065
5d2a804f5e9161c3cc2067d923cbeb37b6c61967
refs/heads/master
2021-09-01T06:31:17.982252
2017-12-25T09:27:40
2017-12-25T09:27:40
null
0
0
null
null
null
null
UTF-8
Python
false
false
1,507
py
test_pushbullet.py
import pytest from notifiers import get_notifier from notifiers.exceptions import BadArguments class TestPushbullet: def test_metadata(self): p = get_notifier('pushbullet') assert p.metadata == { 'base_url': 'https://api.pushbullet.com/v2/pushes', 'provider_name': 'pushbul...
41bca89ce63fe56a1af6af83c465488fa20def90
adc08d7957c1eaad062407c754b436ca6ec8eb7f
/code/get_1993J.py
04a46c30c1f946e10122c614b6989bb36142a5a5
[]
no_license
annayqho/AT2018cow
2497f101c39c1984b4685b2d90a8bda89d505922
74bda4b91c647898665122dceb45433109bcb403
refs/heads/master
2022-08-07T03:50:02.924055
2022-07-12T20:30:32
2022-07-12T20:30:32
139,064,247
0
1
null
null
null
null
UTF-8
Python
false
false
1,785
py
get_1993J.py
""" Format the 1993J measurements """ import numpy as np from astropy.table import Table def run(dt, freq, flux, dat, col, freqval): dt_temp = dat['col2'] flux_temp = dat[col] npts = len(flux_temp) dt.extend(list(dt_temp)) for i in np.arange(npts): freq.append(float(freqval)) flux.ex...
1305cadae912f9f3462992529cda0266bf390416
10b5f5b9a5440bdba1a408ccc76a88faba7fa28c
/tests/processing_components/test_imaging_params.py
795efd90c8d3abb16b7cddd31f2dec7f4a2cbad1
[ "Apache-2.0" ]
permissive
rtobar/algorithm-reference-library
10753145d13b084fae2921a5cd82c0099d7e6264
a0038215e85703c94f4687d1f6b90538b6e7ee03
refs/heads/master
2020-03-20T21:18:50.812897
2018-08-22T07:49:40
2018-08-22T07:49:40
137,734,699
1
0
null
2018-06-18T09:46:12
2018-06-18T09:46:12
null
UTF-8
Python
false
false
5,076
py
test_imaging_params.py
""" Unit tests for Fourier transform processor params """ import logging import unittest import numpy from astropy import units as u from astropy.coordinates import SkyCoord from data_models.polarisation import PolarisationFrame from processing_library.imaging.imaging_params import get_frequency_map, w_kernel_list...
b0b63992a4fb0b60e20e8fb62624094d33ac46d8
db8efd98ca7fc196c57c85ee24bb39de90a177d6
/Science/urls.py
8b1a408ad115cfd7af684ec308129d9274d79471
[]
no_license
SeeWord/CompanyProject
43bef08487cc142bdeb02bff0e52fc6016202a9f
bbbdb2eaebeb4a3253cf395dd8a1a9c930bdb9a5
refs/heads/master
2022-12-25T03:34:34.073081
2020-09-28T01:06:15
2020-09-28T01:06:15
297,900,763
0
0
null
null
null
null
UTF-8
Python
false
false
150
py
urls.py
from django.urls import path from . import views from .views import Science urlpatterns = [ path('Science', Science.as_view(),name='science'), ]
f9f40a2266b432a11a410eb92e3489fd95fa96b0
cc160d6831514ba4e6c5f8e1fddce4da8c724478
/miniproject1/calibrationDataTest.py
823561e6fa7d5f4f6d3410b578bd0f7e15c16cf5
[]
no_license
amuthaOlin/elecanisms
5d9aeeffdd8f7afdc34e1603caa61f7051d5f9b1
7c28299588de5c9a985665603e4a8c5ebb880c88
refs/heads/master
2021-01-18T14:46:24.836214
2016-02-22T06:15:33
2016-02-22T06:15:33
50,120,436
0
0
null
2016-01-21T16:28:26
2016-01-21T16:28:26
null
UTF-8
Python
false
false
939
py
calibrationDataTest.py
import matplotlib.pyplot as plt import numpy as np #data1 = 275.7, 119.5, 296.6, 130.4, 299.0, 128.8, 305.4, 124.7, 308.7, 136.4, 316.8, 166.3, 291.2, 174.9, 18.6, 209.8, 67.3, 242.3 # data = 187.4, 1.6, 191.4, 9.4, 214.2, 57.2, 234.5, 75.7, 258.2, 102.8, 287.5, 129.6, 314.6, 142.0, 349.3, 171.0, 20.0 # errorList = ...
e056bab2d8dbc133fa7f3b3714010d42a1ed602b
bf963df06bcebec75868bc0c856d9656d8ac228f
/notebooks/scripts/book_code/code/N.py
58f166f0cbc6d85865cb14800446998723ce149c
[ "Apache-2.0" ]
permissive
TazoFocus/UWF_2014_spring_COP3990C-2507
aac6f0a4c9fee7ace46073c7ff509fe8a67128e9
4556dff9abde18c0e30f757e1245005580c75e1b
refs/heads/master
2020-04-05T18:57:41.234068
2014-03-17T18:07:29
2014-03-17T18:07:29
null
0
0
null
null
null
null
UTF-8
Python
false
false
106
py
N.py
import inspect def printer(): print 'I am in function', print inspect.getfile(inspect.currentframe())
a179c0c0d265af23b2281a9679c3f2dfb25bb48a
eb54d732b5f14f03d9bf2988c6157605c80bbdd5
/height_balanced_bst.py
fcb215dc2a14b00e9363f38dacce96d6b2e5e12c
[]
no_license
tngo0508/practice_coding
2e60519fed83a9b3c28b52c2d5ec1ee1d2a609ed
453c9a7b9a8aa80f37b245f9df447525a9b0a2d1
refs/heads/master
2022-03-27T01:44:56.589650
2020-01-05T18:58:31
2020-01-05T18:58:31
225,294,423
0
0
null
null
null
null
UTF-8
Python
false
false
755
py
height_balanced_bst.py
class Node: def __init__(self, value, left=None, right=None): self.value = value self.left = left self.right = right def height(tree): if tree is None: return 0 return max(height(tree.left), height(tree.right)) def helper(tree): if tree is None: return 0 ...
5f521f0fddcd00ccc668c96a0db68d9674c31c0c
deb743508da6ad5d60955609bc5616d9d3819f89
/SmartHome/templates/stateMachine.py
5b5598b520f696833909bff19051314ee339ec7b
[]
no_license
Zbysekz/SmartHome
cef1d22d7df64830a834b26260c414b1dabeda90
8d6e9420549728345351d0b9ca145188ff9f2800
refs/heads/master
2023-08-21T01:16:11.773939
2023-08-06T11:59:33
2023-08-06T11:59:33
137,071,009
0
0
null
null
null
null
UTF-8
Python
false
false
1,120
py
stateMachine.py
import time tmrTimeout = 0 def STATE_idle(): NextState(); def STATE_SMS_send(): NextState(); def STATE_SMS_wait(): if False: NextState(STATE_idle); if CheckTimeout(5): Log("Timeout in state:"+str(currState)) NextState(STATE_idle) stateList = [ STATE...
4102db29f4037edbc60fa3660d59b1c9a0169a48
9ad240c73681a099fdc44fda64afdc8c6473a653
/crosshair/libimpl/datetimelib_test.py
2e730b6efa3b9a1dade2566deb135c386ae44ee0
[ "MIT", "LicenseRef-scancode-unknown-license-reference", "Apache-2.0", "Python-2.0" ]
permissive
pschanely/CrossHair
acde7ed4f1758da1f4a26f0a97fc79be046961d3
32124a04f3920234fbb4bb9045c21238f78b8086
refs/heads/main
2023-08-24T11:43:16.340977
2023-08-16T17:06:31
2023-08-16T17:06:31
101,762,821
935
53
NOASSERTION
2023-09-10T20:28:36
2017-08-29T13:11:40
Python
UTF-8
Python
false
false
2,822
py
datetimelib_test.py
import datetime import pytest from crosshair.options import AnalysisOptionSet from crosshair.statespace import CANNOT_CONFIRM, EXEC_ERR, POST_FAIL from crosshair.test_util import check_states _SLOW_TEST = AnalysisOptionSet(per_condition_timeout=20, per_path_timeout=4) def test_timedelta_symbolic_months_fail() -> N...
d0d9a2b9da031d991c4619aae2a6b8e718761873
55344865aa9f495f5067bf07879cfc7efaf3f14c
/bert_lstm.py
a3fd077c887838a7438a4c3afbb76c3c8cfc3be5
[]
no_license
masterzjp/Keras-BertFc
24d0c746e04c485095858f21e4c90dfc0417acf4
b99a6b298a5edf89a3bd549c250a3a90e8ffa5e2
refs/heads/master
2023-02-15T13:52:45.168111
2021-01-06T14:54:35
2021-01-06T14:54:35
326,178,184
0
0
null
null
null
null
UTF-8
Python
false
false
4,241
py
bert_lstm.py
# coding:utf-8 import os import codecs import random import numpy as np import tensorflow as tf from keras.models import Model from keras.optimizers import SGD, Adam from keras.layers import Input, LSTM, GRU, BatchNormalization, Dense, Dropout, GlobalAveragePooling1D, Masking, Concatenate from keras.callbacks import Mo...
a0e4abb4a6d4275aa1c20c7bc21a3b909c764032
5a52ccea88f90dd4f1acc2819997fce0dd5ffb7d
/alipay/aop/api/response/KoubeiTradeKbpaymentPayorderSyncResponse.py
53f02d8dd09689b967fe6c34a58d2bcad305fe1f
[ "Apache-2.0" ]
permissive
alipay/alipay-sdk-python-all
8bd20882852ffeb70a6e929038bf88ff1d1eff1c
1fad300587c9e7e099747305ba9077d4cd7afde9
refs/heads/master
2023-08-27T21:35:01.778771
2023-08-23T07:12:26
2023-08-23T07:12:26
133,338,689
247
70
Apache-2.0
2023-04-25T04:54:02
2018-05-14T09:40:54
Python
UTF-8
Python
false
false
745
py
KoubeiTradeKbpaymentPayorderSyncResponse.py
#!/usr/bin/env python # -*- coding: utf-8 -*- import json from alipay.aop.api.response.AlipayResponse import AlipayResponse class KoubeiTradeKbpaymentPayorderSyncResponse(AlipayResponse): def __init__(self): super(KoubeiTradeKbpaymentPayorderSyncResponse, self).__init__() self._request_id = None...
0e9e6702d65e553e742b256e45c2441b72642df0
8226de6c976caa9a8f8ac2d6bed914ce94e511a9
/hdd.py
5bc11d875c5f90ec7bd0c2c635d61651c84fdd3a
[]
no_license
1wq2/InPD
e255cf2bc6b9f75fb7da0a8a3a76a7b212cb5ede
8bc65e598a4d54c7afc69212430c1697ba00c15f
refs/heads/master
2021-05-07T23:07:58.151057
2017-12-23T09:30:29
2017-12-23T09:30:29
107,395,288
0
0
null
null
null
null
UTF-8
Python
false
false
301
py
hdd.py
import os import subprocess import re subprocess.call("sudo hdparm -I /dev/sda > " + os.getcwd() + "/log.txt", shell=True) logfile = open(os.getcwd() + "/log.txt") dictianory.update(tempDict) path = os.path.join(os.path.abspath(os.path.dirname(__file__)), os.getcwd() + "/log.txt") os.remove(path)
7fe9fd0ed382280dec38387b5873d096d55c6ccb
889ffd2ef755ecb7694d661fb1234fd425165d7e
/fish_tank_final_computerVersion.py
2e34022e02944ca89fe5c84f140ca8d8221c274b
[]
no_license
mitchellvitez/Bubble-Bonanza
558b7b77212a8c2af0784fe479877bf9b944918f
6f8b8913b959bf59b601353365698c76d3459a8f
refs/heads/master
2021-01-23T03:13:27.940465
2014-11-21T17:01:58
2014-11-21T17:01:58
null
0
0
null
null
null
null
UTF-8
Python
false
false
47,612
py
fish_tank_final_computerVersion.py
############################################################################ ## Program: Fish Tank ## ## Programmers: John Groot, June Chew, Mitchell Vitez ## ## Artists: Lauren Breeding, Drew Blazewicz ## ## Purpose: Create the Fish Tank game as ...
cab059313d3d72e1a9e9c959656fd65cbde899da
2dda06786774b7f42896e1c375cf4ed272aeb43b
/mock_server/helpers.py
63f53b345db7141fe5b7277c2a6ce4e879517e8b
[]
no_license
AlphaRishi1229/Masquerader
b7479ba0e151c6823d6f8867e9b666e8619aec96
ada3449ca736be69563a93e0c9a4493805be15b7
refs/heads/main
2023-03-05T06:25:19.827424
2021-02-22T11:52:02
2021-02-22T11:52:02
341,181,084
0
0
null
null
null
null
UTF-8
Python
false
false
8,007
py
helpers.py
"""The helper class where all functions are done.""" import json import secrets from common import utils from dotty_dict import dotty from fastapi import HTTPException from starlette.responses import Response from mock_server import crud indexed_urls = [] def UserAuth(credentials, db): """Used for User Authent...
78a6fb3c3c8f0081c34087c7c139b4c884ff9d8c
74ddf0dfbdfcefcdbce75101413e196a2b53dab2
/passgen.py
167b815c2340d967116cbc24b5eacc5e6a0ba944
[]
no_license
Sladge17/Password-generator
30082e140d868a3cf7893a2a64cf0611bf20b2b5
834b4a2c3c8c4d46b3318bbf8a7dfe54df7d487f
refs/heads/master
2023-02-12T15:50:10.579318
2021-01-13T16:22:05
2021-01-13T16:22:05
329,356,482
0
0
null
null
null
null
UTF-8
Python
false
false
1,184
py
passgen.py
import random letter_1 = 'abcdefghijklmnopqrstuvwxyz' letter_2 = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' numb = '1234567890' spec = '!@#$%^&*()-+' symb = (letter_1, letter_2, numb, spec) def gen_pas(count): if count < len(symb): return ("Unsafe length") password = [''] * count for i in range(len(symb)): r_sy...
1b5580dd995f42423c625b5de469cbd59e004496
0c69245e090ff9df0c8e51a0a3bb170416763dbb
/timeprimes.py
ab3e36b4b3e2ba9dac61aecb9fa287f3a3523ed3
[]
no_license
andrew-social/learn_python
4f914bbabd8abffacf48eff6874f1807795cbd0d
8800d43be430a9d8f0c359b4783854ffccec0280
refs/heads/master
2020-05-16T10:42:40.060288
2019-04-23T10:28:22
2019-04-23T10:28:22
182,991,851
0
0
null
null
null
null
UTF-8
Python
false
false
1,256
py
timeprimes.py
def approach1(givenNumber): # Initialize a list # print("givenNumber = ", givenNumber) primes = [] for possiblePrime in range(2, givenNumber + 1): # Assume number is prime until shown it is not isPrime = True for num in range(2, possiblePrime): if possiblePrime % num ...
c16aa469e756dc21e2ba67a80112bc00b467c231
cf670d0c9636cf75387774906eb1af7b1d337985
/buxfer_to_db/custom_settings.py
b86509c49ee462d0ff2faef3d07b2c5e5bdfcf40
[]
no_license
javiermarcon/buxfer_api_to_db
e6f323bfdb0bea429c8ddfd63c34e89f83fb0c08
0fe9434498a3b79af2758136b4f8b68ec62fa274
refs/heads/master
2023-03-24T08:11:45.497610
2021-03-24T18:54:09
2021-03-24T18:54:09
282,561,803
0
0
null
null
null
null
UTF-8
Python
false
false
721
py
custom_settings.py
import os # Build paths inside the project like this: os.path.join(BASE_DIR, ...) BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) # SECURITY WARNING: keep the secret key used in production secret! SECRET_KEY = '' # SECURITY WARNING: don't run with debug turned on in production! DEBUG = True ...
86da750ddf9f1c20e68e8821c8eed880fc78b2ea
c12fd05b76f1c5caa30813f57217b11c40d59c35
/api/src/common/common.py
ebd1f9b456ad09b9fccf6c147bd7336180badf4b
[]
no_license
happystocks/machine-learning-practice
7e839152ec5abc4eaec983de41ee1da2a01fe9ec
12cc39dd7c47094a6f29b1fd974cf989593d8d86
refs/heads/main
2023-01-19T16:49:13.539775
2020-11-16T07:30:12
2020-11-16T07:30:12
305,041,868
0
1
null
2020-11-16T07:30:13
2020-10-18T06:58:08
Python
UTF-8
Python
false
false
130
py
common.py
import sys, os raw_dir = os.getcwd() data_dir = os.path.join(raw_dir, 'Data') model_dir = os.path.join(raw_dir, 'Trained_Model')
6b08ea2f4d9c028acfb31f8f15af4c74cb4929a4
bd4144e919786b4aded4345a2a69ed79e0922946
/4월 4주차/소형기관차.py
8d909486558c6306a82f2143878757d0b836ae4e
[]
no_license
2020-ASW/kwoneyng-Park
670ee027a77c1559f808a51aaf58f27ab3bb85b9
3ef556889bbf3f2762c01fdfd10b59869d5e912f
refs/heads/master
2023-05-14T16:14:04.227511
2021-06-11T08:00:37
2021-06-11T08:00:37
321,286,504
0
0
null
null
null
null
UTF-8
Python
false
false
593
py
소형기관차.py
n = int(input()) arr = list(map(int,input().split())) m = int(input()) prefix = [0]*(n+1) for i in range(n): prefix[i+1] = arr[i] + prefix[i] amount = [0]*(n) for i in range(n): if i+m <= n: amount[i] = prefix[i+m] - prefix[i] else: amount[i] = prefix[-1] - prefix[i] dp = [[0]*n for _ in...
42a186ea6ad37ab0496a307b86ce767c005aacb9
cc6154486d4546a1394aac53dc5cfa5b1c4dfd02
/tiled/client/context.py
f3741344b9035db7d4428c43330a898d4c9b75e2
[ "BSD-3-Clause" ]
permissive
AustralianSynchrotron/tiled
3c4448030c5fb53c952790ad4c501291bf427214
307d2f3b7e9b841afdf5af716f218584e4c3d530
refs/heads/main
2023-08-29T04:19:20.768182
2021-10-14T00:38:00
2021-10-14T00:38:00
416,939,893
0
0
BSD-3-Clause
2021-10-14T00:36:20
2021-10-14T00:36:19
null
UTF-8
Python
false
false
21,489
py
context.py
import getpass import os from pathlib import Path, PurePosixPath import secrets import urllib.parse import appdirs import httpx import msgpack from .utils import ( ASYNC_EVENT_HOOKS, DEFAULT_ACCEPTED_ENCODINGS, handle_error, NotAvailableOffline, UNSET, ) from ..utils import DictView DEFAULT_TOKE...
3f090f7c94843e37d02af1c843d9c1530171b750
8b9e9de996cedd31561c14238fe655c202692c39
/graph/leetcode_Surrounded_Regions.py
fc5426c2d2e428f6b4234705cd3ee22b2163f597
[]
no_license
monkeylyf/interviewjam
0049bc1d79e6ae88ca6d746b05d07b9e65bc9983
33c623f226981942780751554f0593f2c71cf458
refs/heads/master
2021-07-20T18:25:37.537856
2021-02-19T03:26:16
2021-02-19T03:26:16
6,741,986
59
31
null
null
null
null
UTF-8
Python
false
false
2,340
py
leetcode_Surrounded_Regions.py
"""Surrounded regions leetcode Given a 2D board containing 'X' and 'O', capture all regions surrounded by 'X'. A region is captured by flipping all 'O's into 'X's in that surrounded region. For example, X X X X X O O X X X O X X O X X After running your function, the board should be: X X X X X X X X X X X X X O X X...
06ea44565de2e2779590637087d49a400409fafd
49bd144b5d0d4e7588cb4ae26f9531fcc8606065
/ion/processes/data/ingestion/science_granule_ingestion_worker.py
cea5a3208d81689788185b04440607ee6937d32d
[ "BSD-2-Clause", "LicenseRef-scancode-unknown-license-reference", "BSD-3-Clause" ]
permissive
unwin/coi-services
ba80b8cc77189faf6b0faf04787b3567b6458f8f
43246f46a82e597345507afd7dfc7373cb346afa
refs/heads/master
2021-01-21T03:33:15.541500
2014-07-30T18:21:24
2014-07-30T18:21:24
null
0
0
null
null
null
null
UTF-8
Python
false
false
21,362
py
science_granule_ingestion_worker.py
#!/usr/bin/env python ''' @author Luke Campbell <LCampbell@ASAScience.com> @file ion/processes/data/ingestion/science_granule_ingestion_worker.py @date 06/26/12 11:38 @description Ingestion Process ''' from ion.services.dm.utility.granule.record_dictionary import RecordDictionaryTool from ion.services.dm.utility.granul...
dd18cee63fefcf55beecd7d7cd397f770e980309
579997f0d76bcc6dd3ee31848cf4e6884da7afe1
/DataMakeB.py
593413475164aaa84abf99df7d07f77afcfbb14a
[ "MIT" ]
permissive
Jian-danai/Image-Recovery
0fb192a5cf7c7eab0ed7376ddc9add0efa558811
c30564459c293e8cbbbf51c376c744ceda2645dc
refs/heads/main
2021-07-10T08:27:48.213861
2020-11-10T02:46:58
2020-11-10T02:46:58
211,793,284
0
0
null
null
null
null
UTF-8
Python
false
false
1,846
py
DataMakeB.py
#说明:先修正大小,后根据规则产生数据 # #产生数据########################################################################################## # from PIL import Image # import random # #from pylab import * # # for index in range(1,2001):############################372 or 2001 # I = Image.open("F:\\DataSet\\Images_rec\\A\\labelA\\dog_" + ...
66a29dfb1072ebf0eaaab7b54bda33f6ea6a7434
9ff9168c8aa3ac63a1450c06dc3ca6428f559020
/lambdas-in-python.py
082f857ce92672407032b879fad58e995f51cef1
[]
no_license
philhawker/python-modules-source-source-codes
3adaae7792f45c68a5f497eafd609faf6181b92a
32051c347904c7299fc67f0ed4ed040a206348bc
refs/heads/master
2020-12-15T16:21:22.909985
2020-01-28T21:00:17
2020-01-28T21:00:17
235,174,735
0
0
null
null
null
null
UTF-8
Python
false
false
436
py
lambdas-in-python.py
# LAMBDA allows you to wrap up a smaller function and pass it to other functions. similar to a VARIABLE # functions are first class citizens. very mobile full_name = lambda first, last: f'{first} {last}' #arguments first: then there values # This is the same as above the above LAMBDA def full_name(first, last): ...
d848552981ff7e3f2e65b28e6e0ce3de47a42559
e3c055241165e2a0b0af3a772929c1a950f751cc
/Dynamic Programming/TheMaximumSubarray.py
97e9958d2665432b8110530484ae01f468f43f5d
[]
no_license
sathiiii/Hackerrank-Solutions
bcad7e76348b4bf602c2af90fa8e85b7c0c3ede9
7de92460a88d4c1fb7f1a0b90d88d40c54570f63
refs/heads/master
2021-05-26T00:46:03.734567
2020-10-03T05:02:48
2020-10-03T05:02:48
253,986,658
2
0
null
null
null
null
UTF-8
Python
false
false
1,870
py
TheMaximumSubarray.py
''' Copyright (C) 2020, Sathira Silva Problem Statement: We define subsequence as any subset of an array. We define a subarray as a contiguous subsequence in an array. Given an array, find the maximum possible sum among: (1). all nonempty subarrays. (2). all nonempty subsequences. Print the...
2d09c0d619ac393d491d902b97c2fe1883c4d902
806cb6ccbe5b9afeaa2b398344d84988b85f7375
/utils.py
bbc47a2a8c80814ec2854818438d2916bedc727d
[]
no_license
youngkuan/ism-with-data-augmentation
9d5ae4e2ef264eda40f76faf2c942016d03f5234
acc380b7207a8b4c70ed79c7639a47a9aaa0e44b
refs/heads/master
2020-04-28T03:42:01.767669
2019-04-04T11:17:48
2019-04-04T11:17:48
174,947,597
1
0
null
null
null
null
UTF-8
Python
false
false
4,066
py
utils.py
# -*- coding: utf-8 -*- from collections import OrderedDict from PIL import Image import numpy import torch.nn as nn import torch import os def save_discriminator_checkpoint(discriminator, model_save_path, epoch): if not os.path.exists(model_save_path): os.makedirs(model_save_path) torch.save(disc...
66d0c565935128dca9b41388326d5565c8b6bfa3
7bfb73047b138349bd87ab7efd63a7eee9535da9
/app/expdetail.py
ec3be98654d2d0e334c8db3822c2aee2eeea6be4
[ "MIT" ]
permissive
S0AndS0/ExpenseTracker
0172fca7dea349f8226e234bf5413203d5783e0d
9f024184c499c3af9421d872168447a9c9fae45b
refs/heads/master
2020-08-22T17:08:42.128400
2019-10-21T00:14:52
2019-10-21T00:14:52
216,444,172
0
0
NOASSERTION
2019-10-21T00:01:55
2019-10-21T00:01:54
null
UTF-8
Python
false
false
14,242
py
expdetail.py
from kivy.uix.screenmanager import Screen from kivy.uix.boxlayout import BoxLayout from kivy.properties import ObjectProperty, NumericProperty from kivymd.label import MDLabel from kivymd.list import OneLineRightIconListItem, IRightBody from kivymd.tabs import MDTabsBase from kivymd.pickers import MDDatePicker from ki...
fdf39400025e7022325cb9ac0d1eeccb723e9e6b
c316a938d91faa747dc5ed3f3e72aafe4054bebf
/tools/palette.py
746a5efeec484bdec201dd0119c94295cf25a61d
[]
no_license
davidgfnet/naxa68k
dd9f0fb495c7f9a9329bed67a78e1dc9022a86c1
d5196abcc2c86aa6b18b9c9b807fa9dc04fe4bb0
refs/heads/master
2020-07-27T14:41:27.006917
2019-09-17T23:30:00
2019-09-17T23:30:00
209,127,034
1
0
null
null
null
null
UTF-8
Python
false
false
978
py
palette.py
#!/usr/bin/env python3 # Filename : palette.py # Authors : David Guillen Fandos # Version : 0.1 # Date : June 25, 2019 # Copyright : Public Domain # Prints palette for a bunch of images (unifies it!) from PIL import Image import os, sys, hashlib, math, argparse from common import * parser = argparse.Argum...
9c6d77f24672c067dcaca58053d20549884839f4
233498ab0c9af0abdf8cb8c84f91ff84f9aaee8b
/HWK4/HWK4-2.py
c574764b198a8ea6cb1d5e13aa5b1d3976f43d10
[]
no_license
Namibillow/GOOGLE_STEP_HWKS
3483819db3c7391a32c6b15d6530c5854dd62aaa
1af4a97420678ee0dbb405e77fc3846e06a0f272
refs/heads/master
2020-05-27T20:12:10.785071
2019-06-23T02:45:47
2019-06-23T02:45:47
188,774,619
0
1
null
null
null
null
UTF-8
Python
false
false
2,494
py
HWK4-2.py
import argparse from HWK4_1 import print_bfs, Graph # Google 457783 def build_graph(file_path): with open(file_path, 'r') as f: graph = Graph() for line in f.readlines(): from_vertex, to_vertex = map(int, line.split()) graph.addEdge(from_vertex, to_vertex) return ...
0d87cde06a5e4e8f8b1c8d31db6d45f0bc9f8e91
8f47177bdf51b61b5ef5b662bde7fbf5a1c5f046
/creational/builder/src/director.py
32d7a2eaba0532b9a0bf289b3f85131e3deb8dba
[]
no_license
mkokol/design_patterns
d3f65618c993f48444eb321f116914cdbea90095
422632ab6b08d2651072d0049519e0e063651bf0
refs/heads/master
2023-02-10T13:25:41.268314
2020-12-31T20:37:36
2020-12-31T20:37:36
314,629,882
0
0
null
null
null
null
UTF-8
Python
false
false
330
py
director.py
from src.builder import AbstractBuilder class Director: def __init__(self, builder: AbstractBuilder): self._builder = builder def construct(self): return self._builder \ .set_title('Title') \ .set_description('Description') \ .set_text('Text') \ ...
6d5d15659fe4c1ce2082561b7705e221b552aeee
b5acf3f42f2e001af63a3be408f42ec86faa8fa0
/model.py
523ff5ee21f04a9a2493270f9df4e3e0c9a8d5ef
[]
no_license
CarolineCheng233/machine-learning-classfication
7947b9e9f25152fe6a5db4286552efbf2c9adeed
ed196b4fe0993659e67d33e8b698a48e5e2e861c
refs/heads/master
2023-05-23T08:32:59.226284
2021-05-25T08:04:37
2021-05-25T08:04:37
366,306,483
0
0
null
null
null
null
UTF-8
Python
false
false
3,231
py
model.py
import torch import torch.nn as nn import torch.optim as optim from transformers import AutoModel # from pytorch_pretrained_bert import BertForSequenceClassification class BERT(nn.Module): def __init__(self, pretrained=None, freeze=True): super(BERT, self).__init__() self.pretrained = pretrained ...
c887fdd12f343e8c710364c6b62e4da2a26c1f67
ff9ba43234526e5cf5aa68e4d13bb6b2e457eeef
/deploy/scm/git.py
c8001e5dc2e5976cbe373f28153e5cd4939deebc
[]
no_license
jamieingram/alexa_sonos_client
a9cdd9ac2cc6d9f741e864eee2612c73dbbc612e
5ca2f6202ac0ab73eb0dd09a40c341ff0062d3f6
refs/heads/master
2021-01-13T16:57:57.638393
2016-12-23T00:11:30
2016-12-23T00:11:30
77,181,296
0
0
null
null
null
null
UTF-8
Python
false
false
3,041
py
git.py
#!/usr/bin/python # -*- coding: utf-8 -*- """ .. module:: git :synopsis: Git utilities. """ from __future__ import unicode_literals from fabric.api import run, local, prompt from fabric.colors import blue, yellow, red from fabric.context_managers import cd from fabric.utils import puts from fabric.state import en...
601e9ee9bb51c6dec2976c0a8f8bfd78f511f8b6
ca7aa979e7059467e158830b76673f5b77a0f5a3
/Python_codes/p03826/s542429133.py
0edb467352bb4342569201a3df30e90fb301fa19
[]
no_license
Aasthaengg/IBMdataset
7abb6cbcc4fb03ef5ca68ac64ba460c4a64f8901
f33f1c5c3b16d0ea8d1f5a7d479ad288bb3f48d8
refs/heads/main
2023-04-22T10:22:44.763102
2021-05-13T17:27:22
2021-05-13T17:27:22
367,112,348
0
0
null
null
null
null
UTF-8
Python
false
false
78
py
s542429133.py
a,b,c,d = map(int,input().split()) print(a*b) if (a*b) > (c*d) else print(c*d)
04be4e38e23a91645bd47c4a4447fd6401d43006
164bc5565ac15de4b83f8a0dfa4bc5499936a359
/header.py
8d00eba093de21e00a9b0eb5a90071d5e86af4e0
[ "Apache-2.0" ]
permissive
raphaelcarvalhozup/dighub
febee33f0364367b21b690623afa6760c728f94b
3e755af64237a88a33ec9f76516cf7524d7e1966
refs/heads/main
2023-04-13T00:17:08.159745
2021-03-30T17:09:04
2021-03-30T17:09:04
349,512,740
4
1
Apache-2.0
2021-03-30T16:45:58
2021-03-19T18:01:27
Python
UTF-8
Python
false
false
581
py
header.py
from colorama import Fore, Back, Style def printHeader(): print("\n", Fore.CYAN, " _____ _ _ _ _ \n", " | __ \(_) | | | | | | \n", " | | | |_ __ _| |__| |_ _| |__ \n", " | | | | |/ _` | __ | | | | '_ \ \n", " | |__| | | (_| | | | | |_| | |...
b6fd348d88ec5df73dca1a31f0d584c60fb9aad9
482aed184860a79a29651ea3049454679d747f31
/course_recommender_web/CRS/urls.py
98efdf7066fb6ecac51ff1dbc06d696749fc2806
[]
no_license
yuvalgos/course_recommender_system
22851477de234a48c2702c8d74bde745fe2edcb3
9c7945c3aaf51ed0a64ab953b61ad377247e0c81
refs/heads/master
2023-06-01T06:58:53.247237
2021-07-03T16:26:18
2021-07-03T16:26:18
297,662,001
0
0
null
null
null
null
UTF-8
Python
false
false
1,677
py
urls.py
from django.urls import path, include from . import views from django_email_verification import urls as mail_urls urlpatterns = [ path('', views.home, name='home'), path('new_search', views.new_search, name='new_search'), path('accounts/', include('django.contrib.auth.urls')), path('register/', views.r...
6b2c19be74d02c58bbf8f5cc859a5f843a6894fb
8f67e00e337425ca995ce806f273bf3fed09a434
/users.py
42fd7a0476415cead527aa2fc57ecb709004ed9d
[]
no_license
chejoo-platform/chejoobot
2c608400a9742ec7758e2628af661205daf17c06
fc7f60fcf9efe4239ec72748fb8f9957ab6dcf40
refs/heads/master
2021-01-18T20:46:48.750648
2016-11-11T08:10:06
2016-11-11T08:10:06
69,160,920
3
1
null
null
null
null
UTF-8
Python
false
false
4,705
py
users.py
# -*- coding: utf-8 -*- import constants import db import functions from telegram.ext import ConversationHandler, CallbackQueryHandler from telegram import ReplyKeyboardMarkup, InlineKeyboardButton, InlineKeyboardMarkup def show_user(bot, chat_id, u_id, callback = False, msg_id = 0): user = db.get_user(u_id) i...
6c8cf946fdc9ba3d0b0d5d5ebcefb123838c0f10
ffe140d04795e110a32b94721bdba8c7a484e9d3
/application/model/dao/productdao.py
764d4915ddecab3fe90cd377f9438cdb934a8c71
[ "Apache-2.0" ]
permissive
DablioPaiva/Desafio-Buscap-
6879e49515c792795af96fc41f58b134990e5617
aac788e5bfb87cd788849bf8d7acae4d7dd5ad4c
refs/heads/main
2023-06-03T19:42:33.131611
2021-06-27T00:01:36
2021-06-27T00:01:36
380,616,912
0
0
null
null
null
null
UTF-8
Python
false
false
752
py
productdao.py
from application.model.entity.product import Product import json from typing import List class ProductDAO: def dict_to_list(self, lista_prod): product_list = [] for product_item in lista_prod: product = Product() product.set_id(product_item["id"]) product.set_nam...
53da1fcde6e6de555124f79a4e327e61efabbde4
e7e47f2d7c17e3a3266ff4f885324be703e9aa37
/adv_python/day_03_inhert.py
e2276f393f214c84ec4bd31e5a0482f73967c08c
[]
no_license
gentelyang/full_stack_py
a1af450d9391103b3773495d8844a021d90eb7e8
c527490977442849c041040984b5eefee184c87b
refs/heads/master
2020-06-05T19:45:18.034323
2019-12-17T13:10:12
2019-12-17T13:10:12
192,529,268
1
0
null
null
null
null
UTF-8
Python
false
false
696
py
day_03_inhert.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # author:gentelyang time:2019-06-28 #继承 class Dad: money=10 def __init__(self,name): print "baba" self.name=name def hit_son(self): print " %s 正在打儿子" %self.name class Son(Dad): money = 1000 def __init__(self,name,age): ...
0f402463aeb9ecd6c87dd21a0d182f5fc80e45ff
6651f839d4d6285369846e449f5f50f9fd3d202a
/game/views.py
e43cc446a3059cc58915c802e92c2d5ea123cc53
[ "Apache-2.0" ]
permissive
yjchen-tw/prisoners-dilemma
c92704da9d78137f6bf6b235c458892ddfdee69f
de3d453f44ca7daf1e94fc77de73e279a3b45b62
refs/heads/master
2016-09-05T16:18:32.880481
2014-12-07T16:48:55
2014-12-07T16:48:55
null
0
0
null
null
null
null
UTF-8
Python
false
false
1,486
py
views.py
import logging from django.shortcuts import render from django.views.generic.edit import FormView from .forms import TournamentInfoForm from .forms import FORM_FIELD_TO_PLAYER_OBJECT from tournament import Tournament LOGGER = logging.getLogger(__name__) class GameSimulationView(FormView): template_name = 'simu...
6a7f3e2e9b4d3222fd52b386ae7d606df1ba25a6
e6a61f244c53eb81becaf43fb4890ce0087d7c9f
/qanta/config.py
7439101b0e515068646a6b8f9ed6898529f22882
[ "MIT" ]
permissive
Pinafore/qb
610dce9e678f7b6ea63c0649b8989e4438ad304b
a5afd0c13886f5bc97748a11f98b4b62dd1d02f2
refs/heads/master
2022-12-11T10:33:21.719967
2022-01-26T18:35:24
2022-01-26T18:35:24
36,567,109
126
50
MIT
2022-12-09T05:58:58
2015-05-30T16:59:14
Python
UTF-8
Python
false
false
615
py
config.py
import os import yaml from qanta.util.environment import data_path DEFAULT_CONFIG = data_path("qanta-defaults.yaml") CUSTOM_CONFIG = data_path("qanta.yaml") def load_config(): if os.path.exists(CUSTOM_CONFIG): with open(CUSTOM_CONFIG) as f: return yaml.load(f, Loader=yaml.FullLoader) el...
8e27a6788b54ae179f7758e32a5caf2a9c452dc6
0cecd07c9d2065403ad836e03254cee503e8db60
/meta_to_csv.py
fe193b88421b8d6752f4191bdc4db6c38d7aa43e
[]
no_license
mattclifford1/py_sun
a1d22b53c8113f9336dc5d18853262d245ce81f7
47e5d5517345783c3b67a0a0c575f33c72930f24
refs/heads/master
2020-05-09T10:17:19.109764
2019-04-12T22:20:04
2019-04-12T22:20:04
181,035,991
2
0
null
null
null
null
UTF-8
Python
false
false
6,385
py
meta_to_csv.py
import pickle import numpy as np from random import shuffle import imagesize import sys import utils import pandas as pd import os class SUNRGBD: def __init__(self, train_num): #TODO work data_type # self.train_num_per_class = train_num_per_class # self.test_num_per_class = test_num_per_class ...
077bf0114a05a18e2eea80218aa6436bbe94765f
de19fe50dbd9e7e0b6ad5a4db993409030c6b4c6
/celsus/migrations/0026_project_owners.py
6140a374899ea1978ecd3d02e17ad2e97f3e8ab1
[ "MIT" ]
permissive
Alessi-Lab/cactus
d6d1079f9b06b042b2f5d90f2fe136fea1bb82f5
35b712a009f157565bd447db3cf03ab7ad63d9b7
refs/heads/main
2023-04-11T10:17:29.559840
2023-01-09T13:57:05
2023-01-09T13:57:05
569,663,551
0
0
null
null
null
null
UTF-8
Python
false
false
535
py
0026_project_owners.py
# Generated by Django 4.1.1 on 2022-11-11 10:01 from django.conf import settings from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ migrations.swappable_dependency(settings.AUTH_USER_MODEL), ('celsus', '0025_labgroup_project_lab_group'), ] o...
cd001607c0d12f47836682d3c40438c0cf067f0d
a7be04f67909c829b90244b4d79a2e5c3c16de22
/FrozenLake/4x4-v3/FrozenLake-v3 q-learning.py
4b7d171c3197e18e3a14d83bc7ea4151273efb62
[]
no_license
icsl-machinelearning/Reinforcement-Learning
2a2c3d967dc92feec9a7b7b5b6e73cae69403a8f
7c6856bfeca54d368aad67d742961542880c7e01
refs/heads/master
2020-04-28T16:52:24.151628
2019-04-18T04:58:44
2019-04-18T04:58:44
175,426,559
1
0
null
null
null
null
UTF-8
Python
false
false
1,436
py
FrozenLake-v3 q-learning.py
import gym import numpy as np import matplotlib.pyplot as plt from gym.envs.registration import register # Register FrozenLake with is_slippery False register( id= 'FrozenLake-v3', entry_point= 'gym.envs.toy_text:FrozenLakeEnv', kwargs={'map_name': '4x4','is_slippery': False} ) env = gym.make('F...
c4be627f1b6ed5376f3ece5ff5359e462fb01d80
d7289a02a560cca3d72e15da8893ea6147f2f296
/programming/hmwk1/python/client.py
c7c81bb713330e8603582622a5d1e9d338ef95dc
[]
no_license
shivamchoudhary/cs4180
d14f586de3b4f2a620561886f52cd7ee3822c46d
aae8e3acf9de21a0ce9d5d25745e48dc503b444b
refs/heads/master
2016-09-12T04:27:05.359013
2016-04-21T07:04:31
2016-04-21T07:04:31
50,540,801
0
0
null
null
null
null
UTF-8
Python
false
false
5,801
py
client.py
#!/usr/bin/env python __author__ = "Shivam Choudhary" __uni__ = "sc3973" import socket import argparse import sys import os, random, struct import Common from Crypto.Signature import PKCS1_PSS from Crypto.Cipher import PKCS1_OAEP from Crypto.PublicKey import RSA import hashlib from Crypto.Hash import SHA256 impo...
f9769a448487865bbce1187e74e9edce3a2460a0
a166dcb278ad0a71886f45bf80168b14efd872cd
/webScrap/covid.py
07185cf46adb3c4614aa484040024e976476538c
[]
no_license
pooyaaf/pycode
9ff328a41be9d03bf1af218602c5df871e25636d
1ac27df22841950e3acabc0a20cd6bdaf0057437
refs/heads/master
2023-07-19T09:59:00.355616
2021-09-14T05:36:24
2021-09-14T05:36:24
404,780,425
0
0
null
null
null
null
UTF-8
Python
false
false
611
py
covid.py
from bs4.element import SoupStrainer import requests from bs4 import BeautifulSoup import pandas as pd url = "https://www.worldometers.info/coronavirus/country/iran/" response = requests.get(url) Source = response.content soup = BeautifulSoup(Source,"html.parser") #cases: cases = soup.find_all("div",class_="mainco...
c50b7792a36d9cd32ab4ec1737d2696e4a826539
a242588a2a5c13007dba788df6589e24cadea8b6
/clipsync/components/discovery/__init__.py
3ee7e8c53d1d58971f16fddfecd26206b509f0dc
[ "MIT" ]
permissive
illBeRoy/clipsync
3d982547c7e63118486c079f605cd233317f188c
7b0d52be3809e0aae6fde9c6999622c1878c8459
refs/heads/master
2022-11-13T10:25:06.991529
2016-09-14T19:19:12
2016-09-14T19:19:12
68,054,562
2
0
MIT
2022-11-04T19:12:04
2016-09-12T22:53:56
Python
UTF-8
Python
false
false
1,492
py
__init__.py
import beacon from twisted.internet import threads, task class Discovery(object): def __init__(self, beacon_server, beacon_client, discovery_port, discovery_keyword): self._beacon_server = beacon_server self._beacon_client = beacon_client self._discovery_port = discovery_port sel...
9065b0fa5a8dfb124cdd9f2d37a519edbe7e76c1
25024e2890290d1909463cd4362d0cf0c917ae91
/youtube12.py
2e81726287df1b3c82007d95ff4d6ab6627b2659
[]
no_license
71200593dediyanto/rekursif
a44d32777ee78e9cfa414971e98d57c5cbef7694
f5387a164a5e4e680c0382753a3ec7cbf6fee7bf
refs/heads/main
2023-05-09T02:26:22.799399
2021-06-01T09:59:24
2021-06-01T09:59:24
372,782,408
0
0
null
null
null
null
UTF-8
Python
false
false
875
py
youtube12.py
# Dedi Yanto # 71200593 # Universitas Kristen Duta Wacana # Prodi Teknik Informatika # Fungsi Rekursif ''' joko ingin sekali membuat program untuk mengkonversi bilangan desimal menjadi bilangan binner, namun karena joko tidak pandai untuk membuat program bantulah joko untuk membuat program yang dapat mengkon...
4d4f9bac24cb7da9808cffe07cd8a7b07a23cbcf
d80c10615c2588698c06e1bd86e8e74761b98a97
/zqfa/members.py
baf002a524b7cc5352937b256bf522ad46b0fb68
[]
no_license
hurtonypeter/alumni-vienna
9363be7b23217dec90eec03a195d218e52f41100
f3843175db9bd24b6278025c576b914faeaacfc6
refs/heads/master
2021-01-22T11:27:37.438921
2017-07-15T23:20:06
2017-07-15T23:20:06
92,694,882
0
0
null
null
null
null
UTF-8
Python
false
false
5,445
py
members.py
from flask import Blueprint, render_template, redirect, url_for, request, flash, abort from flask_login import current_user, login_required from flask_wtf import Form from flask_mail import Message from wtforms import fields import newsletter from zqfa.app import db, mail from zqfa.models import User, UserPosition fro...
5b176c6287c713b25cd1ffb87aeeb9875e1e20c0
614d08439c0ab3072ab0cc0fe7cfe2ccdc5a622b
/battlecruiser.py
afd2aabcd3832c7eb46a7e16f23ebcb374757366
[]
no_license
DanialGhofrani/DanGTest
ccef18ecbb7642196f1f3208fe0db6b0dea50c12
3831871c12629ec948a059a566f1b7efcb63812e
refs/heads/master
2021-05-15T06:06:54.714970
2017-12-23T04:54:53
2017-12-23T04:54:53
115,171,371
0
0
null
null
null
null
UTF-8
Python
false
false
50
py
battlecruiser.py
def greet(): print 'who called in the fleet?'
b7b5dd15666f8ec9bc557c6876bdd261826c1f20
ca7aa979e7059467e158830b76673f5b77a0f5a3
/Python_codes/p02916/s726409703.py
a9a75d20752d2d99bc1e3f6eb04ed9ab59da7e8d
[]
no_license
Aasthaengg/IBMdataset
7abb6cbcc4fb03ef5ca68ac64ba460c4a64f8901
f33f1c5c3b16d0ea8d1f5a7d479ad288bb3f48d8
refs/heads/main
2023-04-22T10:22:44.763102
2021-05-13T17:27:22
2021-05-13T17:27:22
367,112,348
0
0
null
null
null
null
UTF-8
Python
false
false
337
py
s726409703.py
# 問題:https://atcoder.jp/contests/abc140/tasks/abc140_a n = int(input()) a = list(map(int, input().strip().split())) b = list(map(int, input().strip().split())) c = list(map(int, input().strip().split())) res = b[a[0]-1] for i in range(1, n): res += b[a[i]-1] if a[i] - a[i-1] == 1: res += c[a[i-1]-1] ...
72ef07b081017ec15f6af99e4920247de24f7d4a
247d1d0981da525eb9bc3360e8df014f3cf375d9
/text_calculator.py
421d1a363a750678e85753428e8602a638733f54
[]
no_license
purcellconsult/scripts
cd815825c95ca4cc20f87221461657857477fe4f
87f6b02a4818c14095a11b2f0543c241b8478ac6
refs/heads/master
2020-04-22T18:40:37.381927
2019-03-13T06:44:03
2019-03-13T06:44:03
170,584,796
0
0
null
null
null
null
UTF-8
Python
false
false
1,794
py
text_calculator.py
#################################################### # A simple text calculator program written in # python that reads user input from the command # line and prints the output. Can handle addition, # subtraction, multiplication, and division. # Reads in an unlimited number of input # # By Doug Purcell # website: http:/...
5a24e3b18610574b62f331f1e56c70fe5da429e4
305b994267305a4ad98735ea41de8ce74d3b6270
/banyakim/iteration/약수의합.py
55c0056398172f9b5b4ce8da0d30e538b7811817
[]
no_license
tokyo-algorithm/algo
6940f99c52cb1c175e158c32a15f09b54e4dbeae
f8e6716df09e5e402b968eb8894127c7b31a49cb
refs/heads/main
2023-02-10T23:58:10.243794
2020-12-31T10:00:42
2020-12-31T10:00:42
310,289,477
1
8
null
2020-12-31T10:00:43
2020-11-05T12:18:45
Python
UTF-8
Python
false
false
183
py
약수의합.py
# -*- coding: utf-8 -*- # UTF-8 encoding when using korean num = int(input()) answer = [] sum = 0 for i in range(1, num+1): if num % i == 0: sum += i answer.append(i) print(sum)
e23de99a336b5ce8d92fec58baaa7a5215e6e389
1722795f281fd1127deb22baea264972d14ab67c
/module_0/module_0.py
d30d3d89eff72c9562d4372f9e499cdbcb6320e5
[]
no_license
MakcimA/Skillfactory
fe52ee73d926c64a5e02c11371f4bfc3b185fdde
1d0456028df090d67a9719c0e5bd17cf1b0048e7
refs/heads/main
2023-05-14T02:36:15.837062
2021-05-24T19:43:15
2021-05-24T19:43:15
369,235,549
0
0
null
null
null
null
UTF-8
Python
false
false
1,940
py
module_0.py
import numpy as np count = 0 # счетчик попыток number = np.random.randint(1, 101) # загадали число print("Загадано число от 1 до 100") def game_core_v2(number): '''Уменьшаем или увеличиваем число в зависимости от того, больше оно или меньше нужного. Число меняется на среднее арифметическое значение межд...
563b9c737742886c4ca03aa9568699df23542f2f
ef9c7ea95cc4e14ec83c3f1a10765d8e0410e73a
/main.py
22ee977e56f6fef46a4103851593f39269bc567d
[]
no_license
artmoni/Prism
5a33a0576baad0b7b93a30c96800c4a63bc332d5
625345ad42331b2400417ecc40d699f7d2749f1f
refs/heads/master
2020-05-05T04:15:57.406718
2019-04-05T07:57:50
2019-04-05T07:57:50
null
0
0
null
null
null
null
UTF-8
Python
false
false
1,562
py
main.py
import argparse import logging import asyncio import websockets from prism import Commander logging.basicConfig(format='%(levelname)s:%(message)s', level=logging.INFO) logging.getLogger("digi").setLevel(logging.WARNING) # disable logging for digi module if __name__ == "__main__": parser = argparse.Ar...
71cb2c6d55685aaeab4b9746ea1d9ef678404ccf
d646ff1c05c7d5c644c8ed33e65111ea15aa36e9
/declarations.py
443e5eaf0443b225bc16caed3889810ff4420082
[]
no_license
sgasparinatos/PySimMonitor
1fe79d8cbe8fa9e40bbca073dc380c24a667e938
f0eabdc21c42522be957961e468f93fd3603ff4f
refs/heads/master
2020-05-22T10:22:42.409446
2017-04-13T17:40:57
2017-04-13T17:40:57
84,690,677
0
0
null
null
null
null
UTF-8
Python
false
false
4,430
py
declarations.py
# MODEM CHECK_STATUS_INTERVAL = 1 # 60 seconds CHECK_SECURITY_INTERVAL = 10 # COMMAND_RETRIES_LIMIT = 10 OPERATOR_DICT = {20201: "Cosmote", 20205: "Vodafone", 20210: "Wind"} REGISTER_DICT = {0: "not registered", 1: "registered home network", 2: "not registered", 3: "...
503e8a043122364cfd660add9e4e4b02c6256274
715a58a87c2c9496d147d0c1402ac8459699e749
/DjangoPrj_Lab_mngmt/lab/migrations/0005_auto_20190131_0210.py
a668779029573b87cfed49e490ef87bfe3691a34
[]
no_license
felzhang/DjangoPrj_Lab_mngmt
0c0f02f359246ad881d3ede1584590ba900b6d4c
1a0fce2577345950eb2beb0d7b94b29c8141c1bd
refs/heads/master
2020-04-20T14:50:12.792075
2019-02-24T08:04:02
2019-02-24T08:04:02
168,910,988
0
0
null
null
null
null
UTF-8
Python
false
false
428
py
0005_auto_20190131_0210.py
# -*- coding: utf-8 -*- # Generated by Django 1.11.18 on 2019-01-31 02:10 from __future__ import unicode_literals from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('lab', '0004_auto_20190131_0206'), ] operations = [ migrations.RenameField( ...
02c194654eb3bdefe0d8c536716d3f49df378781
351752493ad8a9dca01ec3f1399674778e12999b
/src/native/asm.gypi
90d37faec431004bf2d6fc9c84543772661c286c
[ "LicenseRef-scancode-unknown-license-reference", "Apache-2.0" ]
permissive
guymguym/noobaa-core
68373e5ba41f8544e970b94980d2b1e22a2441ef
c497a4f17104081b58bcafbf5b64979cbb0f9ebc
refs/heads/master
2023-08-31T00:01:35.615543
2023-08-27T12:31:38
2023-08-27T12:31:38
193,899,078
0
1
Apache-2.0
2019-06-26T12:22:36
2019-06-26T12:22:36
null
UTF-8
Python
false
false
3,618
gypi
asm.gypi
# Copyright (C) 2016 NooBaa { 'conditions': [ # LINUX [ 'OS=="linux"', { 'conditions': [ [ 'node_arch=="x64"', { 'defines': [ 'HAVE_AS_KNOWS_AVX512', 'HAVE_AS_KNOWS_SHANI', ], ...
b036c9ceb68f6bd19106a6697201f1f78ff86810
2be62957454e8586780dd1ddbf5d243a34546971
/create_hotspots_in_normals.py
0932ca12b82eb6f116f15a8b3d9789f39f5396f4
[]
no_license
mskcc/roslin-qc
a9d498de43f730f2cfb6ba2c5278149eb665c6fd
339da1842c8057cf6128293790df945aa19a6780
refs/heads/master
2021-03-27T13:07:59.989028
2020-07-13T20:05:11
2020-07-13T20:05:11
99,128,539
0
0
null
null
null
null
UTF-8
Python
false
false
3,620
py
create_hotspots_in_normals.py
#!/usr/bin/env python import pandas as pd import numpy as np import glob import os import argparse if __name__ == '__main__': pd.options.mode.chained_assignment = None # default='warn' parser = argparse.ArgumentParser(add_help= True, formatter_class=argparse.ArgumentDefaultsHelpFormatter) parser.add_arg...
851d4eeac9bfb9ed249dc015f7014c067a92787b
9e2ab5125c806c09d712bc624c6f6d0e149dd986
/logic/mix_data_x_y.py
e1ac658e4992687419257b12666efa6cea295822
[]
no_license
medunova/Assistance-system
4d05df4ce82cc889f2b4556d59e3f5dc5d5d1bf3
aa7e9d9b81a4df2a64d8e2a68b96cf5230b7b3bb
refs/heads/master
2020-03-21T17:32:04.926727
2018-06-27T08:30:27
2018-06-27T08:30:27
138,837,519
0
0
null
null
null
null
UTF-8
Python
false
false
599
py
mix_data_x_y.py
''' Created on 11. 3. 2018 @author: Aneta Medunova ''' import random def mix_data(x, y): """ The function randomly snaps the data set and evaluates it so that no connection is broken. """ if(len(x) != len(y)): print("Data not consistence: ") else: for i in range...
9f135210fd42039d6ce5173db4dce9e33c56b937
ae6c57fc01d3f3f14fa9e16c4f37bce006147704
/projects/membrane-beta_4state/codes/cv.py
dd4745ff819556c17512d276eb057ddb16014e09
[]
no_license
rodriluc/SVM_BB4
dc963e8611eb1a033958101055a83c65cf22faaa
326a0bc3a8fabce95e60f50c21ae7cc554e3ee74
refs/heads/master
2021-09-16T20:52:01.268324
2018-03-19T09:32:09
2018-03-19T09:32:09
null
0
0
null
null
null
null
UTF-8
Python
false
false
825
py
cv.py
import clean_CV import numpy as np from sklearn import svm from sklearn.model_selection import cross_val_score from sklearn.metrics import f1_score #found that window size:17 gave me the best score testfile = "../datasets/membrane-beta_4state.3line.txt" smalltestfile = "../datasets/parsetest" def cross...
fe8fbc32976db95936e2254f8fa373b489bffacc
405aebe170f079bad0a1555c9f83b8e3d83b6245
/views/dialogs/misc.py
686fbf2db025023f4667dfa9b5fa794e090050b7
[]
no_license
luckylyk/Pizzicato
79e15a005111ff20e0bac61a98df460ce78f0e49
560cbe6b2799480ec5c4305cd40d459c8c214a35
refs/heads/master
2018-10-29T00:01:11.254008
2018-08-22T22:38:20
2018-08-22T22:38:20
119,444,344
0
0
null
null
null
null
UTF-8
Python
false
false
2,980
py
misc.py
from Pizzicato.views.utils import PrintablesImportFileView from Pizzicato.controllers import PizzicatoController from Pizzicato import text from PyQt5 import QtWidgets, QtCore from Pizzicato.strings import find_closer_string_in_list import os class ImportPrintablesFiles(QtWidgets.QWidget): def __init__(self, fi...
11ec81f189bd9051079ba382a0f596dcade4af0a
0ed3a77898c281d250db0e089870a1af55719e9b
/flask_bigtempo/store/datasources.py
d0d4df019ccee83852ff4a747ed0841e97319b00
[]
no_license
rhlobo/flask-bigtempo
a52464ded78f1dfa863da2c9567161520f09624e
1551705717dcfb68259d29ba7cafd09ff8f3bc0f
refs/heads/master
2021-01-10T18:49:05.166215
2015-01-31T23:41:06
2015-01-31T23:41:06
29,617,246
0
0
null
null
null
null
UTF-8
Python
false
false
857
py
datasources.py
#!/usr/bin/env python # -*- coding: utf-8 -*- import pandas import requests from .core import DatastoreAPI from .clients import DFStoreRestClient from .defaults import * class RESTStoreDatasource(object): def __init__(self, reference, host=DEFAULT_HOST): self.reference = reference self.rest_cl...
93efa7bde634515c5e19756ad50deac58c5366ed
064b33729f8b451f9444ab1fec947d925fcb4345
/script2.py
392f7d150d3ec8a3a093739bdba22e31d54240c6
[]
no_license
singhranjodh/the-hindu-archive-scraper
f956ddbc9cc035a67f659fda89a53d14b4883ae4
7875ec4e08ae475e9c26829b54780c38ef390b5e
refs/heads/master
2021-09-03T06:01:51.716190
2018-01-06T05:13:55
2018-01-06T05:13:55
116,412,981
6
3
null
null
null
null
UTF-8
Python
false
false
725
py
script2.py
import requests from bs4 import BeautifulSoup as bs with open('links.txt', 'r') as f: content = f.readlines() for c in range(len(content)): try: html = requests.get(content[c][:-1]) soup = bs(html.__dict__['_content'], "html5lib") article = soup.select("[class~=article]") title...
251a4e04a8a79e305418e3ffc4b57aea392a5c8e
24fb1dffb57a8d102847841aaaf1da6a4eca7302
/Task1(PythonDev)/prgm1.py
f87e73488647295f9b9833375dc0a9d5353f58d5
[]
no_license
TheCoderIsBibhu/Spectrum_Internship
625dc6430562dd9665727fc7ee4ffa5501c4e5a8
43866ccea7fc532cc9f7d27cc0cc33c056a75a8c
refs/heads/main
2023-06-13T04:36:10.556330
2021-06-28T02:15:48
2021-06-28T02:15:48
380,872,476
1
0
null
null
null
null
UTF-8
Python
false
false
410
py
prgm1.py
# 1-You are given a string and you have to swap cases i.e. to convert uppercase to # lowercase and vice-versa def swapcase(str1): new_string = "" for character in str1: if character.isupper(): new_string += character.lower() else: new_string += character.upper() ...
4bdc7d9ee4a2c66e889f60c74bbaa3066c2c59b5
ab290d4de33f13755384aed256884c0c788a21f3
/test.py
9c5b89d5e6e7e5eb9d2145e9029f2d990309f36e
[]
no_license
theflyingmantis/mahabharata
9cd2995e5b3750bfe3f9d09ea1787580fae6c1eb
edcd0d86b560a35c1532cf3568ad68dfae45d188
refs/heads/master
2021-01-21T13:08:08.504011
2016-04-29T22:56:25
2016-04-29T22:56:25
48,988,974
1
0
null
null
null
null
UTF-8
Python
false
false
241
py
test.py
fob=open("board_file.txt",'r') list1=[] list1=fob.readlines() for i in range(1,122): words=list1[i].split() if words[1]=="U": print words[0] fob.close() # fob=open("board_file",'w') # fob.writelines(words) # fob.close() break
a1ece2c96e808a4e66a414b3d7a7572034748fba
befcd11e323d0a3f8a42624b52c899fa566b4619
/canflood/misc/curvePlot.py
c23cf67d57d565fd32a4eed3b8a915bd88b632e8
[ "MIT" ]
permissive
IBIGroupCanWest/CanFlood
5764bdf8900f1a9521cf863f0cd011cfbb0b2c7a
ff21c5668f1fc4d679c6e1f22c7a6caa4e5e3c32
refs/heads/master
2021-07-07T03:25:31.106238
2021-05-04T17:29:40
2021-05-04T17:29:40
242,797,279
7
0
MIT
2021-03-23T20:42:46
2020-02-24T17:21:08
Python
UTF-8
Python
false
false
16,729
py
curvePlot.py
''' Created on Feb. 9, 2020 @author: cefect plotting damage curves from the library not implemented in GUI yet TODO: Consolidate w/ riskPlot ''' #========================================================================== # logger setup----------------------- #======================================================...
e55e7802ce134747531763ee32b2324b0ee01df0
ae7e7cd1313d94394158a0e9139224ec226abd00
/spiders/__init__.py
4194d5b99e3bc7d8a7e23a36ee84658660404dd4
[]
no_license
odysseus0/bilibili_crawl
f3f9eb2ab294667eab26347f92c31506be408e36
eb3856057c92a65e0448d1cb1f35364101171faf
refs/heads/master
2023-05-13T04:53:00.703570
2021-06-01T16:06:41
2021-06-01T16:06:41
367,553,267
0
0
null
null
null
null
UTF-8
Python
false
false
40
py
__init__.py
__all__ = [ "video", "account" ]
dd05bb253a966746c0823553f8d757531a3d7542
67189da75c3a2a7b6b60db91195c40d1c2037f6b
/postgres/pg_migrate/pg_constants.py
09bbe6276635d011dae5b0467a28581aa0b2934c
[ "Apache-2.0" ]
permissive
ShakexIngwu/kerish
44fb8ceb9318df4b975ef51fe8b8efd1ede8c556
022d9db82c21eeb69c77e4dabafa77a720c9202e
refs/heads/main
2023-03-04T20:22:16.098577
2021-02-15T09:20:51
2021-02-15T09:20:51
331,802,496
0
0
null
null
null
null
UTF-8
Python
false
false
488
py
pg_constants.py
# Postgres database connection parameters # TODO create postgres user/password based on params set in .env file # please follow Cassandra's way to update or change username and password. # the following hardcoded authentication information is a hack and only to unblock the dev process. # remove before release!!! # remo...
1864d69038dc6bdeed653a39a1d384ebd3adc61a
8267910a8016e7c07f6b1f5abf9c889ba12cbf07
/src/tests/test_branches.py
4c3ed4e5deb8b87f75294951ba39cb0849c02af7
[]
no_license
voidexp/nesquik
366699ec422ce6e2f230634c2ceafd8f74acfb6c
600e52e6c113a2c367c9d148824da7698891c92f
refs/heads/master
2023-04-05T21:11:37.413085
2021-03-09T20:44:50
2021-03-09T20:44:50
null
0
0
null
null
null
null
UTF-8
Python
false
false
2,095
py
test_branches.py
import pytest @pytest.mark.parametrize('code,conditions,exp_results', [ ( 'var a = 10\n' 'func main():\n' ' if {expr}:\n' ' a = a + 2\n' ' return a\n', ('a == 10', 'a >= 10', 'a <= 10', 'a < 10', '10 == a', '10 <= a', '10 >= a', '10 > a'), (12, ...
501ada3b8a9d677788df45a0e7b38c1ffb86c455
79a777fb8bcfd1e5b6564f1a684405a4292fe4ac
/r.py
df2e29b6da82bdc1931772bd64108b1a59eddd9e
[]
no_license
yogeshralhan/Flow
85a12137a02dcc7b1d8daa72798ebb91ae25fa62
f0df5b036fdad351cba678b9e676858ad87d7c9a
refs/heads/master
2021-01-10T01:16:00.172790
2016-02-24T06:23:57
2016-02-24T06:23:57
52,419,340
0
0
null
null
null
null
UTF-8
Python
false
false
151
py
r.py
from flask import Flask app= Flask(__name__) @app.route('/user') def user(): return ' <h1> Hello <h1>' if __name__=='__main__': app.run(debug=True)
df0ea904fd5414f6ef0f26c21b4c87badf5fe1e8
1cdc4ba29888e4d1067f2e1835c432a1813ae682
/Feature_selection/ET_selection.py
2068ec278e2d7d3f74ef130771f66c954ceab785
[]
no_license
QUST-AIBBDRC/RPI-MDLStack
6e986e2426d7bd2d57a3262c495f0485e0852eb3
c420ee278dfd2553452f1290dbe59dac50e60cca
refs/heads/master
2023-08-19T16:11:27.720893
2021-10-19T03:06:46
2021-10-19T03:06:46
397,802,262
2
0
null
null
null
null
UTF-8
Python
false
false
1,622
py
ET_selection.py
import numpy as np import pandas as pd from sklearn.preprocessing import scale from sklearn.ensemble import ExtraTreesClassifier from sklearn.feature_selection import SelectFromModel #基于L1正则化的决策树选择算法 def selectFromExtraTrees(data,label): clf = ExtraTreesClassifier(n_estimators=500, criterion='gini', max_dept...
62a70e759c8dfc817ebbf3c0b9acedca23c32cfb
5ad0a8ab299d852cfccf2c2a2300ace1deffa567
/contact_form/models.py
95ce644238e728ee2e0301ffb8ba9b3ade92ab2a
[]
no_license
Code-Institute-Submissions/wilsons_express_v1
ee12bf6f2e4925f09d75a2863e0f1326a0a38a5a
a9f7cfc701c77b8457a23d60f1b77b9b1282843a
refs/heads/master
2023-05-12T10:31:19.359384
2021-06-03T06:46:08
2021-06-03T06:46:08
null
0
0
null
null
null
null
UTF-8
Python
false
false
316
py
models.py
from django.db import models class Contact(models.Model): from_email = models.EmailField(max_length=254, null=False, blank=False) subject = models.CharField(max_length=80, null=False, blank=False) message = models.TextField(null=False, blank=False) def __str__(self): return self.message
215e4424ad322f40e9f113df621fe40f67331a6c
747febe786dd6b7fd6c63cfe73dbe3023354daa8
/src/the_tale/the_tale/game/artifacts/urls.py
a6570594643872ee9a150aeabc83456eab77396c
[ "BSD-3-Clause" ]
permissive
the-tale/the-tale
4e4b8d91dc873a5fb935fe58e9721a877baa6d3f
e8450bd2332344da805b1851e728da5a3e5bf0ef
refs/heads/develop
2023-08-01T13:53:46.835667
2022-12-25T18:04:56
2022-12-25T18:04:56
1,949,167
98
52
BSD-3-Clause
2023-02-15T18:57:33
2011-06-24T18:49:48
Python
UTF-8
Python
false
false
115
py
urls.py
import smart_imports smart_imports.all() urlpatterns = old_views.resource_patterns(views.GameArtifactResource)
5c95d93f04723f023625024d84de6839656ed8df
d4cc77d34a61a8f14c568a8bebf817e3bc472b54
/misc_function2.py
7d560031031e749b42746bab88ecdc97b611a1c6
[ "MIT" ]
permissive
edotheodore/Thesis-Project
c4dac4bc3f2367f66a03117600801c34e003113f
5e36aea435fe1a5032e96b44792cec8c888240d2
refs/heads/master
2020-12-30T03:41:40.969592
2020-02-07T05:07:33
2020-02-07T05:07:33
238,848,270
0
0
null
null
null
null
UTF-8
Python
false
false
846
py
misc_function2.py
# -*- coding: utf-8 -*- """ Created on Fri Jul 5 18:48:21 2019 @author: Theodore """ # -*- coding: utf-8 -*- """ @author: Theodore """ import numpy as np API_KEY = "WWLN1J8UJ2I7Q8ML" # get data from worldtradingdata def stock_url(function, symbol, outputsize): url = (f"https://www.alphavantage.co/query?funct...