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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
3c6ef5ab0efd64646da6bb20b1a0a4dbe7ed9d52 | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p03427/s581758715.py | e0f6f58c743a818c6bcf68751f6112a9ffbc4167 | [] | no_license | Aasthaengg/IBMdataset | 7abb6cbcc4fb03ef5ca68ac64ba460c4a64f8901 | f33f1c5c3b16d0ea8d1f5a7d479ad288bb3f48d8 | refs/heads/main | 2023-04-22T10:22:44.763102 | 2021-05-13T17:27:22 | 2021-05-13T17:27:22 | 367,112,348 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 157 | py | N = input().strip()
k = len(N)
cmax = 0
for i in range(k):
cmax += int(N[i])
if k>1:
cnt = (int(N[0])-1)+9*(k-1)
cmax = max(cmax,cnt)
print(cmax) | [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
024d7c9d22a9d10759f9603ccacb53f3aac364fd | 0104add04cd6da515e2ccb2c27e44bc6693f9bcf | /Yurii_Khomych/l_1_functions/currying_2.py | c3cd7ebafac18d91b79596981f4c1728f815323c | [] | no_license | YuriiKhomych/ITEA-advanced | c96c3cf9b279caf62fefcd41faf543cee7534626 | 90bc47733c07b5b866aa3a14aa12a169f5df289c | refs/heads/master | 2022-12-09T20:38:23.607426 | 2019-12-22T17:30:59 | 2019-12-22T17:30:59 | 209,354,034 | 0 | 9 | null | 2022-12-08T03:04:04 | 2019-09-18T16:23:12 | Python | UTF-8 | Python | false | false | 854 | py |
def change(func_1, func_2, func_3):
def inner_func(arg):
return func_1(func_2(func_3(arg)))
return inner_func
def kilometer2meter(dist):
""" Function that converts km to m. """
return dist * 1000
def meter2centimeter(dist):
""" Function that converts m to cm. """
return dist * 100
... | [
"yuriykhomich@gmail.com"
] | yuriykhomich@gmail.com |
f2061a6cc57c32db6bff0cdc2dfda4b0d2a2a292 | 5d027f4d32fc503212a824355ef45295e6df90b5 | /Homework/HW-Scheduler/HW-Scheduler/scheduler.py | 59e134b93c656a04b20b187861469354df0c6331 | [] | no_license | M1c17/OP_three_easy_steps | c99fa0a9214e42e8b44df14e84125c034b9cb1f3 | ea6190c55358d027169e7911bebd7aa6f2b56dff | refs/heads/master | 2022-12-18T22:25:52.055978 | 2020-09-15T03:10:19 | 2020-09-15T03:10:19 | 295,588,135 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,799 | py | #! /usr/bin/env python
import sys
from optparse import OptionParser
import random
parser = OptionParser()
parser.add_option("-s", "--seed", default=0, help="the random seed",
action="store", type="int", dest="seed")
parser.add_option("-j", "--jobs", default=3, help="number of jobs in the system",
... | [
"pictor117@gmail.com"
] | pictor117@gmail.com |
f940347b0a46dad50d1d229095586c5651621a8f | 397e125e94f4f139f2bf5055824d81f24b8b1757 | /ABC/138/E.py | 90a94533e38572141fe743f2f69457c94250fa59 | [] | no_license | tails1434/Atcoder | ecbab6ee238e3f225551297db961b1b502841fa4 | e7c7fed36be46bbaaf020a70997842240ba98d62 | refs/heads/master | 2021-07-07T00:31:49.235625 | 2020-09-30T01:42:01 | 2020-09-30T01:42:01 | 189,009,622 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 606 | py | from collections import defaultdict
from bisect import bisect_right
def main():
S = input()
T = input()
d = defaultdict(list)
for i, s in enumerate(S):
d[s].append(i+1)
pre = 0
cnt = 0
loop = 0
len_S = len(S)
for t in T:
if not d[t]:
print(-1)
... | [
"sososo1333@gmail.com"
] | sososo1333@gmail.com |
dbd2baaba12c468d6326baad9fc89420ad6d9071 | 388556baa0c2ee53d8767ae8a4bce18c03124488 | /Chapter11/0017_difference_between_abstraction_encapsulation.py | 0a946d6f97028efc1ea5384b7d8c3e1eb976d848 | [] | no_license | 8563a236e65cede7b14220e65c70ad5718144a3/introduction-python-programming-solutions | 6e2e7c8cf8babc3c63f75d8d5e987f4dbc018269 | f21d70ae2062cc2d5d3a2fefce81a2a3b4ea3bfd | refs/heads/master | 2022-12-10T04:24:56.364629 | 2020-07-01T11:34:01 | 2020-07-01T11:34:01 | 294,878,260 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 328 | py | """
Program 11.13
Demonstrate the Difference between Abstraction and Encapsulation
"""
class foo:
def __init__(self, a, b):
self.a = a
self.b = b
def add(self):
return self.a + self.b
def main():
foo_object = foo(3, 4)
print(foo_object.add())
if __name__ == "__main__":
... | [
"warren.jitsing@gmail.com"
] | warren.jitsing@gmail.com |
9af8fb8a7ef155427b16305335e2b3c950d6b53b | 61050d0d7f0c0a60474e4e85d30be4e5ea7c6b04 | /content/components/dom-access/job.odb | 3c76a64ef3a81dd1ef07fb2572060e156f42bdc7 | [] | no_license | danse-inelastic/vnf | 8173f06f32b4a2fa2b71fddfe0fecf9c19e05e9a | be989448577f14f424aca4ce852c7198304ca57b | refs/heads/master | 2021-01-22T01:06:00.294100 | 2015-05-02T23:25:45 | 2015-05-02T23:25:45 | 34,947,878 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 5,779 | odb | # -*- Python -*-
#
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#
# Jiao Lin
# California Institute of Technology
# (C) 2006-2009 All Rights Reserved
#
# {LicenseText}
#
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~... | [
"linjiao@caltech.edu"
] | linjiao@caltech.edu |
8885c933ea131e903feb51fe6f4dbc4537a88af7 | a2d36e471988e0fae32e9a9d559204ebb065ab7f | /huaweicloud-sdk-meeting/huaweicloudsdkmeeting/v1/model/qos_send_receive_info.py | 7b4a4548e2c3a10bc21c875febcbe1d7b61af84f | [
"Apache-2.0"
] | permissive | zhouxy666/huaweicloud-sdk-python-v3 | 4d878a90b8e003875fc803a61414788e5e4c2c34 | cc6f10a53205be4cb111d3ecfef8135ea804fa15 | refs/heads/master | 2023-09-02T07:41:12.605394 | 2021-11-12T03:20:11 | 2021-11-12T03:20:11 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,634 | py | # coding: utf-8
import re
import six
from huaweicloudsdkcore.utils.http_utils import sanitize_for_serialization
class QosSendReceiveInfo:
"""
Attributes:
openapi_types (dict): The key is attribute name
and the value is attribute type.
attribute_map (dict): The key... | [
"hwcloudsdk@huawei.com"
] | hwcloudsdk@huawei.com |
db126458e075c35c3a9606d6dc1f54e18b85536e | d4442db5a7ab9db2b04fef640a9864f3fba54758 | /src/python/WMCore/RequestManager/RequestDB/Oracle/Group/GetGroupFromAssoc.py | 3549961c0b5eea9816bb43e00f98608494e976f0 | [] | no_license | stuartw/WMCore | fa25ff19ab5058a635d35d3c58a0ac56a3e079a1 | 38c39c43f7237fd316930839674ac9be3c0ee8cc | refs/heads/master | 2021-01-18T07:18:18.324604 | 2012-10-18T22:30:34 | 2012-10-18T22:30:34 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 180 | py | from WMCore.RequestManager.RequestDB.MySQL.Group.GetGroupFromAssoc import GetGroupFromAssoc as GetGroupFromAssocMySQL
class GetGroupFromAssoc(GetGroupFromAssocMySQL):
pass | [
"metson@4525493e-7705-40b1-a816-d608a930855b"
] | metson@4525493e-7705-40b1-a816-d608a930855b |
dfcf388075f9499cfdaf3e385b9bec1af4308eb3 | 3aef4825c5f2366f2e551cdfa54b88c034b0b4f4 | /tutorials/2_tensorflow_old/matplotlibTUT/plt14_3d.py | d742a0cd4768afe2bb32c874c3cc31368aaf5fd1 | [
"MIT"
] | permissive | wull566/tensorflow_demo | 4a65cbe1bdda7430ab1c3883889501a62258d8a6 | c2c45050867cb056b8193eb53466d26b80b0ec13 | refs/heads/master | 2020-04-06T17:34:05.912164 | 2018-11-15T07:41:47 | 2018-11-15T07:41:48 | 157,665,187 | 3 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,233 | py | # View more 3_python 2_tensorflow_old on my Youtube and Youku channel!!!
# Youtube video tutorial: https://www.youtube.com/channel/UCdyjiB5H8Pu7aDTNVXTTpcg
# Youku video tutorial: http://i.youku.com/pythontutorial
# 14 - 3d
"""
Please note, this script is for python3+.
If you are using python2+, please modify it acco... | [
"vicleo566@163.com"
] | vicleo566@163.com |
09948ecbf8dce75fc191482b02c52f34414e2dd2 | eea1c66c80784d4aefeb0d5fd2e186f9a3b1ac6e | /atcoder/AGC/agc037/agc037_a.py | 0a81674be640dbd4e2a9a68795fce2f0fa83a027 | [] | no_license | reo11/AtCoder | 4e99d6f40d8befe264761e3b8c33d3a6b7ba0fe9 | 69c6d67f05cb9190d8fb07204488cd7ce4d0bed2 | refs/heads/master | 2023-08-28T10:54:50.859288 | 2023-08-22T18:52:47 | 2023-08-22T18:52:47 | 162,085,118 | 4 | 0 | null | 2023-07-01T14:17:28 | 2018-12-17T06:31:10 | Python | UTF-8 | Python | false | false | 205 | py | s = str(input())
count = 1
pre = s[0]
now = ""
for i in range(1, len(s)):
now += s[i]
if pre == now:
continue
else:
count += 1
pre = now
now = ""
print(count)
| [
"reohirao116@gmail.com"
] | reohirao116@gmail.com |
3948a716848ac63fa942f4ff68789df1d13eec70 | 342ec51a35eef43fe1bafa31bdf8f0c9ef956cd9 | /comlib.py | 2ef51158ec9e1743618a2ad4d19ab834c1795910 | [
"MIT"
] | permissive | Strangemother/python-simple-tts-stt | a60ff7ce4e4b9dd58a3a906c7a8c266b0dc6bb2a | e7ac38e795b32f55367a58107d86bf04ea906f0c | refs/heads/master | 2020-03-21T10:18:41.407181 | 2019-01-02T07:32:24 | 2019-01-02T07:32:24 | 138,444,505 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 530 | py | import speech
import comtypes.client # Importing comtypes.client will make the gen subpackage
import os
try:
assert(os.name == 'nt') # Checks for Windows
except:
raise RuntimeError("Windows is required.")
try:
from comtypes.gen import SpeechLib # comtypes
except ImportError:
# Genera... | [
"jay@strangemother.com"
] | jay@strangemother.com |
5c82f1295336f62ee18d4ca09a43169108808919 | 2bb90b620f86d0d49f19f01593e1a4cc3c2e7ba8 | /pardus/tags/2007-EOL/applications/hardware/bluez-utils/actions.py | 998201a4580feb5fd60d2b947e9349576906fa8d | [] | no_license | aligulle1/kuller | bda0d59ce8400aa3c7ba9c7e19589f27313492f7 | 7f98de19be27d7a517fe19a37c814748f7e18ba6 | refs/heads/master | 2021-01-20T02:22:09.451356 | 2013-07-23T17:57:58 | 2013-07-23T17:57:58 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,287 | py | #!/usr/bin/python
# -*- coding: utf-8 -*-
#
# Copyright 2005-2008 TUBITAK/UEKAE
# Licensed under the GNU General Public License, version 2.
# See the file http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt
from pisi.actionsapi import autotools
from pisi.actionsapi import pisitools
from pisi.actionsapi import get
de... | [
"yusuf.aydemir@istanbul.com"
] | yusuf.aydemir@istanbul.com |
07896960fbc3c364f8fa514f19481ea4d06edca5 | ae10b60cb92a69146bfb05ef5dde735a0aa45d4b | /examples/New Functions/Example distance 1.py | 2d8b3d0afa43d6027b21ee429f3c43c74def211d | [
"MIT"
] | permissive | kantel/nodebox-pyobjc | 471cea4c5d7f1c239c490323186458a74edcc214 | 068ba64c87d607522a240ab60c3ba14f869f6222 | refs/heads/master | 2021-08-14T18:32:57.995445 | 2017-11-16T13:42:23 | 2017-11-16T13:42:23 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 982 | py | import math
def params(val, name):
global x, y
# global scope needs updating.
val = int(round(val,0))
if name == "x":
x = int(val)
else:
y = int(val)
triangle(x, y)
def triangle(x, y):
x0, y0 = 100, 160
x1, y1 = x0 + x, y0
x2, y2 = x0, y0 + y
# draw a trian... | [
"karstenwo@web.de"
] | karstenwo@web.de |
9216428587f42a0e67dbf4b9393da0b0e71f9cdc | 82b946da326148a3c1c1f687f96c0da165bb2c15 | /sdk/python/pulumi_azure_native/apimanagement/v20201201/get_content_item.py | 839b7064a377f6a60900dac782fc801a0b858684 | [
"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 | 3,523 | 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 |
c23e4d616602f79d9d239eacb7e8558f1639d2ff | e59602b7e17fafff70240700138bbe54ced28739 | /PythonSimpleVisualiser.py | 152c3204cf353fff3ddeab2c45ec43bdd5770b29 | [] | no_license | TestSubjector/CompGeometry2 | ddc3dae8517e45d419e7057f2d905ad5d95d67e7 | 3b7f30302c837d883132290789cd84305f0e0b10 | refs/heads/master | 2022-03-27T13:37:46.115463 | 2019-04-03T18:18:48 | 2019-04-03T18:18:48 | 177,393,551 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,173 | py | ## Takes input from a text file and plots all points.
## Connects the points in order read and connects last point to first one.
import argparse
import matplotlib.pyplot as plt
def getArgParser():
''' Returns ArgParser object to handle command-line args'''
parser = argparse.ArgumentParser()
parser.add_argu... | [
"f2015845@hyderabad.bits-pilani.ac.in"
] | f2015845@hyderabad.bits-pilani.ac.in |
95621f79a92dc69d3ca8f9ac1482bf81b28cb8fa | 9cd180fc7594eb018c41f0bf0b54548741fd33ba | /sdk/python/pulumi_azure_nextgen/web/v20181101/get_web_app_function.py | f035db040d58335774ba7aec281ac9825034db4b | [
"Apache-2.0",
"BSD-3-Clause"
] | permissive | MisinformedDNA/pulumi-azure-nextgen | c71971359450d03f13a53645171f621e200fe82d | f0022686b655c2b0744a9f47915aadaa183eed3b | refs/heads/master | 2022-12-17T22:27:37.916546 | 2020-09-28T16:03:59 | 2020-09-28T16:03:59 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,319 | 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
__a... | [
"public@paulstack.co.uk"
] | public@paulstack.co.uk |
5fbbbba6af3dfcfca89cb54da6713158b0a6ecbd | 4e60e8a46354bef6e851e77d8df4964d35f5e53f | /main.py | ae35090fa53b38726ed25a70d0f2454551d2dee5 | [] | no_license | cq146637/DockerManagerPlatform | cbae4154ad66eac01772ddd902d7f70b62a2d856 | 9c509fb8dca6633ed3afdc92d4e6491b5d13e322 | refs/heads/master | 2021-04-09T13:58:14.117752 | 2018-03-19T13:41:04 | 2018-03-19T13:41:04 | 125,712,276 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 773 | py | # -*- coding: utf-8 -*-
__author__ = 'CQ'
import os
import sys
import tornado.httpserver
import tornado.ioloop
import tornado.options
import tornado.web
from settings import settings
from url.urls import urls
from tornado.options import define, options, parse_command_line
define("port", default=8888, help="run on the... | [
"1016025625@qq.com"
] | 1016025625@qq.com |
080f45148a5f23811232fe76aaf7c83e197d9bfb | e8eb2cecee1ebc47455917fa11a58e7b5a912b74 | /python_lessons/python_advanced_02_tic_tac_toe/app/model/game.py | c5b61a7de11ddc51661518c76607cd7bc169970c | [] | no_license | cyr1z/python_education | ad0f9e116536a5583a12e05efe41ee173639ea9c | 37b2edbccf6f96c59c14cabf4bf749a3ec0f503d | refs/heads/main | 2023-06-08T10:24:26.217582 | 2021-06-27T17:02:05 | 2021-06-27T17:02:05 | 359,467,674 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 924 | py | """
Game module.
"""
from app.model.table import GameTable
from app.view.table_view import TableView
class Game:
"""
Game play class
"""
def __init__(self, numbers_map, player1, player2):
self.table = GameTable(numbers_map)
self.players = []
self.players.append(player1)
... | [
"cyr@zolotarev.pp.ua"
] | cyr@zolotarev.pp.ua |
093b8ea7593c9c1b921e251e644de80e43c8a9f9 | ae12996324ff89489ded4c10163f7ff9919d080b | /LeetCodePython/DesignaTextEditor.py | 3f9a03e8ddcfd31fcc7ef5243000df664c94c4e6 | [] | no_license | DeanHe/Practice | 31f1f2522f3e7a35dc57f6c1ae74487ad044e2df | 3230cda09ad345f71bb1537cb66124ec051de3a5 | refs/heads/master | 2023-07-05T20:31:33.033409 | 2023-07-01T18:02:32 | 2023-07-01T18:02:32 | 149,399,927 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 4,725 | py | """
Design a text editor with a cursor that can do the following:
Add text to where the cursor is.
Delete text from where the cursor is (simulating the backspace key).
Move the cursor either left or right.
When deleting text, only characters to the left of the cursor will be deleted. The cursor will also remain within... | [
"tengda.he@gmail.com"
] | tengda.he@gmail.com |
983d4615eb75145cbb024178a9271475c82399be | 29a38674cd5cda4880d539ee235ea118b750571e | /tests/flit_cli/flit_update/tst_badconfig.py | 495501f01a3766375523bcada2ceebbb585b41c1 | [] | no_license | hbrunie/FLiT | 1f0be509f776b86380b215b30e7b365921dd3425 | 836bc3cd2befebc9cfe20926fd855b1f5d29ae17 | refs/heads/master | 2020-07-09T20:26:40.644089 | 2019-04-10T18:47:25 | 2019-04-10T18:47:25 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,702 | py | # -- LICENSE BEGIN --
#
# Copyright (c) 2015-2018, Lawrence Livermore National Security, LLC.
#
# Produced at the Lawrence Livermore National Laboratory
#
# Written by
# Michael Bentley (mikebentley15@gmail.com),
# Geof Sawaya (fredricflinstone@gmail.com),
# and Ian Briggs (ian.briggs@utah.edu)
# under the direct... | [
"mikebentley15@gmail.com"
] | mikebentley15@gmail.com |
b255fdf34e22a4165490cdca3b6a1c6e64f12f1d | 8d2a124753905fb0455f624b7c76792c32fac070 | /pytnon-month01/month01-shibw-notes/day08-shibw/demo02-函数实参传递方式.py | 8552c39f1fd88ff02da5f27af317be220d475eb2 | [] | no_license | Jeremy277/exercise | f38e4f19aae074c804d265f6a1c49709fd2cae15 | a72dd82eb2424e4ae18e2f3e9cc66fc4762ec8fa | refs/heads/master | 2020-07-27T09:14:00.286145 | 2019-09-17T11:31:44 | 2019-09-17T11:31:44 | 209,041,629 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,069 | py | '''
函数传参
实参传递方式
'''
def fun01(a,b,c):#形参 a b c
print(a)
print(b)
print(c)
#位置实参 实参是根据位置与形参对应的
#如果实参位置发生改变 会影响函数结果
# fun01(10,20,30)
# fun01(30,10,20)
#序列实参 用*将序列中的元素拆开然后与形参依次对应
#序列 字符串 列表 元组
list01 = [10,20,30]
fun01(*list01)
# str01 = 'abcd'
# fun01(*str01)#报错
#关键字实参
#实参的值与形参的名称对应
# fun01(a=10,b=20,c=... | [
"13572093824@163.com"
] | 13572093824@163.com |
4153e5a0a7053f1238faf6b9925f4b00dfa351d3 | 3f4f2bb867bf46818802c87f2f321a593f68aa90 | /smile/bin/cftp | f013e4cd473d18741239a41ee15b8ee6fe9ecd80 | [] | no_license | bopopescu/Dentist | 56f5d3af4dc7464544fbfc73773c7f21a825212d | 0122a91c1f0d3d9da125234a8758dea802cd38f0 | refs/heads/master | 2022-11-23T12:42:23.434740 | 2016-09-19T15:42:36 | 2016-09-19T15:42:36 | 282,608,405 | 0 | 0 | null | 2020-07-26T08:30:16 | 2020-07-26T08:30:16 | null | UTF-8 | Python | false | false | 358 | #!/SHARED-THINGS/ONGOING/We.smile/smile/bin/python
# Copyright (c) Twisted Matrix Laboratories.
# See LICENSE for details.
import sys, os
extra = os.path.dirname(os.path.dirname(sys.argv[0]))
sys.path.insert(0, extra)
try:
import _preamble
except ImportError:
sys.exc_clear()
sys.path.remove(extra)
from twiste... | [
"jamaalaraheem@gmail.com"
] | jamaalaraheem@gmail.com | |
ee3a35c8ea73fb5fd4cbd78944d7dd7318dfa7b2 | eb9f655206c43c12b497c667ba56a0d358b6bc3a | /python/helpers/pydev/pydev_tests_python/resources/_debugger_case_set_next_statement.py | 145f36d596c3dbca63ea3726dfa41035f960a000 | [
"EPL-1.0",
"Apache-2.0"
] | permissive | JetBrains/intellij-community | 2ed226e200ecc17c037dcddd4a006de56cd43941 | 05dbd4575d01a213f3f4d69aa4968473f2536142 | refs/heads/master | 2023-09-03T17:06:37.560889 | 2023-09-03T11:51:00 | 2023-09-03T12:12:27 | 2,489,216 | 16,288 | 6,635 | Apache-2.0 | 2023-09-12T07:41:58 | 2011-09-30T13:33:05 | null | UTF-8 | Python | false | false | 169 | py | def method():
a = 1
print('call %s' % (a,))
a = 2
print('call %s' % (a,))
a = 3
if __name__ == '__main__':
method()
print('TEST SUCEEDED!')
| [
"Elizaveta.Shashkova@jetbrains.com"
] | Elizaveta.Shashkova@jetbrains.com |
1da139e0f1926e0aebc7e93d592604dcfb4edf72 | 8d920a35fda0ba351a6fb5e7d6cb2b570d6f1ec6 | /grp_ejecucion_presupuestal/__openerp__.py | 21ef1b0627f49b703a741c5e18df87a2f6e4ca67 | [] | no_license | suningwz/odoo-coreuy | afeb661a1c6bd16e7804f2bd7df9ebe9dda7bab8 | d723860324e3d914a0a44bac14dd83eceefc96fe | refs/heads/master | 2020-09-14T22:43:17.884212 | 2019-07-03T13:48:50 | 2019-07-03T13:48:50 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,555 | py | # -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Enterprise Management Solution
# GRP Estado Uruguay
# Copyright (C) 2017 Quanam (ATEL SA., Uruguay)
#
# This program is free software: you can redistribute it and/or modify
# it... | [
"lcontreras@sofis.com.uy"
] | lcontreras@sofis.com.uy |
cf72b166ab3a1fcf4523e0f20acf976d34f5e402 | ab8187626aa68c1f92301db78e9f8b0c4b088554 | /TwoPointer/75_h.py | a8a07b4bde84c80b9ccb625d2074edf0ebb7ed68 | [] | no_license | khj68/algorithm | 2818f87671019f9f2305ec761fd226e737f12025 | efebe142b9b52e966e0436be3b87fb32b4f7ea32 | refs/heads/master | 2023-04-25T02:33:13.403943 | 2021-05-04T03:09:38 | 2021-05-04T03:09:38 | 287,733,041 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 737 | py | class Solution:
def sortColors(self, nums: List[int]) -> None:
"""
Do not return anything, modify nums in-place instead.
"""
zeroP, twoP = 0, len(nums)-1
i = 0
while i <= twoP:
try:
while nums[zeroP] == 0: zeroP += 1
while n... | [
"maga40@naver.com"
] | maga40@naver.com |
51b14fca6562f512f53b9bd7533a151120bba916 | 128090f08a541eaf52a39bd811147e16fbcd2ef5 | /certificate/hooks.py | 9fd93618a5e0d2acdf2aa4969765c66f2e5bb01a | [
"MIT"
] | permissive | hrgadeha/certificate | e92d420773d2bdfafa641fb1239a38f21db54ee4 | b742679f0002f63a6afd4950b9f20903f9c8dc4b | refs/heads/master | 2020-03-31T12:59:00.530854 | 2018-10-23T07:13:23 | 2018-10-23T07:13:23 | 152,236,987 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 2,849 | py | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from . import __version__ as app_version
app_name = "certificate"
app_title = "Certificate"
app_publisher = "Hardik Gadesha"
app_description = "Custom Certificate for Employee and Company"
app_icon = "octicon octicon-file-directory"
app_color = "grey"
app... | [
"you@example.com"
] | you@example.com |
e69e9f01a37105c49a7d07b7d0f7bf4f565436b7 | 8e3a02a5e104a14a1aa3ba3ba0f05596a9f73757 | /examples/test_gevent.py | 4789c8a0d20458c547189e187018ec4dcc5f1168 | [
"MIT"
] | permissive | jengdal/restkit | 9f114f0f7ded7217cb0c9d405dd1af469c9a918a | e32ff0c3d72415c998353644313bbc02805faa6c | refs/heads/master | 2021-01-18T06:02:55.463294 | 2012-07-19T10:39:32 | 2012-07-19T10:39:32 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 785 | py | import timeit
from gevent import monkey; monkey.patch_all()
import gevent
from restkit import *
from restkit.conn import Connection
from socketpool import ConnectionPool
#set_logging("debug")
pool = ConnectionPool(factory=Connection, backend="gevent")
urls = [
"http://yahoo.fr",
"http://google.com"... | [
"bchesneau@gmail.com"
] | bchesneau@gmail.com |
80b5d59d19dcfbe334c10f0bf90f3ced0118346d | 1804187f39dd6004250933b35ba9ce24297f32a5 | /practice_8_13.py | a00c9a29c89dc4a2064682f2e727369ac0a1010a | [] | no_license | xiaomengxiangjia/Python | ecd2e3e8576364f15482669cb75b52b8790543f5 | 7f52a33d7956068d26347cf34d35c953b945a635 | refs/heads/master | 2020-03-20T23:01:09.981928 | 2018-08-23T09:04:53 | 2018-08-27T05:46:38 | 137,825,481 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 395 | py | def build_profile(first, last, **user_info):
profile = {}
profile['first_name'] = first
profile['last_name'] = last
for key, value in user_info.items():
profile[key] = value
return profile
user_profile = build_profile('benjiming','frankling',
location = 'chengdu',
filed = 'compu... | [
"645334483@qq.com"
] | 645334483@qq.com |
1b7d543aa7cbb7b19a285e7d31a77ff3a6c069a8 | dbfc8ca4dbdef6002b0738dd4c30d569eb9e36c3 | /test/metadata/inbound/plugins/test_plugins_1000_0006_srtm.py | 2d729241c31eb65866a3e9474c3784cc474aaa64 | [] | no_license | GISdeveloper2017/imetadata | da32e35215cc024a2e5d244ee8afc375c296550d | 58516401a054ff0d25bfb244810a37838c4c8cf6 | refs/heads/master | 2023-03-26T06:38:28.721553 | 2021-03-06T09:32:06 | 2021-03-06T09:32:06 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,698 | py | # -*- coding: utf-8 -*-
# @Time : 2020/12/4 09:05
# @Author : 王西亚
# @File : test_plugins_aaa.py
import allure
import pytest
import settings
from imetadata.base.c_file import CFile
from imetadata.base.c_utils import CUtils
from imetadata.business.metadata.base.fileinfo.c_dmFilePathInfoEx import CDMFilePathInfoEx
from i... | [
"18437918096@163.COM"
] | 18437918096@163.COM |
7b795505b76f7218da50a6a9bf53221773d8cfae | 4738be4be8cda375e33ef606dbe82998d6e60bef | /common_nlp/word_histogram_comparison.py | 9cb68293cb5cf094917ad90f252498d2c754186e | [
"MIT"
] | permissive | Arieugon/Pesquisas | 39723d6ee642d50708f4a883b8d13faf5d018c3c | 87e3923c571d44774c36d4bc54e444cb1003b43b | refs/heads/master | 2023-01-21T10:23:53.645736 | 2020-12-02T19:23:48 | 2020-12-02T19:23:48 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,920 | py | from scipy.spatial import distance as dist
try:
from textNormalization import textNormalization
except:
from common_nlp.textNormalization import textNormalization
import numpy as np
class word_histogram_comparison():
def __init__(self):
self.scipy_methods = {
"Euclidean" : dist.euclidean,
"Manhattan" : dist.c... | [
"danilopcarlotti@gmail.com"
] | danilopcarlotti@gmail.com |
72565b8fc05ad482fa524703a4d1c515750710d6 | b66bf5a58584b45c76b9d0c5bf828a3400ecbe04 | /week-03/day-1/hello_dictionary.py | 4019dd86864bc5aa97b59c9b4cbf5f586bf557d3 | [] | no_license | greenfox-velox/szepnapot | 1196dcb4be297f12af7953221c27cd1a5924cfaa | 41c3825b920b25e20b3691a1680da7c10820a718 | refs/heads/master | 2020-12-21T08:11:41.252889 | 2016-08-13T10:07:15 | 2016-08-13T10:07:15 | 58,042,932 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 585 | py | import requests
import re
from bs4 import BeautifulSoup
r = requests.get('http://pocketcultures.com/2008/10/30/say-hello-in-20-languages/')
raw_html = r.text
soup = BeautifulSoup(raw_html, 'html.parser')
strongs = soup("strong")
GREETINGS = {}
hellos = r'\d+\.\s([A-Z]+\s?[A-Z]+.).?'
language = r'\d+.+\–\s([A-Za-z\... | [
"silentpocok@gmail.com"
] | silentpocok@gmail.com |
97070ee6a3ede702c56f5d8433c185084a2ec962 | 15f321878face2af9317363c5f6de1e5ddd9b749 | /solutions_python/Problem_201/2321.py | cef4f2742fcb1a85496d41097792834162b31ccd | [] | 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 | 717 | py | from heapq import *
t = int(input()) # read a line with a single integer
for i in range(1, t + 1):
N, people = [int(s) for s in input().split(" ")]
h = []
heappush(h, 0)
while people:
people -= 1
biggestSpace = N - heappop(h)
if biggestSpace % 2 == 1:
if people == 0:
... | [
"miliar1732@gmail.com"
] | miliar1732@gmail.com |
d924bb3f2ebc12d7519019fe62a01ce3fb6635e0 | dac960516a8b99ec7f0727282c4a9f1e58dcaa22 | /python/samples/v1_x/list_performance_report.py | cc73d135bcc413e5a63cb99be4fec1ea3518e208 | [
"Apache-2.0"
] | permissive | Baldri/googleads-adxbuyer-examples | 948da55e981cb85bfda1e4027beb482f29d1d87a | 285469fe1fff28416d0477c22e59746525694988 | refs/heads/master | 2023-02-22T18:50:29.166146 | 2020-04-17T20:52:22 | 2020-04-17T20:52:22 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,479 | py | #!/usr/bin/python
#
# Copyright 2016 Google Inc. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required b... | [
"msaniscalchi@users.noreply.github.com"
] | msaniscalchi@users.noreply.github.com |
63cccd1521fb66bffc03c4ee7187a82d5af2de60 | 4c10305652193f7b1df8af4dfe28742910f07fcf | /hw/ip/otbn/util/rig/snippet_gen.py | 50d736d4072bbf9555a1219d46d06987be6eb924 | [
"LicenseRef-scancode-unknown-license-reference",
"Apache-2.0"
] | permissive | jake-ke/opentitan | fc162fd3ec2dc3dff7cec6745379ea5aa3d7a5e0 | a7b16226ce13752896a71399910e39c7a5bda88a | refs/heads/master | 2023-07-05T12:38:49.186899 | 2021-01-21T22:38:13 | 2021-01-22T02:16:20 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,802 | py | # Copyright lowRISC contributors.
# Licensed under the Apache License, Version 2.0, see LICENSE for details.
# SPDX-License-Identifier: Apache-2.0
'''A module defining a base class for a snippet generator.
The generators in the ./gens/ subdirectory all derive from this class. To
actually generate some snippets, use t... | [
"rswarbrick@gmail.com"
] | rswarbrick@gmail.com |
4860167b800f06c9498077979e99c03567633e94 | 9737a5e2cfe5521bb9731a356a7639d0dc3692de | /Exercises/week_2_netmiko/exercise6d.py | 88af3c6a3aa08b2bb55ebe967bd9c0ba844d1c91 | [] | no_license | akushnirubc/pyneta | 5c53cbcf42e2450ce6a2d7e6591d671661e84ba0 | ee68205c0b91974ea1cd79b8c06c36ae083fb02c | refs/heads/main | 2023-06-18T18:02:56.242732 | 2021-07-13T21:43:51 | 2021-07-13T21:43:51 | 358,647,513 | 0 | 0 | null | 2021-05-24T21:39:18 | 2021-04-16T15:45:34 | JavaScript | UTF-8 | Python | false | false | 1,272 | py | # Using SSH and netmiko connect to the Cisco4 router. In your device definition, specify both an 'secret' and a 'session_log'. Your device definition should look as follows:
# password = getpass()
# device = {
# "host": "cisco4.lasthop.io",
# "username": "pyclass",
# "password": password,
# "secret": ... | [
"alex.kushnir@ubc.ca"
] | alex.kushnir@ubc.ca |
40355038bf589f532800b1282ca963ededb8e481 | bf0c13d412a7021b299c5e0622e63e72172cf725 | /week1/Hackerrank/easy/finding_percentage.py | 559579e9933496e2810d3b9115a6d038eedc180f | [] | no_license | Alibek120699/BFDjango | 765e734e925041947f607a1d15228309dfa3e647 | eac06c317551c561ffccb44750862972ae11dea3 | refs/heads/master | 2022-12-01T15:49:39.402815 | 2020-04-19T21:09:39 | 2020-04-19T21:09:39 | 233,657,360 | 0 | 0 | null | 2022-11-22T05:49:56 | 2020-01-13T17:50:13 | Python | UTF-8 | Python | false | false | 377 | py | if __name__ == '__main__':
n = int(input())
student_marks = {}
for _ in range(n):
name, *line = input().split()
scores = list(map(float, line))
student_marks[name] = scores
query_name = input()
marks = student_marks[query_name]
total = 0
for i in marks:
total ... | [
"sayakalibek1@gmail.com"
] | sayakalibek1@gmail.com |
4a95586f5e04b017913bbc56e25ca916b195e870 | 9322c270beaf1019328bf14c836d167145d45946 | /raoteh/sampler/_sample_mjp.py | fdab6bbbe2bc9dda67fb576bd4a2b27627ccec95 | [] | no_license | argriffing/raoteh | 13d198665a7a3968aad8d41ddad12c08d36d57b4 | cdc9cce8fdad0a79dbd90dfcdec6feece8fc931f | refs/heads/master | 2021-01-22T19:41:25.828133 | 2014-03-10T22:25:48 | 2014-03-10T22:25:48 | 10,087,018 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,172 | py | """
Rao-Teh samples of MJP trajectories on trees.
"""
from __future__ import division, print_function, absolute_import
import numpy as np
import networkx as nx
from raoteh.sampler import _util, _mjp
__all__ = []
#TODO move more stuff from _sampler.py into this module
def resample_poisson(T, state_to_rate, root... | [
"argriffi@ncsu.edu"
] | argriffi@ncsu.edu |
d214dc2ec55b92f64a7b41190073cca7608a26c1 | d9a22d4dcdfc0c28176c0e8afd784b30d275597e | /multi/result_commands.py | 714185c8a5cd3ed163af2c3f3d34ece8aa591eaa | [] | no_license | jlec/relax | fda1b3ff77be0afc21c2e6cc52348ae7635cd07a | c317326ddeacd1a1c608128769676899daeae531 | refs/heads/master | 2016-09-08T00:27:57.256090 | 2015-02-10T12:24:55 | 2015-02-10T12:24:55 | 30,596,131 | 4 | 1 | null | null | null | null | UTF-8 | Python | false | false | 5,870 | py | ###############################################################################
# #
# Copyright (C) 2007 Gary S Thompson (https://gna.org/users/varioustoxins) #
# Copyright (C) 2008-2013 Edward d'Auvergne #
... | [
"bugman@b7916896-f9f9-0310-9fe5-b3996d8957d5"
] | bugman@b7916896-f9f9-0310-9fe5-b3996d8957d5 |
e8bcf51f6b4bea52914dcb421fdbe9d4c297c1e5 | 10b3d1ce02eaa4908dc16ca378ddfb1955b2d625 | /MV3D_TF_release/tests/private/test_save_pretrained_params_from_npy.py | eb62bf9b4a8afd458e9a0bb684262a62725bed00 | [
"MIT",
"BSD-3-Clause"
] | permissive | ZiningWang/Sparse_Pooling | 7281aa0d974849eac8c48faa5ba08519b091ef6e | f46882832d0e2fed5ab4a0af15cead44fd3c6faa | refs/heads/master | 2023-05-26T08:47:16.232822 | 2023-05-20T08:39:11 | 2023-05-20T08:39:11 | 141,640,800 | 56 | 21 | null | null | null | null | UTF-8 | Python | false | false | 621 | py | #This is for transforming the .npy file saved in python2 to python3
import numpy as np
import os
import scipy.io
params = np.load('mscnn_ped_cyc_kitti_trainval_2nd_iter_15000.npy').item()
#make matlab file
scipy.io.savemat('mscnn_ped_cyc_kitti_trainval_2nd_iter_15000.mat',params)
''' #make txt files(failed)
os.mkdir(... | [
"kiwoo.shin@berkeley.edu"
] | kiwoo.shin@berkeley.edu |
2dd1609af2025fa93e9fc6653d6d33aeb97f9b19 | 493431b109586bc199c0094bb6952b359c30777a | /t/step/test_header_step.py | 22289673b733113ef07729325bf5baffc937a5ad | [] | no_license | phonybone/Rnaseq | 3ec92ba79c6772ffb5ac146ee98dad87663f17e7 | c12d5380db2e36f24b6e5cb84c55a984efdd9cd7 | refs/heads/master | 2020-05-31T21:19:40.175543 | 2011-10-06T00:01:49 | 2011-10-06T00:01:49 | 1,409,030 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,833 | py | import unittest, os, sys, re
dir=os.path.normpath(os.path.dirname(os.path.abspath(__file__))+"/../..")
sys.path.append(os.path.join(dir+'/lib'))
sys.path.append(os.path.join(dir+'/ext_libs'))
from Rnaseq import *
from RnaseqGlobals import *
from warn import *
class TestHeaderStep(unittest.TestCase):
def setUp(... | [
"vcassen@bento.systemsbiology.net"
] | vcassen@bento.systemsbiology.net |
d2239c158fa3aa78bbd5bf3e8a5cb23e8b68c2fc | bfe394e1b7d8a2ff34e37ae65df8cc52070c69d8 | /Source/External/TrainUtility/Source/TrainProcess_FileControl.py | 421e6bb0c5f2eb8f3175960b7bb6fcbe8f89070f | [
"MIT"
] | permissive | Jack-GVDL/PredictModel | bb32d37a5c18a656d5ebed36098ba3fac435fb96 | 20495072fb776c31c4bb5f2ddeecda1b43fcc52e | refs/heads/main | 2023-04-30T05:47:34.364328 | 2021-05-11T09:25:13 | 2021-05-11T09:25:13 | 366,314,664 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,936 | py | import os
from typing import *
from .TrainProcess import TrainProcess
from .ModelInfo import ModelInfo
from .FileControl import FileControl_Local
class TrainProcess_FileControlBuilder(TrainProcess):
def __init__(self):
super().__init__()
# data
self.name = "FileControlBuilder"
self.path_base: str = ""... | [
"33114105+Jack-GVDL@users.noreply.github.com"
] | 33114105+Jack-GVDL@users.noreply.github.com |
08b3a3fbc165a4633691df1cd0579378c3fa8569 | a62fe37f8d633cbeb75d8cf2487f24e2bb0c13ce | /test/1.1.0/08/EndnoteObjectTest08.py | 73e2862f293a89600750726f5cfc582610fa3a47 | [
"Apache-2.0"
] | permissive | monperrus/cff-converter-python | ddf4e28329c48b0d3db4709de8765dfbfc94ad0b | b7b789a80415c6020e864782b601f21188a149f4 | refs/heads/master | 2020-11-27T10:40:11.447633 | 2019-12-19T15:58:01 | 2019-12-19T15:58:01 | 229,408,045 | 0 | 0 | Apache-2.0 | 2019-12-21T09:54:20 | 2019-12-21T09:54:19 | null | UTF-8 | Python | false | false | 1,468 | py | from cffconvert import EndnoteObject
import unittest
import os
import ruamel.yaml as yaml
class EndnoteObjectTest(unittest.TestCase):
def setUp(self):
fixture = os.path.join(os.path.dirname(__file__), "CITATION.cff")
with open(fixture, "r") as f:
cffstr = f.read()
cff_obje... | [
"j.spaaks@esciencecenter.nl"
] | j.spaaks@esciencecenter.nl |
b30391250e931a835456f54fed3840720a37cb94 | ba0a2b0d2d1534443ea34320675aadfa378457b6 | /Tree/Q776_Split BST.py | cec5e5a356eff9e2668e7a6734676b4d15d9afdc | [] | no_license | Luolingwei/LeetCode | 73abd58af116f3ec59fd6c76f662beb2a413586c | 79d4824879d0faed117eee9d99615cd478432a14 | refs/heads/master | 2021-08-08T17:45:19.215454 | 2021-06-17T17:03:15 | 2021-06-17T17:03:15 | 152,186,910 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 705 | py |
# 思路: 分成大于和小于等于v的两部分, 并且保持结构, recursive解决
# 如果v大于等于root.val, 那么左边和root都是小于等于v, split右边, 把low的部分放到root.right, 返回root和high
# 如果v小于root.val, 那么右边和root都是大于v, split左边, 把high的部分放到root.left, 返回low和root
class Solution:
def splitBST(self, root, V: int):
if not root:
return None,None
if root.va... | [
"564258080@qq.com"
] | 564258080@qq.com |
289900379592aeb4d1dacc726059621149bf2852 | c1d5c1285793660982813fd49dfb48620bc95b36 | /linode/commands/urls.py | d058c2eaa689673fe8a916325b5892033662ece2 | [
"MIT"
] | permissive | anvetsu/pylinode | 8e74330a8ae5f789cd9c4512efdc9f20aada61b9 | 3b15a153fa0528df203c0013949827ff836759f5 | refs/heads/master | 2020-04-06T14:05:39.106008 | 2018-11-14T10:06:43 | 2018-11-14T10:06:43 | 157,527,718 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 855 | py | # -*- coding: utf-8 -*-
# Linode api urls
LINODE_CREATE = '&api_action=linode.create'
LINODE_CLONE = '&api_action=linode.clone'
LINODE_BOOT = '&api_action=linode.boot'
LINODE_LIST = '&api_action=linode.list'
LINODE_DISK_CREATE = '&api_action=linode.disk.create'
LINODE_DISK_FROM_IMAGE = '&api_action=linode.disk.create... | [
"anandpillai@letterboxes.org"
] | anandpillai@letterboxes.org |
0c172bfb2db2013120d8d28c36187938f0d125b1 | afbae53ad471e34eb9918f28cc2e27e1ade6fe93 | /vivo_public_modules/spiders/item_padding_spider.py | 4a418287c83ef08a9839f1c20550b6cb9809452d | [] | no_license | wangsanshi123/spiders | 5436431feec8d9591b1b533c7c6da261142403bd | 1b42878b694fabc65a02228662ffdf819e5dcc71 | refs/heads/master | 2020-03-19T13:49:31.161232 | 2018-06-08T09:24:10 | 2018-06-08T09:24:10 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,472 | py | # -*- coding: utf-8 -*-
'''
作者: 郑阔
日期: 2018.04.17
版本: 1.0
出于数据库的要求需要,我们每条记录都需要填充或者计算一些字段
需要填充的有: website_id, website_type, crawl_time等
需要计算的有: model_id, user_id, content_id, refer_id等
由于这是所有爬虫都会涉及的操作,我这里写一个爬虫基类完成完成这个操作
'''
import hashlib
import datetime
import inspect
from scrapy import Item
from scrapy import Spider
... | [
"118319592@qq.com"
] | 118319592@qq.com |
2b242c84ce23da01b9930b418607811c97947727 | 2bb607a8b92cc4014d9e3e4368019a20442fd6ac | /TestRunner.py | 05a21e6e452422bb9d4f6b6da7240b9b68e9a135 | [] | no_license | 164461130/selenium-UI-Python- | 55c47d4dddf2181fb96afcb36d378428fa50681d | 2bf7e65558c825ffd0aef541a14107de27b3de10 | refs/heads/master | 2020-04-14T11:24:20.932244 | 2018-12-12T10:05:50 | 2018-12-12T10:05:50 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 402 | py | # -*- encoding: utf-8 -*-
# @Time : 2017/12/25 14:31
# @Author : mike.liu
# @File : TestRunner.py
import unittest
from testcase.test_chromeTest import BrowserTest
if __name__=='__main__':
suite = unittest.TestSuite()
suite.addTest(test_firefox('test_chrome'))
suite.addTest(BrowserTest('test_firef... | [
"mike.liu@jinfuzi.com"
] | mike.liu@jinfuzi.com |
7db5a055b747a9055b13854037975cec49b0449a | 960dd60c263cea329e27584b03bb430b025fe05a | /venv/bin/gunicorn | f81ebcc4a2bdfc6d083fcd3c5c9594788335a80b | [] | no_license | RuchiBhardwaj/covid_pipeline | 18b3c0ae5836487b150ad112d86e312544d19f9d | f21a98593383caed532b9e7178e70172984cd635 | refs/heads/master | 2022-12-04T09:02:47.076901 | 2020-06-08T14:12:18 | 2020-06-08T14:12:18 | 268,835,744 | 0 | 2 | null | 2022-11-27T19:32:17 | 2020-06-02T15:17:20 | Python | UTF-8 | Python | false | false | 267 | #!/home/nineleaps/PycharmProjects/COVID19_Airflow/venv/bin/python
# -*- coding: utf-8 -*-
import re
import sys
from gunicorn.app.wsgiapp import run
if __name__ == '__main__':
sys.argv[0] = re.sub(r'(-script\.pyw?|\.exe)?$', '', sys.argv[0])
sys.exit(run())
| [
"ruchi.bhardwaj@nineleaps.com"
] | ruchi.bhardwaj@nineleaps.com | |
da7b85fc67c7bfadaab88cc1238a1038576a4cad | bdda06ffbbd49c63a84fbc3bb26a55842d2b2d0a | /mysite/settings.py | 8de5512eefee0dd550c30e69c67f04291c4e0276 | [] | no_license | todqabb/my-first-blog | f820bef4321e06b20fa1e91dc9c9c5d0aaa7cd82 | 67b4dd4b442094ba372e5e2d36fff005159850f7 | refs/heads/master | 2021-01-20T05:22:08.840767 | 2017-08-25T20:22:16 | 2017-08-25T20:22:16 | 101,439,885 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,200 | py | """
Django settings for mysite project.
Generated by 'django-admin startproject' using Django 1.11.4.
For more information on this file, see
https://docs.djangoproject.com/en/1.11/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/1.11/ref/settings/
"""
import os
... | [
"you@example.com"
] | you@example.com |
1117dbbdc89478fcc9b3f3855a551f66657818bc | de24f83a5e3768a2638ebcf13cbe717e75740168 | /moodledata/vpl_data/30/usersdata/73/9601/submittedfiles/atividade.py | ac54c0c02c33500bfc7f846ac89beb1e400e1c04 | [] | no_license | rafaelperazzo/programacao-web | 95643423a35c44613b0f64bed05bd34780fe2436 | 170dd5440afb9ee68a973f3de13a99aa4c735d79 | refs/heads/master | 2021-01-12T14:06:25.773146 | 2017-12-22T16:05:45 | 2017-12-22T16:05:45 | 69,566,344 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 198 | py | # -*- coding: utf-8 -*-
from __future__ import division
import math
n = input ('digite o valor de n:')
soma = 0
for i in range (1,n+1,1):
a = i/(n+1-i)
soma = soma + a
print ('%.5f' %soma )
| [
"rafael.mota@ufca.edu.br"
] | rafael.mota@ufca.edu.br |
b025942a885c51b7cba68983e10da3229b4c6dd2 | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p03474/s139736591.py | 35fd766d01c43ff1779773d47e9f0d978ed03fe3 | [] | no_license | Aasthaengg/IBMdataset | 7abb6cbcc4fb03ef5ca68ac64ba460c4a64f8901 | f33f1c5c3b16d0ea8d1f5a7d479ad288bb3f48d8 | refs/heads/main | 2023-04-22T10:22:44.763102 | 2021-05-13T17:27:22 | 2021-05-13T17:27:22 | 367,112,348 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 305 | py | a,b = map(int,input().split())
s = list(input())
cnt = 0
num = list("0123456789")
for i in range(a):
if s[i] in num:
cnt += 1
if s[a] == "-":
cnt += 1
for i in range(b):
if s[i+a+1] in num:
cnt += 1
if cnt == a+b+1:
print("Yes")
else:
print("No") | [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
8d3edda1cc082f4a48eafa8db8ef84b771cd96ae | c73b9c944deb7d0c564dcefc3fe30fbf0f69e47d | /pipeline/pipeline/backend.py | 5a51e23c0d2fbe7572724f72d786690d3045cecf | [
"MIT"
] | permissive | atgenomix/hail | 46e3edcea33a86184462f6ef0f354ea0239cd0dc | ceb85fc87544b5dceabe64213e3c5acaaae6a05e | refs/heads/master | 2021-06-19T07:48:42.503150 | 2019-02-22T04:09:30 | 2019-02-22T04:09:30 | 171,826,476 | 1 | 0 | MIT | 2019-02-21T07:57:38 | 2019-02-21T07:57:37 | null | UTF-8 | Python | false | false | 2,906 | py | import abc
import os
import subprocess as sp
from .resource import Resource, ResourceGroup
from .utils import get_sha, escape_string
class Backend:
@abc.abstractmethod
def tmp_dir(self):
return
@abc.abstractmethod
def run(self, pipeline, dry_run, verbose, bg, delete_on_exit):
return
... | [
"daniel.zidan.king@gmail.com"
] | daniel.zidan.king@gmail.com |
19fadc6bd0dcb196c68d7e3ac27319302057be8f | e349a8dba0356f9ba252df905f563944750d989a | /scripts/flix.py | ea8aa9f3358bb44e41dedfe2f0bbe0bfb1387917 | [
"MIT"
] | permissive | jaebradley/flix | 49ebe12ae0b53c8c004d403d424478997085e397 | adc02c2f08d01e1acd6f18065be70a8c87e71e55 | refs/heads/master | 2022-12-12T20:15:18.697554 | 2017-06-13T12:38:17 | 2017-06-13T12:38:17 | 93,294,294 | 1 | 0 | MIT | 2022-12-07T23:58:05 | 2017-06-04T06:17:12 | Python | UTF-8 | Python | false | false | 1,547 | py | import click
from data.exceptions import InvalidDateException
from data.time import get_date
from data.services import fetch_parsed_theater_data
from tables.builders import build_table
MONTH_CHOICES = [
"jan", "feb", "mar", "apr", "may", "jun", "jul", "aug", "sep", "oct", "nov", "dec",
"1", "2", "3", "4", "5"... | [
"jae.b.bradley@gmail.com"
] | jae.b.bradley@gmail.com |
2bb2717658bda0e645599dbf83db02d5fce1ebde | 3c934c97bd5748237ac8963c8be779a7d77be629 | /maximumConsecOne.py | 7c8085c860f9b9639124b62b613e6cbd31879ac1 | [] | no_license | Franktian/leetcode | 2b0d0280d18e3401b9f337f027c5d70f26237f02 | 98e7852ba144cefbdb02f705651b1519155ee4d6 | refs/heads/master | 2021-06-12T15:23:09.733650 | 2020-06-17T23:09:18 | 2020-06-17T23:09:18 | 128,710,359 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 295 | py | def findMaxConsecutiveOnes(self, nums):
"""
:type nums: List[int]
:rtype: int
"""
res = 0
curr = 0
for n in nums:
if n == 1:
curr += 1
else:
curr = 0
if curr >= res:
res = curr
return res
| [
"tianyawen201209@hotmail.com"
] | tianyawen201209@hotmail.com |
2b0c2dda599c2b9101d263bb3608cffc7638a3e8 | 757e3de38040878588bfcc846ec87a34740313a3 | /cap_07_iteracao/Lista_Fábio_03_em_for/fabio_iteracao_Q05_fatorial.py | a7ef9b3b83716cd9d39aef8b5d30c39c52b8871b | [] | no_license | Emanuelvss13/ifpi-ads-algoritimos2020 | c0a4a76ce3c41ae945f1ba31719eb68a539a9c9c | ac693feb1eee67f7c816b2ed34d44f3fd939653d | refs/heads/master | 2021-03-06T05:32:37.040171 | 2021-02-03T23:46:24 | 2021-02-03T23:46:24 | 246,182,570 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 274 | py | def main():
numero = int(input('Digite um número: '))
fatorial = 1
numero_print =numero
for i in range(numero):
fatorial = fatorial * numero
numero -= 1
print(f'O fatorial de {numero_print} é : {fatorial}')
main() | [
"noreply@github.com"
] | Emanuelvss13.noreply@github.com |
8c42e5185cd19ce89eb94c84bb3c322b1804aa6a | 9743d5fd24822f79c156ad112229e25adb9ed6f6 | /xai/brain/wordbase/otherforms/_histories.py | 17f1b20f237ac5840ec05fd67dc1b6cdf2391ec7 | [
"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 | 228 | py |
#calss header
class _HISTORIES():
def __init__(self,):
self.name = "HISTORIES"
self.definitions = history
self.parents = []
self.childen = []
self.properties = []
self.jsondata = {}
self.basic = ['history']
| [
"xingwang1991@gmail.com"
] | xingwang1991@gmail.com |
cced9e47a43e84015736e4fd09d4ccfba0f30baf | fc5734ad9b0dc154b3a36ec2f5d848b3d693473f | /solutions/Hash Tables/dot_product_of_two_sparse_vectors.py | 896d3a57d9ce44a518484cdc2456a6631b02371e | [
"MIT"
] | permissive | aimdarx/data-structures-and-algorithms | 8e51ec2144b6e0c413bc7ef0c46aba749fd70a99 | 1659887b843c5d20ee84a24df152fb4f763db757 | refs/heads/master | 2023-08-28T12:00:33.073788 | 2021-11-07T08:31:28 | 2021-11-07T08:31:28 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,652 | py | """
Dot Product of Two Sparse Vectors:
Given two sparse vectors, compute their dot product.
Implement class SparseVector:
SparseVector(nums) Initializes the object with the vector nums
dotProduct(vec) Compute the dot product between the instance of SparseVector and vec
A sparse vector is a vector that has mostly zero... | [
"noreply@github.com"
] | aimdarx.noreply@github.com |
e485686f7b3e2f193e4c57591b0c968748577699 | a6e4a6f0a73d24a6ba957277899adbd9b84bd594 | /sdk/python/pulumi_azure_native/portal/v20181001/get_console.py | ddcd939b6a17147c3b434fa54036381df2a55ba9 | [
"BSD-3-Clause",
"Apache-2.0"
] | permissive | MisinformedDNA/pulumi-azure-native | 9cbd75306e9c8f92abc25be3f73c113cb93865e9 | de974fd984f7e98649951dbe80b4fc0603d03356 | refs/heads/master | 2023-03-24T22:02:03.842935 | 2021-03-08T21:16:19 | 2021-03-08T21:16:19 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,840 | 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"
] | MisinformedDNA.noreply@github.com |
0b8906daed72ba0039fe0761e437da2e6a1ea053 | 312fe86a9540b7bfabcaadd5f20ba107755b195b | /playbooks/monitoring/kibana/docs_compare.py | f421ce5d3d53e5c2befc2e6f379b42c935ca6489 | [
"Apache-2.0"
] | permissive | isabella232/elastic-stack-testing | fa623cce484ecf870c5e90da6b401b3f4c2ce296 | 1526ab4b4ca187dc5f0eb81be2fed058fc556082 | refs/heads/master | 2023-01-05T13:26:22.430049 | 2020-11-09T18:19:44 | 2020-11-09T18:19:44 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,709 | py | '''
Usage:
python docs_compare.py /path/to/legacy/docs /path/to/metricbeat/docs
'''
from docs_compare_util import check_parity
import sys
allowed_deletions_from_metricbeat_docs_extra = [
# 'path.to.field'
'kibana_stats.response_times.max',
'kibana_stats.response_times.average'
]
unused_kibana_usage_propertie... | [
"noreply@github.com"
] | isabella232.noreply@github.com |
d0f72f2c74e04492606256a0d23728e050e02a0e | 7a91286a3636ad9606d5933619401cc45bee1b10 | /lib/banking/balance.py | db0904c2b45181d536718a1e76a3f25b00e70e80 | [] | no_license | phriscage/banking_application | d063bbb24c3e1061c2110c1aace1d67ae53e70cc | cc120437213a25e1864db14509c6d143b65d8102 | refs/heads/master | 2019-01-02T04:00:30.034945 | 2015-01-31T03:50:42 | 2015-01-31T03:50:42 | 30,099,098 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 574 | py | """
balance class
"""
class Balance(object):
""" the balance class includes the balance operations """
def __init__(self):
""" instantiate the class """
self.total = 0
def add(self, value):
""" add value to the total
Args:
value (int): numeric value
... | [
"phriscage@gmail.com"
] | phriscage@gmail.com |
019082fa9d75ecfb96a0de970631cd8ecb05eaeb | 98ad5d08eda9dbce55947b53dc8e1627e7be5404 | /backend/blog_api/serializers.py | e57bb6df05843dd07c9c6292467f59f623977218 | [] | no_license | mhkmcp/blog-react-djagno | 651a9f1f65f0c54804ceb8ea51cddf0587ef2c81 | 6d0904a08311590b8d07a99c6c02d8f50bbaa0de | refs/heads/main | 2023-08-03T16:28:52.666182 | 2021-09-20T15:00:48 | 2021-09-20T15:00:48 | 408,421,779 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 232 | py | from rest_framework import serializers
from blog.models import Post
class PostSerializer(serializers.ModelSerializer):
class Meta:
model = Post
fields = ('id', 'title', 'excerpt', 'content', 'author', 'status') | [
"mhkmcp@yahoo.com"
] | mhkmcp@yahoo.com |
5ae88cd77491d8b24fad6d607239ecf25badf6b8 | 31764c3903bd7b7cde4649860eb843bc8545095d | /books/Language/python/geatpy/code/A02_DTLZ1.py | 8161e8d8fd83f130fdf31b1d442681d18bd7f173 | [] | no_license | madokast/madokast.github.io.old | bf3aa967ee7ccdba99ce7d667e02f8672ae8b00e | 3af6570401c9f7f11932cc3bac79f4979507c79b | refs/heads/master | 2023-06-20T07:52:50.119738 | 2021-07-22T01:35:12 | 2021-07-22T01:35:12 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,670 | py | # -*- coding: utf-8 -*-
""" QuickStart """
import numpy as np
import geatpy as ea
# 自定义问题类
class MyProblem(ea.Problem): # 继承Problem父类
def __init__(self, M): # M 目标维数,测试中使用 3
# 问题的名字
name = 'DTLZ1' # 初始化name(函数名称,可以随意设置)
# 目标变量是最大化还是最小化
maxormins = [1] * M # 初始化maxormins(目标最小最大化标记列表... | [
"578562554@qq.com"
] | 578562554@qq.com |
ff27dbd756b4dde221c7ca61cb5f0e3da88cfb58 | a60bc58d17720a2f1e2f8778146248c01adf8a5a | /post_subjects.py | 3221347af689853f3f40fd00b7bd68bace9316dc | [] | no_license | meau/bentley_scripts | 08bdbc159939731966bdeda396c93022212f922d | e17abff89a775b2b7273661e92b849b85e6a1f8d | refs/heads/master | 2021-01-17T05:46:24.838505 | 2015-09-21T16:17:25 | 2015-09-21T16:17:25 | 42,587,433 | 1 | 0 | null | 2015-09-16T13:03:26 | 2015-09-16T13:03:25 | Python | UTF-8 | Python | false | false | 1,925 | py | """
curl -H "X-ArchivesSpace-Session:$TOKEN" -d '{"source":"lcsh","vocabulary":"/vocabularies/1","terms":[{"term":"Cheese", "term_type":"topical","vocabulary":"/vocabularies/1"},{"term":"Michigan","term_type":"geographic","vocabulary":"/vocabularies/1"}]}' http://localhost:8089/subjects
"""
import requests
import json... | [
"djpillen@umich.edu"
] | djpillen@umich.edu |
bce301e020d3e0032f55ca6472c9e2c8cf63c121 | aa54fd5cafc65d18ceac52097237482cec27f674 | /planetary_system_stacker/Test_programs/count_lines_of_code.py | 5f56284c52c4e38aa219fd0850afce7de4024311 | [] | no_license | Rolf-Hempel/PlanetarySystemStacker | 84f6934e6748177fb1aca20b54392dee5c3f2e3c | 304952a8ac8e991e111e3fe2dba95a6ca4304b4e | refs/heads/master | 2023-07-20T04:11:06.663774 | 2023-07-17T15:20:15 | 2023-07-17T15:20:15 | 148,365,620 | 228 | 34 | null | 2023-09-01T16:33:05 | 2018-09-11T19:00:13 | Python | UTF-8 | Python | false | false | 1,442 | py | # -*- coding: utf-8; -*-
import os
def countlines(start, lines=0, header=True, begin_start=None):
if header:
print('{:>10} |{:>10} | {:<20}'.format('ADDED', 'TOTAL', 'FILE'))
print('{:->11}|{:->11}|{:->20}'.format('', '', ''))
for thing in os.listdir(start):
thing = os.path.join(start... | [
"rolf6419@gmx.de"
] | rolf6419@gmx.de |
6d907810b817e314675bd275c3313d21111ee5a3 | 781e2692049e87a4256320c76e82a19be257a05d | /intervention/results/control_120802_1449613710_39_13.75.py | cb40cf5e2e0afecd0c7c8544b6db900f76291663 | [] | no_license | itsolutionscorp/AutoStyle-Clustering | 54bde86fe6dbad35b568b38cfcb14c5ffaab51b0 | be0e2f635a7558f56c61bc0b36c6146b01d1e6e6 | refs/heads/master | 2020-12-11T07:27:19.291038 | 2016-03-16T03:18:00 | 2016-03-16T03:18:42 | 59,454,921 | 4 | 0 | null | 2016-05-23T05:40:56 | 2016-05-23T05:40:56 | null | UTF-8 | Python | false | false | 227 | py |
def num_common_letters(goal_word, guess):
cache = set('')
counter = 0
for i in goal_word:
if i not in cache:
cache.add(i)
for i in guess:
if i in cache:
counter += 1
cache.remove(i)
return counter | [
"rrc@berkeley.edu"
] | rrc@berkeley.edu |
869ca60250a2409dbfa492cac38092f9ed2dd74c | 7bd5ca970fbbe4a3ed0c7dadcf43ba8681a737f3 | /srm/651-675/660/Coversta.py | 3322d7823065e870dd37931908d60355b24de092 | [] | no_license | roiti46/Contest | c0c35478cd80f675965d10b1a371e44084f9b6ee | c4b850d76796c5388d2e0d2234f90dc8acfaadfa | refs/heads/master | 2021-01-17T13:23:30.551754 | 2017-12-10T13:06:42 | 2017-12-10T13:06:42 | 27,001,893 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 983 | py | #SRM660 Div1 Easy
import math,string,itertools as it,fractions,heapq,collections as collect,re,array,bisect,random,sys
class Coversta:
def place(self, a, x, y):
n, m, k = len(a), len(a[0]), len(x)
a = [map(int, list(a[i])) for i in xrange(n)]
dwr = zip(x, y)
scores = []
for w in xrange(n):
fo... | [
"roiti46@gmail.com"
] | roiti46@gmail.com |
4edc855bd5476a2b9bcab34e8779b09af4dec769 | 485816a0a8b86818e4f2cefec517e6316e2252d6 | /posthog/api/plugin_log_entry.py | 45e70682d86c77170aeadcbe9881f5cb8d48ac7f | [
"MIT",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | abhijitghate/posthog | 3647443274aee6431e7fecf6902644a9fa7eb9d8 | 68dc4d2730600efb00d3708fb7fba70d85612760 | refs/heads/master | 2023-04-19T15:17:25.033992 | 2021-05-13T09:48:59 | 2021-05-13T09:48:59 | 279,130,099 | 1 | 0 | MIT | 2020-07-12T19:04:15 | 2020-07-12T19:04:14 | null | UTF-8 | Python | false | false | 2,275 | py | from typing import Optional
from django.utils import timezone
from rest_framework import exceptions, generics, mixins, request, serializers, status, viewsets
from rest_framework.permissions import IsAuthenticated
from posthog.api.plugin import PluginOwnershipPermission, PluginsAccessLevelPermission
from posthog.api.r... | [
"noreply@github.com"
] | abhijitghate.noreply@github.com |
3049a52f0e3824b7e9183c34e6fbbd82deb72726 | ecf1ce6f8b592f76c7b7c253608c1264ae0676a3 | /days/day023/bite_022_Write_a_decorator_with_argument/test_bite_022.py | cb84a294a8948552c5e32652a8d195cd737cdd88 | [] | permissive | alex-vegan/100daysofcode-with-python-course | 94e99880a50ac412e398ad209ed53796f253641f | b6c12316abe18274b7963371b8f0ed2fd549ef07 | refs/heads/master | 2021-07-20T23:05:59.721661 | 2019-01-21T16:18:25 | 2019-01-21T16:18:25 | 150,115,516 | 0 | 0 | MIT | 2018-09-24T14:28:16 | 2018-09-24T14:28:15 | null | UTF-8 | Python | false | false | 248 | py | from bite_022 import make_html
def test_make_html():
@make_html('p')
@make_html('strong')
def get_text(text='I code with PyBites'):
return text
assert get_text() == '<p><strong>I code with PyBites</strong></p>'
| [
"alex-vegan@outlook.com"
] | alex-vegan@outlook.com |
ddba2951e6d7f604b3af9174b0cd0fd2bc89d4e9 | ecc4e8c9794c8ecddfd3774a396d4a06881c1245 | /test/docker_test.py | 72d60addf7437caf5bb641bfc13d1b97b21c6640 | [
"MIT"
] | permissive | cheminfo-py/crystal_analysis_webservice | d244bd01523c1edfc428458e6dea42b063e3edbd | 444c91adb645aa99401dbb3d8f30d8b98e2343c5 | refs/heads/master | 2023-01-10T20:58:34.389784 | 2020-11-19T07:06:27 | 2020-11-19T07:06:27 | 303,760,806 | 0 | 0 | MIT | 2020-11-19T06:40:05 | 2020-10-13T16:17:15 | Python | UTF-8 | Python | false | false | 670 | py | # -*- coding: utf-8 -*-
"""Test if the API responds in the Docker image"""
import sys
import requests
import os
import json
THIS_DIR = os.path.dirname(os.path.realpath(__file__))
r = requests.get("http://localhost:8091/version/")
keys = r.json().keys()
if "version" in keys:
print("OK")
else:
print("error")
... | [
"kevin.jablonka@epfl.ch"
] | kevin.jablonka@epfl.ch |
b67776dddfb11a06e921bfc4315136dadb462d10 | e3d6f803beece2ecc2cde8de795fdd20291213ff | /nova/tests/functional/notification_sample_tests/test_aggregate.py | 61a4a20565b9da0c0ca69ba8232bfea12032390e | [
"Apache-2.0"
] | permissive | panguan737/nova | 437c1adb81f3e9ef82c28ad957144623db13ba52 | 0d177185a439baa228b42c948cab4e934d6ac7b8 | refs/heads/main | 2023-01-07T00:08:44.069599 | 2020-11-01T14:00:42 | 2020-11-01T14:00:42 | 309,332,719 | 0 | 0 | Apache-2.0 | 2020-11-02T10:17:13 | 2020-11-02T10:17:13 | null | UTF-8 | Python | false | false | 4,047 | py | # 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, software
# d... | [
"147360410@qq.com"
] | 147360410@qq.com |
37c3c598b02fad75e178c54e31aae90a0d649116 | 8f0ce1be6cc093d962c64179eec99c7ccc20ffc4 | /fabrication/migrations/0007_fabricationprojectpage_items.py | f585382451b27a14eb873908ea552ac48e3a6fb3 | [] | no_license | dmeehan/futuregreenstudio | cf5e12c6ead8f0c7023ba09d5868749888068b72 | e6e2b7f7ffa2ed251d21e6b1d07573ab4f70782f | refs/heads/master | 2023-08-30T20:12:24.814970 | 2023-08-28T14:55:26 | 2023-08-28T14:55:26 | 89,943,081 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 482 | py | # -*- coding: utf-8 -*-
# Generated by Django 1.11.29 on 2021-07-26 04:46
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('fabrication', '0006_auto_20210726_0440'),
]
operations = [
migrations.AddF... | [
"dmeehan@gmail.com"
] | dmeehan@gmail.com |
eab1cf90ff876af4f0683c8f49fa175a879378ac | e0045eec29aab56212c00f9293a21eb3b4b9fe53 | /delivery/tests/__init__.py | 8a969170bf17e9fd0f8173deea33b83546ba2af9 | [] | no_license | tamam001/ALWAFI_P1 | a3a9268081b9befc668a5f51c29ce5119434cc21 | 402ea8687c607fbcb5ba762c2020ebc4ee98e705 | refs/heads/master | 2020-05-18T08:16:50.583264 | 2019-04-30T14:43:46 | 2019-04-30T14:43:46 | 184,268,686 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 165 | py | # -*- coding: utf-8 -*-
# Part of ALWAFI. See LICENSE file for full copyright and licensing detailsself.
from . import test_delivery_cost, test_delivery_stock_move
| [
"50145400+gilbertp7@users.noreply.github.com"
] | 50145400+gilbertp7@users.noreply.github.com |
aef82e74b3d77b46a8daf0528299813a33884d69 | 1180c0bfe29959d95f3c131e6e839950e528d4ee | /05/bmiraski/similar_tweeters.py | 370a3f3daee4af7e42956a3ee85a630156a63fbe | [] | no_license | pybites/challenges | e3e461accd8e7f890aee8007ba5070086ef983fc | 02b77652d0901e6e06cb9b1e7cb3e59c675445c2 | refs/heads/community | 2023-08-20T18:19:02.982214 | 2022-11-17T09:23:31 | 2022-11-17T09:23:31 | 78,264,928 | 764 | 3,115 | null | 2023-07-21T05:58:19 | 2017-01-07T07:17:50 | Jupyter Notebook | UTF-8 | Python | false | false | 2,284 | py | """Compare tweet similarity from two users."""
from nltk.corpus import stopwords
import spacy
from string import ascii_lowercase
from string import digits
from string import punctuation
import sys
import usertweets
stoplist = set(stopwords.words('english'))
nlp = spacy.load('en_core_web_md')
def similar_tweeters(... | [
"pybites@projects.bobbelderbos.com"
] | pybites@projects.bobbelderbos.com |
0eb176292acf6b719ee3c1745b86634560ae1707 | 54da94dce244ab659c8036cafcdc1b326fbfe490 | /datoteke-s-predavanj/2016-17/02-rekurzija/rekurzija-b.py | aaf7cba7342ff8211217d6cb04f8b72ed61abd67 | [] | no_license | jakamrak/uvod-v-programiranje | 640b2738164e2026308d7e60f1478659df79cc40 | 3c05290f4f23b384ad9063880fffe208c08fc599 | refs/heads/master | 2022-07-17T16:50:18.563453 | 2020-05-18T13:54:13 | 2020-05-18T13:54:13 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,877 | py | def fibonacci(n):
'''Vrne n-ti člen zaporedja 1, 1, 2, 3, 5, 8, ...'''
if n == 0:
return 1
elif n == 1:
return 1
else:
return fibonacci(n - 1) + fibonacci(n - 2)
def splosni_fibonacci(n, a, b):
'''Vrne n-ti člen zaporedja a, b, a + b, a + 2b, 2a + 3b, ...'''
if n == 0:
... | [
"matija@pretnar.info"
] | matija@pretnar.info |
f655b27fab13fb11eed3d2d3b61c3cec82c6c715 | e1dd0997239951d4d459b1ba0229493512b0b331 | /mds_py/mds-env/lib/python3.11/site-packages/cleo/loaders/factory_command_loader.py | f47ae186ab1d41b16e0ae4a0c34e9357ad678bb2 | [] | no_license | alexmy21/Octopus | bd17777cf66654c1e7959654f63ca82b716865b5 | 7844ec616376ec6cd9c1a8b73dbcad9c729557ae | refs/heads/master | 2022-12-22T22:42:29.473433 | 2022-12-21T16:52:09 | 2022-12-21T16:52:09 | 61,543,002 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 819 | py | from typing import Callable
from typing import Dict
from typing import List
from cleo.commands.command import Command
from ..exceptions import CommandNotFoundException
from .command_loader import CommandLoader
class FactoryCommandLoader(CommandLoader):
"""
A simple command loader using factories to instanti... | [
"alex.mylnikov@hitachivantara.com"
] | alex.mylnikov@hitachivantara.com |
eb20013d020a237284de499bd0d8625c37888b89 | bebba3fb1dfc13a2220f06997c4bc8da42ef8e87 | /smashlib/ipy3x/core/error.py | fdce2fe18b4821b059eb0b9aa031ff4c40673968 | [
"MIT"
] | permissive | mattvonrocketstein/smash | b48b93c3419637f615c7ac3386b04ae756e1fadc | 98acdc27ab72ca80d9a7f63a54c0d52f126a8009 | refs/heads/master | 2021-01-18T23:23:59.340206 | 2016-07-14T01:28:17 | 2016-07-14T01:28:17 | 2,813,958 | 2 | 1 | null | null | null | null | UTF-8 | Python | false | false | 1,742 | py | # encoding: utf-8
"""
Global exception classes for IPython.core.
Authors:
* Brian Granger
* Fernando Perez
* Min Ragan-Kelley
Notes
-----
"""
#-----------------------------------------------------------------------------
# Copyright (C) 2008 The IPython Development Team
#
# Distributed under the terms of the BSD ... | [
"matthewvonrocketstein@gmail-dot-com"
] | matthewvonrocketstein@gmail-dot-com |
966167169ec32aff8bf1faaf037b3ff555065e29 | 6fa7f99d3d3d9b177ef01ebf9a9da4982813b7d4 | /8oNKM4osgxYyrFtGL_19.py | 71e9c04b8fa2dd16ba98bba2536e6efa1c716407 | [] | no_license | daniel-reich/ubiquitous-fiesta | 26e80f0082f8589e51d359ce7953117a3da7d38c | 9af2700dbe59284f5697e612491499841a6c126f | refs/heads/master | 2023-04-05T06:40:37.328213 | 2021-04-06T20:17:44 | 2021-04-06T20:17:44 | 355,318,759 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 164 | py |
def multiply(l):
n = []
ll = len(l)
for w in l:
i = []
ll2 = ll
while ll2 > 0:
i.append(w)
ll2 = ll2 - 1
n.append(i)
return n
| [
"daniel.reich@danielreichs-MacBook-Pro.local"
] | daniel.reich@danielreichs-MacBook-Pro.local |
14f0ad0a9d89f796416f432792c730a988d1b86d | 8acba76d7e7787c0b2c8270552ef5bc7eb0c7549 | /backend/todo/models.py | 10f3336c4b31594c2c1e77ee6f14a3858b46b33a | [] | no_license | harishtm/djreact | a99e91723fa92b52a5d467f01235ec0fc8eb02bb | 6bec0b89db10b255581a5a9dd1f440e40e8bf784 | refs/heads/master | 2023-01-29T04:44:28.276494 | 2020-03-13T06:54:49 | 2020-03-13T06:54:49 | 201,904,114 | 0 | 0 | null | 2023-01-04T06:57:14 | 2019-08-12T09:58:03 | JavaScript | UTF-8 | Python | false | false | 268 | py | from django.db import models
# Create your models here.
class Todo(models.Model):
title = models.CharField(max_length=255)
description = models.TextField()
completed = models.BooleanField(default=False)
def __str__(self):
return self.title
| [
"you@example.com"
] | you@example.com |
d63abbb48211e4004a4441ab8f36cb5cc3a048f2 | 5182897b2f107f4fd919af59c6762d66c9be5f1d | /.history/src/Matriz_esferica_20200707115539.py | 2a05f90d9392c0a9967f9cb280e6bcd2b930b4d3 | [
"MIT"
] | permissive | eduardodut/Trabalho_final_estatistica_cd | 422b7e702f96291f522bcc68d2e961d80d328c14 | fbedbbea6bdd7a79e1d62030cde0fab4e93fc338 | refs/heads/master | 2022-11-23T03:14:05.493054 | 2020-07-16T23:49:26 | 2020-07-16T23:49:26 | 277,867,096 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,224 | py | import numpy as np
import random
#regras de movimentacao
class Matriz_esferica():
def __init__(self, tamanho):
self.tamanho = tamanho
def get_vizinho_esquerda(self, ponto):
pass
def get_vizinho_direita(self, ponto):
pass
def get_vizinho_cima(self, ponto):
pa... | [
"eduardo_dut@edu.unifor.br"
] | eduardo_dut@edu.unifor.br |
4171668175165d80aa71d270e8c75e6894a51269 | f654f5f07dd8109c0ee31ba89dd4804e6b288343 | /src/programy/clients/xmpp.py | 22f1b1c3347d45f3276d071306235db382006fa7 | [
"MIT"
] | permissive | sprinteroz/program-y | 3d1f5f28e4f3be770705d4bef15410b8b78f19da | 454c6bde225dce7c3fb01c549d46249248caf7b5 | refs/heads/master | 2021-01-19T16:05:25.636700 | 2017-08-22T03:56:33 | 2017-08-22T03:56:33 | 100,986,551 | 1 | 0 | null | 2017-08-21T19:43:43 | 2017-08-21T19:43:43 | null | UTF-8 | Python | false | false | 3,522 | py | """
Copyright (c) 2016-17 Keith Sterling http://www.keithsterling.com
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
documentation files (the "Software"), to deal in the Software without restriction, including without limitation
the rights to use, copy, mod... | [
"keith@keithsterling.com"
] | keith@keithsterling.com |
183383359d833fb0a64220802c19ab444a1e24ba | d8e4ffa9daaeca95cf52d3a9e3ca1cff865357bf | /section 7/5. 동전분배하기/aa.py | 04a5b8df849fde24fe520978eff8954f916f87e2 | [] | no_license | mike-bskim/coding_test | ed4e3790b5b41ed62b922ba9d04149d1cd335c84 | 430445c3ad0ddb4435a5fd244ba3a86677cd00ff | refs/heads/master | 2023-05-06T00:04:24.090152 | 2021-05-13T19:33:01 | 2021-05-13T19:33:01 | 365,245,924 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 811 | py | import sys
# sys.stdin=open('in1.txt', 'rt')
# input=sys.stdin.readline
def DFS(L):
global min1
# if max(money)> total/2: # 한개의 숫자가 다른 숫자보다 월등히 크면 로직오류 발생.
# return
if L == n:
dif = max(money) - min(money)
if (dif) < min1:
tmp = set(money)
if len(tmp) == 3:... | [
"mike-bskim@gmail.com"
] | mike-bskim@gmail.com |
e27a4dbde2694d7944a84c853f4374204a7e4703 | cc896a233121c4dc158210fae0588e7bdb63b9ff | /rtcbproj/rtcb/authentication/schema.py | b5af07989b4abed79691dda4ba9e29b3de4ded4c | [
"Apache-2.0"
] | permissive | arsenico13/rtcb-backend | 2b99a0fbb6a07bb0a9ef6652603c6e914ccd4525 | f097eae54a12ba4f3983869fef627ea1d55a37d1 | refs/heads/master | 2023-04-07T04:30:33.874569 | 2020-10-27T00:06:16 | 2020-10-27T00:06:16 | 151,688,197 | 0 | 0 | null | 2018-10-05T07:54:18 | 2018-10-05T07:54:17 | null | UTF-8 | Python | false | false | 554 | py | import graphene
from graphene_django import DjangoObjectType
from .models import User as UserModel
class ChoicesRoles(graphene.Enum):
Defender = 'D'
Striker = 'S'
class User(DjangoObjectType):
role = ChoicesRoles()
class Meta:
model = UserModel
interfaces = (graphene.Node, )
... | [
"andrea.cecchi85@gmail.com"
] | andrea.cecchi85@gmail.com |
6c856cdbc50ea95865105c3aa077d96b3ea9ad24 | 56ab1f0aa30dc0357e84fa11640c9353fd5deeed | /set7/52/set7_pro52.py | 01d24fe9296d4e88110b36a1d56cb8993b0cb214 | [] | no_license | zjwzcn07/cryptopals | c9c11a7627222291e7f5c7a2cfffc4a55b548dc5 | d44c9e8b8f1527e244de6a5425b8d4f46ef98e49 | refs/heads/master | 2021-06-10T13:35:48.517737 | 2016-11-30T11:29:59 | 2016-11-30T11:29:59 | 74,258,995 | 3 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,019 | py | import hmac
import sys
def bad_hash_block(msg,iv):
mac = str2bin(hmac.new(iv,msg).hexdigest())[:16]
#print mac
return mac
def str2bin(string):
string_bin = ""
for x in string:
the_bin = bin(ord(x))[2:]
if((8 - len(the_bin))>0):
the_bin = '0'*(8 - len(the_bin)) + the_bin
string_bin = string_bin + the_b... | [
"1106911190@qq.com"
] | 1106911190@qq.com |
21ce8f7efc7d9750a693501c0a68db78036b44c3 | f576f0ea3725d54bd2551883901b25b863fe6688 | /sdk/resources/azure-mgmt-resource/azure/mgmt/resource/subscriptions/_operations_mixin.py | 5631cad2bfb87a3b4ce5a3932a1c06cdb5d2fd42 | [
"LicenseRef-scancode-generic-cla",
"MIT",
"LGPL-2.1-or-later"
] | permissive | Azure/azure-sdk-for-python | 02e3838e53a33d8ba27e9bcc22bd84e790e4ca7c | c2ca191e736bb06bfbbbc9493e8325763ba990bb | refs/heads/main | 2023-09-06T09:30:13.135012 | 2023-09-06T01:08:06 | 2023-09-06T01:08:06 | 4,127,088 | 4,046 | 2,755 | MIT | 2023-09-14T21:48:49 | 2012-04-24T16:46:12 | Python | UTF-8 | Python | false | false | 3,410 | py | # coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes ... | [
"noreply@github.com"
] | Azure.noreply@github.com |
73d0d1b1c8b75b5f329b134be4f9f52dae01419b | bc5dd7be84a43ec53f8e4215761badb9b61a13ad | /kurs_2/vertualenv/Lib/site-packages/django/contrib/messages/storage/base.py | d1f9b274323aa72fc4ab49364e624f39becd2095 | [] | no_license | MaximMak/DL_Academy_Lessons | ef4758be02e43954748031ac95c970077f71cd7e | 427576859657e88fd81683494397af3df920c674 | refs/heads/master | 2023-01-29T19:53:11.650096 | 2020-12-13T21:40:58 | 2020-12-13T21:40:58 | 276,397,551 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,679 | py | from django.conf import settings
from django.contrib.messages import constants, utils
LEVEL_TAGS = utils.get_level_tags()
class Message:
"""
Represent an actual message that can be stored in any of the supported
storage classes (typically session- or cookie-based) and rendered in a view
or template.
... | [
"54116778+MaximMak@users.noreply.github.com"
] | 54116778+MaximMak@users.noreply.github.com |
4e6c5b0a5c1fc42f8b453fe5a38fd77ed0d32ef8 | 1f8d05b774271e6c9321b23093baa1dda3dae650 | /utils_app/website_settings.py | 1ad5af2e18bf0beded6e8b31a84024909eaa29ea | [] | no_license | pockerman/python_lms | 5ca2f0d90692bf6c9bc7c00d0ffd59db084ead3f | 327dbbd9e5ad96c143c8abe60cf8a2cbc3d5dac0 | refs/heads/master | 2020-07-14T01:07:27.826127 | 2019-08-29T16:08:37 | 2019-08-29T16:08:37 | 205,197,331 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 263 | py |
site_index_title='Ustdy'
navigation_elements = ["Join","Services","Courses","Contact"]
main_page_buttons =["Courses Catalog","Request Info","Tests Catalog","Library","Learn More"]
nav_page_title=["Ustdy-Join","Ustdy-Services","Ustdy-Courses","Ustdy-Contact"]
| [
"a.giavaras@gmail.com"
] | a.giavaras@gmail.com |
6216ac8e2467c29bdefb4a44159e403691e89f88 | 9a5438bdb8e84d0167ddea5458a7f729fdd54121 | /MetaDataApi/tests/test_utils/test_json_utils.py | d364134e98feae48c1bf4083a71f2715fcc53c32 | [] | no_license | Grusinator/MetaDataApi | 740fd2be4cb97b670f827a071a0ac8c50f79f8ff | 081f881c735466ed1dbbd68646b821299c5168f8 | refs/heads/master | 2023-07-25T23:58:22.179717 | 2020-03-15T09:36:05 | 2020-03-15T09:36:05 | 149,087,967 | 5 | 1 | null | 2023-07-25T15:39:12 | 2018-09-17T07:45:09 | CSS | UTF-8 | Python | false | false | 366 | py | import django
from django.test import TransactionTestCase
class TestJsonUtils(TransactionTestCase):
# Django requires an explicit setup() when running tests in PTVS
@classmethod
def setUpClass(cls):
super(TestJsonUtils, cls).setUpClass()
django.setup()
def test_identify_json_data_sam... | [
"grusinator@gmail.com"
] | grusinator@gmail.com |
c8b71e3b91a871f2dc99627693d550ff4be408fe | e4ec5b6cf3cfe2568ef0b5654c019e398b4ecc67 | /azure-cli/2.0.18/libexec/lib/python3.6/site-packages/azure/mgmt/network/v2017_09_01/models/express_route_circuits_routes_table_summary_list_result.py | db62dab03a898b918438cd3d316dd87a3d2c32b5 | [] | no_license | EnjoyLifeFund/macHighSierra-cellars | 59051e496ed0e68d14e0d5d91367a2c92c95e1fb | 49a477d42f081e52f4c5bdd39535156a2df52d09 | refs/heads/master | 2022-12-25T19:28:29.992466 | 2017-10-10T13:00:08 | 2017-10-10T13:00:08 | 96,081,471 | 3 | 1 | null | 2022-12-17T02:26:21 | 2017-07-03T07:17:34 | null | UTF-8 | Python | false | false | 1,251 | py | # coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes ... | [
"Raliclo@gmail.com"
] | Raliclo@gmail.com |
1d5a9de4a037605a35872b62a9cd7204b3ab99ae | a12d46e439d81ba0a60776f46eb60b1a158b8ac1 | /pfrl/utils/__init__.py | d632886211326ad92635ea4bae4dc51d21237a3a | [
"MIT"
] | permissive | TMats/pfrl | 1b2a529aec210b0e3064182433797460a64f79f5 | 9c591657a5433b8f23c589e01751408ee5d1dde5 | refs/heads/master | 2022-12-21T01:27:07.625802 | 2020-10-07T02:32:20 | 2020-10-07T02:32:20 | 284,470,130 | 0 | 0 | MIT | 2020-08-02T13:46:29 | 2020-08-02T13:46:28 | null | UTF-8 | Python | false | false | 548 | py | from pfrl.utils.batch_states import batch_states # NOQA
from pfrl.utils.conjugate_gradient import conjugate_gradient # NOQA
from pfrl.utils import env_modifiers # NOQA
from pfrl.utils.is_return_code_zero import is_return_code_zero # NOQA
from pfrl.utils.random_seed import set_random_seed # NOQA
from pfrl.utils.pre... | [
"muupan@gmail.com"
] | muupan@gmail.com |
96c96efe9ecb296cc2033b388891cae9edfce3eb | 9743d5fd24822f79c156ad112229e25adb9ed6f6 | /xai/brain/wordbase/nouns/_stooges.py | 1d4b04a9490a2094070e8d4dab9ac1b03b79dfd3 | [
"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 | 238 | py |
from xai.brain.wordbase.nouns._stooge import _STOOGE
#calss header
class _STOOGES(_STOOGE, ):
def __init__(self,):
_STOOGE.__init__(self)
self.name = "STOOGES"
self.specie = 'nouns'
self.basic = "stooge"
self.jsondata = {}
| [
"xingwang1991@gmail.com"
] | xingwang1991@gmail.com |
ea00ac9cf0ba38ce3d14ec9351fb5ce1d8ba4246 | a72f39b82966cd6e2a3673851433ce7db550429a | /openchat/openchat/models/imagemodel.py | f1310a355504ba28f45bdb8db17b6ed4d232bf6c | [
"Apache-2.0"
] | permissive | linxi1158/iMIX | 85841d6b95e1d99ed421a1ac3667658e49cae6fc | af87a17275f02c94932bb2e29f132a84db812002 | refs/heads/master | 2023-06-09T23:37:46.534031 | 2021-06-30T12:09:42 | 2021-06-30T12:09:42 | 381,608,650 | 0 | 0 | Apache-2.0 | 2021-06-30T07:08:40 | 2021-06-30T07:08:39 | null | UTF-8 | Python | false | false | 2,534 | py | import torch
from openchat.models.base_model import BaseModel
import openchat.config as cfg
from openchat.utils.prepare_image import detect_objects_on_single_image
from openchat.utils.transforms import build_transforms
import cv2
import sys
sys.path.insert(0, '/home/datasets/mix_data/openchat/scene_graph_benchmark-mai... | [
"hsslab.inspur@gmail.com"
] | hsslab.inspur@gmail.com |
0b25ae4c71c7ade397cad1698cadef5233b1b817 | ecb7e109a62f6a2a130e3320ed1fb580ba4fc2de | /reference-code/lambda/cm-premembers-backend/premembers/check/logic/check_asc/asc_item_16_logic.py | 8cec4f13cbcf037fbbe58d663cd87397596d2cb4 | [] | no_license | nisheeth84/prjs_sample | df732bc1eb58bc4fd4da6e76e6d59a2e81f53204 | 3fb10823ca4c0eb3cd92bcd2d5d4abc8d59436d9 | refs/heads/master | 2022-12-25T22:44:14.767803 | 2020-10-07T14:55:52 | 2020-10-07T14:55:52 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,861 | py | import inspect
from premembers.repository.const import CheckResult
from premembers.common import common_utils, S3Utils
from premembers.const.const import CommonConst
from premembers.exception.pm_exceptions import PmError
from premembers.common import FileUtils, date_utils, aws_common
from premembers.check.logic.check_... | [
"phamkhachoabk@gmail.com"
] | phamkhachoabk@gmail.com |
fad8cd1b400beabb441d442165b3a8bf0df6762a | cbf9f600374d7510988632d7dba145c8ff0cd1f0 | /virtual/XMLProContest/07/b.py | 35635e38d107de7b0178f53764dc410a73266496 | [] | no_license | sakakazu2468/AtCoder_py | d0945d03ad562474e40e413abcec39ded61e6855 | 34bdf39ee9647e7aee17e48c928ce5288a1bfaa5 | refs/heads/master | 2022-04-27T18:32:28.825004 | 2022-04-21T07:27:00 | 2022-04-21T07:27:00 | 225,844,364 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 543 | py | s = input()
if s[0] != "A":
print("WA")
else:
c_count = 0
for i in range(2, len(s)-1):
if s[i] == "C":
c_count += 1
if c_count == 1:
upper = 0
lower = 0
for i in s:
if 97 <= ord(i) <= 122:
lower += 1
else:
... | [
"sakakazu2468@icloud.com"
] | sakakazu2468@icloud.com |
a015ebe3fa675abc13b391e986aad5bcb118daa4 | 996bc055b89b5e103f345dd26b0883caffd1c9bc | /openstack/identity/v3/region.py | 1fdd1c20cda5780cde2af826cfa5caf2581b8f71 | [
"Apache-2.0"
] | permissive | starlingx-staging/stx-openstacksdk | be633cedf4740e8788b814eca68039df3de6fe4b | 93d4e95536c4824e2197b2a63a4438ff5c60b653 | refs/heads/master | 2020-03-18T03:00:29.254952 | 2018-11-23T18:27:59 | 2018-11-24T01:17:45 | 134,218,298 | 1 | 4 | Apache-2.0 | 2018-11-24T01:17:46 | 2018-05-21T04:34:40 | Python | UTF-8 | Python | false | false | 1,277 | py | # 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, software
# distributed under t... | [
"tengqim@cn.ibm.com"
] | tengqim@cn.ibm.com |
563575c004cb97e9beef32766003f08b7e584b18 | da386754e12ed3e251d5fb9091d9416b9f97edc7 | /sfepy/discrete/common/extmods/cmesh.pxd | 120eceb44f387f87854279f1d9895b7f2a036891 | [
"BSD-3-Clause"
] | permissive | nasseralkmim/sfepy | 5b5642f084b62632c1ca48035e510f27728e25ab | 647f1754bcd4fd103cd19a03ed36cb10ebc8fd15 | refs/heads/master | 2020-04-06T04:57:21.589694 | 2016-08-03T12:38:31 | 2016-08-03T12:38:31 | 65,736,316 | 2 | 1 | null | 2016-08-15T13:58:01 | 2016-08-15T13:58:01 | null | UTF-8 | Python | false | false | 3,893 | pxd | # -*- Mode: Python -*-
"""
C Mesh data structures and functions.
"""
cimport numpy as np
from libc.stdio cimport FILE, stdout
from types cimport uint32, int32, float64, complex128
cdef extern from 'string.h':
void *memcpy(void *dest, void *src, size_t n)
cdef extern from 'common.h':
void *pyalloc(size_t siz... | [
"cimrman3@ntc.zcu.cz"
] | cimrman3@ntc.zcu.cz |
7d84de5d28cd4b40bb4268adbdf0cb11c4199569 | 8cb8bfd2dae516612251039e0632173ea1ea4c8a | /modules/analyzes/employment/models.py | 05c8ebbf391dc038ba5a93dbda7e187bdd3c6fba | [] | no_license | nyzsirt/lift-prod | 563cc70700d26a5812a1bce0bd9795998dce6e99 | 9a5f28e49ad5e80e422a5d5efee77a2d0247aa2b | refs/heads/master | 2020-04-22T01:05:42.262876 | 2019-02-09T13:31:15 | 2019-02-09T13:31:15 | 170,003,361 | 1 | 0 | null | 2019-02-10T17:11:50 | 2019-02-10T17:11:50 | null | UTF-8 | Python | false | false | 1,074 | py | import datetime
from mongoengine import Document
from mongoengine import StringField
from mongoengine import DateTimeField
from mongoengine import ObjectIdField
from mongoengine import DecimalField
from mongoengine import ReferenceField
from modules.analyzes.employment.kat_hesap_tipleri.models import KatHesapTipleri
... | [
"mutlu.erdem@soft-nec.com"
] | mutlu.erdem@soft-nec.com |
36e370f7a59eb4a0f324af58795cd112dc7ceb73 | 9a819fc91e17ef9a44e45cf68e76cf696381d06d | /cdk_examples/cdk.out/asset.50ce0df99f68b771fed9c79fa8d531712d8d56eadb6b19697b42dfa31931f8ff/chardet/cli/chardetect.py | 2f1156136c9af217a753fafdb0dd5b3a7cf52a9b | [] | no_license | Gautam3994/Dark-Knight | aef1d6383e0785130db75e80ed40f544a120579e | 327b2d58851a42da1b707addea73e40fac6a61cc | refs/heads/master | 2022-12-01T11:58:39.857379 | 2020-09-05T18:07:51 | 2020-09-05T18:07:55 | 203,866,327 | 0 | 1 | null | 2022-11-24T09:16:18 | 2019-08-22T20:14:43 | Python | UTF-8 | Python | false | false | 2,764 | py | #!/usr/bin/env python
"""
Script which takes one or more file paths and reports on their detected
encodings
Example::
% chardetect somefile someotherfile
somefile: windows-1252 with confidence 0.5
someotherfile: ascii with confidence 1.0
If no paths are provided, it takes its input from stdin.
"""
from... | [
"gautam3994@gmail.com"
] | gautam3994@gmail.com |
9a0dd6f10c652e2de3589f21c50e5edd3f286226 | 389569a591284a2adcdc38046114e7b1038afd94 | /python-script/trax/remove_duplicate.py | 01e34ae3b7890c0987c7795f288b8816e515b37c | [] | no_license | xytysingle/AnnotationTool | b797daf2fd472f602341b16f24fb1ed9b702aef1 | a217d4376ceee739e0d8c43515c403133982e86e | refs/heads/master | 2020-04-11T18:16:10.438919 | 2019-07-31T10:21:18 | 2019-07-31T10:21:18 | 161,992,153 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,431 | py | # !/usr/bin/env python
# -*- coding: utf-8 -*-
"""
@Author: Kong Haiyang
@Date: 2018-05-21 09:40:31
"""
from __future__ import absolute_import, division, print_function
import hashlib
import os
from os import walk
import time
from PIL import Image
from tqdm import tqdm
path1 = '/Users/lingmou/Desktop/堆头项目/duito... | [
"2463072824@qq.com"
] | 2463072824@qq.com |
d3c4e601c45ab7daa7422417c26f7028a4043b80 | cd78d84441e69c1fc40b6a6e9e235e7cf6882454 | /python/110.balanced_binary_tree.py | e5b1cf1d1f013903993e66591250ea684ad21e5e | [] | no_license | buy/leetcode | 53a12d4e0298284a5a2034c88353d0dc195aa66c | da0e834e3f2e3016396fffc96ef943ab9ec58ea4 | refs/heads/master | 2021-01-13T01:48:01.176632 | 2015-06-14T06:17:17 | 2015-06-14T06:17:17 | 31,863,627 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 826 | py | # Given a binary tree, determine if it is height-balanced.
# For this problem, a height-balanced binary tree is defined as a binary tree in which the depth of the two subtrees of every node never differ by more than 1.
# Definition for a binary tree node.
# class TreeNode:
# def __init__(self, x):
# self.... | [
"cliu@groupon.com"
] | cliu@groupon.com |
74fca21f256479a3865581a72ae58c5bc5d98d3b | 8268afb15bebb260a65c9b4c54ff3a6eb709c7c3 | /denoiser/lib_denoiser.py | 6d5d8e12ffdb9c77dea02f213f5c263bd84144f5 | [] | no_license | edublancas/yass-private | 2dc4b5b520c7effbece6f93bf74d39af918b5e29 | 33e9e83ccd6cc7a333b0199c11cdd81363ced846 | refs/heads/master | 2021-03-24T12:48:12.715117 | 2018-12-24T20:22:29 | 2018-12-24T20:22:29 | 108,217,478 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,548 | py | import numpy as np
from yass.templates import TemplatesProcessor
from yass.templates import util as templates_util
class SpikeIndex:
"""Wraps spike index logic
"""
def __init__(self, spike_index_array, channel_index=None, geometry=None,
neighbors=None):
self.arr = spike_index_... | [
"fkq8@blancas.io"
] | fkq8@blancas.io |
0130e5fb78d51a55447ac03623a3d816d1707af0 | c1ee8f22ece4fc39cb94fe19832fcba8e45cf5bc | /프로그래머스/체육복.py | 6418eba937f097af343006fbd58235dfaf80fd2e | [] | no_license | JeongHanJun/BOJ | ae6b1c64c5b3226deef2708ae447aa1225333a92 | a865624fb0a9291b68f99af8535f708554fa0b41 | refs/heads/master | 2023-03-31T02:22:58.974437 | 2021-04-02T02:43:57 | 2021-04-02T02:43:57 | 258,809,902 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,921 | py | # 체육복
'''
# testcase #11 실패 코드
def solution(n, lost, reserve):
answer = 0
students = [1] * (n+2)
for i in reserve:
students[i] += 1
for i in lost:
students[i] -= 1
for i in range(1, n+1):
if students[i] == 2:
if students[i-1] == 0:
stu... | [
"noreply@github.com"
] | JeongHanJun.noreply@github.com |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.