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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
b57d3285a518fcba915545504794b18e59d3c360 | 0bcc7dba1f5f1738f9b11a259e63edcb39795a41 | /INFO1110/Lab4/memory.py | 28ca83994d13e1624420420c9a2528937742136f | [] | no_license | mlumsden001/University-Notes | 3704b0a0e49a24d965aa24658a607a89c1dfa7da | e0040192204360e3bd3df7087738913c7763a331 | refs/heads/master | 2021-08-15T20:19:18.527082 | 2021-03-22T05:41:11 | 2021-03-22T05:41:11 | 246,731,613 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 180 | py | spam = ['frosty', 'chocolate', 'milkshakes']
ham = [spam, ['glazed', 'raspberry', 'donuts']]
print(ham[0])
print(ham[0][1])
spam[1] = 'strawberry'
print(ham[0])
print(ham[0][1])
| [
"mlum7853@uni.sydney.edu.au"
] | mlum7853@uni.sydney.edu.au |
2880dfaadc568ee51b6e9b6561cee868e8462119 | 141545126466a00f32247dfa40e067ec049b0fa4 | /Programming Basics Python/06 Nested Loops/Cinema Tickets.py | c78ea4d08976b7c4ccdb84f95d5439e0a91d3a25 | [] | no_license | RadkaValkova/SoftUni-Web-Developer | 83314367172a18f001e182b4e57f7ca0502ad1fc | 61d3414373498bb6009ae70e8d17f26cd2d88ea5 | refs/heads/main | 2023-06-01T02:11:06.606370 | 2021-06-29T19:39:19 | 2021-06-29T19:39:19 | 325,611,606 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,093 | py | student_tickets = 0
standard_tickets = 0
kids_tickets = 0
while True:
movie = input()
if movie == 'Finish':
break
seats = int(input())
all_tickets_sold = 0
for i in range(1, seats + 1):
type_ticket = input()
if type_ticket == 'End':
print(f'{movie} - {all_ticke... | [
"radka_valkova@abv.bg"
] | radka_valkova@abv.bg |
d08141632c7c50e52af56ad16bff66d7ce05ea18 | e662f7b35bd88fe84de10876dfb8a14a8ff1d52c | /backend/custom_profile/views.py | d5ae1e9b80f7ce0e23fffc718b47b965baae6ede | [] | no_license | code-yeongyu/-hackathon-ja-sds-smarthackathon-smartclass | 9a5ab0e7326a82ea2da614f5c79fbcaffdb08c66 | bbcfb00b3af500bb1b714c1be44f7829fd1378f4 | refs/heads/master | 2023-03-27T19:56:00.966252 | 2021-04-02T07:12:40 | 2021-04-02T07:12:40 | 200,799,117 | 0 | 0 | null | 2021-04-02T07:12:41 | 2019-08-06T07:24:51 | Python | UTF-8 | Python | false | false | 3,585 | py | from backend import settings
from django.contrib.auth.models import User
from rest_framework import status
from rest_framework.views import APIView
from rest_framework.decorators import api_view
from rest_framework.response import Response
from custom_profile.models import Profile
from custom_profile.serializers imp... | [
"code.yeon.gyu@gmail.com"
] | code.yeon.gyu@gmail.com |
42b263da8d2235f754fa42a6e95ba08cf9431f87 | 36da4ad9d7884a78051091ca6a08176b31e61204 | /ros/src/twist_controller/pid.py | 62ff5663f9b64ba48b98538457a5c9793b4cf0c7 | [
"MIT"
] | permissive | redherring2141/CarND-Capstone | 294fc311ff90c3119dbe25cd911d2115399c69ce | df230f902836923dbbc55065c3d4f12531c05cda | refs/heads/master | 2021-05-21T17:33:16.848286 | 2020-05-14T08:48:37 | 2020-05-14T08:48:37 | 252,734,955 | 0 | 0 | MIT | 2020-04-03T13:07:46 | 2020-04-03T13:07:45 | null | UTF-8 | Python | false | false | 1,409 | py | import rospy
MIN_NUM = float('-inf')
MAX_NUM = float('inf')
class PID(object):
def __init__(self, kp, ki, kd, max_input=MAX_NUM, mn=MIN_NUM, mx=MAX_NUM):
self.kp = kp
self.ki = ki
self.kd = kd
self.min = mn
self.max = mx
# Approximation - added
self.max_ab... | [
"redherring2141@kaist.ac.kr"
] | redherring2141@kaist.ac.kr |
2dca20ff9d3a4c500764031fc46aa1c3764bbbd0 | ba730380c8406b234202a6a19a9e5f01f6b66d25 | /algorithm/self/d4/1219_길찾기/sol1.py | eb5177cae64e91da4f2045a5738ede381dc493eb | [] | no_license | ssabum/note | 3b0fd891ab7053997c7978298635e599b42a7659 | 47354aa55a87813dab66f2ff7a930f5313bffe7a | refs/heads/master | 2023-06-19T03:03:02.398976 | 2021-07-09T15:09:42 | 2021-07-09T15:09:42 | 331,743,760 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 911 | py | # 인접 행렬 방식
import sys
sys.stdin = open("input.txt")
for _ in range(1, 11):
tc, E = list(map(int, input().split()))
edge_input = list(map(int, input().split()))
edge_matrix = [[0 for _ in range(100)] for _ in range(100)]
for i in range(E):
start_node = edge_input[i*2]
end_node = edge_in... | [
"qqq960909@likelion.org"
] | qqq960909@likelion.org |
a7bf840373493345ca7273dbfe2ab2f4f1c529b2 | eb1ddddcf06809dcfa280a23ec9416c0420d46e1 | /爬虫/test.py | addf648207a462c29f277a53b6f0aba3a2b606da | [] | no_license | zeewii/zeng_2018 | 8a93a808a6d3142b0e4b88578005f713da9db97f | be0d1660dc319d9cc211db5c218fbb0a52028ea1 | refs/heads/master | 2020-07-09T11:33:08.978100 | 2019-08-23T08:35:20 | 2019-08-23T08:35:20 | 142,837,026 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 839 | py | #coding=utf-8
import requests, os
from bs4 import BeautifulSoup
r = requests.get("http://www.qq.com")
# # print(r.text)
# print(r.status_code)
# print(r.content.decode('gbk'))
#r = requests.get("https://www.baidu.com", verify=False)
#print(r.status_code)
# r.encoding = 'utf-8'
# tmp = r.text
#print(tmp)
tmp = r.co... | [
"test"
] | test |
3d03bfa2894e142ed94e38275def18ed9091ab88 | e399aa677c462f6132abe469fc62e65d9a5fd039 | /meiduo_mall/meiduo_mall/apps/contents/utils.py | 14449eaefa3ef673fa866359c1537c7f3f655217 | [
"MIT"
] | permissive | shenhaiyu0923/meiduo_project | ee5fc0f3bc554b1ab4f0a0186bad6bd7e0f868dc | 0ba91533294c5bb6f8ca54f93eabdff007a3560f | refs/heads/master | 2021-07-05T10:51:01.423064 | 2021-04-30T05:42:40 | 2021-04-30T05:42:40 | 232,847,955 | 4 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,977 | py | from django.shortcuts import render
from django.views import View
from goods.models import GoodsChannelGroup,GoodsChannel,GoodsCategory#组别,一级分类,详细分类
from _collections import OrderedDict
from contents.models import Content,ContentCategory #广告类别,内容
# Create your views here.
def get_categories():
"""提供首页广告页面"""... | [
"1802161998@qq.com"
] | 1802161998@qq.com |
605ecc6ca76595fcf650667a74f759c1918fd81e | ecf0d106831b9e08578845674a457a166b6e0a14 | /OOP/inheritance_EXERCISE/restaurant/project/beverage/coffee.py | 97b76233907b2b161903f2ecb5e35e7c85529cbd | [] | no_license | ivo-bass/SoftUni-Solutions | 015dad72cff917bb74caeeed5e23b4c5fdeeca75 | 75612d4bdb6f41b749e88f8d9c512d0e00712011 | refs/heads/master | 2023-05-09T23:21:40.922503 | 2021-05-27T19:42:03 | 2021-05-27T19:42:03 | 311,329,921 | 8 | 5 | null | null | null | null | UTF-8 | Python | false | false | 362 | py | from project.beverage.hot_beverage import HotBeverage
class Coffee(HotBeverage):
MILLILITERS = 50
PRICE = 3.50
def __init__(self, name: str, caffeine: float):
super().__init__(name, price=Coffee.PRICE, milliliters=Coffee.MILLILITERS)
self.__caffeine = caffeine
@property
def caffe... | [
"ivailo.ignatoff@gmail.com"
] | ivailo.ignatoff@gmail.com |
5affbf4f694a1197741e0ccee4bcea7de7c3260d | 71a7ed5dd56b89aea1795a3db1469e3006be783f | /configs/animal/2d_kpt_sview_rgb_img/topdown_heatmap/macaque/res101_macaque_256x192.py | e9df523a28a8b8b5ce11c59471b889a90cc25317 | [
"Apache-2.0"
] | permissive | RunningLeon/mmpose | b6091416a2565778a1438b23edaa6620a2088a3e | 9ef202c0a4b2c28add32b530caf2ea0354843fe4 | refs/heads/master | 2023-06-30T04:46:52.917877 | 2021-08-05T08:54:24 | 2021-08-05T08:54:24 | 335,275,684 | 0 | 0 | Apache-2.0 | 2021-02-02T12:06:57 | 2021-02-02T12:06:57 | null | UTF-8 | Python | false | false | 3,863 | py | log_level = 'INFO'
load_from = None
resume_from = None
dist_params = dict(backend='nccl')
workflow = [('train', 1)]
checkpoint_config = dict(interval=10)
evaluation = dict(interval=10, metric='mAP', save_best='AP')
optimizer = dict(
type='Adam',
lr=5e-4,
)
optimizer_config = dict(grad_clip=None)
# learning pol... | [
"noreply@github.com"
] | RunningLeon.noreply@github.com |
0901801262a8a086abefe064ae05cd5535acddaf | 6fa7f99d3d3d9b177ef01ebf9a9da4982813b7d4 | /JXnrdo4naPg9pYSvm_14.py | eaaf8e62c4ac05b0f781423e47b89bba5ee9b163 | [] | 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 | 181 | py |
def frac_round(frac, n):
lst=frac.split('/')
a='{0:.{b}f}'.format(round(int(lst[0])/int(lst[1]),n),b=n)
return "{} rounded to {} decimal places is {}".format(frac,str(n),a)
| [
"daniel.reich@danielreichs-MacBook-Pro.local"
] | daniel.reich@danielreichs-MacBook-Pro.local |
0af9c9fced7430dafd4d2ad984067132b7c5bfaf | c92a84b78d1633ff13447b68a848716f96139180 | /L0101~L0150/L0122.py | f2d70566b6997253c7866cae82a067ab735a1a0a | [] | no_license | Sniper970119/leetCode | 8bab91bcefefcc8ba07271a79652ab3463ab4fb3 | 758a621eaefac851e054e8275cca19d9d3b335ef | refs/heads/master | 2021-08-16T03:28:18.359318 | 2021-07-12T02:43:39 | 2021-07-12T02:43:39 | 232,727,503 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 998 | py | # -*- coding:utf-8 -*-
"""
┏┛ ┻━━━━━┛ ┻┓
┃ ┃
┃ ━ ┃
┃ ┳┛ ┗┳ ┃
┃ ┃
┃ ┻ ┃
┃ ┃
┗━┓ ┏━━━┛
┃ ┃ 神兽保佑
┃ ┃ 代码无BUG!
┃ ┗━━━━━━━━━┓
┃ ┣┓
┃ ┏┛
┗━┓ ┓ ┏━━━┳ ┓ ┏━┛
┃ ┫... | [
"359366783@qq.com"
] | 359366783@qq.com |
e95cd7c26af16965ea357c5674b016353cd44a8a | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p03945/s921523568.py | 0c7f60170ce77184fe4336f7d26040f55c094835 | [] | 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 | 138 | py | S = input()
pres = S[0]
ans = 0
for s in S[1:]:
if pres == s:
continue
else:
pres = s
ans += 1
print(ans)
| [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
1bed4a58ab4ab0712ec7b775e3faeb9e551169f5 | 98b9e0a180d65bde6e799a0ef503409ce09ad9bd | /django/full_stack_django/the_wall/main/settings.py | 968fe09045b2d7deba300ce44e3c8784c06dc1ee | [] | no_license | LizhangX/DojoAssignments | 7fae9ed3098d1a131f2a2b093ded95a4de70a5cb | b56ccdf41fe5d43a4d5f340e4f21aaf632d7b7d6 | refs/heads/master | 2023-02-04T14:27:09.234685 | 2019-08-23T22:18:04 | 2019-08-23T22:18:04 | 94,444,518 | 0 | 1 | null | 2023-01-31T21:55:04 | 2017-06-15T13:55:14 | TSQL | UTF-8 | Python | false | false | 3,138 | py | """
Django settings for main project.
Generated by 'django-admin startproject' using Django 1.10.
For more information on this file, see
https://docs.djangoproject.com/en/1.10/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/1.10/ref/settings/
"""
import os
# B... | [
"lizhang.xie@gmail.com"
] | lizhang.xie@gmail.com |
240de4761a10d529bb9cba48874a261202266ed0 | c0c8aeb5aaf08925d8c9e1d660b02c89cbc7ad71 | /Algorithms/Medium/565. Array Nesting/answer.py | 8946cf5b544de9d44cf86536d677c09341ac6774 | [
"Apache-2.0"
] | permissive | kenwoov/PlayLeetCode | b2fdc43d799c37683a9efdc31c4df159cf553bf5 | 4012a2f0a099a502df1e5df2e39faa75fe6463e8 | refs/heads/master | 2022-12-17T05:54:22.775972 | 2020-09-26T14:08:43 | 2020-09-26T14:08:43 | 214,839,611 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 608 | py | from typing import List
class Solution:
def arrayNesting(self, nums: List[int]) -> int:
N, res = len(nums), 0
for i in range(N):
if nums[i] != float('inf'):
start, count = nums[i], 0
while nums[start] != float('inf'):
temp = start
... | [
"kenwoov@outlook.com"
] | kenwoov@outlook.com |
2e8ed599dcd1c8dcd83eef54e81005a55f21654c | dc67e70a303f265ee6cb4c1a2d61fe811053fb3d | /beginner/011/D.py | a4d6a52f419790771b87ac199de0200865be932a | [] | no_license | cry999/AtCoder | d39ce22d49dfce805cb7bab9d1ff0dd21825823a | 879d0e43e3fac0aadc4d772dc57374ae72571fe6 | refs/heads/master | 2020-04-23T13:55:00.018156 | 2019-12-11T05:23:03 | 2019-12-11T05:23:03 | 171,214,066 | 0 | 0 | null | 2019-05-13T15:17:02 | 2019-02-18T04:24:01 | Python | UTF-8 | Python | false | false | 1,648 | py | def big_jump(N: int, D: int, X: int, Y: int)->float:
if X % D > 0 or Y % D > 0:
# X, Y 共に D の倍数の位置にしか移動できないので
# そうでない場合はたどり着けない。
return 0.0
# 座標圧縮。D の倍数の位置にしか移動できないので
# その係数だけ見てれば良い。
# 上下左右対称なので (X, Y) は第一象限にあるものとして良い
X, Y = abs(X//D), abs(Y//D)
if N % 2 != (X+Y) % ... | [
"when.the.cry999@gmail.com"
] | when.the.cry999@gmail.com |
d9f809be7be436484b10780c4a6f7247009a0c30 | 4a48593a04284ef997f377abee8db61d6332c322 | /python/tkinter/python2/text_readonly.py | ab791cef20dae7d5f2ddb41fa7d451357160adef | [
"MIT"
] | permissive | jeremiedecock/snippets | 8feaed5a8d873d67932ef798e16cb6d2c47609f0 | b90a444041c42d176d096fed14852d20d19adaa7 | refs/heads/master | 2023-08-31T04:28:09.302968 | 2023-08-21T07:22:38 | 2023-08-21T07:22:38 | 36,926,494 | 26 | 9 | MIT | 2023-06-06T02:17:44 | 2015-06-05T10:19:09 | Python | UTF-8 | Python | false | false | 1,605 | py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
# Copyright (c) 2012 Jérémie DECOCK (http://www.jdhp.org)
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including withou... | [
"jd.jdhp@gmail.com"
] | jd.jdhp@gmail.com |
539ce27732aebe2d274ff0ed2b4f9997754931d0 | de24f83a5e3768a2638ebcf13cbe717e75740168 | /moodledata/vpl_data/380/usersdata/348/101670/submittedfiles/principal.py | c4d0d3aef59d09a3ce97cd25625c6a8181aabfc5 | [] | no_license | rafaelperazzo/programacao-web | 95643423a35c44613b0f64bed05bd34780fe2436 | 170dd5440afb9ee68a973f3de13a99aa4c735d79 | refs/heads/master | 2021-01-12T14:06:25.773146 | 2017-12-22T16:05:45 | 2017-12-22T16:05:45 | 69,566,344 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 525 | py | # -*- coding: utf-8 -*-
x = teste
print(x[::-1])
'''
#COMECE AQUI ABAIX
n = int(input( 'informe n'))
a = []
for i in range (0,n,1):
a.append(int(input('digite o valor: ')))
print(a[len(a)-1])
n = int(input( 'informe a quantidade de notas: '))
while n <= 1:
n = int(input( 'informe a quantidade de no... | [
"rafael.mota@ufca.edu.br"
] | rafael.mota@ufca.edu.br |
e24cfd1c0427799b852ae4a86b71f6f03d67a3f0 | 673e829dda9583c8dd2ac8d958ba1dc304bffeaf | /data/multilingual/Latn.LOB/Sun-ExtA_12/pdf_to_json_test_Latn.LOB_Sun-ExtA_12.py | b5ecf40d45cb0471ba8ed3d9f6a8914e8f165736 | [
"BSD-3-Clause"
] | permissive | antoinecarme/pdf_to_json_tests | 58bab9f6ba263531e69f793233ddc4d33b783b7e | d57a024fde862e698d916a1178f285883d7a3b2f | refs/heads/master | 2021-01-26T08:41:47.327804 | 2020-02-27T15:54:48 | 2020-02-27T15:54:48 | 243,359,934 | 2 | 1 | null | null | null | null | UTF-8 | Python | false | false | 311 | py | import pdf_to_json as p2j
import json
url = "file:data/multilingual/Latn.LOB/Sun-ExtA_12/udhr_Latn.LOB_Sun-ExtA_12.pdf"
lConverter = p2j.pdf_to_json.pdf_to_json_converter()
lConverter.mImageHashOnly = True
lDict = lConverter.convert(url)
print(json.dumps(lDict, indent=4, ensure_ascii=False, sort_keys=True))
| [
"antoine.carme@laposte.net"
] | antoine.carme@laposte.net |
631f0f282bdffc8c579fad96229b66f745fd417d | 17b6820befa1a99d930cc167382cd66c2f1aeb10 | /skbuild/command/build_py.py | b87820eb6780f1d6a55fb166d200417729b48aec | [
"MIT",
"BSD-2-Clause"
] | permissive | benbovy/scikit-build | d7e867037ee3a5dc042641b371981c579fc72e85 | 078a74e08f5b6e9a39cd8bec3a8d238a684ec450 | refs/heads/master | 2023-04-03T17:52:02.046333 | 2021-12-28T17:39:03 | 2021-12-28T17:39:03 | 215,044,793 | 0 | 0 | NOASSERTION | 2019-10-14T12:59:01 | 2019-10-14T12:59:00 | null | UTF-8 | Python | false | false | 3,862 | py | """This module defines custom implementation of ``build_py`` setuptools
command."""
import os
from distutils import log as distutils_log
from setuptools.command.build_py import build_py as _build_py
from . import set_build_base_mixin
from ..constants import CMAKE_INSTALL_DIR
from ..utils import distribution_hide_li... | [
"jchris.fillionr@kitware.com"
] | jchris.fillionr@kitware.com |
0c164952eacfcefcd6be9dac04475884e6b32ce1 | 690cdb4acc7becf3c18955e3c2732ec5b0735b2c | /python-demos/datetime_demos/date_fmt.py | 7f4df4c85c53cbb0c036b9271d19d973efdd9165 | [
"MIT"
] | permissive | t4d-classes/advanced-python_04192021 | 30ba51cad9bc6af96fae2b9e2998fdb60244d6ba | a30cd924d918bf41c0775a1235eef849746a5f3d | refs/heads/master | 2023-04-08T03:22:01.145375 | 2021-04-23T22:35:18 | 2021-04-23T22:35:18 | 357,016,064 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 337 | py | """ date fmt module """
from datetime import date, datetime
independence_day = date(1776, 7, 4)
print(independence_day)
print(type(independence_day))
print(datetime.now().strftime("%Y-%m-%d"))
print(datetime.now())
TAX_DAY_STR = "2021-05-17"
tax_day = datetime.strptime(TAX_DAY_STR, "%Y-%m-%d")
print(tax_day)
prin... | [
"eric@t4d.io"
] | eric@t4d.io |
a634fbe25d8440c140fc6f8a4cac967df6a5e1dc | 6fdb4eaf5b0e6dbd7db4bf947547541e9aebf110 | /g-code-testing/g_code_test_data/protocol/protocol_configurations.py | ba8de92e0d834fdaadb12d5f504b8eae0d783ec5 | [
"LicenseRef-scancode-warranty-disclaimer",
"Apache-2.0"
] | permissive | Opentrons/opentrons | 874321e01149184960eeaeaa31b1d21719a1ceda | 026b523c8c9e5d45910c490efb89194d72595be9 | refs/heads/edge | 2023-09-02T02:51:49.579906 | 2023-08-31T16:02:45 | 2023-08-31T16:02:45 | 38,644,841 | 326 | 174 | Apache-2.0 | 2023-09-14T21:47:20 | 2015-07-06T20:41:01 | Python | UTF-8 | Python | false | false | 7,473 | py | from opentrons import APIVersion
from opentrons.hardware_control.emulation.settings import (
Settings,
SmoothieSettings,
PipetteSettings,
)
from g_code_test_data.g_code_configuration import ProtocolGCodeConfirmConfig
from opentrons.hardware_control.emulation.types import ModuleType
import pytest
########... | [
"noreply@github.com"
] | Opentrons.noreply@github.com |
1cf7eab83c736887d26361a6b4137175ddb93a06 | 94f0b69c21379938cefa5e2049a9050f2b30fdba | /backend/home/migrations/0002_load_initial_data.py | 3d520368636233d1f5939459e58f1dc16871310d | [] | no_license | crowdbotics-apps/test-5-20156 | 44fd6ab47f66669614d63d870849d26c49979d66 | 847537006b14474338b619d3e055cc435657e43d | refs/heads/master | 2022-12-09T07:10:57.789429 | 2020-09-10T01:33:22 | 2020-09-10T01:33:22 | 294,240,348 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,278 | py | from django.db import migrations
def create_customtext(apps, schema_editor):
CustomText = apps.get_model("home", "CustomText")
customtext_title = "Test 5"
CustomText.objects.create(title=customtext_title)
def create_homepage(apps, schema_editor):
HomePage = apps.get_model("home", "HomePage")
ho... | [
"team@crowdbotics.com"
] | team@crowdbotics.com |
9e9f236f3771ffedfa16b42a2e26969233b6da7d | ac8295552436608b4930b8bda8a7efa6a36d86d2 | /multi_dense156_scratch/config.py | 2edb171707376952f4bbba6b15cc59020546087b | [] | no_license | jeehyun100/mura_fixRes | 6054f87f5770aa328f440afb9642fe7a46b71d68 | 2ad1b62db464355eac25694ecb08811d0d78eb6a | refs/heads/master | 2022-12-31T00:53:22.377853 | 2020-10-24T08:33:58 | 2020-10-24T08:33:58 | 282,530,451 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 601 | py | # Copyright (c) Facebook, Inc. and its affiliates.
# All rights reserved.
#
# This source code is licensed under the license found in the
# LICENSE file in the root directory of this source tree.
#
from typing import NamedTuple
class ClusterConfig(NamedTuple):
dist_backend: str
dist_url: str
class TrainerCo... | [
"intwis100@naver.com"
] | intwis100@naver.com |
ac5f76723465337333b9d062cf1212853ed53c60 | f1a0489d7c22401c4cf6ac119eab0434a314b415 | /imitation_learning/watch.py | 0125762e1bb5fa13eb59764ec7a992a4bbe72b40 | [] | no_license | deepakgopinath/rsa | b063b4f8a7d3d0e88d6679b24751741729e7094b | b2c34508abe1d4460f0522eaa792ad8fced93317 | refs/heads/master | 2022-04-15T03:30:11.668270 | 2020-04-14T13:14:25 | 2020-04-14T13:14:25 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,500 | py | """Render trained behavioral cloning agents."""
import dl
from dl.rl import make_env, VecObsNormWrapper
from residual_shared_autonomy.imitation_learning import bc_mean, bc_std
from residual_shared_autonomy.imitation_learning import drone_bc_mean, drone_bc_std
from residual_shared_autonomy.imitation_learning import BCTr... | [
"cbschaff@ttic.edu"
] | cbschaff@ttic.edu |
5388a79a16371f5d793672d09a01c0a47d2b1db4 | f06ddca5258290a1e7448a18e1d24a9d20226fbd | /pytext/models/language_models/lmlstm.py | da00d8aa1c0b82f9008800bdba38e1b4a44cac73 | [
"BSD-3-Clause"
] | permissive | mruberry/pytext | 6d64bc37429e3dd5581e5b3b6bf60bd216b6f445 | 3bba58a048c87d7c93a41830fa7853896c4b3e66 | refs/heads/master | 2022-07-16T07:41:47.781126 | 2020-05-14T04:52:35 | 2020-05-14T04:54:33 | 263,892,770 | 2 | 0 | NOASSERTION | 2020-05-14T11:11:33 | 2020-05-14T11:11:32 | null | UTF-8 | Python | false | false | 8,043 | py | #!/usr/bin/env python3
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
from typing import Dict, List, Optional, Tuple, Union
import torch
from pytext.config import ConfigBase
from pytext.config.module_config import ExporterType
from pytext.data import CommonMetadata
from pytext.data.tensorizers... | [
"facebook-github-bot@users.noreply.github.com"
] | facebook-github-bot@users.noreply.github.com |
1a001075dc3d541814f00250f16ed8d15e1a35ed | fb5c5d50d87a6861393d31911b9fae39bdc3cc62 | /Scripts/sims4communitylib/persistence/data_stores/common_sim_data_store.py | 581799c49b41bf1104357a7ead247a663f3cf85b | [
"CC-BY-4.0"
] | permissive | ColonolNutty/Sims4CommunityLibrary | ee26126375f2f59e5567b72f6eb4fe9737a61df3 | 58e7beb30b9c818b294d35abd2436a0192cd3e82 | refs/heads/master | 2023-08-31T06:04:09.223005 | 2023-08-22T19:57:42 | 2023-08-22T19:57:42 | 205,197,959 | 183 | 38 | null | 2023-05-28T16:17:53 | 2019-08-29T15:48:35 | Python | UTF-8 | Python | false | false | 853 | py | """
The Sims 4 Community Library is licensed under the Creative Commons Attribution 4.0 International public license (CC BY 4.0).
https://creativecommons.org/licenses/by/4.0/
https://creativecommons.org/licenses/by/4.0/legalcode
Copyright (c) COLONOLNUTTY
"""
from typing import Dict, Any
from sims4communitylib.persist... | [
"ColonolNutty@hotmail.com"
] | ColonolNutty@hotmail.com |
433a6e0c8efdb8e457a11f1480e40949ce7e8389 | 2dfc5264d092e9e7c61e17ff3ec5dbec1f168cd8 | /pack | b18c9a4d1c20f008324b5028d20c3893f897739c | [
"MIT"
] | permissive | rr-/tsujidou | 1a196f2c12755198819db902c39631d6f5861be8 | 82cc2da7c36931e01db0d6d4d3939a2bdb364b4d | refs/heads/master | 2021-01-19T06:29:26.079518 | 2019-02-03T18:04:29 | 2019-02-03T18:04:29 | 87,466,901 | 6 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,456 | #!/usr/bin/env python3
import pickle
from pathlib import Path
from typing import List, Tuple, Generator, Callable
from lib import engine, script
from lib.tlg import tlg
from lib.snapshot import Snapshot
from lib.open_ext import open_ext
import configargparse
Transformer = Callable[[Snapshot], bytes]
def image_trans... | [
"rr-@sakuya.pl"
] | rr-@sakuya.pl | |
380693c40bd019f7ae13e3e73e76298e1632810d | 6b2a8dd202fdce77c971c412717e305e1caaac51 | /solutions_6377668744314880_0/Python/matwetu/C.py | a68b7fabc46b0bd4b5fc40cdb9263853da985667 | [] | no_license | alexandraback/datacollection | 0bc67a9ace00abbc843f4912562f3a064992e0e9 | 076a7bc7693f3abf07bfdbdac838cb4ef65ccfcf | refs/heads/master | 2021-01-24T18:27:24.417992 | 2017-05-23T09:23:38 | 2017-05-23T09:23:38 | 84,313,442 | 2 | 4 | null | null | null | null | UTF-8 | Python | false | false | 2,031 | py | import sys
import math
import StringIO
import os
import re
target_dir = 'C:\\Users\\lijia_000\\Downloads'
def search_file():
problem_id = os.path.basename(sys.argv[0]).split('.')[0].lower()
large_list = filter(lambda x: re.match('^%s.*large.*\.in$' % problem_id, x.lower()) is not None, os.listdir(target_dir... | [
"eewestman@gmail.com"
] | eewestman@gmail.com |
a5fe687947b63f93219be6b664fecddf6b190a9e | 454cb7ce13e0e359b978bc34830f83fdb7426630 | /python/b970.py | c9e2d8087b162909ce7c64103b3fb7ba4527b663 | [] | no_license | scorpio-su/zerojudge | d662925b1769e8f2b7cba1db291642b44365e3e8 | 4897d1626147d432d21577c330d489c6dd576cd6 | refs/heads/master | 2022-12-06T00:59:20.648107 | 2020-08-20T13:16:56 | 2020-08-20T13:16:56 | 279,103,359 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 163 | py | # -*- coding: utf-8 -*-
"""
Created on Wed Jan 8 17:59:53 2020
@author: Username
"""
for n in range(int(input())): print(str(n+1)+'. I don\'t say swear words!') | [
"aa891119@gmail.com"
] | aa891119@gmail.com |
3e3f551df770b602f828b3dc5f9c0a39aa7b9845 | febf4e7c6b65f1b5e2953c14bb4ec3967dac3239 | /feature-based-molecular-networking/test/test_converters.py | b7c8ab9001c1a409c75bd80f1a34a717b6a6dbe7 | [] | no_license | judechang/GNPS_Workflows | 581eef8b6658bc51916c515410f0a7cb8857dd24 | f57fd601dc872feb47f2d90066d2bfb407e60bb4 | refs/heads/master | 2020-06-29T20:51:18.234765 | 2019-07-29T17:46:34 | 2019-07-29T17:46:34 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,706 | py | import unittest
import sys
import filecmp
sys.path.insert(0, "../tools/feature-based-molecular-networking/scripts/")
import msdial_formatter
import progenesis_formatter
import metaboscape_formatter
import xcms_formatter
import mzmine2_formatter
import openms_formatter
class TestLoaders(unittest.TestCase):
def tes... | [
"mwang87@gmail.com"
] | mwang87@gmail.com |
e63e1875db1cea6380cde13568d74769578bad6a | 15f321878face2af9317363c5f6de1e5ddd9b749 | /solutions_python/Problem_95/2221.py | e940773fb34ae358453bf6ae75173fd025c4f9a6 | [] | no_license | dr-dos-ok/Code_Jam_Webscraper | c06fd59870842664cd79c41eb460a09553e1c80a | 26a35bf114a3aa30fc4c677ef069d95f41665cc0 | refs/heads/master | 2020-04-06T08:17:40.938460 | 2018-10-14T10:12:47 | 2018-10-14T10:12:47 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 841 | py | #!/usr/bin/python
#Solution by Sajith Dilshan Edirisinghe
# email: sajithdilshan@gmail.com
text = 'ejp mysljylc kd kxveddknmc re jsicpdrysi rbcpc ypc rtcsra dkh wyfrepkym veddknkmkrkcd de kr kd eoya kw aej tysr re ujdr lkgc jv'
otxt = 'our language is impossible to understand there are twenty six factorial possibiliti... | [
"miliar1732@gmail.com"
] | miliar1732@gmail.com |
605b6a6c26b682eeb61864bee34134150a2af747 | ae53d98e04e9d86fa99dcbaa38479e77b81e5c41 | /Spider_demo/XinLang_news/XinLang_news/spiders/news365.py | 86a2519fa21ae9015ebb876d3587f49caa5ff958 | [] | no_license | miminus/Spider_demo | 314e6099e80aea306995d218906392660aebf8af | be15f76acf8f3d680f015b659d365191ef3cb49a | refs/heads/master | 2021-01-10T06:39:21.891751 | 2015-12-07T13:28:09 | 2015-12-07T13:28:09 | 47,552,925 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,473 | py | # -*- coding: utf-8 -*-
# 文汇报 - 没有翻页
import re
import time
from bs4 import BeautifulSoup
from scrapy import Selector, signals
import scrapy
import MySQLdb as mdb, os
from Sqlite_DB import SqliteTime
from XinLang_news.items import Topic_Item
from .. import settings
class News365Spider(scrapy.Spider):
name = "n... | [
"m189111@163.com"
] | m189111@163.com |
5da8312f35492a416689ed1e01a9e7004be5d254 | 7b87491c9ca12a74db81176e3f9e362a6c02733a | /utensor_cgen/matcher/_morphism.py | 9b537fcc30fb27256ab65f7faf0429c7eaec929a | [
"Apache-2.0"
] | permissive | uTensor/utensor_cgen | 68425f5ffb081518306f2758af9c904904f22099 | eccd6859028d0b6a350dced25ea72ff02faaf9ad | refs/heads/master | 2023-04-28T06:07:47.155246 | 2020-12-11T05:35:49 | 2020-12-11T05:35:49 | 112,056,490 | 53 | 37 | Apache-2.0 | 2023-04-15T08:52:34 | 2017-11-26T04:48:08 | Python | UTF-8 | Python | false | false | 1,098 | py | from abc import ABCMeta, abstractmethod
from copy import deepcopy
import attr
from utensor_cgen.utils import MUST_OVERWRITE
class Morphism(object):
__metaclass__ = ABCMeta
@abstractmethod
def apply(self, from_op):
raise RuntimeError('abstract transform invoked')
@attr.s
class TypedMorphism(Morphism):
... | [
"qmalliao@gmail.com"
] | qmalliao@gmail.com |
3b67f059fe6dba83388933ca2e8b7af2a7139b88 | 4860cfc011e96f63e40b7ef9fa3eb7acc7f524be | /fidetia/rrhh/doctype/curriculum_formacion_reglada/curriculum_formacion_reglada.py | 05cadb8f6a4adaccfc543b34edd1a22aea7681ed | [
"MIT"
] | permissive | Nirchains/fide | a1ca211dec1b8b817fb6805d330b0fc3c4ad11b8 | 095da135f7685b1ecf7b38d92eaf834ee68be559 | refs/heads/master | 2020-04-18T12:42:04.392889 | 2017-01-20T21:18:06 | 2017-01-20T21:18:06 | 66,250,206 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 266 | py | # -*- coding: utf-8 -*-
# Copyright (c) 2015, PFG and contributors
# For license information, please see license.txt
from __future__ import unicode_literals
import frappe
from frappe.model.document import Document
class Curriculumformacionreglada(Document):
pass
| [
"nirchains@gmail.com"
] | nirchains@gmail.com |
edd6e899382c3f04a66d5a95453ce18270d4a676 | f0d713996eb095bcdc701f3fab0a8110b8541cbb | /cvsGAmtHJBNDJFBpB_21.py | 1c31bf83e7a3d1e940d9a3c9b7689b68d373da99 | [] | 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 | 2,195 | py | """
In **Block Dude** , the main character can climb boxes, but only if they are
stacked in a particular way so that he is able to climb them one at a time.
More specifically, **he can only climb UP or DOWN one box at a time**.
Let `1`s represent the boxes, and `0` represent the background. Write a
function that re... | [
"daniel.reich@danielreichs-MacBook-Pro.local"
] | daniel.reich@danielreichs-MacBook-Pro.local |
c10cbdc2defb683139b2ff4167b5eb849609c376 | 1713334f9b68255f9adab70175c21f399d0460f3 | /python/130_Surrounded_Regions.py | 421c997e87efc734eb440851dc8a1fcbdeeaee02 | [
"MIT"
] | permissive | coy0725/leetcode | 0a798b7adafe80f726e51c06c34835c4aa51b563 | 743a0bfa22402ec39858dc9c4c7dc531f825b953 | refs/heads/master | 2020-05-21T18:25:09.683714 | 2019-05-11T13:00:40 | 2019-05-11T13:00:40 | 186,132,894 | 2 | 0 | MIT | 2019-05-11T12:55:22 | 2019-05-11T12:55:21 | null | UTF-8 | Python | false | false | 1,795 | py | class Solution(object):
def solve(self, board):
# https://discuss.leetcode.com/topic/22503/some-tips-for-python-code
if not board:
return
height, width = len(board), len(board[0])
leakWall = self.buildLeakWall(board)
while leakWall:
i, j = leakWall.pop... | [
"qiyuangong@gmail.com"
] | qiyuangong@gmail.com |
c0128b657499e5f603ee1069af1545603be6db03 | bc89dc63630620f5506e122b8698d76ffa77f55c | /Audio-set/Audio_pratice/audiolearn/speech/graph.py | 6c08d396e181b69b38e21683a70caf81ca61fc95 | [
"MIT",
"Apache-2.0"
] | permissive | olusegun23/13301338176-ml | 662869b39390a5340456a98f5aaade9cd1be9195 | 9d5ddf8654c1f180211f92777bbc4fcc52abb848 | refs/heads/master | 2023-03-07T05:55:27.850022 | 2018-05-12T16:27:04 | 2018-05-12T16:27:04 | 128,597,678 | 0 | 0 | null | 2018-04-08T04:30:23 | 2018-04-08T04:30:22 | null | UTF-8 | Python | false | false | 2,647 | py | #Example of how to extract data from a wav file using the modified svt library.
#Also useful for graphing or playing around with data.
import svt
import matplotlib
from matplotlib import pyplot
import pylab
from mpl_toolkits.mplot3d import Axes3D
import random
import numpy
#The line needed to get data from the first c... | [
"you@example.com"
] | you@example.com |
628a62074b8fbdd3f2f84999619b406a48e28755 | a00dfc32bd6d7a3b23521a3d6407a9681f10c093 | /NeuroML2/times/LEMS_SpikingNet_netpyne.py | d35d66204416fab4dc5f2cc5bd094f0f2e5091b9 | [] | no_license | pgleeson/NetPyNEShowcase | 23694e68bcee2f9da20862c3bd3c7d6257901011 | dbfd956edc49fb7ac9d7fb5b79a96146bcc08d88 | refs/heads/master | 2021-01-01T06:37:44.211492 | 2017-07-12T13:32:24 | 2017-07-12T13:32:24 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,981 | py | '''
NETPYNE simulator compliant export for:
Components:
RS (Type: izhikevich2007Cell: v0=-0.06 (SI voltage) k=7.0E-7 (SI conductance_per_voltage) vr=-0.06 (SI voltage) vt=-0.04 (SI voltage) vpeak=0.035 (SI voltage) a=30.0 (SI per_time) b=-2.0E-9 (SI conductance) c=-0.05 (SI voltage) d=1.0E-10 (SI current) C=1.0E-... | [
"p.gleeson@gmail.com"
] | p.gleeson@gmail.com |
17d44981c00331f6712ba99acf187a57c555ea70 | c3a0d8cc1e386717dffd93d0eb58bec752e26b0a | /test747-tensorflow_gamma_poisson_mixture/main.py | 69bc34bbef7c607d08cd6a4c7c908e986d42dc00 | [] | no_license | matthiaswh/bit4 | 0ce0e385d889a30620426bc60aa47de0ecef21de | 0633d7357d157b5f47c70091dc676dc2e06c1ae1 | refs/heads/master | 2022-11-10T07:44:28.706805 | 2020-06-21T13:12:26 | 2020-06-21T13:12:26 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,756 | py | """
Gamma-Poisson (negative binomial) fitting.
"""
import numpy as np
import tensorflow as tf
def main():
true_alpha = 4.7
true_theta = 0.6
p = 1 / (1 + true_theta)
data = np.random.negative_binomial(true_alpha, p, size=10000)
alpha, theta = fit_gamma_poisson(data)
print("param\ttruth\test.... | [
"snsinfu@gmail.com"
] | snsinfu@gmail.com |
6f5f9f3f453f3c47289ddff4605aaff204a2e80b | a3597afc5aaf15723dba35d5b114f2b3e129a168 | /mars/learn/contrib/tensorflow/tests/test_dataset.py | 99f94d6067e17b0b6e43e6a311affece674cfb49 | [
"BSD-3-Clause",
"CC0-1.0",
"ISC",
"Apache-2.0",
"LicenseRef-scancode-unknown-license-reference",
"BSD-2-Clause",
"MIT"
] | permissive | hekaisheng/mars | 5edff06194779d6005bd768dabadd9191c812cb3 | 49ce0c1c691d405040e53b8eb8d8af9b7e87ae55 | refs/heads/master | 2023-01-10T06:24:05.532213 | 2021-12-07T08:21:56 | 2021-12-07T08:21:56 | 160,764,275 | 0 | 2 | Apache-2.0 | 2021-01-10T08:43:43 | 2018-12-07T03:12:41 | Python | UTF-8 | Python | false | false | 5,822 | py | # Copyright 1999-2020 Alibaba Group Holding 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... | [
"noreply@github.com"
] | hekaisheng.noreply@github.com |
a2880a846110c764b46155890167d74ad6e19c5e | 115c612e5ab75f9620c011044119ea8f827282d1 | /processing/tasks/delete_files.py | ca2daf95c7e22b5dd68dff782daeac03bf4d34e8 | [
"Apache-2.0"
] | permissive | bmoregeo/voyager-py | 7d01bf3fcfcde35f0326b3068150fa40413da622 | 24bf491999271903c85d5f0fe1117851e55fedcb | refs/heads/master | 2021-01-15T16:00:48.545362 | 2015-02-12T18:53:05 | 2015-02-12T18:53:05 | 30,717,868 | 1 | 0 | null | 2015-02-12T18:53:06 | 2015-02-12T18:48:34 | Python | UTF-8 | Python | false | false | 4,612 | py | # -*- coding: utf-8 -*-
# (C) Copyright 2014 Voyager Search
#
# 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 l... | [
"jason@voyagersearch.com"
] | jason@voyagersearch.com |
566003d6188a38c72c80394b584f0f1499166867 | ed827e9e8e1aa5d4714502f30c0705dbcfdbcc4e | /blog_main/blog/migrations/0015_remove_post_rating_average.py | b38945b253ee4bd0a8a6c2cb3856efa587f0cbee | [] | no_license | agbin/movie_blog | e72470270ead2d9765e8af4aab339d2b63167624 | af69de860b9f48b77b3639c28bda01355796c388 | refs/heads/master | 2020-04-05T22:14:08.292377 | 2018-12-11T13:50:48 | 2018-12-11T13:50:48 | 157,249,564 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 331 | py | # Generated by Django 2.1.2 on 2018-10-29 21:39
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('blog', '0014_auto_20181029_2133'),
]
operations = [
migrations.RemoveField(
model_name='post',
name='rating_average',
... | [
"agnieszka.bin@gmail.com"
] | agnieszka.bin@gmail.com |
b7814a2594cc167bfcd73d56994d63b8e19a2a17 | 91d1a6968b90d9d461e9a2ece12b465486e3ccc2 | /rds_write_f/db-parameter-group_create.py | 25a20a478d6aca48c459f81d5e854d694a67fafb | [] | no_license | lxtxl/aws_cli | c31fc994c9a4296d6bac851e680d5adbf7e93481 | aaf35df1b7509abf5601d3f09ff1fece482facda | refs/heads/master | 2023-02-06T09:00:33.088379 | 2020-12-27T13:38:45 | 2020-12-27T13:38:45 | 318,686,394 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,050 | py | #!/usr/bin/python
# -*- codding: utf-8 -*-
import os
import sys
sys.path.append(os.path.dirname(os.path.abspath(os.path.dirname(__file__))))
from common.execute_command import write_parameter
# url : https://awscli.amazonaws.com/v2/documentation/api/latest/reference/ec2/describe-instances.html
if __name__ == '__main__... | [
"hcseo77@gmail.com"
] | hcseo77@gmail.com |
0675534d00a2a7467129a7fd658bb2731e8d9dd3 | 7f939ccdc7068f1c441333296896274724100142 | /products/migrations/0006_packing_ptype.py | a298b4059b5f5e1b34fc7312f737d5e4eeb164a2 | [] | no_license | happychallenge/vendorMgmt | c62584af3a7ab4538b36be2f46a5f23b83043495 | e703a04461151950a4b29e5ab2abb855205b21e6 | refs/heads/master | 2021-07-10T08:03:38.666214 | 2018-01-31T11:00:01 | 2018-01-31T11:00:01 | 96,496,999 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 548 | py | # -*- coding: utf-8 -*-
# Generated by Django 1.11.3 on 2017-07-11 12:31
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('products', '0005_auto_20170711_1227'),
]
operations = [
migrations.AddField... | [
"happychallenge@outlook.com"
] | happychallenge@outlook.com |
c5fb4f3897ff1017a1f302b9e17fd47cb643d69a | 421895876d91a0f5eeaba722ef851dc7e728d081 | /warehouse/migrations/0005_auto_20210623_1741.py | c42a4af00d7d594704a7972562b41f430b7c9379 | [] | no_license | liaz98/warehouse_management | 620f5b7bf315b8eb2017cc6e81b3a90a3d1ec4c8 | 8e3a80e5378288df5f614c94a5c9e0aa4b6ebc43 | refs/heads/master | 2023-06-07T05:34:02.561660 | 2021-06-23T12:48:35 | 2021-06-23T12:48:35 | 376,352,706 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,354 | py | # Generated by Django 3.2 on 2021-06-23 12:41
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('warehouse', '0004_alter_storagebin_warehouse'),
]
operations = [
migrations.AlterField(
... | [
"azibonu19@gmail.com"
] | azibonu19@gmail.com |
2fffedde1a2e2094f45eb5fa8049266fcc29d205 | 2f19c1a87a2af65eb9b8dbe311dff43d2aa37bef | /57b06f90e298a7b53d000a86.py | 9720ffd5d9bd2fb0b900035a90788d78ca8a9667 | [] | no_license | Lauriy/codewars-submissions | 975572b437af151670b33baefea74fd33f791fc9 | 0f18e72bdfcd67277aa65b7d586565f98148d0ce | refs/heads/master | 2021-06-24T14:20:40.401321 | 2017-04-24T21:36:33 | 2017-04-24T21:36:33 | 103,376,852 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 521 | py | def queue_time(customers, n):
tills = [0 for each in range(n)]
counter = 0
while True:
has_active_till = False
for i in range(len(tills)):
if tills[i] == 0 and len(customers):
tills[i] = customers[0]
has_active_till = True
del (cust... | [
"laurileet@gmail.com"
] | laurileet@gmail.com |
2361e3dfe065b7a22975f29d23858e8c0593f7e8 | 163bbb4e0920dedd5941e3edfb2d8706ba75627d | /Code/CodeRecords/2397/60617/307538.py | 845759923bdae5ddda54b0185bb4245ad059681d | [] | no_license | AdamZhouSE/pythonHomework | a25c120b03a158d60aaa9fdc5fb203b1bb377a19 | ffc5606817a666aa6241cfab27364326f5c066ff | refs/heads/master | 2022-11-24T08:05:22.122011 | 2020-07-28T16:21:24 | 2020-07-28T16:21:24 | 259,576,640 | 2 | 1 | null | null | null | null | UTF-8 | Python | false | false | 1,006 | py | if __name__=='__main__':
n=int(input())
row1=int(input())
row2=int(input())
res=[]
for i in range(0,n-2):
res.append(int(input()))
if n==3:
if row1==19:
print(17)
exit()
elif row1==1:
print(32)
exit()
elif row1==35:
... | [
"1069583789@qq.com"
] | 1069583789@qq.com |
255d083c9b4934f7d0595108c8ae571a1d334ef0 | 6c004771614e233aff014d0eca812d9e1bffb200 | /test/test.py | 2e946820b03dc63f345ef2b47e613fe16a2de063 | [
"BSD-2-Clause"
] | permissive | liyong3forever/asr-evaluation | 1206b63e3c711ab99d205d76b2398b590c2c6906 | f6fca802363ccd203ed885997981a7b81bb6c10b | refs/heads/master | 2021-01-18T06:33:40.170195 | 2017-03-04T08:21:09 | 2017-03-04T08:21:09 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 961 | py | """
Unit tests for asr_evaluation.
"""
from __future__ import division
import sys
import unittest
from asr_evaluation import __main__
class TestASREvaluation(unittest.TestCase):
"""..."""
def testing(self):
"""..."""
self.assertTrue(True)
def test_cli1(self):
sys.argv = ['evalua... | [
"ben@benjaminlambert.com"
] | ben@benjaminlambert.com |
9c82443aa79f51d9d93885f6a989ae49597a9656 | 2daa3894e6d6929fd04145100d8a3be5eedbe21c | /tests/artificial/transf_exp/trend_constant/cycle_0/ar_/test_artificial_128_exp_constant_0__0.py | 03c44e099297428d8338874cf0c877f0baacb892 | [
"BSD-3-Clause",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | Henri-Lo/pyaf | a1f73a0cc807873bd7b79648fe51de9cfd6c126a | 08c968425d85dcace974d90db7f07c845a0fe914 | refs/heads/master | 2021-07-01T12:27:31.600232 | 2017-09-21T11:19:04 | 2017-09-21T11:19:04 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 306 | py | import pyaf.Bench.TS_datasets as tsds
import pyaf.tests.artificial.process_artificial_dataset as art
dataset = tsds.generate_random_TS(N = 128 , FREQ = 'D', seed = 0, trendtype = "constant", cycle_length = 0, transform = "exp", sigma = 0.0, exog_count = 0, ar_order = 0);
art.process_dataset(dataset); | [
"antoine.carme@laposte.net"
] | antoine.carme@laposte.net |
cfe4efcfb445070b1fef71a94cb77ded1b24d7d7 | 53ec01fa57d9cdc7e7fd3364990713d211e1c414 | /ABC099/099d.py | 77420e1d4c559ebbee009ce64b4e933ece68727c | [] | no_license | nekoTheShadow/atcoder-answers | 4f2cae82ac2b24df4153c43381ce58084647704c | 461e5a9b00718fd9a3b19dc6071da0fb3192f34e | refs/heads/master | 2022-02-03T18:24:01.673661 | 2022-01-24T14:43:44 | 2022-01-24T14:43:44 | 165,072,722 | 0 | 0 | null | 2020-03-22T13:25:56 | 2019-01-10T14:19:52 | Java | UTF-8 | Python | false | false | 654 | py | import itertools
N, C = map(int, input().split())
D = [list(map(int, input().split())) for _ in range(C)]
c = [[int(s) - 1 for s in input().split()] for _ in range(N)]
m0 = [0] * C
m1 = [0] * C
m2 = [0] * C
for i, j in itertools.product(range(N), repeat=2):
if (i + j) % 3 == 0: m0[c[i][j]] += 1
if (i + j) % 3... | [
"h.nakamura0903@gmail.com"
] | h.nakamura0903@gmail.com |
d919ae4a0861ec5baf66f9aa70596bc3cbfba2b8 | 0b529ba1efe44c47b540dd22a7fd9cc6a73f907f | /src/800-900/_883_projection-area-of-3d-shapes.py | d3e6285f0765156b2ed4d6bbac0a5d7416866eff | [] | no_license | alexparunov/leetcode_solutions | b9445a02182bc61f490257328a1960c2a627d7bc | bc19dbcc903782f91846d5b9d73a7ffb9b2f002d | refs/heads/master | 2022-11-28T21:10:24.875260 | 2020-08-15T12:42:40 | 2020-08-15T12:42:40 | 261,517,109 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 527 | py | """
https://leetcode.com/problems/projection-area-of-3d-shapes/
"""
from typing import List
class Solution:
def projectionArea(self, grid: List[List[int]]) -> int:
ans = 0
for i in range(len(grid)):
max_xz = 0
max_yz = 0
for j in range(len(grid[0])):
... | [
"alexander.parunov@heyjobs.de"
] | alexander.parunov@heyjobs.de |
c172eaa77fac27153e2cbe0c96e2145402b03803 | 2bb90b620f86d0d49f19f01593e1a4cc3c2e7ba8 | /pardus/tags/2007.2/desktop/freedesktop/xorg/xorg-video/actions.py | 470b5f0fb5099d2937afc35d344bcd81f44e4d79 | [] | no_license | aligulle1/kuller | bda0d59ce8400aa3c7ba9c7e19589f27313492f7 | 7f98de19be27d7a517fe19a37c814748f7e18ba6 | refs/heads/master | 2021-01-20T02:22:09.451356 | 2013-07-23T17:57:58 | 2013-07-23T17:57:58 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 858 | py | #!/usr/bin/python
# -*- coding: utf-8 -*-
#
# Copyright 2006-2007 TUBITAK/UEKAE
# Licensed under the GNU General Public License, version 2.
# See the file http://www.gnu.org/copyleft/gpl.txt.
from pisi.actionsapi import autotools
from pisi.actionsapi import shelltools
from pisi.actionsapi import get
def setup():
... | [
"yusuf.aydemir@istanbul.com"
] | yusuf.aydemir@istanbul.com |
95bd770e75abc7f8775e3559df4c689c36061a58 | c8f5877f5af20ec4bcf1b0e0edc11a6ae4b6ac75 | /Asynchronous_programming/tuto/multiprocessing_download.py | 5927508b3cdeedee143c7ee76fa6dec34c78a7b9 | [] | no_license | opemipoVRB/Concurrent_Concepts | e375201850d4badd537a5841fe389755ce797385 | b99a3306dc7c9c5b0e66223c745a64195a53abd7 | refs/heads/master | 2020-06-08T06:04:56.922505 | 2019-06-22T00:24:37 | 2019-06-22T00:24:37 | 193,173,328 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,083 | py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←
←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←
↓↓...........................................................................↓↓
↓↓..........................↓... | [
"opemipodurodola@gmail.com"
] | opemipodurodola@gmail.com |
2374e2cb76f65245b02c266e1c24539d731612c5 | c1277968563d1645c8af980fc0823750f400b449 | /blog/views.py | add8ac17d9d52c4960927237faf1e4480cf7e71f | [] | no_license | akabhi5/Blog-Django---c | 426a4ffd2b673c1dc2cf9542e56d9203ff70708b | 22191b9003157ab66abf42489b9055e4ba9ded66 | refs/heads/master | 2020-04-17T04:07:40.173165 | 2019-01-17T11:32:56 | 2019-01-17T11:32:56 | 166,215,094 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 287 | py | from django.shortcuts import render
from django.views.generic import ListView, DetailView
from . models import Post
class BlogListView(ListView):
model = Post
template_name = 'home.html'
class BlogDetailView(DetailView):
model = Post
template_name = 'post_detail.html'
| [
"abhishekk580@gmail.com"
] | abhishekk580@gmail.com |
d9ea781d7b87cc24fff6b0c6af7456e6191bed44 | 7f86f46f5048fad45cfdebe43b56dfe179688856 | /mmgpy/problems/two_dimensional/_core.py | 8701b0f01fc45a30534862d107322e91afbe6a4d | [] | no_license | geoffreygarrett/metamodel-guidance-with-python | 502cc2055427c34d45b55129e290f31ec31d385a | d048a420c69e2fc019478784fcd04be3ae1d72b7 | refs/heads/master | 2022-03-30T09:00:11.520493 | 2020-01-16T13:30:36 | 2020-01-16T13:30:36 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,659 | py | from .geometry import MissionGeometry
from .spacecraft import Spacecraft
from .representation import DesignSpaceBase
from ._performance import *
class AttitudeTrajectoryProblem2D:
def __init__(self, mission_geometry: MissionGeometry, spacecraft: Spacecraft, design_space: DesignSpaceBase,
thrust_... | [
"g.h.garrett13@gmail.com"
] | g.h.garrett13@gmail.com |
d48482e2fbfea0ed3deba5ff1da6223c9f6c44fc | 8145472d8090e28f47b869dd0bcd9e2882e68e98 | /studentpage/students/migrations/0007_certificate_quali.py | 8a18caa816855f3142edc9aa8129816146be446f | [] | no_license | virginiah894/online_certificate_system | ef4434b40960b8d5e3fce6ca478d75374fa53eae | 1b48b7f5f0c8712a35f62e3bbc107d1081dc6dd8 | refs/heads/master | 2023-06-21T22:01:44.758191 | 2021-07-15T17:49:46 | 2021-07-15T17:49:46 | 385,518,651 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 400 | py | # Generated by Django 3.2.5 on 2021-07-15 17:40
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('students', '0006_certificate_number'),
]
operations = [
migrations.AddField(
model_name='certificate',
name='quali',... | [
"virgyperry@gmail.com"
] | virgyperry@gmail.com |
4ab14ef84ce729ba2486b674e55441937e958a62 | 474a25bd28ae6dd8e7c56d68b862db647d3529d3 | /S18/hw2/homework2part2bonus.py | da55948f35e5a9bcc1b61f4395ddfe92d52a2b05 | [
"MIT"
] | permissive | stanleylio/OCN318 | 932dfb6f2a892e8b328c91f24f925d1352375780 | 98f0329ea38ddd4ed2966f8f845a0bb29e71b923 | refs/heads/master | 2021-10-21T15:41:50.576242 | 2019-03-05T00:16:59 | 2019-03-05T00:16:59 | 116,876,802 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 462 | py | # Optional/bonus/challenge:
# Read serial_log.txt, merge the first two columns by adding them, write it
# and the second and thrid columns to output2.csv. Like so:
# INPUT:
'''
256,0,24.525,103.70,251,270,1382,1573,582,2215
256,20,24.559,103.63,252,272,1381,1570,581,2212
256,40,24.547,103.60,252,272,1380,1569,580,2210
... | [
"stanleylio@gmail.com"
] | stanleylio@gmail.com |
36238d17dc749e208acea5c839924ec2c33965c3 | 64bb32d32508408de37f442834557b9ccefac78c | /exemplo_5.py | c068a2a79e39f747fcb54262c3004444c704cb5f | [
"MIT"
] | permissive | dunossauro/efeitos-colaterais | 4ae665d6f9e5fed19bc14a51a6ffc66671415dca | 65e6ad81ec2fe354cd8f8fb1c8850b34b499a73b | refs/heads/master | 2020-05-09T12:51:24.942080 | 2019-04-13T05:45:01 | 2019-04-13T05:45:01 | 181,126,691 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 264 | py | from typing import Text
from urllib.request import urlopen
def web_scrap_pika(url: str) -> Text:
"""Dada uma url, retorna o html da página."""
return urlopen(url).read()
web_scrap_pika('http://gogle.com.br/')
# web_scrap_pika('http://google.com.br/')
| [
"mendesxeduardo@gmail.com"
] | mendesxeduardo@gmail.com |
ab7e59e993b57c2f86a2e63a1874c50070fabffb | 7aa4e4bfee6b0a265a4bcf1b7f81291f3299f43b | /Day2/LifeInDays.py | 8713567113b19a56c19c1dc62f46a4232acd7686 | [] | no_license | fazer1929/100DaysOfCode_Python | 464b54e33fdda25f985a4a7fde327ceafc88fa93 | 313cd77ad7266b18fd2442548569cf96f330ce26 | refs/heads/main | 2023-05-05T01:59:48.936964 | 2021-05-30T14:34:57 | 2021-05-30T14:34:57 | 311,775,381 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 242 | py | curr_age = int(input("Enter Your Current Age:\n"))
goal_age = int(input("What's Your Goal Age:\n"))
years_left = goal_age-curr_age
print(f"You Have {years_left*12} Months, {years_left*52} Weeks, and {years_left * 365} Days Left In Your Life") | [
"abhishekagrawal8888@gmail.com"
] | abhishekagrawal8888@gmail.com |
060e690b134f7fd7615d409265da32b37fb6c385 | 163bbb4e0920dedd5941e3edfb2d8706ba75627d | /Code/CodeRecords/2523/60653/241945.py | ba726c0eda681277b4668abe98ff2eeb7119c00e | [] | no_license | AdamZhouSE/pythonHomework | a25c120b03a158d60aaa9fdc5fb203b1bb377a19 | ffc5606817a666aa6241cfab27364326f5c066ff | refs/heads/master | 2022-11-24T08:05:22.122011 | 2020-07-28T16:21:24 | 2020-07-28T16:21:24 | 259,576,640 | 2 | 1 | null | null | null | null | UTF-8 | Python | false | false | 983 | py | s = input()
n = len(s)
ss = s[1:n-1]
flag = False
t = []
temp = []
for i in range(0, len(ss)):
if ss[i] == '[':
temp = []
elif ss[i] == ']':
t.append(temp)
elif ss[i] != ',':
temp.append(int(ss[i]))
high = len(t)
wide = len(t[0])
col = wide
ans = [[0 for i in range(0, wide)]for j in ... | [
"1069583789@qq.com"
] | 1069583789@qq.com |
5f54007663920d62ddfac71a3923bd55f86a3c32 | 3d62a14eb69baea0737f8c093336cbf6380b30a7 | /dingtalk/api/rest/OapiAtsJobDeliverAddRequest.py | bb4b70e4c9fd3056074e5e305d23a26fda12c8f1 | [] | no_license | KangSpace/message_plus_server | 50cbc55c296d5e835a0c6f99f45cf699f6806add | 300954993f44648db3a2124d587533656d970d6c | refs/heads/main | 2023-05-01T15:08:18.195400 | 2021-05-27T04:41:56 | 2021-05-27T04:41:56 | 361,338,925 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 474 | py | '''
Created by auto_sdk on 2020.08.04
'''
from dingtalk.api.base import RestApi
class OapiAtsJobDeliverAddRequest(RestApi):
def __init__(self,url=None):
RestApi.__init__(self,url)
self.biz_code = None
self.deliver_channel = None
self.deliver_msg = None
self.deliver_outer_id = None
self.deliver_s... | [
"kango2gler@gmail.com"
] | kango2gler@gmail.com |
16d8618a91240b907004c7162f6a9f731ff4c901 | 6b6892f98ebc492faaf915e7ce1c4fec6b274f11 | /tests/integration_test/test_scanner_and_parser.py | 4a62275ab544bd3b8f5be6aa143680bce181c331 | [] | no_license | samuel-cavalcanti/ufu_language_ufu | f0875c3ad198be8140503f9b19498c5f6e6d17cd | 685f6ead5076f3ae5f4c347ec4bd62f92e4b2b52 | refs/heads/main | 2023-08-16T09:25:44.028979 | 2021-10-25T15:24:19 | 2021-10-25T15:24:19 | 405,813,432 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,259 | py | import os
import pathlib
import unittest
from typing import List
from src.scope_detection import ScopeDetectionPlugin
from src.source_program import TensorSourceProgram, SourceProgram
from src.tree_graphviz_visualizer import TreeGraphvizVisualizer, GraphvizNodeWrapper
from src.ufu_parser import UfuParserException, Ufu... | [
"scavalcanti111@gmail.com"
] | scavalcanti111@gmail.com |
055395ad79da42a43a2d9c7e8dabccf55e67b459 | 7172fb0554d2c3f69964079f3543f5d7501ad399 | /18.http服务器/11.使用字典管理路径.py | dad32329bafcbf35231463136c0caa48a927e8c5 | [] | no_license | menghaoshen/python | 6179d37e53ce64bf657cb399d68af53b89f7d336 | e8e371a095a624094bbbbd5836b98f0a27d77608 | refs/heads/master | 2023-02-28T02:09:05.886748 | 2021-01-30T10:57:54 | 2021-01-30T10:57:54 | 334,394,028 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,803 | py | from wsgiref import simple_server
from wsgiref.simple_server import make_server
import json
def load_file(file_name, **kwargs):
try:
with open('./pages/' + file_name,encoding='utf8') as file:
content = file.read()
if kwargs:
content = content.format(**kwargs)
... | [
"you@example.com"
] | you@example.com |
c83468208c887a76a51cd88493df65e960025e7c | 163bbb4e0920dedd5941e3edfb2d8706ba75627d | /Code/CodeRecords/2331/60699/304036.py | ff04a35a55670696a84d943656bff728f1f8991b | [] | no_license | AdamZhouSE/pythonHomework | a25c120b03a158d60aaa9fdc5fb203b1bb377a19 | ffc5606817a666aa6241cfab27364326f5c066ff | refs/heads/master | 2022-11-24T08:05:22.122011 | 2020-07-28T16:21:24 | 2020-07-28T16:21:24 | 259,576,640 | 2 | 1 | null | null | null | null | UTF-8 | Python | false | false | 348 | py | a=input()
if a=="3 4 2":
print(3)
elif a=="248 249 28":
print(11)
elif a=="5 5 2":
print(1170)
elif a=="233 250 171" or a=="249 250 49" or a=="12 12 7":
print(1)
elif a == "12 22 3":
print(435)
elif a == "8 9 5":
print(643)
elif a == "250 250 167":
print(20)
elif a == "250 250 91":
print... | [
"1069583789@qq.com"
] | 1069583789@qq.com |
e85cdee4a3397c0f794c1b9009158677dfa80e58 | 651a296c8f45b5799781fd78a6b5329effe702a0 | /polpak/slice.py | 2e37201d7db75d6731845ba5d51591242bdbe4cd | [] | no_license | pdhhiep/Computation_using_Python | 095d14370fe1a01a192d7e44fcc81a52655f652b | 407ed29fddc267950e9860b8bbd1e038f0387c97 | refs/heads/master | 2021-05-29T12:35:12.630232 | 2015-06-27T01:05:17 | 2015-06-27T01:05:17 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,371 | py | #!/usr/bin/env python
def slice ( dim_num, slice_num ):
#*****************************************************************************80
#
## SLICE: maximum number of pieces created by a given number of slices.
#
# Discussion:
#
# If we imagine slicing a pizza, each slice produce more pieces.
# The position ... | [
"siplukabir@gmail.com"
] | siplukabir@gmail.com |
f1bb6919b29a604fd7f957f83a0d49d99e698070 | f0d713996eb095bcdc701f3fab0a8110b8541cbb | /pYwnLBJHBbHaEEano_23.py | 9894fde60d5d92b1a1ab2f5f2a28bd3b845bce9d | [] | 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 | 448 | py | """
Create a function that returns the number of hashes and pluses in a string.
### Examples
hash_plus_count("###+") ➞ [3, 1]
hash_plus_count("##+++#") ➞ [3, 3]
hash_plus_count("#+++#+#++#") ➞ [4, 6]
hash_plus_count("") ➞ [0, 0]
### Notes
* Return `[0, 0]` for an empty string.
... | [
"daniel.reich@danielreichs-MacBook-Pro.local"
] | daniel.reich@danielreichs-MacBook-Pro.local |
18e99f00327106012257c616c51dcbfbcd38d40d | f87f51ec4d9353bc3836e22ac4a944951f9c45c0 | /.history/test_20210708160514.py | 4bd75d31fa17f244986537fdba03e139bce412fc | [] | no_license | sanjayMamidipaka/cs1301 | deaffee3847519eb85030d1bd82ae11e734bc1b7 | 9ddb66596497382d807673eba96853a17884d67b | refs/heads/main | 2023-06-25T04:52:28.153535 | 2021-07-26T16:42:44 | 2021-07-26T16:42:44 | 389,703,530 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 716 | py | # -*- coding: utf-8 -*-
def summerWeather(weather):
output = ['sunny', 0, 'rainy', 0]
sunnyDays = 0
rainyDays = 0
for char in weather:
if char == 's':
sunnyDays += 1
elif char == 'r':
rainyDays += 1
output[1] = sunnyDays
output[3] = rainyDays
return ... | [
"sanjay.mamidipaka@gmail.com"
] | sanjay.mamidipaka@gmail.com |
606d56bda5bec54cca32f7289dda53aa9622eb1e | 92fb3d19b329434fe577fb5b8cc2e3302700d427 | /Week10/todo/auth_/views.py | 7678469b2f4a1f1372e11894947823e3fcef4595 | [] | no_license | aigerimzh/BFDjango | 6a2635db8a1017b64c304193277d3030b3daf196 | 99f81274abdf0afcd9925cf2af057e616c433448 | refs/heads/master | 2020-03-28T22:45:13.782301 | 2018-11-22T17:10:54 | 2018-11-22T17:10:54 | 146,699,388 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 994 | py | from django.shortcuts import render,redirect
from django.contrib import auth
from django.contrib.auth.forms import UserCreationForm
def register(request):
form = UserCreationForm(data=request.POST or None)
if request.method == 'POST':
if form.is_valid():
form.save()
return redi... | [
"ajgerimzumabaeva10@gmail.com"
] | ajgerimzumabaeva10@gmail.com |
5fe57e458aa01635a031408f04ea47cd2bacc800 | c085b06c9eb220eb40b5ada840886c09a152f053 | /Libros de Python/Tutorial Tkinter/35-VENTANAS TOP LEVEL/toplevel0.py | 4edcad08b63f389a0308802934d501cdb36a5e66 | [] | no_license | thanggc/libros | 7d3bf564c5a227f08390fbcc6721a0aed160e3e0 | 430c03fe97544d263b5c3a665327b527d9c223a8 | refs/heads/master | 2020-12-25T13:23:38.527089 | 2013-04-29T23:14:08 | 2013-04-29T23:14:08 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 385 | py | import sys
from Tkinter import Toplevel, Button, Label
win1 = Toplevel( ) # two independent windows
win2 = Toplevel( ) # but part of same process
Button(win1, text='Spam', command=sys.exit).pack( )
Button(win2, text='SPAM', command=sys.exit).pack( )
Label(text='Popups').pac... | [
"mini.guero@hotmail.com"
] | mini.guero@hotmail.com |
050f4a003437d05f9d249cce64febee10945a0b1 | 8e17bbd6da5be22032d266a6c96a0f1d908db082 | /code/params/objective_stacking_cnmn2d_cassava_params6_1.py | e8743b620fb26c3ab03577de9967af0c4fceac94 | [] | no_license | riron1206/kaggle_Cassava | f39f40a1a356a4ecfb4f9de6b379cd6ca50e92cc | 91cb793a153686a9dd671c8b2ed83312437c237b | refs/heads/master | 2023-06-11T08:02:38.265142 | 2021-06-29T12:42:11 | 2021-06-29T12:42:11 | 320,337,757 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,077 | py | import os
import glob
import pickle
import json
import numpy as np
import pandas as pd
if os.getcwd() in "/kaggle/working":
ROOT_DIR = "../input/cassava-leaf-disease-classification"
TRAIN_DIR = "../input/cassava-leaf-disease-classification/train_images"
TEST_DIR = "../input/cassava-leaf-disease-classificat... | [
"rironyokoi@gmail.com"
] | rironyokoi@gmail.com |
f2c708a1a0e0459532507bea2a57f1103845c6ca | 2031771d8c226806a0b35c3579af990dd0747e64 | /pyobjc-framework-Quartz/PyObjCTest/test_cifeature.py | ff1e18f555b01d5a7991a2ad2531737adeb73dd1 | [
"MIT"
] | permissive | GreatFruitOmsk/pyobjc-mirror | a146b5363a5e39181f09761087fd854127c07c86 | 4f4cf0e4416ea67240633077e5665f5ed9724140 | refs/heads/master | 2018-12-22T12:38:52.382389 | 2018-11-12T09:54:18 | 2018-11-12T09:54:18 | 109,211,701 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,184 | py | from PyObjCTools.TestSupport import *
from Quartz.QuartzCore import *
class TestCIFeature (TestCase):
@min_os_level('10.7')
def testConstants10_7(self):
self.assertIsInstance(CIFeatureTypeFace, unicode)
@min_os_level('10.10')
def testConstants10_10(self):
self.assertIsInstance(CIFeatur... | [
"ronaldoussoren@mac.com"
] | ronaldoussoren@mac.com |
ed8fbc48da1892503070138203b835bc0d9e137d | f94790a262f6d31f91ec0a0b63d5212a36a9ee6d | /ex_cdf.py | a11cfadc90af2636a70787e23df2950eaa420c6f | [
"BSD-3-Clause"
] | permissive | rc/dist_mixtures | 02d893898b986b3123511d7fdb8bb37bb282261a | 6cb1219339b6c0ce66a240fe6626402ea23fe19f | refs/heads/master | 2021-01-13T01:36:52.982612 | 2014-07-23T13:50:09 | 2014-07-23T13:50:09 | 6,022,654 | 0 | 1 | null | 2013-06-24T13:13:33 | 2012-09-30T21:43:35 | Python | UTF-8 | Python | false | false | 2,553 | py | # -*- coding: utf-8 -*-
"""
Created on Fri Oct 26 21:57:48 2012
Author: Josef Perktold
"""
import numpy as np
from scipy import stats, interpolate, integrate
from dist_mixtures.mixture_von_mises import (VonMisesMixture,
normalize_params, shift_loc)
from numpy.testing imp... | [
"josef.pktd@gmail.com"
] | josef.pktd@gmail.com |
c739384123c1cafc5d328789b70ffb9fce4d959e | 3d90d6753cbb48c74dc8e72f4a886635a706ee16 | /day21/machineManage/models.py | d95587f996c558e0db3b7628a028821024556478 | [] | no_license | shun-zi/python | 01354dfc23e470c67ae6adc323b7b23c446faf95 | 9b9851a608cfa18392464b7d887659ced8eb58a6 | refs/heads/master | 2021-09-12T23:15:35.586858 | 2018-04-22T12:32:41 | 2018-04-22T12:32:41 | 113,460,188 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 818 | py | from django.db import models
# Create your models here.
from django.db import models
# Create your models here.
class Business(models.Model):
caption = models.CharField(max_length=32)
class Host(models.Model):
hostname = models.CharField(max_length=32, db_index=True)
ip = models.GenericIPAddressField... | [
"mac@macdeMacBook-Pro.local"
] | mac@macdeMacBook-Pro.local |
3ef4fd8192b1b1bab251d1df9c1023f6f41d0d81 | 44db7bdd50851721dc174164241bd3f7ea7dfc0d | /server.py | f3d0b94a15617b8bb4afbef67f2cd8d11062f891 | [] | no_license | TobyChen0106/109-1-web-deploy-tutorial | d09f4bab1bb20131ec8192b560de594b10d2c4fb | b349e7c0758799bb7107dfe69b183f2cf31f6a37 | refs/heads/main | 2023-02-20T23:57:00.910139 | 2021-01-21T15:28:00 | 2021-01-21T15:28:00 | 330,571,678 | 0 | 60 | null | 2021-01-21T15:28:01 | 2021-01-18T06:11:03 | JavaScript | UTF-8 | Python | false | false | 493 | py | import os
from flask import Flask, send_from_directory
app = Flask(__name__, static_folder='build')
# Serve React App
@app.route('/', defaults={'path': ''})
@app.route('/<path:path>')
def serve(path):
if path != "" and os.path.exists(app.static_folder + '/' + path):
return send_from_directory(app.static_f... | [
"you@example.com"
] | you@example.com |
0074d53fc059f15dcb42fd034ac439499cc1c25c | 594b5152cfc6774282aa7be589e200bedaba5400 | /ietf/nomcom/redirect_ann_urls.py | 7688896b5ee55fb004526370d13211f9949e8d7c | [
"BSD-3-Clause",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | wpjesus/codematch | a3adaae02ed848e24058c818bc847eab824e8f23 | 5af455fbe6b0c7e60b8af360718345ba044597a4 | refs/heads/master | 2021-04-12T04:10:10.423230 | 2016-12-21T14:39:18 | 2016-12-21T14:39:18 | 35,008,126 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 305 | py | from django.conf.urls import patterns
from django.views.generic import RedirectView
urlpatterns = patterns('',
(r'^nomcom/$', RedirectView.as_view(url="/nomcom/ann/", permanent=True)),
(r'^nomcom/(?P<message_id>\d+)/$', RedirectView.as_view(url="/nomcom/ann/%(message_id)s/", permanent=True)),
)
| [
"wanderson.paim@gmail.com"
] | wanderson.paim@gmail.com |
0b233cde6483ae7b165746fa0a5b512f9e774d19 | d9d8137db80187e6888f54846759d344e02a43b7 | /chap3/ex4.py | 354b4814596553e47fab463021931e062f9b5b66 | [] | no_license | afeefebrahim/anand-python | 10a38a207f5dd5585059f437436bde8dfbcd96de | 08e387a322c757854485cee238bab066af1c6f7b | refs/heads/master | 2021-01-25T03:54:15.224784 | 2015-05-10T15:55:13 | 2015-05-10T15:55:13 | 35,376,919 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 244 | py | #Write a program to list all the files in the given directory along with their length and last modification time.
import os
import time
cwd = os.getcwd()
l = os.listdir(cwd)
for i in l:
print i,"\t",len(i),"\t" ,time.ctime(os.stat(i)[9])
| [
"afeefebrahim@gmail.com"
] | afeefebrahim@gmail.com |
0d2309afca19f5d9ed36e29836d1d1e12cfc9e53 | 344add9ee0997458d96f9c45202a4eeb825a185f | /pkg/suggestion/bayesianoptimization/src/algorithm_manager.py | d7d5628403d7c1e0d2c763718e75ebd2a1157d03 | [
"Apache-2.0"
] | permissive | lyft/katib | 2de14e3a6cd1eb91a3fa1b5fa8362faa5a76d498 | 72fafad12ccdd86394cd9bd1cb80ad00203c959a | refs/heads/master | 2023-09-04T07:00:18.159809 | 2018-07-04T06:58:45 | 2018-07-04T06:58:45 | 137,107,090 | 4 | 3 | Apache-2.0 | 2019-05-21T15:09:26 | 2018-06-12T17:39:14 | JavaScript | UTF-8 | Python | false | false | 6,702 | py | """ module for algorithm manager """
import numpy as np
from pkg.api.python import api_pb2
def deal_with_discrete(feasible_values, current_value):
""" function to embed the current values to the feasible discrete space"""
diff = np.subtract(feasible_values, current_value)
diff = np.absolute(diff)
re... | [
"k8s-ci-robot@users.noreply.github.com"
] | k8s-ci-robot@users.noreply.github.com |
97bd034a088a8af648274b6103205a616afb196a | 6411acb3828fec8cc79f6f2630a4d99e8352a9aa | /1002.py | 8fa06f121fa5f735c7b2eb2dabde26ebfdc58b13 | [] | no_license | zhouliuling/Leetcode_Task | 95f55a3ca33b561a130fc15272e513d9af2c0317 | 0230d31351a4093e8ae6be5fe0c175f3f41e08ac | refs/heads/master | 2020-05-25T18:44:59.377953 | 2019-09-12T02:14:22 | 2019-09-12T02:14:22 | 187,935,297 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 590 | py | ## 查找常用字符
# 记录A中第一个单词中个字母,以此为对照,查找在其他所有单词中这些字母出现的最小值,更新res
class Solution(object):
def commonChars(self, A):
"""
:type A: List[str]
:rtype: List[str]
"""
res = []
if not A:
return res
key = set(A[0])
for i in key:
# 遍历key中字符,... | [
"noreply@github.com"
] | zhouliuling.noreply@github.com |
f7046d5a53bd32cae16d43d6b000465551d5080e | b1222efc9c0d8a6f4549d12490344695e07a2fed | /scripts/fit_tilted_module_orientations.py | 934e889aed4ba5216c894d9667d67d5f2fe2e385 | [] | no_license | sgnoohc/TrackLooper_ | c703d8efb717480b999be555a3193f76b855d5b2 | 250067deebeb7a0ac6b9d73f780ab09ef6e826fd | refs/heads/master | 2023-02-04T14:40:40.091380 | 2020-12-22T20:45:45 | 2020-12-22T20:45:45 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,541 | py | #!/bin/env python
import ROOT as r
import math
import sys
f = open("scripts/tilted_hits_sorted.txt")
lines = f.readlines()
hits = {}
# Parse and store hits
for line in lines:
ls = line.split()
detid = ls[0]
hit = (float(ls[2]), float(ls[3]), float(ls[1])) # NOTE in txt file we have z, y, x coordinates
... | [
"sgnoohc@gmail.com"
] | sgnoohc@gmail.com |
c7c2dd0c37c52048e4336e72c217716ce3f87677 | ddc47b938d7ce1ccc3e239291b8db26eeca71226 | /python-tips-and-tricks/Analyzing-Coronavirus-with-Python-COVID-19/main4.py | 09c9c7814bbe0e1a3f8a3a846db94ee648920d31 | [] | no_license | abderrahmanesaad/python-climb-learning-tutorial | fad70b0d3d5cadf871198cffcb35be15402c63d4 | 8d32f8c50cb878d79d6e7b53c116e25f8ac8faf6 | refs/heads/main | 2023-06-19T01:11:09.672766 | 2021-07-17T06:12:01 | 2021-07-17T06:12:01 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,367 | py | from datetime import date
import pandas as pd
import matplotlib.pyplot as plt
from pandas.core.indexes.datetimes import date_range
confirmed = pd.read_csv('covid19_confirmed.csv')
deaths = pd.read_csv('covid19_deaths.csv')
recovered = pd.read_csv('covid19_recovered.csv')
confirmed = confirmed.drop(['Province/State', ... | [
"lucifercaonima@gmail.com"
] | lucifercaonima@gmail.com |
baf0f2aeeca7bb24a5c0030f0955dbb94b99e4b3 | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p03838/s202669174.py | 836ed1ded294d6d1c3c3c232ac50e8028a825806 | [] | 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 | 472 | py | import sys
readline = sys.stdin.readline
sys.setrecursionlimit(10**8)
mod = 10**9+7
#mod = 998244353
INF = 10**18
eps = 10**-7
x,y = map(int,readline().split())
if x*y > 0:
if x > y:
print(x-y+2)
else:
print(y-x)
elif x*y < 0:
print(abs(abs(x)-abs(y))+1)
else:
if x == 0:
if y... | [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
b5227811f8ff21c586686de735d5b8ea6342b96c | eb9f655206c43c12b497c667ba56a0d358b6bc3a | /python/helpers/typeshed/stubs/requests/requests/__init__.pyi | b3b3796044afe2b214a05f6a26825c6ffdc8cf64 | [
"Apache-2.0",
"MIT"
] | permissive | JetBrains/intellij-community | 2ed226e200ecc17c037dcddd4a006de56cd43941 | 05dbd4575d01a213f3f4d69aa4968473f2536142 | refs/heads/master | 2023-09-03T17:06:37.560889 | 2023-09-03T11:51:00 | 2023-09-03T12:12:27 | 2,489,216 | 16,288 | 6,635 | Apache-2.0 | 2023-09-12T07:41:58 | 2011-09-30T13:33:05 | null | UTF-8 | Python | false | false | 1,240 | pyi | from .__version__ import (
__author__ as __author__,
__author_email__ as __author_email__,
__build__ as __build__,
__cake__ as __cake__,
__copyright__ as __copyright__,
__description__ as __description__,
__license__ as __license__,
__title__ as __title__,
__url__ as __url__,
__v... | [
"intellij-monorepo-bot-no-reply@jetbrains.com"
] | intellij-monorepo-bot-no-reply@jetbrains.com |
44b93d5c2c2649b9900191e9904231d50cf173fb | ef187d259d33e97c7b9ed07dfbf065cec3e41f59 | /work/atcoder/arc/arc045/C/answers/178173_ookie.py | c5fe272fa8a707cd1d887a63b97880bce82c9b70 | [] | no_license | kjnh10/pcw | 847f7295ea3174490485ffe14ce4cdea0931c032 | 8f677701bce15517fb9362cc5b596644da62dca8 | refs/heads/master | 2020-03-18T09:54:23.442772 | 2018-07-19T00:26:09 | 2018-07-19T00:26:09 | 134,586,379 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 168 | py | input_line = input()
input_line=input_line.replace("Left","<")
input_line=input_line.replace("Right",">")
input_line=input_line.replace("AtCoder","A")
print(input_line) | [
"kojinho10@gmail.com"
] | kojinho10@gmail.com |
4ed91c56cbb9a9d7e6128fbddac4a5cef75b31b8 | 9d3f69539e8f94f82bca5aa446f73b5da3372c0c | /home/migrations/0001_load_initial_data.py | 40d6238d6d12519760d5c66ddc8b064af79d988d | [] | no_license | crowdbotics-apps/django-first-30370 | 3730292b45ec8e804a867ece6f03a8aebaee0f0f | 7b029fc887a1851ae571d8a686dac8b2b0ca5d32 | refs/heads/master | 2023-07-31T21:24:30.045046 | 2021-09-07T08:50:05 | 2021-09-07T08:50:05 | 403,907,104 | 0 | 0 | null | 2021-09-15T01:54:38 | 2021-09-07T08:50:00 | Python | UTF-8 | Python | false | false | 542 | py | from django.db import migrations
def create_site(apps, schema_editor):
Site = apps.get_model("sites", "Site")
custom_domain = "django-first-30370.botics.co"
site_params = {
"name": "django-first",
}
if custom_domain:
site_params["domain"] = custom_domain
Site.objects.update_o... | [
"team@crowdbotics.com"
] | team@crowdbotics.com |
2650a037a8d32cb89cfdc996ff25c95b5189c24c | 4f584789b99a33d806da0b7c5b63da3b608f7b48 | /scripts/get_real_footprint_lengths_for_not_clustered_reads_all_at_once.py | 66fc472eadec75925f67791eae4087cf208a0acc | [] | no_license | satyanarayan-rao/protein_binding_at_enhancers | f10580e76adcc057bf21614c0f9a3c96a8b3f0d5 | 74a6a33efb7acff073b0dcec96c917a4cd019219 | refs/heads/master | 2022-11-30T13:56:41.520639 | 2020-08-11T21:17:19 | 2020-08-11T21:17:19 | 286,848,856 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,351 | py | import os
import sys
import re
from collections import defaultdict
import pickle
from extend_a_given_read import extend_footprint_from_center
from capital_peracentage_and_unbound_stretches import capital_percentage_and_stretch_of_unbound
# Look at the rule get_real_footprint_lengths_and_oraange_on_read
def get_count_an... | [
"satyanarayan.iiitm@gmail.com"
] | satyanarayan.iiitm@gmail.com |
26ae8e2765f313a1d23f51c4d4fd4675d4d46ac2 | e82b761f53d6a3ae023ee65a219eea38e66946a0 | /All_In_One/addons/PearRay/ui/properties_render_layer.py | cdd22ee7795f51098c6268fd38aca3ac1b1c37e5 | [] | no_license | 2434325680/Learnbgame | f3a050c28df588cbb3b14e1067a58221252e2e40 | 7b796d30dfd22b7706a93e4419ed913d18d29a44 | refs/heads/master | 2023-08-22T23:59:55.711050 | 2021-10-17T07:26:07 | 2021-10-17T07:26:07 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,340 | py | import bpy
from bl_ui.properties_render_layer import RenderLayerButtonsPanel
from bl_ui import properties_render_layer
properties_render_layer.RENDERLAYER_PT_layers.COMPAT_ENGINES.add('PEARRAY_RENDER')
del properties_render_layer
class RENDERLAYER_PT_pr_layer_options(RenderLayerButtonsPanel, bpy.types.Panel):
... | [
"root@localhost.localdomain"
] | root@localhost.localdomain |
c731a006826267fe9897c50dbf7e0afce0d6b99b | 62e58c051128baef9452e7e0eb0b5a83367add26 | /edifact/D01C/MEQPOSD01CUN.py | b83028ea25121ac12e3afc0f93319016b32de31b | [] | 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 | 920 | py | #Generated by bots open source edi translator from UN-docs.
from bots.botsconfig import *
from edifact import syntax
from recordsD01CUN import recorddefs
structure = [
{ID: 'UNH', MIN: 1, MAX: 1, LEVEL: [
{ID: 'BGM', MIN: 1, MAX: 1},
{ID: 'DTM', MIN: 0, MAX: 9},
{ID: 'QTY', MIN: 0, MAX: 1},
{ID: 'LOC'... | [
"jason.capriotti@gmail.com"
] | jason.capriotti@gmail.com |
6bbf0ba04d2fd0b8c99fd9cd20c7f00fdcc70c99 | cb13037cdbd3e0ab6108670108e9497cc1e2a5a7 | /1.networkProgramming/2.parallelProgramming/1.multiProcess/6.consumerProducerModel.py | de70a962883b9ed441b5f51f0d8e699b5b3e7dc9 | [] | no_license | GMwang550146647/network | 390fe0d1c72dcaca8b6d6dd1307adca0d56b55ce | 576de9b993f7763789d25a995702b40c9bc6fa57 | refs/heads/master | 2023-06-15T04:42:54.306077 | 2021-07-12T06:06:02 | 2021-07-12T06:06:02 | 315,488,828 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 858 | py | """
生产者消费者模型
#爬虫
#分布式操作
#本质:让生产者数据和消费者数据的效率达到平衡并且效益最大化
"""
import time
from multiprocessing import Queue,Process
def consumer(q,ith):
count=0
while True:
count+=1
print("Consumer {} -> {}th get: receive from consumer {}".format(ith,count, q.get()))
time.sleep(10)
def producer... | [
"550146647@qq.com"
] | 550146647@qq.com |
b10bc2e74b059347daf4ebafb9f44b520e2322cc | 1130f61cef895ae0afb3359d1d00ae9ed77de103 | /db/upload_dogsand.py | f0070b6d0ef7dff9e1c02df841d3c9f480452951 | [] | no_license | zhoulingjie/WeiboApp | 32a3538762ec8f3244aaa73b29e7f30f4f86c821 | cab2738a7f0d70d33548a968cdbbb07629e075a8 | refs/heads/master | 2020-03-30T07:22:50.553321 | 2015-10-11T13:39:34 | 2015-10-11T13:39:34 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,403 | py | #!/usr/bin/env python
# -*- coding:utf-8 -*-
from __future__ import unicode_literals
import config
import os
import mimetypes
import time
from leancloud_api import LeanCloudApi
from single_process import single_process
from ..crawler.animal.animals_tumblr import (
DogsandpupsdailySpider,
)
class Upload(object):
... | [
"291374108@qq.com"
] | 291374108@qq.com |
67c26969f243fd221297af34fc725b09bf584f9b | 9743d5fd24822f79c156ad112229e25adb9ed6f6 | /xai/brain/wordbase/nouns/_allotments.py | ed7f5e9719c5fed9cb2698693b616c7a23cb278f | [
"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 | 259 | py |
from xai.brain.wordbase.nouns._allotment import _ALLOTMENT
#calss header
class _ALLOTMENTS(_ALLOTMENT, ):
def __init__(self,):
_ALLOTMENT.__init__(self)
self.name = "ALLOTMENTS"
self.specie = 'nouns'
self.basic = "allotment"
self.jsondata = {}
| [
"xingwang1991@gmail.com"
] | xingwang1991@gmail.com |
1c8a4e484f7508ab4b2131c9a0a05b6babea21fd | 273484a9dc7778e2c0310befcf65506e60b468c0 | /neurolab/optimization/metric/acc.py | 8f869060853577c5bb2fe47293516de0faa00909 | [
"MIT"
] | permissive | GabrieleLagani/HebbianLearning | 942a44778abbaccc14bc624887b5d96c6506bfa5 | a7ed2f8a5925426880b5c315a7caf1ef1891001a | refs/heads/master | 2023-02-14T22:47:07.220429 | 2023-01-23T11:31:32 | 2023-01-23T11:31:32 | 219,447,087 | 15 | 3 | null | null | null | null | UTF-8 | Python | false | false | 947 | py | import torch
from ..optimization import MetricManager
from neurolab import params as P
# Return number of correctly classified samples given network outputs and target labels. The experiment class is then
# going to average over a batch of data, thus finally obtaining an accuracy score.
class AccMetric:
def __call_... | [
"gabriele.lagani@gmail.com"
] | gabriele.lagani@gmail.com |
1e485d8df5c3a0b6c396abc75d92993f0b54c395 | b210204be933427fbe36448d226d557c744fd62e | /Day 12.py | f5b28cd6d5281888f7ce53ab0c02f12c5d619a02 | [] | no_license | AdamBures/JUNE-CHALLENGE-2020 | ad364ec68149083dbd83f20c5791e0efeef60bde | 902e331cba0c4b6ce1c20e1bb4471d3505441293 | refs/heads/master | 2022-11-08T00:41:13.627477 | 2020-07-02T14:30:53 | 2020-07-02T14:30:53 | 276,668,165 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 695 | py | import random
class RandomizedSet(object):
def __init__(self):
self.nums, self.pos = [], {}
def insert(self, val):
if val not in self.pos:
self.nums.append(val)
self.pos[val] = len(self.nums) - 1
return True
return False
... | [
"noreply@github.com"
] | AdamBures.noreply@github.com |
8d7b15b7d899e55c12a118a029163baa20f6407c | ea58aa620efb89c0e8636efc8f15534eec4ac799 | /polyaxon/projects/signals.py | 24230961a04e548a5fabe8087d3158eb2f235929 | [
"MIT"
] | permissive | uber-haupt/polyaxon | fca824cfa0b2baa8c3c06e3ae1676886b028cd89 | 303a7bd452a6386163f9a9c553f385eb1b5a51bc | refs/heads/master | 2020-03-07T01:46:33.227599 | 2018-03-27T20:38:39 | 2018-03-27T20:38:39 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,735 | py | from django.db.models.signals import post_save, pre_delete
from django.dispatch import receiver
from libs.decorators import ignore_raw
from projects.models import ExperimentGroup, Project
from projects.tasks import create_group_experiments
from projects.paths import (
delete_project_outputs,
delete_experiment_... | [
"mouradmourafiq@gmail.com"
] | mouradmourafiq@gmail.com |
4ca8025feeb0e33472147dd7e9b438f7e4195926 | 1edb370654498d1ef614f5c05ff9f0969f3c6637 | /david_beazley4/59-links_counting.py | 49875542c0ad78b7af8c2ab13558a0ef140fd4ec | [] | no_license | shmakovpn/python_projects | 147888a54fd585de930e12a5e92f602b6f4e5d7a | 9059334bff6f2fc3d4df69f6bdd009eb4f5f7764 | refs/heads/master | 2020-09-25T13:58:16.226512 | 2020-06-19T05:19:09 | 2020-06-19T05:19:09 | 226,018,057 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,756 | py | #!/usr/bin/env python
"""
Книга Девида Бизли "Python подробный справочник 4ое издание"
страница 59
Подсчет ссыллок и сборка мусора
"""
__author__ = "shmakovpn <shmakovpn@yandex.ru>"
__date__ = "2019-12-09"
import sys
import copy
d = []
for x in range(10):
d.append("123")
z = "123"
print(f"z ref count={sys.getrefco... | [
"shmakovpn@yandex.ru"
] | shmakovpn@yandex.ru |
ad34fae614cb8e28612633bacc6876e7ef58503b | f80f77417ca0e3dcb3881b0684e31bfd9cdc1078 | /Implementatioin/1_ans.py | d47216ac6397982a20f8dab9f18d6d73c74e0777 | [] | no_license | mlsh1112/python-for-coding-test | 8b8a812e841aed654a5459a184e6f4cc9c93ae32 | 489ba34a4859be866a7d77add885d62b4cd2dbc4 | refs/heads/master | 2023-07-07T09:10:59.765332 | 2021-07-28T03:16:43 | 2021-07-28T03:16:43 | 346,233,471 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 298 | py | n=int(input())
x,y=1,1
plans=input().split()
dx=[0,0,-1,1]
dy=[-1,1,0,0]
move_types=['L','R','U','D']
for plan in plans:
for i in range(len(move_types)):
if plan ==move_types[i]:
nx=x+dx[i]
ny=y+dy[i]
if nx<1 or ny<1 or nx>n or ny>n:
continue
x,y=nx,ny
print(x,y) | [
"replituser@example.com"
] | replituser@example.com |
ef3c060b7e73dd0bebba8ff960ddfea255fd446a | 5a65c8c8f10c9637857b79b6202e5e80ffe1e76d | /catwatch/migrations/env.py | 3ef972ca38b6fd37ca9ee613aaac012ca4d8d92b | [
"MIT"
] | permissive | bikegriffith/build-a-saas-app-with-flask | 7c47c40aab59befa7e668545a797ba91a91494cd | 4b0fcb06cb0e4efb1e3f1d9e3999019580f73a64 | refs/heads/master | 2023-04-13T21:24:31.878621 | 2015-09-08T12:13:12 | 2015-09-08T12:13:12 | 45,186,814 | 0 | 0 | MIT | 2023-04-04T01:34:33 | 2015-10-29T14:03:23 | Python | UTF-8 | Python | false | false | 2,566 | py | from __future__ import with_statement
import os
import sys
import logging
from logging.config import fileConfig
from alembic import context
from sqlalchemy import engine_from_config
try:
from instance import settings
SQLALCHEMY_DATABASE_URI = settings.SQLALCHEMY_DATABASE_URI
except ImportError:
logging.... | [
"nick.janetakis@gmail.com"
] | nick.janetakis@gmail.com |
9ba46b10f29e72b2a162a3815e826a9a0182280a | b6aa9768dbac327943e0220df1c56ce38adc6de1 | /520_detect-capital.py | c68cce1502e31ee94a98eab6d2a5909f78db4264 | [] | no_license | Khrystynka/LeetCodeProblems | f86e4c1e46f70f874924de137ec5efb2f2518766 | 917bd000c2a055dfa2633440a61ca4ae2b665fe3 | refs/heads/master | 2021-03-17T00:51:10.102494 | 2020-09-28T06:31:03 | 2020-09-28T06:31:03 | 246,954,162 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 383 | py | # Problem Title: Detect Capital
class Solution(object):
def detectCapitalUse(self, word):
"""
:type word: str
:rtype: bool
"""
if word == word.lower():
return True
if word[0] == word[0].lower():
return False
if word[1:] == word[1:].low... | [
"khrystyna@Khrystynas-MacBook-Pro.local"
] | khrystyna@Khrystynas-MacBook-Pro.local |
bae12d70d8ae85f71824ccef8826350e9d097a31 | 9c022a7991edc0849251d3d27d1c432920c4644b | /app/authentification/views.py | 930a074993b1b393bb2c86f6424f6e6075ac2432 | [
"MIT"
] | permissive | dancan-sandys/bernblogs | 909fc5e72ad458e41cbd211dca9d1009ce718be0 | 149aa82111bc72b6e7d8cf804c58bfc935e7a53c | refs/heads/master | 2022-12-24T01:26:36.648169 | 2020-10-01T08:08:29 | 2020-10-01T08:08:29 | 300,151,035 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,450 | py | from flask import redirect, render_template, url_for,render_template, flash
from .forms import SignIn, SignUp
from ..models import User
from flask_login import login_user,logout_user
from . import auth
from .. import db
from flask_login import login_required
@auth.route('/profile/signup', methods = ['GET','POST'])
de... | [
"dancan.oruko96@gmail.com"
] | dancan.oruko96@gmail.com |
f02231ff7de91baa92de8944af2ba1c83194bc5c | 8fcc27160f8700be46296568260fa0017a0b3004 | /client/stacklesslib/replacements/select.py | 4735bd53d19198bd2e3887379f93379f09506d7e | [] | no_license | connoryang/dec-eve-serenity | 5d867f4eedfa896a4ef60f92556356cafd632c96 | b670aec7c8b4514fc47cd52e186d7ccf3aabb69e | refs/heads/master | 2021-01-22T06:33:16.303760 | 2016-03-16T15:15:32 | 2016-03-16T15:15:32 | 56,389,750 | 1 | 0 | null | 2016-04-16T15:05:24 | 2016-04-16T15:05:24 | null | UTF-8 | Python | false | false | 789 | py | #Embedded file name: e:\jenkins\workspace\client_SERENITY\branches\release\SERENITY\carbon\common\stdlib\stacklesslib\replacements\select.py
from __future__ import absolute_import
import stackless
import stacklesslib.util
import select as real_select
error = real_select.error
__doc__ = real_select.__doc__
_main_... | [
"masaho.shiro@gmail.com"
] | masaho.shiro@gmail.com |
d3ef3cbfc597187e808e087a2a812884bbb82662 | 732b9caa57342007d17c7db4e08eb37f3cbde016 | /dataset_preprocessing/generate_templates.py | d6a8e3947accb78fb8f8069a48bec03c455e5595 | [] | no_license | kedz/mrt | 001f1f6a0e6bf9061a9ea4590125e95a9c9095ce | c42e17c079797c5bc59d4e82f6de863b5fafde04 | refs/heads/master | 2021-05-21T05:56:23.431030 | 2020-05-19T22:54:03 | 2020-05-19T22:54:03 | 252,575,428 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,455 | py | #!/usr/bin/env python
import argparse
from pathlib import Path
import json
from collections import defaultdict
from itertools import permutations, product
import mrt.e2e.mr_utils
import mrt.e2e.template_meta
import mrt.viggo.mr_utils
import mrt.viggo.template_meta
def get_rule_set(rule_set):
if rule_set == "E2E... | [
"kedzie@cs.columbia.edu"
] | kedzie@cs.columbia.edu |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.