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
8e39496238ae7abc1a45eade812fa000e74ef3bb
11e81ec279ec17196bdbc75ce334305e95929b52
/8주차 이분탐색,그래프/파티/김승욱.py
526773d77fb4084503893cb8d8223ccb823b07d7
[]
no_license
wheejoo/PythonCodeStudy
70992e1723d621fec933786dd2b3faa5d2518763
9e324f9deee1be044c07b64e7480c6bfac42876c
refs/heads/main
2023-07-28T23:11:19.335117
2021-10-03T11:37:09
2021-10-03T11:37:09
382,866,256
1
4
null
null
null
null
UTF-8
Python
false
false
1,227
py
# x를 시작으로 가장 먼곳 간다음 그 곳에서 다시 x까지 거리 구하려햇는데 # 왕복 거리가 다르므로 이렇게 풀면 안됨 # 모든 정점에서 x까지 최단거리 구하고 # 다시 x에서 모든 거리까지 최단거리 구해서 서로 더한다음 # 가장 큰 값구함 import heapq import sys input = sys.stdin.readline n, m, x = map(int,input().split()) INF = sys.maxsize grpah = [[] for _ in range(n+1)] maxx = 0 for i in range(m): a,b,c = map...
ddc056b2b37e8b40bdb6264c89407197605144ef
566ce57c0a56a492895dc5b2e4b7ae1b49b301dd
/job/urls.py
2ca32cf10b8d4220993e331027bcaabdfa5591c6
[]
no_license
ingafter60/job-portal
178e81c0f1d3fc4527242cf8c9bcc29c5d413ac9
6af2460927a29c914df74ea10172a731fcd528c6
refs/heads/master
2022-11-26T09:27:23.543390
2020-07-15T03:40:47
2020-07-15T03:40:47
279,142,881
1
0
null
null
null
null
UTF-8
Python
false
false
214
py
# job/urls.py from django.contrib import admin from django.urls import path, include urlpatterns = [ path('users/', include('users.urls')), path('', include('jobs.urls')), path('admin/', admin.site.urls), ]
68adf7e197ced3869d0d0a33c74355024394305e
0beaf9d78d03100b2aebaaac38fb343d425f2b6a
/tests/regression/gsheet/test_chrome_gsheet_100r_number_chars_image.py
bc85a9757ae1b561082d29b318d73a1b600482a8
[]
no_license
digitarald/Hasal
462fc044bb4a754c8d76c0bfb0df519f1786fdcc
c496afae6ec2e3743148f3a6288b78f120100513
refs/heads/master
2021-01-13T14:29:44.471037
2016-11-04T10:49:19
2016-11-04T10:49:19
null
0
0
null
null
null
null
UTF-8
Python
false
false
459
py
from lib.perfBaseTest import PerfBaseTest class TestSikuli(PerfBaseTest): def setUp(self): super(TestSikuli, self).setUp() def test_chrome_gsheet_100r_number_chars_image(self): self.test_url = self.env.GSHEET_TEST_URL_SPEC % self.env.TEST_TARGET_ID_100R_NUMBER_ENCHAR_IMAGE self.sikul...
f89f2605057672e195be30599e8b17bd6843fffa
3b84c4b7b16ccfd0154f8dcb75ddbbb6636373be
/google-cloud-sdk/lib/googlecloudsdk/command_lib/container/gkeonprem/flags.py
65a11cb83a4f743b2ab1aef526415180dfa7ce70
[ "Apache-2.0", "LicenseRef-scancode-unknown-license-reference" ]
permissive
twistedpair/google-cloud-sdk
37f04872cf1ab9c9ce5ec692d2201a93679827e3
1f9b424c40a87b46656fc9f5e2e9c81895c7e614
refs/heads/master
2023-08-18T18:42:59.622485
2023-08-15T00:00:00
2023-08-15T12:14:05
116,506,777
58
24
null
2022-02-14T22:01:53
2018-01-06T18:40:35
Python
UTF-8
Python
false
false
3,400
py
# -*- coding: utf-8 -*- # # Copyright 2022 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...
02cc868019621649a62b17392c2f8891804a69a6
696e35ccdf167c3f6b1a7f5458406d3bb81987c9
/mash/DEPS
681fd163d9adfc6508b88a7df485d548ae8c59da
[ "BSD-3-Clause" ]
permissive
mgh3326/iridium-browser
064e91a5e37f4e8501ea971483bd1c76297261c3
e7de6a434d2659f02e94917be364a904a442d2d0
refs/heads/master
2023-03-30T16:18:27.391772
2019-04-24T02:14:32
2019-04-24T02:14:32
183,128,065
0
0
BSD-3-Clause
2019-11-30T06:06:02
2019-04-24T02:04:51
null
UTF-8
Python
false
false
279
include_rules = [ "+ash/public", "+components/prefs", "+components/viz/common", "+mojo/converters", "+mojo/public", "+services/catalog/public", "+services/service_manager", "+services/ws/common", "+services/ws/public", "+third_party/skia/include", "+ui", ]
6a83f1a2c02e53428cf6622fc3cc28737370842f
c47340ae6bcac6002961cc2c6d2fecb353c1e502
/test/test_known_hosts.py
1c2c8b6867e85b61f8a35c508543f3fccb4a802f
[ "MIT" ]
permissive
rafaeldelrey/controlm_py
6d9f56b8b6e72750f329d85b932ace6c41002cbd
ed1eb648d1d23e587321227217cbfcc5065535ab
refs/heads/main
2023-04-23T09:01:32.024725
2021-05-19T00:25:53
2021-05-19T00:25:53
null
0
0
null
null
null
null
UTF-8
Python
false
false
871
py
# coding: utf-8 """ Control-M Services Provides access to BMC Control-M Services # noqa: E501 OpenAPI spec version: 9.20.115 Contact: [email protected] Generated by: https://github.com/swagger-api/swagger-codegen.git """ from __future__ import absolute_import import unittest import con...
c0367113441a8db2c3f75729fd8ff004260f1624
fdbcbb95a34e05e015c3ece6a071b04915c70346
/code_interview/settings.py
abae8f9ec0cbf5a01bc576629629e91621ec3687
[ "Apache-2.0" ]
permissive
nonbeing/codeinterview-backend
ed0e8f4d4dddbc25e235a817cfbc22e491c5c5c9
f44a592640a4a663daebef06561063c062c8acb0
refs/heads/master
2022-09-04T11:28:04.105984
2020-06-01T05:13:22
2020-06-01T05:13:22
268,828,769
1
0
Apache-2.0
2020-06-02T14:49:35
2020-06-02T14:49:35
null
UTF-8
Python
false
false
3,870
py
import os BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) SECRET_KEY = 'j%4s9n79np!^nrq3&h4=6a8r2c^ex9s)gg3s(zsx((o@qll2yj' DEBUG = True ALLOWED_HOSTS = [] # Celery config CELERY_BROKER_URL = 'pyamqp://' CELERY_RESULT_BACKEND = 'redis://' CELERY_TASK_ROUTES = { # WARNING: room.tasks stil...
3e02711859000bf568d3065860caad09b02d70f6
8aa5b087176a5de567664a9377eda56641cda628
/binaryapi/ws/chanels/contract_update_history.py
3a6a664953571745700447201f3bdf44426e7027
[]
no_license
pabloapdz/binaryapi
ce55d2f4d125b2725ae0c5b23b953521c792cf27
c2cca1ec144d10b885df7aeda03c7c63dbe673de
refs/heads/master
2022-11-19T16:10:04.567328
2020-07-23T03:00:40
2020-07-23T03:00:40
null
0
0
null
null
null
null
UTF-8
Python
false
false
1,316
py
"""Module for Binary contract_update_history websocket chanel.""" from binaryapi.ws.chanels.base import Base # https://developers.binary.com/api/#contract_update_history class ContractUpdateHistory(Base): """Class for Binary contract_update_history websocket chanel.""" name = "contract_update_history" ...
2fba0ba36775b47980f0366230afbcb1da18fd79
749efa5eb1ea53a5372b31832ed74d85dc15f641
/temporal_graph/structure_network/structure_graph.py
75ee3f2cae8ea41f57d59fa4cfb7acf6a2211fdc
[]
no_license
summukhe/TemporalGraph
ac8f7be103620b5d53aeae6e6f462d2f74cd5f8c
722fedaf737950ac32d4dabd830afbd241a03a2c
refs/heads/master
2020-05-05T03:17:05.918359
2019-06-01T05:40:49
2019-06-01T05:40:49
179,666,707
0
0
null
null
null
null
UTF-8
Python
false
false
5,220
py
import numpy as np from copy import deepcopy from temporal_graph.network_analysis import GeometricGraph3d from temporal_graph.spatial_ds import * from temporal_graph.pdb_processor import * from temporal_graph.force_field import * __version__ = "1.0" __all__ = ['contact_graph', 'potential_contact_graph', ...
58e4e79d5aff5d675c44d475f8eb78c71f373b12
20d9130fdc21756c4f8fe255583922352f5c5762
/src/DIRAC/DataManagementSystem/Service/LcgFileCatalogProxyHandler.py
ba7ea68222b2cc3e09dd20556e2c46165ff46f1b
[]
no_license
bopopescu/bes3-jinr
095314e43f41f08bd48b248fe3ca627a5c009f58
fdfd852c92a56192b8ee9970b66f0136e6e0afff
refs/heads/master
2022-11-26T06:01:36.718508
2014-03-17T06:03:50
2014-03-17T06:03:50
282,113,617
0
0
null
2020-07-24T03:30:10
2020-07-24T03:30:09
null
UTF-8
Python
false
false
3,628
py
######################################################################## # $HeadURL $ # File: LcgFileCatalogProxyHandler.py ######################################################################## """ :mod: LcgFileCatalogProxyHandler ================================ .. module: LcgFileCatalogProxyHandler ...
ff091989b08d7360d35edcde8d929dbfa9826630
185960fa68ac9ff6377eff50e3afc3900827c264
/one_model_n_data.py
29e8ab68e888ca6f56013c0a4b34873b52af055a
[]
no_license
enjoysport2022/Incident_Detection
0a9158e163ff5c74c7d2bb1ebae6fad8adb53de4
87b6848ae3f038e7eab9c0c40c0ea19efa27208c
refs/heads/master
2023-02-22T11:29:00.385996
2015-12-07T03:21:07
2015-12-07T03:21:07
null
0
0
null
null
null
null
UTF-8
Python
false
false
6,730
py
# -*- coding: UTF-8 -*- #运行程序需要安装numpy,scipy,sklearn # 需要导入的库: import time import requests import conf start=time.clock() import csv from sklearn.svm import SVC import numpy as np from sklearn import preprocessing,neighbors from sklearn.cross_validation import train_test_split from sklearn.metrics import confusion_mat...
280d992fa5b09c52dc7e19f51da135e40cdd64ec
d93fe0484fc3b32c8fd9b33cc66cfd636a148ec4
/AtCoder/ABC-C/112probC3.py
c3bbb316c6ac065245c203087a439022efbf8c8b
[]
no_license
wattaihei/ProgrammingContest
0d34f42f60fa6693e04c933c978527ffaddceda7
c26de8d42790651aaee56df0956e0b206d1cceb4
refs/heads/master
2023-04-22T19:43:43.394907
2021-05-02T13:05:21
2021-05-02T13:05:21
264,400,706
0
0
null
null
null
null
UTF-8
Python
false
false
647
py
N = int(input()) P = [list(map(int, input().split())) for _ in range(N)] for cx in range(101): for cy in range(101): H = -1 ok = True for x, y, h in P: if h == 0: continue Hi = abs(x-cx) + abs(y-cy) + h if H == -1: H = Hi ...
388b1376ecae66dea21f6eb31224085c51938a87
426f216e3d38d2030d337c8be6463cc4cd7af6c3
/day08/monitor/server/conf/services/generic.py
abc781d82c426c6dae6cf7b1f236a2e0e65bc7f2
[ "Apache-2.0" ]
permissive
zhangyage/Python-oldboy
c7b43801935fc9e08e973ee0b852daa8e8667fb7
a95c1b465929e2be641e425fcb5e15b366800831
refs/heads/master
2021-01-23T02:59:37.574638
2019-10-27T05:35:58
2019-10-27T05:35:58
86,039,220
1
0
null
null
null
null
UTF-8
Python
false
false
364
py
#!/usr/bin/env python # -*- coding:utf-8 -*- ''' 通用的 定义的是基本的监控项目 service ''' class BaseService(object): def __init__(self): self.name = 'BaseService' self.interval = 300 #监控间隔 self.last_time = 0 self.plugin_name = 'your_plugin' #监控插件 self.triggers = {} #监控阈值
3af48aef1784b977a278aaf5bba88fe616c0c1b5
cc64a1dfa57d4b667129efdadb97506bafce73f0
/letsencrypt-nginx/setup.py
a37b8222b05d005279f96320447da3dd50ac18f6
[ "Apache-2.0", "MIT" ]
permissive
ryanwinchester-forks/letsencrypt
83e027e3f4e78c5b4fad5fc3cc5676d2cde1f8e9
9bff9c0edf0f1fa28684332c17729473aa42ebca
refs/heads/master
2021-01-18T02:00:13.041678
2015-10-20T16:43:55
2015-10-20T16:43:55
44,626,314
0
1
null
null
null
null
UTF-8
Python
false
false
1,631
py
import sys from setuptools import setup from setuptools import find_packages version = '0.1.0.dev0' install_requires = [ 'acme=={0}'.format(version), 'letsencrypt=={0}'.format(version), 'PyOpenSSL', 'pyparsing>=1.5.5', # Python3 support; perhaps unnecessary? 'setuptools', # pkg_resources '...
ae580464cc83075118e66de8f98e34b16370cc90
52b5773617a1b972a905de4d692540d26ff74926
/.history/fractions_20200802121517.py
abb8224836def842553093f1a7ab4d84e93a4fd7
[]
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,432
py
def fractions(numerator,denominator): if denominator == 0 : return str(numerator) number = numerator / denominator if numerator % denominator == 0: return str(numerator // denominator) newStr = str(number) print(newStr) largeStr = newStr.split(".") if len(largeStr[1]) > 1: ...
aed016ed1a15167c9ddb335b87695a86c7f128b7
0738d9f85b98a7e30d7f33b4fe94ceb58f44b123
/Algorithm/Backtracking/Python/N_queen_problem.py
69015ddf23b8dd022f18b5baa90d480ccbfc7420
[]
no_license
arifkhan1990/Competitive-Programming
e51606b6bafc0671e8799df4297529b27eb6488e
9b8ca6e8f2ec4c74ea314e8d80657ac97489a315
refs/heads/master
2022-10-28T19:31:16.818123
2022-10-14T21:32:51
2022-10-14T21:32:51
199,027,360
5
4
null
null
null
null
UTF-8
Python
false
false
778
py
def solveNQ(n): col = set() posDiag = set() # r+c negDiag = set() # r-c ans = [] board = [['0'] * n for _ in range(n)] def backtraking(r): if r == n: copy = ["".join(r) for r in board] ans.append(copy) return for c in range(n...
2e559d799618df295505bb747e712d4de41097c4
09efb7c148e82c22ce6cc7a17b5140aa03aa6e55
/env/lib/python3.6/site-packages/pandas/tests/tslibs/test_parse_iso8601.py
a6e7aee46b485b6b524f363351f1bb011b8b0b0e
[ "MIT" ]
permissive
harryturr/harryturr_garmin_dashboard
53071a23b267116e1945ae93d36e2a978c411261
734e04f8257f9f84f2553efeb7e73920e35aadc9
refs/heads/master
2023-01-19T22:10:57.374029
2020-01-29T10:47:56
2020-01-29T10:47:56
235,609,069
4
0
MIT
2023-01-05T05:51:27
2020-01-22T16:00:13
Python
UTF-8
Python
false
false
2,108
py
from datetime import datetime import pytest from pandas._libs import tslib @pytest.mark.parametrize( "date_str, exp", [ ("2011-01-02", datetime(2011, 1, 2)), ("2011-1-2", datetime(2011, 1, 2)), ("2011-01", datetime(2011, 1, 1)), ("2011-1", datetime(2011, 1, 1)), ("201...
ea41839b6a0a26d593362635192d222831c3f1b4
18ad97292b34a679b8dea8a85090541c5bbf6174
/candlebox.py
72e9d35d1aae4302ce3baca36368789c9c7073a3
[]
no_license
Jyotirm0y/kattis
b941044e39dc36d169450480fc33fd33bd2e0f8e
2b9c1819ba29419bbea3db2e8ad7851155abbb3a
refs/heads/master
2023-05-31T21:11:38.350044
2021-06-12T08:21:47
2021-06-12T08:21:47
null
0
0
null
null
null
null
UTF-8
Python
false
false
204
py
import math d = int(input()) r = int(input()) t = int(input()) x = math.ceil(math.sqrt(2*(r+6))) y = x - d while (x*(x+1)//2)-6 + (y*(y+1)//2)-3 != r + t: x -= 1 y -= 1 print(r-((x*(x+1)//2)-6))
9684ed8877dc1d5f50b40a958207c71a45c2687a
259cc507d97bfeff84d21de3a0ab56640676a9eb
/venv1/Lib/site-packages/tensorflow/contrib/eager/python/datasets.py
f9b6f54e4482a424f8f775e0fbbf659cfb0a31e7
[ "MIT", "Apache-2.0" ]
permissive
Soum-Soum/Tensorflow_Face_Finder
c3ef71b6f718f6720b80f8760d28b6ca6e11e6d2
fec6c15d2df7012608511ad87f4b55731bf99478
refs/heads/master
2020-03-22T20:31:39.606644
2018-07-12T13:47:56
2018-07-12T13:47:56
140,607,068
0
0
null
null
null
null
UTF-8
Python
false
false
8,168
py
# Copyright 2017 The TensorFlow 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...
66358a8cd5f8c3683912d15e44b84dc84ab92762
0b2ffe7092e4008c73fdbf8791d107a2ce583c5d
/terraform_builder/release.py
e459a6e688e3c9d51565d16f56827ef2e2a73d4d
[ "MIT" ]
permissive
mrlesmithjr/terraform-builder
1f960741ca5a37a862e2498b8ad81a31dffc13b2
08ed71333e988682ce50c6ef865fdd8ba27de395
refs/heads/master
2022-10-16T03:05:34.351002
2020-06-19T03:53:53
2020-06-19T03:53:53
248,327,103
8
0
MIT
2022-09-30T20:02:28
2020-03-18T19:43:30
Python
UTF-8
Python
false
false
160
py
"""terraform_builder/release.py""" # Version tracking for package. __author__ = 'Larry Smith Jr.' __version__ = '0.1.0' __package_name__ = 'terraform_builder'
bcabfd47909ebc6b12e84806dd30400748c428f8
60aae6fe961b6fadcbefa0154976012e84d29e6a
/molotov/tests/example5.py
4228ca09bfcc30279829df5c3a827295e5b6c979
[ "Apache-2.0" ]
permissive
tarekziade/molotov
33aefd27e08be35b0f010a4d125f287e798a24c2
27f7599d9d04d86964878f3cac78e91c8b231d61
refs/heads/main
2023-08-03T12:07:54.036876
2023-07-18T06:58:50
2023-07-18T06:58:50
35,025,578
45
4
Apache-2.0
2023-07-20T16:33:12
2015-05-04T09:17:25
Python
UTF-8
Python
false
false
534
py
""" This Molotov script demonstrates how to hook events. """ import molotov @molotov.events() async def print_request(event, **info): if event == "sending_request": print("=>") @molotov.events() async def print_response(event, **info): if event == "response_received": print("<=") @molot...
1d65e5ff19c250a211d18eccd6cf2e6535690ff3
17c0eeede746d8dc164d27ef1f1eea3167aa0484
/array/215.kth_largest.py
0fce094deb14b5fdfde0e6bb5179c82d2c0c7d95
[]
no_license
mirzasaad/leetcode-solutions
a778c70e6ea5a94f9874fb90ec24d16d877ca5f2
53a3eb91411d5b732c91cbe7dafe44ed0ea7335f
refs/heads/master
2022-12-11T11:45:57.830633
2020-09-03T16:23:01
2020-09-03T16:23:01
264,158,622
0
0
null
null
null
null
UTF-8
Python
false
false
1,190
py
def findKthLargest(self, nums: List[int], k: int) -> int: def partition(A, lo, hi): pivot = A[hi] left = lo for i in range(lo, hi): if A[i] < pivot: A[left], A[i] = A[i], A[left] left += 1 A[left], A[hi] = A[hi], A[left] return left lo, hi...
7ab2d68fe32381cc7e34646cb4a849d9d429ff60
9981e61fd113fac5af9825b78b57617e001160e0
/test/test/spiders/dmoz_spider.py
a88147643fae839c825207112f340fcb96388b17
[]
no_license
yfjelley/scrapy
9191ee94e4ed3732287bd040b5d2d2c16476ec12
dc9f1dc1e76603ea623e0ab9608084f0aedba802
refs/heads/master
2020-03-29T12:02:38.981328
2014-09-30T08:29:28
2014-09-30T08:29:28
null
0
0
null
null
null
null
UTF-8
Python
false
false
427
py
from scrapy.spider import Spider class DmozSpider(Spider): name = "dmoz" allowed_domains = ["dmoz.org"] start_urls = [ "http://www.dmoz.org/Computers/Programming/Languages/Python/Books/", "http://www.dmoz.org/Computers/Programming/Languages/Python/Resources/" ] def parse(self, ...
38b7548ce83a179d7b6f7597294f350513664810
d7516481db51c31ae1690892a4bb19246c831ac4
/examples/reinforcement_learning_examples/dueling_ddqn_cartpole.py
4ebc65acb4014e727a5930cfdab6c1a1c501ad0b
[ "MIT" ]
permissive
gyunt/polyaxon
0f7c3b026635ad62d28316bf68fc806c51fc4ccb
0c99cca9ae9a2a4e957febe1970bf6508225f292
refs/heads/master
2021-09-01T07:02:51.453682
2017-12-20T23:02:37
2017-12-20T23:02:37
null
0
0
null
null
null
null
UTF-8
Python
false
false
1,293
py
# -*- coding: utf-8 -*- from __future__ import absolute_import, division, print_function from polyaxon_schemas.losses import HuberLossConfig from polyaxon_schemas.optimizers import SGDConfig from polyaxon_schemas.rl.explorations import DecayExplorationConfig import polyaxon as plx import tensorflow as tf def main(*...
29ad398e603eb50a181b953682529ba792218ca0
a8750439f200e4efc11715df797489f30e9828c6
/HackerEarth/lcs_3.py
dbc637ba24752327cc743e3495ecfbebd8558e33
[]
no_license
rajlath/rkl_codes
f657174305dc85c3fa07a6fff1c7c31cfe6e2f89
d4bcee3df2f501349feed7a26ef9828573aff873
refs/heads/master
2023-02-21T10:16:35.800612
2021-01-27T11:43:34
2021-01-27T11:43:34
110,989,354
0
0
null
null
null
null
UTF-8
Python
false
false
394
py
def longest_increasing_subsequence(d): 'Return one of the L.I.S. of list d' l = [] for i in range(len(d)): l.append(max([l[j] for j in range(i) if l[j][-1] < d[i]] or [[]], key=len) + [d[i]]) return max(l, key=len) if __name__ == '__main__': for d in [[4,2,6,3,8]]: ...
8b80f1b6b8ed8568ac76e0489c295bc5f828cb2f
e23a4f57ce5474d468258e5e63b9e23fb6011188
/125_algorithms/_exercises/templates/_algorithms_challenges/codewar/_CodeWars-Python-master/solutions/All_that_is_open_must_be_closed.py
d1806dce261468de3df26a597cc6e422df9c3fe6
[]
no_license
syurskyi/Python_Topics
52851ecce000cb751a3b986408efe32f0b4c0835
be331826b490b73f0a176e6abed86ef68ff2dd2b
refs/heads/master
2023-06-08T19:29:16.214395
2023-05-29T17:09:11
2023-05-29T17:09:11
220,583,118
3
2
null
2023-02-16T03:08:10
2019-11-09T02:58:47
Python
UTF-8
Python
false
false
1,259
py
""" All that is open must be closed... http://www.codewars.com/kata/55679d644c58e2df2a00009c/train/python """ ___ is_balanced(source, caps count # dict stack # list ___ c __ source: __ c __ caps: i caps.i.. c) __ i % 2 __ 0: __ caps[i] __ caps[i + 1]: ...
7bb259878309e08221c4eed095a0919d1ca02770
314cf05e7acdfb2b83bf4a56de4ee65310bd28f2
/tests/outcomes/plot/bar/universal_tests/data_simple/matplotlib_x_column_string_plt.py
c460d965e0851ce752035f391d3b6331c3e2f2a1
[]
no_license
hyperskill/hs-test-python
9f0201904cb68f3eb35275bb0c3b9bb70164a1e7
260313395d0534d148738e031753eb8f60de2e13
refs/heads/master
2023-05-10T17:49:26.400853
2023-04-26T11:49:52
2023-04-26T11:49:52
214,279,373
20
7
null
2023-04-26T11:49:53
2019-10-10T20:28:03
Python
UTF-8
Python
false
false
343
py
def plot(): try: import pandas as pd import numpy as np import matplotlib.pyplot as plt except ModuleNotFoundError: return df = pd.DataFrame(np.array([[1, 2], [2, 3], [3, 4], [4, 5], [5, 6]]), columns=['one', 'two']) plt.bar(df['one'], df['two']) ...
73af4638f94ae74093fb40dec034e500c1ac23d7
5b3bd326998606188b45a7870852643eda024a97
/utils/test_utils_test.py
9ad7254bc0a5ca873d88901f4d4b83e24ee085cc
[]
no_license
KuznetsovIllya/clearml_od_toy
31556d0726d15a054c1c18317c361d97801381a4
92f15f04a023d4e0e165a250fddc3129144913d0
refs/heads/main
2023-04-11T05:55:56.248478
2021-04-14T15:59:40
2021-04-14T15:59:40
357,827,336
0
0
null
null
null
null
UTF-8
Python
false
false
129
py
version https://git-lfs.github.com/spec/v1 oid sha256:27f15ba16a39d8a04be71ec29510f423d102dac19cdfa5d0e7f09e8e55f55b4b size 3328
883988c4f6204ea5858a3976c048f2751e24b4f0
0c66e605e6e4129b09ea14dbb6aa353d18aaa027
/diventi/feedbacks/migrations/0006_auto_20181007_2139.py
b9a3a92a2f8c2db58839655d1c35c38662b0de2a
[ "Apache-2.0" ]
permissive
flavoi/diventi
58fbc8c947f387cbcc1ce607878a59a6f2b72313
c0b1efe2baa3ff816d6ee9a8e86623f297973ded
refs/heads/master
2023-07-20T09:32:35.897661
2023-07-11T19:44:26
2023-07-11T19:44:26
102,959,477
2
1
Apache-2.0
2023-02-08T01:03:17
2017-09-09T14:10:51
Python
UTF-8
Python
false
false
556
py
# Generated by Django 2.0.8 on 2018-10-07 19:39 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('feedbacks', '0005_auto_20181007_1951'), ] operations = [ migrations.RemoveField( model_name='question', name='survey...
dd362d139002a4217fdd1735daa4f34396aee423
efceab61588936151e49bf9311fe6f949cdd81c8
/context_utils/regression_analysis/contexts/feature_weights.py
55efd2312a5d416e950262951e999744467a7568
[]
no_license
GiovanniCassani/distributional_bootstrapping
c74b4dddcb91a083c8cc0c55263228bc1acff54c
324176f659835a29cfd6859febb570e99c1bad31
refs/heads/master
2021-03-19T11:45:38.364181
2018-09-10T15:24:37
2018-09-10T15:24:37
113,855,663
0
0
null
null
null
null
UTF-8
Python
false
false
2,348
py
__author__ = 'GCassani' """Compute feature weights for the relevant contexts given an input co-occurrence vector space""" import os from collections import defaultdict def compute_feature_weights(training_space, output_file): """ :param training_space: the path to a file containing the co-occurrence coun...
7ed3e17232f1e18ac0f0b32b4082aea884541ced
a1e6c25d701eacb0dd893802f7d3db316768dbc4
/featureExtrator/feature_extractor.py
e461e884f6bcae25d455741367a851a7a26da379
[]
no_license
zhengchengyy/BBDataProcessing
c04f5053266881116f1ab764041f7fd4901561ab
5d4f98e4b4b7d7e98db2677d00b618d2bb6a74c8
refs/heads/master
2021-07-20T22:31:28.894304
2020-05-17T14:04:30
2020-05-17T14:04:30
165,455,028
2
0
null
null
null
null
UTF-8
Python
false
false
3,672
py
''' 修改原有的feature_extractor文件,将按次数处理获得的数据改为按时间段处理 新增以及改变的代码均使用两行------标识 使用观察者模式实现特征提取,特征提取器(Subject)依赖于多个特征提取模块(Observer),特征提取器注册了多个特征提取模块, 当特征提取器状态改变(获取到新数据),通知所有特征模块更新状态(计算新的特征值)。 ''' from abc import ABC, abstractmethod from queue import Queue class ProcessModule(ABC): """Observer的抽象类,表示处理数据的模块。 每一个继承Proce...
c6d92dc424e95b6378c43eb99d934375630c943d
e1fe66628d58e66b25d910c6d2f173a7dfa74301
/1. Edge AI Fundamentals with OpenVINO/4. Inference Engine/Workspaces/3. Integrate into an Edge App/solution/app-custom.py
48e61b9d9b66578fc97dd81f97cebbf7727c6f5e
[ "MIT" ]
permissive
mmphego/Udacity-EdgeAI
7c5443c4f19eaaf4f6eb44739f7e6413ba26e106
25af22f85772adc25ff9d5a59ba8a33a1e5551cd
refs/heads/master
2022-12-31T15:39:07.077926
2020-10-20T11:45:58
2020-10-20T11:45:58
258,950,438
8
1
MIT
2020-05-25T14:38:30
2020-04-26T05:48:07
Jupyter Notebook
UTF-8
Python
false
false
4,277
py
import argparse import cv2 from inference import Network INPUT_STREAM = "test_video.mp4" CPU_EXTENSION = "/opt/intel/openvino/deployment_tools/inference_engine/lib/intel64/libcpu_extension_sse4.so" def get_args(): """ Gets the arguments from the command line. """ parser = argparse.ArgumentParser("Run...
3cd47a7d7dd674e5aa584bc0ac1049be6c8bdf48
b01646abacbef23719926477e9e1dfb42ac0f6a9
/Rebrov/training/673K/673K_O088N12_Rebrov_lib_and_all_families/input.py
d9cd3c9eddcac08e009b6e6733f837aefa7982fc
[]
no_license
Tingchenlee/Test
41b0fd782f4f611d2b93fda6b63e70956881db33
37313c3f594f94cdc64c35e17afed4ae32d3e4e6
refs/heads/master
2023-06-02T05:38:32.884356
2021-06-10T11:59:02
2021-06-10T11:59:02
349,764,587
0
0
null
null
null
null
UTF-8
Python
false
false
3,308
py
# Microkinetic model for ammonia oxidation # E.V. Rebrov, M.H.J.M. de Croon, J.C. Schouten # Development of the kinetic model of platinum catalyzed ammonia oxidation in a microreactor # Chemical Engineering Journal 90 (2002) 61–76 database( thermoLibraries=['surfaceThermoPt111', 'primaryThermoLibrary', 'thermo_DFT...
3071ce5a9c9fdebf28175ab07ecb3091a84ba165
edfa045d12b8efb65de20261ff80a86160298e44
/checkout/migrations/0003_orderitem_order.py
97c09cc1a4f31557128d3510eed3d113a9d9b7d2
[ "MIT" ]
permissive
yusif763/Unistore-pro
1d559a89bb71f3db8b5d1e89df64ed7113f00f2a
41ad0fa209c79a201d3f6a7aa68ec0ace707dcad
refs/heads/main
2023-04-24T02:50:30.085011
2021-04-29T11:00:11
2021-04-29T11:00:11
362,782,688
4
0
null
null
null
null
UTF-8
Python
false
false
549
py
# Generated by Django 3.1.7 on 2021-04-13 09:08 from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('checkout', '0002_auto_20210413_0746'), ] operations = [ migrations.AddField( model_name='orderi...
4936d190287dd5249daf34313e71e03c891daab6
fb5d9f9b4ae3d7059d582ebb390916c2f9528852
/util/__init__.py
231dd87f66aa7d5f32d08714cbb4ea33acfaa90f
[]
no_license
tianxiaguixin002/Code-Implementation-of-Super-Resolution-ZOO
32d4168f4d8d031968b7a601cf68b50730b15b06
f6ccf309c7653a27173de5184d17bb5933baab14
refs/heads/master
2022-11-13T17:09:11.484532
2020-07-06T01:51:25
2020-07-06T01:51:25
null
0
0
null
null
null
null
UTF-8
Python
false
false
1,476
py
"""This package includes a miscellaneous collection of useful helper functions.""" import os def mkdirs(paths): """create empty directories if they don't exist Parameters: paths (str list) -- a list of directory paths """ if isinstance(paths, list) and not isinstance(paths, str): for p...
38e065c61bb431a8fc4dd5b8d0a8130d39cb9dfd
4ddf4fa6a4a499d64b23fb99d70a7bb3802fd1b0
/exercises/flask_regression.py
4fd8a87deed5370e70ec83805bf14ac80fa11aac
[]
no_license
biterbilen/MVML
2b318b3883c00ed1908ef75924077e3aab639094
76a79ded26d09452234b7ae2b4809e47aa93df70
refs/heads/master
2023-01-13T10:04:10.269589
2020-11-16T18:55:19
2020-11-16T18:55:19
null
0
0
null
null
null
null
UTF-8
Python
false
false
364
py
import pickle from flask import Flask, request, render_template import pandas as pd app = Flask(__name__) with open('exercises/model.pkl', 'rb') as f: model = pickle.load(f) @app.route("/") def index(): pass @app.route("/result", methods=["POST"]) def predict(): new = pd.DataFrame({'X': [20]}) y = f...
686a68dd2426c857f28b7069b29021b4b28d8624
9743d5fd24822f79c156ad112229e25adb9ed6f6
/xai/brain/wordbase/verbs/_monsters.py
e7f2bb60af124f30bf240705f5e9a379d84687ad
[ "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
245
py
from xai.brain.wordbase.verbs._monster import _MONSTER #calss header class _MONSTERS(_MONSTER, ): def __init__(self,): _MONSTER.__init__(self) self.name = "MONSTERS" self.specie = 'verbs' self.basic = "monster" self.jsondata = {}
90088be62e540370be33da0a6c2da6c4e57b429a
d3426a5d1bbecde0fe480e7af64a54bfdb8295eb
/students/migrations/0005_auto_20170802_1524.py
24c508cf44b2fa93d7d609ad89d31875eb8a08a5
[ "MIT" ]
permissive
pu6ki/elsyser
5a3b83f25f236b4a4903180985f60ced98b3fb53
52261c93b58422b0e39cae656ae9409ea03a488d
refs/heads/master
2021-01-12T18:06:18.375185
2017-12-10T18:18:34
2017-12-10T18:18:34
71,325,732
5
4
MIT
2017-12-10T18:18:35
2016-10-19T06:26:47
Python
UTF-8
Python
false
false
739
py
# -*- coding: utf-8 -*- # Generated by Django 1.10.2 on 2017-08-02 12:24 from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('students', '0004_auto_20170801_1243'), ] operations = [ migrations.DeleteMo...
0d243a771485ed631550fd265ff1c7dd644c4b81
d8af7c6372aff57012c80d3b8a9dfaab81499f71
/AIDStudy/01-PythonBase/day07/exercise05.py
ab36bcf266a5024e045bea117f549cbbf81366f4
[]
no_license
fanxiao168/pythonStudy
4843c56019b8f997fd7fc566904a9e0162e9a541
f94e2238d40c41ee54ff4184c500d659c6820c03
refs/heads/master
2021-02-04T20:54:10.850770
2020-05-28T08:55:35
2020-05-28T08:55:35
243,708,800
1
0
null
null
null
null
UTF-8
Python
false
false
456
py
# 3行5列的二维列表 list01 = [ [0, 1, 2, 3, 4], [1, 28, 45, 6, 7], [20, 7, 3, 65, 2] ] # 将第二行元素打印出来 for item in list01[1]: print(item, end=' ') # 将第一列打印出来 print(list01[0][0]) print(list01[1][0]) print(list01[2][0]) for i in range(len(list01)): print(list01[i][0]) # 将全部元素打印出来 for i in range(len(list01)): ...
46077844615c08090f6de524a45ad3b9f9d1e776
e415e4cdab3d1cd04a4aa587f7ddc59e71977972
/datetime/datetime.timedelta.py
77ed0bd2af1f40780439d18c8c5f04973b36cd10
[]
no_license
nixawk/hello-python3
8c3ebba577b39f545d4a67f3da9b8bb6122d12ea
e0680eb49d260c5e3f06f9690c558f95a851f87c
refs/heads/master
2022-03-31T23:02:30.225702
2019-12-02T10:15:55
2019-12-02T10:15:55
84,066,942
5
7
null
null
null
null
UTF-8
Python
false
false
691
py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ class datetime.timedelta A duration expressing the difference between two date, time, or datetime instances to microsecond resolution. """ import datetime def datetime_timedelta(): # def __new__(cls, days=0, seconds=0, microseconds=0, milliseconds=0, mi...
b7020ef6386d6ad70f6a34fd08ff52d6e5aac54a
bf4f5e90fff95800f3ab944efcdb9aace29be71d
/banshee-master/api/mms/balance/mall_balance.py
2f573caaf12c82cd5229034b31716e1636ce01a9
[]
no_license
tanlu01/testfan
c77c833d4e164a4786f20d7f28ffbb99cd6dcb2e
de8cf936dc7e80a9e2847fa47ae5c909729675b1
refs/heads/master
2023-04-20T17:12:57.515484
2021-05-10T15:53:15
2021-05-10T15:53:15
365,418,159
0
0
null
null
null
null
UTF-8
Python
false
false
3,918
py
from api.mms.mms_ import Mms class MallBalance(Mms): method = 'post' api = '/api/mall/Balance' data = {} error_resp = { 'code': 400000, 'message': '没有可以购买的商品' } expected_schema = { "$schema": "http://json-schema.org/draft-06/schema#", "title": "expected_data",...
eb7268205ffc0e037565f404d2dc6e35a518804e
5cfc22491d6c83e807b21883ce71fdb958a2c53f
/identify/trend.py
826bf058e30afc7807df0bd377da5c8348ad60e1
[]
no_license
Jeffin-Studios/stocktool
ce29824bfa663927eac1b17dad3ed7830dbedf1f
96f4e96feb4de9a54028e4b5ef56bd8554f122eb
refs/heads/master
2020-03-28T03:27:27.271479
2018-10-18T08:03:08
2018-10-18T08:03:08
147,646,775
1
1
null
null
null
null
UTF-8
Python
false
false
4,466
py
#rolling average for both stock and market from pandas_datareader import data import matplotlib.pyplot as plt import pandas as pd import numpy as np class stocktrend(): # Initialization requires a ticker symbol def __init__(self, stock_name, start_date = None, end_date = None, draw_graph = False): self.name ...
0e361c2d25f1dc4f3d81ae0f99eff2116e37073d
eec0d71067c95a772e3fdeeadab242230cd2b31f
/mysite/settings.py
e3abb79a4fe1388ad0999909201edfd4ccbc3f9b
[]
no_license
amcmy/my-first-blog
d543ef051ab9decca1a5ff073c3bb40ef552f74a
5bb9d7284633f31797e5cc83fcd3d14b9eed8960
refs/heads/master
2020-05-17T15:21:36.295933
2019-04-27T15:14:09
2019-04-27T15:14:09
183,788,627
0
0
null
null
null
null
UTF-8
Python
false
false
3,189
py
""" Django settings for mysite project. Generated by 'django-admin startproject' using Django 2.2. For more information on this file, see https://docs.djangoproject.com/en/2.2/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/2.2/ref/settings/ """ import os # Bu...
8214a4f2f5d28141284cdcea9a1c77e386cbbf48
cb4736c3db7288ca3868e319ace6c19364302d2f
/module_template/repeater.py
e453e33ab9530bcdf5872230c59496fffeb4f50f
[ "MIT" ]
permissive
rstms/repeat
0928d9833463e5048071a2564916b1a2eb233fb6
af9f1aa01cc0d5d5fd8e6ff688e7c84267b8600f
refs/heads/master
2023-07-27T16:40:04.187344
2021-09-11T03:43:31
2021-09-11T03:43:31
399,602,397
0
0
null
null
null
null
UTF-8
Python
false
false
1,784
py
# -*- coding: utf-8 -*- """repeater object for repeat command line tool This simple module contains a Repeater() class with a run() method that does the work of the program. Example: To use the function open an input stream and an output stream in text mode, then cal the run method specifying the number of t...
4f57c4e198a2dc78dc00b90d05162dd65d57d004
ebd1d1bbaa0fe30590e2c8c0d19a9d7eff180320
/arp/scripts/xtalk_preview.py
7110e508cd826977ff0fc86692a60f78449baab7
[]
no_license
HERA-Team/hera_sandbox
3093009c21e13a79bf3914d64b521b8fbc4bc733
f9d292f4a91c0599947e3c013b48114b2097d76d
refs/heads/master
2021-11-26T16:54:38.665721
2021-10-05T19:41:40
2021-10-05T19:41:40
95,712,482
2
6
null
2017-07-10T19:46:22
2017-06-28T21:17:39
Python
UTF-8
Python
false
false
1,100
py
#! /usr/bin/env python import aipy as a, capo as C, pylab as p, numpy as n import sys CH0,CH1 = 16,182 fqs = n.linspace(.1,.2,203) jy2T = C.pspec.jy2T(fqs) fqs = fqs[CH0:CH1] aa = a.cal.get_aa('psa6240_v003', n.array([.15])) t,dat,flg = C.arp.get_dict_of_uv_data(sys.argv[1:], 'cross', 'I') window = a.dsp.gen_window(fq...
b3bb756dcc5fa36b2ee79947713b1d3b50e1fdda
03dddfda1c488f08ae4b7914e83dd96c24f1e3d7
/meadow_mall/meadow_mall/apps/oauth/utils.py
25c69391d72c9ec60ab021d7c100769fbc532cd7
[]
no_license
zizle/MeadowMall
0223ed134baf164eb71358e0c0d3c7a0fbf58782
d5cc05e71a666724726bc324c1eb4841b828b284
refs/heads/master
2020-03-21T00:14:47.853180
2018-07-11T00:38:55
2018-07-11T00:38:55
137,884,601
0
0
null
2018-07-11T00:38:56
2018-06-19T11:50:28
HTML
UTF-8
Python
false
false
3,856
py
# _*_ coding:utf-8 _*_ # QQ登录辅助 from django.conf import settings from urllib.parse import urlencode, parse_qs from urllib.request import urlopen from itsdangerous import TimedJSONWebSignatureSerializer as TJWSSerializer, BadData import logging import json from .exceptions import OAuthQQAPIError from . import constants...
df21b265a6cacdff01901795d819235d4a0eb590
f7e0780b4d73ebf6e50fe4053c01fd3cc4d6b227
/auctioning_platform/shipping_infrastructure/shipping_infrastructure/repositories/address.py
8ec2f8f1ec18b584e7ea6e8fffc9eacf0ddcf650
[ "MIT" ]
permissive
Enforcer/clean-architecture
78d663585f913c51a0460bcafa4af35515cdf549
f0c1c0a8364996d309e7381b44933807529200b1
refs/heads/master
2023-02-20T01:40:24.653512
2022-08-02T20:59:03
2022-08-02T20:59:03
208,138,785
454
51
MIT
2023-02-16T01:31:26
2019-09-12T20:16:08
Python
UTF-8
Python
false
false
589
py
import uuid import faker from shipping import AddressRepository from shipping.domain.entities import Address from shipping.domain.value_objects import ConsigneeId class FakeAddressRepository(AddressRepository): def get(self, consignee_id: ConsigneeId) -> Address: fake = faker.Faker() return Addr...
eb9f0a5bbe7e49980ce27a7e5656855d9bfe7f04
14427b4c73fef188791affb42c9fffe8e25b7dc1
/tests/solr_tests/tests/admin.py
082e19f81b3cb37860f748e658e952a736a542f1
[ "BSD-3-Clause", "MIT" ]
permissive
markng/django-haystack
697ea05dd49980be43002e0fb6bf5c2b6357a015
78160bb2f530f7fadc0caf22f2f8babbac89ef32
refs/heads/master
2021-01-17T23:13:00.755184
2010-10-21T01:02:38
2010-10-21T01:02:38
1,010,851
1
0
null
null
null
null
UTF-8
Python
false
false
2,667
py
from django.conf import settings from django.contrib.auth.models import User from django.test import TestCase from haystack import backends from core.models import MockModel from solr_tests.tests.solr_backend import SolrMockModelSearchIndex, clear_solr_index class SearchModelAdminTestCase(TestCase): fixtures = ['...
d6d19a882acc2888a4c56b24b29d7ea83b450ec4
b2cfcacbd898f758a56d095f2140681934205d89
/GeekShop_mentor/src_lesson_8/step_6(CBV_DetailView)/geekshop/geekshop/urls.py
f61dfb9bfdf3de46c576ad4a7bb2d44badcae26a
[]
no_license
AndreySperansky/Django_1
7d3be3ea2ede8e46d932fdae146ce4a7c4e300b4
0fec0a9a02b887fd8b45a5b763b7da5dc6377208
refs/heads/master
2022-12-15T19:56:23.611288
2020-09-21T17:40:40
2020-09-21T17:40:40
284,131,625
0
0
null
null
null
null
UTF-8
Python
false
false
677
py
from django.conf.urls import url, include from django.contrib import admin import mainapp.views as mainapp from django.conf import settings from django.conf.urls.static import static urlpatterns = [ url(r'^$', mainapp.main, name='main'), url(r'^products/', include('mainapp.urls', namespace='products')), u...
60f8ee32eec66d5a1aceb50eae7ede2d9486b5ac
12068d6ebe90fcbd13c635f35c23ce7c73884b12
/Lecture/Lecture_basic/TSP.py
bdc30261cdae927d3d5f5be96d23f11de1767206
[]
no_license
jngcii/python-algorithm
6ffb7a90eb0288cadc64bc3b2bf2d103455d2337
e976b0033beeeb14217e7acc8d67f201a79184f2
refs/heads/master
2020-04-21T09:09:13.353113
2020-01-23T17:36:02
2020-01-23T17:36:02
169,439,831
1
0
null
null
null
null
UTF-8
Python
false
false
2,119
py
def next_permutation(a): # 다음 순열 찾는 함수 # 맨 뒤부터 자기보다 자기 바로앞이 작은 놈을 찾는다. i = len(a) - 1 if i > 0 and a[i] <= a[i-1]: i -= 1 # 끝까지 갔는데도 자기보다 작은놈을 못찾았다. ======> e.g) 987654321 if i <= 0: False # 이제 i-1은 무조건 i 보다 크다. # i부터 마지막중에 i-1보단 큰것중에 제일 작은거 찾기 # i-1 이후로는 내림차순(87654)으로 정렬되어있어서 맨뒤부...
f04ac3ed7b2bb5e3752f0ef2d96c1cb9e22b29a2
1670af31dd78a82915b8cda16c181c0aa31a1c3a
/favs/urls.py
4e213700c57ab1fa1133e8a7999e64f4f4711de4
[ "CC-BY-3.0", "MIT" ]
permissive
chyuting/dj4e-samples
ecd2eca6edc50402a55dee487c11f74ec873cb2d
bbe3dcd214789e4be96dd2460018524f8078b4e3
refs/heads/master
2020-09-15T18:12:47.472948
2019-11-22T20:28:57
2019-11-22T20:28:57
223,524,434
1
0
MIT
2019-11-23T03:24:03
2019-11-23T03:24:02
null
UTF-8
Python
false
false
1,083
py
from django.urls import path, reverse_lazy from . import views from django.views.generic import TemplateView # In urls.py reverse_lazy('favs:all') # In views.py class initialization reverse_lazy('favs:all') # In views.py methods reverse('favs:all') # In templates {% url 'favs:thing_update' thing.id %} app_name='favs'...
dbc327a8c84469e18f9c25854df9fec96a476708
0fb505765604b586c3a46e608fc23930f8501db5
/venv/lib/python2.7/site-packages/django/contrib/staticfiles/apps.py
ae69667b7b99c779598188e2cff803417bb26aa0
[ "MIT" ]
permissive
domenicosolazzo/practice-django
b05edecc302d97c97b7ce1de809ea46d59e2f0e6
44e74c973384c38bd71e7c8a1aacd1e10d6a6893
refs/heads/master
2021-08-19T15:36:22.732954
2015-01-22T18:42:14
2015-01-22T18:42:14
25,118,384
0
0
MIT
2021-06-10T19:50:51
2014-10-12T12:08:47
Python
UTF-8
Python
false
false
206
py
from django.apps import AppConfig from django.utils.translation import ugettext_lazy as _ class StaticFilesConfig(AppConfig): name = 'django.contrib.staticfiles' verbose_name = _("Static Files")
7601589c18fcecc2f0a8da320cabeceadd1e1dbe
9ef6d625945ecdebb476614a96a83a2139a92e9b
/nlstruct/datasets/quaero.py
8d1aedb5e67c9965c45a5d4f2bc23add2d4fe78c
[ "MIT" ]
permissive
percevalw/nlstruct
f0cdf8ed86a32a5a96204b1c787eb35b1a4a804a
7b5fa2230a555331e2e68b25fbb2b25e4c9404a0
refs/heads/master
2023-08-09T00:07:13.782518
2023-07-03T14:37:43
2023-07-03T14:37:43
229,176,303
13
7
MIT
2023-07-23T00:52:19
2019-12-20T02:38:34
Python
UTF-8
Python
false
false
6,137
py
import os import random import zipfile from sklearn.datasets._base import RemoteFileMetadata from nlstruct.datasets.brat import load_from_brat from nlstruct.datasets.base import NetworkLoadMode, ensure_files, NormalizationDataset class QUAERO(NormalizationDataset): REMOTE_FILES = [ RemoteFileMetadata( ...
1ecc6c19485b08f78b1da7819afdbb6fb6669109
93713f46f16f1e29b725f263da164fed24ebf8a8
/Library/bin3/jupyter-kernelspec
e82d73045ac485f46b7e7879db1c57e894321d7b
[ "Python-2.0", "BSD-3-Clause" ]
permissive
holzschu/Carnets
b83d15136d25db640cea023abb5c280b26a9620e
1ad7ec05fb1e3676ac879585296c513c3ee50ef9
refs/heads/master
2023-02-20T12:05:14.980685
2023-02-13T15:59:23
2023-02-13T15:59:23
167,671,526
541
36
BSD-3-Clause
2022-11-29T03:08:22
2019-01-26T09:26:46
Python
UTF-8
Python
false
false
344
#!/var/mobile/Containers/Data/Application/966C455F-0658-40E2-B076-EC684AFD0415/Library/bin/python # -*- coding: utf-8 -*- import re import sys from jupyter_client.kernelspecapp import KernelSpecApp if __name__ == '__main__': sys.argv[0] = re.sub(r'(-script\.pyw?|\.exe)?$', '', sys.argv[0]) sys.exit(KernelSpe...
e49d78dfbaf2eab206ce9b59421933eb775a7f3e
523f8f5febbbfeb6d42183f2bbeebc36f98eadb5
/424.py
25219c47f183e713f54738fc014afb70c66da0ff
[]
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
669
py
class Solution(object): def characterReplacement(self, s, k): """ :type s: str :type k: int :rtype: int """ dict=[0]*26 tail=0 res=0 for i in range(len(s)): # print(i,tail,dict) dict[ord(s[i])-ord('A')]+=1 ma...
170f17debf8e0aa5216ed9e03bf1456f06c0cc04
a7205bcd48196c1391d8c56414a1e20c39b52aa7
/train_online.py
2f18b62b4240057a1e6866d5f6aabb0846fd5164
[]
no_license
CS-433/cs-433-project-2-fesenjoon
f9f58ef0caa54b08c6d59ffca0cbf2a08642ecb5
cb0f7519901f16ae0cb1bb9b1ae8b89761a0b519
refs/heads/master
2021-04-18T19:56:06.737876
2020-12-17T13:42:15
2020-12-17T13:42:15
314,034,672
0
0
null
null
null
null
UTF-8
Python
false
false
5,511
py
import argparse import json from datetime import datetime import os import numpy as np import torch import models import datasets from utils import train_one_epoch, eval_on_dataloader try: from tensorboardX import SummaryWriter except: from torch.utils.tensorboard import SummaryWriter def build_parser(): ...
0b01562f680ea36d596485130d22202338aa0262
f0d713996eb095bcdc701f3fab0a8110b8541cbb
/9b4h6mK9CBMLwyGiY_6.py
1abf1ae0a48f31137fb13996b1512d64f8d6b0d6
[]
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,117
py
""" In this challenge, you have to find the distance between two points placed on a Cartesian plane. Knowing the coordinates of both the points, you have to apply the **Pythagorean theorem** to find the distance between them. ![Two points on a Cartesian plane](https://edabit- challenges.s3.amazonaws.com/coordinatep...
ee12d3b89ca259032c8f090a344825f2320900a2
45cfc0bf573d0419ff4c2e9cc8d73256be9bf8bb
/lws/translate.py
9a4d17f3e2092934a1d8e61e371afa9ac8f16708
[ "MIT" ]
permissive
KEHANG/Life_Web_Services
c79c0f7df9aa78ca9efee79652c2fc8525076aae
2f519d38692492088fb6ba80a648d2099828b07e
refs/heads/master
2021-06-19T01:02:15.520716
2021-01-03T19:58:02
2021-01-03T19:58:02
149,108,564
0
0
MIT
2018-09-22T22:55:59
2018-09-17T10:27:50
Python
UTF-8
Python
false
false
744
py
import json import requests from flask_babel import _ from flask import current_app def translate(text, source_language, dest_language): if 'MS_TRANSLATOR_KEY' not in current_app.config or not current_app.config['MS_TRANSLATOR_KEY']: return _('Error: the translation service is not configured.') auth = ...
3130f019200ef90cb43098229e4eae8adf5a1006
d08e6e7a2abcc7568fd3b9a6022c79091ebd0efa
/Logic/verify_no_duplicate_seqs_test.py
7924d76700dab6cb85ace88791fd019b1f32ef3e
[]
no_license
hz-xmz/Kaggle-LANL
dd20b6951743fc068a866c799de93d9a89a2429d
0236d3bcaeb2f3f4c960902d6c31ef0c49e749c4
refs/heads/master
2020-09-11T01:25:06.633524
2019-06-07T16:50:41
2019-06-07T16:50:41
null
0
0
null
null
null
null
UTF-8
Python
false
false
1,214
py
import numpy as np import pandas as pd data_folder = '/media/tom/cbd_drive/Kaggle/LANL/Data/' if not 'test_combined' in locals(): test_combined = pd.read_csv( data_folder + 'test_combined.csv').values.reshape(-1, 150000) extreme_length = 10000 first_id = 0 def get_max_shared_seq_len(first_id, sec_id): val...
3a5d3b8bcd880c5bb11c80e625c2118f69744913
d3efc82dfa61fb82e47c82d52c838b38b076084c
/Autocase_Result/SjShObligationCall/YW_GGQQ_YWFSJHA_GOU_084.py
e0ca6b636bc265d2295b0d6957247055bbcce54d
[]
no_license
nantongzyg/xtp_test
58ce9f328f62a3ea5904e6ed907a169ef2df9258
ca9ab5cee03d7a2f457a95fb0f4762013caa5f9f
refs/heads/master
2022-11-30T08:57:45.345460
2020-07-30T01:43:30
2020-07-30T01:43:30
280,388,441
0
0
null
null
null
null
UTF-8
Python
false
false
3,913
py
#!/usr/bin/python # -*- encoding: utf-8 -*- import sys import json sys.path.append("/home/yhl2/workspace/xtp_test/xtp/api") from xtp_test_case import * sys.path.append("/home/yhl2/workspace/xtp_test/option/service") from OptMainService import * from OptQueryStkPriceQty import * sys.path.append("/home/yhl2/workspace/xt...
96cfc8f20622043eeff69349f2ee5eda49f0f6a3
7769cb512623c8d3ba96c68556b2cea5547df5fd
/mmdet/ops/carafe/grad_check.py
06820be2459c9766113796cbe34e76db7ae9c108
[ "MIT" ]
permissive
JialeCao001/D2Det
0e49f4c76e539d574e46b02f278242ca912c31ea
a76781ab624a1304f9c15679852a73b4b6770950
refs/heads/master
2022-12-05T01:00:08.498629
2020-09-04T11:33:26
2020-09-04T11:33:26
270,723,372
312
88
MIT
2020-07-08T23:53:23
2020-06-08T15:37:35
Python
UTF-8
Python
false
false
2,118
py
import os.path as osp import sys import mmcv import torch from torch.autograd import gradcheck sys.path.append(osp.abspath(osp.join(__file__, '../../'))) from mmdet.ops.carafe import CARAFENAIVE # noqa: E402, isort:skip from mmdet.ops.carafe import carafe_naive # noqa: E402, isort:skip from mmdet.ops.carafe import ...
6f925f97b7f04bf835e0d8185ead4532b0c99e7b
9743d5fd24822f79c156ad112229e25adb9ed6f6
/xai/brain/wordbase/nouns/_orbs.py
66df141052b56b070130b15e4bf528655d9c8b3a
[ "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
217
py
from xai.brain.wordbase.nouns._orb import _ORB #calss header class _ORBS(_ORB, ): def __init__(self,): _ORB.__init__(self) self.name = "ORBS" self.specie = 'nouns' self.basic = "orb" self.jsondata = {}
61886c57f514349c383865d61b354268510431e7
350db570521d3fc43f07df645addb9d6e648c17e
/1367_Linked_List_in_Binary_Tree/solution_test.py
3b9df505ae99770b2edb20625a60761479c57dfc
[]
no_license
benjaminhuanghuang/ben-leetcode
2efcc9185459a1dd881c6e2ded96c42c5715560a
a2cd0dc5e098080df87c4fb57d16877d21ca47a3
refs/heads/master
2022-12-10T02:30:06.744566
2022-11-27T04:06:52
2022-11-27T04:06:52
236,252,145
1
1
null
null
null
null
UTF-8
Python
false
false
387
py
''' 1367. Linked List in Binary Tree Level: Medium https://leetcode.com/problems/linked-list-in-binary-tree ''' import unittest class TestSum(unittest.TestCase): def test_sum(self): self.assertEqual(sum([1, 2, 3]), 6, "Should be 6") def test_sum_tuple(self): self.assertEqual(sum((1, 2, 2))...
d8ffdcf84d2027052d36f9dd6c7668b3dec09237
17fb5e4cdcf8e557bd0ab8606dfd88074dc4d525
/ticket_26758/tests.py
0c5f0bcdd0c36962169c74cd5c324dbae1b70edd
[]
no_license
charettes/django-ticketing
0b17c85afa049d1b73db244e1199798feb9a4b73
78ed6a345e760ea46434690e9385ae4d26fc2810
refs/heads/master
2021-01-17T06:38:35.337305
2016-06-15T02:33:38
2016-06-15T02:33:38
45,122,368
0
1
null
2016-02-09T20:21:48
2015-10-28T15:30:59
Python
UTF-8
Python
false
false
291
py
from django.test import TestCase from django.db.models import Count from .models import Company class FooTests(TestCase): def test_foo(self): qs = Company.objects.annotate(ticketcount=Count('srservice')).exclude(ticketcount=0).order_by('-ticketcount') print(list(qs))
768bbacc62ddda437780f7a4469c365ecc15cccc
a31c21bcc4486fd44dd2c5b7f364e8f0320f7dd3
/mlsh/lab/lab/envs/mujoco/ant_obstaclesgen.py
9d1881775735ec9b7f26b3bb7e0f778226fe12c2
[ "MIT" ]
permissive
SynthAI/SynthAI
0cb409a4f5eb309dfc6a22d21ac78447af075a33
4e28fdf2ffd0eaefc0d23049106609421c9290b0
refs/heads/master
2020-03-19T12:49:07.246339
2018-06-07T23:27:51
2018-06-07T23:27:51
136,542,297
3
1
null
null
null
null
UTF-8
Python
false
false
3,907
py
import numpy as np from lab import utils from lab.envs.mujoco import mujoco_env class AntObstaclesGenEnv(mujoco_env.MujocoEnv, utils.EzPickle): def __init__(self): self.count = 0 self.realgoal = 0 mujoco_env.MujocoEnv.__init__(self, 'ant_obstacles_gen.xml', 5) utils.EzPickle.__init_...
55a0831d34cbfef8d1eeff1fafad9e2e71e5f77b
ea378480ba678eb123ef826e3ca0c3eb8f4e538f
/paused/02.DXF write/dxfwrite-1.1.0/tests/test_abstract_entity.py
d9db54a5c2ba688be3762d19b23babb1cd18b1fc
[]
no_license
msarch/py
67235643666b1ed762d418263f7eed3966d3f522
dcd25e633a87cdb3710e90224e5387d3516c1cd3
refs/heads/master
2021-01-01T05:21:58.175043
2017-05-25T08:15:26
2017-05-25T08:15:26
87,453,820
1
0
null
null
null
null
UTF-8
Python
false
false
1,296
py
#!/usr/bin/env python #coding:utf-8 # Created: 15.11.2010 # Copyright (C) 2010, Manfred Moitzi # License: GPLv3 __author__ = "mozman <[email protected]>" try: # Python 2.6 and earlier need the unittest2 package # try: pip install unittest2 # or download source from: http://pypi.python.org/pypi/unit...
238d011d53f467d54bd37298772793a292644147
d87483a2c0b50ed97c1515d49d62c6e9feaddbe0
/.history/buy_top_fc_20210203213703.py
da47d36dfa2e2de55eb512db4b137d0e379b7d01
[ "MIT" ]
permissive
HopperKremer/hoptrader
0d36b6e33922414003cf689fb81f924da076a54b
406793c10bc888648290fd15c7c2af62cf8c6c67
refs/heads/main
2023-06-12T15:51:00.910310
2021-07-06T16:15:41
2021-07-06T16:15:41
334,754,936
0
2
null
null
null
null
UTF-8
Python
false
false
1,567
py
# Buy top tickers from Financhill import requests from tda import auth, client from tda.orders.equities import equity_buy_market, equity_buy_limit from tda.orders.common import Duration, Session import tda import os, sys import time currentdir = os.path.dirname(os.path.realpath(__file__)) parentdir = os.path.dirname(c...
c315767ae48f4b9f82aeda1f355e3cd3dc81471b
7ddded3d38469cd3238a702d7d62cf816cb0d5d5
/cmsplugin_cascade/segmentation/mixins.py
92dd20dd334d71023b13787c88506ee2f5282004
[ "MIT" ]
permissive
sayonetech/djangocms-cascade
8e249ab83bba97dad27aee468a2a6fce0eb58f3b
699d645cefae926d32879fbc6837693082f84c78
refs/heads/master
2022-05-25T02:31:58.059789
2020-04-25T07:33:29
2020-04-25T07:33:29
259,930,919
0
0
MIT
2020-04-29T13:20:54
2020-04-29T13:20:53
null
UTF-8
Python
false
false
7,488
py
from django import VERSION as DJANGO_VERSION from django.conf.urls import url from django.contrib import admin from django.contrib.auth import get_user_model from django.http import HttpResponse, HttpResponseBadRequest from django.template.response import TemplateResponse from django.urls import reverse from django.uti...
b86fb3e8323c7fac53da50672674d2d083ec8e83
c137d7fb6eaa1c1900a63b8dae6b027176a98b6f
/MxShop/apps/user_operation/migrations/0002_auto_20191215_1324.py
67ebf35770168b3b304df8aed21406cfe8fb758c
[]
no_license
LasterSmithKim/vuedjango
22220414ad2f928f0a0df1a0e68c9083e90c1cc7
4a5b7fee4dd3f2d31255d7dc9188ea977a75db29
refs/heads/master
2022-12-10T19:52:25.014956
2019-12-23T16:23:01
2019-12-23T16:23:01
225,315,491
0
0
null
2022-11-22T04:52:05
2019-12-02T07:47:12
JavaScript
UTF-8
Python
false
false
495
py
# Generated by Django 2.2.7 on 2019-12-15 13:24 from django.conf import settings from django.db import migrations class Migration(migrations.Migration): dependencies = [ migrations.swappable_dependency(settings.AUTH_USER_MODEL), ('goods', '0003_auto_20191201_0823'), ('user_operation', '0...
dac682aff595a8ac60201e3480935c04e5b62c3b
83cf642504313b6ef6527dda52158a6698c24efe
/scripts/addons/fd_scripting_tools/autocompletion/suggestions/dynamic/_bpy_fake/__private__/obstacle.py
7598560cf2b91178e54ad5d8d3e0f5402501e10f
[]
no_license
PyrokinesisStudio/Fluid-Designer-Scripts
a4c40b871e8d27b0d76a8025c804d5a41d09128f
23f6fca7123df545f0c91bf4617f4de7d9c12e6b
refs/heads/master
2021-06-07T15:11:27.144473
2016-11-08T03:02:37
2016-11-08T03:02:37
113,630,627
1
0
null
2017-12-09T00:55:58
2017-12-09T00:55:58
null
UTF-8
Python
false
false
500
py
from . struct import Struct from . bpy_struct import bpy_struct import mathutils class Obstacle(bpy_struct): @property def rna_type(self): '''(Struct) RNA type definition''' return Struct() @property def name(self): '''(String) Unique name used in the code and scripting''' ...
358c3dc0cf6ca85640bf9dce63f0bc8db277b92d
c5291e50a3c72c885922378573a0ad423fcedf05
/EasyPay/billpay/controllers/transaction.py
5d51ce3230840967ef71d5b124a63aff15748a5b
[]
no_license
raghurammanyam/django-projects
bcc3ed6285882af437a2995514cef33760fb063e
dd20ae354f7f111a0176a1cc047c099bd23e9f05
refs/heads/master
2022-12-12T19:22:31.698114
2018-12-09T09:41:45
2018-12-09T09:41:45
137,443,359
0
0
null
2022-11-22T03:01:07
2018-06-15T05:08:15
Python
UTF-8
Python
false
false
1,353
py
from rest_framework.views import APIView from rest_framework.response import Response from django.core import serializers from django.http import JsonResponse from billpay.models import transactions from billpay.serializers.transactionserializer import transactionSerializer,gettransactionSerializer from django.http imp...
3e2c4eec3c3fd761e5f94ad65d35d6609cc1d30a
c41edf53089b1ee466ea578aa74f0c1e9b95a8b3
/aqi_v3.0.py
04b339479b8e885f186fe65eb4e7373bb5804cc2
[]
no_license
gjw199513/aqidemo
fb4e81e6d1f6b40c14bbcc5401ce57eac11beb2b
64dc64def274916aa513890cb24e18777518c375
refs/heads/master
2021-05-11T12:33:20.256133
2018-01-16T09:17:49
2018-01-16T09:17:49
117,661,305
0
0
null
null
null
null
UTF-8
Python
false
false
884
py
# -*- coding:utf-8 -*- __author__ = 'gjw' __time__ = '2018/1/16 0016 上午 9:33' # AQI计算 # 读取json文件 import json import csv def process_json_file(filepath): """ 解码json文件 :param filepath: :return: """ f = open(filepath, mode='r', encoding='utf-8') city_list = json.load(f) return city_list...
55bd0b4a233bda1faa5458145b221dc1f947400a
e7c3d2b1fd7702b950e31beed752dd5db2d127bd
/code/pythagorean_tree/sol_395.py
a058d0ed47da7c5635ddf92ee8c14e841b46c257
[ "Apache-2.0" ]
permissive
Ved005/project-euler-solutions
bbadfc681f5ba4b5de7809c60eb313897d27acfd
56bf6a282730ed4b9b875fa081cf4509d9939d98
refs/heads/master
2021-09-25T08:58:32.797677
2018-10-20T05:40:58
2018-10-20T05:40:58
null
0
0
null
null
null
null
UTF-8
Python
false
false
1,396
py
# -*- coding: utf-8 -*- ''' File name: code\pythagorean_tree\sol_395.py Author: Vaidic Joshi Date created: Oct 20, 2018 Python Version: 3.x ''' # Solution to Project Euler Problem #395 :: Pythagorean tree # # For more information see: # https://projecteuler.net/problem=395 # Problem Statement ''' T...
4921921057dceaa1a35447e580f62d0b41e5898e
e6590826c10648c472743c20b898655ec0ef3ce5
/7.14.py
1417073e3f79cdfa391f4ccd257ba21c5e5cc211
[]
no_license
suddencode/pythontutor_2018
a770fbf476af049dc8f04c8b0f81cce7922a63c4
767cdd0d980be290a613ebda455a49daad1a7902
refs/heads/master
2020-03-24T00:15:07.744889
2019-02-11T20:17:42
2019-02-11T20:17:42
142,281,968
2
0
null
null
null
null
UTF-8
Python
false
false
131
py
a = [int(s) for s in input().split()] c = '' for f in range(len(a)): if a.count(a[f]) == 1: c += str(a[f]) + ' ' print(c)
5c740df3c278cbd5a651616a8c6362d2a129e5df
0a46b027e8e610b8784cb35dbad8dd07914573a8
/scripts/venv/lib/python2.7/site-packages/cogent/struct/selection.py
03f31e74ff518727fac35b01df2868657cf41af5
[ "MIT" ]
permissive
sauloal/cnidaria
bb492fb90a0948751789938d9ec64677052073c3
fe6f8c8dfed86d39c80f2804a753c05bb2e485b4
refs/heads/master
2021-01-17T13:43:17.307182
2016-10-05T14:14:46
2016-10-05T14:14:46
33,726,643
3
0
null
null
null
null
UTF-8
Python
false
false
3,229
py
"""Contains functions to select and group structural entities.""" from cogent.core.entity import StructureHolder, ModelHolder, ChainHolder, \ ResidueHolder, AtomHolder, HIERARCHY __author__ = "Marcin Cieslik" __copyright__ = "Copyright 2007-2012, The Cogent Project" __credits__ = ["Mar...
653912fc3bb836925fa3ad1cc2c80b096d3ce413
c36d9d70cbb257b2ce9a214bcf38f8091e8fe9b7
/1480_running_sum_of_1d_array.py
2963386c35e2ba41f6b22c1535d379e20a42c43a
[]
no_license
zdadadaz/coding_practice
3452e4fc8f4a79cb98d0d4ea06ce0bcae85f96a0
5ed070f22f4bc29777ee5cbb01bb9583726d8799
refs/heads/master
2021-06-23T17:52:40.149982
2021-05-03T22:31:23
2021-05-03T22:31:23
226,006,763
0
0
null
null
null
null
UTF-8
Python
false
false
218
py
class Solution: def runningSum(self, nums: List[int]) -> List[int]: n = len(nums) if n == 1: return nums for i in range(1,n): nums[i] += nums[i-1] return nums
1cbbbcd8c445f2dc867f77a6fe853653e4a2819d
0b69a011c9ffee099841c140be95ed93c704fb07
/problemsets/Codeforces/Python/A586.py
d7228d5b1012ec2539b03decd80c92a6c9012979
[ "Apache-2.0" ]
permissive
juarezpaulino/coderemite
4bd03f4f2780eb6013f07c396ba16aa7dbbceea8
a4649d3f3a89d234457032d14a6646b3af339ac1
refs/heads/main
2023-01-31T11:35:19.779668
2020-12-18T01:33:46
2020-12-18T01:33:46
320,931,351
0
0
null
null
null
null
UTF-8
Python
false
false
178
py
""" * * Author: Juarez Paulino(coderemite) * Email: [email protected] * """ import re input() print(len(''.join(re.split('00+',input().replace(' ','').strip('0')))))
9bf48177a873f6126e4cfa4661fed22742055db9
15f321878face2af9317363c5f6de1e5ddd9b749
/solutions_python/Problem_116/795.py
219e317d76df5272a163058483e9e3d06bc08a8e
[]
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
1,355
py
#!/usr/bin/python2 def won(player): return rows(player) or cols(player) or diag1(player) or diag2(player) def rows(player): for i in range(0,4): if row(i,player): return True return False def cols(player): for j in range(0,4): if col(j,player): return True ...
85f5a86b401a45080844f34bc6d9b786c830a113
71c7683331a9037fda7254b3a7b1ffddd6a4c4c8
/Phys/BsJPsiKst/python/BsJPsiKst/syst.py
64b1b8e87dad10cd219df5f4cd53e134b168dbff
[]
no_license
pseyfert-cern-gitlab-backup/Urania
edc58ba4271089e55900f8bb4a5909e9e9c12d35
1b1c353ed5f1b45b3605990f60f49881b9785efd
refs/heads/master
2021-05-18T13:33:22.732970
2017-12-15T14:42:04
2017-12-15T14:42:04
251,259,622
0
1
null
null
null
null
UTF-8
Python
false
false
130
py
from math import * eps = 1.011 f = 0.951 k = 1.063 def err(s1,s2,v): a1 = abs(s1-v) a2 = abs(s2-v) return max(a1,a2)
bb64dbc2667d5b007272f60222fdce55f6a7ba45
21f98d8bb31264c94e7a98fb8eb806d7f5bd396e
/Binary Search/081. Search in Rotated Sorted Array II.py
996738cbc12be3cb5963f0b2d735bfec29253141
[]
no_license
mcfair/Algo
e1500d862a685e598ab85e8ed5b68170632fdfd0
051e2a9f6c918907cc8b665353c46042e7674e66
refs/heads/master
2021-10-31T01:25:46.917428
2021-10-08T04:52:44
2021-10-08T04:52:44
141,460,584
2
2
null
null
null
null
UTF-8
Python
false
false
875
py
""" When pivot has duplicates, nums[0]==nums[-1], the solution for LC33 doesn't apply here anymore """ class Solution(object): def search(self, nums, target): if not nums: return False if target == nums[0]: return True pivot = nums[0] l, r = 0, len(nums) #this while ...
c381edbdc210fa7e13c9646b2572c064b2fb4914
9b68d23d4409af5921a51e2d91344090996787e5
/main_backup20190512.py
ce5655b0b8aebe49a859eeb899f1dea4d9abaf20
[]
no_license
sasakishun/segm
48381b77b9a876c44edfbcdbb4a2ef19096b48f4
d48158243853d737b7056815108aef4e0ac5b6ca
refs/heads/master
2020-05-05T10:23:12.673182
2019-05-14T07:46:07
2019-05-14T07:46:07
179,943,924
0
0
null
2019-04-07T09:31:08
2019-04-07T09:31:08
null
UTF-8
Python
false
false
7,122
py
from model import Model from load_data import Datagen, plot_data import tensorflow as tf from util import plot_segm_map, calc_iou import numpy as np import networkx as nx import adjacency import matplotlib.pyplot as plt import scipy import math np.set_printoptions(threshold=np.inf) G = nx.Graph() nodes = np.array(lis...
7ef60b70a910574209907c3a9e4d6c0dc73d5b45
67b0d2d2e1e3b2b9fba4cfc14adc31f503bb0b91
/AirConditioningV2/filters.py
54b56a16c2e40a45057929cf6936b15a8652dbdb
[]
no_license
Hk4Fun/qtstudy
02a5059555462f5e7fe626632e351f4af69206f6
7b38853e29c8e055f9db2828c34815000158bf28
refs/heads/master
2020-03-14T11:29:32.501540
2018-06-16T07:48:35
2018-06-16T07:48:35
131,591,363
0
0
null
null
null
null
UTF-8
Python
false
false
1,397
py
__author__ = 'Hk4Fun' __date__ = '2018/5/15 17:24' import time import datetime from PyQt5.QtCore import QDate from AirConditioningV2.settings import * def mapWindSpeed_c2w(wind_speed): return {LOW_WIND: '低风', MID_WIND: '中风', HIGH_WIND: '高风'}[wind_speed] def mapWindSpeed_w2c(wind_speed): return {'低风': LOW...
029838e1292b4def0204d31ffebfc8890bbee7bc
8906e04870524f190a11f3eb3caf8fe377ab3a24
/Chapter14/Chapter_14/multiprocessing_env.py
9c110a17857d5a7f8028ddace2f37a2e3e7c1954
[ "MIT" ]
permissive
PacktPublishing/Hands-On-Reinforcement-Learning-for-Games
8719c086c8410a2da2b4fb9852b029a4c8f67f60
609d63ee5389b80b760a17f7f43abe632d99a9bb
refs/heads/master
2023-02-08T19:35:30.005167
2023-01-30T09:09:07
2023-01-30T09:09:07
231,567,217
54
32
MIT
2022-04-21T06:47:24
2020-01-03T10:43:21
Python
UTF-8
Python
false
false
4,886
py
#This code is from openai baseline #https://github.com/openai/baselines/tree/master/baselines/common/vec_env import numpy as np from multiprocessing import Process, Pipe def worker(remote, parent_remote, env_fn_wrapper): parent_remote.close() env = env_fn_wrapper.x() while True: cmd, data = remote...
74b490218935aa0cdad3e8d7ddf4d99da22c41ec
2542edca28a456aa5c217be10419e56fc581fa4e
/dataread.py
ad68b69900a80d898c714dc5dd7e53ff56578f0a
[]
no_license
neeshuagr/profile_match_score
16bfef57c38e6993148175bf40c29acae6e7e9a1
77f4f8035746f075b8232e466907f18aa3eef641
refs/heads/master
2020-04-29T08:22:35.568600
2019-03-16T15:28:11
2019-03-16T15:28:11
175,984,719
1
0
null
null
null
null
UTF-8
Python
false
false
7,041
py
#!/usr/bin/python3.4 import datareadfiletypes import config import filemanager import utility import dcrnlp import custom import datetime import dictionaries import pyodbc import dbmanager def route_dataread(filepaths): data_read_count = int(utility.read_from_file( config.ConfigManager().ExecutioncountFi...
24f8c5f6b848ba541a0f03a6241859851b481ca3
53fab060fa262e5d5026e0807d93c75fb81e67b9
/backup/user_386/ch92_2019_10_02_18_01_55_591754.py
c842af9ea317fe2aab5bd222878e1be5c6911078
[]
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
276
py
dict = {} dict['felipe']="lacombe" dict['ohara']="shiba" def simplifica_dict(dict): dictLista = [] for key, value in dict.items(): dictLista = [key,value] dictLista.append(dictLista) print (dictLista) for i in dictLista: print (i)
f408e84b593fd962f105e3137ee4041a8f4baee6
ea4e262f3dc18a089895fef08bedefc60b66e373
/supervised_learning/0x01-classification/4-neuron.py
5ceefc3c0dea7f50a83093a29231b625e4e999eb
[]
no_license
d1sd41n/holbertonschool-machine_learning
777899d4914e315883ba0c887d891c0c8ab01c8a
5f86dee95f4d1c32014d0d74a368f342ff3ce6f7
refs/heads/main
2023-07-17T09:22:36.257702
2021-08-27T03:44:24
2021-08-27T03:44:24
317,399,917
0
0
null
null
null
null
UTF-8
Python
false
false
2,257
py
#!/usr/bin/env python3 """[summary] Raises: TypeError: [description] ValueError: [description] """ import numpy as np class Neuron: """[summary] """ def __init__(self, nx): """[summary] Args: nx ([type]): [description] Raises: TypeErr...
cb884614e8d42df912c3aefa67005b33d068d5f6
73758dde83d1a1823c103e1a4ba71e7c95168f71
/nsd2003/py01/day02/login2.py
4eefdabd2111bbcb78f2b762df349d7530f21edb
[]
no_license
tonggh220/md_5_nsd_notes
07ffdee7c23963a7a461f2a2340143b0e97bd9e1
a58a021ad4c7fbdf7df327424dc518f4044c5116
refs/heads/master
2023-07-02T01:34:38.798929
2021-05-12T08:48:40
2021-05-12T08:48:40
393,885,415
0
0
null
null
null
null
UTF-8
Python
false
false
228
py
import getpass username = input('username: ') password = getpass.getpass('password: ') if username == 'bob' and password == '123456': print('\033[32;1m登陆成功\033[0m') else: print('\033[31;1m登陆失败\033[0m')
11852eaac17d838c7e11ed135d73821c3fb707bd
8985adb377e92b4764d1b138b5c23c92fab44244
/tests/test_open_file.py
380fbd698fba2697e062433f5e6d758c6238ff2a
[ "MIT" ]
permissive
vuillaut/pyeventio
b8f2b4ecabb9b2c94d1e3f7d651b8c5ef83e4a5f
f7fd0f3546099e34fdab1ccb3f43f5bc515f2143
refs/heads/master
2020-04-11T04:44:59.932722
2019-01-18T07:51:59
2019-01-18T07:51:59
161,524,392
0
0
null
2018-12-12T17:45:57
2018-12-12T17:45:56
null
UTF-8
Python
false
false
885
py
import eventio from os import path import pkg_resources def test_is_install_folder_a_directory(): dir_ = path.dirname(eventio.__file__) assert path.isdir(dir_) def test_can_open_file(): testfile = 'tests/resources/one_shower.dat' eventio.EventIOFile(testfile) def test_file_is_iterable(): testf...
05329d547998d9406a4a55e93a03a512da6d1f66
494e3fbbdff5cf6edb087f3103ad5f15acbc174f
/company/migrations/0005_employee_checkedin.py
6dd66f7f62dbe154d700daa4addec76dd04d087a
[]
no_license
TalentoUnicamp/my
1209048acdedbb916b8ae8ec80761d09f6ad7754
3d87a33cd282d97dbbbd5f62658f231456f12765
refs/heads/master
2020-03-23T21:12:58.316033
2018-08-14T06:11:36
2018-08-14T06:11:36
142,090,262
11
0
null
2018-08-17T05:13:26
2018-07-24T01:53:23
JavaScript
UTF-8
Python
false
false
394
py
# Generated by Django 2.0.3 on 2018-08-12 02:44 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('company', '0004_company_access_level'), ] operations = [ migrations.AddField( model_name='employee', name='checkedin...
a03f8b20320b2b0cd2a0c8a40c42c197b83f1048
18ad97292b34a679b8dea8a85090541c5bbf6174
/chess.py
0fa35ed4de237177a9e5fefa36517a277692e1e0
[]
no_license
Jyotirm0y/kattis
b941044e39dc36d169450480fc33fd33bd2e0f8e
2b9c1819ba29419bbea3db2e8ad7851155abbb3a
refs/heads/master
2023-05-31T21:11:38.350044
2021-06-12T08:21:47
2021-06-12T08:21:47
null
0
0
null
null
null
null
UTF-8
Python
false
false
3,184
py
n = int(input()) r = 'ABCDEFGH' for _ in range(n): s = input().split() a = r.index(s[0]) b = int(s[1])-1 x = r.index(s[2]) y = int(s[3])-1 m = abs(x-a) n = abs(y-b) if a == x and b == y: print(0,s[0],s[1]) elif m == n: print(1, s[0],s[1], s[2],s[3]) elif (m+n)%2 !...
2d0753b8960fa3c7bb7014d2317bc0555cd17999
fcbe21026e7ae483c535f6eb38ffbfaaa2aa06c2
/.history/main_20210412094009.py
7efdf4db3a5b77a3a63e5eb7f311427f5aca19c3
[]
no_license
robertstrauss/discordAIchatbot
8e4c85920f73d49daeb1394afbd1ce8baffbb97b
8347e6a591d352ace1b8fe4c4629e831763eb0ba
refs/heads/master
2023-04-03T12:55:07.641825
2021-04-13T17:54:57
2021-04-13T17:54:57
357,641,172
0
0
null
null
null
null
UTF-8
Python
false
false
1,858
py
import discord import re import requests import random import time import asyncio import pytorch as torch import pandas as pd client = discord.Client() guildID = 755473404643115170 guild = None channelID = 831188849946394654 talkchannel = None # async def pingean(): # while True: # await asyncio.slee...
7199acf0e62fd850cfe1c8e99807a92710e8e2f2
854d0673d18cf1db557d2b9b27c248dd879ba28a
/test/test1.py
3c51d8306463a0078a64f3dbd5b8dc13fba22485
[]
no_license
Miao1127/code-charpter3
51e141c0e463f1ea63f371a498d967b520f59853
313dae0b53f1f68fb7ce713ac3eab7e1a2d1b001
refs/heads/master
2023-07-15T21:27:22.688910
2021-08-23T01:13:59
2021-08-23T01:13:59
398,937,184
0
0
null
null
null
null
UTF-8
Python
false
false
381
py
# _*_ coding:utf-8 _*_ # 开发人员:103中山分队-苗润龙 # 开发时间:2019/12/1620:50 # 文件名:test1.py # 开发工具:PyCharm # 功能:测试全局变量 import time import sys def show(): global a print(a) a = 3 def s(): global a print(a) a = 5 if __name__ == '__main__': a = 1 show() print(a) s() print(a)
[ "Miao@DESKTOP-AJA95IE" ]
Miao@DESKTOP-AJA95IE
df98aec7cbcf6664ef07942ff574d25f1dc989c7
599913671c29ca3c427514fa6cb22260d1420d35
/st2actions/st2actions/runners/remote_script_runner.py
d0fc84e70bce2ff066dd85ba069a41d4e6435b31
[ "Apache-2.0" ]
permissive
grengojbo/st2
2c9642c157f95b57a95175b04d17de7a312164cf
24956136df165a8b8ac629ba6be1f6de0d77385a
refs/heads/master
2020-12-30T21:42:57.664608
2015-08-20T14:23:56
2015-08-20T14:23:56
39,152,248
0
0
null
2015-07-15T17:58:43
2015-07-15T17:58:42
null
UTF-8
Python
false
false
3,618
py
# Licensed to the StackStorm, Inc ('StackStorm') under one or more # contributor license agreements. See the NOTICE file distributed with # this work for additional information regarding copyright ownership. # The ASF licenses this file to You under the Apache License, Version 2.0 # (the "License"); you may not use th...
b2ea215b35210f9d73283dae43957dc12d943e32
29345337bf86edc938f3b5652702d551bfc3f11a
/python/src/main/python/pyalink/alink/tests/examples/from_docs/test_softmaxpredictstreamop.py
ed44324ed0eac0718b830e65b094dc71dad0a64e
[ "Apache-2.0" ]
permissive
vacaly/Alink
32b71ac4572ae3509d343e3d1ff31a4da2321b6d
edb543ee05260a1dd314b11384d918fa1622d9c1
refs/heads/master
2023-07-21T03:29:07.612507
2023-07-12T12:41:31
2023-07-12T12:41:31
283,079,072
0
0
Apache-2.0
2020-07-28T02:46:14
2020-07-28T02:46:13
null
UTF-8
Python
false
false
953
py
import unittest from pyalink.alink import * import numpy as np import pandas as pd class TestSoftmaxPredictStreamOp(unittest.TestCase): def test_softmaxpredictstreamop(self): df_data = pd.DataFrame([ [2, 1, 1], [3, 2, 1], [4, 3, 2], [2, 4, 1], ...
20d782976fa64be463fcafcdcad085eb498f3c78
3034e86347c71bf7e7af9e5f7aa44ab5ad61e14b
/pweb/day06/queue2.py
1e303bf16b69ae88861efeb393b81111e60f2ba4
[]
no_license
jason12360/AID1803
bda039b82f43d6609aa8028b0d9598f2037c23d5
f0c54a3a2f06881b3523fba7501ab085cceae75d
refs/heads/master
2020-03-17T00:43:42.541761
2018-06-29T10:07:44
2018-06-29T10:07:44
133,127,628
0
0
null
null
null
null
UTF-8
Python
false
false
293
py
from multiprocessing import Process,Queue import time #创建消息队列 q = Queue() def fun1(): time.sleep(1) q.put('我是进程1') def fun2(): time.sleep(2) print('取消息',q.get()) p1 = Process(target = fun1) p2 = Process(target = fun2) p1.start() p2.start() p1.join() p2.join()
3f84cd518baad07c427aacb915704490f4665028
452e376385cf9294c7f416748e353ddbfeb8460c
/migrations/versions/d2d0eb2fe55a_create_info_type_table.py
41952b64c1710a34e5225043c0bb4c6c68964741
[]
no_license
huozhihui/atuiguang
e7576de0acc53998a67669f577cb371f386a001d
7e6db16746e6124cd95a2cf71d063db67a9b0d1f
refs/heads/master
2021-01-20T08:37:50.479023
2017-09-05T14:28:46
2017-09-05T14:28:46
101,567,814
0
0
null
null
null
null
UTF-8
Python
false
false
1,026
py
"""create info_type table Revision ID: d2d0eb2fe55a Revises: 818a0a098c23 Create Date: 2017-09-02 18:54:31.644588 """ from alembic import op import sqlalchemy as sa # revision identifiers, used by Alembic. revision = 'd2d0eb2fe55a' down_revision = '818a0a098c23' branch_labels = None depends_on = None def upgrade(...
0eee740e8053dfaa728e96765f202ca5904ce08d
37c3b81ad127c9e3cc26fa9168fda82460ca9bda
/Baekjoon/boj_2628.py
3860cbf720e66de2d4735521eb108e758f043ee3
[]
no_license
potomatoo/TIL
5d85b69fdaed68966db7cfe2a565b7c64ed3e816
395dc190fa13e5ed036e1e3c7d9e0bc2e1ee4d6c
refs/heads/master
2021-07-08T16:19:40.410097
2021-04-19T02:33:40
2021-04-19T02:33:40
238,872,774
0
0
null
null
null
null
UTF-8
Python
false
false
467
py
w, h = map(int,input().split()) n = int(input()) garo = [] sero = [] for i in range(n): where, idx = map(int,input().split()) if where == 0: garo.append(idx) else: sero.append(idx) garo.append(0) sero.append(0) garo.append(h) sero.append(w) garo.sort() sero.sort() ls1 = [] ls2 = [] for i i...
c76607201a54c4b15b585cebd9ac427bc7e11dd0
af32cdbbf31d52d01753ddfa5e813e851411403b
/tests/job/test_databaseproperties.py
5b4cbb469a7497b64814c7ed06d2148275bafbf3
[ "BSD-3-Clause" ]
permissive
pmrv/pyiron_base
3e72298df7790f4c3b84d78c990b5d7e12e9016b
af1729708a8226575ca2c84f574e7cb046b7f7cd
refs/heads/master
2022-12-25T03:15:09.270651
2020-09-13T13:56:40
2020-09-13T13:56:40
294,116,811
0
0
BSD-3-Clause
2020-09-09T13:10:31
2020-09-09T13:10:31
null
UTF-8
Python
false
false
5,610
py
# coding: utf-8 # Copyright (c) Max-Planck-Institut für Eisenforschung GmbH - Computational Materials Design (CM) Department # Distributed under the terms of "New BSD License", see the LICENSE file. import unittest import datetime import os from pyiron_base.project.generic import Project from pyiron_base.job.core impo...
3fb2cae71bf50676b6228b742a5f2bc1b3d9856b
3012e5a0f34dd54fbac568c70506826973192ce1
/pylib/lines.py
0568e2c4370b658c9fb453b1094d7360c2fd0918
[]
no_license
metatab-packages/civicknowledge.com-osm-demosearch
89999227bda7bae91259c10bd651f220ae35c52f
d4ecb7775662a50413c848c3ae5a901b147ef532
refs/heads/master
2023-05-14T12:39:25.328559
2021-06-08T13:52:39
2021-06-08T13:52:39
334,572,037
0
0
null
null
null
null
UTF-8
Python
false
false
6,999
py
""" """ from itertools import chain from pathlib import Path import fiona # Import first to work around an import bug import geopandas as gpd import numpy as np import pandas as pd import shapely from demosearch import FileCache from demosearch.util import run_mp from shapely.wkt import loads as loads_wkt from tqdm....
1049de780f9f5d1abb00009e1767374fd69fa854
1b5404b8099de74d4e39e0a41b1d04c61defa8d4
/fractals/pythagoras_tree.py
9aaeb7710c9cda5161272fbed91510d7491c7690
[]
no_license
ipeterov/random-stuff
5d07bdcfdcb145d06ed89095f2ad34b70ff0f0bd
dbb38d42331f636919fd149b23783e02ee2c9afb
refs/heads/master
2023-05-14T00:41:51.122251
2023-05-04T12:10:26
2023-05-04T12:10:26
206,028,412
0
0
null
null
null
null
UTF-8
Python
false
false
3,292
py
import math from types import SimpleNamespace import pygame from abstract_drawer import AbstractDrawer SIZE = WIDTH, HEIGHT = 500, 500 class PythagorasTreeDrawer(AbstractDrawer): DEFAULT_PARAMS = { 'angle': 45, 'starting_size': 100, 'max_depth': 2, } PARAMS_SCHEMA = { ...