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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
275a965beacc898d34762e7483c622411e29df6e | 008c0a630ffa5bc412571acef2b7462e22fce196 | /tests/test_console.py | 3ec9d656f2396736bf0840eec5723aff6aeb2a8d | [
"BSD-2-Clause",
"Python-2.0",
"BSD-2-Clause-Views"
] | permissive | Jacktwist/python-tcod | dea56c330f5c27d85e71a2c44074b0b2c4536675 | d271cc9892a6bdcd931f7a9984fffc754170b36f | refs/heads/master | 2020-04-28T12:57:01.653126 | 2019-03-11T01:39:52 | 2019-03-11T01:39:52 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,786 | py | import pickle
import numpy as np
from numpy import array
import pytest
import tcod
@pytest.mark.filterwarnings("ignore:Directly access a consoles")
def test_array_read_write():
console = tcod.console.Console(width=12, height=10)
FG = (255, 254, 253)
BG = (1, 2, 3)
CH = ord('&')
tcod.console_put_... | [
"4b796c65@gmail.com"
] | 4b796c65@gmail.com |
be4111fbce90624d076a4b5716314151ab4cc46e | d4e38b8a1438c0509f3f160a2ceb9aa166ac3ed1 | /quizzes/quiz1/server.py | 1f8c6d93d9cce2d4febe28260c52823c3b82da31 | [] | no_license | yulu9206/cmpe273-spring2018 | e7ffa36818cb87596de351b36d5dc33ec387bf1b | 8e0eaa0ce951b718dae195753dca0d9fc07b5a97 | refs/heads/master | 2021-04-06T11:17:44.918483 | 2018-03-15T20:26:35 | 2018-03-15T20:26:35 | 125,421,797 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 734 | py | import time
import grpc
import ping_pb2
import ping_pb2_grpc
from concurrent import futures
class PingServer(ping_pb2_grpc.PingPongServicer):
def ping(self, request, context):
return ping_pb2.Response(data='Pong')
def run(host, port):
server = grpc.server(futures.ThreadPoolExecutor(max_workers=1))
... | [
"yulu9206@Lus-MacBook-Air.local"
] | yulu9206@Lus-MacBook-Air.local |
f787f4e893e031beb971965ab9fcd5ad7fea6217 | 15e5b2e39d8f1c08b34b36783cc5504638e3e434 | /TODO-PROJECT/todo-back/todos/migrations/0001_initial.py | 318ee532b77426a5c00753188598859bd9f21d93 | [] | no_license | ghdus4185/Vue_intro | 62e0ded5b4a23ef34869d8e0bb7b337a7e9c934f | b999f19a4140b2456614625f8063ff919b8cdfed | refs/heads/master | 2023-01-13T09:42:15.804784 | 2019-11-21T00:01:38 | 2019-11-21T00:01:38 | 219,454,656 | 0 | 0 | null | 2023-01-07T21:19:32 | 2019-11-04T08:41:36 | HTML | UTF-8 | Python | false | false | 3,393 | py | # Generated by Django 2.2.6 on 2019-11-18 06:18
from django.conf import settings
import django.contrib.auth.models
import django.contrib.auth.validators
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
class Migration(migrations.Migration):
initial = True
... | [
"ckdghdus@naver.com"
] | ckdghdus@naver.com |
8b07c0d19f6538fff2340e3c06e09aba7bac2636 | 0ca210752cd5b926201f3fb40ee4aadc6da4f537 | /code/test_hd22879.py | bdca611a496161a373724a5b3bd0c099afc339a0 | [
"MIT"
] | permissive | andycasey/precise-objective-differential-spectroscopy | f45f93dfdaeb78d138d7792c439cf7b6065882c5 | 658b0d226300330375570dd2450bb284f1cf167a | refs/heads/master | 2021-01-19T20:24:48.539975 | 2014-07-09T13:41:32 | 2014-07-09T13:41:32 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,015 | py | import cPickle as pickle
from stellar_parameters import Star
from channel import SpectralChannel
class spectrum(object):
pass
import sick
spec = sick.specutils.Spectrum.load("spectra/hermes-sun.fits")
spec = sick.specutils.Spectrum.load("spectra/uvessun1.txt")
blue_channel = spectrum()
blue_channel.dispersi... | [
"andycasey@gmail.com"
] | andycasey@gmail.com |
7bfb340afa9df5a5df6c0f09a08cba7269997bbb | ecd0cffe45c6fee6ce02b70fb5721caac66a7b37 | /Data_Structures/Graphs/DijkstraAlgorithm.py | d16d8b75f887ff9deefb3181f6df5ca25839d837 | [] | no_license | johngaitho05/Interview-Questions | 75925ba5e3326857a13cfe6e1add27be3d1aa83e | 979f6960bc44186208c629403fa4ed73f72673b0 | refs/heads/master | 2021-05-21T13:39:48.290629 | 2020-06-18T05:51:30 | 2020-06-18T05:51:30 | 252,669,485 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,447 | py | import sys
import heapq
def cmp(x, y):
"""
Replacement for built-in function cmp that was removed in Python 3
Compare the two objects x and y and return an integer according to
the outcome. The return value is negative if x < y, zero if x == y
and strictly positive if x > y.
... | [
"johngaitho05@gmail.com"
] | johngaitho05@gmail.com |
163ef3f305c3772d2d7644c28856b2fc13b47f3b | 55a2e62805cca90f46f3ac9c9501aa3386ab3109 | /games/urls.py | f8a56294778ab42f63bedfc70f5c669ad53da1b9 | [] | no_license | profmcdan/games-service | 2bf5d533b797d46e6a27ae63eac9c367cf144497 | 24049d08cfc645bd750839bcd0eba16fa7d7ee2d | refs/heads/master | 2022-12-16T01:19:09.859633 | 2019-08-06T15:11:54 | 2019-08-06T15:11:54 | 200,827,749 | 0 | 0 | null | 2022-12-08T01:48:16 | 2019-08-06T10:14:54 | Python | UTF-8 | Python | false | false | 984 | py | # from django.conf.urls import url
from django.urls import path
# from .views import game_collection, game_detail
from . import views
urlpatterns = [
path('esrb-ratings/', views.EsrbRatingList.as_view(),
name=views.EsrbRatingList.name),
path('esrb-ratings/<int:pk>/', views.EsrbRatingDetail.as_view(),
... | [
"danielale9291@gmail.com"
] | danielale9291@gmail.com |
f5b439565e4463e6269798259de653eacdfd482e | 03195a6f98396fd27aedc3c06d81f1553fb1d16b | /pandas/_libs/properties.pyi | b2ba55aefb8a57e9a884c9c07d3882b1e3014f78 | [
"BSD-3-Clause"
] | permissive | huaxz1986/pandas | a08d80d27726fe141d449835b9a09265bca5b5e0 | ba2473834fedcf571d3f8245b4b24796873f2736 | refs/heads/master | 2023-06-11T02:20:14.544220 | 2022-01-12T04:40:06 | 2022-01-12T04:40:06 | 131,370,494 | 3 | 4 | BSD-3-Clause | 2018-04-28T03:51:05 | 2018-04-28T03:51:05 | null | UTF-8 | Python | false | false | 330 | pyi | # pyright: reportIncompleteStub = false
from typing import Any
# note: this is a lie to make type checkers happy (they special
# case property). cache_readonly uses attribute names similar to
# property (fget) but it does not provide fset and fdel.
cache_readonly = property
def __getattr__(name: str) -> Any: ... # i... | [
"noreply@github.com"
] | huaxz1986.noreply@github.com |
f9106238b4ff20bec1e7b0835e8bd33b0db2acf4 | 8e69eee9b474587925e22413717eb82e4b024360 | /v1.0.0.test/toontown/uberdog/DistributedDataStoreManagerUD.py | a96c02427ed6514633f660973bad639449564c3f | [
"MIT"
] | permissive | TTOFFLINE-LEAK/ttoffline | afaef613c36dc3b70514ccee7030ba73c3b5045b | bb0e91704a755d34983e94288d50288e46b68380 | refs/heads/master | 2020-06-12T15:41:59.411795 | 2020-04-17T08:22:55 | 2020-04-17T08:22:55 | 194,348,185 | 5 | 4 | null | null | null | null | UTF-8 | Python | false | false | 523 | py | from direct.directnotify import DirectNotifyGlobal
from direct.distributed.DistributedObjectUD import DistributedObjectUD
class DistributedDataStoreManagerUD(DistributedObjectUD):
notify = DirectNotifyGlobal.directNotify.newCategory('DistributedDataStoreManagerUD')
def startStore(self, todo0):
pass
... | [
"s0mberdemise@protonmail.com"
] | s0mberdemise@protonmail.com |
73a145d26a657841c35d7ea4b5ab7b210955a4ee | b3879bc761ac38dab903da57c4061ad79fd70c6d | /курсы пайтон модуль 8/задание 9.py | 6957678c459752ce7e24854b4f53dc592a0069d7 | [] | no_license | Ruslan5252/all-of-my-projects-byPyCharm | 4df70cc3a31c4a5d97560fa858a706edcc856299 | 817d5f711408590ea141590ae52c6d888dfa2015 | refs/heads/master | 2023-05-03T01:06:30.156731 | 2021-05-29T13:51:16 | 2021-05-29T13:51:16 | 371,970,160 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,957 | py | class Car():
def __init__(self,name,model,maxSpeed,year,volume):
self.name=name
self.model=model
self.maxSpeed=maxSpeed
self.year=year
self.volume=volume
def ride(self):
print(f"машина названием ",{self.name},"моделью ",{self.model},"с максимальной скоростью ",{se... | [
"r.u.s_2000@mail.ru"
] | r.u.s_2000@mail.ru |
8fca49fbe0da62e740f590084e3aea24dc479f4e | fcd29745ed7a66b46f5039c2ad07f2fa5cb457a2 | /6_files/files_project/app.py | 758c311e0fb3ecf125e133b27a725f2b0261621f | [
"MIT"
] | permissive | PacktPublishing/The-Complete-Python-Course | 17489ec6939b5c6c20b92d5bb2d15a71a6444f8e | b880ef9c0e281316f4080531d3690435a686e9c0 | refs/heads/master | 2023-02-19T04:22:33.451524 | 2023-02-02T06:04:40 | 2023-02-02T06:04:40 | 204,631,924 | 56 | 72 | MIT | 2023-02-15T23:21:39 | 2019-08-27T06:09:32 | Python | UTF-8 | Python | false | false | 239 | py | my_file = open('data.txt', 'r')
file_content = my_file.read()
my_file.close()
print(file_content)
user_name = input('Enter your name: ')
my_file_writing = open('data.txt', 'w')
my_file_writing.write(user_name)
my_file_writing.close()
| [
"dwayned@packtpub.com"
] | dwayned@packtpub.com |
2bc2d9a96d32d718cd7212819c018fb6c1d25567 | 5cc4a73d6fb144d72e74b07a10b60fc36bfe50ec | /shops/migrations/0002_auto_20190330_1916.py | df99c08c2f3e516d78ab25dd75133d1b5afcbeba | [] | no_license | pedrofolch/digitalsoil | 79d9497dcbb54df3c7df64f9da35d71d592fe580 | 7b6d1ffd34e991cf87c91342e5336a97fa1cf59b | refs/heads/master | 2022-12-11T00:47:01.728729 | 2019-04-11T03:34:12 | 2019-04-11T03:34:12 | 120,937,159 | 0 | 0 | null | 2022-12-08T04:58:09 | 2018-02-09T17:49:10 | CSS | UTF-8 | Python | false | false | 659 | py | # Generated by Django 2.1.5 on 2019-03-31 02:16
import django.contrib.gis.db.models.fields
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('shops', '0001_initial'),
]
operations = [
migrations.AlterField(
model_name='elevation',
... | [
"pedro.folch@gmail.com"
] | pedro.folch@gmail.com |
e4f668c29f8509034aa848c7bc5ab56a68eb64c4 | ca0e761b2948b2bd93d46e5bab610901f4a9936c | /data/convert_to_json_file.py | 6e7ef5a2f0f1f046e2029916e023b0653ab42ed7 | [
"MIT"
] | permissive | dojinkimm/go-krx | 7f122321f69a119594de1ee184be57eeb4f148f7 | b565696a7c13427f3320c6c43a529638ea06682e | refs/heads/main | 2023-03-11T22:06:00.291164 | 2021-02-28T13:29:51 | 2021-02-28T13:29:51 | 300,895,170 | 7 | 2 | null | 2021-02-23T12:34:18 | 2020-10-03T14:09:40 | Go | UTF-8 | Python | false | false | 1,695 | py | import json
import pandas as pd
dfstockcode = pd.read_html(
"http://kind.krx.co.kr/corpgeneral/corpList.do?method=download", header=0
)[0]
stock_information = list()
for (
i,
(
name,
symbol,
sector,
industry,
listing_date,
settlement_month,
represen... | [
"dojinkim119@gmail.com"
] | dojinkim119@gmail.com |
7c691685311f964776bd731d24ea73ab2268ea4a | a6719f4815ff41d3a1f09e9a63a64c4582d03702 | /file_handling/read_file_demo.py | b131427b8bc801751761bb301ff7f1a6d3fecacc | [
"MIT"
] | permissive | thanh-vt/python-basic-programming | 8136007b8435dae6339ae33015fe536e21b19d1d | 5fe817986fbef2649b4b03955f07b59d2a2035d8 | refs/heads/main | 2023-01-30T12:57:36.819687 | 2020-12-13T17:27:05 | 2020-12-13T17:27:05 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 144 | py | f = open('demo_file.txt', 'r')
print(f.read())
# read only part of a file (first 5 characters)
f = open('demo_file.txt', 'r')
print(f.read(5))
| [
"thanhvt@vissoft.vn"
] | thanhvt@vissoft.vn |
686006acd784aeb64f48aa38eeb51d5c566319c7 | 1d11ff770c5530de4c18e83d9474d4c09c4376d2 | /igor/std-plugins/philips/scripts/philips.py | 0a6d1b43a4de640d5a4642c054379da4b21d6527 | [
"MIT"
] | permissive | bobandrey37/igor | 6660508639d90e7f44ea85146581685513b99ca2 | 41e163c8fa3da8ef13a337e1fe4268cf6fd7d07a | refs/heads/master | 2020-05-01T06:27:36.954089 | 2019-03-04T14:45:26 | 2019-03-04T14:45:26 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,929 | py | #!/usr/bin/python
from __future__ import print_function
from __future__ import unicode_literals
from future import standard_library
standard_library.install_aliases()
from builtins import object
import socket
import struct
import select
import json
import urllib.request, urllib.parse, urllib.error
import sys
DEBUG=Fal... | [
"Jack.Jansen@cwi.nl"
] | Jack.Jansen@cwi.nl |
dd289bbe11d653c04e5f33bf697ff022530a0ef8 | b7eb8279ebe2f525d27849d6ca24cc7270d30433 | /processing/b2_demultiplex_stats.py | c941dc97629b4495d6d94f77ebdff996cd4bb1a9 | [] | no_license | maxwshen/prime-peptide | d0da277521537c6e09dfeca4afbe3297893ed61b | d72244e85683583c812d3bd106b6874da0a17b80 | refs/heads/main | 2023-04-07T19:07:03.371146 | 2021-04-09T20:36:07 | 2021-04-09T20:36:07 | 356,391,769 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,136 | py | #
from __future__ import division
import _config
import sys, os, fnmatch, datetime, subprocess
sys.path.append('/home/unix/maxwshen/')
import numpy as np
from collections import defaultdict
from mylib import util
import pandas as pd
# Default params
inp_dir = _config.OUT_PLACE + 'b_demultiplex/'
NAME = ut... | [
"maxwshen@gmail.com"
] | maxwshen@gmail.com |
6f6bbd7824afebb390fcad7b60006d07593eaeb0 | f445450ac693b466ca20b42f1ac82071d32dd991 | /generated_tempdir_2019_09_15_163300/generated_part005963.py | 536d9214289d3cb10209ba7b567a2e1a915c7dca | [] | no_license | Upabjojr/rubi_generated | 76e43cbafe70b4e1516fb761cabd9e5257691374 | cd35e9e51722b04fb159ada3d5811d62a423e429 | refs/heads/master | 2020-07-25T17:26:19.227918 | 2019-09-15T15:41:48 | 2019-09-15T15:41:48 | 208,357,412 | 4 | 1 | null | null | null | null | UTF-8 | Python | false | false | 1,302 | py | from sympy.abc import *
from matchpy.matching.many_to_one import CommutativeMatcher
from matchpy import *
from matchpy.utils import VariableWithCount
from collections import deque
from multiset import Multiset
from sympy.integrals.rubi.constraints import *
from sympy.integrals.rubi.utility_function import *
from sympy.... | [
"franz.bonazzi@gmail.com"
] | franz.bonazzi@gmail.com |
bf4938d9e73a26fe0757893e1a32b04c141a9cdb | d1845a132213f2239fb0fea3502982dcfbdaca08 | /youtube-favourites-export.py | 965eff77359c96636c638fe0f16b20fabf00c131 | [
"MIT"
] | permissive | dw/scratch | 361e9dac7693061b66ccd064633f4ed09875e1b2 | c22c84d4d2d0347283e70192458ea50e08efcadb | refs/heads/master | 2021-01-17T12:21:52.423557 | 2019-06-11T00:09:30 | 2019-06-11T00:09:30 | 3,239,854 | 30 | 10 | null | null | null | null | UTF-8 | Python | false | false | 982 | py |
import gdata.youtube.client
client = gdata.youtube.client.YouTubeClient()
client.client_login('email@gmail.com', 'password', 'exporter')
entries = []
uri = 'https://gdata.youtube.com/feeds/api/users/default/favorites'
while True:
print 'Fetch', uri
feed = client.get_videos(uri=uri, **{'max-results': 50})
... | [
"dw@botanicus.net"
] | dw@botanicus.net |
676b57edf2543587624cb7fb53630425c91c775f | 7c1892d60f07848756cefe0dea0cce7292c7c572 | /database/add.py | a4e5e1046441fc9f119b92398f0c094ccabc923e | [] | no_license | cherryMonth/BWC | 31d92a583b0ff35a18368a2c2ccfdb8d549dd7e1 | 187430bbc9e81d1cbc8721fd423f9b0488e0e78d | refs/heads/master | 2021-01-01T17:29:17.655717 | 2017-07-28T04:40:20 | 2017-07-28T04:40:20 | 98,082,540 | 3 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,605 | py | # coding=utf-8
import csv
import os
import collections
class Add(object):
@staticmethod
def add(filename, key_list=None):
if not os.path.exists(filename):
index = 1
else:
index = 0
try:
with open(filename, 'ab') as csv_file:
... | [
"1115064450@qq.com"
] | 1115064450@qq.com |
fcb0ac9a2e90fb3003f163171bdf3f9429306a81 | e43ff8f429a6938a4f16edc4b2c94976acbff157 | /ABC/HELLO SPACE/c.py | 7e33c484056d96fed727123096a19a47f8c58635 | [] | no_license | Soule50431/AtCoder | 4fcd6ab6b771d55c90dc62aedd75eb81fd067466 | 118ac5d03630ce143fb50153402eee38e988ae0c | refs/heads/master | 2023-06-18T13:07:13.843361 | 2021-07-14T01:56:20 | 2021-07-14T01:56:20 | 357,827,698 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 496 | py | n = int(input())
team = [tuple(map(int, input().split())) for i in range(n)]
def check(x):
comb = set()
for member in team:
comb.add(sum(1 << i for i in range(5) if member[i] >= x))
for x in comb:
for y in comb:
for z in comb:
if x | y | z == 31:
... | [
"h.ekcero.el6no11@outlook.jp"
] | h.ekcero.el6no11@outlook.jp |
9f7513aceb03d3a629148eb93790f2bd922608ca | 6c2ecefb12be6b04f597e3fb887d9389050aa7e1 | /DjangoCourse/第三周/djangologin/djangologin/settings.py | ca207ee45368d5f381d99a9266ac9e571e9357b6 | [] | no_license | GmyLsh/learngit | 99d3c75843d2b0b873f26e098025832985c635b3 | 3e7993c7119b79216fea24e5e35035336e4f5f5b | refs/heads/master | 2020-04-12T09:11:55.068312 | 2018-12-19T07:19:42 | 2018-12-19T07:19:42 | 162,395,001 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,616 | py | """
Django settings for djangologin project.
Generated by 'django-admin startproject' using Django 2.1.2.
For more information on this file, see
https://docs.djangoproject.com/en/2.1/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/2.1/ref/settings/
"""
import o... | [
"469192981@qq.com"
] | 469192981@qq.com |
b7ea7c196a657c03362e5a72b8dc3b5a15f15f9c | eb9c3dac0dca0ecd184df14b1fda62e61cc8c7d7 | /google/ads/googleads/v6/googleads-py/google/ads/googleads/v6/services/services/ad_group_criterion_simulation_service/transports/base.py | ecc835952d95a794ce1333feaca5eb673c52f842 | [
"Apache-2.0"
] | permissive | Tryweirder/googleapis-gen | 2e5daf46574c3af3d448f1177eaebe809100c346 | 45d8e9377379f9d1d4e166e80415a8c1737f284d | refs/heads/master | 2023-04-05T06:30:04.726589 | 2021-04-13T23:35:20 | 2021-04-13T23:35:20 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,855 | py | # -*- coding: utf-8 -*-
# Copyright 2020 Google LLC
#
# 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 o... | [
"bazel-bot-development[bot]@users.noreply.github.com"
] | bazel-bot-development[bot]@users.noreply.github.com |
49c05d2676b8eed51218f2ef3306bf504397a1b1 | 0f0a7adfae45e07a896c5cd5648ae081d4ef7790 | /python数据结构/python黑马数据结构/排序于搜索/桶排序2.py | 081bee496e92f52adc6aa7b5f6d0b08d0687b4c3 | [] | no_license | renlei-great/git_window- | e2c578544c7a8bdd97a7a9da7be0464d6955186f | 8bff20a18d7bbeeaf714aa49bf15ab706153cc28 | refs/heads/master | 2021-07-19T13:09:01.075494 | 2020-06-13T06:14:37 | 2020-06-13T06:14:37 | 227,722,554 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 630 | py | lista = [12, 4, 5, 6, 22, 3, 3, 3, 3, 43, 654, 765, 7, 234]
def pail_sort(alist):
"""桶排序"""
n = len(alist)
cur = 0
while cur < n-1:
if alist[cur] > alist[cur+1]:
max_num = alist[cur]
cur += 1
max_li = [0] * (max_num +1)
for i in alist:
max_li[i] += 1
... | [
"1415977534@qq.com"
] | 1415977534@qq.com |
b12de6c619935508db19c3f39260210233e6a4ab | a0801d0e7325b31f0383fc68517e208680bb36d6 | /Kattis/rijeci.py | 7d0bdadf29031e7404c2c5a61ad6cc2e938add57 | [] | no_license | conormccauley1999/CompetitiveProgramming | bd649bf04438817c7fa4755df2c2c7727273b073 | a7e188767364be40f625612af3d16182f2d8d4de | refs/heads/master | 2023-05-14T13:19:32.678134 | 2023-05-11T16:07:33 | 2023-05-11T16:07:33 | 179,089,010 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 173 | py | K = int(raw_input())
if K == 1:
print 0, 1
else:
x = [0, 1]
y = [1, 1]
for i in range(0, K - 1):
t = [y[0]+x[0], y[1]+x[1]]
x = y
y = t
print x[0], y[0] | [
"conormccauley1999@gmail.com"
] | conormccauley1999@gmail.com |
50f5477a0bbb10e0d356fbe8aa777cae29d9dffa | 6ec91b363b077bffd33f15300a0935124e9fb915 | /Cracking_the_Code_Interview/Leetcode/14.DP/120.Triangle.py | a7e2879f610fe04793e1b1f2c35318dc4b3ff0fc | [] | no_license | lzxyzq/Cracking_the_Coding_Interview | 03232515ae8eb50394d46322d36b230d1a626fcf | 79dee7dab41830c4ff9e38858dad229815c719a0 | refs/heads/master | 2023-06-05T19:52:15.595289 | 2021-06-23T22:46:02 | 2021-06-23T22:46:02 | 238,068,000 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 805 | py | '''
@Author: your name
@Date: 2020-06-30 18:43:37
@LastEditTime: 2020-06-30 19:39:19
@LastEditors: Please set LastEditors
@Description: In User Settings Edit
@FilePath: /Cracking_the_Code_Interview/Leetcode/14.DP/120.Triangle.py
'''
# Given a triangle, find the minimum path sum from top to bottom. Each step you may mov... | [
"lzxyzq@gmail.com"
] | lzxyzq@gmail.com |
bf73bd5eda0d1303716e539c0d40f57d6ab13de8 | 22fe6ed51715486ebbc09e404504ed4d7a28c37d | /python-katas/57_CountHi.py | 6ef69b2da8a4251f4d619f0a62ab8c3d5042d32a | [] | no_license | Jethet/Practice-more | 1dd3ff19dcb3342a543ea1553a1a6fb0264b9c38 | 8488a679730e3406329ef30b4f438d41dd3167d6 | refs/heads/master | 2023-01-28T14:51:39.283741 | 2023-01-06T10:14:41 | 2023-01-06T10:14:41 | 160,946,017 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 378 | py | # Return the number of times the string 'hi' appears in a given string.
def count_hi(str):
return str.count('hi')
# CodingBat solution:
def count_hi(str):
sum = 0
for i in range(len(str)-1):
if str[i:i+2] == 'hi':
sum += 1 #or: sum = sum + 1
return sum
print(count_hi('abc hi ... | [
"henriette.hettinga@gmail.com"
] | henriette.hettinga@gmail.com |
13ab0721b3a33f3abbaaf46d0378e8b4649ba27f | d1f15554df2d5c0f74ddbcba6e870359841f682b | /wagtail/migrations/0057_page_locale_fields_notnull.py | 8f18589b5c9f794cba254c26312dd2d73645c5f1 | [
"BSD-3-Clause",
"LicenseRef-scancode-proprietary-license"
] | permissive | wagtail/wagtail | bd405f89b86e0c625fef0685fd6bfba41cf5cbfc | 06a7bc6124bf62675c09fbe0a4ed9bbac183e025 | refs/heads/main | 2023-09-04T06:22:51.601208 | 2023-09-01T15:22:00 | 2023-09-01T15:22:00 | 16,479,108 | 12,974 | 3,580 | BSD-3-Clause | 2023-09-14T10:45:04 | 2014-02-03T12:41:59 | Python | UTF-8 | Python | false | false | 793 | py | # Generated by Django 2.2.10 on 2020-07-13 10:17
from django.db import migrations, models
import django.db.models.deletion
import uuid
class Migration(migrations.Migration):
dependencies = [
("wagtailcore", "0056_page_locale_fields_populate"),
]
operations = [
migrations.AlterField(
... | [
"matt@west.co.tt"
] | matt@west.co.tt |
83852e477286aff2176a0246871748edca6bcef8 | c733e6b433914a8faba256c7853f5cf2cd39c62a | /Python/Leetcode Daily Practice/Heap/692. Top K Frequent Words.py | db9a25d3ab733cd3cdd4dd640983c8602e54fffe | [] | no_license | YaqianQi/Algorithm-and-Data-Structure | 3016bebcc1f1356b6e5f3c3e588f3d46c276a805 | 2e1751263f484709102f7f2caf18776a004c8230 | refs/heads/master | 2021-10-27T16:29:18.409235 | 2021-10-14T13:57:36 | 2021-10-14T13:57:36 | 178,946,803 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 385 | py | class Solution(object):
def topKFrequent(self, words, k):
from collections import Counter
import heapq
cnt = Counter(words) # o(n)
h = [(-freq, key) for key, freq in cnt.items()] # o(n)
return [heapq.heappop(h)[1] for i in range(k)] # o (k * logn)
print(Solution().topKFrequen... | [
"alicia.qyq@gmail.com"
] | alicia.qyq@gmail.com |
55b52764902ce153ec4c19dc6da9439dee543669 | 9a0eb3e292d57b59198c7c66a994372ced9cfa5b | /nodes/1.x/python/String.ReplaceIllegalFilenameCharacters.py | a922b676f1485306810fd884001c9016638051ed | [
"MIT"
] | permissive | andydandy74/ClockworkForDynamo | 544ddf0893f5c0072fca7934f4e128001771f767 | 528400c667c4c3f2b51814af84e85c8fab8a8059 | refs/heads/master | 2023-08-19T03:07:33.489926 | 2023-08-13T04:31:17 | 2023-08-13T04:31:17 | 15,043,988 | 184 | 100 | MIT | 2023-09-04T18:47:40 | 2013-12-09T10:11:01 | Python | UTF-8 | Python | false | false | 430 | py | strings = IN[0]
replace = IN[1]
strlist = []
for str in strings:
str = str.replace('/', replace)
str = str.replace('?', replace)
str = str.replace('<', replace)
str = str.replace('>', replace)
str = str.replace('\\', replace)
str = str.replace(':', replace)
str = str.replace('*', replace)
str = str.replace('|',... | [
"dieckmann@caad.arch.rwth-aachen.de"
] | dieckmann@caad.arch.rwth-aachen.de |
48b15be505f68c01bcbe37105ce08e8d80a90959 | 93b704572dd4f36ae488f931fbe8372a215b13ad | /clean_solutions/day3.py | d56d9cf4949958790cfde7211c768208ff456079 | [] | no_license | Goldenlion5648/AdventOfCode2020Live | 7cfdf6804402fdf42d10c70742579522c487f501 | e3f5908e8747991b50bdde339ad9ecba527b1168 | refs/heads/master | 2023-04-04T12:48:21.318124 | 2021-04-08T16:42:13 | 2021-04-08T16:42:13 | 317,414,264 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 736 | py |
'''
Right 1, down 1.
Right 3, down 1. (This is the slope you already checked.)
Right 5, down 1.
Right 7, down 1.
Right 1, down 2.
'''
from collections import *
with open("input3.txt") as f:
# a = list(map(int,f.read().strip().split("\n")))
board = f.read().strip().split("\n")
def slide(xChange, yChange):
... | [
"coboudinot@gmail.com"
] | coboudinot@gmail.com |
eabc327817af3553828fe0ffc5f9a44d5e5d1951 | 52b5773617a1b972a905de4d692540d26ff74926 | /.history/mushroomPicker_20200729130815.py | f6b760f3a1112376d639f98641c3cd38b7ba4176 | [] | no_license | MaryanneNjeri/pythonModules | 56f54bf098ae58ea069bf33f11ae94fa8eedcabc | f4e56b1e4dda2349267af634a46f6b9df6686020 | refs/heads/master | 2022-12-16T02:59:19.896129 | 2020-09-11T12:05:22 | 2020-09-11T12:05:22 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,178 | py | '''
You are given a non-empty, zero-indexed array A of n (1 � n � 100 000) integers
a0, a1, . . . , an−1 (0 � ai � 1 000). This array represents number of mushrooms growing on the
consecutive spots along a road. You are also given integers k and m (0 � k, m < n).
A mushroom picker is at spot number k on the road and sh... | [
"mary.jereh@gmail.com"
] | mary.jereh@gmail.com |
ad5d5361d58d186ea6682f1b01c9158b0e151206 | 1255b4c76aa2def0d8ca07ff75ef264383de36e3 | /main.py | 8b482da2a9acf7567e56eec60c0e4c881703abac | [] | no_license | thepixelboy/flask-auth | bcbe2ce182e54743acfa70860f975b059952c65c | e49903b65c9451891b61138e1b5453ea29f733d1 | refs/heads/main | 2023-07-10T00:41:46.442728 | 2021-08-23T16:56:39 | 2021-08-23T16:56:39 | 399,182,979 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,337 | py | from os import name
from flask import Flask, render_template, request, url_for, redirect, flash, send_from_directory
from werkzeug.security import generate_password_hash, check_password_hash
from flask_sqlalchemy import SQLAlchemy
from flask_login import UserMixin, login_user, LoginManager, login_required, current_user... | [
"34570952+thepixelboy@users.noreply.github.com"
] | 34570952+thepixelboy@users.noreply.github.com |
5317b35317ba1ab2da314d6bd8ad9be085d19480 | 13f4a06cd439f579e34bf38406a9d5647fe7a0f3 | /nn_ns/parsing/FS/readme.py | d02accd2f405f4744acde147164ec31870528870 | [] | no_license | edt-yxz-zzd/python3_src | 43d6c2a8ef2a618f750b59e207a2806132076526 | 41f3a506feffb5f33d4559e5b69717d9bb6303c9 | refs/heads/master | 2023-05-12T01:46:28.198286 | 2023-05-01T13:46:32 | 2023-05-01T13:46:32 | 143,530,977 | 2 | 2 | null | null | null | null | UTF-8 | Python | false | false | 2,141 | py | 3 froms:
FSM, [Rule], regular_expression
FSM:
TotalState : FSM
formal - FSM{initial :: TotalState,
finals :: Set TotalState,
error :: TotalState,
transition :: Map TotalState (Map Symbol TotalState)
... | [
"wuming_zher@zoho.com.cn"
] | wuming_zher@zoho.com.cn |
51a7abc5c786abeb3e55dc95ed53aef57e85b34a | 94df6050f2a262da23f62dd678ccc4366b7657fc | /temporary/bin/tqdm | 9efa8c44cdb5ce4f8dc9684a0b3710267894d570 | [] | no_license | EkenePhDAVHV/phd-autonomous-cars-frank | 29cc2fc608db53d4d060422022dc5019cf6360f0 | 1daed3425bfad99dac31543fbeb7950e25aa2878 | refs/heads/main | 2023-04-29T06:02:59.444072 | 2021-05-23T11:04:07 | 2021-05-23T11:04:07 | 357,157,735 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 265 | #!/home/ekene/PycharmProjects/phd-autonomous-cars-frank/temporary/bin/python
# -*- coding: utf-8 -*-
import re
import sys
from tqdm.cli import main
if __name__ == '__main__':
sys.argv[0] = re.sub(r'(-script\.pyw|\.exe)?$', '', sys.argv[0])
sys.exit(main())
| [
"e.f.ozioko@pgr.reading.ac.uk"
] | e.f.ozioko@pgr.reading.ac.uk | |
b3673d87cd687e139daef7c90d95e0a9126b841d | 954df5fb1ceaf64fe3004e0b072b78024065cdd0 | /virtual/Lib/site-packages/future/moves/_markupbase.py | 41c4f96c55552b677772b61ba497a16ba84b3df8 | [] | no_license | chelseyrandolph/cs440_DatabaseUI | 7dc5b4c3d0a4e72023db61f4a613fc889bc69f86 | 28355cdfe0f4732568f1f8e43e2ce7809b4fc260 | refs/heads/master | 2022-06-06T19:18:31.819483 | 2020-05-05T20:51:58 | 2020-05-05T20:51:58 | 259,436,551 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 151 | py | from __future__ import absolute_import
from future.utils import PY3
if PY3:
pass
else:
__future_module__ = True
from markupbase import *
| [
"chelseyrrandolph@gmail.com"
] | chelseyrrandolph@gmail.com |
17af078221d30f88e222eb9d6c5861dc1a20e88a | 9743d5fd24822f79c156ad112229e25adb9ed6f6 | /xai/brain/wordbase/verbs/_disintegrating.py | 532e7be5907664219ed247bb6f5173a80c0ad3de | [
"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 | 282 | py |
from xai.brain.wordbase.verbs._disintegrate import _DISINTEGRATE
#calss header
class _DISINTEGRATING(_DISINTEGRATE, ):
def __init__(self,):
_DISINTEGRATE.__init__(self)
self.name = "DISINTEGRATING"
self.specie = 'verbs'
self.basic = "disintegrate"
self.jsondata = {}
| [
"xingwang1991@gmail.com"
] | xingwang1991@gmail.com |
50ac6709acfc86d952d4ef089c648926671f477b | 8acffb8c4ddca5bfef910e58d3faa0e4de83fce8 | /ml-flask/Lib/site-packages/sacremoses/corpus.py | 721a5bbd1be20eb165825ba3c6dae6936c425b69 | [
"MIT"
] | permissive | YaminiHP/SimilitudeApp | 8cbde52caec3c19d5fa73508fc005f38f79b8418 | 005c59894d8788c97be16ec420c0a43aaec99b80 | refs/heads/master | 2023-06-27T00:03:00.404080 | 2021-07-25T17:51:27 | 2021-07-25T17:51:27 | 389,390,951 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 129 | py | version https://git-lfs.github.com/spec/v1
oid sha256:d72f15b792d94c6d388af9f8c568d412c657f055c925abdae378464c275c54a4
size 5016
| [
"yamprakash130@gmail.com"
] | yamprakash130@gmail.com |
d31f11bddf9791dee17880f0c0425c13ad495a90 | ab6c6559d9cfac36c3c4ece192fa2300767662d1 | /Python Game Development for Beginners - Working Files/Chapter 5/Increasing Challenge with Levels Part I/main.py | 38ecd797fc5c5f6c15d8d84cfd91391e4842c047 | [] | no_license | Igor-Nosatov/PythonGameDev_Trinket | 962b86572c74c64652a24768dfec2101fcae221f | e6166f69307ded6880b0aaa3299c0a151807bb9c | refs/heads/master | 2020-06-24T20:22:57.187289 | 2016-05-03T10:33:26 | 2016-05-03T10:33:26 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,111 | py | # import the turtle module so we can use all the neat code it contains
import turtle
from helpercode import BoxTurtle, printwin, checkpos, maketurtles
from time import sleep
from random import randint, choice
# Create variables to contain our BoxTurtle objects
boxturtles = maketurtles()
# Create a variable `tina` th... | [
"lrbeaver@gmail.com"
] | lrbeaver@gmail.com |
a3f236ba9acc0a4b6555b96f6a332662b412630d | 4591b4c66f443a2a54c858a8f3b529b8f388a5e4 | /workshops/migrations/0009_auto_20141201_0016.py | 63d5f5e8ede381a4c432f6a8b3b7406a26f704cf | [
"MIT"
] | permissive | sburns/amy | 39e11b48212304c7620e56a66c2f585d3d5951ae | 7a315ba934f45e2234aaf1ea0e953b88a6239e10 | refs/heads/master | 2020-12-28T20:31:22.103801 | 2015-01-20T20:27:31 | 2015-01-20T20:27:31 | 27,539,122 | 0 | 1 | null | 2015-01-27T17:43:06 | 2014-12-04T12:18:40 | Python | UTF-8 | Python | false | false | 451 | py | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
class Migration(migrations.Migration):
dependencies = [
('workshops', '0008_person'),
]
operations = [
migrations.AlterField(
model_name='person',
name='email... | [
"gvwilson@third-bit.com"
] | gvwilson@third-bit.com |
ff27d1695dcafdf6c0990e339bae4ebdc384fe83 | c5a921726a3805663d26a2dbaa47e49497931d4e | /Algorithms/challenges/lc437_path_sum_3.py | 3c2379a605bdceaccb345b85e6736d43f336db08 | [] | no_license | snowdj/cs_course | a50d07548198b4202e8abde01ec572e2cce38ab3 | fa6504cb5145d10952f4615478fa745f4b35ba13 | refs/heads/master | 2020-03-17T15:18:52.190747 | 2018-05-13T08:08:51 | 2018-05-13T08:08:51 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,111 | py | """
Time: O(n)
Space: O(n)
You are given a binary tree in which each node contains an integer value.
Find the number of paths that sum to a given value.
The path does not need to start or end at the root or a leaf, but it must go downwards (traveling only from parent nodes to child nodes).
The tree has no more tha... | [
"jesse@liu.onl"
] | jesse@liu.onl |
2113063d729a811629f3bc376ba4bf53a6246231 | ea2f7efb514b7e33eb205519cfffc356f58a9816 | /Clases en Python/__repr()__.py | 6f40939cad236fb3207cb6550a444771c025da4d | [] | no_license | MGijon/Learning-Python | fa79071bf53172743e96d2c614be2963a5107a9d | 728f8d7e30729a965c5a093e08005d715aa6e46b | refs/heads/master | 2021-06-28T15:44:34.082472 | 2019-02-23T17:58:06 | 2019-02-23T17:58:06 | 105,207,614 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,145 | py | ''' __REPR()__: Nos devuelve una cadena de texto con la representación única de un objeto. Es útil, por ejemplo, a la hora de depurar un error.
------------
A la representación única accedemos de dos formas: con la función repr() o con las dobles comillas hacia atrás (``).
Si __repr()__ no está definido, ... | [
"mgijon94@gmail.com"
] | mgijon94@gmail.com |
70d28bdb9d82aa11081654760958d50a0e9b5ae3 | 55647a80c8b412af9df0ba3f50595cc2f29c25e6 | /res/scripts/client/gui/battle_control/controllers/consumables/__init__.py | de6cdb4912e1bd8a0b0ace2de737e8453afc24ad | [] | no_license | cnsuhao/WOT-0.9.17-CT | 0035eb6070fb4fab8d8ee9f8bbc676c10d511cfb | d1f932d8cabaf8aa21708622e87f83c8d24d6451 | refs/heads/master | 2021-06-08T18:11:07.039293 | 2016-11-19T19:12:37 | 2016-11-19T19:12:37 | null | 0 | 0 | null | null | null | null | WINDOWS-1250 | Python | false | false | 1,212 | py | # 2016.11.19 19:48:19 Střední Evropa (běžný čas)
# Embedded file name: scripts/client/gui/battle_control/controllers/consumables/__init__.py
from gui.battle_control.controllers.consumables import ammo_ctrl
from gui.battle_control.controllers.consumables import equipment_ctrl
from gui.battle_control.controllers.consumab... | [
"info@webium.sk"
] | info@webium.sk |
7d72e289cd1a204ce8d9543b02b422fad79372c9 | 9848584d5f1858692fb4cdbe793bc91ed3be920e | /coding/00239-sliding-window-max/solution.py | aef03fa50138e58d6f572230081501d70f98fcf3 | [] | no_license | misaka-10032/leetcode | 1212223585cc27d3dfc6d2ca6a27770f06e427e3 | 20580185c6f72f3c09a725168af48893156161f5 | refs/heads/master | 2020-12-12T09:45:31.491801 | 2020-09-14T00:18:19 | 2020-09-14T00:18:19 | 50,267,669 | 3 | 1 | null | null | null | null | UTF-8 | Python | false | false | 1,055 | py | #!/usr/bin/env python3
# encoding: utf-8
import collections
from typing import List
class DecreasingGarbageCollectionQueue:
def __init__(self, ttl: int):
self._ttl = ttl
self._q = collections.deque()
def append(self, t: int, v: int):
# First, clean up the stale elements.
whil... | [
"longqicai@gmail.com"
] | longqicai@gmail.com |
ed33f94bbd108c9000ac2d9dc0d03f9bc890dcbc | 1f689e448d8b510ea6575590cb6920048b4e9aea | /leetcode/202_happy_number.py | 238115bb7972505ac6b64021c56ccdb3faf05303 | [] | no_license | lijenpan/python | 52c6061ff90c611efd039b1858339edbefdb5ad0 | 7f67045a83bd2592ccc399420194094fb78404b8 | refs/heads/master | 2020-05-30T10:53:15.634090 | 2016-12-02T20:50:28 | 2016-12-02T20:50:28 | 7,646,477 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 977 | py | """
Write an algorithm to determine if a number is "happy".
A happy number is a number defined by the following process: Starting with any positive integer, replace the number by the sum of the squares of its digits, and repeat the process until the number equals 1 (where it will stay), or it loops endlessly in a cycl... | [
"noreply@github.com"
] | lijenpan.noreply@github.com |
34457b9f1292450d30115f4b973ae6c397ad444b | f5d1e8b54ddbc51a9ef1b868eee93096d9b0fbeb | /weapp/tools/weather/views.py | bc7bb0580ac24124ade857e06b690326ad36e083 | [] | no_license | chengdg/weizoom | 97740c121724fae582b10cdbe0ce227a1f065ece | 8b2f7befe92841bcc35e0e60cac5958ef3f3af54 | refs/heads/master | 2021-01-22T20:29:30.297059 | 2017-03-30T08:39:25 | 2017-03-30T08:39:25 | 85,268,003 | 1 | 3 | null | null | null | null | UTF-8 | Python | false | false | 6,497 | py | # -*- coding: utf-8 -*-
__author__ = "liupeiyu"
import time
from datetime import timedelta, datetime, date
import urllib, urllib2
import os
import json
from django.http import HttpResponseRedirect, HttpResponse
from django.template import Context, RequestContext
from django.contrib.auth.decorators import... | [
"jiangzhe@weizoom.com"
] | jiangzhe@weizoom.com |
7fc1aab1de73aa78dbb82daf249adb798a862e6e | ac0e9a702e73739209b24ba3f6d9297647e06b76 | /Example Files/Intermediate/phonebook_example_unittest/test_phonebook.py | 877ed597231b563f8b52e0fd04a0c7d5d40c137e | [] | no_license | afettouhi/PyStudentManager | 9c256c38b20136f10b86fb2e2270bb5848be802d | 71343bc52e5426b2267f068bd6af2e66c0807f08 | refs/heads/master | 2020-05-14T16:53:09.501889 | 2019-06-07T14:22:44 | 2019-06-07T14:22:44 | 181,881,548 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,424 | py |
import unittest
from phonebook import Phonebook
class PhonebookTest(unittest.TestCase):
def setUp(self):
self.phonebook = Phonebook()
def test_lookup_entry_by_name(self):
self.phonebook.add("Bob", "12345")
self.assertEqual("12345", self.phonebook.lookup("Bob"))
... | [
"A.Fettouhi@gmail.com"
] | A.Fettouhi@gmail.com |
35757bf0f4d8afe1c0b99428daee2cf27e28c9fd | 97af3c1e09edbb09dfabe0dd8cb5334735d874b6 | /code/lib/python/console/clint/textui/progress.py | 960c35b9cb5d9319ca98f0dd9a3e887086ff01bf | [] | no_license | joyrexus/ldp | 31d3e155110e3249ad0f7c97f1b663120c6a125d | d0e15f051bb175fc66a4647b3001b31702aa16f3 | refs/heads/master | 2021-01-17T14:30:46.115805 | 2015-05-05T20:20:14 | 2015-05-05T20:20:14 | 11,434,923 | 2 | 2 | null | null | null | null | UTF-8 | Python | false | false | 1,180 | py | # -*- coding: utf-8 -*-
"""
clint.textui.progress
~~~~~~~~~~~~~~~~~
This module provides the progressbar functionality.
"""
from __future__ import absolute_import
import sys
STREAM = sys.stderr
BAR_TEMPLATE = '%s[%s%s] %i/%i\r'
BAR_EMPTY_CHAR = '-'
BAR_FILLED_CHAR = '='
DOTS_CHAR = '.'
def bar(it, label='', w... | [
"joyrexus@gmail.com"
] | joyrexus@gmail.com |
f32f2075cffb1ee258d2840c969615cb58be0bbf | f0d713996eb095bcdc701f3fab0a8110b8541cbb | /qM6zWQM7gdfPgE9Hh_10.py | ac926ffffc597d07e0e765dc6f988e28824815d1 | [] | 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 | 1,147 | py | """
Given a _dictionary_ of some items with _star ratings_ and a _specified star
rating_ , return a new dictionary of items **which match the specified star
rating**. Return `"No results found"` if _no item_ matches the _star rating_
given.
### Examples
filter_by_rating({
"Luxury Chocolates" : "*****",
... | [
"daniel.reich@danielreichs-MacBook-Pro.local"
] | daniel.reich@danielreichs-MacBook-Pro.local |
c93abfeac1a23ee94be4cfa675344b58b62a7439 | 42a812ac785752921dcdddd4ae56064b51452b39 | /bulletin/post/tests/test_post_view.py | cd2fe8bc9b73e4f73864e1875b41fc2744fb8149 | [] | no_license | Pre-Onboarding-Listerine/aimmo-assignment-team-1 | e4a15d3e71f1985febf911360691389f5996f0fb | d94dd7482f065ac1b020bb500984740c13af14e6 | refs/heads/main | 2023-09-02T12:23:49.693075 | 2021-11-03T00:25:18 | 2021-11-03T00:25:18 | 423,444,898 | 1 | 3 | null | 2021-11-02T16:35:38 | 2021-11-01T11:46:19 | Python | UTF-8 | Python | false | false | 4,881 | py | import json
import unittest
from datetime import datetime
from http import HTTPStatus
from unittest import mock
from unittest.mock import MagicMock
import jwt
from assertpy import assert_that
from django.conf import settings
from django.test import Client
from member.models import Member
from ..dto.deleted_post_id i... | [
"rlawndhks217@gmail.com"
] | rlawndhks217@gmail.com |
74458f6a29b52a4aba737448865b8f86ca8a360b | 23611933f0faba84fc82a1bc0a85d97cf45aba99 | /google-cloud-sdk/lib/surface/version.py | 7d7321ca5431114f3472d2997a60ebba92f03cde | [
"LicenseRef-scancode-unknown-license-reference",
"Apache-2.0"
] | permissive | KaranToor/MA450 | 1f112d1caccebdc04702a77d5a6cee867c15f75c | c98b58aeb0994e011df960163541e9379ae7ea06 | refs/heads/master | 2021-06-21T06:17:42.585908 | 2020-12-24T00:36:28 | 2020-12-24T00:36:28 | 79,285,433 | 1 | 1 | Apache-2.0 | 2020-12-24T00:38:09 | 2017-01-18T00:05:44 | Python | UTF-8 | Python | false | false | 1,488 | py | # Copyright 2013 Google Inc. 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 required by applicable law or ag... | [
"toork@uw.edu"
] | toork@uw.edu |
d7f2ac70b8cb10c2f05a112b0c00c9af580c876b | fcb87e969a3989f2023f3847a5f0e1289a0a8694 | /sip/execution_control/configuration_db/sip_config_db/scheduling/_scheduling_object_list.py | 15f0af7ef8ff43197a068b6a31c7c792caf4f15b | [
"BSD-3-Clause"
] | permissive | SKA-ScienceDataProcessor/integration-prototype | 299eb0aa41ba9c7f683f5bac101af5a19fccb171 | 5875dc0489f707232534ce75daf3707f909bcd15 | refs/heads/master | 2021-05-01T05:02:16.697902 | 2019-07-28T22:32:05 | 2019-07-28T22:32:05 | 58,473,707 | 3 | 10 | BSD-3-Clause | 2021-03-25T22:21:08 | 2016-05-10T15:41:14 | C++ | UTF-8 | Python | false | false | 3,436 | py | # -*- coding: utf-8 -*-
"""Base class for list of scheduling or processing block data objects."""
from typing import List
from ._scheduling_object import SchedulingObject
from .. import ConfigDb
from .._events.event_queue import EventQueue
from .._events.pubsub import get_subscribers, publish, subscribe
DB = ConfigDb... | [
"ben.mort@gmail.com"
] | ben.mort@gmail.com |
fcdbe8b38ae560684105297029179656a604f2db | 321b4ed83b6874eeb512027eaa0b17b0daf3c289 | /222/222.count-complete-tree-nodes.233499249.Accepted.leetcode.py | 07968f423174e017c6f9c7febffa58330579725a | [] | no_license | huangyingw/submissions | 7a610613bdb03f1223cdec5f6ccc4391149ca618 | bfac1238ecef8b03e54842b852f6fec111abedfa | refs/heads/master | 2023-07-25T09:56:46.814504 | 2023-07-16T07:38:36 | 2023-07-16T07:38:36 | 143,352,065 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 655 | py | class TreeNode(object):
def __init__(self, x):
self.val = x
self.left = None
self.right = None
class Solution(object):
def countNodes(self, root):
if not root:
return 0
left_subtree = self.left_depth(root.left)
right_subtree = self.left_depth(root.ri... | [
"huangyingw@gmail.com"
] | huangyingw@gmail.com |
102cfb4a48484d5440f4765e4468f290cddc203a | ea9f2c578e479fcaebbba84d2a1fe63e96f9145d | /src/common/models/user.py | 4d4c9b4f978ae046c363d45934812a5da49ed9b4 | [] | no_license | spandey2405/onlinecoderbackend | 1a6bd278f725ae5b1ad1c57b951ac5f9f87b71eb | afffd81c027a46247dd47e2ca02ab981e124b09a | refs/heads/master | 2021-01-17T07:57:03.077054 | 2016-08-01T13:41:50 | 2016-08-01T13:41:50 | 64,668,772 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,411 | py | from django.db import models
from src.common.libraries.constants import *
import binascii, os, uuid
class UserManager(models.Manager):
def generate_userid(self):
return str(uuid.uuid4())
def generate_salt(self):
return binascii.hexlify(os.urandom(SALT_LENGTH/2)).decode()
class User(models.Mo... | [
"spandey2405@gmail.com"
] | spandey2405@gmail.com |
e3d8cb3403b6a91ceba70ae0162d75363b5c0a9d | 01abb5fe2d6a51e8ee4330eaead043f4f9aad99d | /Repo_Files/Zips/plugin.video.streamhub/resources/lib/smodules/trailer.py | 729c4e3dd4f78c4945f1e6ce4a8b48274938d418 | [] | no_license | MrAnhell/StreamHub | 01bb97bd3ae385205f3c1ac6c0c883d70dd20b9f | e70f384abf23c83001152eae87c6897f2d3aef99 | refs/heads/master | 2021-01-18T23:25:48.119585 | 2017-09-06T12:39:41 | 2017-09-06T12:39:41 | 87,110,979 | 0 | 0 | null | 2017-04-03T19:09:49 | 2017-04-03T19:09:49 | null | UTF-8 | Python | false | false | 3,905 | py | # -*- coding: utf-8 -*-
'''
Exodus Add-on
Copyright (C) 2016 Exodus
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any l... | [
"mediahubiptv@gmail.com"
] | mediahubiptv@gmail.com |
b843de38c9488e62441a89a633f1336a972f423a | 0d91c86aa0c70115d70f09e3e45460df73dcc652 | /alpha_a.py | d8263fba6f7a743eb66fc076ec23ea33da0d66a6 | [] | no_license | Michael-Gong/DLA_project | 589791a3ca5dba7a7d5b9a170c9e2ad712a3ae36 | 3a6211451cc404d772246f9c2b60e0c97576cfef | refs/heads/master | 2021-04-27T08:11:37.414851 | 2019-01-18T05:24:40 | 2019-01-18T05:24:40 | 122,650,552 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,172 | py | %matplotlib inline
#import sdf
import matplotlib
import matplotlib as mpl
mpl.style.use('https://raw.githubusercontent.com/Michael-Gong/DLA_project/master/style')
#matplotlib.use('agg')
import matplotlib.pyplot as plt
import numpy as np
from numpy import ma
from matplotlib import colors, ticker, cm
from matplotlib.mlab... | [
"noreply@github.com"
] | Michael-Gong.noreply@github.com |
ff4ae30a5bc2aa2818fcf1314ca8b8c98913fbaf | c8be7becd7466bd6639382156e0886fce3cfb386 | /array_list_repeat.py | cd49a02546a3accdc328440da4354653614c9424 | [] | no_license | wlgud0402/pyfiles | 864db71827aba5653d53320322eb8de8b0a5fc49 | 0e8b96c4bbfb20e1b5667ce482abe75061662299 | refs/heads/master | 2021-02-28T00:42:51.321207 | 2020-03-09T10:48:52 | 2020-03-09T10:48:52 | 245,648,824 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 393 | py | #반복문을 사용한 리스트 생성
array = []
for i in range(0,20,2):
array.append(i * i)
print(array)
print()
#리스트 안에 for문 사용하기
list_a = [z * z for z in range(0, 20, 2)] #최종결과를 앞에 작성 z*z
print(list_a)
print()
#if문도 추가하기
newarray = [1,2,3,4,5,6,7,8,9]
output = [number for number in newarray if number != 3]
print(output) | [
"wlgudrlgus@naver.com"
] | wlgudrlgus@naver.com |
3fabf4f4ba845759d4b8fc8576fc5bc284056ab8 | a4dfbafdb2d1cc39534a481747fe9746ebb4ef7a | /src/models/base_models/resnest_model.py | 158eb4a786862e66ce97c979d9f509c5c8e10334 | [] | no_license | huangchuanhong/dist_face_pytorch | 3f41045f662de0f9826bc5041bdd2b9abbcb9558 | dc662b713564b2c3f5a61d4ad0e8a78e4aa54a84 | refs/heads/master | 2022-12-31T23:01:26.997504 | 2020-10-26T08:29:39 | 2020-10-26T08:29:39 | 264,177,084 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,114 | py | import torch.nn as nn
from .backbones import ResNest
from ..registry import BASE_MODEL
from ..utils import constant_init, normal_init, kaiming_init
@BASE_MODEL.register_module
class ResNestModel(nn.Module):
def __init__(self,
feature_dim,
**kwargs):
super(ResNestModel, sel... | [
"huangchuanhong@xgrobotics.com"
] | huangchuanhong@xgrobotics.com |
d0303d53dd3eba23fd2b686900359aa35a47c0bb | 18aee5d93a63eab684fe69e3aa0abd1372dd5d08 | /python/paddle/vision/models/alexnet.py | 4239395c03319dd88ea9923153eb9cc250de73f0 | [
"Apache-2.0"
] | permissive | Shixiaowei02/Paddle | 8d049f4f29e281de2fb1ffcd143997c88078eadb | 3d4d995f26c48f7792b325806ec3d110fc59f6fc | refs/heads/develop | 2023-06-26T06:25:48.074273 | 2023-06-14T06:40:21 | 2023-06-14T06:40:21 | 174,320,213 | 2 | 1 | Apache-2.0 | 2022-12-28T05:14:30 | 2019-03-07T10:09:34 | C++ | UTF-8 | Python | false | false | 7,002 | py | # copyright (c) 2022 PaddlePaddle Authors. All Rights Reserve.
#
# 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 applica... | [
"noreply@github.com"
] | Shixiaowei02.noreply@github.com |
af1b04d6cf97703519e4498002d19f6698381301 | 5c8139f1e57e06c7eaf603bd8fe74d9f22620513 | /PartB/Py判断是否为合理的括号.py | 2a3605334e6226a0c403baec737ed955220c4db7 | [] | no_license | madeibao/PythonAlgorithm | c8a11d298617d1abb12a72461665583c6a44f9d2 | b4c8a75e724a674812b8a38c0202485776445d89 | refs/heads/master | 2023-04-03T07:18:49.842063 | 2021-04-11T12:02:40 | 2021-04-11T12:02:40 | 325,269,130 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 356 | py |
class Solution:
def isValid(self, s: str) -> bool:
dic = {'{': '}', '[': ']', '(': ')', '?': '?'}
stack = ['?']
for c in s:
if c in dic: stack.append(c)
elif dic[stack.pop()] != c: return False
return len(stack) == 1
if __name__ == '__main__':
s = Solut... | [
"2901429479@qq.com"
] | 2901429479@qq.com |
01e81a1f99193030b8a12ff979b36ab877ecbdbd | 9dd14d428b2513376f0e1c3ec06a3b06fc60fc73 | /solution/operators/sdi_pandas_0.0.37/sdi_pandas_0.0.36/content/files/vflow/subengines/com/sap/python36/operators/sdi_pandas/sample/sample.py | 41fd2ff0d55d9875b9f252b305861c73eef12369 | [
"MIT"
] | permissive | thhapke/sdi_pandas | 38b1a3a688c62621fb858f03e4ac2f3bcbc20b88 | 7a9108007459260a30ea7ee404a76b42861c81c5 | refs/heads/master | 2020-07-24T10:40:05.643337 | 2020-04-08T06:59:52 | 2020-04-08T06:59:52 | 207,894,698 | 3 | 1 | null | null | null | null | UTF-8 | Python | false | false | 6,795 | py | import sdi_utils.gensolution as gs
import sdi_utils.set_logging as slog
import sdi_utils.textfield_parser as tfp
import sdi_utils.tprogress as tp
import pandas as pd
EXAMPLE_ROWS = 5
try:
api
except NameError:
class api:
class Message:
def __init__(self,body = None,attributes = ""):
... | [
"53856509+thhapke@users.noreply.github.com"
] | 53856509+thhapke@users.noreply.github.com |
1131b28b0a153d0d74427cea61cfce5a5b8d28f4 | 90cc37b6cc67bce397411631587a14be72085d2e | /tests/unit/test_deployment.py | 6cda651e7bc2a1406caa35b50b68d8220d34e492 | [
"Unlicense"
] | permissive | michaeljoseph/righteous | 49d36bb895945a26d5db4b3d13a2e303aef3ef93 | ba95c574a94df85aca33397cc77b053e7f545705 | refs/heads/master | 2016-09-06T11:01:57.478168 | 2013-10-17T11:00:27 | 2013-10-17T11:00:27 | 2,584,142 | 2 | 1 | null | 2013-10-18T14:53:04 | 2011-10-16T00:07:14 | Python | UTF-8 | Python | false | false | 2,389 | py | from righteous.compat import urlencode
from .base import ApiTestCase
import righteous
class DeploymentTestCase(ApiTestCase):
def setUp(self):
self.setup_patching('righteous.api.deployment._request')
super(DeploymentTestCase, self).setUp()
def test_list_deployments(self):
righteous.in... | [
"michaeljoseph+github@gmail.com"
] | michaeljoseph+github@gmail.com |
da6990b212765548549d6a7ed409b29dfd3ff68a | 758ca5e2bf50016fbac7022ac5f9036aa8aa099b | /LeetCodeWeb.py | 3359b7e6c9cd5b4f92bd6298419aa98886ca70f5 | [] | no_license | zhantong/leetcode-web | 04f17901e4bf5a6065e35dd126dd7bbcc8b1128f | 3f79f5463e77ed7eab8b808a7004eea8c29fc35e | refs/heads/master | 2021-01-02T22:54:54.797228 | 2017-10-19T02:00:48 | 2017-10-19T02:00:48 | 99,420,755 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,913 | py | from flask import Flask
from flask import render_template
from flask import request
from flask import redirect
from flask import g
import os.path
from pygments import highlight
from pygments.lexers import get_lexer_by_name
from pygments.formatters import HtmlFormatter
import sqlite3
app = Flask(__name__)
ROOT = os.pat... | [
"zhantong1994@163.com"
] | zhantong1994@163.com |
330058010818406687c80f7723e26b445b282e69 | 5be2fc94724cc05d2dc449e0f5b40d9fb07edd51 | /tests/test_biosample.py | 4e618528f17766b407935e78b014a86d7a17a3b8 | [
"MIT"
] | permissive | LucaCappelletti94/encodeproject | b84614683c8652f812f2c01b0002903d849a080b | a2bcae8cfbb505a978ecea95c3a007f65625c57a | refs/heads/master | 2022-05-07T13:16:58.774258 | 2022-04-27T07:51:22 | 2022-04-27T07:51:22 | 216,822,791 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 245 | py | from encodeproject import biosample, biosamples
def test_biosample():
biosample("ENCSR000EDP")
biosample("ENCSR000EDP", False)
def test_biosamples():
biosamples(["ENCFF454HMH", "ENCFF663AYS"])
biosamples(["ENCSR000EDP"], False) | [
"cappelletti.luca94@gmail.com"
] | cappelletti.luca94@gmail.com |
14cc45de89528b42640f58cba86eb2f58860bbcc | 1879e4df9cff25bc0c32ff63aedc859301062f9d | /0x05-personal_data/encrypt_password.py | 088ba68a96806e4bfba46db604229b5f920df220 | [] | no_license | rakiasomai/holbertonschool-web_back_end | 0f9d36160c9762df0826adcac66b009d1076043b | f5aeeda56def93fe13d901dd52217b0dbd4124e9 | refs/heads/master | 2023-02-28T10:02:54.929275 | 2021-02-06T22:17:04 | 2021-02-06T22:17:04 | 305,420,230 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 389 | py | #!/usr/bin/env python3
''' Personal data '''
import bcrypt
def hash_password(password: str) -> bytes:
''' def hash password '''
var = password.encode('utf-8')
return bcrypt.hashpw(var, bcrypt.gensalt())
def is_valid(hashed_password: bytes, password: str) -> bool:
''' def is valid '''
var = pass... | [
"somai.rakia@hotmail.fr"
] | somai.rakia@hotmail.fr |
5f62efd77cda877b0f315654e66fcb575dcf38a5 | b21180985c994c19e850ef51d5d87c6bf595dc21 | /wechat/queryexp.py | efc683b5018ed5bac565cde68dd6455b49f93e69 | [] | no_license | hldai/labelwc | c74d3af98576acd514f9136db663ca4cbd95708f | 38c969c61f240e49d5475be716c6b159b57220cd | refs/heads/master | 2020-12-02T22:18:06.991302 | 2017-08-13T13:04:44 | 2017-08-13T13:04:44 | 96,111,637 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,942 | py | from utils import load_names_file
def load_acronym_to_name(acronym_name_file, exclude_strs):
acr_name_dict = dict()
f = open(acronym_name_file, 'r')
for line in f:
line = line.strip().decode('utf-8')
acr, name, _ = line.split('\t')
if exclude_strs and acr in exclude_strs:
... | [
"hldai@outlook.com"
] | hldai@outlook.com |
b7d65448e1c658d3cc0b42437060aee5c8c46e72 | ca002961fa07883ff79ea67713bbc79e0ac79d28 | /plugins/brains/BBWander.py | 5c642987580df24602062aadb1efb8cb65ea2809 | [] | no_license | mindgitrwx/pyrobot3 | e51f8f1bac01a2509f2d89668102770053c16f56 | 45216c0c11f5efaaa4042916b2fe8eaac00fc4a7 | refs/heads/master | 2020-03-23T19:28:44.395949 | 2018-10-03T22:06:42 | 2018-10-03T22:06:42 | 141,980,775 | 0 | 3 | null | 2018-09-14T11:20:00 | 2018-07-23T07:53:27 | Python | UTF-8 | Python | false | false | 2,185 | py | # A Behavior-based control system
from pyrobot.brain.fuzzy import *
from pyrobot.brain.behaviors import *
import math, time
class Avoid (Behavior):
"""Avoid Class"""
def setup(self): # called when created
"""setup method"""
self.lasttime = time.time()
self.count = 0
def direction(... | [
"hybridkernal@gmail.com"
] | hybridkernal@gmail.com |
b0eba99c0ca25ed04ea431a7bee9a18f308d4931 | 646cadb1c72ef4a060343baf2fcbe271958b6878 | /tigerjython/TJExamples/10-Ef/Eff4d.py | a11bfecbf166ccc406e98f9264dc1a5edaf3fec4 | [] | no_license | tigerjython/tjinstall | bd75cf8e4ae27b639a13865ef1ec5710391a2938 | aab61519b5299c2ab4f423c6fc5d8ea7c7860a99 | refs/heads/master | 2021-01-17T08:53:50.386905 | 2018-01-12T06:56:28 | 2018-01-12T06:56:28 | 40,659,466 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,151 | py | from gamegrid import *
locations = {
'Althaus':Location(2, 0),
'Bellevue':Location(0, 1),
'City':Location(1, 3),
'Dom':Location(4, 2),
'Enge':Location(5, 0),
'Friedhof':Location(3, 4)}
neighbours = {
'Althaus':['Bellevue', 'Dom', 'Enge'],
'Bellevue':['Althaus', 'City', 'Dom'],
'City':['Bellevue', 'Dom... | [
"support@tigerjython.com"
] | support@tigerjython.com |
773fa456f16adc76fdbca0568bf8feb723dfad1b | 2d4af29250dca8c72b74e190e74d92f1467120a0 | /TaobaoSdk/Request/TaohuaChildcatesGetRequest.py | a624463f6f4d5bb1765b77cb318501d6f0daeeac | [] | no_license | maimiaolmc/TaobaoOpenPythonSDK | 2c671be93c40cf487c0d7d644479ba7e1043004c | d349aa8ed6229ce6d76a09f279a0896a0f8075b3 | refs/heads/master | 2020-04-06T03:52:46.585927 | 2014-06-09T08:58:27 | 2014-06-09T08:58:27 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,548 | py | #! /usr/bin/env python
# -*- coding: utf-8 -*-
# vim: set ts=4 sts=4 sw=4 et:
## @brief 通过类目ID获取它的类目列表
# @author wuliang@maimiaotech.com
# @date 2012-07-03 10:25:14
# @version: 0.0.0
import os
import sys
import time
def __getCurrentPath():
return os.path.normpath(os.path.join(os.path.realpath(__file__), os.pa... | [
"liyangmin@maimiaotech.com"
] | liyangmin@maimiaotech.com |
44745815bf70dfefbc566356404d6d02776e8a77 | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p03254/s956844324.py | 07d913466375174a9e3f7d1410eaa5709318f863 | [] | 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 | 171 | py | N,x = map(int, input().split())
A = sorted(map(int, input().split()))
s = 0
for i in range(N):
x -= A[i]
if x<0:
break
else:
s += 1
print(s if x<=0 else s-1) | [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
21bd5066ba2a212591f1557923296b35eda07ae0 | 53fab060fa262e5d5026e0807d93c75fb81e67b9 | /backup/user_072/ch25_2019_08_21_19_49_43_725038.py | 4ad02d8f6560a27c1b43320c99a7c2c44a6ef538 | [] | 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 | 199 | py | a=float(input('Qual será a distância percorrida ? '))
def preco_passagem(a):
if a<=200:
return a*0.5
else:
return 100+(a-100)*0.45
print('{0:.2f}'.format(preco_passagem(a))) | [
"you@example.com"
] | you@example.com |
43c46f3842293ca95fcc91f1dcb7bdd6100621cd | f0937d9fb9108cdd69c5c477a782965bb1f25da5 | /first/settings.py | 5922c4ca8b47a4245264bfa0f0f1e6fe1814266e | [] | no_license | SimeonYS/first | 64218a5c2113cebfc1e1aec3f2808dcefcc30342 | 986e7bbbe5635685ce6795ee9f1459ce5d5a8ef5 | refs/heads/main | 2023-03-29T17:29:57.300975 | 2021-03-29T07:58:32 | 2021-03-29T07:58:32 | 352,561,410 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 372 | py | BOT_NAME = 'first'
SPIDER_MODULES = ['first.spiders']
NEWSPIDER_MODULE = 'first.spiders'
FEED_EXPORT_ENCODING = 'utf-8'
LOG_LEVEL = 'ERROR'
DOWNLOAD_DELAY = 0
USER_AGENT="Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/88.0.4324.150 Safari/537.36"
ROBOTSTXT_OBEY = True
ITEM_PIP... | [
"simeon.simeonov@ADPVT.com"
] | simeon.simeonov@ADPVT.com |
c5cf3f5dddb8cb510c9b6acf954b3ddde35e9e2e | 8506f0a22ef4edf03627951ced530b921ff4d383 | /tools/sumolib/output/convert/gpx.py | 0ec2127c1bf7a9f35b0a8fba39d2c071c8999ca0 | [] | no_license | deepak728/Traffic-Optimization- | fb0ac074fa601e524eb0d79defc7e8b84ab03138 | 85bc54de2e318f36bdcc5bb6f05badde0fb35ffe | refs/heads/master | 2020-03-29T23:29:36.740048 | 2018-11-12T09:19:17 | 2018-11-12T09:19:17 | 150,475,374 | 1 | 1 | null | 2018-11-12T09:19:19 | 2018-09-26T18:57:35 | Java | UTF-8 | Python | false | false | 1,366 | py | """
@file gpx.py
@author Jakob Erdmann
@author Laura Bieker
@date 2014-02-13
@version $Id: gpx.py 18096 2015-03-17 09:50:59Z behrisch $
This module includes functions for converting SUMO's fcd-output into
GPX format (http://en.wikipedia.org/wiki/GPS_eXchange_Format)
SUMO, Simulation of Urban MObility; see htt... | [
"deepak711998@gmail.com"
] | deepak711998@gmail.com |
7e0f20a3411dc570ed92600197a47eda29d7e3fc | b5ffa0109ee980406550b7f9a4f5c7587f10a759 | /sklearn库.py | c597a056daae863e773ae3d33e4f1db9b08556b2 | [] | no_license | SuneastChen/np_pd_sklearn | 07fd99f383cfaf117e6dff7beb12b240957cbbe0 | 2ff777772c5a0db1e21635796351919c049dc680 | refs/heads/master | 2020-03-07T22:38:27.311708 | 2018-04-02T13:24:03 | 2018-04-02T13:24:03 | 127,759,582 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,832 | py | # _*_ coding:utf-8 _*_
# !/usr/bin/python
import numpy as np
from sklearn import datasets
from sklearn.model_selection import train_test_split
from sklearn.neighbors import KNeighborsClassifier
iris = datasets.load_iris() # 加载指定数据库,是一个字典,data与target是key
iris_X = iris.data # 特征数据表,是二维数组
iris_y = iris.target # 结果标签... | [
"1050521852@qq.com"
] | 1050521852@qq.com |
727b5f688d0d70414334ccda20dfd1f147a25259 | b604d6e2b1f206e6df660da2be2add78ec22941a | /resources/ros_kinetic/src/ros/rosbuild/bin/rosgcov_summarize | 9c19df610036bbb08442ed9a949fe1a44b505a54 | [] | no_license | fqez/common | 7b521773d81e2e687f6ae482f595ca3d19515e39 | f423fec07f39da9cb38f91dc4f3f1cd51c1a3130 | refs/heads/master | 2020-05-21T23:59:17.035384 | 2017-03-14T11:46:57 | 2017-03-14T11:46:57 | 62,873,104 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,635 | #!/usr/bin/env python3
import sys
import fileinput
import re
import os.path
USAGE = "USAGE: rosgcov_summarize <package_dir> <rosgcov_file>"
if len(sys.argv) != 3:
print(USAGE)
sys.exit(-1)
pkg = sys.argv[1]
fname = sys.argv[2]
if not os.path.exists(fname):
print('[rosgcov] %s : %.2f%% (no coverage results)' ... | [
"f.perez475@gmail.com"
] | f.perez475@gmail.com | |
fa4e4448ac09a8ca4502f4e8591d83ef40112882 | fc2447b91cbee82e74e939092ec1903678f3217a | /PythonPractice/算法图解/Dijkstra's algorithm.py | 0cd528a8c91f11657af1906538a31b531f16e4a9 | [] | no_license | yglj/learngit | 0eac654e7c49f2ede064b720e6ee621a702193b4 | 74fb4b93d5726c735b64829cafc99878d8082121 | refs/heads/master | 2022-12-24T10:01:56.705046 | 2019-05-27T21:04:08 | 2019-05-27T21:04:08 | 146,157,116 | 0 | 1 | null | 2022-12-12T07:01:25 | 2018-08-26T06:28:20 | HTML | UTF-8 | Python | false | false | 1,771 | py | """
狄克斯特拉算法
每条边上的关联数字称为权重
带权重的图叫加权图
寻找加权图的最短路径
只是用于有向无环图
"""
graph = {} # 加权图
costs = {} # 开销
parents = {} # 父节点
# 图的各顶点的邻居及边的权重
graph['start'] = {}
graph['start']['a'] = 6
graph['start']['b'] = 2
# print(graph['start'].keys())
graph['a'] = {}
graph['a']['fin'] = 1
graph['b'] = {}
graph['b']['a'] = 3
graph['b']['f... | [
"2365952530@qq.com"
] | 2365952530@qq.com |
4aa3c05bab82dea4ae678dfc7c1ea442168008e2 | 414a58c691ff7b434034086433644870f8ac5c99 | /tests/test_geom.py | b1de7a128110d8a3d34fee1bc3c1dbf3d7148c62 | [
"Apache-2.0",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | WZBSocialScienceCenter/pdftabextract | 08328197681ca03b764ea2df410851c06e0a92b7 | 7b86a9098b5d397f984b1cbc6716d55860e34ef8 | refs/heads/master | 2022-08-02T16:43:42.187628 | 2022-06-24T09:51:22 | 2022-06-24T09:51:22 | 62,884,666 | 2,239 | 401 | Apache-2.0 | 2022-06-24T09:51:23 | 2016-07-08T11:44:46 | Python | UTF-8 | Python | false | false | 7,946 | py | # -*- coding: utf-8 -*-
"""
Created on Mon Feb 13 09:50:51 2017
@author: mkonrad
"""
import math
import pytest
from hypothesis import given
import hypothesis.strategies as st
import numpy as np
from pdftabextract.geom import (pt, ptdist, vecangle, vecrotate, overlap, lineintersect,
... | [
"markus.konrad@wzb.eu"
] | markus.konrad@wzb.eu |
4b3ea08a26e0a92132a0a700b7e8ff04bd9e13fb | 0420b28aa59330fb0d9548f636b1460668163887 | /accounts/migrations/0005_alter_userprofile_profile_picture.py | 591939011f4877d881bd9c3396ddd91668e6bf0a | [] | no_license | akhmadakhmedov/modamag | 30cc3ea335b7fe8fbc234149b11d2df11b627281 | 0459f27230027fab51cbaae2a594ffde52a64d04 | refs/heads/main | 2023-08-11T01:48:58.979894 | 2021-10-12T11:18:08 | 2021-10-12T11:18:08 | 391,133,082 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 419 | py | # Generated by Django 3.2.5 on 2021-08-16 09:22
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('accounts', '0004_userprofile'),
]
operations = [
migrations.AlterField(
model_name='userprofile',
name='profile_pict... | [
"ahmedov.thy@gmail.com"
] | ahmedov.thy@gmail.com |
1c41b31c2095067d219200c34429fe81d65f2c1a | 96c1f13473cf224113185902edd4c9c01091e106 | /tests/torchlie_tests/functional/test_se3.py | c3af91c3b45ba611167ac0d61031d6cf9bfbf0f1 | [
"MIT"
] | permissive | facebookresearch/theseus | f1e488eb5a25f5ba74a6995911bee958b5da4cf3 | 240e1206329d42fedd40399684d6e17e455c6645 | refs/heads/main | 2023-08-11T07:33:12.328520 | 2023-08-02T12:58:01 | 2023-08-02T12:58:01 | 429,570,359 | 1,410 | 105 | MIT | 2023-08-01T14:30:01 | 2021-11-18T20:28:27 | Python | UTF-8 | Python | false | false | 3,067 | py | # Copyright (c) Meta Platforms, Inc. and affiliates.
#
# This source code is licensed under the MIT license found in the
# LICENSE file in the root directory of this source tree.
from typing import Sequence, Union
import pytest
import torch
import torchlie.functional.se3_impl as se3_impl
from torchlie.functional impo... | [
"noreply@github.com"
] | facebookresearch.noreply@github.com |
908780fe69c1ca758295ca0f25b531c70571438f | 67d8173a716da10a7350213d98938aae9f2115ce | /ProgrammingCourses/CS61A/lab/lab09/tests/substitute.py | c599160851d680f435682a58dd191c6b5377599d | [] | no_license | jxie0755/Learning_Python | 94490d41bdf93acf8396f843328e38b6da310b0f | 143422321cbc3715ca08f6c3af8f960a55887ced | refs/heads/master | 2021-11-02T22:47:35.790239 | 2021-09-26T04:26:23 | 2021-09-26T04:26:23 | 101,445,132 | 0 | 2 | null | 2019-02-19T15:48:44 | 2017-08-25T22:00:16 | Python | UTF-8 | Python | false | false | 1,174 | py | test = {
"name": "substitute",
"points": 1,
"suites": [
{
"cases": [
{
"code": r"""
scm> (substitute "(c a b) "b 'l)
(c a l)
scm> (substitute "(f e a r s) "f 'b)
(b e a r s)
scm> (substitute "(g (o) o (o)) "o 'r)
(g (r) r (r))... | [
"30805062+jxie0755@users.noreply.github.com"
] | 30805062+jxie0755@users.noreply.github.com |
400c7d1dfbd9b32067d5a361e8a800aaea5f8be9 | 771c1e2011a85a287c766b1a3d299ced2e6f799f | /src/electionguard/ballot_compact.py | 96e4d2be29a39ca2eb31f736305027dd3da57e10 | [
"MIT"
] | permissive | microsoft/electionguard-python | f50f64a473a8d77984a2faf4aa8db40cebb5c201 | b3ddc2a732f6c5f078a3afbe05b00d632a2ff5e0 | refs/heads/main | 2023-08-03T12:44:35.322716 | 2022-10-28T12:47:18 | 2022-10-28T12:47:18 | 246,392,956 | 143 | 117 | MIT | 2023-08-02T00:24:32 | 2020-03-10T19:46:06 | Python | UTF-8 | Python | false | false | 5,601 | py | from dataclasses import dataclass
from typing import Dict, List
from .ballot import (
CiphertextBallot,
SubmittedBallot,
PlaintextBallot,
PlaintextBallotContest,
PlaintextBallotSelection,
make_ciphertext_submitted_ballot,
)
from .ballot_box import BallotBoxState
from .election import Ciphertex... | [
"noreply@github.com"
] | microsoft.noreply@github.com |
3dc2bb12966bffd471380690c04c8efd0a9a13b7 | caedff6019e47035eadaaad5a588022e05d92104 | /Christmas2016/question/migrations/0001_initial.py | 763d1090fa8d71921230ce550cd9738236392d82 | [] | no_license | JMorris1575/christmas16 | ff767add9321bfe82ee70477f75a957504dc5288 | 1b06bf8febb94a699226b0b9d951cb14bbe59d50 | refs/heads/master | 2021-01-13T09:33:57.721350 | 2016-12-28T13:12:44 | 2016-12-28T13:12:44 | 72,059,066 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,218 | py | # -*- coding: utf-8 -*-
# Generated by Django 1.10.3 on 2016-12-09 02:39
from __future__ import unicode_literals
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import model_mixins
class Migration(migrations.Migration):
initial = True
dependencies ... | [
"FrJamesMorris@gmail.com"
] | FrJamesMorris@gmail.com |
628d46dc69e58fab2b00e0b3f44ef0d2fcd88ea1 | 5f22ddbd3eeb99709e43e7b9a7958c9987c7efa4 | /interview_bits/level_1/01_mathematics/05_number_encoding/01_rearrange-array.py | f60f9290190be8d9160ecf9353f276b41e9c32b3 | [] | no_license | salvador-dali/algorithms_general | 04950bd823fc354adc58a4f23b7d2f3d39664798 | aeee3356e2488c6fab08741b1ac26e8bd5e4ac0d | refs/heads/master | 2020-12-14T06:24:10.466601 | 2016-07-17T06:00:17 | 2016-07-17T06:00:17 | 47,397,457 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 219 | py | # https://www.interviewbit.com/problems/rearrange-array/
def rearrange(arr):
n = len(arr)
for i in xrange(n):
arr[i] += n * (arr[arr[i]] % n)
for i in xrange(n):
arr[i] /= n
return arr
| [
"dmytro@knowlabs.com"
] | dmytro@knowlabs.com |
077e06806c57829b1f5cc54d139833314ac0bffe | 308953409e1a3b828ac49b7301c1e751cbf762cf | /suite_EETc 12/tst_Open_Change_Values_Import_No/test.py | fec88bb5a37e70b505750a61bac908c5b0993dd9 | [] | no_license | asthagaur1/danfoss-automation | 4dcc7d8f000917b67e4d6f46ff862a525ddcbc5e | 213a99d3375889cd0e0c801421a50e9fe6085879 | refs/heads/main | 2023-03-31T23:26:56.956107 | 2021-04-01T08:52:37 | 2021-04-01T08:52:37 | 353,627,845 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 418 | py | def main():
excel = r"C:\gitworkspace\KoolProg-TestAutomation\Master_Functions\Test_Automation\SourceCode\suite_EETc 12\shared\testdata\Open_Change_Values_Import_No.xls";
#Mapping with Global scripts for Function library and key action.
source(findFile("scripts", "Functions.py"))
source(findFile("script... | [
"asthagaur@danfoss.com"
] | asthagaur@danfoss.com |
9e78bb7a62c7ff5743be037816b12a9c2316c086 | 82fdb2f3baeb4f08799d93c4be8d8c829f092415 | /tests/test_policies.py | 52b3f8e8e75389b6127427521a6f3c7145b58814 | [
"Apache-2.0"
] | permissive | velamurip/rasa_core | 915f815772e2b596f837f0e1af511e829cc28e3e | f3dbb70d0bb748628ab238eded17a8f5e09279e2 | refs/heads/master | 2021-05-16T04:22:04.310610 | 2017-10-05T09:53:22 | 2017-10-05T09:53:22 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,838 | py | from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from __future__ import unicode_literals
import numpy as np
import pytest
from rasa_core.channels import UserMessage
from rasa_core.domain import TemplateDomain
from rasa_core.featurizers import BinaryFeaturize... | [
"tom.bocklisch@scalableminds.com"
] | tom.bocklisch@scalableminds.com |
9db26fb7dad810ee471a57378bf7b950550c9a78 | e1a2c6ed4a4b93b4697974e3b0a32a4d67daa6f6 | /venv/Lib/site-packages/pybrain3/rl/environments/ode/instances/ccrl.py | f868c93f0e79f79e82bdefa752c7d5da13efb64f | [
"MIT"
] | permissive | ishatserka/MachineLearningAndDataAnalysisCoursera | cdf0f23a58617e17d6b938e3a9df17daae8585e4 | e82e772df2f4aec162cb34ac6127df10d14a625a | refs/heads/master | 2021-09-11T01:39:26.228392 | 2018-04-05T14:33:39 | 2018-04-05T14:33:39 | 117,153,454 | 0 | 0 | MIT | 2018-03-27T05:20:37 | 2018-01-11T21:05:33 | Python | UTF-8 | Python | false | false | 6,146 | py | __author__ = 'Frank Sehnke, sehnke@in.tum.de'
from pybrain3.rl.environments.ode import ODEEnvironment, sensors, actuators
import imp
import xode #@UnresolvedImport
import ode #@UnresolvedImport
import sys
from scipy import array, asarray
class CCRLEnvironment(ODEEnvironment):
def __init__(self, xodeFile="ccrlGlas... | [
"shatserka@gmail.com"
] | shatserka@gmail.com |
25ec5c3a23fdcbb3fe68b62fb26e6466e9c81f4a | 94c7440e7f1d2fdbe4a1e26b9c75a94e49c14eb4 | /leetcode/371.py | 9db89c099bace2c01ca91a5174d2047ab78a610c | [
"Apache-2.0"
] | permissive | windniw/just-for-fun | 7ddea4f75cf3466a400b46efe36e57f6f7847c48 | 44e1ff60f8cfaf47e4d88988ee67808f0ecfe828 | refs/heads/master | 2022-08-18T09:29:57.944846 | 2022-07-25T16:04:47 | 2022-07-25T16:04:47 | 204,949,602 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 717 | py | """
link: https://leetcode.com/problems/sum-of-two-integers
problem: 不用 + / - 号,求 integer 类型的 a + b
solution: 由于python没有左移整形溢出这道题难度直线上升。
a + b
== 不进位 (a + b) + 进位 (a + b) << 1
== a ^ b + (a & b) << 1
持续迭代到 (a & b) << 1 为0,即不进位时, 结果为当时的 a ^ b
"""
class Solution:
def get... | [
"windniw36@gmail.com"
] | windniw36@gmail.com |
50f8e6b88bff07c4af0e52bfa551b372a8c93bc8 | a35b2842ff707c9adf70e178ba8cb7a128e6f0fa | /brl_gym/scripts/crosswalk_vel/generate_initial_conditions.py | a9c7a1bb7d4cb52e8276db48814c90777f6661e9 | [
"BSD-3-Clause"
] | permissive | gilwoolee/brl_gym | 7717366a09c7ff96a8fbc02688febe6d559e333a | 9c0784e9928f12d2ee0528c79a533202d3afb640 | refs/heads/master | 2022-11-26T15:08:56.730225 | 2020-08-02T05:08:28 | 2020-08-02T05:08:28 | 198,884,614 | 3 | 0 | null | null | null | null | UTF-8 | Python | false | false | 772 | py | from brl_gym.envs.crosswalk_vel import CrossWalkVelEnv
import numpy as np
env = CrossWalkVelEnv()
env.reset()
goals = env.goals
peds = env.pedestrians
pose = env.pose
ped_speeds = env.pedestrian_speeds
print("Car 37, 38, 35")
print("Peds :\n", np.around(peds,1))
print("Ped speeds:\n", np.around(ped_speeds,2))
pr... | [
"gilwoo301@gmail.com"
] | gilwoo301@gmail.com |
d0a92881174f016830e5b146ca97ba5a68b65627 | 2aa4c7c94866e7a958e4787dd4487aa7c1eb8d61 | /applications/MappingApplication/tests/test_mapper_mpi_tests.py | 17fa528cbfa65adc8d0f6521adde262131b8852b | [
"BSD-3-Clause"
] | permissive | PFEM/Kratos | b48df91e6ef5a00edf125e6f5aa398505c9c2b96 | 796c8572e9fe3875562d77370fc60beeacca0eeb | refs/heads/master | 2021-10-16T04:33:47.591467 | 2019-02-04T14:22:06 | 2019-02-04T14:22:06 | 106,919,267 | 1 | 0 | null | 2017-10-14T10:34:43 | 2017-10-14T10:34:43 | null | UTF-8 | Python | false | false | 2,141 | py | from __future__ import print_function, absolute_import, division # makes KratosMultiphysics backward compatible with python 2.6 and 2.7
import KratosMultiphysics
from KratosMultiphysics.mpi import mpi
import KratosMultiphysics.MetisApplication
import KratosMultiphysics.TrilinosApplication
import KratosMultiphysics.Ma... | [
"philipp.bucher@tum.de"
] | philipp.bucher@tum.de |
224d192a356f25f72640dd130596fa1cc7f853c8 | fb1fd30098fd4dd7f11e614fbcd19bda5e0414bd | /randNum.py | 32dc0504c2cbabfba7c0c7b3ba6838a1d01a160a | [] | no_license | kali-lg/python | 6ceb452ae7fd611bb6b6b99a4be4404f3fd6b2de | 0363dba3e224ee2044dbe3216289c0245df9c5c0 | refs/heads/master | 2021-01-10T09:37:58.103674 | 2016-03-07T13:09:57 | 2016-03-07T13:09:57 | 53,310,186 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 454 | py | #!/usr/bin/python
import random
num = random.randint(0, 100)
while True:
try:
guess = int(raw_input("Please Enter number 1~100:\n"))
except ValueError, e:
print "Please Enter correct number, your number is wrong type."
continue
if guess > num:
print "Guess Bigger:", guess
... | [
"root@localhost.localdomain"
] | root@localhost.localdomain |
bf799d87050ee17a2efe9205421a451ddbc5bbb3 | f0b741f24ccf8bfe9bd1950425d83b6291d21b10 | /components/google-cloud/google_cloud_pipeline_components/container/v1/bigquery/ml_reconstruction_loss/launcher.py | b0671efb65d1838f7599a10b484a9e7483666bb0 | [
"Apache-2.0"
] | permissive | kubeflow/pipelines | e678342b8a325559dec0a6e1e484c525fdcc8ce8 | 3fb199658f68e7debf4906d9ce32a9a307e39243 | refs/heads/master | 2023-09-04T11:54:56.449867 | 2023-09-01T19:07:33 | 2023-09-01T19:12:27 | 133,100,880 | 3,434 | 1,675 | Apache-2.0 | 2023-09-14T20:19:06 | 2018-05-12T00:31:47 | Python | UTF-8 | Python | false | false | 3,115 | py | # Copyright 2022 The Kubeflow Authors. 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 required by applicabl... | [
"nobody@google.com"
] | nobody@google.com |
3ec2e2dd3b709a107fda00833615406e4642a963 | 1bb42bac177fb4e979faa441363c27cb636a43aa | /dual_encoder/model_utils.py | 691253213276f6be9ac1bd05a51079a61df3c007 | [
"BSD-3-Clause",
"Apache-2.0"
] | permissive | google-research/federated | a6040e80fa0fbf533e0d665c66a9bc549d208b3d | 329e60fa56b87f691303638ceb9dfa1fc5083953 | refs/heads/master | 2023-08-28T13:10:10.885505 | 2023-08-22T23:06:08 | 2023-08-22T23:06:40 | 295,559,343 | 595 | 187 | Apache-2.0 | 2022-05-12T08:42:53 | 2020-09-14T23:09:07 | Python | UTF-8 | Python | false | false | 5,775 | py | # Copyright 2021, Google LLC.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing... | [
"copybara-worker@google.com"
] | copybara-worker@google.com |
445617559274b877d9caaaded1e30307947b51ec | ac9e79b04eadb95497b99c30444d952e6068f18f | /dockermap/map/policy/__init__.py | 45f1833b73ce0c9c2dd07d072c74315426a84c27 | [
"MIT"
] | permissive | vijayshan/docker-map | ff58f5c8aba15b8d157478a6614c6d6681de1e61 | a222c92947cbc22aef727c12f39fb93b0b192bc7 | refs/heads/master | 2021-01-17T03:16:31.693681 | 2015-09-14T08:20:55 | 2015-09-14T08:20:55 | 42,375,505 | 1 | 0 | null | 2015-09-12T22:31:07 | 2015-09-12T22:31:07 | null | UTF-8 | Python | false | false | 204 | py | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from .actions import ACTION_ATTACHED_FLAG, ACTION_DEPENDENCY_FLAG
from .simple import SimplePolicy
from .resume import ResumeUpdatePolicy
| [
"matthias@erll.de"
] | matthias@erll.de |
65891c8750b9d10b031594b8b35080a55aaa6663 | 36409b78394002e5d6e9228ca256fd4654b38f80 | /random walk/src/BD_LERW.py | 225bf177733ba635a79943248f53c2381ba65975 | [] | no_license | xiaogang00/Mining-in-Social-Networks | fa383494fd56124096c60317af2b30373c0d4aac | 87ab6f29ae148170d03470987299c7ea812d1dab | refs/heads/master | 2020-12-02T16:22:59.938930 | 2017-08-30T01:58:33 | 2017-08-30T01:58:33 | 96,543,382 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 3,050 | py | #!/usr/bin/python
#
# An implementation of a Bidirectional Loop Erased Random Walk (LERW)
# from a cylinder with reflecting boundaries on the left
# and open boundaries on the right.
# PNG output of a single trajectory.
# Habib Rehmann and Gunnar Pruessner
#
import random
import numpy as np
import matplotlib.pyplot as... | [
"872310734@qq.com"
] | 872310734@qq.com |
579d13c29895c97ff77f3425bac31cb6d6070857 | 1e6e3bb707920fdb01ebca23eaf81097c558d918 | /tests/system/action/test_internal_actions.py | cc7ffd01313c71744500855191c73bb153e2160b | [
"MIT"
] | permissive | OpenSlides/openslides-backend | cbd24589f82a6f29bde02611610511870bb6abbf | d8511f5138db4cc5fe4fa35e2a0200f766bd49c5 | refs/heads/main | 2023-08-23T11:54:25.064070 | 2023-08-22T11:15:45 | 2023-08-22T11:15:45 | 231,757,840 | 6 | 22 | MIT | 2023-09-14T16:23:41 | 2020-01-04T12:17:38 | Python | UTF-8 | Python | false | false | 7,783 | py | from tempfile import NamedTemporaryFile
from typing import Any, Dict, Optional
from openslides_backend.http.views.action_view import (
INTERNAL_AUTHORIZATION_HEADER,
ActionView,
)
from openslides_backend.http.views.base_view import RouteFunction
from openslides_backend.shared.env import DEV_PASSWORD
from opens... | [
"noreply@github.com"
] | OpenSlides.noreply@github.com |
e0401fc292b6f962226021e0e3f636419bf5068e | 958b6de6be5fb8bce876373cec29677259c6ceb3 | /hypergan/train_hooks/experimental/weight_penalty_train_hook.py | 7a672346f3853a2b0d4a457e359240de7e35efd9 | [
"MIT",
"LicenseRef-scancode-warranty-disclaimer"
] | permissive | RandomStudio/HyperGAN | 712679b9121ad414d2f91205a82370d54a930120 | 586cefe69805f5ffa8dcb11aaf346f6b3dcf3ac9 | refs/heads/master | 2020-06-22T22:43:04.884557 | 2019-07-23T12:17:58 | 2019-07-23T12:17:58 | 198,420,256 | 0 | 0 | null | 2019-07-23T11:52:00 | 2019-07-23T11:51:59 | null | UTF-8 | Python | false | false | 2,923 | py | #From https://gist.github.com/EndingCredits/b5f35e84df10d46cfa716178d9c862a3
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from tensorflow.python.ops import control_flow_ops
from tensorflow.python.ops import math_ops
from tensorflow.python.ops import state... | [
"mikkel@255bits.com"
] | mikkel@255bits.com |
bb7645b996dd70bb11bceb7fa31190757f205a92 | 141d1fb160fcfb4294d4b0572216033218da702d | /exec -l /bin/zsh/google-cloud-sdk/lib/surface/composer/environments/run.py | b81165e938f3ff95fea3676709e9be6e342bacc4 | [
"LicenseRef-scancode-unknown-license-reference",
"Apache-2.0"
] | permissive | sudocams/tech-club | 1f2d74c4aedde18853c2b4b729ff3ca5908e76a5 | c8540954b11a6fd838427e959e38965a084b2a4c | refs/heads/master | 2021-07-15T03:04:40.397799 | 2020-12-01T20:05:55 | 2020-12-01T20:05:55 | 245,985,795 | 0 | 1 | null | 2021-04-30T21:04:39 | 2020-03-09T08:51:41 | Python | UTF-8 | Python | false | false | 7,255 | py | # -*- coding: utf-8 -*- #
# Copyright 2017 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... | [
"yogocamlus@gmail.com"
] | yogocamlus@gmail.com |
1750d92d1dc355447d3f4c59c6a8905eb0f2bb15 | 23a1faa037ddaf34a7b5db8ae10ff8fa1bb79b94 | /TCS_Practice/TCS_CodeVita_Problems/Constellation.py | e77bcc038db671a3100235e6c5e1bd94fd310097 | [] | no_license | Pyk017/Competetive-Programming | e57d2fe1e26eeeca49777d79ad0cbac3ab22fe63 | aaa689f9e208bc80e05a24b31aa652048858de22 | refs/heads/master | 2023-04-27T09:37:16.432258 | 2023-04-22T08:01:18 | 2023-04-22T08:01:18 | 231,229,696 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,823 | py | '''
Three characters { #, *, . } represents a constellation of stars and galaxies in space. Each galaxy is demarcated by # characters. There can be one or many stars in a given galaxy. Stars can only be in shape of vowels { A, E, I, O, U } . A collection of * in the shape of the vowels is a star. A star is contained in... | [
"prakharkumar506978@gmail.com"
] | prakharkumar506978@gmail.com |
f85f6f39aa12d9bd44917d0f830d724ec3d6f956 | c42f7f7a8421103cc3ca8ee44673704f7eea22b1 | /src/utils/routes.py | 01fe170c5eaa9ad4e3f0cf77beb0b1f34279b976 | [
"MIT"
] | permissive | styleolder/fp-server | fe585fe73014eb0421b25d5579191d24276df250 | ae405e7c37a919bd73be567e3e098e7fe5524097 | refs/heads/master | 2020-03-21T12:05:36.250998 | 2018-06-24T13:07:51 | 2018-06-24T13:07:51 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,770 | py | # -*- coding:utf-8 -*-
"""
http uri 路由装饰器
"""
from utils import log as logger
class route(object):
"""
@route('/some/path')
class SomeRequestHandler(RequestHandler):
pass
@route('/some/path', name='other')
class SomeOtherRequestHandler(RequestHandler):
pass
my_routes = route.... | [
"valesail7@gmail.com"
] | valesail7@gmail.com |
82d322d9d2a24a4f17977671c69823b4c05dcae3 | 523f8f5febbbfeb6d42183f2bbeebc36f98eadb5 | /207_3.py | a0c0add9e9275d90f0930004027fe8138ec29417 | [] | no_license | saleed/LeetCode | 655f82fdfcc3000400f49388e97fc0560f356af0 | 48b43999fb7e2ed82d922e1f64ac76f8fabe4baa | refs/heads/master | 2022-06-15T21:54:56.223204 | 2022-05-09T14:05:50 | 2022-05-09T14:05:50 | 209,430,056 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,013 | py | class Solution(object):
def canFinish(self, numCourses, prerequisites):
"""
:type numCourses: int
:type prerequisites: List[List[int]]
:rtype: bool
"""
graph={}
indegree=[0]*numCourses
for i in range(numCourses):
graph[i]=[]
for pai... | [
"1533441387@qq.com"
] | 1533441387@qq.com |
3e67c476deabc53331ccd7582f0feff94455d632 | 31741f4807f857675f9304088b689af9b043e7b1 | /chp10/django_ecommerce/contact/views.py | 8160a48a0c26f4c0a9a9857aa9771927481e3ab1 | [] | no_license | ujrc/Realpython_book3 | c487ff0569f90b0e21c2c51cf951d6aad4755541 | aaff8db074b8dd33d6c7305ac0a94c2ef161c847 | refs/heads/master | 2021-01-10T02:02:11.247279 | 2016-01-11T17:06:59 | 2016-01-11T17:06:59 | 48,060,189 | 0 | 0 | null | 2015-12-31T16:48:52 | 2015-12-15T18:03:47 | Python | UTF-8 | Python | false | false | 755 | py | from django.http import HttpResponse, HttpResponseRedirect
from django.template import RequestContext, loader
from .forms import ContactView
from django.contrib import messages
def contact(request):
if request.method == 'POST':
form = ContactView(request.POST)
if form.is_valid():
our_f... | [
"uwjearc@yahoo.com"
] | uwjearc@yahoo.com |
337d900284082e21087ff98ddb9d2bb64e6b8248 | 9743d5fd24822f79c156ad112229e25adb9ed6f6 | /xai/brain/wordbase/otherforms/_banked.py | 08d044b1996c25d485b9094eb3beb1112231d788 | [
"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 | 216 | py |
#calss header
class _BANKED():
def __init__(self,):
self.name = "BANKED"
self.definitions = bank
self.parents = []
self.childen = []
self.properties = []
self.jsondata = {}
self.basic = ['bank']
| [
"xingwang1991@gmail.com"
] | xingwang1991@gmail.com |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.