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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
dbbe06ceccb250198a84188d034663571ac01ebe | d423ac8072d7796ed512a41ee0c4221b0c98325c | /web/raw.py | 62e96e88024a6186cce1802c5c7eb0ac52a40929 | [
"Apache-2.0"
] | permissive | MagiCircles/frgl | fa579e965c451434e85b1bd7b1704869906fce2c | f8da4d6ff688862bfef0902e8315160ae1049e0a | refs/heads/master | 2021-05-29T21:15:33.324305 | 2015-11-01T01:15:10 | 2015-11-01T01:15:10 | 42,368,540 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 903 | py |
# -1 means the value is currently unknown
# -2 means the value differs depending on the card
cards_data = {
'C': {
'stages': 1,
'experiences': [0, 117, 417],
'performances': [60, 132, 200],
'levels': [0, 10, 20],
'max_level_reward': 10,
},
'R': {
'stages': 2,... | [
"db0company@gmail.com"
] | db0company@gmail.com |
e2a001631a36104800fc4d40f2e65499ec59a9f7 | b7546fccec3f417ece54d8fd9da369176f9190a8 | /yt_auth.py | 05ffc67d1740ba122cac09613e557a83a5383596 | [] | no_license | Botmasher/yt-captions-languages | 327f396c6357fb4ba1a50087b192c838f9e145d9 | fa71069fabcfac5e6bfb5aaf9dda469b87c38037 | refs/heads/master | 2020-06-12T14:12:29.992320 | 2019-07-01T20:44:15 | 2019-07-01T20:44:15 | 194,325,010 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,065 | py | # -*- coding: utf-8 -*-
# Instructions for running these code samples locally:
# https://developers.google.com/explorer-help/guides/code_samples#python
import os
import google_auth_oauthlib.flow
import googleapiclient.discovery
import googleapiclient.errors
scopes = ["https://www.googleapis.com/auth/youtube.readonl... | [
"languagejosh@hotmail.com"
] | languagejosh@hotmail.com |
e3c8b16e273d41aa26174d2de74d18df804737f3 | 183e4126b2fdb9c4276a504ff3ace42f4fbcdb16 | /II семестр/Дискретна математика/Лаби/2016-17/Мазан 7109/2/Algorythms.py | 4321fec35960e5e539d712a72179c4177fbdbb32 | [] | no_license | Computer-engineering-FICT/Computer-engineering-FICT | ab625e2ca421af8bcaff74f0d37ac1f7d363f203 | 80b64b43d2254e15338060aa4a6d946e8bd43424 | refs/heads/master | 2023-08-10T08:02:34.873229 | 2019-06-22T22:06:19 | 2019-06-22T22:06:19 | 193,206,403 | 3 | 0 | null | 2023-07-22T09:01:05 | 2019-06-22T07:41:22 | HTML | UTF-8 | Python | false | false | 3,467 | py | from Names import names
import networkx as nx
import pylab as plt
from random import sample,randint
class graphs_gen():
def __init__(self,A,B,relation):
self.relation = relation
self.A = A
self.B = B
self.graph = nx.DiGraph()
def define_graph(self):
self.graph.add_nodes... | [
"mazanyan027@gmail.com"
] | mazanyan027@gmail.com |
df4bd70ae363af51471337895bdf0d0e88de410a | e78154abbb8bacf5afccda9da371684cbeabad36 | /envs/ALPHA-POPEGO/lib/python2.5/site-packages/twisted/web2/dav/method/put.py | 17bbf984ea913e62fbe9dbcba0185cc46d7d0d2f | [
"MIT",
"LicenseRef-scancode-unknown-license-reference",
"BSD-3-Clause"
] | permissive | enterstudio/popego | 1a196fabc374c0f45764e5c74bd7752236424040 | 2d09e793d9d2f297139edb325b8a70ddda9b2705 | refs/heads/master | 2021-04-09T16:39:40.781634 | 2016-10-14T16:53:47 | 2016-10-14T16:53:47 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,519 | py | # -*- test-case-name: twisted.web2.dav.test.test_put -*-
##
# Copyright (c) 2005 Apple Computer, Inc. All rights reserved.
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restrictio... | [
"santisiri@gmail.com"
] | santisiri@gmail.com |
12ff03f8aed23af658ae9feafae2a89b573e0010 | 0ec51a4bf5013e8601d5fa621f6cde88eeb7b4b5 | /CUDA_Python/课程3/solutions/col_sums_solution.py | be380447aa903d7bf52c47c924b00125a632c2dd | [
"MIT"
] | permissive | bobo0810/PytorchNetHub | 6228b0dd69ab2b22b81867c99262a0b1675759a1 | 15312703bc5bf2e1771de1c96402366fa3e727d4 | refs/heads/master | 2023-08-30T14:35:59.369145 | 2023-08-14T03:22:58 | 2023-08-14T03:22:58 | 132,425,167 | 383 | 95 | null | null | null | null | UTF-8 | Python | false | false | 145 | py | @cuda.jit
def col_sums(a, sums, ds):
idx = cuda.grid(1)
sum = 0.0
for i in range(ds):
sum += a[i][idx]
sums[idx] = sum
| [
"1055271769@qq.com"
] | 1055271769@qq.com |
91ab54c692b193ef15b70f550d25cc8e939e0c69 | f68cd225b050d11616ad9542dda60288f6eeccff | /testscripts/RDKB/component/CMAgent/TS_CMAGENT_GetParamValues.py | 1f450f59ff0d7bd463c9d4fb7aac9399f70ba71d | [
"Apache-2.0"
] | permissive | cablelabs/tools-tdkb | 18fb98fadcd169fa9000db8865285fbf6ff8dc9d | 1fd5af0f6b23ce6614a4cfcbbaec4dde430fad69 | refs/heads/master | 2020-03-28T03:06:50.595160 | 2018-09-04T11:11:00 | 2018-09-05T00:24:38 | 147,621,410 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,681 | py | ##########################################################################
# If not stated otherwise in this file or this component's Licenses.txt
# file the following copyright and licenses apply:
#
# Copyright 2016 RDK Management
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use th... | [
"jim.lawton@accenture.com"
] | jim.lawton@accenture.com |
d1c71a3a09bf1ab60e9939f0fc2e6fa3d0844338 | 10d98fecb882d4c84595364f715f4e8b8309a66f | /rouge/test_util.py | 041dfba5fa55d03239266f5a3c3157d65409c920 | [
"Apache-2.0",
"CC-BY-4.0"
] | permissive | afcarl/google-research | 51c7b70d176c0d70a5ee31ea1d87590f3d6c6f42 | 320a49f768cea27200044c0d12f394aa6c795feb | refs/heads/master | 2021-12-02T18:36:03.760434 | 2021-09-30T20:59:01 | 2021-09-30T21:07:02 | 156,725,548 | 1 | 0 | Apache-2.0 | 2018-11-08T15:13:53 | 2018-11-08T15:13:52 | null | UTF-8 | Python | false | false | 1,310 | py | # coding=utf-8
# Copyright 2021 The Google Research Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicab... | [
"copybara-worker@google.com"
] | copybara-worker@google.com |
2825a5aac7cc59f516e43a1498d6e501bcb4853d | e0fc7493f4339145792f54bcd7124acea500ca45 | /cpc/ir/Case.py | 9e62727bce0a942a4cb172aec455d5c2ebb9d7ae | [
"BSD-3-Clause"
] | permissive | U-Ar/Cpresto | d52d99e8d44ed01c87c8911614d744cae695d6aa | f723458fb237c9e3e8bc8a6afdf7c81858a65363 | refs/heads/main | 2023-05-14T15:28:38.449783 | 2021-06-06T15:07:14 | 2021-06-06T15:07:14 | 364,445,894 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 315 | py | from .IRDumpable import IRDumpable
class Case(IRDumpable):
def __init__(self,value,label):
self._value = value
self._label = label
def dump(self, dumper):
dumper.print_class(self)
dumper.print_member("value",self._value)
dumper.print_member("label",self._label) | [
"yuma.arakawa82128awakara.amuy@gmail.com"
] | yuma.arakawa82128awakara.amuy@gmail.com |
4f1a576b5379b63b33bfb71ad1943f8617ab700a | 5eaef75ca4638702e79863fff688394d8afdd7bc | /testRunner-res.py | 4b1bbc797c93a0c1b3d5a3daf1903873be7efbe3 | [
"MIT"
] | permissive | tejastank/domainThing | 34045004332947e8ca881b0d0814d1118033b76a | 28e1d3f6fc23d88a0487fb85a102b80c6a135117 | refs/heads/master | 2021-05-30T15:39:39.501489 | 2016-03-17T23:26:42 | 2016-03-17T23:26:42 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 795 | py | from domainParser import domainReader
from domainResolver2 import domainResolver
from domainConsumer import domainConsumer
import logging
from multiprocessing import Process, current_process, active_children
if __name__ == "__main__":
logger = logging.getLogger()
logger.addHandler(logging.StreamHandler())
... | [
"chrisagallo@gmail.com"
] | chrisagallo@gmail.com |
9a975581de93e01be4828e18a85b4e49b68404c0 | f0d713996eb095bcdc701f3fab0a8110b8541cbb | /b36bBpsnzyDbd4mzF_0.py | 370edaffbb2d97407a6bf21f3389a97d8d057256 | [] | 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 | 582 | py | """
Create a function that calculates the chance of being an imposter. The formula
for the chances of being an imposter is `100 × (i / p)` where `i` is the
imposter count and `p` is the player count. Make sure to round the value to
the nearest integer and return the value as a percentage.
### Examples
imposter... | [
"daniel.reich@danielreichs-MacBook-Pro.local"
] | daniel.reich@danielreichs-MacBook-Pro.local |
df939de128f6f9c89f7761cd09c1e121e032004c | 37e47457fa95ef39ce18d618c6150bdf3a287161 | /python/mono_stack/s42_dp.py | d5089c39aa7a84d5c89d57c71d0d7572b51e4f6d | [] | no_license | TQCAI/Algorithm | 7e9c05055b02748c92e134861c78a74857346465 | 82a6cfdee5f02d56b884cb65872c3d820146ba7b | refs/heads/master | 2023-03-19T08:42:00.423944 | 2021-03-11T04:10:12 | 2021-03-11T04:10:12 | 305,140,106 | 5 | 1 | null | null | null | null | UTF-8 | Python | false | false | 643 | py | from typing import List
class Solution:
def trap(self, height: List[int]) -> int:
sum = 0
n = len(height)
max_left = [0] * n
max_right = [0] * n
for i in range(1, n - 1):
max_left[i] = max(max_left[i - 1], height[i - 1])
for i in reversed(range(1, n - 1)... | [
"1468632627@qq.com"
] | 1468632627@qq.com |
7b1c9612fb7a17754a7b6b29764c37752e059f84 | 8fe4f275cfc1e4f81addcde950c7d50582ddab6b | /SellerUI/migrations/0006_vehicle_bought.py | 404a56d72ae46afeb490603db671f0b031ad4863 | [] | no_license | strange-hawk/ResaleValuePrediction | 5d09b075fcd8367198f02f69efa0402b435b3531 | c0e6cec56e0c3bcf5dcb7e3b46a7ee9152893382 | refs/heads/master | 2022-11-11T04:50:23.610331 | 2020-06-26T17:00:35 | 2020-06-26T17:00:35 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 389 | py | # Generated by Django 3.0.5 on 2020-06-26 14:53
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('SellerUI', '0005_auto_20200626_1807'),
]
operations = [
migrations.AddField(
model_name='vehicle',
name='bought',
... | [
"tanmay.ambadkar@gmail.com"
] | tanmay.ambadkar@gmail.com |
b83fe49dd4b24404a9c5d47f5d730ca86340f1e2 | ef701a68d9cd1f1f2e3699cc0b98b138eeb11934 | /job.py | f335dbe5a778b9003eb95d2d69d87ff2dc514f8d | [] | no_license | yangxuserene/BBSimulator | b920344bc8abb78835a4ff5f5a17d516bbb241bd | 684822d275bb4d180016a9e1a4f4673f7d3755b3 | refs/heads/master | 2021-01-17T12:30:47.256223 | 2016-02-23T19:54:02 | 2016-02-23T19:54:02 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,068 | py | #!/usr/bin/env python
from enum import Enum
import logging
class BBJobTimeStamp(object):
"""timing statistics"""
def __init__(self, submit):
super(BBJobTimeStamp, self).__init__()
self.submit = float(submit) # when job goes into input queue
self.start_in = 0.0
self.finish_in ... | [
"littlepretty881203@gmail.com"
] | littlepretty881203@gmail.com |
03ce106bae9066ec66a3695dd6a7d4c52c838338 | d4d7c65bd4a4283b60caf1d8cea69a4aec9e594d | /04. Mid Exam Tasks/03. Froggy Squad.py | 0af494f78e673e0361b1e6c04525249814f6f788 | [] | no_license | tony-andreev94/Python-Fundamentals | db806d05168c1bb61763e5b3d27f495f045e7667 | 32032d37e3a8f70e156db6ccad2d9f25aac62c23 | refs/heads/master | 2021-08-07T12:32:27.624459 | 2020-12-24T12:47:05 | 2020-12-24T12:47:05 | 233,568,246 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,521 | py | # Create a program that helps you keep track of the frogs that are on the riverside.
# Because you are an extreme animal lover, you also name them.
# You will receive the names of the frogs that are already on the riverside on a single line,
# separated by a single space in the following format:
# "{frog1} {frog2} {fro... | [
"tony.andreev94@outlook.com"
] | tony.andreev94@outlook.com |
f41df66c6e1adf697bf2f3d6c03b719db4aa44b3 | 1f41b828fb652795482cdeaac1a877e2f19c252a | /maya_menus/_MAINMENU_PMC_Rigging/19.Selection/08.Select Destination Connection( ctls, attrs ).py | f8de72daebe0d35b572f115cc222baf4738737b2 | [] | no_license | jonntd/mayadev-1 | e315efe582ea433dcf18d7f1e900920f5590b293 | f76aeecb592df766d05a4e10fa2c2496f0310ca4 | refs/heads/master | 2021-05-02T07:16:17.941007 | 2018-02-05T03:55:12 | 2018-02-05T03:55:12 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 260 | py | import pymel.core
sels = pymel.core.ls( sl=1 )
selAttrs = pymel.core.channelBox( 'mainChannelBox', q=1, sma=1 )
targets = []
for sel in sels:
for attr in selAttrs:
targets += sel.attr( attr ).listConnections( s=0, d=1 )
pymel.core.select( targets ) | [
"kimsung9k@naver.com"
] | kimsung9k@naver.com |
55f8bb4cc636189aed727dbdcd2d0918046f96db | 2d0bada349646b801a69c542407279cc7bc25013 | /src/vai_quantizer/xnnc4xir/xnnc/proto/tf_pb2/reader_base_pb2.py | 1578860ab1cd6daaf243152a58058981a8251456 | [
"BSD-3-Clause",
"LicenseRef-scancode-generic-cla",
"BSD-3-Clause-Open-MPI",
"LicenseRef-scancode-free-unknown",
"Libtool-exception",
"GCC-exception-3.1",
"LicenseRef-scancode-mit-old-style",
"OFL-1.1",
"JSON",
"LGPL-2.1-only",
"LGPL-2.0-or-later",
"ICU",
"LicenseRef-scancode-other-permissive... | permissive | Xilinx/Vitis-AI | 31e664f7adff0958bb7d149883ab9c231efb3541 | f74ddc6ed086ba949b791626638717e21505dba2 | refs/heads/master | 2023-08-31T02:44:51.029166 | 2023-07-27T06:50:28 | 2023-07-27T06:50:28 | 215,649,623 | 1,283 | 683 | Apache-2.0 | 2023-08-17T09:24:55 | 2019-10-16T21:41:54 | Python | UTF-8 | Python | false | false | 5,019 | py | """
Copyright 2019 Xilinx Inc.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, softw... | [
"do-not-reply@gitenterprise.xilinx.com"
] | do-not-reply@gitenterprise.xilinx.com |
c17d73e8b28549a190e9b51caacf123d8b11d9ec | 24fe1f54fee3a3df952ca26cce839cc18124357a | /servicegraph/lib/python2.7/site-packages/acimodel-4.0_3d-py2.7.egg/cobra/modelimpl/isis/db.py | dfa245b2a4813380fba88996e099bc64cdb6034d | [] | no_license | aperiyed/servicegraph-cloudcenter | 4b8dc9e776f6814cf07fe966fbd4a3481d0f45ff | 9eb7975f2f6835e1c0528563a771526896306392 | refs/heads/master | 2023-05-10T17:27:18.022381 | 2020-01-20T09:18:28 | 2020-01-20T09:18:28 | 235,065,676 | 0 | 0 | null | 2023-05-01T21:19:14 | 2020-01-20T09:36:37 | Python | UTF-8 | Python | false | false | 5,562 | py | # coding=UTF-8
# **********************************************************************
# Copyright (c) 2013-2019 Cisco Systems, Inc. All rights reserved
# written by zen warriors, do not modify!
# **********************************************************************
from cobra.mit.meta import ClassMeta
from cobra.m... | [
"rrishike@cisco.com"
] | rrishike@cisco.com |
ff6b877cf1ff67b550b56f6ef180a404c3b60ca2 | 163bbb4e0920dedd5941e3edfb2d8706ba75627d | /Code/CodeRecords/2304/60775/297440.py | 2a5c35b05a3f2272ea4b464e9c0bc37c673d30cf | [] | no_license | AdamZhouSE/pythonHomework | a25c120b03a158d60aaa9fdc5fb203b1bb377a19 | ffc5606817a666aa6241cfab27364326f5c066ff | refs/heads/master | 2022-11-24T08:05:22.122011 | 2020-07-28T16:21:24 | 2020-07-28T16:21:24 | 259,576,640 | 2 | 1 | null | null | null | null | UTF-8 | Python | false | false | 2,110 | py | in1 = input().split(' ')
num_v = int(in1[0])
root = int(in1[1])
tree = [[] for i in range(100)]
for i in range(num_v):
in2 = input().split(' ')
tree[int(in2[0])] = [int(in2[1]),int(in2[2])]
#广度优先遍历
stack = []
stack.append(root)
this_layer_nodes = 1
layer = 1
while stack != []:
next_layer_nodes = 0
pr... | [
"1069583789@qq.com"
] | 1069583789@qq.com |
6db40a61a9d2f970b2620229d396218da4bbba9a | e8cc093ce857f65882e25f4bfae94a395ffc2fe5 | /PESA-BACK/remitapi/utils.py | 15b7d841ed5d3fec3b88484e78393b7201794401 | [] | no_license | mandelashaban593/Chatting-App | f6d0f7ac3785da690f52a7c1427353956699af4c | 0e6e5d9edb0a4f0c91a40391ae5916549e87ec7b | refs/heads/master | 2021-01-22T06:01:42.649403 | 2017-03-20T08:08:55 | 2017-03-20T08:08:55 | 92,512,558 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,063 | py | from remitapi.tasks import send_email, send_sms
from django.template.loader import render_to_string
from django.utils.html import strip_tags
from django.conf import settings
from django.template import RequestContext
import sys
from datetime import datetime
def mailer(request, subject, template, content, to, sender=F... | [
"mandelashaban593@gmail.com"
] | mandelashaban593@gmail.com |
5f562dcaa59d40c74a34cfe55ed08f30174a169d | 49185bd5cf7e2f5190ce22b5189a09fe1ab6bb0f | /Proper/proper/prop_circular_obscuration.py | 626faec83727f75711d6b3eb83c90439547c57bc | [
"MIT"
] | permissive | RupertDodkins/MEDIS | c3f55d8adb6a8c4120593ba6552c9dfe3784d4e2 | bdb1f00fb93506da2a1f251bc6780e70e97a16c5 | refs/heads/master | 2021-07-05T20:06:44.162517 | 2019-09-05T22:16:12 | 2019-09-05T22:16:12 | 160,850,558 | 2 | 2 | null | null | null | null | UTF-8 | Python | false | false | 1,649 | py | # Copyright 2016, 2017 California Institute of Technology
# Users must agree to abide by the restrictions listed in the
# file "LegalStuff.txt" in the PROPER library directory.
#
# PROPER developed at Jet Propulsion Laboratory/California Inst. Technology
# Original IDL version by John Krist
# Python transla... | [
"rupertdodkins@gmail.com"
] | rupertdodkins@gmail.com |
c255da1783f7d52da5f07fbf950c77042766e954 | 0f6a6edcfbfe5669a78748422c7fc0343d532f42 | /src/events/adapters/celery.py | 7284036cbe2d0d304bec18de7ae5555363a8f92d | [
"MIT"
] | permissive | jonatasoli/the-eye | f734f814d0cf12ee157f1e69f95f6e2bf73a7a83 | 0a11334bc24c99dcb7158238bc2ae63a26dc63b1 | refs/heads/main | 2023-08-22T06:55:27.893110 | 2021-10-09T14:35:27 | 2021-10-09T14:35:27 | 415,181,637 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 643 | py | import celery
from loguru import logger
from flask import Flask
celery_obj = celery.Celery(__name__)
def init_app(app: Flask):
logger.info(app.config['CELERY_BROKER_URL'])
logger.info(app.config['CELERY_RESULT_BACKEND'])
celery_obj.conf.broker_url = app.config['CELERY_BROKER_URL']
celery_obj.conf.res... | [
"contato@jonatasoliveira.me"
] | contato@jonatasoliveira.me |
087414c9fb5074b4342290c052f598198db0bc75 | 15f321878face2af9317363c5f6de1e5ddd9b749 | /solutions_python/Problem_199/2460.py | bb3b758e7f02863f07f01b7e76c0a3ec1bdca277 | [] | 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 | 511 | py | import numpy as np
T = int(raw_input())
def solve():
S = len(s)
# print s, K, S
cnt = 0
for ii in xrange(S-K+1):
if s[ii] == '-':
cnt+=1
for jj in xrange(K):
s[ii+jj] = '+' if s[ii+jj] == '-' else '-'
if s.count('-') > 0:
return 'IMP... | [
"miliar1732@gmail.com"
] | miliar1732@gmail.com |
4d1740d100a8a38bb1f5f3a400475d62046b4555 | afbaa5685bf737ec7d16fee2bab54ae13caf96f9 | /geekbang/data_analysis/ch04/numpy3.py | 7556b5147749407b51b42d1bcc8a0f52d3aa9d31 | [] | no_license | ykdsg/myPython | 9dcc9afe6f595e51b72257875d66ada1ba04bba6 | 77d2eaa2acb172664b632cc2720cef62dff8f235 | refs/heads/master | 2023-06-10T20:11:08.061075 | 2023-06-03T11:39:53 | 2023-06-03T11:39:53 | 10,655,956 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 354 | py | import numpy as np
a = np.array([[1, 2, 3], [4, 5, 6], [7, 8, 9]])
print(np.amin(a))
# 延着 axis=0 轴的最小值
print(np.amin(a, 0))
print(np.amin(a, 1))
print(np.amax(a))
print(np.amax(a, 0))
print(np.amax(a, 1))
x = np.array([[0, 1], [2, 3]])
print(np.sum(x, axis=0))
print(np.sum(x, axis=1))
print(np.amin(x, axis=0))
print(... | [
"17173as@163.com"
] | 17173as@163.com |
a30322bdb05ecc03bd4eae8d604f413144cb093d | 0aea9408dceec38dfa4d52be13256cd84367c15f | /my_blog/main/__init__.py | 2c91492717aac4766ba8b72f7ad0e954e8ee4d4c | [] | no_license | ezirmusitua/my-blog-with-flask | 54d11f4cb0326be5a2dbbebf078282dd68b43e44 | d7c2bda06d12359261fe25a24527138f437cef41 | refs/heads/master | 2021-01-16T21:05:34.267515 | 2016-06-21T11:09:17 | 2016-06-21T11:09:17 | 61,627,467 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 134 | py | #!/usr/bin/env python
# -*- coding:utf-8 -*-
from flask import Blueprint
main = Blueprint('main', __name__)
from . import views
| [
"jferroal@gmail.com"
] | jferroal@gmail.com |
8c5ce3513996a713016395c9da9fc122a5f8709a | 39e1320c74bcf0bbebb855645b4f538e9ef361f4 | /src/genui/accounts/urls.py | 6a3bd9d8c8926d8932b1dba59f7fc2685aaf3b8f | [
"MIT"
] | permissive | Tontolda/genui | 4c684e08e78b848e5afa7e4333bbea46c30d9d51 | c5b7da7c5a99fc16d34878e2170145ac7c8e31c4 | refs/heads/master | 2023-04-14T12:57:31.774323 | 2021-01-29T08:01:30 | 2021-01-29T08:01:30 | 344,443,814 | 0 | 0 | NOASSERTION | 2021-04-24T14:56:35 | 2021-03-04T11:00:54 | null | UTF-8 | Python | false | false | 657 | py | """
urls
Created by: Martin Sicho
On: 4/30/20, 7:59 PM
"""
from django.urls import path, include, re_path
from django.contrib import admin
from allauth.account.views import ConfirmEmailView
urlpatterns = []
urlpatterns += [
path('admin/', admin.site.urls),
path('accounts/', include('allauth.urls')),
re_p... | [
"sicho.martin@gmail.com"
] | sicho.martin@gmail.com |
4a4363b17be5d1d57768b191fe9a685a4a95b7a5 | c9ddbdb5678ba6e1c5c7e64adf2802ca16df778c | /cases/pa3/benchmarks/stdlib-464.py | 6fd0b1b2c131801d99e2804b1f0a3ef65bd17f03 | [] | no_license | Virtlink/ccbench-chocopy | c3f7f6af6349aff6503196f727ef89f210a1eac8 | c7efae43bf32696ee2b2ee781bdfe4f7730dec3f | refs/heads/main | 2023-04-07T15:07:12.464038 | 2022-02-03T15:42:39 | 2022-02-03T15:42:39 | 451,969,776 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,611 | py | # ChocoPy library functions
def int_to_str(x: int) -> str:
digits:[str] = None
result:str = ""
# Set-up digit mapping
digits = ["0", "1", "2", "3", "4", "5", "6", "7", "8", "9"]
# Write sign if necessary
if x < 0:
result = "-"
x = -x
# Write digits using a recursive call
... | [
"647530+Virtlink@users.noreply.github.com"
] | 647530+Virtlink@users.noreply.github.com |
b55369c3e074890c1d761da477257d3372efcd96 | d2e029233e08ea2b7f806728fb6fdb4313992d1d | /Python Fundamentals/for loop.py | 303b1615818d69f5568318b74b3521dc1fecb333 | [] | no_license | pvr30/Python-Tutorial | f0ccc6c6af2346afc656e5f1f98bae69a58bda6d | 3c4b968d0e0efbf454fbf9a9f98cd630a288b2d9 | refs/heads/master | 2023-06-02T10:08:50.891627 | 2021-06-21T16:36:11 | 2021-06-21T16:36:11 | 378,997,069 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 613 | py | # for loop
for index in range(10):
print(index)
print("\n")
for index in range(5,10):
print(index)
print("\n")
for i in range(1,20,2):
print(i) # this will print number between 1 to 20 with difference of 2
# Print list.
name = ["Harsh","Sanjay","Sahil","Manthan"]
for index in name:
print(index)
# P... | [
"vishalparmar6958@gmail.com"
] | vishalparmar6958@gmail.com |
3cb38ba06488f204e037b03a48de04afff964cc6 | ddefb1ad0ba5939b66e3f5e8fae5fb8a88f03d4a | /四级/四级.py | 56a7d411d403c8ba85fa9f1d76dcb5e3d96676c2 | [] | no_license | github3332422/case | 45ea6a8f7528affa9b724bb31088c8c8c9f0cdf2 | fb86da7f94c8ce24f142e1d34d2cec1f6e21a81f | refs/heads/master | 2020-05-19T13:28:37.379740 | 2019-05-05T14:15:49 | 2019-05-05T14:15:49 | 185,039,295 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,095 | py | #!/usr/bin/python3
# -*- coding:utf-8 -*-
# @Time:2018/8/24 9:37
# @Author: wardseptember
# @File: CountHighFrequencyWords.py
import re
excludes = ['the', 'of', 'to', 'and', 'in', 'a', 'is', 'were', 'was', 'you',
'I', 'he', 'his', 'there', 'those', 'she', 'her', 'their',
'that', '[a]', '[b]', '... | [
"mail.zhangqing@gmail.com"
] | mail.zhangqing@gmail.com |
dec8f4a34c5465e586dbdbcddfbb3d2c85cc27bc | 8f81a0ff4a5bef52bdc23decfdd21183040451f1 | /docs/conf.py | e411946184148cfbcbb42fbc600b02373eb15ba1 | [
"MIT"
] | permissive | shimw6828/sramongo | 22faad838376a2b264cb003c937522b72b67d6d0 | 7b73a2a71c9c12160da7d0aaa1537a615a356136 | refs/heads/master | 2022-11-14T18:33:17.122167 | 2020-07-02T19:42:09 | 2020-07-02T19:42:09 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,163 | py | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
#
# sramongo documentation build configuration file, created by
# sphinx-quickstart on Thu Jan 5 14:49:04 2017.
#
# This file is execfile()d with the current directory set to its
# containing dir.
#
# Note that not all possible configuration values are present in this
# a... | [
"justin.m.fear@gmail.com"
] | justin.m.fear@gmail.com |
15ef14fad6965eb4f3742e852d29527029f1f162 | 09df68c721f724bdfa1d00f18d5ee6fffba548df | /NK_25.py | f53bf49e6d6c9a353293f13fe6d37c671183f4ed | [] | no_license | NeilWangziyu/JZOffer | c8cde80cf54545244ebeb3a9fc88d5ac6b832622 | ce29ea836bd20841d69972180273e4d4ec11514d | refs/heads/master | 2020-04-23T06:19:48.434829 | 2019-09-25T12:35:38 | 2019-09-25T12:35:38 | 170,969,684 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 592 | py | n,m = list(map(int,input().split()))
def getChildCount(pre,mx):
ans = 1
p = 10
while pre * p <= mx:
if pre * p + p - 1 <= mx:
ans += p
else:
ans += mx - pre * p + 1
p *= 10
return ans
def find(m,mx):
ans = 1
while m != 0:
v = getChildCoun... | [
"17210720158@fudan.edu.cn"
] | 17210720158@fudan.edu.cn |
73c1a9a4086a951478d1b79d38eca31ad7308602 | 84046429e40890d1c0e1064726db0cf359dbadcf | /django_git_deploy/__init__.py | e8400d0c61ee787ebe7d4c3f9c382fed2532bc11 | [] | no_license | joakim-hove/django-git-deploy | 8cb346ccff632209df8a5d5fcb69eb6b1b7d6191 | 6413fa7d1b71258a2f176b1630dbc4ac602bbb49 | refs/heads/master | 2022-06-07T05:42:53.915611 | 2022-05-23T21:32:59 | 2022-05-23T21:32:59 | 183,873,411 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,858 | py | import sys
import os
import os.path
import subprocess
import shutil
import time
import yaml
import fnmatch
from contextlib import contextmanager
@contextmanager
def env_context(env):
env0 = os.environ.copy()
for key,value in env.items():
if value is None:
if key in os.environ:
... | [
"joakim.hove@gmail.com"
] | joakim.hove@gmail.com |
4aeedb82b2fb9519b3d200ad0e488617b17fae76 | b194dbc7889e8175993a76f2d2f65a4b81c5d725 | /statistics_hypothesis_testing/18_one_sided_p_value.py | 1b94a09124221130a1bc99028b8c1cb0ed6514c0 | [] | no_license | rahulsaini/oreilly_math_fundamentals_data_science | f96d40f5684c7b1cd993993d82931694afea6976 | 888326dfdea37f5a9b336d37e127a72ae4512a5a | refs/heads/main | 2023-05-18T22:32:32.928472 | 2021-06-08T13:07:22 | 2021-06-08T13:07:22 | 372,832,069 | 1 | 0 | null | 2021-06-01T13:02:53 | 2021-06-01T13:02:52 | null | UTF-8 | Python | false | false | 197 | py | from scipy.stats import norm
# Cold has 18 day mean recovery, 1.5 std dev
mean = 18
std_dev = 1.5
# Probability of 16 or less days
x = norm.cdf(16, mean, std_dev)
print(x) # 0.09121121972586788
| [
"thomasnield@live.com"
] | thomasnield@live.com |
28643ca7f0873fb86a9b6ce8a36119c0b6719ae3 | f1600240f3bbadfa8f190c165bd40b0f74110652 | /model/core/XML_CNN.py | 77d8c627d999b273d9fe1bfd6474da3313acf7df | [] | no_license | shubhampachori12110095/XMTC | b45801e143710e97ad8098ee028b4c44b22cb110 | b93a8a78c7799461b4853006f5cd7a0fc4fcdc67 | refs/heads/master | 2020-04-22T23:26:19.869742 | 2018-04-29T01:56:55 | 2018-04-29T01:56:55 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,965 | py | '''
Created on Jan, 2018
@author: FrancesZhou
'''
from __future__ import absolute_import
import numpy as np
import tensorflow as tf
class XML_CNN(object):
def __init__(self, max_seq_len, word_embedding, filter_sizes, label_output_dim, hidden_dim, args):
self.max_seq_len = max_seq_len
self.word_e... | [
"zhouxian@sjtu.edu.cn"
] | zhouxian@sjtu.edu.cn |
96df624ea6bd582ebb0abe1224a3de5593c6665c | 393c8e9d26f89c9b4f1f24a160970dee437a36db | /shortener/forms.py | 262f395e21bc7cd33d5826e02a21863f9680c29b | [] | no_license | victorsemenov1980/Shorten-URL-Django | eb12b04573e7cd562e46510afb24062e0383eb39 | 5a854d8e061ea88c5b7abe992d6414dea1e06120 | refs/heads/master | 2022-11-05T06:52:24.551215 | 2020-06-17T11:13:34 | 2020-06-17T11:13:34 | 272,881,388 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 323 | py | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Created on Wed Jun 17 00:10:37 2020
@author: user
"""
from django import forms
from .models import url
class UrlForm(forms.Form):
url = forms.URLField(label='URL',)
hash_ = forms.CharField(label='Hash value - optional', max_length=15,required=False,)
... | [
"vs1378009@icloud.com"
] | vs1378009@icloud.com |
b5c607c76cf485cef3717ca12fb01cacd49003ca | c78ce4f66cc964c230ad60fbf2ced6b4811eab89 | /0x04-python-more_data_structures/8-simple_delete.py | 80e9e4f0e0199a69a96ccc4a5f11e897b5024a38 | [] | no_license | jebichii/holbertonschool-higher_level_programming-1 | 89026557909851dd775ae355f036db89ebd9adb9 | 741953aa479af90e8eac6f1315415eff4a20224f | refs/heads/master | 2023-03-15T14:58:27.062528 | 2020-06-11T07:21:23 | 2020-06-11T07:21:23 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 270 | py | #!/usr/bin/python3
def simple_delete(a_dictionary, key=""):
""" Delete a dictionary entry
"""
if a_dictionary is not None:
try:
del a_dictionary[key]
except KeyError:
pass
return a_dictionary
return None
| [
"pdeyoreo@gmail.com"
] | pdeyoreo@gmail.com |
e0e4a5522cfe5345bb65f2fdec29cfc93476dd42 | 3c19870b8e937e5e360ad3cb97453e7e0d0e755f | /smartphoniker_wiki/urls.py | 35b952496d8a0d687a254508c0fce7ab94d72c5a | [] | no_license | M0r13n/wiki | 37862d63f52565efc692c41cc762700de686b236 | 9b263771bb4554c67e52c07b38a845f53d6e97b7 | refs/heads/master | 2022-11-15T22:51:42.615490 | 2020-07-11T09:35:51 | 2020-07-11T09:35:51 | 278,831,073 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,240 | py | from django.conf import settings
from django.contrib import admin
from django.contrib.staticfiles.urls import staticfiles_urlpatterns
from django.http.response import HttpResponse
from django.urls import include
from django.urls import re_path
from django.views.static import serve as static_serve
admin.autodiscover()
... | [
"31622033+M0r13n@users.noreply.github.com"
] | 31622033+M0r13n@users.noreply.github.com |
10e66a88c03e25b636ca4c2dfb9e251d60931935 | 8ccbadcfaebb9148b60978fc89290291625c14ec | /resolwe/storage/tests/test_views.py | 3a61280c490fa45e4e5ce80f30f6490d8fb66848 | [
"Apache-2.0"
] | permissive | romunov/resolwe | f7e426c5965917045e23608c6c52a44b78d735c9 | 11a06a9d741dcc999253246919a0abc12127fd2a | refs/heads/master | 2021-07-11T16:07:17.015683 | 2021-02-21T18:33:07 | 2021-02-25T13:49:02 | 229,769,285 | 0 | 0 | Apache-2.0 | 2019-12-23T14:36:02 | 2019-12-23T14:36:01 | null | UTF-8 | Python | false | false | 1,265 | py | """Test resolwe.storage.views."""
import json
from unittest.mock import MagicMock, patch
from django.test import TestCase
from rest_framework import status
from resolwe.storage.views import UriResolverView
class UriResolverViewTest(TestCase):
"""Test UriResolverView."""
@patch("resolwe.storage.views.DataB... | [
"zmrzlikar.jure@gmail.com"
] | zmrzlikar.jure@gmail.com |
b0e870438ce45f557046f6ba32280a0ed8293072 | bee9ab30f3230831030a74ecc4698d951011c0d2 | /scripts/cnocr_predict.py | ab3b94ccf9178faec1c4bb57b4e74e16cd0bae31 | [
"NCSA",
"Zlib",
"Intel",
"LicenseRef-scancode-unknown-license-reference",
"MIT",
"BSD-2-Clause-Views",
"BSD-3-Clause",
"LicenseRef-scancode-generic-cla",
"BSL-1.0",
"Apache-2.0",
"BSD-2-Clause"
] | permissive | DCMMC/cnocr | 2493f5f175cc4847cd75783eb2922a9c2a4ca789 | ea66f8e87c155ff1959fdc1c3e526acd0dac8c74 | refs/heads/master | 2022-04-24T15:27:14.393242 | 2020-04-25T13:28:27 | 2020-04-25T13:28:27 | 258,252,551 | 0 | 0 | Apache-2.0 | 2020-04-23T15:43:07 | 2020-04-23T15:43:06 | null | UTF-8 | Python | false | false | 1,963 | py | # coding: utf-8
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"... | [
"breezedeus@163.com"
] | breezedeus@163.com |
5d19425b9f79dca344d62f5713da2454035970cf | a1bffcd8854e1843e56bb812d4d83b3161a5211e | /tests/unit/module_utils/common/validation/test_check_type_bool.py | 193622d5bc7dbf0eb681bea33c6c8f96045faacc | [] | no_license | goneri/ansible.community | 1a71f9d98c164b77f8ed2ed7f558b4963005ff8f | f26f612dd0a3154050d90b51a75502018c95f6e4 | refs/heads/master | 2020-12-29T07:47:35.353515 | 2020-01-22T17:43:18 | 2020-01-22T17:43:18 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,476 | py | # -*- coding: utf-8 -*-
# Copyright (c) 2019 Ansible Project
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
from __future__ import absolute_import, division, print_function
__metaclass__ = type
import pytest
from ansible_collections.ansible.community.plugins.module_utils... | [
"ansible_migration@example.com"
] | ansible_migration@example.com |
b9eb17b596550fa1751c638e5d554839479d80dd | 46279163a543cd8820bdc38133404d79e787c5d2 | /test/distributed/_pipeline/sync/skip/test_stash_pop.py | 7a5b16a39cff59a886e16432f0db67c0bc9af3fa | [
"BSD-2-Clause",
"BSD-3-Clause",
"LicenseRef-scancode-generic-cla",
"BSL-1.0",
"Apache-2.0"
] | permissive | erwincoumans/pytorch | 31738b65e7b998bfdc28d0e8afa7dadeeda81a08 | ae9f39eb580c4d92157236d64548b055f71cf14b | refs/heads/master | 2023-01-23T10:27:33.628897 | 2020-12-06T01:22:00 | 2020-12-06T01:23:40 | 318,930,000 | 5 | 1 | NOASSERTION | 2020-12-06T01:58:57 | 2020-12-06T01:58:56 | null | UTF-8 | Python | false | false | 3,050 | py | # Copyright 2019 Kakao Brain
#
# Copyright (c) Facebook, Inc. and its affiliates. All rights reserved.
#
# This source code is licensed under the BSD license found in the
# LICENSE file in the root directory of this source tree.
import pytest
import torch
from torch import nn
from torch.distributed._pipeline.sync.skip... | [
"facebook-github-bot@users.noreply.github.com"
] | facebook-github-bot@users.noreply.github.com |
cc7446671e306d6a6e487bb6ec3c82bb71b00587 | b7125b27e564d2cc80a2ce8d0a6f934aa22c8445 | /.history/display_board_20201103142917.py | 8c63f44d74fa4ec5b0c7cf268870c0b69d958f52 | [] | no_license | JensVL96/Puzzle-solver-for-fun | 4c15dcd570c3705b7ac555efb56b52913e81083c | 6d8a4378a480372213a596a336a4deca727a00fc | refs/heads/master | 2021-07-15T05:19:42.185495 | 2020-11-08T13:59:49 | 2020-11-08T13:59:49 | 224,855,888 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,433 | py | from config import *
import pygame as pg
class Display_board():
def __init__(self, screen):
self.screen = screen
self.font_num = pg.font.SysFont("comicsans", NUMBER_SIZE)
self.font_cdt = pg.font.SysFont("comicsans", CANDIDATE_SIZE)
def draw_val(self, val, x, y):
text1 = self.... | [
"jle040@uit.no"
] | jle040@uit.no |
c695f796fffd594178ab5a19127ff197690acb7c | 33836016ea99776d31f7ad8f2140c39f7b43b5fe | /fip_collab/2016_08_31_polycrystal_FIP/plot_err_v_pc.py | ba4dcd807183302d80eb21fd3d85c224651fb99c | [] | no_license | earthexploration/MKS-Experimentation | 92a2aea83e041bfe741048d662d28ff593077551 | 9b9ff3b468767b235e7c4884b0ed56c127328a5f | refs/heads/master | 2023-03-17T23:11:11.313693 | 2017-04-24T19:24:35 | 2017-04-24T19:24:35 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,561 | py | import numpy as np
import matplotlib.pyplot as plt
import matplotlib.cm as cm
from constants import const
from matplotlib.ticker import AutoMinorLocator
import h5py
def plterr(par, upbnd, deg, Tvec, Hvec):
C = const()
colormat = cm.plasma(np.linspace(0, .8, len(Hvec)))
# colormat = cm.rainbow(np.linspac... | [
"noahhpaulson@gmail.com"
] | noahhpaulson@gmail.com |
83ed30f264265a018a2915a912dc401fb61247ad | 163bbb4e0920dedd5941e3edfb2d8706ba75627d | /Code/CodeRecords/2630/60636/251138.py | 6a6bbb79cd34380643c6e73cf9718a1721f76e69 | [] | no_license | AdamZhouSE/pythonHomework | a25c120b03a158d60aaa9fdc5fb203b1bb377a19 | ffc5606817a666aa6241cfab27364326f5c066ff | refs/heads/master | 2022-11-24T08:05:22.122011 | 2020-07-28T16:21:24 | 2020-07-28T16:21:24 | 259,576,640 | 2 | 1 | null | null | null | null | UTF-8 | Python | false | false | 2,007 | py | def location(source,a):
for i in len(source):
for j in len(source[0])-1:
if(source[i][j]==a):
return [i,j]
def find(source,i,j,alls):
if i==0 and j==0:
return min([source[0][1],source[1][0]])
elif i==0 and j==len(source[i])-1:
if(not location(alls,min([sou... | [
"1069583789@qq.com"
] | 1069583789@qq.com |
1e3d6016c25d1b2a8f583b4da27b2234c064d97e | d08b0a2ea1365e96c2143a3076d6f1cfce178321 | /learnPython-master/news/ithome/demo.py | ab355ef2de9b7770e0ebab59189751875d274e5d | [] | no_license | xueyes/py3_study | f64060e5dbfcbf11c8d61de8561ce90bbb4e3c19 | a7d83b58ef95806f061f375952db604afe98bc13 | refs/heads/master | 2022-12-11T05:56:03.540612 | 2019-05-06T13:07:55 | 2019-05-06T13:07:55 | 162,883,421 | 1 | 0 | null | 2022-12-08T02:28:21 | 2018-12-23T11:02:31 | HTML | UTF-8 | Python | false | false | 381 | py | from lxml import etree
import requests
url = 'https://dyn.ithome.com/ithome/getajaxdata.aspx'
data = {
'newsID': '326707',
'hash': 'A379730C87B522EA',
'type': 'commentpage',
'page': '3',
'order': 'false',
}
html = requests.post(url, data=data).text
print(html)
# urls = 'https://dyn.ithome.com/co... | [
"1401354763@qq.com"
] | 1401354763@qq.com |
64e61e45e0a348bd5d50ae86d13b5f1dd0a34442 | 484a348682d9fa515666b94a5cd3a13b1b725a9e | /Data Structure/考试.py | 00a3ea41fd9be666a23b1b977479e92d1ce53653 | [] | no_license | joseph-mutu/Codes-of-Algorithms-and-Data-Structure | 1a73772825c3895419d86d6f1f506d58617f3ff0 | d62591683d0e2a14c72cdc64ae1a36532c3b33db | refs/heads/master | 2020-12-29T17:01:55.097518 | 2020-04-15T19:25:43 | 2020-04-15T19:25:43 | 238,677,443 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,332 | py | #include <stdio.h>
#include <stdlib.h>
using namespace std;
int N;
typedef struct BiTree
{
int Data;
struct BiTree* left, *right;
}BiTree;
BiTree* CreatTree(int data1[], int data2[], int start, int ends, int &ind)
{
int mid = data1[ind];
int i;
for(i = ends; i >= start; i--)
{
if(... | [
"josephmathone@gmail.com"
] | josephmathone@gmail.com |
5b7db5c2f10832e93c05e4accf948b198fd38fc5 | 5c4515960dcbfd3861d06d90b8c9bde0bdf3ecf5 | /Iserlab/migrations/0044_auto_20170306_0956.py | 649dec546e754ed99d60b1d6b99ffde77ce3b431 | [] | no_license | Mathilda1992/mcysite | 66bb2f51de622b7f7c450664c798eb11ce195cae | def82e43474ecc734c6cbb26842bd87f698b2b88 | refs/heads/master | 2021-01-11T19:58:23.611196 | 2017-06-26T08:58:11 | 2017-06-26T08:58:11 | 79,434,975 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 457 | py | # -*- coding: utf-8 -*-
# Generated by Django 1.9.7 on 2017-03-06 09:56
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('Iserlab', '0043_score_socre_time'),
]
operations = [
migrations.AlterField(
... | [
"machenyi2011@163.com"
] | machenyi2011@163.com |
ce924970e5c11232b741a9273bf79d4aec02ecf8 | 42ed6d4e67172522f79ab6f3c8cb650f4234be90 | /grpc/client/main.py | 55d9fa17b36fef38b4fffb7106dd8f1ebf9684f2 | [] | no_license | Hylan129/Self-Learning | 81a5143015850c33d5226c4da43d110150661dc7 | 06ccdc202f62629395900658909e1363a32632fd | refs/heads/master | 2020-06-12T19:45:50.479677 | 2020-05-26T15:38:26 | 2020-05-26T15:38:26 | 194,405,633 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 408 | py | #! /usr/bin/env python
# -*- coding: utf-8 -*-
import grpc
from example import data_pb2, data_pb2_grpc
_HOST = 'localhost'
_PORT = '8080'
def run():
conn = grpc.insecure_channel(_HOST + ':' + _PORT)
client = data_pb2_grpc.FormatDataStub(channel=conn)
response = client.DoFormat(data_pb2.Data(text='hello,... | [
"jyzyg129@163.com"
] | jyzyg129@163.com |
b4953030c41f9a1add974681fbeb2f552d932ccf | beb4d7c16ea8d8da9747b94298891cf01d9466f6 | /users/urls.py | c7b3b09544316033c571df99cedc218e2fa6a055 | [] | no_license | Chirag-Django/nonstopio_assignment | 48985445a19f8d01c1f0565e8058cd032942d903 | b1f1561e841857ea64d9a5170974704a347cc0e3 | refs/heads/master | 2023-03-05T07:05:49.963018 | 2021-02-20T18:35:29 | 2021-02-20T18:35:29 | 340,347,626 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 451 | py | from django.urls import path
from . import views
from django.contrib.auth import views as auth_views
app_name='users'
urlpatterns = [
path('register/', views.register, name='register'),
path('update_profile/',views.update_profile,name='update_profile'),
path('login/', auth_views.LoginView.as_view(template... | [
"chirag.django@gmail.com"
] | chirag.django@gmail.com |
ba0317152df2c5141cbc08cfba662a6ad4943890 | e7c1f3af60c030b97916e4f431172ebdbc07b2a9 | /django_mindscape/tests/test_dependencies.py | c02066d0898bbc0482536e51e8faff115d00fe83 | [] | no_license | podhmo/django-mindscape | d1df56c217750fee3cf3c24a49591bf98bbb6e89 | 2da92e155b7aaf465d631258f9799eb2e3d59671 | refs/heads/master | 2016-08-03T12:04:42.090545 | 2015-03-10T19:12:14 | 2015-03-10T19:12:14 | 31,464,195 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,128 | py | # -*- coding:utf-8 -*-
import unittest
from evilunit import test_target
@test_target("django_mindscape:Walker")
class ForeignKeyTests(unittest.TestCase):
@classmethod
def setUpClass(cls):
from django.db import models
class Group(models.Model):
name = models.CharField(max_length=25... | [
"podhmo+altair@beproud.jp"
] | podhmo+altair@beproud.jp |
aef95b48318caf1b38584776aca1d4f9936f4928 | 487ce91881032c1de16e35ed8bc187d6034205f7 | /codes/CodeJamCrawler/16_2_1_neat/16_2_1_Math_getting_digit.py | ba10364f80fe35b453998f9f7dfea738adce6858 | [] | no_license | DaHuO/Supergraph | 9cd26d8c5a081803015d93cf5f2674009e92ef7e | c88059dc66297af577ad2b8afa4e0ac0ad622915 | refs/heads/master | 2021-06-14T16:07:52.405091 | 2016-08-21T13:39:13 | 2016-08-21T13:39:13 | 49,829,508 | 2 | 0 | null | 2021-03-19T21:55:46 | 2016-01-17T18:23:00 | Python | UTF-8 | Python | false | false | 1,233 | py | #!/usr/bin/python3
import sys
def remove_letters(letters, word, ref_letter):
if (ref_letter in letters and letters[ref_letter] > 0):
number = letters[ref_letter]
for ll in word:
letters[ll] -= number
return(number)
else:
return(0)
def solve_number(SS, case):
let... | [
"[dhuo@tcd.ie]"
] | [dhuo@tcd.ie] |
7458e345152467d791ea25abac7dba7b3fe448a1 | bc6ebddfd13b36d5e394f7b5eb15444f7467f5e5 | /sundial/utils.py | 2670fc6d9ad15404fea7729d884697854ba0c8d8 | [
"MIT"
] | permissive | Surgo/django-sundial | 28bbe8da723ca45fe926750e78ae568b1c5f0092 | e6a3f69d61a49a5d7ae2b053cdd79289e11a8a73 | refs/heads/master | 2021-01-17T06:09:01.327135 | 2015-03-12T09:13:12 | 2015-03-12T09:13:12 | 32,067,215 | 0 | 0 | null | 2015-03-12T09:01:48 | 2015-03-12T09:01:48 | Python | UTF-8 | Python | false | false | 709 | py | from __future__ import unicode_literals
from django.core.exceptions import ValidationError
from django.conf import settings
from django.utils.text import force_text
from django.utils.translation import ugettext_lazy as _
import pytz
TIMEZONE_SESSION_KEY = getattr(
settings, 'SUNDIAL_TIMEZONE_SESSION_KEY', '_time... | [
"charette.s@gmail.com"
] | charette.s@gmail.com |
27cfac09bd2fc5432cc9463f81553242ffb3e67f | 0de5fbd2c992388d572bfb4c114f82741a351b8e | /0x06-Basic_authentication/api/v1/auth/auth.py | 55326846343b39f19a21e2e490782c8f2570f96d | [] | no_license | veromejia/holbertonschool-web_back_end | 3fac1ad905d02bb6d351092210d005a211053df4 | 44258bb53104da95c6df8a69dd066233cb0daae0 | refs/heads/main | 2023-02-10T01:49:31.439587 | 2021-01-05T00:44:46 | 2021-01-05T00:44:46 | 305,465,622 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,000 | py | #!/usr/bin/env python3
""" Define Auth class """
from flask import request
from typing import List, TypeVar
class Auth:
"""Auth Class that handle public methods"""
def require_auth(self, path: str, excluded_paths: List[str]) -> bool:
"""Check if path requires authentication"""
if path is No... | [
"veromejia.q@gmail.com"
] | veromejia.q@gmail.com |
626e573ed0bbb8e22c948eeb92c9e96d8ffb4782 | be6e6d8af85adf044bf79676b7276c252407e010 | /spec/construct/test_switch_manual_enum_invalid.py | 66cd2a7da5b985e6bb318912bb2ad2cc7e62bf3c | [
"MIT"
] | permissive | kaitai-io/kaitai_struct_tests | 516e864d29d1eccc5fe0360d1b111af7a5d3ad2b | 3d8a6c00c6bac81ac26cf1a87ca84ec54bf1078d | refs/heads/master | 2023-08-19T19:42:47.281953 | 2023-08-04T20:26:50 | 2023-08-04T20:26:50 | 52,155,797 | 12 | 41 | MIT | 2023-07-30T23:30:30 | 2016-02-20T13:55:39 | Ruby | UTF-8 | Python | false | false | 531 | py | # Autogenerated from KST: please remove this line if doing any edits by hand!
import unittest
from switch_manual_enum_invalid import _schema
class TestSwitchManualEnumInvalid(unittest.TestCase):
def test_switch_manual_enum_invalid(self):
r = _schema.parse_file('src/enum_negative.bin')
self.assert... | [
"petr.pucil@seznam.cz"
] | petr.pucil@seznam.cz |
f71da1fd302633769fc6a1663d9ca71769b093c6 | eddbfe4eb1aa3052cb8d03097cca2673ae207ec0 | /books/migrations/0003_auto_20210429_1839.py | 63f82e9831d65f0c47c2a14623a7f4bae6ac1eab | [] | no_license | luiz158/CRUD_Django | f40d630f09916a0cd2d06a076415873122c02098 | 852242b34c7ff4781c9704df032865e83ded9bf3 | refs/heads/master | 2023-07-02T08:58:45.637229 | 2021-08-04T21:57:03 | 2021-08-04T21:57:03 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 581 | py | # Generated by Django 3.2 on 2021-04-29 18:39
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('books', '0002_alter_book_date_inclusion'),
]
operations = [
migrations.RemoveField(
model_name='b... | [
"jonathan.mothe@gmail.com"
] | jonathan.mothe@gmail.com |
4efd9e8caa0fa82f83d43e5d2702eae94ce0a814 | 2db7597686f33a0d700f7082e15fa41f830a45f0 | /Python/BinaryTree/1448. 统计二叉树中好节点的数目.py | f1622e85dcf75ab740d30faccdc8934d48e9b3c6 | [] | no_license | Leahxuliu/Data-Structure-And-Algorithm | 04e0fc80cd3bb742348fd521a62bc2126879a70e | 56047a5058c6a20b356ab20e52eacb425ad45762 | refs/heads/master | 2021-07-12T23:54:17.785533 | 2021-05-17T02:04:41 | 2021-05-17T02:04:41 | 246,514,421 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 836 | py | '''
1448. 统计二叉树中好节点的数目
给你一棵根为 root 的二叉树,请你返回二叉树中好节点的数目。
「好节点」X 定义为:从根到该节点 X 所经过的节点中,没有任何节点的值大于 X 的值。
'''
# Definition for a BT node
class TreeNode:
def __init__(self, x = 0):
self.val = x
self.left = None
self.right = None
def goodNodes(root):
if root == None:
return 0
... | [
"leahxuliu@gmail.com"
] | leahxuliu@gmail.com |
3f9a50bca0bdd49ad832b81e37cc2acb7ef94337 | f0d713996eb095bcdc701f3fab0a8110b8541cbb | /aQWEQDoWiNbryG8xs_13.py | 74b473ad6cce9d4cfa59205686035d2b90514e34 | [] | 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 | 529 | py | """
Create a function that takes a number `num` and returns the first 10 multiples
of `num` with 1 added to it, separated by commas.
### Examples
n_tables_plus_one(7) ➞ "8,15,22,29,36,43,50,57,64,71"
n_tables_plus_one(1) ➞ "2,3,4,5,6,7,8,9,10,11"
n_tables_plus_one(3) ➞ "4,7,10,13,16,19,22,25,... | [
"daniel.reich@danielreichs-MacBook-Pro.local"
] | daniel.reich@danielreichs-MacBook-Pro.local |
6cb50044646a8ed42437fa9dd67f027154040955 | 241e8be8fbd310384e5669b64142cf173ecf692b | /mickey/admin.py | 65504f3ffe946c80f308fdd06f1d942f53fbe379 | [
"MIT"
] | permissive | raihanba13/mickey | a1e61cf71419b61acfc2240336c8a8cebf712ceb | 6a151145d11687760eae14749b7ee150c9d5a044 | refs/heads/master | 2022-06-10T03:22:18.869733 | 2020-05-07T11:31:20 | 2020-05-07T11:31:20 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,993 | py | from django.contrib import admin
from django.utils.html import format_html
from django.contrib import messages
from django.contrib.contenttypes.admin import GenericTabularInline
from mickey.models import *
from mickey.widgets import *
import logging
logger = logging.getLogger(__name__)
# Register your models here.
d... | [
"farhapartex@gmail.com"
] | farhapartex@gmail.com |
9f79014a99de26096629779af1c9279f8319b7b4 | 86813bf514f3e0257f92207f40a68443f08ee44b | /0072 编辑距离/0072 编辑距离.py | 09a71367fdde0319dcd6e517d8d2183aa808a77f | [] | no_license | Aurora-yuan/Leetcode_Python3 | 4ce56679b48862c87addc8cd870cdd525c9d926c | 720bb530850febc2aa67a56a7a0b3a85ab37f415 | refs/heads/master | 2021-07-12T13:23:19.399155 | 2020-10-21T03:14:36 | 2020-10-21T03:14:36 | 212,998,500 | 4 | 1 | null | null | null | null | UTF-8 | Python | false | false | 893 | py | # label: dynamic programming difficulty: difficult
class Solution(object):
def minDistance(self, word1, word2):
"""
:type word1: str
:type word2: str
:rtype: int
"""
#用dp[i][j]表示word1[:i + 1], word2[:j + 1]这个问题的解
m, n = len(word1), len(word2)
dp = [[0... | [
"noreply@github.com"
] | Aurora-yuan.noreply@github.com |
7ae7e78b80d63d83fad51f24b644042cd5b26dc0 | 128c32834fa8156a25e5693131991525ea33020b | /2016.1/Exércicio LAB DE PROGRAMAÇÃO/Exercício 2016.1/Exemplos_Realizados_em_Sala/TabelaHashOficial.py | 32d11b51e1e5f60f2130fc55a4f5649f77574158 | [] | no_license | wellington16/BSI-UFRPE | 5780e94b4c10b3ee8885d01fc14f4050e6907611 | 268d0e5beabf211df1aa69cbe52ac1e0cb85fe64 | refs/heads/master | 2020-06-30T16:59:59.316415 | 2020-03-10T13:22:31 | 2020-03-10T13:22:31 | 66,642,156 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 7,527 | py |
class No:
def __init__(self, valor):
self.valor = valor
self.prox = None
self.ant = None
def getValor(self):
return self.valor
def setValor(self, novodado):
self.prox = novoDado
def getNovValor(self):
return self.prox
def setN... | [
"wjfilmagens@hotmail.com"
] | wjfilmagens@hotmail.com |
b5e65556cb0df5cb435e365882c7a0da7fe6731e | ac1bbabc7c1b3149711c416dd8b5f5969a0dbd04 | /Python Advanced/comprehensions/heroes_inventory.py | 1ae5e593c8b94b15f8fb01e9809e0e0be37b5b93 | [] | no_license | AssiaHristova/SoftUni-Software-Engineering | 9e904221e50cad5b6c7953c81bc8b3b23c1e8d24 | d4910098ed5aa19770d30a7d9cdf49f9aeaea165 | refs/heads/main | 2023-07-04T04:47:00.524677 | 2021-08-08T23:31:51 | 2021-08-08T23:31:51 | 324,847,727 | 1 | 0 | null | 2021-08-08T23:31:52 | 2020-12-27T20:58:01 | Python | UTF-8 | Python | false | false | 634 | py | heroes = input().split(', ')
command = input()
heroes_inventory = {hero: [] for hero in heroes}
while not command == "End":
data = command.split('-')
name, item, cost = data
if name in heroes_inventory:
if heroes_inventory[name]:
if item not in heroes_inventory[name][0]:
... | [
"assiaphristova@gmail.com"
] | assiaphristova@gmail.com |
27f120ae877d4f79cb6762956b3002c61edeb0ca | bde402f8375dc12f1a337d534e4ed217023fd1d2 | /setup.py | 18226d5ce7c5d447cabe839a450b0e052abc3db6 | [] | no_license | CONNJUR/nmrglue | 975d386a5128db6904041a57f833b34980ec9170 | 9ee6d6278d1d2be87648bb4903f3948fb6447da1 | refs/heads/master | 2020-04-20T16:52:19.143719 | 2019-02-03T17:51:44 | 2019-02-03T17:51:44 | 168,971,497 | 0 | 0 | null | 2019-02-03T17:22:07 | 2019-02-03T17:22:06 | null | UTF-8 | Python | false | false | 1,654 | py | #!/usr/bin/env python
# setup script for nmrglue
from distutils.core import setup
from codecs import open
from os import path, walk
here = path.abspath(path.dirname(__file__))
# get long description from README
with open(path.join(here, 'README.rst'), encoding='utf-8') as f:
long_description = f.read()
setup(
... | [
"jjhelmus@gmail.com"
] | jjhelmus@gmail.com |
63ab12f6fb3b539ccfbf9e77397ab0cef69e7a12 | cb2c9c33b993e14fec3db34cdbaf04dabdf60ad1 | /2018/17/solve | 4d8fb57693bb81b44e1058eb285023126ead0e59 | [] | no_license | rr-/aoc | 51e95711d3eaf5de4b80bcd57c90750c1c09252d | babc68340eb46dac42981e700435bd740ff3c625 | refs/heads/master | 2020-04-10T00:26:08.388243 | 2018-12-25T15:08:06 | 2018-12-25T15:17:17 | 160,685,276 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,368 | #!/usr/bin/env python3
import re
import typing as T
from collections import defaultdict
from pathlib import Path
from PIL import Image
WELL_X = 500
WELL_Y = 0
AIR = "."
CLAY = "#"
WELL = "+"
STILL_WATER = "~"
RUNNING_WATER = "|"
def parse_chunk(text: str) -> T.List[int]:
num = list(map(int, re.findall(r"\d+", ... | [
"rr-@sakuya.pl"
] | rr-@sakuya.pl | |
540ec97d8fd8b38e391df681d5f04875976ab585 | 243335dfe75c72f4e94ff953f5b0851d2e116cb1 | /model/simple_graphs.py | dd2a0ecdd9d8c05fc516c00c757c9509420d2282 | [] | no_license | bwhub/generalizable-device-placement | f485aea87b8a297cc3212014f3674fd9bad8df49 | d9a81a9f6cb05bfc94773722a4e7ead793ca7fd1 | refs/heads/master | 2022-02-24T13:24:43.374572 | 2019-10-25T01:02:52 | 2019-10-25T01:02:52 | 298,305,058 | 1 | 0 | null | 2020-09-24T14:32:56 | 2020-09-24T14:32:55 | null | UTF-8 | Python | false | false | 1,606 | py | import networkx as nx
# d is the number of chains
def makeChainGraph(N, d=2):
G = nx.DiGraph()
def add_edge(i, j):
G.add_edge(str(i), str(j))
'''
for N = 4, d = 2
1 2 3 4
0 9
5 6 7 8
Lowest Runtime: (N+2) + l_fact* 2
'''
n = 1
for i in range(d):
add_edge(0, n)
for j in... | [
"addanki@mit.edu"
] | addanki@mit.edu |
44db05656099ea323b7329dabe2deea43a7f61fe | 29c71deb76575eb7142f5e798745ccda8dd5d366 | /salesapp/cart.py | 91c2657add7953b609ab17ee0029f8001f8cac73 | [] | no_license | bill0812/salesSystem | c0b992949183ce8df8cd6c3a1470b17a5f6dc33b | 4ff17f52bac911959b7b7fff0c5e046d5471ed66 | refs/heads/master | 2020-03-29T10:04:57.736379 | 2020-03-01T12:04:10 | 2020-03-01T12:04:10 | 149,788,656 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,300 | py | from firebase import firebase
import hashlib,re
url = "https://sales-system-project.firebaseio.com/"
fb = firebase.FirebaseApplication(url, None)
def fetch_cart(account):
customer_data = fb.get("/會員資料/"+account+"/購物車/客製化",None)
product_data = fb.get("/會員資料/"+account+"/購物車/產品資訊",None)
return customer_data,p... | [
"maxwell111023@gmail.com"
] | maxwell111023@gmail.com |
1874a9fa74e68180d06cdde9266507f63280c99c | b167407960a3b69b16752590def1a62b297a4b0c | /tools/project-creator/Python2.6.6/Lib/test/test_aepack.py | 46ec71b7ce3f537a8a7011abdb870791b1e84d7a | [
"MIT"
] | permissive | xcode1986/nineck.ca | 543d1be2066e88a7db3745b483f61daedf5f378a | 637dfec24407d220bb745beacebea4a375bfd78f | refs/heads/master | 2020-04-15T14:48:08.551821 | 2019-01-15T07:36:06 | 2019-01-15T07:36:06 | 164,768,581 | 1 | 1 | MIT | 2019-01-15T08:30:27 | 2019-01-09T02:09:21 | C++ | UTF-8 | Python | false | false | 2,617 | py | # Copyright (C) 2003 Python Software Foundation
import unittest
import aepack
import aetypes
import os
from test import test_support
class TestAepack(unittest.TestCase):
OBJECTS = [
aetypes.Enum('enum'),
aetypes.Type('type'),
aetypes.Keyword('kwrd'),
aetypes.Range(1, 1... | [
"278688386@qq.com"
] | 278688386@qq.com |
ce32fd8f2071c627a7f0902be8dfa99ab9d61d03 | bc441bb06b8948288f110af63feda4e798f30225 | /topboard_sdk/model/ops_automation/jobs_pb2.py | 9233835a9eb0089af4f4dc15c4c5b04c2d1ac53e | [
"Apache-2.0"
] | permissive | easyopsapis/easyops-api-python | 23204f8846a332c30f5f3ff627bf220940137b6b | adf6e3bad33fa6266b5fa0a449dd4ac42f8447d0 | refs/heads/master | 2020-06-26T23:38:27.308803 | 2020-06-16T07:25:41 | 2020-06-16T07:25:41 | 199,773,131 | 5 | 0 | null | null | null | null | UTF-8 | Python | false | true | 5,796 | py | # -*- coding: utf-8 -*-
# Generated by the protocol buffer compiler. DO NOT EDIT!
# source: jobs.proto
import sys
_b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1'))
from google.protobuf import descriptor as _descriptor
from google.protobuf import message as _message
from google.protobuf import... | [
"service@easyops.cn"
] | service@easyops.cn |
3edc5c35853123a22c04959e95910dfd09412079 | 73a0f661f1423d63e86489d4b2673f0103698aab | /python/oneflow/test/modules/test_flatten.py | cf2ada9bbbdcad6b4174bcacb1aeef712538c9af | [
"Apache-2.0"
] | permissive | Oneflow-Inc/oneflow | 4fc3e081e45db0242a465c4330d8bcc8b21ee924 | 0aab78ea24d4b1c784c30c57d33ec69fe5605e4a | refs/heads/master | 2023-08-25T16:58:30.576596 | 2023-08-22T14:15:46 | 2023-08-22T14:15:46 | 81,634,683 | 5,495 | 786 | Apache-2.0 | 2023-09-14T09:44:31 | 2017-02-11T06:09:53 | C++ | UTF-8 | Python | false | false | 4,076 | py | """
Copyright 2020 The OneFlow 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 applicable law or agr... | [
"noreply@github.com"
] | Oneflow-Inc.noreply@github.com |
14ba40653e5a91516f606e964c3cc7999beb2bd4 | 2ee7195d71993838829e06f26347f76a2433931b | /test_backtest/T0backtest.py | 6b49876c013292907cee777def029de94403fe24 | [
"MIT"
] | permissive | imgreenbird/QUANTAXIS | 0a056de2c3961f5d0b7d0e17782f34b25593e5fb | 88eac434135a92cd64bd035cd844b34020729747 | refs/heads/master | 2020-03-23T14:27:23.003742 | 2018-07-20T01:25:27 | 2018-07-20T01:25:27 | 141,676,903 | 3 | 0 | MIT | 2018-07-20T07:11:09 | 2018-07-20T07:11:09 | null | UTF-8 | Python | false | false | 3,821 | py |
# coding: utf-8
# In[1]:
from QUANTAXIS.QAARP.QAStrategy import QA_Strategy
from QUANTAXIS.QAARP.QAAccount import QA_Account
from QUANTAXIS.QAUtil.QAParameter import (AMOUNT_MODEL, MARKET_TYPE,
FREQUENCE, ORDER_DIRECTION,
ORDER_MOD... | [
"yutiansut@qq.com"
] | yutiansut@qq.com |
20a9b35189e8cc10558e34e4a5f9b23e8b6e8215 | c733e6b433914a8faba256c7853f5cf2cd39c62a | /Python/Leetcode Daily Practice/Stack/907.Sum of Subarray Minimums.py | 27776a90d32a21b05ff11eaa3a7e22e5d544f69d | [] | 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 | 1,337 | py | class Solution(object):
def sumSubarrayMins(self, A):
MOD = 10**9 + 7
stack = []
dot, ans = 0, 0
for num in A:
cnt = 1
while stack and stack[-1][0] >= num:
n, c = stack.pop(-1)
cnt += c
dot -= n * c
... | [
"alicia.qyq@gmail.com"
] | alicia.qyq@gmail.com |
5d54aa954b5a801f72d85eef577ed6856517acbf | cccd1ede83f9391238893f3862e7beff999647e1 | /rw_and_plot/15_1_cubes.py | efe10175eca18c8f2ef07cef6f815f60667a78fa | [] | no_license | SMS-NED16/pcc-data-vis | c7c136e32921619af52b46cdbf12f6debaa8a690 | f9750ee947163335c351a6df453f5d2dab87d855 | refs/heads/master | 2020-03-09T02:32:19.494589 | 2018-04-04T12:11:40 | 2018-04-04T12:11:40 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 724 | py | import matplotlib.pyplot as plt
x = list(range(1, 6))
five_cubes = [val ** 3 for val in x]
thousand_cubes = [ val ** 3 for val in range(1, 5001)]
plt.subplot(1, 2, 1)
plt.scatter(x, five_cubes, s=40)
plt.title("Graph of first five cubes", fontsize=14)
plt.xlabel("Values", fontsize=12)
plt.ylabel("Cube of Value", font... | [
"saadmsiddiqui96@gmail.com"
] | saadmsiddiqui96@gmail.com |
824d5eea34380df61a582e52a5a070cac3dff314 | ac5e52a3fc52dde58d208746cddabef2e378119e | /exps-gsn-edf/gsn-edf_ut=3.5_rd=0.8_rw=0.04_rn=4_u=0.075-0.35_p=harmonic-2/sched=RUN_trial=48/sched.py | afb4c0412030f6f941ad2606c1757d3218fe3c14 | [] | no_license | ricardobtxr/experiment-scripts | 1e2abfcd94fb0ef5a56c5d7dffddfe814752eef1 | 7bcebff7ac2f2822423f211f1162cd017a18babb | refs/heads/master | 2023-04-09T02:37:41.466794 | 2021-04-25T03:27:16 | 2021-04-25T03:27:16 | 358,926,457 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 450 | py | -X FMLP -Q 0 -L 1 132 400
-X FMLP -Q 0 -L 1 125 400
-X FMLP -Q 0 -L 1 65 250
-X FMLP -Q 0 -L 1 48 175
-X FMLP -Q 1 -L 1 45 250
-X FMLP -Q 1 -L 1 40 125
-X FMLP -Q 1 -L 1 36 250
-X FMLP -Q 1 -L 1 34 150
-X FMLP -Q 2 -L 1 26 175
-X FMLP -Q 2 -L 1 25 125
-X FMLP -Q 2 -L 1 22 150
-X FMLP -... | [
"ricardo.btxr@gmail.com"
] | ricardo.btxr@gmail.com |
7d2398a97349b50e741469065939c3bdc7116573 | 5d45174eef86562b6c90a4bc07c86258df249486 | /hyak/launcher.py | 7b06e8c0e6a491706816db94253c46ac6fdff997 | [] | no_license | bmorris3/shampoo | a70dd3b1896c7a4f2e88413c13cae96d80f21c71 | 853c6668efef3e7b69727ea45ff9eff419e9a70b | refs/heads/master | 2023-05-27T04:30:02.756962 | 2018-03-28T14:38:09 | 2018-03-28T14:38:09 | 41,105,695 | 22 | 12 | null | 2021-04-27T11:06:07 | 2015-08-20T16:08:58 | Python | UTF-8 | Python | false | false | 2,342 | py | from __future__ import (absolute_import, division, print_function,
unicode_literals)
import os
from glob import glob
import numpy as np
python_path = '/usr/lusers/bmmorris/miniconda2/bin/python'
data_dir = '/gscratch/stf/bmmorris/shamu/2015.12.15_17-47'
output_dir = '/gscratch/stf/bmmorris/sha... | [
"brettmorris21@gmail.com"
] | brettmorris21@gmail.com |
e06d7832c60e9bb8324a477b100c0e87fb4cfe26 | c3274a346ddcf09c9ec70e1402daa34ad0ac44af | /examples/dataframe/dataframe_sum.py | f8171d3e92e95fabd061003fe34051a41b89a867 | [
"BSD-2-Clause"
] | permissive | vishalbelsare/hpat | cb6b39ddeb07c319c88e132df9cee4c6adb0a415 | eb5efbad9bfec67db88b52474c4bd00238b61283 | refs/heads/master | 2023-04-06T14:59:35.723023 | 2023-03-10T16:44:51 | 2023-03-10T16:44:51 | 161,796,133 | 0 | 0 | BSD-2-Clause | 2023-03-19T09:18:25 | 2018-12-14T14:35:55 | Python | UTF-8 | Python | false | false | 1,882 | py | # *****************************************************************************
# Copyright (c) 2020, Intel Corporation All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# Redistributions of sou... | [
"noreply@github.com"
] | vishalbelsare.noreply@github.com |
2d221ec37b42ee7d6d78140f67e53a4798e29806 | 90419da201cd4948a27d3612f0b482c68026c96f | /sdk/python/pulumi_azure_nextgen/appconfiguration/v20200701preview/list_configuration_store_keys.py | 1c5a925503a75002b4536769dfcd2cc6de923821 | [
"BSD-3-Clause",
"Apache-2.0"
] | permissive | test-wiz-sec/pulumi-azure-nextgen | cd4bee5d70cb0d332c04f16bb54e17d016d2adaf | 20a695af0d020b34b0f1c336e1b69702755174cc | refs/heads/master | 2023-06-08T02:35:52.639773 | 2020-11-06T22:39:06 | 2020-11-06T22:39:06 | 312,993,761 | 0 | 0 | Apache-2.0 | 2023-06-02T06:47:28 | 2020-11-15T09:04:00 | null | UTF-8 | Python | false | false | 3,284 | py | # coding=utf-8
# *** WARNING: this file was generated by the Pulumi SDK Generator. ***
# *** Do not edit by hand unless you're certain you know what you are doing! ***
import warnings
import pulumi
import pulumi.runtime
from typing import Any, Mapping, Optional, Sequence, Union
from ... import _utilities, _tables
from... | [
"noreply@github.com"
] | test-wiz-sec.noreply@github.com |
670ee8f2f3d080e83ece3e6e319c7b2d5c3ec218 | d8dfe2bb29965f2bf00724caaa4d5f3f02715002 | /crater/operations/expand_dims.py | c5c91efc7cd1005456f0b37dce2f1d1912a19e56 | [] | no_license | malyvsen/kth-deep-learning | 20fc0d89c0b81ea97af77b627f0ee46458310126 | 17b3140043aaa81cf86a6a9b7fed3295ee48b061 | refs/heads/main | 2023-05-05T10:02:29.764591 | 2021-05-13T08:35:25 | 2021-05-13T08:35:25 | 353,112,929 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 612 | py | from typing import Union, Tuple
import numpy as np
from crater.tensor import Tensor
from crater.gradient import Gradients, Gradient
from crater.utils import tuplify
from .coalesce import coalesce
def expand_dims(tensor: Tensor, axes: Union[None, int, Tuple[int]] = None):
tensor = coalesce(tensor)
axes = () if... | [
"5940672+malyvsen@users.noreply.github.com"
] | 5940672+malyvsen@users.noreply.github.com |
104f75c625a5c419f721c085bd4d90f8ac2b482c | b7f3edb5b7c62174bed808079c3b21fb9ea51d52 | /third_party/blink/tools/blinkpy/w3c/monorail_unittest.py | 14a22ac6fb4b1feb36e0116e4dc30575cf05e1d7 | [
"LGPL-2.0-or-later",
"GPL-1.0-or-later",
"MIT",
"Apache-2.0",
"LicenseRef-scancode-warranty-disclaimer",
"LGPL-2.1-only",
"GPL-2.0-only",
"LGPL-2.0-only",
"BSD-2-Clause",
"LicenseRef-scancode-other-copyleft",
"BSD-3-Clause"
] | permissive | otcshare/chromium-src | 26a7372773b53b236784c51677c566dc0ad839e4 | 64bee65c921db7e78e25d08f1e98da2668b57be5 | refs/heads/webml | 2023-03-21T03:20:15.377034 | 2020-11-16T01:40:14 | 2020-11-16T01:40:14 | 209,262,645 | 18 | 21 | BSD-3-Clause | 2023-03-23T06:20:07 | 2019-09-18T08:52:07 | null | UTF-8 | Python | false | false | 4,252 | py | # -*- coding: utf-8 -*-
# Copyright 2017 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import unittest
from blinkpy.w3c.monorail import MonorailAPI, MonorailIssue
class MonorailIssueTest(unittest.TestCase):
def te... | [
"commit-bot@chromium.org"
] | commit-bot@chromium.org |
420a38deaafbfe305203da3b4483510a880f60ab | 98bd2625dbcc955deb007a07129cce8b9edb3c79 | /simulate_barseq_tnseq.py | 85aaae7b4ea0ea4073de7d774c6a359a4df634fe | [] | no_license | melanieabrams/bremdata | 70d0a374ab5dff32f6d9bbe0a3959a617a90ffa8 | df7a12c72a29cca4760333445fafe55bb6e40247 | refs/heads/master | 2021-12-26T01:57:25.684288 | 2021-09-30T22:48:05 | 2021-09-30T22:48:05 | 166,273,567 | 0 | 3 | null | null | null | null | UTF-8 | Python | false | false | 2,755 | py | import regex
import numpy as np
import sys
import subprocess as sp
import random
# HELP #
if len(sys.argv) == 1:
print("USAGE: python3 simulate_barseq_tnseq out_directory fastq_file1 fastq_file2...")
exit()
# INPUT #
num_orig = 20 #number of unmodified reads to preserve. This will make sure my modifi... | [
"noreply@github.com"
] | melanieabrams.noreply@github.com |
da29fd239650f5e1ed7b3fbb80213b271705d874 | edde333afca3ca4977bec7b38271d8c9e8448d85 | /mirage/projectstartup/django_app_create.py | 377edc7000d92c5c2d4e56add53610298c23d128 | [
"LicenseRef-scancode-unknown-license-reference",
"Apache-2.0"
] | permissive | TrendingTechnology/mirage-django-lts | 0219450155d9ce122196b66045de2bee13fa6bfd | b9d74006c1b64f5f5b33049b5a1701de58b478b3 | refs/heads/master | 2023-05-29T20:25:45.865865 | 2021-06-16T01:20:23 | 2021-06-16T01:20:23 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,119 | py | # -*- coding: utf-8 -*-
"""
Copyright 2017-2020 Shota Shimazu.
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 appl... | [
"hornet.live.mf@gmail.com"
] | hornet.live.mf@gmail.com |
4dedc840e56c94ed1dd1857f53ca4926ff01e49f | 8997a0bf1e3b6efe5dd9d5f307e1459f15501f5a | /zelle_graphics/hello_world.py | 7b041997c7b74d4bae882c7bb8f6ac20efcc7645 | [
"CC-BY-4.0"
] | permissive | stepik/SimplePyScripts | 01092eb1b2c1c33756427abb2debbd0c0abf533f | 3259d88cb58b650549080d6f63b15910ae7e4779 | refs/heads/master | 2023-05-15T17:35:55.743164 | 2021-06-11T22:59:07 | 2021-06-11T22:59:07 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 228 | py | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
__author__ = 'ipetrash'
from graphics import *
win = GraphWin("My Circle", 100, 100)
c = Circle(Point(50, 50), 10)
c.draw(win)
win.getMouse() # Pause to view result
win.close()
| [
"ilya.petrash@inbox.ru"
] | ilya.petrash@inbox.ru |
182d05ded57370c6cfa6cbc2097c846975a841d1 | 82b946da326148a3c1c1f687f96c0da165bb2c15 | /sdk/python/pulumi_azure_native/web/v20200901/list_web_app_function_secrets_slot.py | d97937e5b7161052acdff721dd2dc7821a150932 | [
"BSD-3-Clause",
"Apache-2.0"
] | permissive | morrell/pulumi-azure-native | 3916e978382366607f3df0a669f24cb16293ff5e | cd3ba4b9cb08c5e1df7674c1c71695b80e443f08 | refs/heads/master | 2023-06-20T19:37:05.414924 | 2021-07-19T20:57:53 | 2021-07-19T20:57:53 | 387,815,163 | 0 | 0 | Apache-2.0 | 2021-07-20T14:18:29 | 2021-07-20T14:18:28 | null | UTF-8 | Python | false | false | 2,925 | py | # coding=utf-8
# *** WARNING: this file was generated by the Pulumi SDK Generator. ***
# *** Do not edit by hand unless you're certain you know what you are doing! ***
import warnings
import pulumi
import pulumi.runtime
from typing import Any, Mapping, Optional, Sequence, Union, overload
from ... import _utilities
__... | [
"noreply@github.com"
] | morrell.noreply@github.com |
8daeb7d575a3677e6cbd190d314c2986273f7bc5 | 6bd51065a8ecd097e7f80ee3c6acd16a083be350 | /tensorflow/contrib/framework/__init__.py | 8421ba7c0423c6ed274f92ba74930822d0171e05 | [
"Apache-2.0"
] | permissive | cglewis/tensorflow | 29b50dadbdb599bacd06af960689bc518a472de1 | 6eac524ef63728bdc10c40f95d30c94aede5f4ea | refs/heads/master | 2023-04-07T18:38:29.752739 | 2017-10-31T17:56:48 | 2017-10-31T17:56:48 | 109,033,012 | 0 | 0 | Apache-2.0 | 2023-04-04T00:37:48 | 2017-10-31T17:54:48 | C++ | UTF-8 | Python | false | false | 2,622 | py | # Copyright 2016 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 applica... | [
"gardener@tensorflow.org"
] | gardener@tensorflow.org |
4bb739f59e43b16c125bc8bb2a99540f52ebf7a0 | 58e4c3e1302a97e781b5657764fdde3e8dd48708 | /no_if_required.py | 0644af70c34260fd2a4fc9ef39a1b2891b776aa4 | [] | no_license | bgroveben/coursera_LTP_TF | 05ebf73991f73a98360ffbde685f24f6c68d3968 | f96bd2d19316713b496979df63d5ebec2161c722 | refs/heads/master | 2020-02-26T15:40:04.082856 | 2017-03-01T13:52:01 | 2017-03-01T13:52:01 | 70,072,027 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 546 | py | # Booleans are your friend.
# Why do this:
def is_even(num):
""" (int) -> bool
Return whether number is even.
>>> is_even(1)
False
>>> is_even(2)
True
"""
if num % 2 == 0:
return True
else:
return False
print(is_even(1))
print(is_even(2))
# When you can do this:
... | [
"bgroveben@gmail.com"
] | bgroveben@gmail.com |
78f2cb1b699f7ef5beaaeed03f0c6df3b2382e73 | d9a490dc36da08051b2685489a8e6af3d29fa903 | /gaussNodes.py | 396b5e58af12eae8c24a9c007102e128565535cc | [] | no_license | freephys/numeric-for-engineer | 403679c3f055164bf8b7097c360ad8bfc2cb9978 | a98d318e8cdff679cc02a575d32840fa87a4717d | refs/heads/master | 2020-04-16T01:33:43.530839 | 2009-11-28T18:42:12 | 2009-11-28T18:42:12 | 388,559 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,021 | py | ## module gaussNodes
''' x,A = gaussNodes(m,tol=10e-9)
Returns nodal abscissas {x} and weights {A} of
Gauss-Legendre m-point quadrature.
'''
from math import cos,pi
from numarray import zeros,Float64
def gaussNodes(m,tol=10e-9):
def legendre(t,m):
p0 = 1.0; p1 = t
for k in range(1,m):
... | [
"freephys@gmail.com"
] | freephys@gmail.com |
914136d9cb630ffafb4876af0629d835fdf2852d | 7839d009f3ae0a0c1bc360b86756eba80fce284d | /build/rostime/catkin_generated/generate_cached_setup.py | 35bb758cd62d38d6d794504e7e737ab1ac541e5b | [] | no_license | abhat91/ros_osx | b5022daea0b6fdaae3489a97fdb1793b669e64f5 | 39cd8a79788d437927a24fab05a0e8ac64b3fb33 | refs/heads/master | 2021-01-10T14:43:41.047439 | 2016-03-13T23:18:59 | 2016-03-13T23:18:59 | 53,812,264 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 1,283 | py | # -*- coding: utf-8 -*-
from __future__ import print_function
import argparse
import os
import stat
import sys
# find the import for catkin's python package - either from source space or from an installed underlay
if os.path.exists(os.path.join('/opt/ros/jade/share/catkin/cmake', 'catkinConfig.cmake.in')):
sys.pat... | [
"abhat@wpi.edu"
] | abhat@wpi.edu |
382fe6b2d5bbcfdf0985153ae02dac0e9df70625 | 9f1039075cc611198a988034429afed6ec6d7408 | /tensorflow-stubs/python/estimator/canned/metric_keys.pyi | 10d9b385f98a4f8bc2d53253b192caa053ff2447 | [] | no_license | matangover/tensorflow-stubs | 9422fbb1cb3a3638958d621461291c315f9c6ec2 | 664bd995ef24f05ba2b3867d979d23ee845cb652 | refs/heads/master | 2020-05-23T12:03:40.996675 | 2019-05-15T06:21:43 | 2019-05-15T06:21:43 | 186,748,093 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 848 | pyi | # Stubs for tensorflow.python.estimator.canned.metric_keys (Python 3)
#
# NOTE: This dynamically typed stub was automatically generated by stubgen.
from tensorflow.python.estimator import model_fn as model_fn
from typing import Any as Any
class MetricKeys:
LOSS: Any = ...
LOSS_MEAN: Any = ...
LOSS_REGULAR... | [
"matangover@gmail.com"
] | matangover@gmail.com |
f26f4be9786d1d6d93f78cd9342425b3d05c88fc | 99c9ca6edd44a13fd4eabee78625c827cc535ea1 | /examples/english/english_experiment.py | 911a51f8596bb8082423e0c2ed51e9a07dfd52f2 | [
"Apache-2.0"
] | permissive | adeepH/MUDES | bbcdcac41b33990545eac769d127a37ba5f4566f | f2f7413f9c683194253f7ea9286587bad3058396 | refs/heads/master | 2023-04-04T07:26:19.917166 | 2021-04-16T11:51:59 | 2021-04-16T11:51:59 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,320 | py | import os
import statistics
from sklearn.model_selection import train_test_split
from examples.english.transformer_configs import transformer_config, MODEL_TYPE, MODEL_NAME, LANGUAGE_FINETUNE, \
language_modeling_args, TEMP_DIRECTORY
from mudes.algo.evaluation import f1
from mudes.algo.mudes_model import MUDESMod... | [
"rhtdranasinghe@gmail.com"
] | rhtdranasinghe@gmail.com |
7d7114b73f7531d5ead27980f9e0b3608c42a9a3 | c64dd4b7f67d1f3c6ade8404831676a3652963e4 | /dask_drmaa/sge.py | 0ec11dacb016ef01325f45ed1814c9faf8b51b02 | [] | no_license | mrocklin/dask-drmaa | 6921a59bf29fd2c5e082dd0aad9bdf1f1e0f1806 | 71bd87c8c11a759f2495139e3b613421e7ba4986 | refs/heads/master | 2021-05-01T20:29:12.752914 | 2017-01-18T13:20:26 | 2017-01-18T13:20:26 | 79,346,877 | 3 | 0 | null | 2017-01-18T14:18:45 | 2017-01-18T14:18:45 | null | UTF-8 | Python | false | false | 1,210 | py | from .core import DRMAACluster, get_session
class SGECluster(DRMAACluster):
default_memory = None
default_memory_fraction = 0.6
def createJobTemplate(self, nativeSpecification='', cpus=1, memory=None,
memory_fraction=None):
memory = memory or self.default_memory
memory_fraction... | [
"mrocklin@gmail.com"
] | mrocklin@gmail.com |
d2c7ab03478503220cdf8c286f1feb0daed10e8a | cad5b92686d48a2e06766b5d3d671eb41083b825 | /microcosm_pubsub/tests/test_decorators.py | b0e88c4ccf382cd9d7abde003189d5cc6f2b313e | [
"Apache-2.0"
] | permissive | lior001/microcosm-pubsub | 8166b4596c04d78330f2ceca31f2827d272ec6ae | eeea8409c1f89a6c420fdf42afcc92b1d69d0e11 | refs/heads/develop | 2020-12-31T00:09:54.584041 | 2017-02-08T18:51:23 | 2017-02-08T18:51:23 | 86,563,543 | 0 | 0 | null | 2017-03-29T09:29:54 | 2017-03-29T09:29:54 | null | UTF-8 | Python | false | false | 1,016 | py | """
Decorator tests.
"""
from hamcrest import (
assert_that,
equal_to,
instance_of,
is_,
)
from marshmallow import fields, Schema
from microcosm.api import create_object_graph
from microcosm_pubsub.decorators import handles, schema
@schema
class TestSchema(Schema):
MEDIA_TYPE = "test"
test ... | [
"jesse.myers@globality.com"
] | jesse.myers@globality.com |
c0433ae54e1875d6032f2bb5e76a991006e302f1 | a867b1c9da10a93136550c767c45e0d8c98f5675 | /LC_yelp_14_Longest_Common_Prefix.py | d27e5697bb4aff657ed6b1ef3ff7795167d9a246 | [] | no_license | Omkar02/FAANG | f747aacc938bf747129b8ff35b6648fb265d95b6 | ee9b245aa83ea58aa67954ab96442561dbe68d06 | refs/heads/master | 2023-03-25T19:45:08.153403 | 2021-03-28T07:13:08 | 2021-03-28T07:13:08 | 280,783,785 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 504 | py | # import __main__ as main
# from Helper.TimerLogger import CodeTimeLogging
# fileName = main.__file__
# fileName = fileName.split('\\')[-1]
# CodeTimeLogging(Flag='F', filename=fileName, Tag='String', Difficult='Easy')
def longoestCommonPrefix(strs):
strs = list(zip(*strs))
ans = ''
for s in strs:
... | [
"omkarjoshi4031@live.com"
] | omkarjoshi4031@live.com |
dcffb14f17f4fb9194a97de500c404736ef0cec9 | edfd1db2b48d4d225bc58be32fbe372a43415112 | /3. Airflow Fundamentals 3/exercises/lesson3.exercise6.py | e5c543342b90982555c56e162aa19390c2e9af9f | [] | no_license | rwidjojo/airflow-training | ed83cb9e97ca85ef06de1426f2f41014881a1f22 | ac82040d8ddc3859df5576eee08d397e824016f1 | refs/heads/main | 2023-08-12T21:01:17.672059 | 2021-01-04T09:17:48 | 2021-01-04T09:17:48 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 638 | py | import airflow
from airflow import DAG
from airflow.utils.dates import days_ago
from airflow.operators.bash_operator import BashOperator
owner = 'john_doe' # Replace with your short name
default_args = {
'owner': owner,
'depends_on_past': False,
'start_date': days_ago(2),
}
dag = DAG(
dag_id=f'{owner}... | [
"nurcahyopujo@gmail.com"
] | nurcahyopujo@gmail.com |
3e4ac973d2c8a00ad85ba4f40d23f66a548805d7 | e89f44632effe9ba82b940c7721cad19a32b8a94 | /text2shorthand/shorthand/svsd/nakatta.py | 23f660a4c9c066fff1b7352e466d935597403401 | [] | no_license | Wyess/text2shorthand | 3bcdb708f1d7eeb17f9ae3181c4dd70c65c8986e | 5ba361c716178fc3b7e68ab1ae724a57cf3a5d0b | refs/heads/master | 2020-05-17T14:52:11.369058 | 2019-08-20T12:50:00 | 2019-08-20T12:50:00 | 183,776,467 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,870 | py | from ..svsd.char import SvsdChar
from text2shorthand.common.point import Point as P, PPoint as PP
import pyx
from pyx.metapost.path import (
beginknot,
knot,
endknot,
smoothknot,
tensioncurve,
controlcurve,
curve)
class CharNakatta(SvsdChar):
def __init__(self, name='なかった', kana='nakatt... | [
"diyhacker@mail.goo.ne.jp"
] | diyhacker@mail.goo.ne.jp |
c1d36397e7e64ebf831efb5633fa13e307f25556 | f883b2ccb4bf6d527f31fca1f1748e8aa5f17f3a | /web/app/social_auth/urls.py | 2a6e7402dd2d88391b4a3b7b449e536511f5e311 | [] | no_license | nikolaykhodov/liketools | a710faa7fe31cd72df8299829bcc89d16a8d2721 | 65b4a046c3180eec3af0fa709f23bb12975dfe1c | refs/heads/master | 2021-01-10T18:35:08.586890 | 2014-03-31T12:41:50 | 2014-03-31T12:41:50 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 459 | py | # -*- coding: utf-8 -*-
from django.conf.urls.defaults import patterns, url
from social_auth.views import VkAuthView, LoginView, LogoutView, KvSetView
urlpatterns = patterns('',
url(r'^login/$', LoginView.as_view(), name='social_auth_login'),
url(r'^logout/$', LogoutView.as_view(), name='social_auth_logout'),... | [
"nkhodov@gmail.com"
] | nkhodov@gmail.com |
65c5dc7ecc967754e6eb46de86e6f915461f2ea1 | d0af9f544b76e1df4f8ffb6c65a3da1fe13c5871 | /setup.py | c10007500e179356be10008723c3f04774009beb | [
"MIT"
] | permissive | vanadium23/doc484 | 472a90ad08352891aa3ed9526375aebad71f3d16 | ff8058f07e6cba8f26e7ce48ef4dd42203dc065a | refs/heads/master | 2020-03-29T20:54:44.503542 | 2018-09-25T22:55:08 | 2018-09-25T22:55:08 | 150,338,332 | 0 | 0 | MIT | 2018-09-25T22:48:16 | 2018-09-25T22:48:16 | null | UTF-8 | Python | false | false | 1,730 | py | from setuptools import setup, find_packages
import os.path
HERE = os.path.abspath(os.path.dirname(__file__))
def read(*parts):
with open(os.path.join(HERE, *parts)) as f:
return f.read()
setup(
name="doc484",
version="0.2.0",
author="Chad Dombrova",
description="Generate PEP 484 type co... | [
"chadrik@gmail.com"
] | chadrik@gmail.com |
fad7b7f80e12f72ca4a0827c794f7b6a156be69f | 7eb606a7957e5500f163c93dc4b19418cf9cf335 | /examples/lbfgs/model.py | d68967e5e2c64b3f598e36263ab1e7edc2e6d907 | [
"Apache-2.0",
"MIT"
] | permissive | ludwig-ai/ludwig | 024f74da86567a57ec8e30efcb4600f0c52333a1 | e1d023e41606c9b76b35e1d231c2f13368a30eca | refs/heads/master | 2023-09-03T08:07:32.978301 | 2023-09-01T19:39:32 | 2023-09-01T19:39:32 | 163,346,054 | 2,567 | 285 | Apache-2.0 | 2023-09-14T20:34:52 | 2018-12-27T23:58:12 | Python | UTF-8 | Python | false | false | 1,033 | py | import logging
import pandas as pd
from ludwig.api import LudwigModel
from ludwig.datasets import amazon_employee_access_challenge
df = amazon_employee_access_challenge.load()
model = LudwigModel(config="config.yaml", logging_level=logging.INFO)
training_statistics, preprocessed_data, output_directory = model.trai... | [
"noreply@github.com"
] | ludwig-ai.noreply@github.com |
a5124967f629b267a5314e52eda661da43dc0c9a | aba1d17ddc7d7ad9f49e2d6d87600e9e0387ba14 | /mi/dataset/driver/dosta_abcdjm/cspp/dosta_abcdjm_cspp_telemetered_driver.py | 6f3ee50a7855782d946f895365a65c2d76667fb4 | [
"BSD-2-Clause",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | oceanobservatories/mi-instrument | 3ad880c1366b1a8461fc9085768df0e9ddeb6ef5 | bdbf01f5614e7188ce19596704794466e5683b30 | refs/heads/master | 2023-07-23T07:28:36.091223 | 2023-07-14T15:54:49 | 2023-07-14T15:54:49 | 24,165,325 | 1 | 32 | BSD-2-Clause | 2023-07-13T01:39:22 | 2014-09-17T22:53:22 | Python | UTF-8 | Python | false | false | 2,147 | py | """
@package mi.dataset.driver.dosta_abcdjm.cspp
@file mi.dataset.driver.dosta_abcdjm.cspp.dosta_abcdjm_cspp_telemetered_driver.py
@author Emily Hahn
@brief Telemetered driver for the dosta series abcdjm instrument through cspp
"""
__author__ = 'ehahn'
from mi.core.log import get_logger
log = get_logger()
from mi.da... | [
"petercable@gmail.com"
] | petercable@gmail.com |
b9f78075d182ca9e57ef766de03b49e5e67b83e3 | 5ae3bc1920fafc33693cdfa3928a48158aa6f725 | /339/339.py | 3ae587496c391a69889871704c55b71a5fa45463 | [] | no_license | sjzyjc/leetcode | 2d0764aec6681d567bffd8ff9a8cc482c44336c2 | 5e09a5d36ac55d782628a888ad57d48e234b61ac | refs/heads/master | 2021-04-03T08:26:38.232218 | 2019-08-15T21:54:59 | 2019-08-15T21:54:59 | 124,685,278 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,912 | py | # """
# This is the interface that allows for creating nested lists.
# You should not implement it, or speculate about its implementation
# """
#class NestedInteger:
# def __init__(self, value=None):
# """
# If value is not specified, initializes an empty list.
# Otherwise initializes a single i... | [
"jcyang@MacBook-Air.local"
] | jcyang@MacBook-Air.local |
264486e6a67a5bd97d1e2a4f5fe5a9d2793e581e | 60ca69e2a4c6b05e6df44007fd9e4a4ed4425f14 | /beginner_contest/072/C.py | 080a37ff02695427c7499db8c51223bd96de0bd5 | [
"MIT"
] | permissive | FGtatsuro/myatcoder | 12a9daafc88efbb60fc0cd8840e594500fc3ee55 | 25a3123be6a6311e7d1c25394987de3e35575ff4 | refs/heads/master | 2021-06-13T15:24:07.906742 | 2021-05-16T11:47:09 | 2021-05-16T11:47:09 | 195,441,531 | 0 | 0 | MIT | 2021-05-16T11:47:10 | 2019-07-05T16:47:58 | Python | UTF-8 | Python | false | false | 320 | py | import sys
input = sys.stdin.readline
sys.setrecursionlimit(10 ** 7)
n = int(input())
a = list(map(int, input().split()))
t = [0] * (max(a) + 1)
for v in a:
t[v] += 1
if max(a) <= 1:
print(sum(t))
sys.exit(0)
ans = 0
for i in range(0, max(a) - 1):
ans = max(ans, t[i] + t[i+1] + t[i+2])
print(ans)
| [
"204491+FGtatsuro@users.noreply.github.com"
] | 204491+FGtatsuro@users.noreply.github.com |
0c52af3d9af2fa22e731c5bf98e9226c2a7b2245 | b2b79cc61101ddf54959b15cf7d0887d114fb4e5 | /web/pgadmin/browser/server_groups/servers/databases/schemas/tables/tests/test_table_get_script_sql.py | bfd9c1ad7926ca39adec0ae5ed46e473f8192970 | [
"PostgreSQL"
] | permissive | 99Percent/pgadmin4 | 8afe737eb2ec1400ab034ad1d8a4f7c4ba4c35c8 | 5e0c113c7bc4ffefbec569e7ca5416d9acf9dd8a | refs/heads/master | 2021-10-10T20:08:48.321551 | 2021-09-30T12:51:43 | 2021-09-30T12:51:43 | 165,702,958 | 0 | 0 | NOASSERTION | 2019-01-14T17:18:40 | 2019-01-14T17:18:39 | null | UTF-8 | Python | false | false | 4,072 | py | ##########################################################################
#
# pgAdmin 4 - PostgreSQL Tools
#
# Copyright (C) 2013 - 2021, The pgAdmin Development Team
# This software is released under the PostgreSQL Licence
#
##########################################################################
import uuid
from ... | [
"akshay.joshi@enterprisedb.com"
] | akshay.joshi@enterprisedb.com |
48fae7769117066bc7dbba45df7955795e600155 | 1677eaad65da601a3ac34bd6648c973ffd23c5a9 | /test/test_payment_intent.py | 96a16f7f0e080de4c3970d1af68af0c32eebc622 | [] | no_license | jeffkynaston/sdk-spike-python | dc557cc1557387f8a126cd8e546201d141de535e | f9c65f578abb801ffe5389b2680f9c6ed1fcebd3 | refs/heads/main | 2023-07-10T00:58:13.864373 | 2021-08-05T21:38:07 | 2021-08-05T21:38:07 | 393,175,147 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,307 | py | """
Plastiq Public API
No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501
The version of the OpenAPI document: 1.0.0
Generated by: https://openapi-generator.tech
"""
import sys
import unittest
import openapi_client
from openapi_c... | [
"jeff.kynaston@plastiq.com"
] | jeff.kynaston@plastiq.com |
c4b8382cde9c3442aad8576c605f4e3165a4187c | cb3583cc1322d38b1ee05cb1c081e0867ddb2220 | /home/0024_auto_20210409_1103.py | 6dfdc8917586768f05e72645b5ee96b68f7f94cc | [
"MIT"
] | permissive | iamgaddiel/codeupblood | 9e897ff23dedf5299cb59fd6c44d9bd8a645e9c6 | a0aa1725e5776d80e083b6d4e9e67476bb97e983 | refs/heads/main | 2023-05-07T23:34:27.475043 | 2021-04-24T20:49:08 | 2021-04-24T20:49:08 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,718 | py | # Generated by Django 3.1.6 on 2021-04-09 18:03
from django.db import migrations, models
import tagulous.models.fields
import tagulous.models.models
class Migration(migrations.Migration):
dependencies = [
('home', '0023_auto_20210409_0900'),
]
operations = [
migrations.AlterField(
... | [
"www.spbiology@gmail.com"
] | www.spbiology@gmail.com |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.