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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
13cfeb410f558293d1349938d05e9cddf793a4a1 | 80c9ac04c6fd134689c5ef2af37e187d450c45ad | /sante/migrations/0009_auto_20191115_1940.py | 26b5454627ac9cca381c994932cdcb1e03a771ee | [] | no_license | pavanchikkanna/webapp_using_django | 685e10181d7b5c113c7a1a026a824949848f93b2 | c876c0228892f9c0cbcdc20d5fc728f899bf2a6d | refs/heads/master | 2020-09-30T13:56:14.875321 | 2020-01-24T17:42:14 | 2020-01-24T17:42:14 | 227,301,319 | 3 | 1 | null | null | null | null | UTF-8 | Python | false | false | 394 | py | 0009_auto_20191115_1940.py | # Generated by Django 2.2.7 on 2019-11-15 14:10
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('sante', '0008_auto_20191115_1930'),
]
operations = [
migrations.AlterField(
model_name='farmer',
name='phone',
... |
986f102ddec4e83d6a49b08018c174226c7e218c | 6b43225c9516432b7dadacde49f728ca9252c6fc | /seed_db.py | c26257a6a2e160f925689ee9acd9c54673dc6cc2 | [] | no_license | penelopy/luigi-demo | ed6b2cc29a66f9e333dffd15928f2d0cfe10a95a | 98e76e441ec5fd858908ca3c3e6c8f19bf38e6c2 | refs/heads/master | 2021-01-20T00:56:55.107848 | 2015-08-30T22:21:45 | 2015-08-30T22:21:45 | 40,564,224 | 1 | 0 | null | 2015-08-30T21:56:15 | 2015-08-11T20:42:21 | Python | UTF-8 | Python | false | false | 930 | py | seed_db.py | import csv
from mysql_etl_tasks import Db
def create_table():
Db.execute(
"""
CREATE TABLE IF NOT EXISTS stories (
id INT NOT NULL AUTO_INCREMENT
, full_text VARCHAR(128) NOT NULL
, first_word VARCHAR(20) NOT NULL
... |
f5679fc9b9490a03a6d7b3bdc0682f96d17f1fdc | 7c83feaa876fe99b0b0bf2f1f1d7053f901122d8 | /Codigos 2/Interfaz Grafica/Frames/Frames_2/Probabilidad.py | 414da2d7211e7637305751e996d2cd98ed4b2b9d | [] | no_license | Grupo13BIODI/Grupo13BIODI.github.io | 777fc861b3211eda061c1df4f2856c71df531a05 | 364fe0989ac2745b634c658e3294f74fbc9cbdda | refs/heads/master | 2023-02-02T09:57:34.407735 | 2020-12-23T03:41:32 | 2020-12-23T03:41:32 | 298,176,719 | 0 | 0 | null | 2020-09-24T15:45:52 | 2020-09-24T05:21:19 | null | UTF-8 | Python | false | false | 1,432 | py | Probabilidad.py | from tkinter import ttk
class probabilidad(ttk.Frame):
def __init__(self, parent, show_menu, show_historial):
super().__init__(parent)
self.columnconfigure(0, weight=1)
i = 1
botones_container = ttk.Frame(
self,
padding="30 15 30 15"
)
... |
3f0825b0adabac9d9dc322afcc06aedc85b3a4f2 | cfa01be3fa9ec4ad1f4915347303eb0ab4046e19 | /11_create_second_window.py | 429617e183dedd6c99d82ae8a63a8ae21a7d35c7 | [] | no_license | momchilantonov/CODEMY-Create-GUI-With-Tkinter | 27bd93f7e149d78544145163a8bc57226d9dcdd0 | 44e4263b35db1f59591276eb2b0a61e38d8d86c4 | refs/heads/main | 2023-02-12T00:53:37.856301 | 2021-01-09T21:41:12 | 2021-01-09T21:41:12 | 327,694,979 | 6 | 0 | null | null | null | null | UTF-8 | Python | false | false | 424 | py | 11_create_second_window.py | from tkinter import *
from PIL import ImageTk, Image
root = Tk()
root.title("base")
def open_btn():
global my_img
top = Toplevel()
top.title("II")
my_img = ImageTk.PhotoImage(Image.open("E:\Mine\Python\\first_tk\images\\3.png"))
Label(top, image=my_img).pack()
Button(top, text="close window",... |
bb3d7ace06f41e89a365949f77397251923ff69a | 7fd435889df70c451636af53daebd01f8d3e0c64 | /Booc_2.py | 30f4c9c8085483f129eae170ecd1e5035b43276c | [] | no_license | Hamarko/Book_numbers | f48c5bace9cadaf010c7f97fafdb0da09681a19f | e784d04fc4d41fc593d173bcf93b4c388051856b | refs/heads/master | 2020-07-23T10:44:19.902737 | 2016-10-10T14:10:41 | 2016-10-10T14:10:41 | 67,278,173 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,163 | py | Booc_2.py |
"""
PhoneBook
Trying to create a console version of the PhoneBook apps. using knowledge after two lessons:
loop
exceptions
list comprehension
defining a function (with default values)
doc string
LEGB
decorators
"""
import functools
import sys
import pickle
class PhoneBookError(Exception... |
8560ccfb579b134e65d61344d55491eae3194894 | 17f527d6936397270183a35d7097e0a99de16cb5 | /AtCoder/ABC/63_c.py | de0b5dee49bba0700a7b00cfad7d0adc0e7ad6ea | [] | no_license | ryosuke071111/algorithms | e942f043d08c7c7e2c926ed332ee2b8c44bdf0c5 | 867764450cc0f2a709fa2f743d9a0d95001e9296 | refs/heads/master | 2020-05-14T17:14:39.314064 | 2019-04-17T12:58:12 | 2019-04-17T12:58:12 | 181,888,623 | 11 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,038 | py | 63_c.py | #10:59-
# n=int(input())
# S=sorted([int(input()) for i in range(n)])
# not_10=[i for i in S if i%10!=0]
# sums=sum(S)
# if sums%10!=0:
# print(sums)
# else:
# print(sums-not_10[0] if not_10 else 0)
"""
2^100値の最大値を取る問題(sum%10!=0)
①合計がすでに%10!=0ならそのまま出力
②そうでないなら%!10=0でないもののうち最小を取り出す
→35 25 15 5 の場合、それぞれペアが作られて部分的に... |
40249248f87f2990b2be2eb991b3595daae51027 | 93cf3d9acf2463ba34fd3b2e89375baa9dcf23a9 | /test_init_pop.py | dded9bcd5133f3de62ce10b01799a120c624518a | [] | no_license | tnazikian/ga_tree | c3daf97958d4ea98d446bfc32f438059cd07b970 | 384ac2956ea94ba168984e9459ceebeac7e73a2d | refs/heads/master | 2020-08-15T19:18:58.821057 | 2019-11-20T08:56:25 | 2019-11-20T08:56:25 | 215,394,811 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,627 | py | test_init_pop.py | from numpy import *
import ga_tree
from ga_tree.helper import *
TEST = False # Toggle if you want real numbers for coeffs
COEFF_MAX = 10
num_cycles = 1
num_individuals = 30
data_in = {}
data_in['x'] = np.linspace(0, 2 * np.pi * 30, 1000)
data_in['y'] = np.linspace(0, 2 * np.pi * 30, 1000)
data_out = np.sin(np.sin(d... |
b1e8ce787f9198426ea3a6f1bcf133b4fda7f711 | 3835d436f3a52effa6d30ea5ad2be7af1fcc1dbe | /Battle/character.py | 50d60a9cc8bc7dfc8f6836d4e21fac86d9187681 | [] | no_license | RyanTheCao/BattleProgram | 617f812555a4204e2ef1a1618e293012c1a01807 | cf8a3c452748c0630846031a7a756dab38e5c4f1 | refs/heads/master | 2021-05-19T15:07:06.593869 | 2020-03-31T22:55:55 | 2020-03-31T22:55:55 | 251,833,788 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,603 | py | character.py | import helper
import random
'''
Implement a method in Character called factory() that accepts two arguments: "type" and "name".
If type is equal to "Monster", return a Monster with the given name, and if the type is equal to "Mage", return a Mage with the given name.
'''
class Character:
MAX_HP = 100
de... |
fdf04f3b4c637b5ac80a08417030740a2c3cf36d | d3edb1566d70478421a9a09cb8d7450babf119b3 | /watch-later | 1a505472026d9879194839428bc536639a995c6d | [] | no_license | nburns/utilities | f7bb78231438486f0957dfdc24b01bba182fd6be | 219440959322259a049890bd2de6de054b9bb425 | refs/heads/main | 2023-06-09T01:19:58.819869 | 2023-06-07T05:07:50 | 2023-06-07T05:07:50 | 28,217,373 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 340 | watch-later | #!/usr/bin/env python3
import yt_dlp
options = {
'format': 'bestvideo[vcodec!*=av01]+bestaudio[acodec!*=opus]',
'merge-output-format': 'mkv',
'outtmpl': '%(uploader)s-%(title)s-%(id)s.%(ext)s',
'cookies': './cookies.txt',
}
with yt_dlp.YoutubeDL(options) as y:
y.download(['https://www.youtube.com/... | |
3b3ef1865819d55925d3d2c8bd4298cdbfcb0a0a | 9732d7b11bc5ef3aefa64cf74b951e0b9812e63d | /SAN/TestCode/code/model/non_local/utils.py | 1597b56afb3d3ae3cf490861671af2b4c9da177b | [] | no_license | umd-fire-coml/2020-summer-t2-image-super-resolution | 0751b206342b63926d5a8fe8e1ed0be035e47b05 | bb9259fb3188c7014e1c584449b2f50637a6d396 | refs/heads/master | 2023-05-26T04:24:57.642130 | 2020-06-26T15:56:52 | 2020-06-26T15:56:52 | 272,475,343 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 143 | py | utils.py | import config as cfg
import os
def create_architecture():
if not os.path.exists(cfg.model_dir):
os.mkdir(cfg.model_dir)
|
85f1a23d19b8ec5a2c969d81b40e1f171c37b194 | bc416ae3b9990f32716cc849e62a70acbb95857d | /katas/sudoku_solution_validator_v3.py | d804a78620c4453e39e08d3a30318bb693403067 | [] | no_license | BrendanArthurRing/code | 0d348b2baf9a9c52da64ede2d92e0742c38b04ca | 1afb8db228f3706f80dd6212cf09ce17306a0910 | refs/heads/master | 2021-07-22T06:44:19.782263 | 2020-04-26T00:48:22 | 2020-04-26T00:48:22 | 105,839,255 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,716 | py | sudoku_solution_validator_v3.py | # My Kata Solution
# Kata Link: https://www.codewars.com/kata/sudoku-solution-validator/train/python
board = [
[5, 3, 4, 6, 7, 8, 9, 1, 2],
[6, 7, 2, 1, 9, 5, 3, 4, 8],
[1, 9, 8, 3, 4, 2, 5, 6, 7],
[8, 5, 9, 7, 6, 1, 4, 2, 3],
[4, 2, 6, 8, 5, 3, 7, 9, 1],
[7, 1, 3, 9, 2, 4, 8, 5, 6],
[9, 6, 1, 5, 3, 7, 2... |
0e32728de940301f6cdabbc3ceaa13300a22338c | de0670c97351b00340124593e7b91cd0ece0f919 | /sacx/environments/mock_env.py | 4785d238ae755f4d8ad065bf09357a31158f56b3 | [
"MIT"
] | permissive | ascane/sacq-hsr | 8927171d83e9bc91e013d34ca59c7e2edbd185f6 | c143e3e98ab882188f511a4b4edcde8cd10fc9f4 | refs/heads/master | 2020-03-27T03:28:08.471833 | 2018-09-06T10:28:45 | 2018-09-06T10:28:45 | 145,865,392 | 6 | 0 | null | null | null | null | UTF-8 | Python | false | false | 934 | py | mock_env.py | import numpy as np
from core import FiniteActionEnvironment, State, Action
from sacx.extcore import TaskEnvironment
ACTIONS = [0, 1, 2]
TASKS = [0,1,2]
class MockState(State):
def __init__(self, terminal, state):
super(MockState, self).__init__(terminal)
self.state = state
class MockEnv(Finit... |
5d3d15a52a0095818a8ac58edde8005ac0b38470 | c15767dbf19e6c92c52aa4ae943243d156804be9 | /src/_version.py | 311eb7007b02ee7914a361a6f38b14683b1ab440 | [] | no_license | TJM/newRHELic | a89317be6baefe4ce0902ae3bbc1de3702506adb | d20d53d94456cb144f08d2e342bdc8f53c2ec1c5 | refs/heads/master | 2021-01-18T03:52:26.844588 | 2014-06-20T22:35:26 | 2014-06-20T22:35:26 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 35 | py | _version.py | # Version File
__version__='0.2.0'
|
f9b82513d62a51a405973bc6437237da9a66e3ce | 4b961f497f9c70603dbf42ec57f33e7c323c6431 | /src/simulator.py | 383883584d6e644776fd27db67dd5a0919879ffb | [
"MIT"
] | permissive | brotherBear/simulator | ff514a673eeb0e3068e225fb17520dc3b4d100e8 | 260cba8342f46867e6b444c38d41f97dc9142afe | refs/heads/main | 2023-01-02T22:47:30.764752 | 2020-10-27T13:28:34 | 2020-10-27T13:28:34 | 306,468,955 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,870 | py | simulator.py | # -*- coding: utf-8 -*-
from random import randint, random as r
NOT_FOUND_PCT = 0.011
CONNECTION_FAIL_PCT = 0.002
VERIFICATION_FAIL_PCT = 0.023
def fc(batch, pct):
""" Roll the dice to see how many should fail"""
res = 0
for i in range(batch):
res += 1 if r() < pct else 0
return res
def sta... |
5d64176b0a9be930b4c71cc7eb3c50a8579c2f51 | 88763856256a2039d432d73c087608c05dfa59a9 | /PY01019.py | 58b4aedf175e3ba490dfa3be7339ff9e81f2c4da | [] | no_license | cuongdh1603/Python-Basic | 40a46a4de227a24cc3bc52a05e617df5be8f968c | d68a6c20970fa991a34ba745313ab84295714060 | refs/heads/master | 2023-09-05T18:18:29.796370 | 2021-10-23T09:39:30 | 2021-10-23T09:39:30 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 339 | py | PY01019.py | # XÂU “THĂNG BẰNG”
t = int(input())
while t>0:
s = input()
l = len(s)
s1 = s[l-1::-1]
check = 1
for i in range(1,l):
if abs(int(ord(s[i])-ord(s[i-1]))) != abs(int(ord(s1[i])-ord(s1[i-1]))):
check = 0
break
if check == 0:
print('NO')
else: print('YES')
... |
082627041a5c03123195874a8737797aff23ded3 | 202bf6cd78eb19025aa63dea609b40903ce1a735 | /data/plate_reader/metadata/specs_plate048u.py | 1e67e93cc5ad991d9de207197f6dbc6ce84abdd3 | [
"MIT"
] | permissive | jbkinney/17_inducibility | 1e4a5943bd680252f19008fb77a0b9bb8cfbdaf6 | cb2ddf984608fba6f85c98711bce0d7e450fba0e | refs/heads/master | 2020-04-06T07:28:02.386966 | 2018-12-05T16:25:35 | 2018-12-05T16:25:35 | 157,273,701 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 2,238 | py | specs_plate048u.py | plate_name = 'plate048u'
induced = False
growth_file = plate_name + "_600.txt"
miller_csv = plate_name + "_420.txt"
optics_csv = plate_name + "_550.txt"
raw_growth = "2017.6.15_lacstar_c6r18l10lib_repeat3_plate1_uninduced_315_OD600.txt"
raw_miller = "2017.6.15_lacstar_c6r18l10lib_repeat3_plate1_uninduced_miller_10h_... |
8a14ebd8650a5d68d8287aa696889a5ac47296f7 | 1c893091dc6055a750a484bc48dc468d727814f9 | /tests/test_pact.py | 2377d1562a6f3503bc146192c8b4b6fb239de876 | [
"MIT"
] | permissive | felipevolpone/py-contract | 2d0706f9fe85b6fb427792fbd5425bd603533beb | c4c3f007b4bec2b3c734020ce998c0aaaf5658b1 | refs/heads/master | 2020-04-05T01:38:08.556996 | 2018-11-12T17:29:02 | 2018-11-12T17:29:02 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 757 | py | test_pact.py | import pytest
from contract.pact import Contract
from .conftest import client_http
def test_pact_green_path():
contract = Contract('tests/contracts/pact1.json')
expected = {
"user": {"name": "felipe", "lastname": "volpone"},
"repo": {"host": "github", "name": "py-contract"}
}
# fake ... |
4991d27b6ec9765c03d0913e431e03deed682481 | acc02c76f31e726823d2df5bf86f08dddd42ef2a | /2011/Senior/S3.py | e345f3a4fdbdb08d8f07b1f5ddef842fb6f3d5d7 | [] | no_license | zywh/waterlooccc | 3b0e4dac9bcb9ee10e58346658edf0456efb7cc5 | 86744a21ed6df0c0958ab495376a6f50c389fb14 | refs/heads/master | 2021-05-05T01:23:52.221179 | 2018-02-06T17:03:41 | 2018-02-06T17:03:41 | 119,609,349 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 2,036 | py | S3.py | # CCC 2011 Senior 3: Alice through the Looking Glass
# written by C. Robart
# March 2011
# Recursion. It's simple, once done, but
# it took a LONG while to think of it and debug :-)
#
# Consider the original configuration of blocks
# _____
# __X__
# _XXX_
#
# As the grid expands, with increased m, I think of the... |
b525d2c1f40ae392e795178335421a7d49695373 | fdfec00c4cd7d655bb59412c9acd44ee4fae32b9 | /imageRecognition/wrapper.py | 2e6304bd79eca686ffd44017f0950e0aafb15552 | [] | no_license | nhongooi/ImageMatching | 83cc6ef8f24fb69804c0e62e70dfb84cd96205d3 | 078c450785383a81d2617d388d0e649adc5e5d15 | refs/heads/master | 2020-03-12T03:29:26.574395 | 2018-04-24T18:58:03 | 2018-04-24T18:58:03 | 130,425,627 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,318 | py | wrapper.py |
from multiprocessing import Process, Queue
from imageRecognition.process import block, template, hashing
from imageRecognition.util import extract, crawler, FileUtil
class ImageWrapper():
""" Wrap all image processing functionality"""
def __init__(self, imaging_type, return_path, path, search='image',
... |
a997e61c9dc62f721520d5c08d348aded8d16644 | afd2087e80478010d9df66e78280f75e1ff17d45 | /benchmarks/tensorexpr/tensor_engine.py | 9b598bf046d758d4e701670036edf63fae5b1223 | [
"BSD-3-Clause",
"BSD-2-Clause",
"LicenseRef-scancode-secret-labs-2011",
"LicenseRef-scancode-generic-cla",
"BSL-1.0",
"Apache-2.0"
] | permissive | pytorch/pytorch | 7521ac50c47d18b916ae47a6592c4646c2cb69b5 | a6f7dd4707ac116c0f5fb5f44f42429f38d23ab4 | refs/heads/main | 2023-08-03T05:05:02.822937 | 2023-08-03T00:40:33 | 2023-08-03T04:14:52 | 65,600,975 | 77,092 | 24,610 | NOASSERTION | 2023-09-14T21:58:39 | 2016-08-13T05:26:41 | Python | UTF-8 | Python | false | false | 1,133 | py | tensor_engine.py | tensor_engine = None
def unsupported(func):
def wrapper(self):
return func(self)
wrapper.is_supported = False
return wrapper
def is_supported(method):
if hasattr(method, "is_supported"):
return method.is_supported
return True
def set_engine_mode(mode):
global tensor_engine... |
0c1fd60e1627262d717e13a31a05b42114bb4a56 | 4d0d73b5dcd35de5e5d08013ff616b1ffc44b21a | /forum/forms.py | b59360e574a9f226559170cab5c6a6e38ea38ea9 | [] | no_license | GithubMateusz/forum | 873b9d6e5ffb7a8696e958474d6518e4e0e6bef3 | d0209916c7f4567430b12bee1c6acaaa87b65706 | refs/heads/master | 2020-06-02T05:06:46.777346 | 2019-11-07T04:07:00 | 2019-11-07T04:07:00 | 191,046,727 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,052 | py | forms.py | from django import forms
from django.contrib.auth import get_user_model
from django.contrib.auth.forms import UserCreationForm
from django.forms import Select
from mptt.forms import TreeNodeChoiceField
from .models import Topic, Answer, Category
class DisabledChoiceWidget(Select):
def __init__(self, *args, **kwa... |
fc1d74b47e0ae1b8f95437c4350f4fad3d0dd089 | 79b3a9df5b552f5aff8d2a51f6fd4c02f9fb23f3 | /selenium-j4m-01b.py | 93527f15df8bd3f199f5d380bb4a95308184c75b | [] | no_license | noribang/Selenium-tests | c3f1d2fc54a969b0a5f68e7796720af5976b1bea | 3d7155cae05b25d6dcfd88db2492fb37dfd29681 | refs/heads/master | 2020-03-22T04:32:40.905678 | 2018-07-12T21:07:30 | 2018-07-12T21:07:30 | 139,505,290 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,473 | py | selenium-j4m-01b.py | ## Reference: http://selenium-python.readthedocs.io/getting-started.html ##
# import time
from time import sleep
from selenium import webdriver
from selenium.webdriver.common.keys import Keys
# Create of instance of webdriver for Firefox browser.
#a. This will open Firefox browser.
## driver = webdriver.Firefox()
#b... |
60dee9f1cdda181ebd00e2c8c9e7bcf4a6f191d1 | ebc9f43e0376aea0ee666cc1c1e4cc975f4f5df4 | /utils/xh.py | 4fe2d505a1e2fccb4783fd69d980b3620e3be12a | [
"MIT"
] | permissive | urchinpro/L2-forms | e80801f9df382cd3e53925c3cbacb50356d35e45 | 37f33386984efbb2d1e92c73d915256247801109 | refs/heads/ultra-dev_curators | 2020-04-22T00:16:56.957815 | 2019-03-29T13:14:26 | 2019-03-29T13:14:26 | 169,973,749 | 0 | 0 | MIT | 2019-03-29T13:22:12 | 2019-02-10T12:05:02 | JavaScript | UTF-8 | Python | false | false | 55 | py | xh.py | def fix(s: str):
return s.replace('<br>', '<br/>')
|
af616c7e2852b47ad4f9513956a8bfcc251e7c04 | 540b4d418eb9489029430293314cdbb1cff1b027 | /blog/migrations/0005_auto_20180404_0525.py | fd660f6c8b7dffc085f2ee91d34c90b47efaf437 | [] | no_license | inyoka/django2.0_blog_app | 24cfd3a21fe7b52dcd744199c1471785d06f7251 | 9207932795302a53c494e889aa083a332071d1ff | refs/heads/master | 2021-04-12T03:23:30.820567 | 2018-04-05T07:46:20 | 2018-04-05T07:46:20 | 125,961,651 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 717 | py | 0005_auto_20180404_0525.py | # Generated by Django 2.0.3 on 2018-04-04 05:25
import datetime
from django.db import migrations, models
from django.utils.timezone import utc
class Migration(migrations.Migration):
dependencies = [
('blog', '0004_auto_20180404_0522'),
]
operations = [
migrations.AlterField(
... |
e7a3f1008aa8db017b8c1a993bb3849611c0ac72 | 49831adae62cb0f006d75a24640cf0a14e0536d5 | /lab7/cgi-bin/form.py | 9098b8d5866eac451bab1e951f66428b9007f0e7 | [] | no_license | Vitalton/python_labs | 3fad8595d5de7fdd874873ec519f21cd6e8e0418 | b62aa7d9e59096feac67aa278ba178dc27b161f4 | refs/heads/master | 2022-12-26T12:48:13.657411 | 2020-10-13T09:06:13 | 2020-10-13T09:06:13 | 250,501,814 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,058 | py | form.py | #!/usr/bin/env python3
import cgi
import numpy as np
print("Content-Type: text/html")
print()
list = np.random.randint(-33, 44, 16)
print("Массив случайных чисел: ", list, "<br>")
# GROUP 1
def func_1(list):
rezult = 0
for i in list:
if (i > 0):
rezult += i
return rezult
# GROUP 2
de... |
24459876fe61d9d4cdbb6dc9670636c7bde7e015 | 8cb0e880eee46f9c8ae6668025e6af3198bcfd96 | /cluster/join_alpha_scores.py | 5eb288185ceb90d25ac6d86c35fb794820237337 | [] | no_license | galabing/alpha | a9eb568809c0e4cc4452b5227bf064daacb4cf0e | 01413e67f5b20fa8fa03a112450fc5ae80e3ef55 | refs/heads/master | 2020-05-17T15:35:04.084982 | 2013-10-23T05:24:08 | 2013-10-23T05:24:08 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,382 | py | join_alpha_scores.py | #!/usr/local/bin/python3
import argparse
import os
OUTPUT_FOLDER = 'alpha_scores'
def main():
parser = argparse.ArgumentParser()
parser.add_argument('--score_dir', required=True)
parser.add_argument('--cluster_base_dir', required=True)
args = parser.parse_args()
score_files = os.listdir(args.score_dir)
... |
a00d5588a38f7abafde04ce6c4ba75d46d07d4fa | cd3df53a432d35e2fe7b4e4f9bbe62222235a85b | /tests/binding_tests/multipolygon_tests/test_equals.py | 4d6df3c3cbafc462c2ba56885aba05e5c4c07a57 | [
"MIT"
] | permissive | vincentsarago/wagyu | 00ccbe6c9d101724483bde00e10ef512d2c95f9a | f6dce8d119fafa190d07f042ff6c4d5729a4c1e6 | refs/heads/master | 2023-01-20T06:26:27.475502 | 2020-11-21T04:57:01 | 2020-11-21T04:57:01 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,404 | py | test_equals.py | from _wagyu import Multipolygon
from hypothesis import given
from tests.utils import (equivalence,
implication)
from . import strategies
@given(strategies.multipolygons)
def test_reflexivity(multipolygon: Multipolygon) -> None:
assert multipolygon == multipolygon
@given(strategies.mult... |
87279fe41f407589e35d4255521f966e57babd1b | 6932a9ae700a623f16a3aef417d0598cf6d4f389 | /FineTuning/karasu_speak.py | f02fa4b6e6c8ae8675a2b53e6ff09ed8d127c077 | [
"MIT"
] | permissive | MuAuan/hirakegoma | 9f1a252d913749a2c16ae5bd7a8870550048d26d | 861879af1016c25b7a14bcabe543bfba47fd57f3 | refs/heads/master | 2020-04-27T20:12:25.315594 | 2019-03-24T12:38:30 | 2019-03-24T12:38:30 | 174,649,241 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 4,405 | py | karasu_speak.py | # -*- coding: utf-8 -*-
from __future__ import print_function
import cv2
import pyaudio
import sys
import time
import wave
import pydub
from pydub import AudioSegment
import moviepy.editor as mp
import datetime
import os
from vgg16_like import model_family_cnn
from keras.preprocessing import image
import matplotlib.pyp... |
72304cd5a3fd5880c6922509a5de29836b10f3b6 | 8973166216a9ea05fe3700d48ea85862d351edb0 | /apps/blog/templatetags/urlify.py | 3e24a71390392d751bbc1f35ff574b05102d2b8d | [] | no_license | adidacom/django-portfolio | da245af1f83883801c4a833de3f52fa272218059 | a1f32ec5b6612b49e0c4ad80b6081e10cbb5e57b | refs/heads/master | 2022-12-11T23:29:03.455086 | 2019-06-29T13:26:51 | 2019-06-29T13:26:51 | 194,408,528 | 2 | 0 | null | 2022-11-22T02:39:36 | 2019-06-29T13:26:18 | Python | UTF-8 | Python | false | false | 247 | py | urlify.py | from urllib.parse import quote_plus
from django import template
register = template.Library()
# Getting Django template library and register as a filter
# to use inside templates
@register.filter
def urlify(value):
return quote_plus(value)
|
be638e8ded050d8394422af0635d68ab981d3a00 | f8847b16bb44c54b00f40d8d749a5339490c0dd8 | /Interview_Coding_Questions/05-find the pair in array whose sum is closest to x.py | 1cec1af81f3a7db455cc08c0839ac39b0c46b3ae | [] | no_license | sanjitroy1992/PythonCodingTraining | 60478829697e6837abf7cfeff4724b38c57328ac | 0706769084d60a397366d41bb87add8d53ba8eb3 | refs/heads/master | 2021-01-02T02:15:10.609349 | 2020-07-09T18:06:41 | 2020-07-09T18:06:41 | 239,450,113 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,998 | py | 05-find the pair in array whose sum is closest to x.py | """
Given a sorted array and a number x, find the pair in array whose sum is closest to x
Examples:
Input: arr[] = {10, 22, 28, 29, 30, 40}, x = 54
Output: 22 and 30
Input: arr[] = {1, 3, 4, 7, 10}, x = 15
Output: 4 and 10
Note: Here taking the absolute value of the difference is very important. this way we could ch... |
2a8b812b407e3ea6946396a098509d84550101b1 | f0dbc5087579f5d91dbdc2875c8af33e7249d49a | /{{ cookiecutter.experiment_name }}/run | ea2a966ef3f8f689621a0f195233ddc4121ce37e | [] | no_license | mightyCelu/cookiecutter-veins-experiment | 65e7bb0ffa7898d05dd3bde2cb2bbe1ce003e73c | 11c58b9d0bc3277d791d8e3547edd1dff07e1682 | refs/heads/master | 2020-08-03T19:26:22.932623 | 2019-10-15T08:20:25 | 2019-10-15T08:59:22 | 211,860,830 | 0 | 1 | null | 2020-07-16T14:52:35 | 2019-09-30T13:01:20 | Python | UTF-8 | Python | false | false | 1,817 | run | #!/usr/bin/env python2
"""
Runs Veins simulation in current directory
"""
import os
import argparse
def relpath(s):
root = os.path.dirname(os.path.realpath(__file__))
return os.path.relpath(os.path.join(root, s), '.')
parser = argparse.ArgumentParser('Run a Veins simulation')
parser.add_argument('-d', '--de... | |
6dbffe802cf6b0c0a9382ca5e26d40dec199e746 | d5b6c00e8892adf049a300f141b939fe5199d8e9 | /untitled6.py | 8a9645802a90e60ba32a33b7f0712abaeb57d990 | [] | no_license | saikumarballu/PythonPrograms | 1b547f497b706769b444accb2795c40ad5057d4d | e6d2f6c0061a3263fbbd7db8239b53b3a4c2a339 | refs/heads/master | 2020-04-28T17:59:18.349212 | 2019-07-16T21:23:08 | 2019-07-16T21:23:08 | 175,463,773 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 120 | py | untitled6.py | # -*- coding: utf-8 -*-
"""
Created on Fri Mar 1 12:50:19 2019
@author: saib
"""
a = [1,2,3,4,5,6,7]
print(a.length)
|
cf584ae3e76266c86973e33a57260f4642503070 | 834844eb2f530d32570f03c70f6556aff9ae2f74 | /prawmagic.py | f0091f3e5fc97dde0ed56902073fd1adcac4c640 | [] | no_license | zahmadpost/reddit_data | da4ed3ff0a50ff1835d62cc68a1e3975bfd858d6 | 48bdb5f580aae8c1497dfd9f4953fcc2d03ab344 | refs/heads/master | 2022-04-05T04:54:40.074071 | 2020-02-02T05:32:09 | 2020-02-05T03:28:28 | 221,596,382 | 3 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,344 | py | prawmagic.py | FETCHES = 16
def speed_up():
_modify_rate_limit()
_use_prefetch()
# use exponentially decaying rate limiting to enhance burst performance
def _modify_rate_limit():
from prawcore.rate_limit import RateLimiter
from time import time
if not hasattr(RateLimiter, "update_without_mod"):
RateLimi... |
50b0331cf23aaf16b00da9bcc2813597a312c829 | 029ad695064b5a919fd816c2dfa75a70f9419872 | /demo_face_compare.py | 78e7c9129987a9c1cd9c9e73786c4b6a977173ef | [] | no_license | THU-2021-AI-Class-10th-team/ai_shop | 5a48242c0f2621682fe15889c054c12407cea9cb | d9fd89979add99ee6da4994cc69a51a2ec307c01 | refs/heads/master | 2023-07-31T21:24:05.923148 | 2021-09-14T13:55:50 | 2021-09-14T14:04:08 | 397,913,690 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 9,295 | py | demo_face_compare.py | from flask import Flask, request, jsonify
from typing import NewType, Tuple, List
import boto3
import cv2
import flask
import io
import numpy as np
import os
import pathlib
Path = NewType('path', pathlib.Path)
def compare_faces(source: Path, target: bytes) -> Tuple[float]:
'''Send pictures and evoke rekognitio... |
ea0b22d0705ecb352ba554465245f19155081182 | 7d7bbaea128d521c40d2d0890b025ca05c258547 | /registration/models.py | 406c3cf5e6fe9e54b17a93866f48065ba844063a | [] | no_license | TitechMeister/mikan | 43c27a267cc24c5c26464454de5443f6a7e8c567 | f51878b0fc18ab74b37c8a045e1a0d7c6877dcfb | refs/heads/develop | 2022-12-12T19:23:31.168911 | 2021-10-28T14:38:26 | 2021-10-28T14:38:26 | 123,887,409 | 0 | 0 | null | 2022-12-08T03:15:00 | 2018-03-05T08:19:26 | Python | UTF-8 | Python | false | false | 862 | py | models.py | import pytz
from string import ascii_lowercase, digits
from random import choices
from django.db import models
def generate_code():
return "".join(choices(ascii_lowercase + digits, k=10))
class RegistrationCode(models.Model):
code = models.CharField(max_length=10,
default=generat... |
c846fc160be40c138ec695cc7f7fa487fb98f577 | 9bdb641c0e6e29e88c1a6d482650024c30d25b2b | /ui-server/model/rover.py | 8051a9bbaed3357d74f84a1191717f9315aaa6d5 | [
"MIT"
] | permissive | TomZurales/northernpike | b7ec42c9e697ac7c389f4728fd9fcfe53f348557 | f7d878ad7681456e95e3c480b31bfcb2358aa2d9 | refs/heads/master | 2020-04-17T02:10:11.946728 | 2019-01-09T05:29:35 | 2019-01-09T05:29:35 | 154,417,170 | 0 | 0 | MIT | 2018-10-24T01:00:04 | 2018-10-24T01:00:04 | null | UTF-8 | Python | false | false | 395 | py | rover.py | import csv
class roverState:
def __init__(self):
self.writer = csv.writer(testfile1.csv, dialect='excel')
def getRoverGyro(self):
return "Gyro values x: %d y: %d z: %d" % (self.x, self.y, self.z)
def getRoverCompass(self):
return "Direction: %d" % (self.d)
def readGyroData(self):
return None
def wri... |
a921f1c1b664d60807da218e5f898cfba2682a58 | b39fde658004b2cde70251856514db9e8d862cf2 | /16.py | 80b46329191cb7bde68ac81d2ba172bef6b1b062 | [] | no_license | mit-d/euler | 2fe85b284761a2aeb399225970efcc41e15d312d | 859bd2356a9cf2048f104ea6961af1a5dc24b2af | refs/heads/master | 2021-01-03T02:43:48.207507 | 2020-02-19T00:28:37 | 2020-02-19T00:28:37 | 239,886,086 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 286 | py | 16.py | # Power Digit Sum
# 2**15 = 32768, and the sum of the digits is 3 + 2 + 7 + 6 + 8 = 26.
#
# What is the sum of the digits of 2**1000?
def SumDigits(n):
ans = 0
for i in str(n):
ans += int(i)
return ans
if __name__ == "__main__":
print(SumDigits(2 ** 1000))
|
47ac5c222da8f67549fe335916e2063c843b1844 | 702b36d1a4ffc251d2f15c7a2a70039fefec2f67 | /Set2/Code/13-ECB_Cut_n_paste/msg/PADDING.py | 2ed7c97395f48d8d74d142110a90d3bdd12118ce | [
"Apache-2.0"
] | permissive | Jason429/CryptoPalsChallenge | fe0224383f012dab780cc3a6b32242e2851c8096 | 7da9d5b615183b9479ec4375c0c7b89bb2161b1d | refs/heads/master | 2021-09-05T22:20:56.201037 | 2018-01-31T10:07:04 | 2018-01-31T10:07:04 | 119,669,049 | 0 | 0 | null | 2018-01-31T10:05:28 | 2018-01-31T09:59:33 | Python | UTF-8 | Python | false | false | 758 | py | PADDING.py | #! /usr/bin/python3
def pkcs7(msg, len_needed):
"""(len_needed = int)This returns a bytearray with pkcs7 padding.
Msg needs to be bytearray
It places it into the msg.
It takes the the msg and add the padding required to the end."""
# Test for int
if type(len_needed) != type(1):
print('From padding.... |
d19b64f067d58683e0097783f4c740710962c286 | 33fc96c5fcc983bb312518cfbe766e95173fb895 | /docs/examples/random_agent_robot.py | 2d9dba6bcc596298d8db01443af48a285723b698 | [
"MIT"
] | permissive | jr-robotics/robo-gym | 47439a319a40ed159ebdfed510e98f9e0a9d7611 | 93386e52d259399e3939dcef0e96fa5208c020e3 | refs/heads/master | 2022-05-06T07:54:11.917706 | 2022-03-09T15:02:26 | 2022-03-09T15:02:26 | 252,740,567 | 360 | 67 | MIT | 2020-05-26T11:32:49 | 2020-04-03T13:29:26 | Python | UTF-8 | Python | false | false | 385 | py | random_agent_robot.py | import gym
import robo_gym
robot_address = 'xxx.xxx.xxx.xxx'
# initialize environment
env = gym.make('NoObstacleNavigationMir100Rob-v0', rs_address=robot_address)
num_episodes = 1
for episode in range(num_episodes):
done = False
env.reset()
while not done:
# random step in the environment
... |
ca54efefef3569bed93ac4c0ae1b7ee9c47e16fc | e37842595b75eba28ab268112ec89f8d2d84ff8f | /models.py | d1ada3e328a2ce74b6fc12241882c0b009f25f24 | [] | no_license | german-iakovlev/hangman | e46746ce86a27b423b6c4972fc6a4871aecd3045 | 04e551a65dd14c47d4404e7c6966c8bf0f784ff3 | refs/heads/master | 2021-10-24T11:42:41.392462 | 2019-03-25T19:30:50 | 2019-03-25T19:30:50 | 107,897,423 | 0 | 1 | null | 2019-03-25T19:30:52 | 2017-10-22T19:47:15 | Python | UTF-8 | Python | false | false | 1,659 | py | models.py | import urllib.parse as urlparse
import os
import psycopg2
from peewee import *
from hangman import loadWords, chooseWord
import time
from datetime import datetime
import json
if os.environ.get('DEBUG'):
config = json.load(open('local_db_config.json'))
db_name = list(config)[0]
db = PostgresqlDatabase(
... |
06d7961205342b233553a5375517657278e4440f | 6030f0c7c56a88c90d4880c07b5c3e54b149c99f | /im/interface.py | 0f845f9e700d6ee9e14994f8412cd54c562a6d5f | [] | no_license | yetihan/slack-robot | 768834adcff74b9c29e8f8356029d34e23edb586 | e217e58ced97e7a18127e378bac95aa5ae332225 | refs/heads/master | 2022-12-30T15:31:32.525298 | 2020-09-28T14:27:10 | 2020-09-28T14:27:10 | 299,012,310 | 0 | 0 | null | 2020-09-28T14:27:11 | 2020-09-27T10:59:58 | Python | UTF-8 | Python | false | false | 244 | py | interface.py | from abc import ABC, abstractmethod
class IM(ABC):
def __init__(self):
pass
@abstractmethod
def send_msg(self):
return NotImplemented
@abstractmethod
def get_msg(self):
return NotImplemented
|
123dcf410a8c9b824c214b36e81fc7379ea3c6d7 | e27b64ccde7f6e25ad6e8c5ab466613de7ce5e01 | /utilities.py | 18b7d350a70095ac795e17e930e2e6ab845cd7d1 | [] | no_license | sksg/mega | 3a6bcabd26549595937509018d56120f7807d9ed | b4834734966206426eb47e56c17949bbf64e8cad | refs/heads/master | 2023-03-08T02:15:53.623233 | 2019-01-11T08:32:58 | 2019-01-11T08:32:58 | 151,526,715 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,135 | py | utilities.py | import numpy as np
import os
import cv2
from concurrent.futures import ThreadPoolExecutor as thread_pool
from concurrent.futures import as_completed
from numba import jit
@jit(nopython=True)
def rint(array, dtype=int):
return np.rint(array).astype(dtype)
@jit(nopython=True)
def fint(array, dtype=int):
retur... |
152b0acdde671019e77b797f3d65836ff22bf4a1 | a0e9accc4d46ef431e6b30405977dcc7549f4f75 | /bookmark/views.py | b8ae660f8c67e6c733a5fb02f2502665cba62314 | [] | no_license | MrSaerus/RSS | 536ccf29823a4d37c15f99f59d74d3d56fba3472 | 515ffc5a6fd8f301ad973e21713abe322d9b703a | refs/heads/master | 2022-11-12T14:12:34.470143 | 2020-06-29T11:23:40 | 2020-06-29T11:23:40 | 272,680,978 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,295 | py | views.py | from django.shortcuts import render
from bookmark.models import book_mark
from configuration.views import TempFunction
from configuration.views import username_f
def getBookMarkUser(UserId, read):
if read == 'all':
BookMarkUser = book_mark.objects.select_related().filter(user_id=UserId)
else:
... |
dc7c8ea5653c63801504a62225be799cfc28eeb4 | 6746806c593e0f674827531fee2d5fd99534d60b | /I0320055_soal1_tugas5.py | 97c8ff8c6a4b5b57130e325c608095c441d4b842 | [] | no_license | Larasfadani/Larasati-Fadhilah-Adani_I0320055_Tiffany-Bella_Tugas5 | fa31d8faa945b342bfb19743051869a2a0bea699 | 269c8db510c18b7e16ec002ce2cf72ad55ca4a66 | refs/heads/main | 2023-04-07T09:42:41.050679 | 2021-04-02T18:25:18 | 2021-04-02T18:25:18 | 353,972,025 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 297 | py | I0320055_soal1_tugas5.py | print("Selamat datang di Hotel Del Luna, silakan masukkan nama dan jenis kelamin anda!")
nama = str(input("Siapa nama anda? "))
jk = str(input("Apa jenis kelamin anda? (P/L) "))
if jk == 'P':
print("Selamat datang, Nyonya", nama, "!")
else:
print("Selamat datang, Tuan", nama, "!")
print() |
710b737ac13c6bd0bd697e68b0ae8e94e15e2ecf | b88861187583e6c874aa9b5d821f3b22ea3fcc1e | /logs/mc_log_ui/mc_log_tab_widget.py | 25721d2be4223acdda4fa98e83762ab6073219cb | [
"BSD-2-Clause",
"BSD-3-Clause"
] | permissive | stephane-caron/lipm_walking_controller | 441bb95e5511e121d4309891d7eb36b8e4a0540d | ecdb81e824273b0dc867ae26633ea742dadfb119 | refs/heads/master | 2023-09-04T07:52:56.837217 | 2023-08-11T20:20:34 | 2023-08-11T20:20:34 | 149,110,222 | 186 | 48 | BSD-2-Clause | 2019-12-11T22:30:36 | 2018-09-17T10:43:44 | C++ | UTF-8 | Python | false | false | 1,229 | py | mc_log_tab_widget.py | # -*- coding: utf-8 -*-
#
# Copyright 2015-2019 CNRS-UM LIRMM, CNRS-AIST JRL
#
from PyQt5 import QtCore, QtWidgets
class MCLogTabBar(QtWidgets.QTabBar):
def __init__(self, parent = None):
super(MCLogTabBar, self).__init__(parent)
def mouseReleaseEvent(self, event):
if event.button() == QtCore.Qt.MiddleBu... |
6c2d32ddc2a4f7cb743cb7f70f401f3fba37d7e4 | 56c21a5483e320f3caa76d99afb8709862de4581 | /AR_week8_test/src/move_panda_square.py | 18b3948252652601d08a70cbcea6b782f8a7fb37 | [] | no_license | sivakar94/Programming_Robot_movement | 777465f136728526596bd9ecc240e67c9375b619 | 275a67c818c89e9efb37a964fa14ec80e6018a1a | refs/heads/master | 2020-07-28T02:35:24.903985 | 2019-09-18T10:32:35 | 2019-09-18T10:32:35 | 209,281,744 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,141 | py | move_panda_square.py | # Name: Sivakar Sivarajah
#!/usr/bin/env python
# license removed for brevity
import rospy
import sys
import copy
import rospy
import moveit_commander
import moveit_msgs.msg
import geometry_msgs.msg
from math import pi
from std_msgs.msg import String
from moveit_commander.conversions import pose_to_list
from AR_week8_... |
1c3ceea611c9a4a2221e4ad8e44603a4daf5db3f | 8d60e95792b051547019f0983a72eecce781211c | /perpustakaan.py | 366e5633a9dffa9115da2da7c24e2f90433b4703 | [] | no_license | Ruzuren/Tugas | 299f7613cb1d8b7c2295a3697beb70fa34650a76 | 5e8e9fd34220dc8a992025162f58f2029c6617af | refs/heads/master | 2023-05-10T10:55:08.235446 | 2021-06-07T06:54:35 | 2021-06-07T06:54:35 | 357,816,582 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 17,246 | py | perpustakaan.py | from flask_cors import CORS, cross_origin
from flask import Flask, request, jsonify
from flask_sqlalchemy import SQLAlchemy
from sqlalchemy import create_engine
from flask_migrate import Migrate
from flask_bcrypt import Bcrypt
from sqlalchemy import text
import base64
import uuid
app = Flask(__name__)
app.config['SQLA... |
eea556e1ff8d079ea55be2be5829513026b96f5a | 968881dcd0864f40bae3fce60ca841c8a9eb395f | /main.py | b3d9450a0f4929eed931de569be8f01dbec45133 | [] | no_license | NikkiFRTL/alien_invasion | f173fd5294bb040cf1bcb933ddd668be96e0ad6a | 03c41cdfeb7adbbc830733e4f853cd4d898a792d | refs/heads/master | 2023-02-26T01:25:43.986663 | 2021-02-02T12:30:51 | 2021-02-02T12:30:51 | 332,176,105 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 14,021 | py | main.py | import sys
from time import sleep
import pygame
from settings import Settings
from ship import Ship
from bullet import Bullet
from alien import Alien
from game_stats import GameStats
from button import Button
from scoreboard import Scoreboard
class AlienInvasion:
"""
Класс для управления ресурсами и поведение... |
91f220d2701cbec226e197f51c47d110db7dabf1 | cd9349782665c734102b54f174dee1b22ccd2a70 | /dsdag/core/__init__.py | 76a94121626dd507f395964829fe4375847193d6 | [] | no_license | Sandy4321/DSDAG | 43169a4d453bb04467948c02457702098c6f7f5f | 22398d61b87c4594542bf274a31cd384afc38968 | refs/heads/master | 2020-07-08T12:50:45.776158 | 2019-03-20T21:22:14 | 2019-03-20T21:22:14 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 70 | py | __init__.py | import dsdag.core.op
import dsdag.core.dag
import dsdag.core.parameter |
543886cce2ce896d1f38bb654f86f7754e32e668 | 5b16b66eb5268fa596dfefd6556c46b89966a08a | /test/test_batched_fps.py | 4da8b8247f10942bb777e88fe4c7a6ec39c74cad | [] | no_license | iffiX/scratchpad | 57bc724cd58056508afd1bcd2a3b68039bb3229e | b85fe7a02d659de229cdda867d3082c4e9165763 | refs/heads/master | 2022-12-04T05:13:25.512728 | 2020-08-24T04:06:26 | 2020-08-24T04:06:26 | 287,674,031 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 960 | py | test_batched_fps.py | from scratchpad import (
Setting,
Point,
BatchedScratchPad,
get_brushes,
set_omp_max_threads
)
from time import time, sleep
import numpy as np
# 19ms per frame (2 pads), per layer at 1024 * 1024, using 2 threads per pad, float
# constrained by memory bandwidth
pad_size = (1024, 1024)
pad_num = 2
i... |
9f9c664b7a67ebdc1aa6fc4df5d71bf978fba4a3 | 1518ed59b0dfe80febe415f806a4303940cd212d | /src2/calendar_app/migrations/0010_auto_20200915_2134.py | 5f81cc27796b7a883086a866fdf5df1a206e14db | [] | no_license | wilson-song-git/Social-Calendar-App | 3695fe214bc94bfb14c0c4a52895c4d7754e6540 | f4f4df628afd1b129b6bf841609c33df27ffa131 | refs/heads/main | 2023-02-22T06:14:06.234546 | 2021-01-26T21:44:55 | 2021-01-26T21:44:55 | 333,217,494 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 390 | py | 0010_auto_20200915_2134.py | # Generated by Django 3.0.8 on 2020-09-15 16:34
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('calendar_app', '0009_auto_20200915_2117'),
]
operations = [
migrations.AlterField(
model_name='event',
name='title',... |
aebc4e002adce3b8a3cd754eca90ff0edf821481 | 07c4c1a40c9e3f3121676f46c66adeff15bc82b4 | /src/main/app/LanguageLevel.py | d9e61960310f6f9b419b815577a5c4dddbd5b62c | [] | no_license | lpekelharing/Dev6Delivery | 2c2bfe68592e565e76e7b8df1bc507db47cf3923 | 22696d30db40af365373506b83262c1b3c45159b | refs/heads/master | 2021-06-09T12:46:45.728114 | 2016-12-12T16:30:22 | 2016-12-12T16:30:22 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 80 | py | LanguageLevel.py | class LanguageLevel():
def __init__(self, languageLevel):
# TODO
pass
|
1f46f93ede62d22be8cde6d29d3445475f6a01ec | 6516f49fd375829d420a550ecfb857b3596c50c3 | /scripts/CRplotMaker/make_NJNB_extrap_plots.py | 0573b766784202fa13a4c742e62412e198a42629 | [] | no_license | cmstas/MT2Analysis | c2fe67ee19632c1ece6bd41dced72e003914fcca | 8f227858ccf18fb85972feeaadabf5c445d7bebb | refs/heads/master | 2023-08-21T14:45:58.807579 | 2023-08-13T19:41:07 | 2023-08-13T19:41:07 | 17,522,563 | 0 | 2 | null | null | null | null | UTF-8 | Python | false | false | 12,537 | py | make_NJNB_extrap_plots.py | #! /usr/bin/env python
import sys
import ROOT
# run in batch mode to suppress plot windows
ROOT.gROOT.SetBatch(1)
from MT2PlotMaker import *
import MT2PlotDefs as pd
plot_defs = [
("nJet30_ge7j", True, None, None),
("nJet30_ge7j_0b", True, None, None),
("nBJet20_ge7j", True, None, None),
("nJet30_ge7... |
56c34e4e68d935ab66d2d9dea1b9e3686183c0dd | 177df6bb9033ae6a239aea696d598950381554b8 | /hiworld.py | 05c225a6752b4e01f43e6436111669987d4822df | [] | no_license | madilon/dojos | e3b4e26eaf907ee9dcd4f6a02f02a8eaa7d5a08f | 272da459fdbc70e0f814c66433cb9ecf62be2b2b | refs/heads/master | 2020-08-30T21:04:30.982935 | 2019-10-30T09:24:26 | 2019-10-30T09:24:26 | 218,488,661 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 103 | py | hiworld.py | def sayhi(name, age):
name = Madalin
age = 24
print("Te numesti" + name "Ai varsta de" + age)
|
0008a36bbb7b8a5b2758ccd8f0f4fd481d02ad5c | 8c22fd1746a8dd4b3d63a533e45fd325c79917c1 | /threads/RequestNewSuccessor.py | 208ec247780cbba7d001215f83b513f74a723112 | [] | no_license | william-coulter/COMP3331_assignment | f9aba944d552aea085b242f18307a71ab47bc360 | 51e993c7cbb8241b7c8665ecc04bd8c197854c21 | refs/heads/master | 2021-11-03T19:58:44.622117 | 2019-04-26T13:23:27 | 2019-04-26T13:23:27 | 179,949,402 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,164 | py | RequestNewSuccessor.py | import socket
import threading
import pickle
from supporting.Messages import requestNewSuccessorMessage
# sends a message requesting for a new successor over TCP
class requestNewSuccessor(threading.Thread):
def __init__(self, id, prev_successors, is_immediate=False):
threading.Thread.__init__(self)
... |
25828e34a07f2f96bbce8adb1b4c8681bfce8186 | 5281cf03d1269f341cbf006b43c6f09efa5e98ab | /tests/heom/ploter_yan2021.py | d7d66da96970242b95d365d4b6f6fe83776035be | [] | no_license | vINyLogY/minimisTN | 3927431eb7bf73ffd6cf42aa8faf7c189e7f3c55 | 0d6c7bd23ccf766e8d39c42082e8fb6b751ee2fc | refs/heads/master | 2022-05-09T06:10:56.413522 | 2022-04-12T14:04:48 | 2022-04-12T14:04:48 | 140,754,574 | 3 | 1 | null | 2022-04-12T14:04:19 | 2018-07-12T19:11:10 | Python | UTF-8 | Python | false | false | 1,120 | py | ploter_yan2021.py | #!/usr/bin/env python3
# coding: utf-8
from __future__ import absolute_import, division, print_function
from minitn.heom.network import simple_heom
import os
from builtins import filter, map, range, zip
import numpy as np
from matplotlib import pyplot as plt
f_dir = os.path.abspath(os.path.dirname(__file__))
os.chdi... |
12d0054637b6c91cd07f7fd99cabd8ba545731af | 5d1c43bb4881039f198eedcee2ceb101b406e0a0 | /Django/project/project/urls.py | 2bd89445e159dd79ed8bae67703ef4f24bd9310e | [] | no_license | MunSeoHee/Likelion_Gachon_2020 | 46155b1686a245a59c5664f7726ac754b7079e4b | e0e48845fdb0e4aa2365e7c47e29880a27f0f261 | refs/heads/master | 2021-04-10T09:51:06.618980 | 2020-12-07T10:06:43 | 2020-12-07T10:06:43 | 248,927,668 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,273 | py | urls.py | """project URL Configuration
The `urlpatterns` list routes URLs to views. For more information please see:
https://docs.djangoproject.com/en/2.0/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-based... |
31f25e913f7e9488976cc5fffe3020ab478de375 | fd950e1300352785f249660e16b6d3aa3932795b | /Working/Masters/2.3 answers.py | 15c64a5c668c66a8ec8945f6602ffb8dff9253d5 | [] | no_license | matthewcheung810/ICS3U1d-2018-19 | 120d82db319f966a9b6bc80915e073cd2d555aa2 | 1df42619284883298f1d2c09669a41342dd46144 | refs/heads/master | 2020-04-25T23:13:38.919069 | 2019-05-29T15:07:01 | 2019-05-29T15:07:01 | 173,137,961 | 0 | 0 | null | 2019-02-28T15:33:39 | 2019-02-28T15:33:38 | null | UTF-8 | Python | false | false | 410 | py | 2.3 answers.py | def caught_speeding(speed, is_birthday):
if is_birthday == True and speed <= 65:
return("0")
elif is_birthday == True and speed >=86:
return("2")
elif speed <= 60:
return("0")
elif speed >=81:
return("2")
else:
return("1")
print(caught_speeding(60, False)... |
fe199cf7842ec59c1311a5c23bb2d6883ef59ce1 | 3b0d17e658a0e74843644ab40edd7abf0c74ce51 | /Hello/HelloWorld.py | 8c7b17ee10df9a8a5f0ffc360660b803b3939646 | [] | no_license | wendyliu1236/First_Git_Project | 7a46aa0edc94c47780fb3d02c9cba51163393d0c | cab42b333b2281bdb986928918c25f96c14457f6 | refs/heads/master | 2020-12-27T04:52:32.358527 | 2020-02-02T16:24:53 | 2020-02-02T16:24:53 | 237,772,271 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 391 | py | HelloWorld.py | # coding: utf-8
# import sys
# import os
# curPath = os.path.abspath(os.path.dirname(__file__))
# rootPath = os.path.split(curPath)[0]
# sys.path.append(rootPath)
class Hello:
def __init__(self):
print("this is init")
def hello(self):
print("hello world! This is my first git project launch... |
cff79a4c658c1448515cb84f50915114f9e17c7b | cf5071539e6c1c8a33d3188b096149c4a76e25c5 | /main.py | c7a24387f13df32b03c95ab00ea8dc182e3bb167 | [] | no_license | arihant72600/BioFaceNet | 8e3043a9411b1bcf4e2e761e7d687dd02fae7bae | d98394de5417848af4b9da5f0f8cf92126749af1 | refs/heads/master | 2023-08-06T03:42:20.295215 | 2021-10-07T19:27:31 | 2021-10-07T19:27:31 | 361,631,553 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,325 | py | main.py | import argparse
from random import randint
import time
import h5py
import numpy as np
import torch
from torch.utils.data import DataLoader, TensorDataset, random_split
import matplotlib.pyplot as plt
from model import Unet
from decoder import Decoder
from loss import Loss
parser = argparse.ArgumentParser()
parser.a... |
07c4f080c229d9b5bea5a452dff6b500720e7bb8 | 360f1f9d3dcf679ad5f8661447aaaf214a34dbe2 | /Init.py | 453273f7f875906bbb76c4ccc5f8769303304d81 | [] | no_license | JavierGuillamon/KaisApi | d247547e9ef44fe290737ba0b855c13aab99b44a | 5a84200d55ea95a99ffe093776f96f370469d6a6 | refs/heads/master | 2022-04-24T03:06:36.124184 | 2020-04-24T17:17:15 | 2020-04-24T17:17:15 | 258,575,751 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,381 | py | Init.py | # -*- coding: utf-8 -*-
import json
from ChampionStats import ChampionStats
from Switch import itemStat
def readJson(url):
with open(url) as json_file:
data = json.load(json_file)
print(data["data"]["Kaisa"]["stats"])
if __name__ == "__main__":
# ==================... |
37c728ece3c2a0eb14614db50dd3a42a733614d0 | b95e71dcc1b42ebf3459ee57bd0119c618a79796 | /HashTable/Easy/202.py | 5de96da8bfc5f5f8a3b9fa65330685bcb7c838a8 | [] | no_license | anton-dovnar/LeetCode | e47eece7de28d76b0c3b997d4dacb4f151a839b5 | 6ed9e1bd4a0b48e343e1dd8adaebac26a3bc2ed7 | refs/heads/master | 2023-06-29T07:21:06.335041 | 2021-07-31T15:08:05 | 2021-07-31T15:08:05 | 361,205,679 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 436 | py | 202.py | """
Happy Number
"""
class Solution:
def isHappy(self, n: int) -> bool:
seen = set()
squared_sum = 0
while n > 1:
to_square = n
while to_square:
squared_sum += (to_square % 10) ** 2
to_square //= 10
n = squared_sum
... |
6a9b26baa217085de3e10dd26e2d4e52f7389a5f | fdcfd694c9d3955690482958f2edcd3e15c2b2be | /source/clear_db.py | 37d391271e01e5fb94fd62fb82c125a27a3aaf9d | [] | no_license | sifae/tremor | 4bf724be980c43135920a81d36b81bbdeb0acb58 | cee249e3cfff38341e8b9ea7182c8bd01a194fda | refs/heads/master | 2021-09-18T17:01:22.038725 | 2018-07-17T05:57:29 | 2018-07-17T05:57:29 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 341 | py | clear_db.py | import sqlite3
import os
def get_parent_dir(directory):
return os.path.dirname(directory)
parent = get_parent_dir(os.getcwd())
os.chdir("{0}/data".format(parent))
conn = sqlite3.connect("data.db")
cursor = conn.cursor()
sql_1 = "DELETE FROM esp"
sql_2 = "DELETE FROM opencv"
cursor.execute(sql_1)
cursor.execute... |
ba2770d75614a19df84268d364f92ff0fa2a7258 | 6863eb1345a41b034372892b54819a4eb7d4dafc | /web_server/MyWebFramworks.py | a0b519881e4206640cf8666211b7eb26cf7ae638 | [] | no_license | YangYangJiang/My-Local-Repository | 13e2cfe36f243764e41836de398e88fb5950568d | 096dedb35471bade6236c4dba40239680fcbd159 | refs/heads/master | 2020-03-22T13:00:03.045178 | 2018-07-07T14:27:20 | 2018-07-07T14:27:20 | 140,075,906 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,705 | py | MyWebFramworks.py | import time
class Application(object):
"""web框架"""
def __init__(self, urls):
# 设置路由信息
self.urls = urls
def __call__(self, env, start_response):
path = env.get('PATH_INFO', '/')
print(path)
if path.startswith('/static/'):
file_name = path[8:]
... |
4e2a49c90e96eeafecaf8b6a2c047ba17d69982d | cf73f475c8539b677aeca8e035b63c5ad2ed7255 | /pandabear17.py | 61447df7d2b74196fc46afb933b565a02f39b70c | [] | no_license | shreejabhattarai/pyapi20191202 | 8bee2b16c67697cc2f712c04f4348957313a3789 | a8c77a40bc59a0299fe9fea97b2ff0cd6cedf415 | refs/heads/master | 2020-09-24T06:00:02.185497 | 2019-12-16T17:47:15 | 2019-12-16T17:47:15 | 225,682,124 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,770 | py | pandabear17.py | #!/usr/bin/python3
import pandas as pd
import matplotlib.pyplot as plt
def main():
# define the name of our xls file
excel_file = "datasets/movies.xls"
# create a DataFrame (DF) object. EASY!
# because we did not specify a sheet
# only the first sheet was read into the DF
movies = pd.read_e... |
a7430e4dcd0259b55ebb8ab02a7dfbe72346bfd2 | 08efa36046a196acbc471786589cf5fb72433067 | /module-2-challenge-3.py | 738c11e2660714638db650f66c02a2c4e2b2bbb0 | [] | no_license | CatSheng/OOP | 3ee718c822285f180e77d0732ef9d5f0ca309d83 | 1aa9b3390aaf30a244243fffd9880cee3d9a732a | refs/heads/main | 2023-04-08T13:53:31.167989 | 2021-04-29T02:39:24 | 2021-04-29T02:39:24 | 362,667,292 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,395 | py | module-2-challenge-3.py | # This code will take a month inputted by the user and
# let the user know how many days are in that month.
# month holds the spot for what the user inputs
month = input("Input a month: \n")
# This converts all the letters in the word the user inputted to lowercase
month = month.lower()
# If the month that th... |
e6cfdbcfa3a374f1c2372219441dec75d5560664 | 98b6f55f3d17760a484a07e8727981db199b01ef | /nunif/tasks/waifu2x/waifu2x.py | 60865aabc156eb2e7fc4f959812297c1110fbcad | [
"MIT"
] | permissive | zhuomingliang/nunif | dfca76375c3d874817a0578940bcb76357e2d197 | eab6952d93e85951ed4e4cff30cd26c09e1dbb63 | refs/heads/master | 2023-03-18T15:32:12.404690 | 2021-03-24T03:48:09 | 2021-03-24T03:48:09 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,962 | py | waifu2x.py | from os import path
import torch
import torchvision.transforms.functional as TF
from ... transforms import functional as NF
from ... utils import tiled_render, make_alpha_border
from ... models import load_model
class Waifu2x():
def __init__(self, model_dir, gpus):
self.scale_model = None
self.noi... |
5d6db74e52de22deb7c264fdd2ee775d378a27ca | 56d0ff23ed05c1b7ff2923b9358474e2ef29646b | /MadhaparDemo/Events/migrations/0002_eventalbum.py | 205f27e9fc280350b83aae9d4a3a39acace069c3 | [] | no_license | Pinank/MadhapargamDemo | 64573c0f060d7649b5e7f35d7cab03af5f5fb748 | b3fafdac3b0076df099ad24d16d5322cff8b45a2 | refs/heads/master | 2020-07-20T18:56:34.522695 | 2016-09-11T15:24:37 | 2016-09-11T15:24:37 | 67,099,421 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 953 | py | 0002_eventalbum.py | # -*- coding: utf-8 -*-
# Generated by Django 1.10 on 2016-08-30 13:44
from __future__ import unicode_literals
import Events.models
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('Events', '0001_initial'),
]
ope... |
1c6bf33722ed979d47a97fc8838d135ff346f55f | 043a7826d0897abaeebabe9c5d98b2fd3ced57a8 | /SRC/main.py | cc7ddaa3bb5f0203da943896f6eeaeaecc42ebdc | [] | no_license | Juliet1999Hu/Capstone_Project_2 | 1ad828bc851218d4865964854979eef972b48a24 | 86abdcf2d149677c608e326ea45029f559b948c4 | refs/heads/master | 2022-10-25T20:20:54.628890 | 2020-06-15T05:19:17 | 2020-06-15T05:19:17 | 270,430,445 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 22,493 | py | main.py | # ----------------------------------------------------------------------------
# File name: Third Party Operator Matching Algorithm
#
# Author: Julia Hu
#
# Created on: 9th January 2020
#
# Important information: After ML, the final algorithm was implemented as a pickle file
#
#
# Description:
#
# 1) This is initial e... |
4103311e2be463698ece6982912eec060174ad8a | 8d55f46b5fda2a64acf452396ebc249527b04f7e | /libraries/analyzeResults.py | 998277e70faf7d6c998cd60753f64699b00a723b | [
"MIT"
] | permissive | Vilax/bfactorLocalResolution | 64dbad89fbcc4a772daac83ade92e0bbb382b528 | 26db7a699b1b8904bede376f7689b8069293cf8b | refs/heads/main | 2023-04-27T06:51:01.831615 | 2021-05-06T15:51:35 | 2021-05-06T15:51:35 | 333,019,720 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,250 | py | analyzeResults.py | #!../env/bin/python3
# -*- coding: utf-8 -*-
"""
Created on Thu Apr 30 15:46:30 2020
@author: vilas
"""
from PyQt5 import QtWidgets, uic
# from PyQt5.QtWidgets import QFileDialog
from libraries.plotWindow import PlotLocalResolution_Bfactor
# import os
import icons
# from confPaths import confPaths
class Ui_AnalyzeR... |
cc1335a50e4a070d7347d693b153550f44368dd0 | 25eaaa6ff28877e59b3d46a272b9df65fc3f6282 | /nlp/test_pages.py | 8c7f0279e4b8c2eb8fbf5d7f18dc3f10eca10375 | [] | no_license | bluepokeboy/N-Grams-Smoothing-Virtual-Labs-Website | 61bd033a615bf1a7533a184d61e6f734fd1137b9 | e08c2d016624668de8d0933c65b3e8b243602381 | refs/heads/master | 2020-08-30T11:46:31.182880 | 2019-10-29T19:47:42 | 2019-10-29T19:47:42 | 218,370,913 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,781 | py | test_pages.py | import urllib,json
import unittest
from flask import Flask, render_template, flash, redirect, url_for, session, request, logging, jsonify
from flask_testing import LiveServerTestCase
from flask_sqlalchemy import SQLAlchemy
class MyTest(LiveServerTestCase):
SERVER="http://127.0.0.1:5000"
def create_app(self):... |
56b86ebde61fe32e5cff10c3436b9501ad7e276a | ed2ec6e9f3cb69fd48332251eaf83f0dd8ad7efd | /device.py | 4b9ddbeea696a42ccef81758cf11f79600a79eff | [] | no_license | SemiMaks/unittest | e7888c580ac46b21655393eaf43b870bc05e99c8 | 84d014e4f22280574e608b9786778299e7ae53ba | refs/heads/master | 2023-07-11T06:08:13.348715 | 2021-08-15T22:00:56 | 2021-08-15T22:00:56 | 396,509,659 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 580 | py | device.py | import matplotlib.pyplot as plt
data = {'Смартфон': 251, 'Компьютер': 340, 'Планшет': 36, 'ТВ': 10}
def percent(arr):
return [i/sum(arr)*100 for i in arr]
def test_arr(arr):
return list(arr.keys()), list(arr.values())
def table(arr):
if type(arr) != dict:
raise TypeError
index, values = ... |
db8daf84e1c20287ab96eaef20dadf2c27dceeb6 | 189851fc159bb8ed1d35576b4d6f48c23bfc7369 | /python3/dist-packages/cloudinit/cmd/query.py | 3d95bba51f96ef30c433c9f37cc054ca26773c88 | [] | no_license | riteshshahoo/PvtProdFiles | ab333e09fdc60055a5ad54ee360f9700415a0c53 | 0fdc2906f9da7375b4a7d90d74e3f3d070dfa236 | refs/heads/master | 2021-02-23T11:18:23.492766 | 2020-03-06T10:43:52 | 2020-03-06T10:43:52 | 245,399,085 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 129 | py | query.py | version https://git-lfs.github.com/spec/v1
oid sha256:a95a2ddd9850f32d509e7824ea8440524e1234eee1f648fa383141b9d425680a
size 6216
|
474fab078e3890fc3addae8a283d685b1ce564bf | 9ea2558425f1594014f0290475f230909ed9d1ef | /Archive/3Dmodel.py | 2b11752fb5a4d6219ef268e3881da7b3b6740cd7 | [] | no_license | waffelroffel/BeefSimulator | 7c3b24e61818110e7022cacf25f7164863fb099b | 0cb1c8c1682455d877f74f06e88a38b391119ff2 | refs/heads/master | 2023-07-20T04:18:13.757819 | 2022-07-05T09:30:04 | 2022-07-05T09:30:04 | 235,530,042 | 1 | 0 | null | 2023-07-06T21:56:52 | 2020-01-22T08:31:06 | Python | UTF-8 | Python | false | false | 2,693 | py | 3Dmodel.py | # 3Dmodel.py
#
# Quick and dirty way to solve the stationary part of equations
# TODO: Boundary conditions not implemented
import numpy as np
import auxillary_functions as func
import constants as co
from scipy import ndimage as sn
#3D solution of stationary equation yielding dT/dt = Rn = T(n+1)-T(n) / delta(t)
#NB!... |
285ccc2d096d74f61d81cbb2cf398a53ef9ef3bd | dbc59d7ed0a24fbabb8047d6faa33d372a17edaf | /io/search.py | 9a1b2ac5ff50b23dbbe1868ea444359bece0804c | [] | no_license | milton1993/python-learning | a7434e9cb5c38440bbffa87065da89622edf1328 | 8731b81cc4fd1b255b90f4acf4de71e1a9b20a35 | refs/heads/master | 2021-01-10T06:39:39.290520 | 2015-12-19T15:05:38 | 2015-12-19T15:05:38 | 46,255,622 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 184 | py | search.py | __author__ = 'milton'
#coding=utf-8
import sys
import os
reg = sys.argv[1]
def search(s):
for x in os.listdir('.'):
if x.__contains__(s):
print x
search(reg) |
a68aca2200b993d7db5b79d17b16886b65fb1e13 | b7ba03e884be3b9d4dfeb774f12214cf397bf8e2 | /word.py | 0dbb91e67e775f04bf1f6a9f5b06dab8c82e37eb | [] | no_license | arduan/wordCount | f66113a30607aade4683ae975d90c96dd44225b4 | a8cc6734988b4c2739916ec3a6eb77632cf306e3 | refs/heads/master | 2023-09-04T21:58:34.893967 | 2021-10-29T06:14:20 | 2021-10-29T06:14:20 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,381 | py | word.py | # Подсчет частоты слов в произведении Пушкина Метель.
import string
import nltk
import time
from nltk import word_tokenize
from nltk.probability import FreqDist
from nltk.corpus import stopwords
from wordcloud import WordCloud
from pylab import figure, axes, pie, title, show
import matplotlib.pyplot as plt
f = open("p... |
ab462630d3bbb0720bdf0c23d86e1a6148485179 | 6c867b341bbdfd68d1d919b8138d11fd26e52934 | /actions_selenium/find_stored_element_in.py | ca5d430688a19f2a89de0fbc12b2f405afda4fae | [
"MIT"
] | permissive | alex-carter-bluefruit/Python-ScreenPlay | 61efa3d8e85449fa8533268216fb22132b4b53a1 | 45315c372d9a0773a27f05cf1545cf89a246a5bf | refs/heads/master | 2022-10-17T11:14:26.249954 | 2020-06-14T21:23:26 | 2020-06-14T21:23:26 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 991 | py | find_stored_element_in.py | from screenplay import Action, Actor, log_message
class _find_stored_element_with_text(Action):
def __init__(self, sourceId: str, text: str):
super().__init__()
self._sourceId = sourceId
self._text = text
self._id = None
def and_store_as(self, id):
self._id = id
... |
179308e61bfc50d51bd9643faa01af4f5e0b88a6 | 0ef95aad4db1f9e2e28dcfd8ca94ed6d7393e925 | /ads_project/chatAPI/views.py | f414c65401897b9371acdac4481770dd2e7dbbc9 | [
"Unlicense"
] | permissive | bornajouya/softio | 557adfbd1a05c8c0c5896c872f0bb60407abef40 | d309fb9f67bdabc1a1d6886cb92569c53ece2172 | refs/heads/main | 2023-06-28T09:36:16.544351 | 2021-08-01T19:46:18 | 2021-08-01T19:46:18 | 364,283,938 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,295 | py | views.py | from django.http.response import HttpResponse
from django.shortcuts import render, HttpResponse
from .models import chat
from registerAPI.models import User
from adsAPI.models import Ads
from django.views.decorators.csrf import csrf_exempt
# Create your views here.
#def send_msg(request):
def Chat_View(request,... |
7ffe825e502306780a514601fac5cc7d243b3442 | 697ec61d599bbe8df11f629492ef3f6ddf03831f | /apreciacoes/middlewares.py | cdbd4f4359f6767c39971f0e0d92df7d70a79af4 | [] | no_license | gimoteco/apreciacoes | 5312efecb9a5a23cbda23286670433a7794ede42 | 26eb81c4f9dcba3d24840cdbdea10d3a2ab96cb7 | refs/heads/master | 2021-01-10T10:46:39.981030 | 2016-02-20T23:25:24 | 2016-02-20T23:25:24 | 50,694,475 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 520 | py | middlewares.py | from django.http import HttpResponse
from apreciacoes.base import permite_acesso_anonimo
from django.conf import settings
import re
class LoginObrigatorioMiddleware:
def process_view(self, request, view_func, view_args, view_kwarg):
url = request.path_info
eh_excecao = any(url.startswith(excecao) for excecao in ... |
7b5ebe2e4a81ab97a8c5ec40f0e5e0c6507943eb | 72101d0fc4eaf08f973169559a6692613d2fe77e | /email_api/migrations/0003_auto_20190413_1130.py | f1b3a2a15dee656ce9db0e2d7e67f115e30d800f | [] | no_license | jackarthurm/artists-gallery-api | e6211445b3a4625d1de8e7713fc1d5c60f883a7f | e80a3bce05b0a8ffa159ba6b6e4dab81378e9471 | refs/heads/master | 2022-06-29T01:44:45.230783 | 2020-05-04T17:19:24 | 2020-05-04T17:19:24 | 177,664,234 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 437 | py | 0003_auto_20190413_1130.py | # Generated by Django 2.1.7 on 2019-04-13 11:30
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('email_api', '0002_auto_20190331_2312'),
]
operations = [
migrations.AlterField(
model_name='contactenquiry',
name='b... |
3b6589fc6a3c37452af8e67d483acd8665ace0fb | b6bfe695ad9c71b377f9f476efa66949792bf3e3 | /app/delete_core.py | 61d93a2b590f4ac4d5728c20aa3a97a4385851cc | [] | no_license | elderlima/python_fundamentals | 690d9db7c4fd7ddef5741bc419cba0c9ecf02b52 | 64d4d3ba2a8f5f90c8f6ef80f14f343f32cd1be3 | refs/heads/master | 2021-03-04T11:46:40.001465 | 2020-03-13T20:54:21 | 2020-03-13T20:54:21 | 246,031,430 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 269 | py | delete_core.py | from sqlalchemy import delete
from core import user_table, engine
con = engine.connect()
nome = input('Digite o nome do usario que sera deletado: ')
apaga = delete(user_table).where(user_table.c.nome == nome)
resultado = con.execute(apaga)
print(resultado.rowcount) |
31b739a7345397d4331a7c3faa1770e6c1c8c9b2 | 30badfa6d0dc89c03bc68ddaa4df63ca38bd115c | /Evenements/Evaluation/combine_event_files.py | f083b7bd39e4992ea62d7af3b4d2c2891ee08b74 | [] | no_license | HackaTAL/2016 | 843356a76ab2cd40ab930fb29e4abf82ca0d2c7c | 4247347e3885bd43f33c2304cde16d13e6b5b39d | refs/heads/master | 2020-04-12T09:38:02.455945 | 2018-06-07T12:47:31 | 2018-06-07T12:47:31 | 56,326,588 | 9 | 9 | null | 2016-07-03T16:03:21 | 2016-04-15T14:33:05 | Python | UTF-8 | Python | false | false | 1,274 | py | combine_event_files.py | from optparse import OptionParser
import os
import ntpath
import re
import sys
def parse_match(file_name):
head, tail = ntpath.split(file_name)
name = tail or ntpath.basename(head)
p = re.match("(\S+?)_(\S+?)_(\S+?)_\S+", name)
if p:
team1 = p.groups()[0].replace('-', ' ').replace('~', ' ')
tea... |
cb1eac5c8d5da1bf7bab01c95c28eb50113042a0 | 60a86e7442e19a86874ca44947fcb51571e5278e | /ccmp_monthly.py | 87fca1e37fafcb802213ef44dad9b6b385906569 | [] | no_license | CarlMears/Eval_CCMP_Versions | 26bcf9e41ecccae36148e590b8f04bd685e8ea82 | 374c952d7d28cef52e97b3bbad10c1efb66af847 | refs/heads/main | 2023-06-25T14:12:01.688204 | 2021-07-27T18:30:10 | 2021-07-27T18:30:10 | 390,083,022 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 8,192 | py | ccmp_monthly.py | import numpy as np
import xarray as xr
import matplotlib.pyplot as plt
import datetime
import calendar
import copy
import os
import cmocean
import sys
sys.path.append('C:/job_CCMP/python/eval_CCMP_monthly_bias/')
sys.path.append('C:/job_CCMP/python/plotting_and_analysis/')
sys.path.append('C:/job_CCMP/python/binned_st... |
7cf31765f84e32701e31d6ca5b7540ca05bcf5c0 | d051a2858872089ecef02b1363e986876709b022 | /parser.py | f6a8fdd55a0a7aeb45f0f92fd049b236f4eae4f2 | [] | no_license | colourful-tree/ParseDepParser2Tree | dc9e5599a312185973c117a6086ecfe540f7ffa5 | ea41f91318c26e766dc0dd876953f7dead5b4904 | refs/heads/master | 2021-06-24T22:58:02.346321 | 2017-09-11T01:43:03 | 2017-09-11T01:43:03 | 103,076,314 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,253 | py | parser.py | # coding: utf-8
class Node(object):
def __init__(self):
self.value = ""
self.childrens = None
self.father = None
class Tree(object):
def __init__(self):
self.count = 0
self.origin_sents = []
self.sents = []
self.trees = []
self.trunks = []
... |
b2d420e1ad54354f017a52d9ffac65d35d1e4131 | 0a1b6a70b84d02b518084dd5936ee977adc66008 | /egs/librispeech/ASR/local/test_prepare_lang.py | d4cf62bba586c8d4aa582f769e441a0ba82cb07d | [
"Apache-2.0"
] | permissive | songmeixu/icefall | 13b0ac88d173858cec60330d02279abcae839300 | a80e58e15d9d7b2639f1cc5f2a5997634344aa80 | refs/heads/master | 2023-08-06T02:15:08.318832 | 2021-09-20T07:44:54 | 2021-09-20T07:44:54 | 408,423,891 | 0 | 0 | NOASSERTION | 2021-09-20T11:55:26 | 2021-09-20T11:55:25 | null | UTF-8 | Python | false | false | 2,805 | py | test_prepare_lang.py | #!/usr/bin/env python3
# Copyright 2021 Xiaomi Corp. (authors: Fangjun Kuang)
#
# See ../../../../LICENSE for clarification regarding multiple authors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy... |
033c22d496349fae109b2cb58d57e8a63e8e6823 | abb220936a91946738c67c5310fe98d2e450f913 | /0x04-python-more_data_structures/11-multiply_list_map.py | 5a01a9d9c8bc5889e7e3faf3f2a140b830802c54 | [] | no_license | JavaPhish/holbertonschool-higher_level_programming | aeaea93836238a240247a765cb3581db3e2cdc2e | 21ced28281b9fb73cc158c494314b4e338472f38 | refs/heads/master | 2022-12-18T17:55:26.828425 | 2020-09-24T15:15:39 | 2020-09-24T15:15:39 | 207,327,823 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 118 | py | 11-multiply_list_map.py | #!/usr/bin/python3
def mutiply_list_map(my_list=[], number=0):
return list(map(lambda x: x * number, my_list))
|
29d767ba1bbcde38e6b6b425a9e6740983889c75 | 3fb120e47b76f0bc4d63e2e0dbaf040b9e7852d2 | /reddit.py | fbc805ae95357ebf3b58144214cda800374d33ff | [] | no_license | alex-wey/OVPR-ML | a8995aa4346eb7188657a76d93672c18e433edc3 | 623e310793cac3d0499dba96e5724b3b0780f771 | refs/heads/main | 2023-04-23T23:21:47.154880 | 2021-05-12T16:01:23 | 2021-05-12T16:01:23 | 366,555,253 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 8,756 | py | reddit.py | import argparse
import os
import random
import pandas as pd
import nltk
import csv
import string
import math
import re
from datetime import datetime
from sklearn.feature_extraction.text import TfidfVectorizer
from nltk.corpus import stopwords
from annotations import preprocess
stopwords = stopwords.words("english")
... |
de56e8e3a5514f5f24fc5ed5d8a586be62fb4f34 | 2ada0e17c3db5bddecf29df3535c19a798c05f94 | /Weather_api/config_keys.py | 8ba72f878520462e61e71d023269d4dc3bfc4b5e | [] | no_license | JosiahR89/PythonAPI-Challenge | 34385244809691806be27be912f7ac432e21af02 | 7c758508dd3cc8bb155f6f3398eca7d074b71261 | refs/heads/main | 2023-05-29T17:39:41.413246 | 2021-06-24T03:09:25 | 2021-06-24T03:09:25 | 378,768,982 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 207 | py | config_keys.py | #place all API keys here with different names
from requests import api
omdb_key = "cf723643" #OMDB
weather_key = "b97468fbe70ad9deb27cb5f203b90f4f" #Weather
gkey = "AIzaSyBI1wK4n0vuqudV400attd9ZyV11hvkqu4" |
c6809e4c0dfd7aecb5a4316ecf2adc4e0baf2e9a | ca9570c442f29fd26f6c4459c684cf55a3f89456 | /test/test_medimg.py | ee65064ddf882abfbb3dcdc81112d1a56a8c0861 | [
"MIT"
] | permissive | cni/nimsdata | 8f2403caa3db60d71c02cac16c86dfdd84af795c | 2f3e7b545de8e913da7eaa0f6b78f9355c8925df | refs/heads/master | 2021-06-06T09:36:52.436825 | 2021-05-11T18:01:16 | 2021-05-11T18:01:16 | 31,079,699 | 2 | 1 | MIT | 2021-05-10T17:06:15 | 2015-02-20T18:59:57 | Python | UTF-8 | Python | false | false | 2,057 | py | test_medimg.py | # @Author: Kevin S Hahn
"""Test nimsdata package."""
import os
import glob
import datetime
import numpy as np
from nose.plugins.attrib import attr
from numpy.testing.decorators import skipif
from nose.tools import ok_, eq_, raises, assert_raises
import nimsdata.medimg
import nimsdata.tempdir as tempfile
# data is ... |
e8ad81b14118013426f15d7c872e136e4f5ca4db | 189e06b20700cb52e735e0148c66982a10bd550f | /July/Week2/Find Peak Element.py | 1f0c18abb9ba085fdc352e6a778e8531f7ef7352 | [
"MIT"
] | permissive | vinaykumar7686/Leetcode-Monthly_Challenges | a7f63613f97b2eb80f416a7e1ac794a0faf6af1e | fe1928d8b10a63d7aa561118a70eeaec2f3a2f36 | refs/heads/master | 2023-06-15T14:49:43.930460 | 2021-07-14T14:12:52 | 2021-07-14T14:12:52 | 284,466,932 | 0 | 0 | MIT | 2021-03-04T17:13:24 | 2020-08-02T13:27:54 | Python | UTF-8 | Python | false | false | 1,038 | py | Find Peak Element.py | # Find Peak Element
'''
A peak element is an element that is strictly greater than its neighbors.
Given an integer array nums, find a peak element, and return its index. If the array contains multiple peaks, return the index to any of the peaks.
You may imagine that nums[-1] = nums[n] = -∞.
You must write an algor... |
3711869dcf2333266c1b006df262e0acf624b65e | 03fc1129f411efc9b79024488bcf98769fe04e23 | /rplugin/python3/denite/modules/finders/app_finder.py | ede05b6e9efe43e1c0d126d5c5a9700484606855 | [
"MIT"
] | permissive | sakuma/denite-rails | 06fa1f907698b62f6a65f9264265c23c952b9152 | 0029de49b10496ba647e28f66416faab55128081 | refs/heads/master | 2020-03-15T03:46:22.773112 | 2018-09-09T18:48:59 | 2018-09-09T18:48:59 | 131,950,597 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 459 | py | app_finder.py | import os
import finder_utils
from app_file import AppFile
class AppFinder:
GLOB_PATTERN = 'app/**/*'
def __init__(self, context):
self.context = context
self.root_path = context['__root_path']
def find_files(self):
files = finder_utils.glob_project(self.root_path, self.GLOB_PATT... |
912fa8b95d546a98ca66182580bd2ce42fa1655a | 4cbfbd2964df8df1ebaf4b92fb788856ae26bf63 | /cnn_cvd_disease.py | d7836b1906e1e046c47d16a9f72f77ad3f5674fc | [] | no_license | gchetty/cvd | dff9a8313475bafbcbf4847305e13d90cf7a700e | a8de5daf49716f5c7e36eb443d40972e9d142b7c | refs/heads/main | 2023-08-23T13:32:19.353614 | 2021-10-27T03:55:11 | 2021-10-27T03:55:11 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 26,265 | py | cnn_cvd_disease.py | # -*- coding: utf-8 -*-
"""CNN_CVD_Disease.ipynb
Automatically generated by Colaboratory.
# CNN using CVD disease data
This work is aiming at the design and testing of a deep neural network architecture on CVD disease using Tensorflow and Keras.
## Importing libraries
"""
from google.colab import dri... |
c5b2b9f315157baff8b1f237c052078ab5e5afce | c00ad7b7ea1afab8fd64cd518299e17c218c2907 | /server/server.py | 840539cceedcac6f224089ce50e97081f6b6d970 | [] | no_license | yoni1306/hackIDC18 | b767245dd39a01cd4e8af9baed57bca4f227e90f | 312ae3b98eff8caeef672316473d186394cad9a8 | refs/heads/master | 2020-03-13T12:47:33.082811 | 2018-04-26T14:17:50 | 2018-04-26T14:17:50 | 131,126,492 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 3,174 | py | server.py | import tornado.ioloop
import tornado.web
import json
import pymongo
import logging
import sys
from geopy.distance import geodesic
from pymongo import MongoClient
import time
root = logging.getLogger()
root.setLevel(logging.DEBUG)
ch = logging.StreamHandler(sys.stdout)
ch.setLevel(logging.DEBUG)
formatter = logging.For... |
7c52d4006553d7694b30374811f83c356bb9e8d7 | a7ba1b845cb3679c5a2e9e0bc37624e8d4c31a3f | /api/vk_cache.py | 3dba14917b3f67e167b5e2c80a08bf632f379acb | [
"MIT"
] | permissive | fumyk/cat | acbfeef9f93d807cfa81cfed4c4545ad057352b2 | e8a05427a4f646cdee06a7d0f6c4a84d6c316275 | refs/heads/master | 2022-02-22T19:48:37.638780 | 2018-06-01T11:44:58 | 2018-06-01T11:44:58 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 325 | py | vk_cache.py | import api.vk as vk
class Users:
def __init__(self):
self.cache = {}
def get(self, user_id, fields=None):
if user_id in self.cache:
return self.cache[user_id]
else:
data = vk.users_get(user_id, fields)
self.cache[user_id] = data
return ... |
272561e9a1df3e144677541482c90f46c39fcd36 | 88089db5d25f850b3ee9ce6eff2fc357a3b8049b | /localization/english/generate_goods_tooltips.py | 1d6535bedea36acc447967a872151bb4347198f4 | [] | no_license | krushka5/imp19c | 65ca32d7f20c414cf4120566e43aee3b51fbdc17 | 804d86e1deb3fbc4b6483fdbb9918db9a51d0f34 | refs/heads/master | 2023-03-16T00:39:12.264137 | 2022-11-01T13:22:59 | 2022-11-01T13:22:59 | 235,019,479 | 0 | 0 | null | 2020-01-26T14:34:30 | 2020-01-20T04:35:24 | Python | UTF-8 | Python | false | false | 1,285 | py | generate_goods_tooltips.py | def print_out_good(goods_name):
caps_name = goods_name.upper()
lowercase_name = goods_name.lower()
initial_cap_name = goods_name.capitalize()
loc = """PROVWINDOW_GOV_{caps_name}_STOCKPILE:0 "[GuiScope.SetRoot(ProvinceWindow.GetState.GetGovernorship.MakeScope).ScriptValue('GOODS_{lowercase_name}_stockpile')|0]"
... |
09017b123397339b73940e63b02d7fcac0da9348 | 8b18a49f0be0d3bc2ac1d7142878aa76852cd4b6 | /20171114/20171114_2.py | 06e72b7be08516769e0c09a08ffd32aa210e1132 | [] | no_license | SDRLurker/starbucks | 10ff8fd52f240a8b20447931e4928c759ded872e | 680526f7cdfbaa58f027f9325bf0d814f0373377 | refs/heads/master | 2021-01-23T21:36:01.582516 | 2020-12-31T05:48:08 | 2020-12-31T05:48:08 | 57,950,539 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,714 | py | 20171114_2.py | # Definition for a binary tree node.
class TreeNode(object):
def __init__(self, x):
self.val = x
self.left = None
self.right = None
class Solution(object):
def binaryTreePaths(self, root):
self.routes = []
if root:
a = [0 for _ in range(1000)]
a[0... |
d126c75e6e74f379e52c87b27899af6573598568 | 717eff82959249a31546595a1d6d9cddfeedc4cd | /spider_main.py | 592273eca56bba0c32264c652683a4ee75aff009 | [] | no_license | StormWyrm/BaikeSpider | 56b059e655deb03b6543b4c17f3f903c3f86e5dc | 8310c77661fb545f1530c783d21f8349c73d8518 | refs/heads/master | 2020-03-09T04:29:59.094349 | 2018-04-08T02:38:52 | 2018-04-08T02:38:52 | 128,589,341 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,106 | py | spider_main.py | import url_manager
import url_downloader
import url_outputer
import url_parser
class SpiderMain(object):
def __init__(self):
self.url_manager = url_manager.UrlManager()
self.url_downlader = url_downloader.UrlDownlader()
self.url_parser = url_parser.UrlParser()
self.url_outputer = ... |
7377941767eea834d5257d77c3312f04eb362291 | 2f700a61ccb2e005ad086ce734da378b160cb854 | /unit_examples/linkedlist.py | 426e24938f812329dac10e117e746bba56a3f6c8 | [] | no_license | ren100700/ren | 1d8becea61b965470ba7a505e5028e79263a19f2 | d95b2146f289a7f1b98af2fee587b898160e369d | refs/heads/master | 2020-03-29T19:27:40.212624 | 2018-11-26T13:02:08 | 2018-11-26T13:02:08 | 150,264,341 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,791 | py | linkedlist.py | class Stack:
def __init__(self, max_size):
self.max_size = max_size
self.top = None
def push(self, item):
if self.size() != self.max_size:
node = Node(item)
node.next_node = self.top
self.top = node
def pop(self):
if self.top is None:
... |
7be5458ad7f3ff5119520888ce2a86254793304c | 73a4c2807978926ca9f72e92c11916ce1baf6fd3 | /tests/test_stables.py | 0fcdc633bcfedf16cdb401141ba134ee56be74dc | [] | no_license | JoshCLWren/TNM | a6c28bdb87b57c22902697754d7f33a4f8cfa5f1 | 341cbf6d9269e6cce47804075ee5caaddd021d2b | refs/heads/main | 2023-07-26T23:15:44.848912 | 2021-08-28T22:20:57 | 2021-08-28T22:20:57 | 393,585,913 | 0 | 0 | null | 2021-08-28T22:20:58 | 2021-08-07T05:13:34 | Python | UTF-8 | Python | false | false | 575 | py | test_stables.py | import pytest
import circuits
import wrestlers
import stables
from database import cursor, con
import seed_db
def test_stable_serializer():
"""Tests Dropping and rebuilding stables table"""
fake = seed_db.fake_stable()
nwo = [{}]
nwo[0]["Stable Name"] = fake["name"]
nwo[0]["ids"] = fake["member... |
09ba00fc02ced19fdfe0d9e3cb90081be2e39a7a | cbcdf195338307b0c9756549a9bffebf3890a657 | /django-stubs/contrib/contenttypes/management/commands/remove_stale_contenttypes.pyi | 3d5c5fecde5aafbb580b44ffbf78ff8c2ad73571 | [
"MIT"
] | permissive | mattbasta/django-stubs | bc482edf5c6cdf33b85005c2638484049c52851b | 8978ad471f2cec0aa74256fe491e2e07887f1006 | refs/heads/master | 2020-04-27T08:38:22.694104 | 2019-03-06T09:05:08 | 2019-03-06T09:05:24 | 174,178,933 | 1 | 0 | MIT | 2019-03-06T16:18:01 | 2019-03-06T16:18:00 | null | UTF-8 | Python | false | false | 790 | pyi | remove_stale_contenttypes.pyi | from typing import Any, Optional
from django.core.management import BaseCommand
from django.core.management.base import CommandParser
from django.db.models.deletion import Collector
from ...management import get_contenttypes_and_models
class Command(BaseCommand):
stderr: django.core.management.base.OutputWrapper... |