blob_id stringlengths 40 40 | directory_id stringlengths 40 40 | path stringlengths 3 288 | content_id stringlengths 40 40 | detected_licenses listlengths 0 112 | license_type stringclasses 2
values | repo_name stringlengths 5 115 | snapshot_id stringlengths 40 40 | revision_id stringlengths 40 40 | branch_name stringclasses 684
values | visit_date timestamp[us]date 2015-08-06 10:31:46 2023-09-06 10:44:38 | revision_date timestamp[us]date 1970-01-01 02:38:32 2037-05-03 13:00:00 | committer_date timestamp[us]date 1970-01-01 02:38:32 2023-09-06 01:08:06 | github_id int64 4.92k 681M ⌀ | star_events_count int64 0 209k | fork_events_count int64 0 110k | gha_license_id stringclasses 22
values | gha_event_created_at timestamp[us]date 2012-06-04 01:52:49 2023-09-14 21:59:50 ⌀ | gha_created_at timestamp[us]date 2008-05-22 07:58:19 2023-08-21 12:35:19 ⌀ | gha_language stringclasses 147
values | src_encoding stringclasses 25
values | language stringclasses 1
value | is_vendor bool 2
classes | is_generated bool 2
classes | length_bytes int64 128 12.7k | extension stringclasses 142
values | content stringlengths 128 8.19k | authors listlengths 1 1 | author_id stringlengths 1 132 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
4fd9bed4328f8591ad62960574eed263df888ec7 | f618cb7a1b1f49c02396a2bb969cc7518fd163ab | /doc/_gallery/1_3_1_noisy_chirp_wv.py | ba10a534a72d30bbb4a32f5780d048b7422177fb | [] | no_license | kingjr/pytftb | b968b8e2fc294a19cec8bf63e7d289f368ddf194 | 0bcacf5eef46bd173d90a23c00a7f4b8ee284b22 | refs/heads/master | 2021-01-16T22:27:05.587174 | 2015-06-25T05:16:02 | 2015-06-25T05:16:02 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 572 | py | #! /usr/bin/env python
# -*- coding: utf-8 -*-
# vim:fenc=utf-8
#
# Copyright © 2015 jaidev <jaidev@newton>
#
# Distributed under terms of the MIT license.
"""
"""
from tftb.generators import fmlin, sigmerge, noisecg
from tftb.processing.cohen import WignerVilleDistribution
# Generate a chirp signal
n_points = 128... | [
"deshpande.jaidev@gmail.com"
] | deshpande.jaidev@gmail.com |
2f60ba606f3f3ff16f6ce61b7441c7944a9a3939 | 15f365dc711f2230073391687642498305286321 | /Figure plotting/FIG_3.9c)_maximal allowable radial offset.py | d3495aa3b0b50f74b8be071296dbfa7a96ad2f13 | [] | no_license | Isabelliuqin/Optical_Levitation_Master_project_final | 16d177ee0852361745286d4a5af8eea84aad5845 | 0ebe133a08a84e3c8521b06c6e9eec2584e0b3cc | refs/heads/master | 2023-01-03T13:35:05.753240 | 2020-11-01T10:13:59 | 2020-11-01T10:13:59 | 309,067,970 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,693 | py | # -*- coding: utf-8 -*-
"""
Created on Sun Nov 1 16:31:57 2020
@author: liuqi
"""
import scipy as sp
import numpy as np
from mpl_toolkits.mplot3d import axes3d
import matplotlib.pylab as plt
import scipy.integrate as spi
from scipy.integrate import quad
import seaborn
from scipy.integrate import odei... | [
"qin.liu16@imperial.ac.uk"
] | qin.liu16@imperial.ac.uk |
a0558eff96171575b90ef92a7b59d2a7abd7f87f | f07a42f652f46106dee4749277d41c302e2b7406 | /Data Set/bug-fixing-5/a8ab1a0b200881f52f564d28db90f10730c1f0b5-<latest>-fix.py | 34987d8922650e14b77fd72b4e1557dd3181ede0 | [] | no_license | wsgan001/PyFPattern | e0fe06341cc5d51b3ad0fe29b84098d140ed54d1 | cc347e32745f99c0cd95e79a18ddacc4574d7faa | refs/heads/main | 2023-08-25T23:48:26.112133 | 2021-10-23T14:11:22 | 2021-10-23T14:11:22 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,811 | py | def latest(module, items, repoq, yum_basecmd, conf_file, en_repos, dis_repos, update_only, installroot='/'):
res = {
}
res['results'] = []
res['msg'] = ''
res['changed'] = False
res['rc'] = 0
pkgs = {
}
pkgs['update'] = []
pkgs['install'] = []
updates = {
... | [
"dg1732004@smail.nju.edu.cn"
] | dg1732004@smail.nju.edu.cn |
a8cf597841bdc78c1f56b1e0b73d9efdcca7b554 | c55bca491632ef98dfd0e39e9e197f86d4ce94f0 | /wcoa/migrations/0019_auto_20200922_1837.py | 6a1b7fb208ec5b9d7b5906ffb04ffb52f40aa3af | [
"MIT"
] | permissive | Ecotrust/wcoa | 420b2e9f03219a72f79e435c1001b87a76233a8b | f6ad1e42fa93560d57043ebeb8464a320befef14 | refs/heads/main | 2023-08-03T21:02:01.013970 | 2023-07-28T22:56:03 | 2023-07-28T22:56:03 | 196,878,615 | 1 | 1 | MIT | 2021-12-09T19:29:37 | 2019-07-14T20:07:39 | Python | UTF-8 | Python | false | false | 395 | py | # Generated by Django 2.2.9 on 2020-09-22 18:37
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('wcoa', '0018_delete_masonrypage'),
]
operations = [
migrations.AlterField(
model_name='catalogiframepage',
name='sou... | [
"ryan.d.hodges@gmail.com"
] | ryan.d.hodges@gmail.com |
cd9815be7c9cc8ccdc4c8d46f182389f7124895a | 0f6581b105ea7eb4b99dbff131378340a634e7ac | /pages/select_mall_page.py | a47f0ce03ea8ce69435593430a96ed74a92a928e | [] | no_license | langdawang678/Se2PO | ded5e9f97a329f39a6de8ffaebe92330eb598eff | 96d7eb6b4e1774b06b2fd9a4781f9bee7d8f5ed6 | refs/heads/master | 2023-03-25T10:44:23.140843 | 2021-03-23T09:41:39 | 2021-03-23T09:41:39 | 346,628,227 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 526 | py | from selenium.webdriver.support.wait import WebDriverWait
from selenium.webdriver.support import expected_conditions as EC
from locations.goods_lib_locations import GoodsLibLocations
from common.base_page import BasePage
class SelectMallPage(BasePage):
# 退出元素是否存在
def get_elements_exists(self):
try:
... | [
"langdawang678@sina.com"
] | langdawang678@sina.com |
3ed16fe01640223215e8ecb9dd68102306c1c59b | 592498a0e22897dcc460c165b4c330b94808b714 | /1000번/1406_에디터.py | a89e92eec4a01dc869414b5d997fc614f0d9d6f9 | [] | no_license | atom015/py_boj | abb3850469b39d0004f996e04aa7aa449b71b1d6 | 42b737c7c9d7ec59d8abedf2918e4ab4c86cb01d | refs/heads/master | 2022-12-18T08:14:51.277802 | 2020-09-24T15:44:52 | 2020-09-24T15:44:52 | 179,933,927 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 469 | py | from collections import deque
import sys
ip = sys.stdin.readline
lst = deque(list(ip().strip()))
rst = deque([])
for i in range(int(ip())):
cmd = ip().strip()
if cmd[0] == 'L':
if len(lst):
rst.appendleft(lst.pop())
elif cmd[0] == 'D':
if len(rst):
lst.append(rst.popl... | [
"zeezlelove@gmail.com"
] | zeezlelove@gmail.com |
e1b448acf3b730cb600a2828622a2b86bc3e47d9 | c9f4de7bf63df23325b477d3375a1bfb99865059 | /main_a3.py | 2a0057fd589f5aa522859a2167872c1f9d5d7b8e | [] | no_license | EliHill/TextAnalysis | 440a15dca3f467ab5d79a234582a9ca3b4c7ab10 | 44b05bd1995290bbbd7972a1f8953aa5e75be37e | refs/heads/master | 2020-09-30T16:24:18.911419 | 2019-12-06T19:52:17 | 2019-12-06T19:52:17 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,750 | py | """main_a3.py
"""
import re
import os
import math
import nltk
from nltk.corpus import brown
from nltk.corpus import wordnet as wn
from nltk.corpus import PlaintextCorpusReader
from fsa import FSA
# NLTK stoplist with 3136 words (multilingual)
STOPLIST = set(nltk.corpus.stopwords.words())
# Vocabulary with 234,3... | [
"marc@cs.brandeis.edu"
] | marc@cs.brandeis.edu |
e0cca15b4698cfcef55c59c32ad1ec019b327f0b | b576ed1ff65700d505f687961cbed86fe94b1c3f | /objectModel/Python/cdm/utilities/copy_data_utils.py | 52fd4d1ee5390f942bbde1ef66b2b5cca9e4104f | [
"MIT",
"CC-BY-4.0"
] | permissive | AzureMentor/CDM | c80761737c92cf6561d4b982b4882b1b1c5265d3 | 84d3928995e7ab3bba0a283771e5e26639408643 | refs/heads/master | 2021-11-30T17:52:42.274900 | 2021-11-27T18:38:19 | 2021-11-27T18:38:19 | 217,569,642 | 1 | 0 | NOASSERTION | 2021-11-27T18:38:20 | 2019-10-25T16:04:16 | Java | UTF-8 | Python | false | false | 870 | py | # Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for license information
from typing import Union, List, Optional, TYPE_CHECKING
if TYPE_CHECKING:
from cdm.objectmodel import CdmCollection, CdmObject
from cdm.utilities import Res... | [
"nebanfic@microsoft.com"
] | nebanfic@microsoft.com |
7ff960b1f5fe2ab8db39e70e382084c495881cb8 | 1b12e6096c47312b67fa6ff223216945d2efb70c | /sandbox/vtk/selection/myinteractor.py | 139202e49f1fe0d1418bde34dcae5a42beb929c2 | [
"Apache-2.0"
] | permissive | rboman/progs | 6e3535bc40f78d692f1f63b1a43193deb60d8d24 | 03eea35771e37d4b3111502c002e74014ec65dc3 | refs/heads/master | 2023-09-02T17:12:18.272518 | 2023-08-31T15:40:04 | 2023-08-31T15:40:04 | 32,989,349 | 5 | 2 | Apache-2.0 | 2022-06-22T10:58:38 | 2015-03-27T14:04:01 | MATLAB | UTF-8 | Python | false | false | 4,329 | py | # -*- coding: utf-8 -*-
import vtk
colors = vtk.vtkNamedColors()
class MyInteractorStyle(vtk.vtkInteractorStyleTrackballCamera):
def __init__(self, parent=None):
"""register to event listening
"""
self.AddObserver("LeftButtonPressEvent", self.leftButtonPressEvent)
self.selection... | [
"romain.boman@gmail.com"
] | romain.boman@gmail.com |
bf2df9013b94ee7ca80c35660b101bf47f905569 | bd4f8320118c4fb25b95d29193c1adb2f5b55ec6 | /contrib/userproperty_lint.py | 7d99b16806929b36131ad944ccb545cac48d4c45 | [
"Apache-2.0"
] | permissive | Khan/khan-linter | 30229d57ec82466af54b539eb3a57770335e0d65 | 9222e8f8c9aa6dead5c434d1eb7bb326207ed989 | refs/heads/master | 2023-07-21T05:06:19.757797 | 2022-07-11T16:54:42 | 2022-07-11T16:54:42 | 4,628,579 | 26 | 8 | Apache-2.0 | 2023-09-06T21:29:52 | 2012-06-11T18:29:03 | Python | UTF-8 | Python | false | false | 1,639 | py | """Linter that warns about using the dangerous UserProperty.
UserProperty's user_id value can change depending on whether or not Google
currently has a Google account registered w/ an email address that matches
UserProperty's email property. That means when a user changes email settings
in their Google account it can ... | [
"csilvers@khanacademy.org"
] | csilvers@khanacademy.org |
95b5c45037161cace8ce3128cfd2bf49dc2bb7b6 | fc6eefb980b53baae393980c46ac40d256687014 | /Udacity-Intro-To-Computer-Science/Lesson 1/Lesson 1 - Quizzes/Final Quiz.py | 8aa9f447ce3f3fde860303b34c61711a69cb1cb7 | [] | no_license | Brian-Mascitello/UCB-Third-Party-Classes | 7bc151d348f753f93850f5e286c263639f782b05 | e2d26e3d207d364462024759ad2342a8e172f657 | refs/heads/master | 2021-01-02T09:10:01.146169 | 2018-10-08T00:19:58 | 2018-10-08T00:19:58 | 99,150,324 | 0 | 0 | null | 2018-02-01T06:33:25 | 2017-08-02T18:47:29 | Python | UTF-8 | Python | false | false | 780 | py | # Write Python code that assigns to the
# variable url a string that is the value
# of the first URL that appears in a link
# tag in the string page.
# Your code should print http://udacity.com
# Make sure that if page were changed to
# page = '<a href="http://udacity.com">Hello world</a>'
# that your code still assi... | [
"bmascitello@gmail.com"
] | bmascitello@gmail.com |
2c6de1d98469164b77e496a0c33bfd4a67f22e17 | 1f5420fda4359bfc21b53de3a5f6e6a93b47b996 | /ch02/ch02_menu.py | 5abfa489c2386f900a6c3f914341bd20f4c6a22b | [] | no_license | fl0wjacky/wxPython | 600f5bfccad3ef5589e11573b30cffd1e2708b83 | 50b3cd5a63750d36065684b73aab0da70ff650a7 | refs/heads/master | 2022-09-02T04:24:47.540157 | 2022-08-10T04:13:17 | 2022-08-10T04:13:17 | 13,976,582 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,071 | py | #! /usr/bin/env python
import wx
import wx.py.images as images
class ToolbarFrame(wx.Frame):
def __init__(self, parent, id):
wx.Frame.__init__(self, parent, id, 'Toolbars', size=(300,200))
panel = wx.Panel(self)
panel.SetBackgroundColour('White')
statusBar = self.CreateStatusBar()#... | [
"flowjacky@gmail.com"
] | flowjacky@gmail.com |
9e28e0cd12e58048913b3c3764cd180e05af5636 | 9e41adf86b2c166a219f0b6d9371089c5f2d7d93 | /Exerciciospython2/Função/e100.py | 0b47e1bb8952e250e0f02facf33b98bfe7653f2f | [] | no_license | Nadirlene/Exercicios-python | 1aaead61dd0efcb5303f6294e765e9e1d54506cc | 3fe82e166003922ef749756a249840ed1fe940b0 | refs/heads/main | 2022-12-25T21:35:06.172839 | 2020-09-28T15:08:37 | 2020-09-28T15:08:37 | 299,343,047 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 514 | py | from random import randint
from time import sleep
númerosSorteados = []
def sorteio(lista):
print(f'Sorteando {len(lista)} valores da lista:', end=' ')
for c in range(0, 5):
lista.append(randint(1, 10))
print(lista[c], end=' ')
sleep(0.3)
print('PRONTO!')
def somaPar(lista):
so... | [
"nadirleneoliveira@yahoo.com"
] | nadirleneoliveira@yahoo.com |
b21ef021ca3d6afdf535882ef61eb49b75bf895c | 8b7db851e13737d5c44cc00d38a46a2817c7707b | /tests/train.py | 788e79cd09e75082a8dc8cf4d75b3dd063b824b5 | [
"MIT"
] | permissive | goelshivam1210/gym-novel-gridworlds | b6f24b38cfceb2b44461da9bb7607c56d27f4a9e | c8f419da02e4fd716b9e293fcf0b99ee2eb96367 | refs/heads/master | 2023-01-15T13:46:23.438199 | 2020-11-23T14:42:13 | 2020-11-23T14:42:13 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,349 | py | import os
import time
import gym
import gym_novel_gridworlds
import numpy as np
from stable_baselines.common.env_checker import check_env
from stable_baselines import PPO2
from stable_baselines import DQN
from stable_baselines.gail import ExpertDataset
from stable_baselines.common.policies import MlpPolicy
from st... | [
"gtatiya@live.com"
] | gtatiya@live.com |
e0bd0c8393e10d70cd1d7736fc15a898d1f059dc | 2e858717fbc3b74cc809dc5d60d337a844ae7fed | /codegolf/planets.py | a4f5b0a908013fcda517843121fbb9b541e6773d | [] | no_license | maxbergmark/misc-scripts | 95a1b5416c34e65b7e8ef26f5c941f9ba0ae0986 | a1b3b889f8f6d28a452969a62af637a6866b69d3 | refs/heads/master | 2020-03-28T10:32:38.362737 | 2019-09-20T12:23:14 | 2019-09-20T12:23:14 | 148,118,739 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,108 | py |
def get_score(l, s):
c = 0
for i, e in enumerate(l):
c += int(e == s[i])
return c
def check_modulo(l, n):
mod = [i%n for i in l]
s = list(set(mod))
if len(s) == len(l):
return 1, get_score(sorted(s), s)
return 0, 0
def check_modulo_sq(l, n):
mod = [(i*i)%n for i in l]
s = list(set(mod))
if len(s) == le... | [
"max.bergmark@gmail.com"
] | max.bergmark@gmail.com |
b20eb31e621b6af9cf0b1d9291f57832e0b170b2 | e00186e71a1f52b394315a0cbc27162254cfffb9 | /durga/without_rest_models/testapp/models.py | 6cac7e2e06e3e0b26b958a2b5e56c8110c3d2e6b | [] | no_license | anilkumar0470/git_practice | cf132eb7970c40d0d032520d43e6d4a1aca90742 | 588e7f654f158e974f9893e5018d3367a0d88eeb | refs/heads/master | 2023-04-27T04:50:14.688534 | 2023-04-22T05:54:21 | 2023-04-22T05:54:21 | 100,364,712 | 0 | 1 | null | 2021-12-08T19:44:58 | 2017-08-15T10:02:33 | Python | UTF-8 | Python | false | false | 240 | py | from django.db import models
# Create your models here
class Employee(models.Model):
eno = models.IntegerField()
ename = models.CharField(max_length=64)
esal = models.FloatField()
eadd = models.CharField(max_length=64)
| [
"anilkumar.0466@gmail.com"
] | anilkumar.0466@gmail.com |
3a32e88f924763cebc773b157f5ade3bbf566316 | f0d713996eb095bcdc701f3fab0a8110b8541cbb | /9BJzrtpdMP8JFQg74_5.py | 54241e25ddb6e70ccec2ec15821dcacf5ef26e29 | [] | no_license | daniel-reich/turbo-robot | feda6c0523bb83ab8954b6d06302bfec5b16ebdf | a7a25c63097674c0a81675eed7e6b763785f1c41 | refs/heads/main | 2023-03-26T01:55:14.210264 | 2021-03-23T16:08:01 | 2021-03-23T16:08:01 | 350,773,815 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 652 | py | """
Create a function that given a list, it returns the index where if split in
two-subarrays (last element of the first array has index of (foundIndex-1)),
the sum of them are equal.
### Examples
twins([10, 20, 30, 5, 40, 50, 40, 15]) ➞ 5
# foundIndex 5 : [10+20+30+5+40]=[50+40+15]
twins([1, 2, 3... | [
"daniel.reich@danielreichs-MacBook-Pro.local"
] | daniel.reich@danielreichs-MacBook-Pro.local |
b9c2ab2a145c713904bc1750e4837b1d3b4cc7d7 | bbfa3b7ee2008617d33a7c5c7770d22e1aa8836b | /Neural_Network/_base.py | 4297021e909f92cc59ba0f6ba4d9070986e15fba | [
"MIT"
] | permissive | luoshao23/ML_algorithm | 1a0046ce9c3abed029cceffa35defe57fffa82b2 | 6e94fdd0718cd892118fd036c7c5851cf3e6d796 | refs/heads/master | 2021-08-07T08:38:16.102455 | 2020-03-18T06:49:43 | 2020-03-18T06:49:43 | 92,467,636 | 4 | 1 | MIT | 2018-01-16T05:01:29 | 2017-05-26T03:20:08 | Jupyter Notebook | UTF-8 | Python | false | false | 1,611 | py | from scipy.special import expit as logistic_sigmoid
import numpy as np
def identity(X):
return X
def logistic(X):
return logistic_sigmoid(X, out=X)
def tanh(X):
return np.tanh(X, out=X)
def relu(X):
return np.clip(X, 0, np.finfo(X.dtype).max, out=X)
def softmax(X):
tmp = X - X.max(axis=1)[... | [
"luoshao23@gmail.com"
] | luoshao23@gmail.com |
1d11db0aa1ed010ab524edc4b7847c5ce929f009 | 53fab060fa262e5d5026e0807d93c75fb81e67b9 | /backup/user_089/ch78_2020_04_13_14_24_17_375788.py | f3ffd533ba171b545632219f377a3046205a82d8 | [] | no_license | gabriellaec/desoft-analise-exercicios | b77c6999424c5ce7e44086a12589a0ad43d6adca | 01940ab0897aa6005764fc220b900e4d6161d36b | refs/heads/main | 2023-01-31T17:19:42.050628 | 2020-12-16T05:21:31 | 2020-12-16T05:21:31 | 306,735,108 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 429 | py | jogo = True
import math
while jogo:
a = input("Qual o nome?")
if a == "sair":
jogo = False
else:
b = float(input("Aceleracao?"))
dic = {a:b}
dic2 = {}
soma = 0
for e in dic:
if e not int dic2:
dic2[e] = math.sqrt(200/dic[e])
if dic2[e] > soma:
... | [
"you@example.com"
] | you@example.com |
f2016ead70d10ced68bab597dac0c22bfd28423e | d7641647d67d110e08997767e85bbea081c2537b | /bitmovin_api_sdk/encoding/inputs/udp_multicast/udp_multicast_api.py | 59839e170880781ece7571d5ff6cbc19d6ee3393 | [
"MIT"
] | permissive | aachenmax/bitmovin-api-sdk-python | d3ded77c459852cbea4927ff28c2a4ad39e6026a | 931bcd8c4695a7eb224a7f4aa5a189ba2430e639 | refs/heads/master | 2022-11-16T08:59:06.830567 | 2020-07-06T07:16:51 | 2020-07-06T07:16:51 | 267,538,689 | 0 | 1 | MIT | 2020-07-06T07:16:52 | 2020-05-28T08:44:44 | Python | UTF-8 | Python | false | false | 3,377 | py | # coding: utf-8
from __future__ import absolute_import
from bitmovin_api_sdk.common import BaseApi, BitmovinApiLoggerBase
from bitmovin_api_sdk.common.poscheck import poscheck_except
from bitmovin_api_sdk.models.response_envelope import ResponseEnvelope
from bitmovin_api_sdk.models.response_error import ResponseError... | [
"openapi@bitmovin.com"
] | openapi@bitmovin.com |
e5edc21a34b45ca67e7abb9b03ee9215880f212d | c440bcb0e566ed107d198593bfeb482c59276dd8 | /advent_of_code/2021/day10_1.py | 2d34868acd58b3462cc9f7332e432aea3f23b3a6 | [] | no_license | TheCDC/Musings | 1ee917bbf2fd39f6fa97b268568053ca6ad7fbbf | 7b07e315230248239bbccad5d85d0a5e8a54d5d8 | refs/heads/master | 2022-11-30T23:37:24.608955 | 2021-12-19T08:12:03 | 2021-12-19T08:12:03 | 175,046,297 | 0 | 0 | null | 2022-11-22T07:20:49 | 2019-03-11T17:01:54 | Python | UTF-8 | Python | false | false | 1,751 | py | from typing import List, Optional, Tuple
with open("inputs/day10.txt") as f:
lines = f.read().split()
openers = "([{<"
closers = ")]}>"
points_corruption = {")": 3, "]": 57, "}": 1197, ">": 25137}
def complete(opens: List[str]):
to_complete = opens[:]
completion: List[str] = []
while to_complete:
... | [
"christopher.chen1995@gmail.com"
] | christopher.chen1995@gmail.com |
4699041df8bc845885513fbf247fa04518328cbd | 14afcc5e2b8bdb3d91b500f6e7985d8a3378e929 | /src/68.文本左右对齐.py | b3689a9c97bc0475d281eab692c085002b906bbc | [] | no_license | hysapphire/leetcode-python | 8569a0e76f8917165e6b9fb25bfef1afc1186e3c | 8e338ee7a5c9f124e897491d6a1f4bcd1d1a6270 | refs/heads/master | 2022-12-03T15:17:52.557115 | 2020-08-17T14:19:59 | 2020-08-17T14:19:59 | 278,781,919 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,782 | py | #
# @lc app=leetcode.cn id=68 lang=python3
#
# [68] 文本左右对齐
#
# @lc code=start
class Solution:
def fullJustify(self, words: List[str], maxWidth: int) -> List[str]:
splited_words = []
s = []
cnt = 0
for word in words:
t = cnt + len(word)
if t > maxWidth:
... | [
"huoyang93@qq.com"
] | huoyang93@qq.com |
2850dbedb93f513dc0ee15666df35c5ff685c000 | 1302c48beae789b1b7837f34325a8f2b203d69df | /src/byro/bookkeeping/models/account.py | 866ae96ca5bbdf954ac3dddf73f44b8cdd0bb526 | [] | no_license | grince/byro | b9a8ad0d54b78ee220af6dedee119ab9ec0036df | abe8743c04ba828fdd5ff50c55c43a3b32bc26bd | refs/heads/master | 2021-01-25T12:31:12.461853 | 2018-02-26T17:42:12 | 2018-02-26T17:42:12 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,496 | py | from django.db import models
from django.db.models import Q
from django.utils.decorators import classproperty
from django.utils.timezone import now
from django.utils.translation import ugettext_lazy as _
from byro.common.models.auditable import Auditable
from byro.common.models.choices import Choices
class AccountCa... | [
"rixx@cutebit.de"
] | rixx@cutebit.de |
c8a176d73ce4de43a0c744f3ba4ba152b13f907d | 9c968f7cdf390f8417912519b53f1b7f6ea8b7e8 | /HJ_AL/brute_force/b1065_brute.py | 9f0cd478cfd5e6253c843f1b729ba4e7aabdc19b | [] | no_license | hhongjoon/TIL | aa33ce2973552a0baa0e0da5bd7d20824fd2e322 | a33b20af15d3f671ea7c7b2855291e50a9036c1c | refs/heads/master | 2021-08-07T17:33:39.722880 | 2020-04-25T08:11:02 | 2020-04-25T08:11:02 | 162,099,245 | 4 | 0 | null | 2019-10-30T09:06:21 | 2018-12-17T08:34:07 | Jupyter Notebook | UTF-8 | Python | false | false | 427 | py |
num = int(input())
count=0
for i in range(1,num+1):
if len(str(i)) == 1 or len(str(i))==2:
count += 1
continue
str_num=str(i)
judge = True
for j in range(0,len(str_num)-2):
if int(str_num[j]) - int(str_num[j+1]) == int(str_num[j+1]) - int(str_num[j+2]):
continue
... | [
"sungsung129@gmail.com"
] | sungsung129@gmail.com |
028660a24e92f54b0bc846a5d68b6e90ac21cddf | 41710e9133d660739f8f9f17040a2a8a6082e9fb | /python/aa_modules/fitsio_has_errors/eg2.py | d4a0e6e5e75796a2ec451845dfda65e7d12df200 | [] | no_license | hanjiangxue007/Programming | 591678150e2e300051fdeaf09124d3893076d3a9 | 7a545ef2300b004497f30d27d1f2aaa032e26af5 | refs/heads/master | 2020-06-29T18:50:27.776557 | 2016-10-27T18:31:39 | 2016-10-27T18:31:39 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,094 | py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# Author : Bhishan Poudel; Physics PhD Student, Ohio University
# Date : Oct-15-2016 Sat
# Last update :
#
#
# Imports
import fitsio
from fitsio import FITS,FITSHDR
# Often you just want to quickly read or write data without bothering to
# create a FITS objec... | [
"bhishantryphysics@gmail.com"
] | bhishantryphysics@gmail.com |
b65f91b5d0820bef879b4902b41d7a79e7fe245a | 33f304bbd8536045a63dea909031576ea3f7b488 | /census_area/core.py | c3fe06979410922dd4552eca320be2f8349c5c06 | [
"MIT"
] | permissive | LindaLv11/census_area | 859c92cd5ca6a8537ff45014b42771804dc29913 | 48d8bc7e73c12b58e796307e36c93029b1ec0044 | refs/heads/master | 2020-04-20T08:25:32.838867 | 2019-01-04T03:00:47 | 2019-01-04T03:00:47 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,436 | py | import shapely.geometry
import shapely.geos
import esridump
GEO_URLS = {
'tracts' : {
1990 : 'https://gis.uspatial.umn.edu/arcgis/rest/services/nhgis/Census_Tracts_1910_2014/MapServer/8',
2000 : 'https://tigerweb.geo.census.gov/arcgis/rest/services/Census2010/tigerWMS_Census2000/MapServer/6',
... | [
"fgregg@uchicago.edu"
] | fgregg@uchicago.edu |
b5a06168a7891d65d6d1f2dc37cc42b31c3f9075 | 14b8cf0b67104b53534678b8c0e9525ace4714ff | /codeeval/spiral.py | 8ce3b47e920f2d0e9c03bbd1d9e3a51d4092b051 | [] | no_license | bhfwg/py_learn | bb11898fd81f653643fc61949f43df751d317fcb | eca9da748bada67357961d1581d8ec890a3385f8 | refs/heads/master | 2020-03-27T15:01:25.881792 | 2018-06-05T01:36:26 | 2018-06-05T01:36:26 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,433 | py | from sys import argv
def spiral_printing(n, m, one):
if n * m == 1:
yield one[0]
return
def point_2_index(x, y):
return x * m + y
ax = 0
ay = 0
bx = 0
by = m - 1
cx = n - 1
cy = m - 1
dx = n - 1
dy = 0
while 1:
for i in xrange(ay, by):
... | [
"metathinkerk@gmail.com"
] | metathinkerk@gmail.com |
6c45e72f32ca223fecfcc490073f0cd0d14b4b65 | 0130c8b14927097663157846adc4b146d67d2fda | /tests/common/test_run/div_no_nan_run.py | 1a2c66c665dc13f6f5900b55ab27ee71b9d67109 | [
"Apache-2.0",
"LicenseRef-scancode-unknown-license-reference",
"Unlicense",
"BSD-3-Clause",
"NCSA",
"LLVM-exception",
"Zlib",
"BSD-2-Clause",
"MIT"
] | permissive | Shigangli/akg | e8be3e0ee1eafe3e42b4cc4d424c28f08ef4c0bc | 3766c54e0b109541932d147a6b5643a334b82403 | refs/heads/master | 2023-09-06T05:13:40.571583 | 2021-11-23T03:44:54 | 2021-11-23T03:44:54 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,497 | py | # Copyright 2020 Huawei Technologies Co., Ltd
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or a... | [
"1027252281@qq.com"
] | 1027252281@qq.com |
9fc39c434aeb8db7e69c85650d79dea51a686666 | 5d2404f62e58d5fd1f6112744ff32c3166183ac7 | /Geek University/Seção 4/Exercicios/EX49.py | de8275af5902ac3f09895155461a32956779a2ef | [] | no_license | Leownhart/My_Course_of_python | 236cfc84d841c5883e5aa1cc0c0730e7a9a83c40 | 5abb21f8cdad91ab54247a007d40bf9ecd2cff8c | refs/heads/master | 2020-08-28T15:04:33.628086 | 2020-08-24T19:25:39 | 2020-08-24T19:25:39 | 217,733,877 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 654 | py | '''
49 - Faça um programa que leia um horário (hora, minuto, segundo) de inicio e a duração, em
segundos, de uma experiência biológica. O programa de resultar com o novo horário
(hora, minuto, segundo) do termino da mesma.
from datetime import datetime
now = datetime.now()
print now.year
print now.month
print now.da... | [
"francisco.amartins.al@gmail.com"
] | francisco.amartins.al@gmail.com |
68eeea5ed3b7b64fa83adeca2d9a513d9c57fd1c | 24caa6710105a060fab2e17147e6d56609939011 | /06-Importing_Data_in_Python_(Part_2)/01-Importing_data_from_the_Internet/01-Importing_flat_files_from_the_web_your_turn!.py | b845373064884f87b9853e85c1360cd5849f5a64 | [] | no_license | inverseundefined/DataCamp | 99607022ad3f899d7681ad1f70fcedab290e269a | 7226b6b6f41888c3610a884db9a226e013d37e56 | refs/heads/master | 2022-01-10T00:53:21.714908 | 2019-07-24T13:27:49 | 2019-07-24T13:27:49 | 198,280,648 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,446 | py | '''
Importing flat files from the web: your turn!
You are about to import your first file from the web! The flat file you will import will be 'winequality-red.csv' from the University of California, Irvine's Machine Learning repository. The flat file contains tabular data of physiochemical properties of red wine, suc... | [
"inversedrivenundefined@gmail.com"
] | inversedrivenundefined@gmail.com |
af110594bc60b09186afd5627301dc1dbf379ca8 | af61044c866eb85ca2c622e082090f7657431206 | /webcli/arthur_utils/experiment.py | a2e95ed3a2caacf3035abf7dcdb6607dbfd126af | [] | no_license | leepand/gridpoc | f7959ef099d8a5513c59dfeb682761771ffe7594 | 4c476cd0241a95a4a7d2abf53a519d3749ecfb94 | refs/heads/master | 2020-04-28T02:38:49.631595 | 2019-03-11T02:01:50 | 2019-03-11T02:01:50 | 174,906,542 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,502 | py | from _mlflow_object import _MLflowObject
class Experiment(_MLflowObject):
"""
Experiment object.
"""
DEFAULT_EXPERIMENT_ID = 0
ACTIVE_LIFECYCLE = 'active'
DELETED_LIFECYCLE = 'deleted'
def __init__(self, experiment_id, name, artifact_location, lifecycle_stage):
super(Experiment, s... | [
"85721094@qq.com"
] | 85721094@qq.com |
33667e8b97d6c876c073bc1b32185c8188c271fa | a1614311937bae5204e171b2a3481fb31e61a490 | /media/codigos/36/36sol118.py | 0e4ccda5dba78b1aa00e7913b2e0c1bb249e5ec9 | [] | no_license | alexandre146/avaliar | 8d406100ed72f10292a0580edac50ad061ad92e9 | 3daf247ca68962086592a356e013b07fa1569afe | refs/heads/master | 2020-03-21T03:09:29.493919 | 2018-07-23T11:41:38 | 2018-07-23T11:41:38 | 137,883,682 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 178 | py | n=int(input())
m=int(input())
if(m%n==0):
print(m)
elif(m%n!=0):
x=m%n
if((m-x)==n):
print("sem multiplos menores que"+str(m))
else:
print(m-x)
| [
"alexandre146@gmail.com"
] | alexandre146@gmail.com |
3a9bf2b914edde4e5c397c7319864fbf32311712 | 117f066c80f3863ebef74463292bca6444f9758a | /finnhub_swagger_api/finnhub_swagger_api/models/revenue_estimates_info.py | 02eb5c15a1e32e1b17eb727157f4a1affeec2537 | [] | no_license | cottrell/notebooks | c6de3842cbaeb71457d270cbe6fabc8695a6ee1b | 9eaf3d0500067fccb294d064ab78d7aaa03e8b4d | refs/heads/master | 2023-08-09T22:41:01.996938 | 2023-08-04T22:41:51 | 2023-08-04T22:41:51 | 26,830,272 | 3 | 1 | null | 2023-03-04T03:58:03 | 2014-11-18T21:14:23 | Python | UTF-8 | Python | false | false | 7,028 | py | # coding: utf-8
"""
Finnhub API
No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) # noqa: E501
OpenAPI spec version: 1.0.0
Generated by: https://github.com/swagger-api/swagger-codegen.git
"""
import pprint
import re # noqa: F401
import six... | [
"cottrell@users.noreply.github.com"
] | cottrell@users.noreply.github.com |
26ec2100442d4be7cb84f871f4af39f81f332470 | 056f10d9f99506bb9b5abf7e91633f3ad0c76061 | /CountCSVRows.py | f31ac1a85a8c869736b03a67223274ff65e3ce66 | [] | no_license | taers232c/GAM-Scripts3 | 5f171b620b2ac19514ab7198e39720f59a60ba9e | a59c5adb7b03b6bc9a4e054b9b41eabae2779f13 | refs/heads/master | 2023-08-31T06:43:57.645295 | 2023-08-22T17:32:21 | 2023-08-22T17:32:21 | 108,921,186 | 176 | 46 | null | 2023-02-28T15:52:32 | 2017-10-30T23:48:44 | Python | UTF-8 | Python | false | false | 573 | py | #!/usr/bin/env python3
"""
# Purpose: Count rows in a CSV file
#
# Python: Use python or python3 below as appropriate to your system; verify that you have version 3
# $ python -V or python3 -V
# Python 3.x.y
# Usage:
# python3 CountCSVRows.py File.csv
#
"""
import csv
import sys
QUOTE_CHAR = '"' # Adjust as nee... | [
"ross.scroggs@gmail.com"
] | ross.scroggs@gmail.com |
7c4856b94c048615d4958703b69db3191a928ddf | d7195e61bc37f6b90c8bc2d6f164e5e7da98aa77 | /landlab/grid/linkstatus.py | 6eb74a1aadecb3b7f83bdb0915c210dc93491ae0 | [
"MIT"
] | permissive | joeljgeo/landlab | ffaae36b3ad3c5e1377355427bc9cfbb21074f01 | 1d2651c76a8a36a7a132f139638192df1823f8fb | refs/heads/master | 2020-04-05T01:38:11.870170 | 2018-11-09T16:44:31 | 2018-11-09T16:44:31 | 156,443,219 | 0 | 0 | MIT | 2018-11-09T16:44:32 | 2018-11-06T20:26:54 | Python | UTF-8 | Python | false | false | 5,415 | py | #! /usr/bin/env python
import numpy as np
from .nodestatus import (CLOSED_BOUNDARY, CORE_NODE, FIXED_GRADIENT_BOUNDARY,
FIXED_VALUE_BOUNDARY)
from ..utils.decorators import (cache_result_in_object,
make_return_array_immutable)
# Define the link types
#: Indica... | [
"mcflugen@gmail.com"
] | mcflugen@gmail.com |
6d8323e3ea02352d65d2f5f99110a013ddd2cc3d | 1348885ccdebfcb6010a267a3440a4ccc64373d1 | /Examples/IPlugSideChain/scripts/update_installer_version.py | d4c3a9886d1d11e75b3572f01e371d4ebdeff671 | [
"LicenseRef-scancode-other-permissive",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | ddf/iPlug2 | c6565343def57dbf063fefb3b875c6337d363081 | d05d20929544b06500369208b9ec81a62eb191fb | refs/heads/master | 2022-11-02T04:39:45.019866 | 2022-10-10T17:15:04 | 2022-10-10T17:15:04 | 170,179,953 | 2 | 0 | NOASSERTION | 2019-02-11T18:30:30 | 2019-02-11T18:30:30 | null | UTF-8 | Python | false | false | 3,091 | py | #!/usr/bin/python3
# this script will update the versions in packages and innosetup installer files to match that in config.h
import plistlib, os, datetime, fileinput, glob, sys, string
scriptpath = os.path.dirname(os.path.realpath(__file__))
projectpath = os.path.abspath(os.path.join(scriptpath, os.pardir))
IPLUG2_... | [
"olilarkin@googlemail.com"
] | olilarkin@googlemail.com |
d021d36f984ab643b089ddca6cf72adba3e0c21e | e3565e1ce607f60745f2a045aae8026661a6b99b | /resources/Onyx-1.0.511/py/onyx/grid/griddy.py | b7fdb67930c51b30bfc7c426ac2a4ed49d48c2c2 | [
"Apache-2.0"
] | permissive | eternity668/speechAD | 4c08d953b2ed06b3357b1c39d8709dd088a2471c | f270a1be86372b7044615e4fd82032029e123bc1 | refs/heads/master | 2021-01-12T22:10:33.358500 | 2014-02-03T16:03:28 | 2014-02-03T16:03:28 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,152 | py | ###########################################################################
#
# File: griddy.py (directory: ./py/onyx/grid)
# Date: 4-Feb-2009
# Author: Hugh Secker-Walker
# Description: A function for use in testing by gridgo.py
#
# This file is part of Onyx http://onyxtools.sourceforge.net
#
... | [
"nassos@n12mavra.cs.ntua.gr"
] | nassos@n12mavra.cs.ntua.gr |
9eb02a16cb5679b043e158e4f36ae3ea11a51e80 | 162f0a636cab320ead784b33597e583e38ac432f | /1744.py | f339b7b48defbece73a4dddc7bee0dbea7c0d161 | [] | no_license | goodsosbva/BOJ_Greedy | fc2450df90f64790f6cc01c168ba7f19ec83e504 | 98d21af254cacf41632a4b40ca9ef643b29bb104 | refs/heads/main | 2023-03-31T17:26:33.863396 | 2021-04-06T07:50:57 | 2021-04-06T07:50:57 | 347,081,712 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,641 | py | n = int(input())
sequence = []
negative = []
positive = []
res = 0
for i in range(n):
i = int(input())
sequence.append(i)
for k in sequence:
if k < 0:
negative.append(k)
elif k > 0:
positive.append(k)
else:
negative.append(k)
negative.sort()
positive.sor... | [
"noreply@github.com"
] | goodsosbva.noreply@github.com |
f8e9765b859dd527defd2ce06933a55ecb70e041 | 35fdd5b42b47a1dbe6a25f6fc1865f4e48b842a5 | /evalml/tests/component_tests/test_catboost_classifier.py | 1ef6fd41a8656a2914d90172ce42a92330d0a24e | [
"BSD-3-Clause"
] | permissive | skvorekn/evalml | 41e5426f9f7d5ad625c21b74336009894c79c7de | 2cbfa344ec3fdc0fb0f4a0f1093811135b9b97d8 | refs/heads/main | 2023-03-27T01:42:07.691406 | 2021-03-19T18:53:43 | 2021-03-19T18:53:43 | 349,555,689 | 0 | 0 | BSD-3-Clause | 2021-03-21T14:57:01 | 2021-03-19T21:08:12 | null | UTF-8 | Python | false | false | 837 | py | import pandas as pd
from pytest import importorskip
from evalml.pipelines.components import CatBoostClassifier
from evalml.utils import SEED_BOUNDS
importorskip('catboost', reason='Skipping test because catboost not installed')
def test_catboost_classifier_random_seed_bounds_seed(X_y_binary):
"""ensure catboost... | [
"noreply@github.com"
] | skvorekn.noreply@github.com |
0f776e18f96167e136351a53c789777a2a35a629 | cbc5e26bb47ae69e80a3649c90275becf25ce404 | /xlsxwriter/test/comparison/test_chart_layout04.py | f377a5806721d2af1d65752bac33bb918a5d84f3 | [
"BSD-2-Clause-Views",
"BSD-3-Clause",
"MIT"
] | permissive | mst-solar-car/kicad-bom-generator | c3549409c3139f787ad28391372b5cb03791694a | 2aae905056d06f3d25343a8d784049c141d05640 | refs/heads/master | 2021-09-07T14:00:40.759486 | 2018-02-23T23:21:13 | 2018-02-23T23:21:13 | 107,868,801 | 3 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,764 | py | ###############################################################################
#
# Tests for XlsxWriter.
#
# Copyright (c), 2013-2017, John McNamara, jmcnamara@cpan.org
#
from ..excel_comparsion_test import ExcelComparisonTest
from ...workbook import Workbook
class TestCompareXLSXFiles(ExcelComparisonTest):
"""... | [
"mwrb7d@mst.edu"
] | mwrb7d@mst.edu |
48cf0f54c8738ea16878d6beb0a2fd2a8d7aa385 | c50e5af8f72de6ef560ee6c0bbfa756087824c96 | /刷题/Leetcode/84. 柱状图中最大的矩形/p84_Largest_Rectangle_in_Histogram_暴力.py | 7430809260718f7c390d48a5c4dc9f9b4dcaa792 | [] | no_license | binghe2402/learnPython | 5a1beef9d446d8316aaa65f6cc9d8aee59ab4d1c | 2b9e21fe4a8eea0f8826c57287d59f9d8f3c87ce | refs/heads/master | 2022-05-27T03:32:12.750854 | 2022-03-19T08:00:19 | 2022-03-19T08:00:19 | 252,106,387 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,012 | py | from typing import List
class Solution:
# # 遍历不同边界(宽度),根据最小高度
# def largestRectangleArea(self, heights: List[int]) -> int:
# area = 0
# for i in range(len(heights)):
# for j in range(i, len(heights)):
# area = max(area, (j-i+1)*min(heights[i:j+1]))
# return ... | [
"binghe2402@hotmail.com"
] | binghe2402@hotmail.com |
c6fef081bd46b0cb2875a2870bf64ad4631575c4 | baffcef29e33658138c43ef358d7399ab3ea2c0d | /WORKFLOWS/Tools/NEC/NAL/nal-model/rest/test/unit/test_dcs.py | cb088e130c920d2697ba7584fef6500526bdc175 | [
"Apache-2.0",
"JSON"
] | permissive | openmsa/NO | aa7d4ff000875bfcff0baee24555ec16becdb64e | 24df42ee3927415b552b5e5d7326eecd04ebca61 | refs/heads/master | 2020-03-09T23:21:09.657439 | 2019-03-29T06:29:07 | 2019-03-29T06:29:07 | 129,056,267 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 7,271 | py | import json
import mysql.connector
import os
import sys
import unittest
import urllib.request
import urllib.parse
sys.path.append(os.path.dirname(os.path.abspath(__file__)) + '/../../../')
from rest.api import router
from rest.conf import config
class TestSelectAPI(unittest.TestCase):
# Do a test of Select.
... | [
"ofa@ubiqube.com"
] | ofa@ubiqube.com |
fbd49bfeec9947ef6f83b1e9787a0081f6be9f05 | 57775b4c245723078fd43abc35320cb16f0d4cb6 | /Data structure/linked-list/delete-node-given-position.py | cc4164b336e8f1ad6093479327c26ce5514d4106 | [] | no_license | farhapartex/code-ninja | 1757a7292ac4cdcf1386fe31235d315a4895f072 | 168fdc915a4e3d3e4d6f051c798dee6ee64ea290 | refs/heads/master | 2020-07-31T16:10:43.329468 | 2020-06-18T07:00:34 | 2020-06-18T07:00:34 | 210,668,245 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,394 | py | """
Given a ‘key’, delete the first occurrence of this key in linked list.
To delete a node from linked list, we need to do following steps.
1) Find previous node of the node to be deleted.
2) Change the next of previous node.
3) Free memory for the node to be deleted.
"""
class Node:
def __init__(self, data):
... | [
"farhapartex@gmail.com"
] | farhapartex@gmail.com |
ca0bf818f5d797fe169d26f5876caf9e6873172e | 197b10d75ba44b22fca29f8d69c2922b72cb8ca5 | /ship/api.py | ae8690dc1a4da94d2c96e6f66ac78b8994a82a42 | [] | no_license | webbyfox/py_master | c713c87cf4fd7d2697765211cdaefd7b49f96adc | e4b3ef5ea618b8f91c363d7f51d0e7b7064762a9 | refs/heads/master | 2021-01-11T14:45:15.060075 | 2017-01-27T13:24:58 | 2017-01-27T13:24:58 | 80,209,118 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,519 | py | # -*- coding: utf-8 -*-
from rest_framework import viewsets, mixins, status
from rest_framework.pagination import LimitOffsetPagination
from rest_framework.permissions import IsAuthenticated
from rest_framework.response import Response
from assessment.auth import TokenAuthSupportQueryString
from .injection_setup impor... | [
"mr.mansuri@gmail.com"
] | mr.mansuri@gmail.com |
e7cbec8407c61c7b724171aa967674dbf244853b | 89bae02f23e787416fda894a128c9abfb4986515 | /metalearning/allennlp/tests/modules/matrix_attention/cosine_matrix_attention_test.py | cff481ba8ea3a77de780b912867c54cef1eb849c | [
"Apache-2.0"
] | permissive | asheverdin/multilingual-interference | f2e64cebfffc749b080fa64860659922224e6e65 | 7bc1b5918142e3c84bea83c5a7f39e3f245172e9 | refs/heads/main | 2023-05-12T13:07:19.997696 | 2021-05-28T22:16:26 | 2021-05-28T22:16:26 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,518 | py | import torch
from numpy.testing import assert_almost_equal
import numpy
from allennlp.common import Params
from allennlp.common.testing.test_case import AllenNlpTestCase
from allennlp.modules.matrix_attention import CosineMatrixAttention
from allennlp.modules.matrix_attention.matrix_attention import MatrixAtten... | [
"lcur0308@test3.irc.sara.nl.irc.sara.nl"
] | lcur0308@test3.irc.sara.nl.irc.sara.nl |
d2462ea0d850cd6935ccb6c60eff3fbb00faf7d7 | 07917881310fc81d85a2cbdf27c9b3c4fa03c694 | /python1812/python_1/17_测试_收发邮件_二维码/代码/04_验证码生成器.py | 4d493eee3597ce7e1c156d58c53c29845e19966c | [] | no_license | zaoyuaner/Learning-materials | 9bc9a127d1c6478fb6cebbb6371b1fd85427c574 | 1f468a6f63158758f7cbfe7b5df17f51e3205f04 | refs/heads/master | 2020-05-18T11:38:45.771271 | 2019-05-20T09:07:44 | 2019-05-20T09:07:44 | 184,384,050 | 2 | 3 | null | null | null | null | UTF-8 | Python | false | false | 2,363 | py | import datetime
import hashlib
from PIL import ImageFont,ImageDraw,Image
from random import randint
class VerifyCode:
def __init__(self,width=100,height=40,size=4):
"""
:param width: 验证码的宽度
:param height: 验证码的高度
:param size: 验证码的长度
"""
self.width = width if width > 0 else 100
self.height = height if h... | [
"13510647877@163.com"
] | 13510647877@163.com |
edfcd0b67010b318be752683aea47602efef2e0e | 9b57429efa72dbfa2ead9ae8d98a148475264aef | /dataservice/zmq/UPcomputer_part/data_process_0mqsubsys/codetestfile.py | 5b92ab166e2e97779e29006953d6456126db19c8 | [] | no_license | Scottars/nis_website | 7d78b1ab8647ebf17bc2b020660a56ac6f6a039f | 2025e428dd65dba06c95738233978604ee011570 | refs/heads/master | 2022-03-07T19:04:15.565128 | 2021-01-19T16:03:50 | 2021-01-19T16:03:50 | 218,421,853 | 0 | 0 | null | 2022-03-02T06:49:57 | 2019-10-30T01:58:29 | JavaScript | UTF-8 | Python | false | false | 155 | py | import struct
b = b'exp' + struct.pack('!f', 12)
print(b)
print(b[0:3])
if b[0:3] == b'exp':
exp_id = struct.unpack('!f', b[3:7])[0]
print(exp_id) | [
"ScottarSEEE@hust.edu.cn"
] | ScottarSEEE@hust.edu.cn |
82ecfd01834d11e1c0de1b980af3a9cafb7d5d79 | d0fec74acfbfdee1b662736731c1cc988e2ba2ee | /problem_44/p044.py | 45a4578f96261bb8aeac04304edbc1ab5ebc2014 | [] | no_license | msztylko/project-Euler | fdd0cfefbe88b63f6dbd2d08f1cd59270b9e1735 | b3f5ce828ccc6662c100dd27fa295fc8afa22f6e | refs/heads/master | 2021-11-23T02:50:19.333259 | 2021-10-31T17:52:28 | 2021-10-31T17:52:28 | 195,980,596 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,851 | py | import itertools, sys
if sys.version_info.major == 2:
range = xrange
def compute():
pentanum = PentagonalNumberHelper()
min_d = None # None means not found yet, positive number means found a candidate
# For each upper pentagonal number index, going upward
for i in itertools.count(2):
pen... | [
"marcin.sztylko@gmail.com"
] | marcin.sztylko@gmail.com |
81678e4f401442962478ab90127c24b61b21e897 | c074ce302e0a2a09ebe8b0a94e342380afbaa911 | /beakjoon_PS/no2579_2.py | 7c00e40144c179d3cbf2eca5fbd8ec8eb8d546f6 | [] | no_license | elrion018/CS_study | eeea7a48e9e9b116ddf561ebf10633670d305722 | 3d5478620c4d23343ae0518d27920b3211f686fd | refs/heads/master | 2021-06-10T13:35:20.258335 | 2021-04-25T10:12:17 | 2021-04-25T10:12:17 | 169,424,097 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 555 | py |
import sys
N = int(sys.stdin.readline())
stair = []
for _ in range(N):
stair.append(int(sys.stdin.readline()))
dp = [[0, 0] for _ in range(N)]
if N > 2:
dp[0][0] = stair[0]
dp[1][0] = stair[1]
dp[1][1] = stair[0] + stair[1]
dp[2][0] = stair[0] + stair[2]
dp[2][1] = stair[1] + stair[2]
f... | [
"elrion018@gmail.com"
] | elrion018@gmail.com |
aa4c1d64ab5007478c6035cf4a0c3268d542695f | 9743d5fd24822f79c156ad112229e25adb9ed6f6 | /xai/brain/wordbase/nouns/_tow.py | bbb4161da8d142413231367d45dc13fd41964c06 | [
"MIT"
] | permissive | cash2one/xai | de7adad1758f50dd6786bf0111e71a903f039b64 | e76f12c9f4dcf3ac1c7c08b0cc8844c0b0a104b6 | refs/heads/master | 2021-01-19T12:33:54.964379 | 2017-01-28T02:00:50 | 2017-01-28T02:00:50 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 369 | py |
#calss header
class _TOW():
def __init__(self,):
self.name = "TOW"
self.definitions = [u"to pull someone's vehicle using a rope or chain tied to your vehicle: ", u'being pulled along: ']
self.parents = []
self.childen = []
self.properties = []
self.jsondata = {}
self.specie = 'nouns'
def run(sel... | [
"xingwang1991@gmail.com"
] | xingwang1991@gmail.com |
1345cc0e0a984974cc45d265fb5e248b561053c2 | b503e79ccfca67c8114f5bd7a215f5ae993a0ba4 | /airflow/providers/amazon/aws/sensors/glue.py | 21a82da9ee9d040fd45ccda5044d467bf7c6b4c3 | [
"Apache-2.0",
"BSD-3-Clause",
"Python-2.0",
"MIT"
] | permissive | github/incubator-airflow | df1d9780f862ea1df8261ea6015dd50a4583f983 | 73f70e00b9fd294057f8ca6b714a85622f6d5dd5 | refs/heads/gh-2.0.2 | 2023-07-29T18:08:43.140580 | 2022-09-14T18:23:42 | 2022-09-14T18:23:42 | 80,634,006 | 24 | 27 | Apache-2.0 | 2023-04-18T04:24:36 | 2017-02-01T15:34:55 | Python | UTF-8 | Python | false | false | 2,398 | py | #
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not... | [
"noreply@github.com"
] | github.noreply@github.com |
816ccf13d545d21c6a8991fbbd5db56841a3fd65 | 4eab1bd9e1b00155872e44963a5df0532cb5341f | /menus/menuTwo.py | ebbc521d4e91603c346648b2c0ccb7a4a9256571 | [] | no_license | soheilpaper/python-gui | 9b067467ca41d27092e5817d0a49162b10c37de6 | 4e6bcad319829dd2c0fdc328520a55a7932060c7 | refs/heads/master | 2020-12-31T04:29:16.798703 | 2016-04-08T08:41:59 | 2016-04-08T08:41:59 | 55,763,643 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 1,595 | py | import wx
########################################################################
class MyForm(wx.Frame):
""""""
#----------------------------------------------------------------------
def __init__(self):
"""Constructor"""
wx.Frame.__init__(self, None, title="wx.Menu Tutorial")
... | [
"soheil_paper@yahoo.com"
] | soheil_paper@yahoo.com |
5ea8085f35c9778a5a1d4aae6dc84dacc2eb3e30 | 62e58c051128baef9452e7e0eb0b5a83367add26 | /edifact/D08A/MOVINSD08AUN.py | 546f7086b78b82989b1b35deabc5ccb25f908114 | [] | no_license | dougvanhorn/bots-grammars | 2eb6c0a6b5231c14a6faf194b932aa614809076c | 09db18d9d9bd9d92cefbf00f1c0de1c590fe3d0d | refs/heads/master | 2021-05-16T12:55:58.022904 | 2019-05-17T15:22:23 | 2019-05-17T15:22:23 | 105,274,633 | 0 | 0 | null | 2017-09-29T13:21:21 | 2017-09-29T13:21:21 | null | UTF-8 | Python | false | false | 1,740 | py | #Generated by bots open source edi translator from UN-docs.
from bots.botsconfig import *
from edifact import syntax
from recordsD08AUN import recorddefs
structure = [
{ID: 'UNH', MIN: 1, MAX: 1, LEVEL: [
{ID: 'BGM', MIN: 1, MAX: 1},
{ID: 'DTM', MIN: 1, MAX: 1},
{ID: 'RFF', MIN: 0, MAX: 9, LEVEL: [
... | [
"jason.capriotti@gmail.com"
] | jason.capriotti@gmail.com |
82b102860dad12c81b3575f99ab5d3102e7229e3 | 927d23e5fbcbd7001b1007990b9a28014bfb8219 | /mnist_classification.py | 373bf1d62d3f945e2554161b608f5dc3b439098b | [] | no_license | minar09/tensorflow-practices | 5822cf784063223bc0a5a62570fa0a5548cf1ef0 | 7982860ce2ec6df0c57a5389711464cbddad89fe | refs/heads/master | 2020-03-28T21:09:32.658650 | 2018-10-08T15:25:08 | 2018-10-08T15:25:08 | 149,133,679 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,725 | py | #### MNIST classification ###
# Hide the warning messages about CPU/GPU
import os
os.environ['TF_CPP_MIN_LOG_LEVEL'] = '2'
# Import libraries
import tensorflow as tf
import time
import numpy as np
old_v = tf.logging.get_verbosity()
tf.logging.set_verbosity(tf.logging.ERROR)
# Download/Read MNIST
from tensorflow.ex... | [
"minar09.bd@gmail.com"
] | minar09.bd@gmail.com |
088dc88aa4aeb64878d97237118802a64edf1d5f | 48db7bebad4309a7bca8b7dec2cc9193551f46a3 | /returns/_generated/pointfree/bind_io.pyi | 192094dd7cdfecddb6d6bb7c83451e2b4d7e27ae | [
"BSD-2-Clause"
] | permissive | kenjihiraoka/returns | bff6196a059d411b6c36f4a2e284e4439d24fd73 | 4589973520d7226b18acd7295d1a9a10ff032759 | refs/heads/master | 2022-11-20T13:20:41.094871 | 2020-07-07T08:23:05 | 2020-07-07T08:23:05 | 277,863,697 | 0 | 0 | BSD-2-Clause | 2020-07-07T16:09:25 | 2020-07-07T16:09:25 | null | UTF-8 | Python | false | false | 1,779 | pyi | from typing import Callable, TypeVar, overload
from typing_extensions import Protocol
from returns.context import RequiresContextFutureResult, RequiresContextIOResult
from returns.future import Future, FutureResult
from returns.io import IO, IOResult
_ValueType = TypeVar('_ValueType', contravariant=True)
_ErrorType ... | [
"mail@sobolevn.me"
] | mail@sobolevn.me |
70237c341ae1c9585377c6c6ec289173ce92bdae | 148044ba8412cfe9227201e82360770d6a7e9780 | /check_screen.py | 095f92651215f811b52a37d88fe1c3fbc9022209 | [] | no_license | mwaskom/sticks_experiment | 9e0b2af851e20f82cd8a3011b08ac061b0061191 | fcfd98cb4528e9011168be27b2121a96514b3fa3 | refs/heads/master | 2023-08-24T06:22:27.939464 | 2015-08-28T23:53:16 | 2015-08-31T04:38:24 | 38,704,521 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 424 | py |
import sys
from psychopy import visual, event
import cregg
def main(arglist):
p = cregg.Params("scan")
p.set_by_cmdline(arglist)
win = cregg.launch_window(p)
visual.Circle(win, p.array_radius,
edges=128,
lineColor="white",
lineWidth=2).draw()
... | [
"mwaskom@stanford.edu"
] | mwaskom@stanford.edu |
4a010a42bfbd615afad1fd018c160396fa4dbd69 | 40f4626ec26f23923c2b19d7ed24f3c512495182 | /src/kangqi/task/compQA/model/module/cross_attention_indirect.py | 3606a67410715c49755b69f8e4e28061ab9a5fcc | [] | no_license | Zjhao666/CompQA | c937c382a2f0a0fce4fdda8efda7c916b3e4c978 | 4bb2abc40428373481909e02543062a7388615bd | refs/heads/master | 2023-02-09T02:28:09.966576 | 2020-12-31T21:18:32 | 2020-12-31T21:18:32 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,278 | py | """
Author: Kangqi Luo
Goal: Combine the structure of ABCNN-1 and AF-attention
(A Decomposable Attention Model for Natural Language Inference)
We are using the module in compQA scenario, where the rhs (path) is represented by both pwords and preds.
Therefore, we send'em together into the module, making it a little bit ... | [
"luo.kangqi@qq.com"
] | luo.kangqi@qq.com |
dc34c1f11f334a3d915def0a7e3345ee0781e7e9 | 38ea041a35d6e1bbdcb875cfff1a313b02476e81 | /appModules/AddContact.py | 515d8116725ef529922d9747efd7df54bad352c6 | [] | no_license | saraliuhou/DataDriverTestFrameWork | 1824d0b771c20a87ce3d0b5cebf5cf1e70b4226b | 5f243026e9f03e96fa010f945fb31b7545759798 | refs/heads/master | 2020-06-01T00:19:32.435417 | 2019-06-12T09:10:09 | 2019-06-12T09:10:09 | 190,554,542 | 0 | 0 | null | 2019-06-06T09:29:50 | 2019-06-06T09:29:50 | null | UTF-8 | Python | false | false | 2,262 | py | from pageObjects.HomePage import HomePage
from pageObjects.NewContact import AddContactPage
from selenium.webdriver.support.wait import WebDriverWait
from selenium.webdriver.support import expected_conditions as EC
from util.ParseConfigurationFile import ParseConfigFile
class NewContactPersonAction(object):
def __... | [
"281754043@qq.com"
] | 281754043@qq.com |
d8f3167c34525042bfc9833d02d8d53673ff7978 | 79aa4b99a48bb16a907916ad63c902443420541a | /0019.py | e1253c96f9a4ecabdca22315f7ecd7d39377a98c | [] | no_license | mach8686devops/leetcode-100 | 62dec66c719d7cfa120ca9505701df49d8d5b982 | f90526c9b073165b86b933cdf7d1dc496e68f2c6 | refs/heads/main | 2023-04-11T06:28:15.059587 | 2021-04-13T12:11:54 | 2021-04-13T12:11:54 | 329,346,572 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 375 | py | # Definition for singly-linked list.
class ListNode:
def __init__(self, x):
self.val = x
self.next = None
class Solution:
def removeNthFromEnd(self, head: ListNode, n: int) -> ListNode:
l = []
while head: l, head = l + [head], head.next
if n != len(l): l[-n - 1].next = ... | [
"zhangjohn202@gmail.com"
] | zhangjohn202@gmail.com |
2132ca489839efb59eecac3da30efd56457831e6 | 18eac94ff076c1eecd72870ef93ae656906e8673 | /supervised_learning/0x06-keras/13-predict.py | e2426676d174b5ff52b5fd6940693d363bda35a2 | [] | no_license | dgquintero/holbertonschool-machine_learning | c1331ff87e053f9c143a0e503e8db177dfc7aafe | c80073d0ef68deeedbe2d991e296ef75f58a220f | refs/heads/master | 2022-12-19T21:49:10.581793 | 2020-10-15T14:56:22 | 2020-10-15T14:56:22 | 279,329,167 | 0 | 1 | null | 2020-09-25T19:11:52 | 2020-07-13T14:42:03 | Python | UTF-8 | Python | false | false | 574 | py | #!/usr/bin/env python3
"""function predict"""
import tensorflow.keras as K
def predict(network, data, verbose=False):
"""
function that tests a neural network
Arguments:
network: the network model to test
data: the input data to test the model with
labels: are the correct one-hot l... | [
"dgquintero02@hotmail.com"
] | dgquintero02@hotmail.com |
c4a498197bd65892c63d8b651006a2e100b27e0c | 48e124e97cc776feb0ad6d17b9ef1dfa24e2e474 | /sdk/python/pulumi_azure_native/media/v20210601/get_transform.py | 2d5107073354128ca98d5c3db8d4db0c9a68f79d | [
"BSD-3-Clause",
"Apache-2.0"
] | permissive | bpkgoud/pulumi-azure-native | 0817502630062efbc35134410c4a784b61a4736d | a3215fe1b87fba69294f248017b1591767c2b96c | refs/heads/master | 2023-08-29T22:39:49.984212 | 2021-11-15T12:43:41 | 2021-11-15T12:43:41 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,036 | py | # coding=utf-8
# *** WARNING: this file was generated by the Pulumi SDK Generator. ***
# *** Do not edit by hand unless you're certain you know what you are doing! ***
import warnings
import pulumi
import pulumi.runtime
from typing import Any, Mapping, Optional, Sequence, Union, overload
from ... import _utilities
fro... | [
"noreply@github.com"
] | bpkgoud.noreply@github.com |
4aeb5076c559a2d62968ac097e20666249770856 | 03f9b8bdea312636afb4df3737b55cb0cc4b21ff | /CanIWin.py | 3d81f1f782f454808169ef87a967ad9bee42ec2d | [] | no_license | ellinx/LC-python | f29dd17bbe15407ba0d06ad68386efdc9a343b56 | 9190d3d178f1733aa226973757ee7e045b7bab00 | refs/heads/master | 2021-06-01T15:21:24.379811 | 2020-10-29T04:37:07 | 2020-10-29T04:37:07 | 132,704,788 | 1 | 1 | null | 2019-05-15T03:26:11 | 2018-05-09T05:13:26 | Python | UTF-8 | Python | false | false | 2,052 | py | """
In the "100 game," two players take turns adding, to a running total,
any integer from 1..10. The player who first causes the running total to reach or exceed 100 wins.
What if we change the game so that players cannot re-use integers?
For example, two players might take turns drawing from a common pool of
number... | [
"ellin.xll@gmail.com"
] | ellin.xll@gmail.com |
6276ed8fbaf501f6fe6c7314d1eee780a50c0c89 | 270d7f88e47683abd55c0191466c80513b2aa9f9 | /tests/test_tta.py | 9d0ba17296509b58febeed4a4f4c0b193716299d | [
"MIT"
] | permissive | williamberrios/pytorch-toolbelt | abdf8e455a4ffc79d2afbc92e80005a821fb97a9 | 4a24e6324b8270d31c08b8b2f667d740b9823377 | refs/heads/master | 2023-07-06T06:35:24.197821 | 2021-08-12T07:47:20 | 2021-08-12T07:47:20 | 400,866,088 | 1 | 0 | MIT | 2021-08-28T18:43:12 | 2021-08-28T18:43:12 | null | UTF-8 | Python | false | false | 4,994 | py | from collections import defaultdict
import cv2
import torch
import numpy as np
import pytest
from torch import nn
from pytorch_toolbelt.inference import tta
from pytorch_toolbelt.modules import GlobalAvgPool2d
from pytorch_toolbelt.utils.torch_utils import to_numpy
from pytorch_toolbelt.zoo import resnet34_unet64_s4... | [
"ekhvedchenya@gmail.com"
] | ekhvedchenya@gmail.com |
2f876f6a85661251f0ba85f749269bb1b2e63c24 | e2efa339cf6fb017e1d1898325b363a69c227409 | /app.py | 6367bcdbeda570b322259488161e00e0d12605db | [] | no_license | lm10pulkit/update_delete | 201b22b3816606640ab22a0f63c7bf2d58ed6295 | c9c935e070f555c006dca00fd0940863fcc0790d | refs/heads/master | 2020-04-15T18:32:53.239716 | 2019-01-09T19:07:40 | 2019-01-09T19:07:40 | 164,915,990 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,733 | py | from flask import Flask ,session, render_template, request, redirect,url_for,g
from flask_mysqldb import MySQL
from flask_bcrypt import Bcrypt
import os
# intializing the app
app = Flask(__name__)
#secret key
app.secret_key= os.urandom(24)
# setting up database
app.config['MYSQL_HOST']='localhost'
app.config['MYS... | [
"root@localhost.localdomain"
] | root@localhost.localdomain |
3ad6b6e4e9387b3b9cc5855347a729c5a5d8be58 | 49caef1f93bd4673530e0a4c54c59028fb7b54e6 | /npg7/web_printscreen_zb/controllers.py | f5da2a2deb809c478d12f54592606a9e2f4de36e | [] | no_license | slevenhagen/addons-extra7.0 | 7622024198c0cf637f3f4767eb2b955532af3710 | 85611a86a0e1522fd88b5e6fbb217f425c4ae12d | refs/heads/master | 2020-03-17T14:12:42.082766 | 2018-05-16T13:02:05 | 2018-05-16T13:02:05 | 133,663,372 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,142 | py | # -*- encoding: utf-8 -*-
##############################################################################
#
# Copyright (c) 2013 ZestyBeanz Technologies Pvt. Ltd.
# (http://wwww.zbeanztech.com)
# contact@zbeanztech.com
#
# This program is free software: you can redistribute it and/or modify
# it under the... | [
"slevenhagen@novapointgroup.com"
] | slevenhagen@novapointgroup.com |
19edfb5d48f61044424ab6c2a3dd832edbd0612a | daae0cf103b6c9f26065f7546a7dc79281fc0bde | /16/3.py | 297df94c2bd4b2df86a41fbc8e26d6952e1e12d4 | [] | no_license | oc0de/pyEPI | 97a5d4db91d5459f407c9d414fc999de56885124 | 2b7cedecdd5b8665ab4f1ca4762a3fd5adcc9864 | refs/heads/master | 2021-09-05T09:32:53.646441 | 2018-01-26T03:58:10 | 2018-01-26T03:58:10 | 119,003,665 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 371 | py | def number_of_ways(n, m):
cache = {}
def helper(x,y):
if x == y == 0: return 1
if (x,y) not in cache:
ways_top = 0 if x == 0 else helper(x-1, y)
ways_left = 0 if y == 0 else helper(x, y-1)
cache[(x,y)] = ways_top + ways_left
return cache[(x,y)]
re... | [
"valizade@mail.gvsu.edu"
] | valizade@mail.gvsu.edu |
e0b7367a019a91e2fa1bcd3bff959a74b8b7323a | e8cc4cd00990a4f8a75e538ca68fa77456f37e3c | /telebot/apps.py | f6201278a2003ae19e1031d371370381cf66d2e3 | [] | no_license | devRayanwv/djangoTest | 950b5d54a3a53f52f615e2ed0a99bac975fb0db9 | 71bb9377f70fde5b28c5685e8800c4209f265a9f | refs/heads/master | 2020-04-06T04:28:08.942379 | 2017-02-24T22:20:08 | 2017-02-24T22:20:08 | 82,883,125 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 130 | py | from __future__ import unicode_literals
from django.apps import AppConfig
class TelebotConfig(AppConfig):
name = 'telebot'
| [
"you@example.com"
] | you@example.com |
24d2af17dd3749befa8832fee7ee08d62a1a9063 | 6fa7f99d3d3d9b177ef01ebf9a9da4982813b7d4 | /JgYPQrYdivmqN4KKX_18.py | 51bf0ca4c9e57c6e4d4df644268825f4357b96e2 | [] | no_license | daniel-reich/ubiquitous-fiesta | 26e80f0082f8589e51d359ce7953117a3da7d38c | 9af2700dbe59284f5697e612491499841a6c126f | refs/heads/master | 2023-04-05T06:40:37.328213 | 2021-04-06T20:17:44 | 2021-04-06T20:17:44 | 355,318,759 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 530 | py |
def BMI(weight, height):
if "kilos" in weight:
fBmi = round(float(weight.split()[0]) / float(height.split()[0])**2,1)
else :
a = (float(weight.split()[0])) * 0.453592
b = (float(height.split()[0])) * 0.0254
fBmi = round(a/b**2,1)
if fBmi < 18.5:
return "{0} Underweight".format(fBmi)
eli... | [
"daniel.reich@danielreichs-MacBook-Pro.local"
] | daniel.reich@danielreichs-MacBook-Pro.local |
9ed3302317bb7901f6b3244ef26fc1ecb990a599 | 5b9f9b4ea1494943e6f7f842df55909599ed1304 | /python/onshape_client/oas/models/bt_shaded_render_document_response.py | 7f8e89af07f0ac165d25afbbf29e6536706ff134 | [] | no_license | jenniferyoung02/onshape-clients | f50534f033428027515b7fc0b801b1caab4d0aec | 8ee31a17d7af32f105b851e45f69fd4a3006e1ba | refs/heads/master | 2020-09-07T06:44:37.682545 | 2019-10-08T18:52:06 | 2019-10-08T18:52:06 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,884 | py | # coding: utf-8
"""
Onshape REST API
The Onshape REST API consumed by all clients. # noqa: E501
The version of the OpenAPI document: 1.104
Contact: api-support@onshape.zendesk.com
Generated by: https://openapi-generator.tech
"""
import pprint
import re # noqa: F401
import six
class BTShade... | [
"ekeller@onshape.com"
] | ekeller@onshape.com |
262e1d9f54429dd7118716daf6cfbc910a323686 | 4fb9150b08a128571ed4a84897c8c95afb76ccb6 | /healthy/migrations/0002_labdetail.py | e6624ae565d211b7af58232ca3a06dfcfe941dd7 | [] | no_license | eduarde/ChunkyMonkeys | 815feb7f3e6e2085babb61d12f2255ea2cb46ada | 34f30e6aaeef6af15aa12e6d599f55d67c6fb7d7 | refs/heads/master | 2021-07-09T21:30:49.084584 | 2016-12-05T10:42:04 | 2016-12-05T10:42:04 | 58,738,867 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 1,175 | py | # -*- coding: utf-8 -*-
# Generated by Django 1.9.11 on 2016-11-14 11:38
from __future__ import unicode_literals
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
migrations.swappable_depende... | [
"eduard.erja@gmail.com"
] | eduard.erja@gmail.com |
eb53a990da835beaca9e9cc878481161831bfb1f | 1bb2a9150de01c618163bbb8f872bdce6f14df4f | /BaekJoon/2981_검문.py | acbbec8e742ffdac47cb7a67e0dc300dcd8ab895 | [] | no_license | whyj107/Algorithm | a1c9a49a12a067366bd0f93abf9fa35ebd62102e | aca83908cee49ba638bef906087ab3559b36b146 | refs/heads/master | 2023-04-14T12:59:52.761752 | 2021-05-01T03:53:31 | 2021-05-01T03:53:31 | 240,014,212 | 4 | 0 | null | null | null | null | UTF-8 | Python | false | false | 989 | py | # 문제
# 검문
# https://www.acmicpc.net/problem/2981
# 풀이
from sys import stdin
N = int(stdin.readline())
M = [int(stdin.readline()) for i in range(N)]
M.sort()
tmp = M[-1] - M[0]
y = []
for i in range(2, int(tmp**0.5)+1):
if tmp % i == 0:
y.append(i)
if tmp//i not in y: y.append(tmp/... | [
"noreply@github.com"
] | whyj107.noreply@github.com |
43170fa8f7fc5a3560607c4b21a1cb123096b586 | f6c1a4593859ad75000e726414f25fbf02766143 | /setup.py | 7edb29cfc794fbf5f917801018c219ab2e44a25c | [] | no_license | jbeezley/metadata_extractor | b753ce6f9e55e5bc92f16b5decfbab5b992ac621 | 1401127bf572119353e3c504278ff7436e077c9e | refs/heads/master | 2020-03-20T00:57:52.713434 | 2018-06-12T13:49:54 | 2018-06-12T13:49:54 | 137,062,489 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,917 | py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
###############################################################################
# Copyright 2013 Kitware Inc.
#
# Licensed under the Apache License, Version 2.0 ( the "License" );
# you may not use this file except in compliance with the License.
# You may obtain a cop... | [
"jonathan.beezley@kitware.com"
] | jonathan.beezley@kitware.com |
c56a3f8d77a5d05be57428bbda596c5e31709503 | 241724e83f5c12ed9d7dd3b825dfe4e2b1b0f777 | /examples/boundary_conditions.py | a73111c7860a10c82ddfefc46005d3f0954a7718 | [
"MIT"
] | permissive | xuanxu/py-pde | d8be358ab76d4060b14afc74bc7d836591c6188e | de33d938aea8680eff872ae1b64569895662a248 | refs/heads/master | 2021-03-09T21:37:13.920717 | 2020-03-10T12:18:03 | 2020-03-10T12:18:03 | 246,382,909 | 0 | 0 | MIT | 2020-03-10T18:54:22 | 2020-03-10T18:54:22 | null | UTF-8 | Python | false | false | 521 | py | #!/usr/bin/env python3
from pde import UnitGrid, ScalarField, DiffusionPDE
grid = UnitGrid([16, 16], periodic=[False, True]) # generate grid
state = ScalarField.random_uniform(grid, 0.2, 0.3) # generate initial condition
# set boundary conditions `bc` for all axes
bc_x_left = {'type': 'derivative', 'value': 0.1} ... | [
"david.zwicker@ds.mpg.de"
] | david.zwicker@ds.mpg.de |
aaed72c4c34418066429eb2c96fbe9b95606cdb3 | de358ba57518d65393c810da20c53e1c41494bff | /LRUcache.py | 49f000a37b16c4cd24efb3415b3888324acb43b6 | [] | no_license | avirupdandapat/ALGOPROJECT | 43eef94b13e38452cdc6a506b17b6fee581a07e1 | 55b60a0c6e51cae900e243505f6a4557ad4d7069 | refs/heads/master | 2022-12-29T13:02:54.655976 | 2020-10-18T12:23:57 | 2020-10-18T12:23:57 | 305,095,375 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 878 | py | from collections import deque
class LRUCache:
# @param capacity, an integer
def __init__(self, capacity):
self.capacity = capacity
self.dic = {}
self.q = deque()
# @return an integer
def get(self, key):
if key in self.dic:
self.q.remove(key)
se... | [
"avirup.dandapat@mindtree.com"
] | avirup.dandapat@mindtree.com |
da45f7852916d35f50bd49f037a7b3edd42a3e21 | 68d38b305b81e0216fa9f6769fe47e34784c77f2 | /alascrapy/spiders/amazon_uk_reviews.py | 15695e7d86cb23644a4dfb659ed43372c84943c0 | [] | no_license | ADJet1437/ScrapyProject | 2a6ed472c7c331e31eaecff26f9b38b283ffe9c2 | db52844411f6dac1e8bd113cc32a814bd2ea3632 | refs/heads/master | 2022-11-10T05:02:54.871344 | 2020-02-06T08:01:17 | 2020-02-06T08:01:17 | 237,448,562 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 396 | py | __author__ = 'leonardo'
from alascrapy.spiders.base_spiders.amazon import AmazonReviewsSpider
class AmazonUkReviewsSpider(AmazonReviewsSpider):
name = 'amazon_uk_reviews'
start_url_format = "https://www.amazon.co.uk/product-reviews/%s/ref=cm_cr_dp_see_all_btm?ie=UTF8&showViewpoints=1&sortBy=recent"
date_f... | [
"liangzijie1437@gmail.com"
] | liangzijie1437@gmail.com |
4d1dc1f084686e22f9f832a79dae3c1d0d56dc01 | 43fe6a9d6875f7524204177a3a68229059133789 | /social/account/multiforms.py | 844065a4370c0da415a5df2b271ab382d43f2db9 | [
"MIT"
] | permissive | MiKueen/Social-Network | a011836805ad45228b0031ed1883526b0af02920 | 0b872860f08c3ec6f48a53160128af28787737c7 | refs/heads/master | 2023-04-17T15:33:13.212550 | 2019-07-13T04:40:54 | 2019-07-13T04:40:54 | 196,678,685 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,182 | py | from django.views.generic.base import ContextMixin, TemplateResponseMixin
from django.views.generic.edit import ProcessFormView
from django.http import HttpResponseForbidden
class MultiFormMixin(ContextMixin):
form_classes = {}
prefixes = {}
success_urls = {}
initial = {}
prefix = None
s... | [
"keshvi2298@gmail.com"
] | keshvi2298@gmail.com |
fd975001732ca43e6a45cbcefd0a09a0cf1fd7fa | a37963de31a67c214680d80d9ee3ce4611d28587 | /mrl/modules/model.py | 8f93b82dcc75932df0c875e7910016d0b4a2814d | [
"MIT"
] | permissive | jingweiz/mrl | c4c614877760953b246125688e7df96f9081fc4e | c94ab1685aea85b0d328199adefca543227875af | refs/heads/master | 2022-11-12T01:36:05.354935 | 2020-07-10T23:32:38 | 2020-07-10T23:32:38 | 279,804,300 | 0 | 1 | MIT | 2020-07-15T07:56:50 | 2020-07-15T07:56:49 | null | UTF-8 | Python | false | false | 1,448 | py | import mrl
import torch
from typing import Callable
import os
import pickle
import dill
class PytorchModel(mrl.Module):
"""
Generic wrapper for a pytorch nn.Module (e.g., the actorcritic network).
These live outside of the learning algorithm modules so that they can easily be
shared by different modules (e.g.... | [
"silviu.pitis@gmail.com"
] | silviu.pitis@gmail.com |
0c3976214f8e28555d2e3ff9dd37ab37dd2c712b | 251e4de91841fc42959e89211d3501ce24c4435e | /eventdriven/adapter/base.py | 253f683289151bfeaaceae339ac6fba3956f10e6 | [
"Apache-2.0"
] | permissive | ZSAIm/EventDriven | df1251c4e9f3f382600159d6626a6c959670c438 | 92bed2b3cde9249724f9cc25f3d19470abda5b9b | refs/heads/master | 2020-12-07T17:04:32.511933 | 2020-02-20T07:51:18 | 2020-02-20T07:51:18 | 232,758,430 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,767 | py | # -*- coding: UTF-8 -*-
from abc import ABC
class AbstractAdapter(ABC):
def __setup__(self, parent, name, **options):
""" 安装适配器过程中调用该方法进行初始化。 """
self._parent = parent
self._instance_name = name
self._options = options
def __name__(self):
""" 返回适配器实例名称。 """
re... | [
"zzsaim@163.com"
] | zzsaim@163.com |
7075b62d95d63c0abfdebcac5772e9ce9fff30f4 | 02b460257be33634a5e204c12a22d396c49ec1e8 | /ch1/ex1_6.py | e506176ded89c2a72f238158685c3fe6189a0731 | [] | no_license | wxhheian/ptcb | c5250362d5ab0903498e52c5a5d9cbdccc37853f | ae95fb18853f94246b4b1e84371e3f140677c8e8 | refs/heads/master | 2020-07-02T08:28:16.867948 | 2019-08-09T18:49:50 | 2019-08-09T18:49:50 | 201,473,507 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 466 | py | ##实现一个键对应多个值的字典
#####实现方法一:将多个值放到不同的容器中
# d = {
# 'a':[1,2,3],
# 'b':[4,5]
# }
# e = {
# 'a':{1,2,3},
# 'b':{4,5}
# }
from collections import defaultdict
d = defaultdict(list)
d['a'].append(1)
d['b'].append(2)
d['b'].append(4)
e = defaultdict(set)
e['a'].add(1)
e['a'].add(2)
e['b'].add(4)
############... | [
"365194143@qq.com"
] | 365194143@qq.com |
06d81819ec245e77cec949f12a8b70ffb0617810 | 9431bba2d148f8aef9c0a8f3ca16fcf875890757 | /scraping/get_html_title.py | 9f5573db2266ed5c6d715cae3af9936cb85faae6 | [
"MIT"
] | permissive | terasakisatoshi/pythonCodes | fba0b78414b2c85f4a738200354ea583f0516768 | 953210c06e9885a7c885bc01047715a77de08a1a | refs/heads/master | 2023-05-14T12:30:22.201711 | 2023-05-07T13:41:22 | 2023-05-07T13:41:22 | 197,893,702 | 2 | 1 | MIT | 2022-11-25T10:59:52 | 2019-07-20T07:09:12 | Jupyter Notebook | UTF-8 | Python | false | false | 603 | py | from urllib.request import urlopen
from urllib.error import HTTPError
from bs4 import BeautifulSoup
def get_title(url):
try:
html = urlopen(url)
except HTTPError as e:
print(e)
return None
try:
bsoup = BeautifulSoup(html.read())
title = bsoup.body.h1
except Attr... | [
"terasakisatoshi.math@gmail.com"
] | terasakisatoshi.math@gmail.com |
c822f6ed07953bee56d648fff611aea04680c407 | 366b2ff9cd498808438bf7c48f697c05b361d02c | /models.py | 0606075241f9749a7ff176655dadf12a115be600 | [] | no_license | c-bata/AngularJS-Bottle-TodoApp | 1aef6b09fd85fabaa63898ab3fb9a2d586216b93 | 8f03820b7949b0c28477970c58f25ccd1856b2a9 | refs/heads/master | 2021-03-12T22:40:32.000758 | 2015-11-04T11:14:47 | 2015-11-04T11:14:47 | 38,732,944 | 2 | 0 | null | 2015-11-04T11:11:39 | 2015-07-08T05:02:47 | Python | UTF-8 | Python | false | false | 1,225 | py | from datetime import datetime
from sqlalchemy import (
Column, Integer, Unicode, UnicodeText, Boolean, DateTime,
create_engine
)
from sqlalchemy.ext import declarative
from bottle.ext import sqlalchemy
Base = declarative.declarative_base()
engine = create_engine('sqlite:///:memory:', echo=True)
plugin = sq... | [
"contact@c-bata.link"
] | contact@c-bata.link |
7466229e21a1f6ba95a9a8ae72f30c4c238f16fe | 9ecf6cfdc15b704b44688c533c5c6e9eccc5c0ab | /randomise-selected-objects-color.py | 181f6e92a57894fc3a910c380826c7c07f9afaf0 | [] | no_license | Bordilovskii/cinema4d-scripts | 96b1eab6aa442ef6ead105d22e0bab352d8563c9 | 811be702a64c8b0c97dedbbf95723ce0af06a7fa | refs/heads/master | 2020-03-27T06:37:25.692966 | 2018-07-04T09:30:18 | 2018-07-04T09:30:18 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 508 | py | import c4d
import random as rand
def main():
doc.StartUndo()
objs = doc.GetActiveObjects(0)
if len(objs) == 0:return
for obj in objs:
doc.AddUndo(c4d.UNDOTYPE_CHANGE,obj)
obj[c4d.ID_BASEOBJECT_USECOLOR] = 2
r = rand.random()
g = rand.random()
b = rand.r... | [
"rautio.arttu@gmail.com"
] | rautio.arttu@gmail.com |
24cdb1982f2fe439f8411d943177ebf9d46ba73e | 8d6ec0275afe856834bf10643e3b4b2cbcb318f4 | /03-online-shop/myshop/shop/views.py | 93982ce741c0abec344a2ff2ddd5db46f5ee1ff2 | [] | no_license | markronquillo/django-by-example | be35fbbc483440a11c440733931c146d56816c97 | fa749e5077f64ac68f11c7b529e13ac097cb5bd0 | refs/heads/master | 2021-01-11T14:38:40.854636 | 2017-02-24T03:09:58 | 2017-02-24T03:09:58 | 80,184,667 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 883 | py | from django.shortcuts import render, get_object_or_404
from .models import Category, Product
from cart.forms import CartAddProductForm
def product_list(request, category_slug=None):
category = None
categories = Category.objects.all()
products = Product.objects.filter(available=True)
if category_slug:
category... | [
"markronquillo23@gmail.com"
] | markronquillo23@gmail.com |
1fcb488242e10d0c03422d74916f668b21eb791b | 0e69513ca0fda765b5f655c4405aafb209491389 | /input/parse_pcm-dpc_it.py | 4492610a839245b4948d341f93c7abb1d5d1c339 | [] | no_license | adrianrequena/covid19 | 57a54fdaec79c0d1d57de63810e3337513e87b2f | a13cb2c117a68de2740702831f84c17049aa95ab | refs/heads/master | 2023-07-20T01:49:44.583897 | 2020-04-01T19:19:21 | 2020-04-01T19:19:21 | 252,279,864 | 0 | 0 | null | 2023-07-06T21:57:02 | 2020-04-01T20:28:35 | Python | UTF-8 | Python | false | false | 1,687 | py | #!/usr/bin/env python
import os
import sys
from pathlib import Path
from datetime import datetime, timedelta
import pandas
from utils import \
parse_level_args, github_raw_dataframe, github_raw_url, dataframe_output, merge_previous
# Root path of the project
ROOT = Path(os.path.dirname(__file__)) / '..'
# Th... | [
"oscar@wahltinez.org"
] | oscar@wahltinez.org |
43a3171c18f24f3e5cf493bcf8576ddb6b9456b6 | ebd2df05eae5875f3edd5c891442b9fe1f3d54ee | /empleados/views.py | 3b8388bd33952007db18e34edaecbd69330d2a7c | [] | no_license | gfcarbonell/app_navidad | 06191ef3b084d40c7a5f387a60407406c2c89d54 | fa290f8cf0b4b0d9237b555417fe38f879938adf | refs/heads/master | 2020-12-24T11:54:10.514150 | 2016-11-16T15:37:09 | 2016-11-16T15:37:09 | 73,115,163 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,364 | py | # -*- encoding: utf-8 -*-
from django.conf import settings
from django.views.generic import CreateView, UpdateView, ListView, DetailView
from .models import Empleado
from .forms import EmpleadoModelForm, EmpleadoUsuarioForm
from django.core.urlresolvers import reverse_lazy
from rest_framework import viewsets
from djang... | [
"r.gian.f.carbonell.s@gmail.com"
] | r.gian.f.carbonell.s@gmail.com |
26dace9da5168c53db1423f65ab53c70e82b7187 | d131ad1baf891a2918ae27b0dc57f3c0c1f99586 | /blog/migrations/0001_initial.py | ec6923c8ffb8cbccaa6e420a5a387c7af1f5ae91 | [] | no_license | Alymbekov/TestProjectForDjangoForms | d3bf24844628136f9236d5222d32235e87f7aecd | ce3262e7565e293b691ea70b94b67155c15525bd | refs/heads/master | 2020-04-10T05:35:19.516127 | 2018-12-07T14:24:05 | 2018-12-07T14:24:05 | 160,832,149 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 713 | py | # Generated by Django 2.1 on 2018-11-18 08:19
from django.db import migrations, models
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
name='Post',
fields=[
('id', models.AutoField(auto_... | [
"maxim.makarov.1997@mail.ru"
] | maxim.makarov.1997@mail.ru |
471b28b164af5875eb9670ed6bdea81faaa98ba6 | 9d1c9a81520437122d9f2f012c2737e4dd22713c | /src/td_clean.py | 0b0e3a8e8ad9f059d56a6f5f5dd04748362a15f8 | [
"MIT"
] | permissive | geophysics-ubonn/crtomo_tools | 136aa39a8a0d92061a739ee3723b6ef7879c57b8 | aa73a67479c4e96bc7734f88ac7b35a74b5d158c | refs/heads/master | 2023-08-24T01:55:29.517285 | 2023-08-08T13:03:46 | 2023-08-08T13:03:46 | 142,049,690 | 2 | 9 | MIT | 2019-06-06T12:46:42 | 2018-07-23T17:54:24 | Standard ML | UTF-8 | Python | false | false | 1,791 | py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Clean a simulation directory of all modeling/inversion files
"""
import numpy as np
import os
import glob
def main():
rm_list = []
required_files_inversion = (
'exe/crtomo.cfg',
'grid/elem.dat',
'grid/elec.dat',
'mod/volt.dat')
... | [
"mweigand@geo.uni-bonn.de"
] | mweigand@geo.uni-bonn.de |
fa2af2256e992f5dea361ca6dc8422c6d97e35d1 | 43ab33b2f50e47f5dbe322daa03c86a99e5ee77c | /rcc/models/study_events.py | 73804683abfe9626a9ff78782d4aa06520a3ae77 | [] | no_license | Sage-Bionetworks/rcc-client | c770432de2d2950e00f7c7bd2bac22f3a81c2061 | 57c4a621aecd3a2f3f9faaa94f53b2727992a01a | refs/heads/main | 2023-02-23T05:55:39.279352 | 2021-01-21T02:06:08 | 2021-01-21T02:06:08 | 331,486,099 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,338 | py | # coding: utf-8
"""
nPhase REST Resource
REDCap REST API v.2 # noqa: E501
The version of the OpenAPI document: 2.0
Generated by: https://openapi-generator.tech
"""
import pprint
import re # noqa: F401
import six
from rcc.configuration import Configuration
class StudyEvents(object):
"""NOT... | [
"thomas.yu@sagebase.org"
] | thomas.yu@sagebase.org |
07025217cb00bf91a6ba23c519d15a6c2bff30ad | 82a9077bcb5a90d88e0a8be7f8627af4f0844434 | /google-cloud-sdk/lib/tests/unit/api_lib/compute/instances/ops_agents/exceptions_test.py | 6315b0e3b6f56b2dd728bee1157215665d21febe | [
"LicenseRef-scancode-unknown-license-reference",
"Apache-2.0"
] | permissive | piotradamczyk5/gcloud_cli | 1ae2553595e569fad6ce84af62b91a7ee5489017 | 384ece11040caadcd64d51da74e0b8491dd22ca3 | refs/heads/master | 2023-01-01T23:00:27.858583 | 2020-10-21T04:21:23 | 2020-10-21T04:21:23 | 290,238,061 | 0 | 0 | null | 2020-10-19T16:43:36 | 2020-08-25T14:31:00 | Python | UTF-8 | Python | false | false | 1,861 | py | # -*- coding: utf-8 -*- #
# Copyright 2020 Google LLC. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless requir... | [
"code@bootstraponline.com"
] | code@bootstraponline.com |
80ffd316b9bbc8a682e4c8e9e842d3020e7a8472 | 545536daea315e31e01e388326e21a317f73dc6c | /Guddu on a Date.py | f390db81dd0b921ac0e786f7bc984075e63bfca0 | [] | no_license | calkikhunt/CODE_CHEF | 3cd4db7d2231dc31a045645da08c52a78edda6b6 | 81bb90368822bc77e70582ab3eae1a4244e6c80f | refs/heads/master | 2022-04-18T08:43:23.900118 | 2020-01-29T09:31:35 | 2020-01-29T09:31:35 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 805 | py | t=int(input())
for i in range(t):
ctrcopy=19
n=int(input())
ptr=0
while ptr<(n):
ctr=ctrcopy
check=str(ctrcopy)
doublecheck=str(ctrcopy+19)
sumdigi=0
while ctr>0:
use=ctr%10
ctr=ctr//10
sumdigi+=use
if sumdigi%10==0 and ... | [
"wimpywarlord@gmail.com"
] | wimpywarlord@gmail.com |
a17d7cd9fdcdc856d383afb6531cce96e9bb9932 | 1ff376da81912600e0f8b3d45ea061d9418a654c | /backend/weeklypulls/apps/series/models.py | 219c094f4f48347bc1312ed8e9e5114862031b13 | [] | no_license | rkuykendall/weeklypulls | 9c3448665b3a18cc0375ad40a60ad71008bb4e89 | e8300a6f28f6ce959130865e8bcf8c365033b2ce | refs/heads/master | 2021-01-17T19:51:43.702126 | 2017-12-18T12:16:28 | 2017-12-18T12:16:28 | 61,999,182 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,704 | py | import os
from django.db import models
from django.contrib.postgres.fields import ArrayField
import marvelous
from weeklypulls.apps.marvel.models import DjangoCache
class Series(models.Model):
series_id = models.IntegerField(unique=True)
read = ArrayField(models.IntegerField(), default=list)
skipped = ... | [
"robert@rkuykendall.com"
] | robert@rkuykendall.com |
9b7d397ba307c03c0cd50292f30ea2770a2a8816 | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p02623/s581456736.py | db739a5bab8b529088885d50f94a895ce4eb8e86 | [] | 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 | 713 | py | n, m, k = map(int, input().split())
a = list(map(int, input().split()))
b = list(map(int, input().split()))
a_num = 0
b_num = 0
book_num = 0
passed_k = 0
for i in range(n):
if a[i] + passed_k <= k:
a_num += 1
passed_k += a[i]
else:
break
for i in range(m):
if b[i] + passed_k <= k:
... | [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
881bf26ac89b923944c31b113c5a4250cb30de70 | 780c45da6388931381d911499723c5afa8a44036 | /run_test_c30.py | ce1a8a664e0893aa42c5eaf89ed0835150c1a6ad | [
"Apache-2.0"
] | permissive | daitouli/metaheuristics | f9157bd700957072a69c0be03d8d34378533581c | 9d885e4c9e9f39ad22baa9ea5d263d5daa276f88 | refs/heads/master | 2021-02-04T18:40:47.387347 | 2019-09-30T06:51:26 | 2019-09-30T06:51:26 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,520 | py | import pandas as pd
from models.multiple_solution.swarm_based.ABC import *
from models.multiple_solution.swarm_based.BMO import *
from models.multiple_solution.swarm_based.BOA import *
from models.multiple_solution.swarm_based.EPO import *
from models.multiple_solution.swarm_based.HHO import *
from models.multiple_solu... | [
"nguyenthieu2102@gmail.com"
] | nguyenthieu2102@gmail.com |
ed530e3765c93ad395a073bdba2ebcf9db8a922e | 2069ec66ace2e8fb5d55502d1c3ce7fd89f3cdcc | /fp2/example/write.py | 2835c40effeaaa01280a975bc1037885b60af898 | [] | no_license | caimingA/ritsumeiPython | 6812a0233456cf3d5346a63d890f4201160593c5 | bb9c39726dd26fe53f7a41f5367bdab60c36a057 | refs/heads/master | 2022-11-16T22:28:50.274374 | 2020-07-13T14:53:51 | 2020-07-13T14:53:51 | 279,294,544 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 301 | py | f = open("yuki.txt", mode="w", encoding="utf-8")
f.write("或冬曇りの午後、わたしは中央線の汽車の窓に一列の山脈を眺めてゐた。")
f.write("山脈は勿論まつ白だつた。")
f.write("が、それは雪と言ふよりも山脈の皮膚に近い色をしてゐた。")
| [
"caiming106@sina.com"
] | caiming106@sina.com |
91c38c6e741d31665a613aefbe52b741dad9f2d3 | e2f133885cfcea86a3c06bba2f1d4d165e50c823 | /api_test/main.py | eb2d68962d74199d1e2afd00f96adc2b336a3364 | [] | no_license | JR1QQ4/app_test | e0d9dc25ea03060d17dc7f29f30706ec4b8c16ea | 1c2ab9a5601e94a28f9bfe485e615d22511bb79b | refs/heads/main | 2023-05-25T14:55:53.326377 | 2021-06-08T14:33:52 | 2021-06-08T14:33:52 | 349,760,345 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 8,417 | py | #!/usr/bin/python
# -*- coding:utf-8 -*-
from time import sleep
from appium import webdriver
from appium.webdriver.common.mobileby import MobileBy
from appium.webdriver.common.touch_action import TouchAction
from appium.webdriver.extensions.android.gsm import GsmCallActions
from appium.webdriver.webdriver import WebDr... | [
"chenjunrenyx@163.com"
] | chenjunrenyx@163.com |
e232ea8556be487081ad7ae17a32d47bd88efdad | 31e6ca145bfff0277509dbd7c4b44b8deddf3334 | /LeetCode/Graph/combination-sum.py | 1bad4a940655a4357b9828e4c8a4c2eb18a168a3 | [] | no_license | brillantescene/Coding_Test | 2582d6eb2d0af8d9ac33b8e829ff8c1682563c42 | 0ebc75cd66e1ccea3cedc24d6e457b167bb52491 | refs/heads/master | 2023-08-31T06:20:39.000734 | 2021-10-15T10:51:17 | 2021-10-15T10:51:17 | 254,366,460 | 3 | 1 | null | null | null | null | UTF-8 | Python | false | false | 459 | py | class Solution:
def combinationSum(self, candidates: List[int], target: int) -> List[List[int]]:
result = []
def dfs(csum, index, path):
if csum < 0:
return
if csum == 0:
result.append(path)
return
for i in range(in... | [
"glisteneugene@gmail.com"
] | glisteneugene@gmail.com |
5588a9b58bb4811699015d008966309f1b432923 | 76a01339f7ca19536a07d66e18ff427762157a2a | /codeforces/Python/serval_and_bus.py | 49a999fb8f0c58c2e96f04c61667f1b963aee56a | [] | no_license | shaarangg/CP-codes | 75f99530921a380b93d8473a2f2a588dc35b0beb | 94fc49d0f20c02da69f23c74e26c974dfe122b2f | refs/heads/main | 2023-07-19T21:31:40.011853 | 2021-09-07T05:22:28 | 2021-09-07T05:22:28 | 332,644,437 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 282 | py | n,t = map(int,input().split())
m=10**9
j=0
for i in range(n):
s,d = map(int,input().split())
if(t<=s):
a=s-t
else:
a=t-s
if(a%d==0):
a=0
else:
a = (a//d + 1)*d -t + s
if(m>a):
m=a
j=i+1
print(j) | [
"shaaranggsingh@gmail.com"
] | shaaranggsingh@gmail.com |
a20ec095f9065df80a1ba32f675716abe0875c05 | 26c4426d2c9cd10fd7d4a73609512e69e31b64ba | /justone/mayflower/products/forms.py | 452a35e79f1ecaab5846dfb47812af7c3869b763 | [] | no_license | KirillUdod/html2exc | 550761213eb6edd7d3ea4787938cce65584606c3 | 60569f01822a15b2e5b6884a42774cd428953700 | refs/heads/master | 2021-01-15T17:07:05.906492 | 2016-01-06T11:51:38 | 2016-01-06T11:51:38 | 34,809,072 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,453 | py | from django import forms
from products.models import Bouquet
class DependenciesForm(forms.ModelForm):
def __init__(self, *args, **kwargs):
super(DependenciesForm, self).__init__(*args, **kwargs)
instance = getattr(self, 'instance', None)
dependencies = getattr(self.Meta.model, 'dependenci... | [
"kirilludod@gmail.com"
] | kirilludod@gmail.com |
ec1d8c4d661870efcce6dd2ea0b18baee2087b45 | f21109a5c23340447d0e3d34f14299c30e49d023 | /Dynamic Programming/11. Longest Common Subsequence.py | a8f0e898a3fad5f7001ac206032d7ee02a013de3 | [] | no_license | ShashankSinha98/FAANG-Questions | 45366004c3176a3c11ef554a25a11fe21e53ebca | 73ef742b3747e89d32d384baa6acf35044bf3ce0 | refs/heads/master | 2022-12-21T09:42:51.796086 | 2020-09-24T08:24:47 | 2020-09-24T08:24:47 | 286,765,370 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 598 | py | t = int(input())
def common_lcs(str1,n,str2,m):
dp = [[0]*(m+1) for i in range(n+1)]
for i in range(1,n+1):
for j in range(1,m+1):
if str1[i-1]==str2[j-1]:
dp[i][j] = dp[i-1][j-1] + 1
else:
dp[i][j] = max(dp[i-1][j],dp[i][j-1])
return d... | [
"34626597+ShashankSinha98@users.noreply.github.com"
] | 34626597+ShashankSinha98@users.noreply.github.com |
446d6d7faa595deb53a808126c8a2aced62533ca | 00b86f883694b17575a514227960b963d3b6179b | /Analysis/python/regions.py | fd5293018c7e89c2e26d88fe5e64bddca3efeb61 | [] | no_license | HephyAnalysisSW/TTZRun2EFT | 1b33a6bad49d0d6e119e49c74faa35dee0e4bb0e | 730a7465d4cbde52649965ed0e2a5b29bcc309c3 | refs/heads/master | 2020-04-30T16:40:46.454225 | 2019-04-18T08:09:46 | 2019-04-18T08:09:46 | 176,956,090 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,950 | py | from TTZRun2EFT.Analysis.Region import Region
from TTZRun2EFT.Analysis.Region import texString
from TTZRun2EFT.Analysis.Region import allowedVars
from math import pi
def getRegionsFromThresholds(var, vals, gtLastThreshold = True):
return [Region(var, (vals[i], vals[i+1])) for i in range(len(vals)-1)]
def getRegi... | [
"lukas.k.lechner@gmail.com"
] | lukas.k.lechner@gmail.com |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.