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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
f2edfe179c6a18015940a9ce02b525818d25de88 | 7b0c90185aa3d4ae7c422ff32fcc0ebf930f1eed | /venv/bin/rst2latex.py | 002c40782a6d22022fddcd97bd7aa49b9d76b130 | [] | no_license | skilllauncher/lets-hi5 | d3c83052886027575e5e3b5d4e92cb934105fab5 | 8277d3ea641b44fc70c4bfb1f5581e6ae8e395cb | refs/heads/master | 2020-03-24T03:14:35.276636 | 2018-07-26T08:14:19 | 2018-07-26T08:14:19 | 142,410,670 | 0 | 1 | null | 2018-07-26T08:16:33 | 2018-07-26T08:16:33 | null | UTF-8 | Python | false | false | 829 | py | #!/Users/saicharanreddy/Desktop/lets-hi5/venv/bin/python
# $Id: rst2latex.py 5905 2009-04-16 12:04:49Z milde $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
A minimal front end to the Docutils Publisher, producing LaTeX.
"""
try:
import locale
... | [
"saicharan.reddy1@gmail.com"
] | saicharan.reddy1@gmail.com |
8e0e9ff54a1b264abfcc842a94ec36f8c53d0cfa | ff29c013c24068e7409340ba1cd5b88cf3e82436 | /kobocat/onadata/libs/authentication.py | 20d192ec92a035efa730aba0877ea328cb992763 | [
"BSD-2-Clause"
] | permissive | Jubair70/Acid-Survivors-MIS | 01c64a0589e5ed275d9f1a9cf5973303ea4b937e | 89f19607d18a6d4c88717527e2e8d557aaec2fa9 | refs/heads/master | 2021-05-26T11:26:34.503102 | 2019-08-26T10:38:59 | 2019-08-26T10:38:59 | 254,112,228 | 1 | 0 | null | 2020-04-08T14:53:52 | 2020-04-08T14:33:00 | HTML | UTF-8 | Python | false | false | 906 | py | from django.utils.translation import ugettext as _
from django_digest import HttpDigestAuthenticator
from rest_framework.authentication import (
BaseAuthentication, get_authorization_header)
from rest_framework.exceptions import AuthenticationFailed
class DigestAuthentication(BaseAuthentication):
def __init__... | [
"jubair@mpower-social.com"
] | jubair@mpower-social.com |
8d8d28d252d52ec1db6699a9526d2c622795c93d | df2cbe914f463ad050d7ed26194424afbe3a0a52 | /addons/account/models/account_full_reconcile.py | f2ff0ea0895aae478432ed3fde5739b1a75f6bec | [
"Apache-2.0"
] | permissive | SHIVJITH/Odoo_Machine_Test | 019ed339e995be980606a2d87a63312ddc18e706 | 310497a9872db7844b521e6dab5f7a9f61d365a4 | refs/heads/main | 2023-07-16T16:23:14.300656 | 2021-08-29T11:48:36 | 2021-08-29T11:48:36 | 401,010,175 | 0 | 0 | Apache-2.0 | 2021-08-29T10:13:58 | 2021-08-29T10:13:58 | null | UTF-8 | Python | false | false | 1,646 | py | # -*- coding: utf-8 -*-
from odoo import api, fields, models, _
class AccountFullReconcile(models.Model):
_name = "account.full.reconcile"
_description = "Full Reconcile"
name = fields.Char(string='Number', required=True, copy=False, default=lambda self: self.env['ir.sequence'].next_by_code('account.reco... | [
"36736117+SHIVJITH@users.noreply.github.com"
] | 36736117+SHIVJITH@users.noreply.github.com |
be55eb5dd2519645a214a1282c5a37ce629cb118 | a02a40f0df624c74820ad25c27a5e2fb683610f7 | /qc2tsv/qc2tsv.py | eb179093ed0160a01ab0fa2d4d89c1f3518cddb7 | [
"MIT"
] | permissive | ENCODE-DCC/qc2tsv | d3d688bd3f4b3afb0ec4ba7969a001bb9cb7afb2 | f6bd9959d71254a10792bc30414dddcdcdf3865c | refs/heads/master | 2020-09-01T20:49:34.641168 | 2020-08-10T19:39:36 | 2020-08-10T19:39:36 | 219,053,354 | 2 | 0 | MIT | 2020-08-10T19:39:38 | 2019-11-01T19:54:50 | Python | UTF-8 | Python | false | false | 4,980 | py | import json
import logging
import pandas
from copy import deepcopy
from autouri import AutoURI, AbsPath
from caper.dict_tool import split_dict, merge_dict
logger = logging.getLogger(__name__)
class Qc2Tsv(object):
"""Qc2Tsv converts multiple JSON objects into a single spreadsheet
Its header will have multip... | [
"leepc12@gmail.com"
] | leepc12@gmail.com |
227c923b155c129254ce3c05e10ed9edd285112b | 793318429f3ea697f257b1340f198e2aa9ee46d3 | /pytorch_sentiment_analysis/2lstm.py | 6808356605274436439b62b40e1c0162a1cd46b0 | [
"MIT"
] | permissive | PandoraLS/python_toys | 129eeaba03c6c81509fded2c56e3ac922d22ee41 | d3f78815ada5c20863656c643342d48bcc3aef53 | refs/heads/main | 2023-03-22T18:53:22.028849 | 2021-03-18T14:32:36 | 2021-03-18T14:32:36 | 349,050,335 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,487 | py | #!/usr/bin/env python
# coding: utf-8
# 同样使用RNN,本节的改进如下
#
# * 预训练的词向量
# * 不同的RNN结构(LSTM)
# * 多层RNN
# * 正则化
# * 不同的优化器
# ---
# ## 1. 数据准备
#
# 通过预训练词向量初始化每个词
# In[3]:
import torch
from torchtext import data, datasets
import random
import time
SEED = 1234
begin_t = time.time()
torch.manual_seed(SEED)
torch.cuda.... | [
"lisen_work@163.com"
] | lisen_work@163.com |
969aee15d51bbe3bb9dc711ec920609108fc317f | ce76b3ef70b885d7c354b6ddb8447d111548e0f1 | /other_hand_or_government.py | 6422da2f135a28999761b5955c922750ace9b5de | [] | no_license | JingkaiTang/github-play | 9bdca4115eee94a7b5e4ae9d3d6052514729ff21 | 51b550425a91a97480714fe9bc63cb5112f6f729 | refs/heads/master | 2021-01-20T20:18:21.249162 | 2016-08-19T07:20:12 | 2016-08-19T07:20:12 | 60,834,519 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 242 | py |
#! /usr/bin/env python
def thing_and_part(str_arg):
number_and_big_point(str_arg)
print('person_and_next_point')
def number_and_big_point(str_arg):
print(str_arg)
if __name__ == '__main__':
thing_and_part('place_or_year')
| [
"jingkaitang@gmail.com"
] | jingkaitang@gmail.com |
0902603a00ec16a6c553ebb574aaaaee0f7380b5 | c521d9934cc92390a8bd51c0a5a37257bf1a29df | /mkt/feed/fakedata.py | 6c1e068efe1e236cb05442005c0048d66f5f1a96 | [] | no_license | graingert/zamboni | 1f36992205fbd1329d0d0b0b2bcdb558f363cf60 | d92a0aa4ac6d3129bf3b72b3a8a2a223ced22ef3 | refs/heads/master | 2021-01-22T12:44:36.287310 | 2015-04-17T13:05:11 | 2015-04-17T13:05:11 | 34,050,296 | 0 | 0 | null | 2015-04-16T10:49:13 | 2015-04-16T10:49:12 | null | UTF-8 | Python | false | false | 6,408 | py | import hashlib
import random
from django.core.files.storage import default_storage as storage
from mpconstants.collection_colors import COLLECTION_COLORS
import pydenticon
from mkt.constants.regions import REGIONS_DICT
from mkt.constants.carriers import CARRIER_CHOICE_DICT
from mkt.webapps.fakedata import foreground,... | [
"ashort@mozilla.com"
] | ashort@mozilla.com |
615c56157da6e85bb253d3360f1fe42404143c73 | 382d9643dfc15aaf605112fa1624c2cca5300106 | /build/lib/BearSki/utils/hartool.py | 0d873891b1ad430ed6af29a946532e6fa886a59b | [
"MIT"
] | permissive | xglh/BearSki | 150f67c42d263d142656c4d5e254c1b0472bee12 | ba4c34de658a1b744694a9424b63bd9a5795c42f | refs/heads/master | 2021-06-10T19:10:44.559173 | 2020-03-14T14:02:44 | 2020-03-14T14:02:44 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,867 | py | # -*- encoding: utf-8 -*-
'''
@File : hartool.py
@Time : 2020/01/29 15:29:32
@Author : chenjiusi
'''
import logging
import json,os
from har2case.core import HarParser
from BearSki.utils.arguments import runArg
from BearSki.template import ApiTest_har
logger=logging.getLogger("BearSki.HarTool")
class Har... | [
"chen6_9@163.com"
] | chen6_9@163.com |
643efd214235c664eeffb24299b11c9b101390ab | ded10c2f2f5f91c44ec950237a59225e8486abd8 | /.history/2/matrix_squaring_run_20200424192105.py | 875feea371ca462d383947ebe8dcbfabd7f8fd6b | [] | no_license | jearistiz/Statistical-Physics-Projects | 276a86407b32ded4e06b32efb2fadbd8eff8daed | d9c5b16a50856e148dc8604d92b6de3ea21fc552 | refs/heads/master | 2022-11-05T03:41:23.623050 | 2020-06-28T06:36:05 | 2020-06-28T06:36:05 | 254,909,897 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,213 | py | from matrix_squaring import *
################################################################################################
# PANEL DE CONTROL
################################################################################################
# Decide si corre algoritmo matrix squaring con aproximación de trotter
ru... | [
"jeaz.git@gmail.com"
] | jeaz.git@gmail.com |
a9b9060400b2d7c665146225a0b6e3d64c518c3a | 11763b1150a3a05db89c13dcd6152f8fcca87eaa | /designs/linear/homomorphic/latticebased/keyagreement11.py | f9a954cf9ab102e26637538b7316f642ae13b71d | [] | no_license | acad2/crypto | 343c32fa25aaec73e169290579fc3d02c4b226f6 | cb283df4101fcd618a0478a0018273f00d0734ae | refs/heads/master | 2021-08-19T06:36:26.068033 | 2017-11-25T00:41:03 | 2017-11-25T00:41:03 | 113,048,326 | 2 | 0 | null | 2017-12-04T13:49:02 | 2017-12-04T13:49:01 | null | UTF-8 | Python | false | false | 2,049 | py | #s(a + e)
#x(a + y)
# as + se 16 32 48 32 48 80
# ax + xy
#se(ax + xy) == axse + xyse == xs(ae + ye)
#xy(as + se) == asxy + xyse == xs(ay + ye)
# 24 32 32 32 32 32 32 32 128 - 120 = 8
# 48 64 64 64 64 64 64 64 ... | [
"python_pride@protonmail.com"
] | python_pride@protonmail.com |
0ef5ddc8e7980eeeaa8c87ee02a17c7dd1c0cae8 | 969b7b94eba36e07ce89b41dd2d3201988fda9e4 | /coverage_overlay/old-version/overlap.py | 0142937bd87011e58983fdf807f4197046f4980c | [] | no_license | shahbazymoh/proteomicstools | b1554c5c1729c04ab478d7bcc2cbaeaa8886bcf6 | 59bfcd19ed05ceb59b98bc1d37515b7ff0581da2 | refs/heads/master | 2021-05-30T11:03:10.482346 | 2016-02-03T01:36:39 | 2016-02-03T01:36:39 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,430 | py | from __future__ import print_function
import csv
import uniprot
import re
def clean_seqid(seqid):
pieces = seqid.split('|')
return pieces[1]
def is_overlap(i1, seq1, i2, seq2):
j1 = i1 + len(seq1)
j2 = i2 + len(seq2)
if i1 >= j2 or i2 >= j1:
return False
return True
def gap(i1, seq1, i... | [
"apposite@gmail.com"
] | apposite@gmail.com |
e6e0ebace35bc62a8bc4052e358519b0eb898000 | 87cecf5db9c46b86290e468216d6d6d0bc648d29 | /nerodia/element_collection.py | ebbca08cf9b986d77f0dd89fe1a931a6894f28ca | [
"MIT"
] | permissive | ed00m/nerodia | 84efcb8a5a9b798af669c346a77fb12dfffe475f | 8a1aff52942cf5a58567fb5753cb0a1974310b5a | refs/heads/master | 2020-03-27T16:15:36.202560 | 2018-08-30T14:28:11 | 2018-08-30T14:28:11 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,561 | py | from importlib import import_module
from itertools import islice
import nerodia
from .locators.class_helpers import ClassHelpers
class ElementCollection(ClassHelpers):
def __init__(self, query_scope, selector):
self.query_scope = query_scope
self.selector = selector
self.generator = ()
... | [
"lucast1533@gmail.com"
] | lucast1533@gmail.com |
2e143358fc3e1ac3a4de45f1c3825d405d0e713e | e953441fb81040ca1c55dc4c410fb606dda000ef | /humanoid_maze/envs/humanoid_maze.py | e537da5274eb489e281014768e92b5704974f2e5 | [] | no_license | Rowing0914/MuJoCo_Humanoid_Maze | 5dd25f408526e9666e84e7902a0054a796c496a1 | 2da3330dd58d27ab5b07507e69d0efa466a45d40 | refs/heads/master | 2020-06-21T12:29:56.540230 | 2019-07-17T19:45:39 | 2019-07-17T19:45:39 | 197,451,363 | 3 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,441 | py | # https://github.com/openai/gym/blob/master/gym/envs/mujoco/humanoid_v3.py
import numpy as np
from gym.envs.mujoco import mujoco_env
from gym import utils
DEFAULT_CAMERA_CONFIG = {
'trackbodyid': 1,
'distance': 4.0,
'lookat': np.array((0.0, 0.0, 2.0)),
'elevation': -20.0,
}
def mass_center(model, si... | [
"kosakaboat@gmail.com"
] | kosakaboat@gmail.com |
8db1dd021ad9782e8d54300ed0170c3c75dd5f50 | be0fdb8cd97067212788a1e3d7acb3e03a7a4258 | /data_loader.py | 68ecc46c27a7e9c540f5782664b5ad174399b0c3 | [] | no_license | speedcell4/logistic | dacca0c98a1cf201c1ae47d094823dab9198917e | 0ef2564b400cc8a5bea9f81b4ec9dd8dd630cd61 | refs/heads/master | 2020-03-21T02:43:15.067612 | 2018-06-20T10:05:14 | 2018-06-20T10:05:14 | 138,014,390 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,347 | py | from collections import Counter
from pathlib import Path
from random import shuffle
project_dir = Path(__file__).expanduser().absolute().parent
positive = project_dir / 'data' / 'data' / 'books' / 'positive.review'
negative = project_dir / 'data' / 'data' / 'books' / 'negative.review'
def sentence_stream(path: Path)... | [
"speedcell4@gmail.com"
] | speedcell4@gmail.com |
5261207a2efcbd341065c3dc64ec1e5c816a1b63 | 245a3f8cea6f232bf3142706c11188b51eb21774 | /python/hetu/gpu_links/MatrixDivideConstLink.py | a613061bff3e74d4d6f4526b31cf818adffcce45 | [
"Apache-2.0"
] | permissive | initzhang/Hetu | 5bfcb07e62962fbc83def14148f8367fab02625a | 447111a358e4dc6df5db9c216bdb3590fff05f84 | refs/heads/main | 2023-06-20T18:37:21.760083 | 2021-07-27T04:37:48 | 2021-07-27T04:37:48 | 389,848,768 | 0 | 0 | Apache-2.0 | 2021-07-27T04:32:57 | 2021-07-27T04:32:57 | null | UTF-8 | Python | false | false | 395 | py | from __future__ import absolute_import
import ctypes
from .._base import _LIB
from .. import ndarray as _nd
def matrix_elementwise_divide_const(val, in_mat, out_mat, stream=None):
assert isinstance(in_mat, _nd.NDArray)
assert isinstance(out_mat, _nd.NDArray)
_LIB.DLGpuMatrixDivConst(
ctypes.c_flo... | [
"swordonline@foxmail.com"
] | swordonline@foxmail.com |
08d3f21518ff323ed41e12bbf58539628b0d1d8b | c291ba4506a8998df8d7f384c911f6a0a1294001 | /bai__48/KhaiNiemVeHam.py | 98b0fa0105f06dadc22e7a9e273b79f3d0b51d22 | [] | no_license | thanh-falis/Python | f70804ea4a3c127dcb7738d4e7c6ddb4c5a0a9d4 | fa9f98d18e0de66caade7c355aa6084f2d61aab3 | refs/heads/main | 2023-08-18T17:34:29.851365 | 2021-09-30T12:09:30 | 2021-09-30T12:09:30 | 398,952,505 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 515 | py | '''
- Hàm là một khối lệnh thực hiện một công việc hoàn chỉnh (mudule),
được đặt tên và gọi thực thj nhiều lần tại nhiều vị trí trong chuong trình.
- Hàm còn được gọi là chương trình con.
- Nếu không viết hàm thì
+ Rất khó để viết chính xác khi dự án lớn
+ Khó debug
+ Khó mở rộng
- có 2 loại hàm:
+ Hàm... | [
"thanhelma2020|@gmail.com"
] | thanhelma2020|@gmail.com |
311fd6ae560e67365300344f56e6f7c6b238c27a | c3a76533d1fbb53f291f49fb95b5e89ed69a75f5 | /好咧,最后还是要搞google/hard/RangeSumQuery2DMutable308.py | ac4a3007e5e59c792b05380b333bcff23f1254be | [] | no_license | jing1988a/python_fb | 5feb68efd32bd63952b4df0c0cd2e766b83451ea | fd310ec0a989e003242f1840230aaac150f006f0 | refs/heads/master | 2020-03-28T21:03:19.375549 | 2019-01-31T17:02:17 | 2019-01-31T17:02:17 | 149,125,354 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,380 | py | # Given a 2D matrix matrix, find the sum of the elements inside the rectangle defined by its upper left corner (row1, col1) and lower right corner (row2, col2).
#
#
# The above rectangle (with the red border) is defined by (row1, col1) = (2, 1) and (row2, col2) = (4, 3), which contains sum = 8.
#
# Example:
# Given mat... | [
"jing1988a@gmail.com"
] | jing1988a@gmail.com |
bd3d29706b19819ef147fd249b1fa1c9c7a3a5da | 9889e7fd73314382fb2f9e8f63d92cf3254b75fb | /Vaango/src/StandAlone/inputs/MPM/J2PlasticityModels/J2Test_07_HydrostaticLoadUnload.py | 964f66a2f9b7b9d044a6331b35f7a3df04c15cf0 | [] | no_license | bbanerjee/ParSim | 0b05f43cff8e878658dc179b4a604eabd873f594 | 87f87816b146f40013a5e6648dfe20f6d2d002bb | refs/heads/master | 2023-04-27T11:30:36.252023 | 2023-04-13T22:04:50 | 2023-04-13T22:04:50 | 13,608,512 | 16 | 3 | null | null | null | null | UTF-8 | Python | false | false | 4,849 | py | from J2TestSuite_PostProcUtils import *
from J2YieldSurfaceUtils import *
def hydrostaticLoadUnload(uda_path, save_path,**kwargs):
print("Post Processing Test: 07 - hydrostatic Compression With Loading and Unloading")
# Read the stress simulation data
times, sigmas, sigma_a_sim, sigma_r_sim, sigma_ar_sim, pp_si... | [
"b.banerjee.nz@gmail.com"
] | b.banerjee.nz@gmail.com |
4b17c48950b5703e184c9e5989c37bc617dbc282 | 796f96e8c01db0bb9493c4871be66d92689b73ab | /백준특강대비/7551 pqr(못품)/beakjun3.py | a68b609e1ab473b2ce655f7828e8e1e058986c16 | [] | no_license | swhan9404/swExpertAcademy | cf82b957b7ea6231d1f4b95f77f74e7717d2de0d | dea4176229121983c6daed80811de20de6da5ff6 | refs/heads/master | 2023-04-19T22:57:37.111757 | 2021-05-02T14:58:44 | 2021-05-02T14:58:44 | 337,338,058 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 980 | py | import math
# p * q를 넣었을 때 필요한 arr[r]을 구하는 메서드
def getVal(i, j):
val = K // math.gcd(K, arr[i])
val = val // math.gcd(val, arr[j])
return val
def pqr(N, arr):
# key : 필요한 arr[r]
# val : 개수
pq_dic = {}
pq_dic[getVal(0, 1)] = 1
count = 0
for r in range(2, N):
for pq in pq_... | [
"swhan9404@naver.com"
] | swhan9404@naver.com |
d1f59b1f9aa84f499108cd6bef7c8587bd0cd50d | 028d788c0fa48a8cb0cc6990a471e8cd46f6ec50 | /Python-Web/pythons/pythons/settings.py | 93838833498a2b5c20877f91d18fe4b3b7bcc5c9 | [] | no_license | Sheko1/SoftUni | d6b8e79ae545116f4c0e5705ad842f12d77a9c9d | a9fbeec13a30231b6a97c2b22bb35257ac1481c0 | refs/heads/main | 2023-07-13T15:39:48.826925 | 2021-08-21T12:51:02 | 2021-08-21T12:51:02 | 317,266,200 | 2 | 3 | null | null | null | null | UTF-8 | Python | false | false | 3,159 | py | """
Django settings for pythons project.
Generated by 'django-admin startproject' using Django 3.0.4.
For more information on this file, see
https://docs.djangoproject.com/en/3.0/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/3.0/ref/settings/
"""
import os
#... | [
"martinkypar@gmail.com"
] | martinkypar@gmail.com |
b1b5472d4feb7ec07917f68036bc5806fb608af3 | d963fb56dbb92cc7317c0a042c9059239ebaa028 | /problems/AE59.py | f68623c9ff4659b56d6c696b45c4688cf85ec956 | [] | no_license | ClaudioCarvalhoo/you-can-accomplish-anything-with-just-enough-determination-and-a-little-bit-of-luck | 20572bde5482ddef379506ce298c21dd5e002492 | df287ed92a911de49ed4bc7ca5a997d18a96c3f6 | refs/heads/master | 2023-06-02T16:27:57.994351 | 2021-06-24T23:16:47 | 2021-06-24T23:16:47 | 284,845,707 | 1 | 0 | null | 2020-10-29T21:35:30 | 2020-08-04T01:24:23 | Python | UTF-8 | Python | false | false | 554 | py | # Sum of Linked Lists
# O(max(n, m))
# n = len(linkedListOne) | m = len(linkedListTwo)
def sumOfLinkedLists(linkedListOne, linkedListTwo):
res = LinkedList(None)
curRes = res
curOne = linkedListOne
curTwo = linkedListTwo
carry = 0
while curOne or curTwo or carry > 0:
val1 = 0
val2 = 0
if curOne:
val... | [
"carvalhooclaudio@gmail.com"
] | carvalhooclaudio@gmail.com |
11d61fa58038c3e79014caf950f9575522104906 | f366c19ce822a3e8f3cd5f670b25c6fa54322d0b | /python_udemy/introducao-python/combinations-permutations-product.py | 8d169448eb5230b183f3e546f5c00d63b9fb39ec | [] | no_license | marcelomatz/py-studiesRepo | b83875a366010c9a60bc15d853fcf81c31cee260 | ce99014228f00d8c73cc548dd6c4d5fedc3f1b68 | refs/heads/main | 2023-09-05T00:03:47.712289 | 2021-06-15T09:43:27 | 2021-06-15T09:43:27 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 633 | py | """
Combinations, Permutations e Product - Itertools
Combinação - Ordem não importa
Permutação - Ordem importa
Ambos não repetem valores únicos
Produto - Ordem importa e repete valores únicos
"""
from itertools import combinations, permutations, product
# pessoas = ['Marcelo', 'André', 'Ana', 'João', 'Larissa', 'Silv... | [
"agenciahipster@gmail.com"
] | agenciahipster@gmail.com |
c5da74564f339261ee7acfb82368cc4a5ef17348 | 88dfb9a6ce6a094e5b61deeed3d05ee043067a27 | /Activities/migrations/0011_auto_20160406_1100.py | 3505062bd39317eadfc61a58b2eb571977f9c4cd | [] | no_license | jsyx1994/pinu | 9aebcf4dbc454b3bf19a4b0d6fb355e02409edc3 | ac79d1fcecb13b260dfa3570240a0a86380b2161 | refs/heads/master | 2021-01-10T09:26:52.436373 | 2019-07-23T02:22:32 | 2019-07-23T02:22:32 | 55,506,885 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 627 | py | # -*- coding: utf-8 -*-
# Generated by Django 1.9.5 on 2016-04-06 03:00
from __future__ import unicode_literals
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('Activities', '0010_auto_201... | [
"526593251@qq.com"
] | 526593251@qq.com |
06977c84ef4943b2f2b9de193047098885436e9c | 6a0930a8762caa3aff74d376a38d581d25240189 | /backend/course/api/v1/serializers.py | da73f0615ea1e9f2628834db782765a74df1ec3a | [] | no_license | crowdbotics-apps/teset101-22014 | d26c1b64bfbe6fa6f7a55074f0bfcd0c7b603eda | dd18df5fc13b428ec6888005bc343120ac8d166b | refs/heads/master | 2023-01-06T05:45:54.757818 | 2020-10-27T18:45:06 | 2020-10-27T18:45:06 | 307,771,871 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,622 | py | from rest_framework import serializers
from course.models import (
Recording,
Event,
Subscription,
Course,
Group,
Module,
PaymentMethod,
SubscriptionType,
Enrollment,
Lesson,
Category,
)
class EventSerializer(serializers.ModelSerializer):
class Meta:
model = Eve... | [
"team@crowdbotics.com"
] | team@crowdbotics.com |
7bbc7e4c9690bf90ffb4bec114c9d97a27a627f5 | c8de76f87ef929e08b018bae5de20d3b3d8f9f78 | /santosCua/settings.py | 271c4d96a141bf9b4b88b7d91ad3a1025b2e06d2 | [] | no_license | hanztura/santos-cua | 205dc3052f4107cbc3e819e25b4f913c890356ec | 5be4007d0d75e5d5438b4e1f1e6793d60c4e34ec | refs/heads/master | 2021-08-24T16:06:25.085178 | 2017-11-29T16:40:52 | 2017-11-29T16:40:52 | 111,128,100 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,140 | py | """
Django settings for santosCua project.
Generated by 'django-admin startproject' using Django 1.11.6.
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 ... | [
"hctura.official@gmail.com"
] | hctura.official@gmail.com |
fc59bc762240df0da1577655afc2b35089481cc0 | ef6229d281edecbea3faad37830cb1d452d03e5b | /ucsmsdk/mometa/equipment/EquipmentPfcMmuCap.py | a58342d74435dcb78bd5264dc18854db4e11d29c | [
"Apache-2.0"
] | permissive | anoop1984/python_sdk | 0809be78de32350acc40701d6207631322851010 | c4a226bad5e10ad233eda62bc8f6d66a5a82b651 | refs/heads/master | 2020-12-31T00:18:57.415950 | 2016-04-26T17:39:38 | 2016-04-26T17:39:38 | 57,148,449 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,385 | py | """This module contains the general information for EquipmentPfcMmuCap ManagedObject."""
import sys, os
from ...ucsmo import ManagedObject
from ...ucscoremeta import UcsVersion, MoPropertyMeta, MoMeta
from ...ucsmeta import VersionMeta
class EquipmentPfcMmuCapConsts():
INT_ID_NONE = "none"
POLICY_OWNER_LOCAL... | [
"test@cisco.com"
] | test@cisco.com |
026b94cfbca00fbfec261053f3cf317886e7e818 | 185169048d1b0b584fdef39c9505f8ea6255b7c3 | /tests/unit/test_serializers.py | a1f5e37c3bc02ad6701b30e239c4c183b9373de3 | [
"BSD-2-Clause"
] | permissive | sdbht/requests-cache | 410baad3910348fa586fc0bc40c82a9bcf00a861 | 73cc36133b7eb3d4f714b2199042d7b6fc6bd902 | refs/heads/master | 2023-08-11T02:52:38.137694 | 2021-10-10T19:05:53 | 2021-10-10T19:05:53 | 416,177,571 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,297 | py | # Note: Almost all serializer logic is covered by parametrized integration tests.
# Any additional serializer-specific tests can go here.
import json
import sys
from importlib import reload
from unittest.mock import patch
from uuid import uuid4
import pytest
from itsdangerous import Signer
from itsdangerous.exc import... | [
"jordan.cook@pioneer.com"
] | jordan.cook@pioneer.com |
0047bc2f0d1817d7ac10b9e6da28ca7d17faecf1 | fe8694029e6a3ebd4da74ddde71c2aea8664b615 | /setup.py | d8145bec8148ea5e4d624f7f76548ae63bdcd1b2 | [
"MIT"
] | permissive | sveetch/PO-Projects-client | 5cb50456b616ad5a8ab745eb0c43322361dd608f | e553cb2a8da9c113d3f4b605f156a8d150a2dae2 | refs/heads/master | 2021-01-16T01:01:48.617778 | 2014-07-26T14:56:11 | 2014-07-26T14:56:11 | 19,954,579 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 1,160 | py | from setuptools import setup, find_packages
setup(
name='PO-Projects-client',
version=__import__('po_projects_client').__version__,
description=__import__('po_projects_client').__doc__,
long_description=open('README.rst').read(),
author='David Thenon',
author_email='dthenon@emencia.com',
ur... | [
"sveetch@gmail.com"
] | sveetch@gmail.com |
4c4f472a3c2af26ec95db14be4693f1ed730c4e2 | 8d715aba85829ec824e119c83f324336f6a11883 | /arxiv/canonical/record/tests/test_listing.py | 22c5ed71a557e350598ac2c8359be3f128a4096e | [
"MIT"
] | permissive | arXiv/arxiv-canonical | 9155955075aaee5063ac5a6ff5ee99608ee6a128 | 407cb0b2cef83c7f653dabdf998e797b18475b13 | refs/heads/develop | 2023-04-13T14:59:59.167434 | 2023-03-17T17:18:12 | 2023-03-17T17:18:12 | 160,495,479 | 5 | 4 | MIT | 2023-02-07T23:16:15 | 2018-12-05T09:43:32 | Python | UTF-8 | Python | false | false | 3,794 | py | import io
import json
import os
import tempfile
from datetime import datetime
from pytz import UTC
from typing import IO
from unittest import TestCase, mock
import jsonschema
from ..core import RecordEntry
from ..listing import RecordListing
from ..version import RecordVersion, D
def fake_dereferencer(uri: D.URI) -... | [
"brp53@cornell.edu"
] | brp53@cornell.edu |
251b3c32c213565592f609af6280166f5120fd92 | 487ce91881032c1de16e35ed8bc187d6034205f7 | /codes/CodeJamCrawler/16_0_2/Rajnikanth/gapac_1.py | 528a6b43071f83547a1c014b5e3dd254e13977cf | [] | 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 | 482 | py | t = input()
for T in xrange(1,t+1):
print "Case #"+str(T)+":",
s = list(raw_input())+['#']
temp = 0
ans = 0
while(s[0]=='+'):
s.pop(0)
temp+=1
while(s[0]!='#'):
x = 0
while(s[0]=='-'):
s.pop(0)
x+=1
if(temp!=0):
... | [
"[dhuo@tcd.ie]"
] | [dhuo@tcd.ie] |
b57f0971021b54e3944fb18c60bd6f3b7bf72742 | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p03778/s021239120.py | 879487fb7a7e0b76dfc5b0b89e7933a2b9266b7d | [] | 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 | 278 | py | import sys
input = sys.stdin.readline
def I(): return int(input())
def MI(): return map(int, input().split())
def LI(): return list(map(int, input().split()))
def main():
mod=10**9+7
W,a,b=MI()
d1=max(0,b-(a+W))
d2=max(0,a-(b+W))
print(max(d1,d2))
main()
| [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
f9a48e523e0af79139a143e1dcde6296e0a697b5 | 7283ffa8da2f64a419218af0329b43fb055c4694 | /src/classify_softmax.py | e090acdc564e8375bec795f0a94ae6723b9e50e0 | [
"MIT"
] | permissive | modanesh/facenet | 996b11df5617a849ac9dab81f782a6aa99d6b83f | 0ca5a667b7168caada340dd1c7dbe36cead9fc72 | refs/heads/master | 2021-09-19T02:29:29.399713 | 2018-07-22T08:24:19 | 2018-07-22T08:24:19 | 112,828,989 | 1 | 0 | null | 2017-12-02T09:18:35 | 2017-12-02T09:18:35 | null | UTF-8 | Python | false | false | 4,947 | py | from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import argparse
from collections import Counter
import shutil
from scipy import misc
import tensorflow as tf
import numpy as np
import os
import facenet
import sys
np.set_printoptions(threshold=np.nan)
def m... | [
"mohamad4danesh@gmail.com"
] | mohamad4danesh@gmail.com |
0610b2da12be032cca602030b81b69f1803b8461 | 98c6ea9c884152e8340605a706efefbea6170be5 | /examples/data/Assignment_2/sbysiz002/question1.py | 27f32f4b6107608292622328cb7af08af88b754c | [] | no_license | MrHamdulay/csc3-capstone | 479d659e1dcd28040e83ebd9e3374d0ccc0c6817 | 6f0fa0fa1555ceb1b0fb33f25e9694e68b6a53d2 | refs/heads/master | 2021-03-12T21:55:57.781339 | 2014-09-22T02:22:22 | 2014-09-22T02:22:22 | 22,372,174 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 145 | py | x=eval(input("Enter a year:\n"))
if x%400==0 or x%4==0 and x%100!=0 :
print(x,"is a leap year.")
else :
print(x,"is not a leap year.") | [
"jarr2000@gmail.com"
] | jarr2000@gmail.com |
9411e951e27533f6611fd1c881d52275eaa24cd8 | 0c70dcec22a090e70b1f20613ea6e0a64fd9a037 | /GPS卫星位置的计算/venv/Lib/site-packages/pandas/io/sas/sasreader.py | 370a8baa5b3047371689818f36dbdc312d90aa46 | [
"MIT"
] | permissive | payiz-asj/Gis | 82c1096d830878f62c7a0d5dfb6630d4e4744764 | 3d315fed93e2ab850b836ddfd7a67f5618969d10 | refs/heads/main | 2023-06-27T15:25:17.301154 | 2021-08-03T10:02:58 | 2021-08-03T10:02:58 | 392,269,853 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 4,154 | py | """
Read SAS sas7bdat or xport files.
"""
from abc import ABCMeta, abstractmethod
from typing import TYPE_CHECKING, Optional, Union, overload
from pandas._typing import FilePathOrBuffer, Label
from pandas.io.common import stringify_path
if TYPE_CHECKING:
from pandas import DataFrame # noqa: F401
... | [
"1778029840@qq.com"
] | 1778029840@qq.com |
6ce2b5a34b712b1e165327443aef8be25161aa5e | 79020987de8d1ea21fc3d83d965ec594640f5e66 | /Wind/Architectures/NBeatsArchitecture.py | 7fd70b478ee991cb8d59fa606033556790730777 | [] | no_license | bejar/Wind | 63f6de218cdcace8a4e207f3f5fc4b5f66502fee | a339737ec23d6f54090396eda7d8507c313a8c79 | refs/heads/master | 2021-11-08T22:47:03.363133 | 2021-10-21T09:37:16 | 2021-10-21T09:37:16 | 93,608,891 | 7 | 2 | null | 2020-10-02T05:58:53 | 2017-06-07T08:02:38 | HTML | UTF-8 | Python | false | false | 4,458 | py | """
.. module:: NBeatsArchitecture
NBeatsArchitecture
******
:Description: NBeatsArchitecture
Implementation of the NBeats architecture:
Authors: Oreshkin, Boris N and Carpov, Dmitri and Chapados, Nicolas and Bengio, Yoshua
Pub: International Conference on Learning Representations. 2019.
Link: https... | [
"bejar@cs.upc.edu"
] | bejar@cs.upc.edu |
d219f89daf35876f7eb0e0f619ed2f5ab3f262d2 | f8d3d9bd1c97e9c14ae51ce35b0a49e902dc3a72 | /pacho/day02/day06/04分词.py | 010bd1d82074537a32cd103285b0ea5aa22c118e | [] | no_license | dingmf/mygit | 226cf38bae4a9fecd051733c375fed15f65d5fd2 | bbf36d31d2edbfae663fe45762457f3b98e05161 | refs/heads/master | 2022-11-30T17:18:09.197751 | 2018-09-12T07:40:55 | 2018-09-12T07:40:55 | 139,680,867 | 0 | 1 | null | 2022-11-28T16:17:01 | 2018-07-04T06:52:19 | Python | UTF-8 | Python | false | false | 235 | py | import jieba
str1 = '你可真skr弟弟,笑skr人!!!'
# 按搜索引擎搜索,带符号
mycut = jieba.cut_for_search(str1)
cutStr = jieba.cut(str1, cut_all=True)
print(mycut)
print('/'.join(mycut))
print('*'.join(cutStr)) | [
"1175674559@qq.com"
] | 1175674559@qq.com |
8e5f44a147c6f19cc4e28b11d1783cef2c418de1 | 5f4f3ab6ece4eda1066bda2f80b9cf89a898f409 | /0x06-python-classes/5-square.py | 03fb26572cf5137899c1684988e89074c8c5cc6f | [] | no_license | s0m35h1t/holbertonschool-higher_level_programming | 8af7f3bc54159efa05859f81ca3b9fb1739190e8 | f3b7ddeabf41b5cbc8460841c429b4b3bf254fea | refs/heads/master | 2020-09-28T20:32:23.955579 | 2020-05-14T20:22:50 | 2020-05-14T20:22:50 | 226,859,068 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,441 | py | #!/usr/bin/python3
"""Defines: class Square"""
class Square:
"""Represents a square
Attributes:
__size (int): size of a side of the square
"""
def __init__(self, size=0):
"""Initializes a square
Args:
size (int): size of a side of the square
Returns: Non... | [
"adib.grouz@gmail.com"
] | adib.grouz@gmail.com |
9bf1dd53a1f021085b6ad67f4a8ee62d5ebb370c | a6e4a6f0a73d24a6ba957277899adbd9b84bd594 | /sdk/python/pulumi_azure_native/storagecache/v20201001/__init__.py | 81cba06478ab89a63ffea2d18cb8fba1406ba9e4 | [
"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,237 | 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! ***
# Export this package's modules as members:
from ._enums import *
from .cache import *
from .get_cache import *
from .get_storage_target import *
from ... | [
"noreply@github.com"
] | MisinformedDNA.noreply@github.com |
6ff24a8b7e3a25b2617ad1080b4a92a7dfdcf9d1 | 53fab060fa262e5d5026e0807d93c75fb81e67b9 | /backup/user_161/ch161_2020_06_15_19_33_29_835504.py | 15945963281606445038fcdc114e6e253b984983 | [] | no_license | gabriellaec/desoft-analise-exercicios | b77c6999424c5ce7e44086a12589a0ad43d6adca | 01940ab0897aa6005764fc220b900e4d6161d36b | refs/heads/main | 2023-01-31T17:19:42.050628 | 2020-12-16T05:21:31 | 2020-12-16T05:21:31 | 306,735,108 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 388 | py |
def PiWallis(elementos):
numerador = 2
denominador = 1
contador = 0
multiplicacao = 1
while(contador < elementos):
multiplicacao *= numerador / denominador
#print("{0}/{1}".format(numerador, denominador))
if contador%2 == 0:
denominador += 2
else:
... | [
"you@example.com"
] | you@example.com |
f00d79c165da9f5f415dcbcd61dc41d4a99a4bbe | 505343f6ace00d22f8753c1a943a5794a619e698 | /katas/Python/3 kyu/Binomial Expansion 540d0fdd3b6532e5c3000b5b.py | d7a0668726b90a8fd963e987d8998d2735c4f972 | [] | no_license | bullet1337/codewars | 7652e50bf768bc47976a9124dd98b93602d4d458 | ba7f13ddd766158b41e036dae5d6b15f7f08761a | refs/heads/master | 2020-03-27T05:04:03.751302 | 2019-04-30T17:45:39 | 2019-04-30T17:45:39 | 145,991,995 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 998 | py | # https://www.codewars.com/kata/540d0fdd3b6532e5c3000b5b
from functools import lru_cache
import re
@lru_cache(maxsize=None)
def fact(n):
return 1 if n < 1 else n * fact(n - 1)
def c(n, k):
return fact(n) // (fact(k) * fact(n - k))
def format(a, x=True):
return ('+' if a > 0 else '-') + ('' if x and ab... | [
"alichek95@mail.ru"
] | alichek95@mail.ru |
90cfae906d2dbdf784cb82584a0604f5729e49dc | 7839d009f3ae0a0c1bc360b86756eba80fce284d | /devel/lib/python2.7/site-packages/gazebo_msgs/msg/_ODEPhysics.py | d26775045ca569df97509ded579dfc284ef87fac | [] | 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 | 6,359 | py | # This Python file uses the following encoding: utf-8
"""autogenerated by genpy from gazebo_msgs/ODEPhysics.msg. Do not edit."""
import sys
python3 = True if sys.hexversion > 0x03000000 else False
import genpy
import struct
class ODEPhysics(genpy.Message):
_md5sum = "667d56ddbd547918c32d1934503dc335"
_type = "gaz... | [
"abhat@wpi.edu"
] | abhat@wpi.edu |
18bfeb5cc6ceb600401c040391ad37ceb6251c8a | f023f1b025a49968c1050e7726054e2d69eaddd8 | /practice/practice_4/classde5.py | c65accd7059aa708beecf8de2936e5629602e814 | [] | no_license | soulorman/Python | 225444cab3ce65511ab91db753f07ce28e5bd239 | 4febccac57bfa5f7ef46f5f57e52206c8b0a57ac | refs/heads/master | 2023-05-11T01:50:08.012001 | 2020-06-22T07:14:24 | 2020-06-22T07:14:24 | 149,143,223 | 0 | 0 | null | 2023-04-29T10:08:28 | 2018-09-17T15:03:08 | Python | UTF-8 | Python | false | false | 285 | py | class Singleton(type):
def __call__(cls, *args,**kwargs):
if not hasattr(cls, '_instance'):
cls._instance = super().__call__(*args,**kwargs)
return cls._instance
class Foo(metaclass = Singleton):
pass
f1 = Foo()
f2 = Foo()
print(f1)
print(f2)
| [
"2379797392@qq.com"
] | 2379797392@qq.com |
8f10a168a255600db610bb7ffff9dddf7935dc82 | 5ffdef59c244f719c43ee24d23de7201bf42eab5 | /Model2-EASE/src/nltk/nltk/corpus/reader/rte.py | 1a0972e56044ae9be7ef08cee4bc1a56a684f7fa | [
"AGPL-3.0-only",
"LicenseRef-scancode-unknown-license-reference",
"MIT",
"Apache-2.0",
"LicenseRef-scancode-proprietary-license",
"CC-BY-NC-ND-3.0"
] | permissive | midas-research/calling-out-bluff | 8db408efe1c211a8685bfc1b2553117770689639 | 4de3c56b64edeeef9968288679c4e5b261e9949c | refs/heads/models_test | 2022-12-13T02:36:24.054646 | 2020-08-19T07:05:55 | 2020-08-19T07:05:55 | 280,080,456 | 10 | 9 | MIT | 2020-08-09T18:57:22 | 2020-07-16T07:07:19 | null | UTF-8 | Python | false | false | 4,586 | py | # Natural Language Toolkit: RTE Corpus Reader
#
# Copyright (C) 2001-2012 NLTK Project
# Author: Ewan Klein <ewan@inf.ed.ac.uk>
# URL: <http://www.nltk.org/>
# For license information, see LICENSE.TXT
"""
Corpus reader for the Recognizing Textual Entailment (RTE) Challenge Corpora.
The files were taken from the RTE1... | [
"meharmailbox@gmail.com"
] | meharmailbox@gmail.com |
fb0e647d59ffab8ab02a0836a0b6d540142cf42d | 4e3c976773526fd610d64ffb83589bccfaee5e68 | /sponge-integration-tests/examples/core/processors_scan_java_packages.py | cbce872a1ff83358bc79c246a6ea1149cfd127c7 | [
"Apache-2.0"
] | permissive | softelnet/sponge | 2313d2328953fcff49a002e727bb803757870627 | 7190f23ae888bbef49d0fbb85157444d6ea48bcd | refs/heads/master | 2022-10-28T16:19:55.619882 | 2021-09-16T19:50:08 | 2021-09-16T19:50:08 | 95,256,030 | 10 | 2 | Apache-2.0 | 2022-10-04T23:55:09 | 2017-06-23T20:58:49 | Java | UTF-8 | Python | false | false | 167 | py | """
Sponge Knowledge Base
Scanning Java-based processors
"""
def onLoad():
sponge.enableJavaByScan("org.openksavi.sponge.integration.tests.core.scanning")
| [
"marcin.pas@softelnet.com"
] | marcin.pas@softelnet.com |
7d25591fd9cf0ec0e907b3d119660f7d28b4951f | 5a52ccea88f90dd4f1acc2819997fce0dd5ffb7d | /alipay/aop/api/domain/AlipayUserFamilyShareRelationsSyncModel.py | e389c563bdbcf4ee6dd5b45b0e12ee326dd2ea53 | [
"Apache-2.0"
] | permissive | alipay/alipay-sdk-python-all | 8bd20882852ffeb70a6e929038bf88ff1d1eff1c | 1fad300587c9e7e099747305ba9077d4cd7afde9 | refs/heads/master | 2023-08-27T21:35:01.778771 | 2023-08-23T07:12:26 | 2023-08-23T07:12:26 | 133,338,689 | 247 | 70 | Apache-2.0 | 2023-04-25T04:54:02 | 2018-05-14T09:40:54 | Python | UTF-8 | Python | false | false | 6,168 | py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import json
from alipay.aop.api.constant.ParamConstants import *
class AlipayUserFamilyShareRelationsSyncModel(object):
def __init__(self):
self._expired_date = None
self._resource_content = None
self._resource_id = None
self._scene_i... | [
"jiandong.jd@antfin.com"
] | jiandong.jd@antfin.com |
e6b3b17394ae5c56893b76733cf80dc8bfcb603b | 93205a7cc036732b95b4002bfc766c02fc2a26e4 | /script/control_team_gold | 2b938f8ddf2faf3bd80c30719501cf4b032c2aaf | [
"Apache-2.0"
] | permissive | FrankGaLu/uctf | 2cd4e65d481e0f494ea0671ecd5c73277ddc513c | f7d597b9532995b1509cc29aed4ac7115c2b0cb8 | refs/heads/master | 2023-03-22T12:03:19.303123 | 2017-07-03T20:57:06 | 2017-07-03T20:57:06 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 136 | #!/usr/bin/env python
import sys
from uctf.control import control_team
if __name__ == '__main__':
sys.exit(control_team('gold'))
| [
"dthomas@osrfoundation.org"
] | dthomas@osrfoundation.org | |
033973ddc81a5fdf0e40009c4f321215fe3f4217 | 0ae2bb21d7ca71a691e33cb044a0964d380adda2 | /python/P523.py | 8ee3b72bfe030c43e82624dca3aa76adc9574477 | [] | no_license | xwang322/Coding-Interview | 5d27ec92d6fcbb7b929dd98bb07c968c1e1b2a04 | ee5beb79038675ce73c6d147ba9249d9a5ca346a | refs/heads/master | 2020-03-10T08:18:34.980557 | 2018-06-24T03:37:12 | 2018-06-24T03:37:12 | 129,282,263 | 2 | 6 | null | 2018-04-19T19:31:24 | 2018-04-12T16:41:28 | Python | UTF-8 | Python | false | false | 579 | py | class Solution(object):
def checkSubarraySum(self, nums, k):
if not nums or len(nums) == 1:
return False
sum_array = [0]*(len(nums)+1)
for i, num in enumerate(nums):
sum_array[i+1] = sum_array[i]+num
if k == 0:
if sum_array[-1] == 0:
... | [
"noreply@github.com"
] | xwang322.noreply@github.com |
7594cc59c0f7b3e0b0660a1a5bf904bcb186dc40 | 25dcac1b6b7fd82d689ef78946ae92768cf1b419 | /aries/products/views_product_list.py | dbb763356b8b7569b1fcd752f12d9159a5ef0c1b | [] | no_license | youngwanim/project_aries_primitive | c239809363802235d4c77dfeece0bb174938dc80 | bd3c155be4eb39a4b67b18ec7b0458e550c7baf3 | refs/heads/master | 2023-05-14T01:07:05.907692 | 2019-06-13T07:33:46 | 2019-06-13T07:33:46 | 262,193,936 | 0 | 0 | null | 2021-06-10T22:52:45 | 2020-05-08T01:07:20 | Python | UTF-8 | Python | false | false | 3,343 | py | import logging
from rest_framework.response import Response
from rest_framework.views import APIView
from aries.common import code
from aries.common.exceptions.exceptions import DataValidationError, BusinessLogicError
from aries.common.http_utils.header_parser import parse_language_v2
from aries.common.models import ... | [
"ywlim98@gmail.com"
] | ywlim98@gmail.com |
2e5ebde578be01caaa95fcb9a0db42b6ea91e245 | 921b3a67a24df947f085e93ba58833ec20f6b89e | /producer-tutorial/Lib/site-packages/faker/providers/phone_number/ar_AE/__init__.py | 16c9a8ff934d1e3342027fad2d1ef959a5cd28a1 | [] | no_license | jaslanm/python | e3bacd7ad0020b7e11adcb1b17dd6da3e4b2f65c | 5cfa3913b89acb0b8cf79247de1b2820a8b92f3a | refs/heads/main | 2023-08-30T01:53:13.752918 | 2021-10-23T13:24:48 | 2021-10-23T13:24:48 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,472 | py | from .. import Provider as PhoneNumberProvider
class Provider(PhoneNumberProvider):
# Source: https://en.wikipedia.org/wiki/Telephone_numbers_in_the_United_Arab_Emirates
cellphone_formats = (
'{{area_code}} {{cellphone_provider_code}} ### ####',
'{{area_code}}{{cellphone_provider_code}}######... | [
"jaslanm@gmail.com"
] | jaslanm@gmail.com |
bb0b83b7e5cb59927bf67837eed003b2cb14409b | 4e78d3a0a05d4f0986c3a6204c84605097e10b5e | /setup.py | f3eb8001ffd413ef312c9596950a81848f62147f | [
"Apache-2.0"
] | permissive | Nickycc/AndroidViewClient | eb62c8e3f7092b29cb077974e8c9e2f2a1bbce2a | 20b7dd0f6d058b179cfd32ef6ed900805f746542 | refs/heads/master | 2020-04-07T10:45:11.303302 | 2015-02-06T18:28:35 | 2015-02-06T18:28:35 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,048 | py | #!/usr/bin/env python
from setuptools import setup, find_packages
setup(name='androidviewclient',
version='10.0.0',
description='''AndroidViewClient is a 100% pure python library and tools
that simplifies test script creation providing higher level
operations and the ability of obtaining the t... | [
"dtmilano@gmail.com"
] | dtmilano@gmail.com |
2c802f4ab678b0d656ee10fdd2976f9ad0d0d79c | 81cfd404276f73b7b622cf10382eaf44a0e2e15f | /site/cgi-bin/index.py | 165f39c5af34021f1d3713c134068914218fa07b | [
"MIT"
] | permissive | jsmith1024/toonsite | 55e744a63176bccbbae512e4ddc40ce02f7a00b6 | 909f57ca28c80939d32a1799e9bdd65d37ae96a8 | refs/heads/main | 2023-06-11T19:26:15.876247 | 2021-07-09T17:23:05 | 2021-07-09T17:23:05 | 379,032,565 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 257 | py | #!/usr/bin/env python3
import cgi
import cgitb
cgitb.enable()
from PageManager import PageManager
Page = PageManager()
Page.printStart()
Page.printTitle()
Page.printLine()
Page.printButtons()
Page.printLine()
Page.printContent()
Page.printFinish()
| [
"you@example.com"
] | you@example.com |
01b3bdc93b5c3c35aac100c12641a9a360149ba0 | f0d713996eb095bcdc701f3fab0a8110b8541cbb | /2X2uZysLJ3CpsxLDD_6.py | 71dcb4db3c2ca6ea3efa61b032d1f239180d3f8e | [] | 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 | 447 | py | """
Create a function that takes an angle in radians and returns the corresponding
angle in degrees rounded to one decimal place.
### Examples
radians_to_degrees(1) ➞ 57.3
radians_to_degrees(20) ➞ 1145.9
radians_to_degrees(50) ➞ 2864.8
### Notes
The number `π` can be loaded from the math mo... | [
"daniel.reich@danielreichs-MacBook-Pro.local"
] | daniel.reich@danielreichs-MacBook-Pro.local |
9b008072db9fffb97edae7824a538495c55b0bab | 48832d27da16256ee62c364add45f21b968ee669 | /res_bw/scripts/common/lib/__future__.py | f226254bc476d2fcf9abbfe601942660f2d823b6 | [] | no_license | webiumsk/WOT-0.9.15.1 | 0752d5bbd7c6fafdd7f714af939ae7bcf654faf7 | 17ca3550fef25e430534d079876a14fbbcccb9b4 | refs/heads/master | 2021-01-20T18:24:10.349144 | 2016-08-04T18:08:34 | 2016-08-04T18:08:34 | 64,955,694 | 0 | 0 | null | null | null | null | WINDOWS-1250 | Python | false | false | 3,838 | py | # 2016.08.04 19:58:04 Střední Evropa (letní čas)
# Embedded file name: scripts/common/Lib/__future__.py
"""Record of phased-in incompatible language changes.
Each line is of the form:
FeatureName = "_Feature(" OptionalRelease "," MandatoryRelease ","
CompilerFlag ")"
where, normally... | [
"info@webium.sk"
] | info@webium.sk |
1717f1b245587d6fa78d65d1cc9655ce7ba3846d | 0dcf78e319956f2cb2327c5cb47bd6d65e59a51b | /Python3/Array/JumpGame/DPBottomUp055.py | 6810003594fc54ebbb2716a1b36da74aafbb2846 | [] | no_license | daviddwlee84/LeetCode | 70edd09a64a6f61492aa06d927e1ec3ab6a8fbc6 | da1774fd07b7326e66d9478b3d2619e0499ac2b7 | refs/heads/master | 2023-05-11T03:16:32.568625 | 2023-05-08T05:11:57 | 2023-05-09T05:11:57 | 134,676,851 | 14 | 4 | null | 2018-05-29T14:50:22 | 2018-05-24T07:18:31 | Python | UTF-8 | Python | false | false | 1,132 | py | from typing import List
from enum import Enum
class Index(Enum):
GOOD = 0
BAD = 1
UNKNOWN = 2
class Solution:
def canJump(self, nums: List[int]) -> bool:
"""
Top-down to bottom-up conversion is done by eliminating recursion
benefit
* no method stack overhead
... | [
"daviddwlee84@gmail.com"
] | daviddwlee84@gmail.com |
d0e7f2c538f49d35a54659e8d3811af7d8e4ed27 | 15eea21e7fa3531d45ad0eb8bfab305fcc0fe37a | /程序员代码面试指南-左程云/链表问题/detectCycle_1.py | 3d0c71063ccd93da0fae56b88f7b302a6f63652f | [] | no_license | yearing1017/Algorithm_Note | a3fcfd852903536d02f9360d96d31fc1a7aa6f8f | 8a3f1bda222cb777ff7786170c6d2071ad951ac0 | refs/heads/master | 2023-02-20T19:19:32.641519 | 2023-02-06T15:55:44 | 2023-02-06T15:55:44 | 223,118,925 | 43 | 9 | null | 2023-02-06T15:55:45 | 2019-11-21T07:55:50 | Python | UTF-8 | Python | false | false | 345 | py | # 判断给定的链表中是否有环。如果有环则返回true,否则返回false。
def hasCycle(self , head ):
if not head:
return False
slow, fast = head, head
while fast.next and fast.next.next:
slow = slow.next
fast = fast.next.next
if fast == slow:
return True
return False | [
"yearing1017@126.com"
] | yearing1017@126.com |
c9a44024e9392ef9fe0c8b75c0886a1b815546c5 | ab197194e6f4a7dae78b4cf72456aff78e71740f | /makeBoostedMassResStudies2016.py | 230895ba131caabcf0237c72dbdb7b7a46414980 | [] | no_license | JanFSchulte/MuonResolution | b75919e4dabb064476bc71c997a42b916dd039e0 | e39b4055b654f2b2e93b3b0fdac826fa630b042f | refs/heads/master | 2023-07-02T12:02:40.541267 | 2023-06-06T16:14:45 | 2023-06-06T16:14:45 | 164,695,533 | 0 | 2 | null | 2019-09-13T09:47:52 | 2019-01-08T17:01:51 | Python | UTF-8 | Python | false | false | 3,606 | py | import subprocess
tracks = ["Inner","Outer","Global","TPFMS","Picky","DYT","TunePNew"]
#~ tracks = ["TunePNew"]
for track in tracks:
command = ["python","makeMassRes_atZ3.py","--iDATA","data_2016.root","--iMC","2016PtBinned","-o","2016Boosteddefault","--weight","True","-f","doubleCB","-t","%s"%track]
subprocess.ca... | [
"jschulte@cern.ch"
] | jschulte@cern.ch |
c9d4ed43154d7509f5afc42a0b0bbcf1299abe96 | 72c90301d4753c3d1534473196c6cb0b2f923bc8 | /tests/languages/helpers_test.py | 7019e260fc888bdea88a7d14e2ad147b1aca8539 | [
"MIT"
] | permissive | KevinHock/pre-commit | ec5ab3725fe6678b16abb0978a7414de9babba3f | ab47d08a38c67d6e974295fb58af753b4e8930ad | refs/heads/master | 2021-05-06T23:49:28.970479 | 2017-11-09T02:04:13 | 2017-11-09T02:04:34 | 110,043,358 | 3 | 2 | null | 2017-11-08T23:42:14 | 2017-11-08T23:42:14 | null | UTF-8 | Python | false | false | 302 | py | from __future__ import absolute_import
from __future__ import unicode_literals
from pre_commit.languages import helpers
def test_basic_get_default_version():
assert helpers.basic_get_default_version() == 'default'
def test_basic_healthy():
assert helpers.basic_healthy(None, None) is True
| [
"asottile@umich.edu"
] | asottile@umich.edu |
c5141ba8aba72647f297f5ba22c046a10c2d145e | eb4d8be0efcdfd208d1eebe8ab063bbcbe383155 | /test.py | cf6f97b354d4c3a3e0a133e2b3edada0e9fb6c4a | [] | no_license | r2d2-lex/openni-player | 3148df774b22a0e884bffb0a20f83e3065ccb221 | d50d56fecf4f8be81358593e2ee39ef91d812253 | refs/heads/main | 2023-01-07T03:38:57.316968 | 2020-11-10T21:27:44 | 2020-11-10T21:27:44 | 306,824,354 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 564 | py | from openni import openni2
OPENNI_FOLDER_PATH = r'./OpenNI-Linux-x64-2.3/Redist'
openni2.initialize(OPENNI_FOLDER_PATH)
# dev = openni2.Device.open_file('cap1.oni'.encode('utf-8'))
dev = openni2.Device('cap2.oni'.encode('utf-8'))
playback = openni2.PlaybackSupport(dev)
depth_stream = dev.create_depth_stream()
depth_str... | [
"r2d2-lex@yandex.ru"
] | r2d2-lex@yandex.ru |
e1a45b14465bd9ffc9845cc54a5d14051862b8ea | 03dd1cbd8448a6bab045bdab7fbd94a454ab861c | /menu/migrations/0004_auto_20170927_1122.py | 13c40faf53ece1520ed40ef254faff8eba312d4f | [] | no_license | UnruledLab/ICO-Full-Stack | feb03d7eba6c0d29febdaf47a9947837d8c25f00 | 94dc4c2a7ea176a1901e0c8643795f416f112396 | refs/heads/master | 2022-12-08T11:41:09.577255 | 2017-11-16T19:23:01 | 2017-11-16T19:23:01 | 120,464,345 | 0 | 0 | null | 2022-12-08T00:39:41 | 2018-02-06T13:51:59 | JavaScript | UTF-8 | Python | false | false | 755 | py | # -*- coding: utf-8 -*-
# Generated by Django 1.11.5 on 2017-09-27 11:22
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('menu', '0003_auto_20170922_1022'),
]
operations = [
migrations.AddField(
... | [
"phonxis@gmail.com"
] | phonxis@gmail.com |
c238aaa2a3c5d23684c563af6b598786d80d5c57 | 53fab060fa262e5d5026e0807d93c75fb81e67b9 | /backup/user_326/ch32_2020_04_22_17_35_06_732357.py | 9a442cbe1c7975424562f6996fdc8419632775d3 | [] | no_license | gabriellaec/desoft-analise-exercicios | b77c6999424c5ce7e44086a12589a0ad43d6adca | 01940ab0897aa6005764fc220b900e4d6161d36b | refs/heads/main | 2023-01-31T17:19:42.050628 | 2020-12-16T05:21:31 | 2020-12-16T05:21:31 | 306,735,108 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 572 | py | def lista_primos(numero_indice):
lista_primeiros_primos = []
i = 0
numero_primo = 0
while numero_primo < numero_indice:
if numero_primo < 3:
numero_primo += 1
lista_primeiros_primos.append(numero_primo)
else:
if numero_primo % 3 != 0 and numero_pri... | [
"you@example.com"
] | you@example.com |
9379cda15de724ef0cc38515415428fb839fe9cd | 810bbf089f20a4e26658d8186567da9a54db9a26 | /flexx/app/__init__.py | 32dc5bdf772c85196847588fad3015e87e3a0ab2 | [
"BSD-2-Clause"
] | permissive | sanen/flexx | fedffbf18f8ccfb6f2d6d02a06258273a1678d19 | a3cd1d31223107ecdee5cd4d71ae40d831831307 | refs/heads/master | 2021-01-15T17:01:55.338519 | 2016-02-24T13:18:46 | 2016-02-24T13:18:46 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,794 | py | """
The app module implements the connection between Python and JavaScript.
It implements a simple server based on Tornado. HTML is served to
provide the client with the JavaScript and CSS, but once connected, all
communication goed via a websocket.
A central component is the ``Model`` class, which allows definition ... | [
"almar.klein@gmail.com"
] | almar.klein@gmail.com |
d9b4124cd21066e60a8212c47f75404550ce692b | 28da2837b480e999f3af6311addf1ae7b79e2401 | /bst_14/closed_elements_in_sorted_arrays.py | c909f0f2a65402b92b7aba7e2cc15c5fed0d27bc | [] | no_license | mirzasaad/EPI_Solutions | 3f62b502dd48f3525a7e2e4591b0e9241f3b231a | 29732b367787194562a3178feaa6a0d531f4fc92 | refs/heads/master | 2020-07-26T06:37:46.649086 | 2020-05-15T09:54:51 | 2020-05-15T09:54:51 | 208,566,190 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 857 | py | from binary_tree_prototype import BinaryTreeNode
import bintrees
# @include
def find_closet_elements_in_sorted_arrays(sorted_arrays):
iters = bintrees.RBTree()
min_distance_so_far = float('inf')
for idx, sorted_array in enumerate(sorted_arrays):
it = iter(sorted_array)
first_min = next(it, None)
if ... | [
"saaad.mirxa@gmail.com"
] | saaad.mirxa@gmail.com |
726f7745745eaefaa3d27be283d6fcfc35069b2d | 487ce91881032c1de16e35ed8bc187d6034205f7 | /codes/CodeJamCrawler/16_0_1/Isam/countingSheep.py | 4d64230a7000e992ee0b1a70a2f705a6763d7f34 | [] | 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 | 849 | py | import time
digits = [i for i in range(10)]
def countSheep(N):
myDigits = [9999 for i in range(10)]
i = 1
l = len(N)
s = N
N = int(N)
num = N
if num == 0:
return 'INSOMNIA'
while myDigits != digits:
num = i * N
s = str(num)
for ele in s:
if int(ele) not in myDigits:
myDi... | [
"[dhuo@tcd.ie]"
] | [dhuo@tcd.ie] |
9461b956bf1440b44ecbf939ddeb69a235358c5b | 9eedae344b05a4d7af73c76a10599b4a90db3c4c | /Python_Weakref_Object_ID_Retrieval.py | 7e4a9c7726374e87ebe9e22f7d28f06318e6e77c | [] | no_license | VakinduPhilliam/Python_Weakref_Caching | ab73d94d91fc43316d245e76cb35cf2c5749cac5 | 0df5a6843495fc62638a8e9f55f59e6d6ed874da | refs/heads/master | 2020-05-31T09:46:57.307715 | 2019-06-04T14:53:03 | 2019-06-04T14:53:03 | 190,221,842 | 2 | 0 | null | null | null | null | MacCentralEurope | Python | false | false | 1,322 | py | # Python Weakref
# weakref ó Weak references.
# The weakref module allows the Python programmer to create weak references to objects.
#
# In the following, the term referent means the object which is referred to by a weak reference.
# A weak reference to an object is not enough to keep the object alive: when the ... | [
"noreply@github.com"
] | VakinduPhilliam.noreply@github.com |
2a78db7216be49bce75c25ff134cea3662420ff1 | 6b2a8dd202fdce77c971c412717e305e1caaac51 | /solutions_5753053697277952_0/Python/Grzesiu/A-source.py | 55aae270ef635068c044124ccda5ba50e8686be5 | [] | no_license | alexandraback/datacollection | 0bc67a9ace00abbc843f4912562f3a064992e0e9 | 076a7bc7693f3abf07bfdbdac838cb4ef65ccfcf | refs/heads/master | 2021-01-24T18:27:24.417992 | 2017-05-23T09:23:38 | 2017-05-23T09:23:38 | 84,313,442 | 2 | 4 | null | null | null | null | UTF-8 | Python | false | false | 1,127 | py | import imp, sys
sys.modules["utils"] = __mod = imp.new_module("utils")
exec """#!/usr/bin/python
from itertools import chain, repeat, izip
def line(*args):
L = raw_input().strip().split()
L = izip( L, chain( args, repeat(str) ) )
return [ type(data) for data, type in L ]
def iline(): return map( int, ... | [
"alexandra1.back@gmail.com"
] | alexandra1.back@gmail.com |
eb346ee316187d62bcf91198f7e119ad1fd21d29 | 2bb96128322c0307742c6809f0d8c7eddb09c523 | /try_finally_tutorial.py | e89c7aeef3b2381959a4cf1ed87404de0fa2b0b9 | [
"MIT"
] | permissive | twtrubiks/python-notes | 2390c66d25b39f5a73968829702d4fd02ccf1b28 | 042a651aaa04c07f76c52bc52bace665d0df99d7 | refs/heads/master | 2023-08-17T11:50:13.122573 | 2023-08-05T04:14:56 | 2023-08-05T04:14:56 | 90,001,387 | 122 | 49 | MIT | 2021-12-21T07:18:06 | 2017-05-02T06:55:21 | Python | UTF-8 | Python | false | false | 1,362 | py | def base_example_1():
try:
print("run_1")
except Exception:
print("Exception")
finally:
print("other code")
def example_1():
try:
print("run_1")
except Exception:
print("Exception")
return "re Exception"
finally:
print("other code")
def... | [
"twtrubiks@gmail.com"
] | twtrubiks@gmail.com |
d5b0e340a8e2295c9c0cfd3cd688b5bb192dcdda | 98316f1635a0092a9e92f8070dce3e8ceeeee537 | /pybids_examples.py | 7d6948bd2c69e41af00f56d9be7b6df408aaba3c | [] | no_license | oesteban/grabbit | 692bd2d3293f8ea22a767f5b08d464717f38d817 | 68e54b84aa4b93def2dfb25c0a47a41a127fc2ae | refs/heads/master | 2020-04-10T21:01:21.883610 | 2016-08-05T00:46:36 | 2016-08-05T00:46:36 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,696 | py |
# get func, t1w, and fmap for two particular subjects
# only take run 2 for motor task
# HOW TO DEAL WITH RUN SINCE IT COULD REFER TO FUNC OR T1W?
# ANOTHER TRICK WITH FIELDMAPS - DO WE RETURN ONLY THE FIELDMAPS
# THAT MATCH THE SPECIFIC FUNCTIONAL RUN BEING RETURNED?
pybids_instance = pybids(path='/home/chris/bids_d... | [
"poldrack@gmail.com"
] | poldrack@gmail.com |
19fc188a0c2aec52d03f8e3c1e583d1fb53a48c2 | 670f4ba8ded99b420c3454c6ae35789667880cc8 | /tobiko/tests/unit/test_conftest.py | ee6e63d49558fa535e6928f19e30857aa2ef1e5e | [
"Apache-2.0"
] | permissive | FedericoRessi/tobiko | 892db522198ab48380892138459d801c4bd00efa | ce2a8734f8b4203ec38078207297062263c49f6f | refs/heads/master | 2022-07-26T22:52:10.273883 | 2022-07-20T20:04:43 | 2022-07-20T20:04:43 | 145,856,925 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,874 | py | # Copyright 2021 Red Hat
#
# 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 ... | [
"fressi@redhat.com"
] | fressi@redhat.com |
2b86d2999fe4a3ef7fd96f5e3a7eed40e09f733f | e0375e71cf476cbe76729959d32dfc20ae263efe | /week3/rectangle_area.py | 46c1f4579fbb1c930f2e73205af94cea989692bf | [] | no_license | jonathanqbo/moncton-python-2020 | c920093c0199eed5b918b0aa7e3cbc2c4ea12715 | 40ee150bb80df36889169ad9d2b834939cc257bc | refs/heads/master | 2023-02-27T10:21:17.863058 | 2021-01-30T21:04:52 | 2021-01-30T21:04:52 | 291,563,403 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 561 | py |
def rect_area_v1(width, height):
area = width * height
print('Area of rectangle', [width, height], 'is', area)
rect_area_v1(10, 20)
rect_area_v1(20, 20)
rect_area_v1(30, 20)
def rect_area_v2(width, height):
return width * height
width, height = 10, 20
print('Area of rectangle', [width, height], 'is',... | [
"jonathan.q.bo@gmail.com"
] | jonathan.q.bo@gmail.com |
dedec16126478e91710dec3c1df5614fe7e4ccfd | 395e06560c7b794a965add40c586684cb0b4e59c | /docs/tutorials/output1.py | c0af15407c71da52faf54659741b79329c20f486 | [
"BSD-2-Clause",
"Python-2.0"
] | permissive | alanyee/python-terrascript | f01edef3f6e21e5b18bc3295efef1657be17e3ca | e880e7650a7c3a88603d5429dafbacd28cd26c7e | refs/heads/develop | 2023-03-09T07:33:32.560816 | 2020-09-21T07:11:09 | 2020-09-21T07:11:09 | 300,696,024 | 0 | 0 | BSD-2-Clause | 2021-02-18T00:33:30 | 2020-10-02T17:57:18 | null | UTF-8 | Python | false | false | 597 | py | import terrascript
import terrascript.provider
import terrascript.resource
config = terrascript.Terrascript()
# AWS provider
config += terrascript.provider.aws(region="us-east-1")
# Define Variable and add to config
v = terrascript.Variable("image_id", type="string")
config += v
# Define AWS EC2 instance and add to... | [
"markus@juenemann.net"
] | markus@juenemann.net |
e9a1ead7be3abd84f1b7adfa8920a3cc29ab653e | 6df0d7a677129e9b325d4fdb4bbf72d512dd08b2 | /PycharmProjects/liveshow/old/while1.py | abedbba1b6a78431c887ffd8a9a97ae6f82275df | [] | no_license | yingxingtianxia/python | 01265a37136f2ad73fdd142f72d70f7c962e0241 | 3e1a7617a4b6552bce4a7e15a182f30e1bae221e | refs/heads/master | 2021-06-14T15:48:00.939472 | 2019-12-13T05:57:36 | 2019-12-13T05:57:36 | 152,200,507 | 0 | 0 | null | 2021-06-10T20:54:26 | 2018-10-09T06:40:10 | Python | UTF-8 | Python | false | false | 204 | py | #!/usr/bin/env python3
#__*__coding: utf8__*__
import time
flag = ['-', '/', '|', '\\']
i = 0
while True:
print('\r%s' % flag[i], end = '')
time.sleep(0.5)
i += 1
if i == 4:
i = 0 | [
"903511044@qq.com"
] | 903511044@qq.com |
f47cab049ed7c2aaaa06df25cbcfc32277d38ea0 | 2875edc8b495d37d9d44e1d23d5c0c4e7fdd324b | /src/mkdocs_gallery/mkdocs_compatibility.py | 6526da3283dd325369604ebb9534587a5d98c830 | [
"BSD-3-Clause"
] | permissive | smarie/mkdocs-gallery | c8845a15a452de60ebe6f5384da21c39a9fb452e | 89fea9eacf6b9742fdbe2622f7d6a7d525db42a9 | refs/heads/main | 2023-08-09T21:10:37.119637 | 2023-05-15T16:50:17 | 2023-05-15T16:50:17 | 426,683,311 | 23 | 8 | BSD-3-Clause | 2023-07-27T06:14:53 | 2021-11-10T15:51:30 | Python | UTF-8 | Python | false | false | 936 | py | # Authors: Sylvain MARIE <sylvain.marie@se.com>
# + All contributors to <https://github.com/smarie/mkdocs-gallery>
#
# Original idea and code: sphinx-gallery, <https://sphinx-gallery.github.io>
# License: 3-clause BSD, <https://github.com/smarie/mkdocs-gallery/blob/master/LICENSE>
"""
Backwards-compatilit... | [
"sylvain.marie@se.com"
] | sylvain.marie@se.com |
fa36b654bb5532a8379da57ce3d509fc1a788083 | 53784d3746eccb6d8fca540be9087a12f3713d1c | /res/packages/scripts/scripts/client/gui/miniclient/invitations/__init__.py | e788e2bd58f23379d23db2cc204a62c1c49e2d0f | [] | no_license | webiumsk/WOT-0.9.17.1-CT | 736666d53cbd0da6745b970e90a8bac6ea80813d | d7c3cf340ae40318933e7205bf9a17c7e53bac52 | refs/heads/master | 2021-01-09T06:00:33.898009 | 2017-02-03T21:40:17 | 2017-02-03T21:40:17 | 80,870,824 | 0 | 0 | null | null | null | null | WINDOWS-1250 | Python | false | false | 511 | py | # 2017.02.03 21:48:22 Střední Evropa (běžný čas)
# Embedded file name: scripts/client/gui/miniclient/invitations/__init__.py
import pointcuts as _pointcuts
def configure_pointcuts():
_pointcuts.PrbDisableAcceptButton()
_pointcuts.PrbInvitationText()
# okay decompyling c:\Users\PC\wotsources\files\originals\res... | [
"info@webium.sk"
] | info@webium.sk |
bac62e407b444526b07735208e90a1d137933c20 | b7d0f003cfb0ec6fa25f99d9f7b544dc38ae6aa8 | /algorithmPractice/배열 돌리기4.py | 05a4b26eadcb71d6c8b6caf88bbab611f48bf7c2 | [] | no_license | Kimyechan/dataStructureAndArgorithm | 43c2cfa0d12a5c729f687d786ef6dde23bf193a7 | c9f8f614621aee9e236ffef20e5e563b37bab0b3 | refs/heads/master | 2021-07-09T03:31:31.405725 | 2021-03-09T13:18:55 | 2021-03-09T13:18:55 | 231,402,629 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 991 | py | #틀린 문제
from copy import deepcopy
N, M, K = map(int, input().split(' '))
A = [list(map(int, input().split(' '))) for _ in range(N)]
Q = [tuple(map(int, input().split(' '))) for _ in range(K)]
dx, dy = [1, 0, -1, 0], [0, -1, 0, 1]
ans = 10000
def value(arr):
return min(sum(i) for i in arr)
def convert(arr, qr... | [
"vlvkcjswo7@naver.com"
] | vlvkcjswo7@naver.com |
a249c495bc8645675eb86766e110e36dde7a29fc | f5d1e8b54ddbc51a9ef1b868eee93096d9b0fbeb | /weapp/market_tools/tools/research/settings.py | 12d824f426777960367397db7cf7f7710c0ede4c | [] | no_license | chengdg/weizoom | 97740c121724fae582b10cdbe0ce227a1f065ece | 8b2f7befe92841bcc35e0e60cac5958ef3f3af54 | refs/heads/master | 2021-01-22T20:29:30.297059 | 2017-03-30T08:39:25 | 2017-03-30T08:39:25 | 85,268,003 | 1 | 3 | null | null | null | null | UTF-8 | Python | false | false | 139 | py | # -*- coding: utf-8 -*-
__author__ = 'likunlun'
TOOL_NAME = u'用户调研'
TOOL_ICON_URL = u'/static/img/markettools/vote/vote.jpg' | [
"jiangzhe@weizoom.com"
] | jiangzhe@weizoom.com |
5ea725ba1f92da5aa3dc691cdee9a3d723f8fdf9 | 8f6f27917c1d16856656c62aeed3909f17711144 | /2015/22/puzzle_2.py | 3ad0559d4e83c531d043e45031352f4a8c9650bb | [] | no_license | naydichev/advent-of-code-solutions | 1f2050e6d237bf664dd79925af8656f821080fda | d9f1bc6e95e077d48bd0b1b50e8f5b0ae137ca6a | refs/heads/master | 2022-12-26T15:00:09.429622 | 2022-12-21T08:51:42 | 2022-12-21T08:51:42 | 159,928,226 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,069 | py | #!/usr/bin/env python3
import sys
from collections import defaultdict
from copy import deepcopy
from recordtype import recordtype
Character = recordtype("Character", ["hp", "damage", "mana", "armor"], default=0)
Spell = recordtype("Spell", ["name", "cost", "effect", "duration"])
def magic_missle(_, boss):
boss.... | [
"git@julian.appwarden.com"
] | git@julian.appwarden.com |
d3638f8d683f699e883d5ec2ab3d18a2de509b45 | 4dddd01ca6a60f2fa408ee55fbaebe868917184a | /venv/bin/mitmproxy | 28734f1e2cad0554ee4f2a9f66709b4f554ab352 | [] | no_license | fanpl-sourse/all_study_practice | 6f056c18f0eb7afd6af649e5b595895683bb0cbd | b02f25231855e149b95476b20dd8d53318cfe1a5 | refs/heads/master | 2023-01-22T09:13:15.107616 | 2020-11-30T05:53:43 | 2020-11-30T05:53:43 | 304,493,176 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 276 | #!/Users/a/Documents/2020study/all_study_practice/venv/bin/python
# -*- coding: utf-8 -*-
import re
import sys
from mitmproxy.tools.main import mitmproxy
if __name__ == '__main__':
sys.argv[0] = re.sub(r'(-script\.pyw|\.exe)?$', '', sys.argv[0])
sys.exit(mitmproxy())
| [
"fanpengli@fangdd.com"
] | fanpengli@fangdd.com | |
d8376be88be729318e829b87da4ca137d0356495 | a76f49febfa90d57032068fda127534e491d70b7 | /sample-apps/trello-integration-app/src/formatters/trello/cards.py | cf37dfb5b65e05d91af243cd85d439cf23e930f1 | [] | permissive | jtruty/hubspot-api-python | dedf3b5b6838931d2b7cfbb667e80dc0cea58166 | 3f1b2d2007733a734daee2010611592249b72a0b | refs/heads/master | 2022-12-07T16:04:23.496317 | 2020-08-05T08:03:07 | 2020-08-05T08:03:07 | 288,502,982 | 0 | 0 | Apache-2.0 | 2020-08-18T16:07:45 | 2020-08-18T16:07:44 | null | UTF-8 | Python | false | false | 1,314 | py | from flask import url_for
def format_card_extension_data_response(deal_associated, card=None):
if deal_associated:
result = {
"objectId": card.short_id,
"title": card.name,
"link": card.short_url,
}
if len(card.members) > 0:
result["propertie... | [
"atanasiuk@hubspot.com"
] | atanasiuk@hubspot.com |
da3b6043135ee77de71cc89fa3441c895b69fb87 | da3fac285886bf0f00fd9040fe20a02111722f67 | /foundation/jobs/models.py | 2226f7b8fc36e91c06f1d1332a5ab0cc3d85c6de | [
"MIT"
] | permissive | mikbuddha/foundation | 00b721e8e32de66c8dba34533dc8aea35e09e357 | ac8be263d321afe017a84aebc29ef735e65de393 | refs/heads/master | 2021-01-12T20:40:07.464776 | 2016-04-06T08:08:48 | 2016-04-06T08:09:53 | 55,972,178 | 1 | 0 | null | 2016-04-11T12:54:01 | 2016-04-11T12:54:00 | null | UTF-8 | Python | false | false | 398 | py | from django.db import models
class Job(models.Model):
created_at = models.DateTimeField(auto_now_add=True)
updated_at = models.DateTimeField(auto_now=True)
title = models.CharField(max_length=150)
description = models.TextField()
submission_email = models.EmailField()
submission_closes = mode... | [
"nick@whiteink.com"
] | nick@whiteink.com |
0fdf6b70ec039cb750c2d0e9f3526c5889b7cca9 | dbb0aef6d16f2946c7400a67c0a778cc7c899edb | /antspynet/architectures/create_autoencoder_model.py | 9cd55af3d27e53786eb10a7d0ea05abb2dcbfa57 | [] | no_license | mattcieslak/ANTsPyNet | 8b0e0004360aa7ca50e9501b806b8ddc67f2af3e | b98e7453dcdce13cff5d30ae9c093b2b37e67135 | refs/heads/master | 2020-12-29T08:18:31.297150 | 2020-02-02T02:15:40 | 2020-02-02T02:15:40 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,070 | py |
from keras.models import Model
from keras.layers import Input, Dense
def create_autoencoder_model(number_of_units_per_layer,
activation='relu',
initializer='glorot_uniform'
):
"""
2-D implementation of the Vgg deep learning ... | [
"ntustison@gmail.com"
] | ntustison@gmail.com |
303d9c00db90a3ecbcefa406c9241290e9583f2f | 11301b586c69aa6c9cbbaa79b51c72e25e9e7820 | /encoder/esim.py | 198d95ad3a4dfd57750718c7d4f930e7f8677c4a | [] | no_license | sduchh/nlp_research | 1d1a321280cab678f9d0b95b5aa86697f89d3811 | 9237d2b8ba85254016bd0386e819666f73286d58 | refs/heads/master | 2020-05-24T15:08:13.300994 | 2019-05-17T10:43:09 | 2019-05-17T10:43:09 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,067 | py | import keras
import tensorflow as tf
from keras.layers import *
from keras.activations import softmax
from keras.models import Model
from keras.layers.merge import concatenate
from keras.layers.normalization import BatchNormalization
from keras.utils import multi_gpu_model
#refer:https://arxiv.org/abs/1609.06038
clas... | [
"zfz@zfzdeMacBook-Pro.local"
] | zfz@zfzdeMacBook-Pro.local |
4d3a66401e45ff0c99a630f8f3df823bb67c3a8a | ed97fb5c71da7ed89235432e3971bb0ef6064f8b | /algorithms/python/13.py | 272df1e8d68434f51e5fbca99ac031ed2e5ccb05 | [
"MIT"
] | permissive | viing937/leetcode | 8241be4f8bc9234a882b98ada2e5d13b0ebcca68 | b07f7ba69f3d2a7e294f915934db302f43c0848f | refs/heads/master | 2023-08-31T18:25:06.443397 | 2023-08-31T15:31:38 | 2023-08-31T15:31:38 | 37,374,931 | 3 | 0 | null | null | null | null | UTF-8 | Python | false | false | 443 | py | class Solution(object):
def romanToInt(self, s):
"""
:type s: str
:rtype: int
"""
sym = ['IV', 'IX', 'XL', 'XC', 'CD', 'CM', 'I', 'V', 'X', 'L', 'C', 'D', 'M']
val = [4, 9, 40, 90, 400, 900, 1, 5, 10, 50, 100, 500, 1000]
rls = 0
for i in range(len(sym)... | [
"viing937@gmail.com"
] | viing937@gmail.com |
9ff40c2a2acc8f4ac7abe253f44de58e75d4e87f | 45e23d1db1c1ecd19b4f4055b60b994cf866f240 | /源程序/12.1关键字竞价排名/Auction/useBidResultWin.py | 47498595780a55a6a4bea65ea4ae832f65f8df0c | [] | no_license | hushaoqi/MIS_project | ff8d60ac5461e3be6d1c599378790baa059f43c0 | d23aaf791809d912b15277dc057d84c8f2685f8e | refs/heads/master | 2022-12-23T21:50:37.024694 | 2019-07-24T13:05:28 | 2019-07-24T13:05:28 | 150,825,940 | 0 | 1 | null | 2022-12-17T11:17:42 | 2018-09-29T04:53:06 | Python | UTF-8 | Python | false | false | 442 | py | import sys
from bidResultWin import Ui_BidResultWin
from PyQt5.QtWidgets import QApplication,QMainWindow
import pymysql
#这是结果类
class useBidResultWin(QMainWindow, Ui_BidResultWin):
def __init__(self, parent = None):
super(useBidResultWin,self).__init__(parent)
self.setupUi(self)
if... | [
"1941017133@qq.com"
] | 1941017133@qq.com |
97d0d0256245daf2b951bbf11057513bbe9b52ea | 19ab46afc572466465b794a5feb3257992932b85 | /setup.py | 2b358142faff664bfa7db166133a77631dbb3f78 | [
"CC0-1.0",
"LicenseRef-scancode-public-domain"
] | permissive | biomodels/MODEL1310110017 | 577d52a57f1d8b91286c03babd5e94e4514f8395 | 98237210ce09328a49e5262955de95547a28aa8a | refs/heads/master | 2020-03-28T18:49:44.580065 | 2014-10-16T05:31:02 | 2014-10-16T05:31:02 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 377 | py | from setuptools import setup, find_packages
setup(name='MODEL1310110017',
version=20140916,
description='MODEL1310110017 from BioModels',
url='http://www.ebi.ac.uk/biomodels-main/MODEL1310110017',
maintainer='Stanley Gu',
maintainer_url='stanleygu@gmail.com',
packages=find_packages(... | [
"stanleygu@gmail.com"
] | stanleygu@gmail.com |
0c467616e06d40320fca4cca6f94d31d63d17957 | 53fab060fa262e5d5026e0807d93c75fb81e67b9 | /backup/user_143/ch20_2020_03_04_19_10_56_872662.py | f7d34d7f63ab7866d1479c34e2657d2d6697948a | [] | no_license | gabriellaec/desoft-analise-exercicios | b77c6999424c5ce7e44086a12589a0ad43d6adca | 01940ab0897aa6005764fc220b900e4d6161d36b | refs/heads/main | 2023-01-31T17:19:42.050628 | 2020-12-16T05:21:31 | 2020-12-16T05:21:31 | 306,735,108 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 162 | py | # Pergunta quantos km
qts_km= float(input('quantos km:'))
def P(qts_km):
if qts_km <= 200:
return qts_km*0,5
else:
return qts_km*0,45
| [
"you@example.com"
] | you@example.com |
25d82ccbf3b3dfdc1a8f89dd1e6a98e1d7d97438 | 58a5bc060c870f9e0ffd824d25823e818ad45ce4 | /weather_app.py | b7db06418294b524f134c728e473466b80942f9d | [] | no_license | sincekara/SQL_Alchemy_Analysis | 73ae6e50734ca9f489020bf6c1d8a8331e0d7519 | 2e6c444751a2f324e27feb0e71fe64d45aab1760 | refs/heads/master | 2020-08-03T10:14:07.390519 | 2020-05-29T00:58:44 | 2020-05-29T00:58:44 | 211,716,460 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,823 | py | import numpy as np
import pandas as pd
import sqlalchemy
from sqlalchemy.ext.automap import automap_base
from sqlalchemy.orm import Session
from sqlalchemy import create_engine, func
from flask import Flask, jsonify, render_template
import datetime as dt
engine = create_engine("sqlite:///hawaii.sqlite")
Base = autom... | [
"test"
] | test |
ee5064935e2dcaa64edb9296955420c3590bdc50 | 0adb68bbf576340c8ba1d9d3c07320ab3bfdb95e | /regexlib/python_re_test_file/regexlib_4271.py | 679ccaecf031a6dd4a7516a068a0dd02612beca0 | [
"MIT"
] | permissive | agentjacker/ReDoS-Benchmarks | c7d6633a3b77d9e29e0ee2db98d5dfb60cde91c6 | f5b5094d835649e957bf3fec6b8bd4f6efdb35fc | refs/heads/main | 2023-05-10T13:57:48.491045 | 2021-05-21T11:19:39 | 2021-05-21T11:19:39 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 606 | py | # 4271
# ^[A-Za-z0-9](([_\.\-]?[a-zA-Z0-9]+)*)@([A-Za-z0-9]+)(([\.\-]?[a-zA-Z0-9]+)*)\.([A-Za-z]{2,})$
# EXPONENT
# nums:4
# EXPONENT AttackString:"A"+"a"*32+"!1 __NQ"
import re
from time import perf_counter
regex = """^[A-Za-z0-9](([_\.\-]?[a-zA-Z0-9]+)*)@([A-Za-z0-9]+)(([\.\-]?[a-zA-Z0-9]+)*)\.([A-Za-z]{2,})$"""
RE... | [
"liyt@ios.ac.cn"
] | liyt@ios.ac.cn |
f97d38f60f3af84331b5d2fedba787633e71e1e2 | f33b30743110532ddae286ba1b34993e61669ab7 | /1002. 查找常用字符.py | e138cc8408b653a1a12090fbe6b8044f7104e698 | [] | no_license | c940606/leetcode | fe9dcee7a5daa4d52999d5f53253dd6dd33c348b | 631df2ce6892a6fbb3e435f57e90d85f8200d125 | refs/heads/master | 2021-07-10T14:01:26.164966 | 2020-08-16T10:46:16 | 2020-08-16T10:46:16 | 186,588,449 | 3 | 0 | null | null | null | null | UTF-8 | Python | false | false | 490 | py | class Solution:
def commonChars(self, A) :
from collections import Counter
if not A:
return []
lookup = Counter(A[0])
for a in A[1:]:
tmp = Counter(a)
c = Counter()
for t in (tmp & lookup):
c[t] = min(tmp[t],lookup[t])
... | [
"762307667@qq.com"
] | 762307667@qq.com |
d210fc2188700e1f94d762d2d4eeb71ee4343895 | 59b839f796c73f19de9baee2f2e8e1c5822506ed | /pwncat/db/user.py | 57ba810ac6bc2942a77822bdd455d52610759d26 | [] | no_license | tilt41/pwncat | ac3377a99ff6a690cd38cfea794bc7041f5a208f | 30e084ab6e8c41fa2f0a43b557b308599eb0bdf3 | refs/heads/master | 2022-12-08T11:11:14.285109 | 2020-08-25T17:18:14 | 2020-08-25T17:18:14 | 290,603,252 | 1 | 0 | null | 2020-08-26T20:57:46 | 2020-08-26T20:57:45 | null | UTF-8 | Python | false | false | 1,761 | py | #!/usr/bin/env python3
from sqlalchemy import Column, Integer, String, ForeignKey, Table
from sqlalchemy.orm import relationship
from pwncat.db.base import Base
SecondaryGroupAssociation = Table(
"secondary_group_association",
Base.metadata,
Column("group_id", Integer, ForeignKey("groups.id")),
Column... | [
"caleb.stewart94@gmail.com"
] | caleb.stewart94@gmail.com |
84bde73fa42eabd69ba5bea4fc838c0be58cfc32 | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p03007/s730382399.py | 981228d0cf9c62b57f9fcd8ada7c352af271632d | [] | 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 | 422 | py | import sys
def input(): return sys.stdin.readline().strip()
def mapint(): return map(int, input().split())
sys.setrecursionlimit(10**9)
N = int(input())
As = list(mapint())
As.sort()
mini = As.pop(0)
maxi = As.pop()
ans = []
for a in As:
if a>=0:
ans.append((mini, a))
mini -= a
else:
a... | [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
1441dde7e105cd3cde97729e1031e35a9f9e86e6 | 37e87b3d5e1ee9009f0ea0671bc0c6edf0e233b7 | /100.py | a0df2217a46082b4c28a98defe34177c131fb5f5 | [] | no_license | Jane11111/Leetcode2021 | d9f4987792938597bf89ff72ba6bbcb4a3f9d081 | a95b871578aae0103066962c33b8c0f4ec22d0f2 | refs/heads/master | 2023-07-14T21:29:41.196752 | 2021-08-23T03:28:02 | 2021-08-23T03:28:02 | 344,804,297 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 726 | py | # -*- coding: utf-8 -*-
# @Time : 2021-04-19 10:21
# @Author : zxl
# @FileName: 100.py
# Definition for a binary tree node.
class TreeNode:
def __init__(self, val=0, left=None, right=None):
self.val = val
self.left = left
self.right = right
class Solution:
def dfs(self,p1,p2):
... | [
"791057615@qq.com"
] | 791057615@qq.com |
b15addfc45ab37cec5e041e5a2373309e44ff52c | a6ad2fb11672d4500077e438ae17d6566a6423db | /tutorial/parse_ranking2.py | 9b697699831b12f1ed8e5864ef56b9fe399b5c0d | [
"MIT"
] | permissive | disc5/RLScore | 7d884ac575d3814a346a6d0db0d84116005bc693 | cfc34e999da02807ea1582358fe3e382fe100b70 | refs/heads/master | 2020-12-26T03:00:51.505825 | 2016-04-17T10:09:07 | 2016-04-17T10:09:07 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,573 | py | import numpy as np
from rlscore.learner import QueryRankRLS
from rlscore.measure import cindex
from rlscore.reader import read_sparse
from rlscore.utilities.cross_validation import map_ids
def train_rls():
#Select regparam with k-fold cross-validation,
#where instances related to a single sentence form
#to... | [
"ajairo@utu.fi"
] | ajairo@utu.fi |
506816b1070a86d2d6f242f4ae1a7f83d40ef933 | 24fe1f54fee3a3df952ca26cce839cc18124357a | /servicegraph/lib/python2.7/site-packages/acimodel-4.0_3d-py2.7.egg/cobra/modelimpl/fabric/rtpathl2outatt.py | 3e4dff57b7e1b4cd5566226d80dc40b8dbdc1972 | [] | 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 | 4,789 | 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 |
23846ce4bec5d5384d38a3c2953d879d89b4d23d | 8e81c6c053f0a886675f47c84185ee2c749d7144 | /quiz/Problem 5-1.py | 69e13e5800c0e5a891f1bf88b5a2fd8502cf15e3 | [] | no_license | Silver-Iron/EDX-MITx--6.00.2x | 81acf404cda7fe34e0e3c0a9532faafb29048fe6 | 47740ea97d9f54ef5396fe3186e6485cbfeeba0f | refs/heads/master | 2021-01-22T22:34:16.283793 | 2017-03-20T09:34:31 | 2017-03-20T09:34:31 | 85,552,811 | 0 | 0 | null | 2017-03-20T08:33:25 | 2017-03-20T08:33:25 | null | UTF-8 | Python | false | false | 1,162 | py | """
You are taking a class that plans to assign final grades based on two midterm quizzes and a final exam. The final grade will be based on 25% for each midterm, and 50% for the final. You are told that the grades on the exams were each uniformly distributed integers:
Midterm 1: 50 <= grade <= 80
Midterm 2: ... | [
"dr.tallin@gmail.com"
] | dr.tallin@gmail.com |
1939dc7db68354a767eb23fbeb3da366e3043063 | 20176bf4fbd8aec139c7b5a27f2c2e155e173e6e | /data/all-pratic/preety_10022/Day2/Guess_Word_Game.py | 54df69da926c00a645e99a803a03b03a155f693c | [] | no_license | githubjyotiranjan/pytraining | 4ac4a1f83cc4270e2939d9d32c705019c5bc61c5 | 8b50c4ab7848bd4cbfdfbc06489768d577289c66 | refs/heads/master | 2020-03-19T06:22:20.793296 | 2018-06-15T20:08:11 | 2018-06-15T20:08:11 | 136,013,642 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 711 | py | word_input="Apple"
word_length=len(word_input)
word_input=word_input.lower()
letter_guess = ''
count = 0
limit = 10
livesleft=limit
correct_words=0
while livesleft >= 1:
letter_guess = input('Guess a letter: ')
letter_guess=letter_guess.lower()
if letter_guess in word_input:
print(' It is correct... | [
"jsatapathy007@gmail.com"
] | jsatapathy007@gmail.com |
d0570e0c7100f66c352d8a6765156f68a49587d1 | ffc4f38fcb8fd341132152fad008d10ff5b3f4e7 | /menu-duplicatefirst.py | 467265b5b8cd581f940580f34412a8b3a9af1e87 | [] | no_license | imclab/AddLocator | 840a88371bf11b4f44818bd88e803f4bdf3c1b13 | 67b6f47a8eade3601a233dccfdeee2d6918ee20d | refs/heads/master | 2021-01-21T02:20:18.746329 | 2013-08-13T20:36:29 | 2013-08-13T20:36:29 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,492 | py | from maya.cmds import *
import maya.mel as mel
#1. make an array of all selected objects
target = ls(sl=True)
#2. if only one selection, just make a new duplicate at the same coordinates...
if(len(target)==1):
#call through mel because python has no rc option!
mel.eval("duplicate -un -ic -rc")
else:
try:... | [
"nick@fox-gieg.com"
] | nick@fox-gieg.com |
3943ff161decd9e1262e58fabc959079a0dbd52b | 07aa9b5a07df2a80b7d899da1da63c84b1060fec | /src/iegen/codegen/visitor/_visitor.py | 573f2e54a91763a9bcdc2516091ce08d8217736e | [] | no_license | lamielle/iegen | f26da812a01557daca086e0a1c76a62af8fe7cd4 | 0f48edad8d14ae18c907d705751552cf6eb53c8e | refs/heads/master | 2016-09-05T12:48:23.698779 | 2010-12-14T19:17:13 | 2010-12-14T19:17:13 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,741 | py | # _visitor.py
#
# Visitor class for traversing an AST of a program
# Alan LaMielle 10/20/2008
from iegen import IEGenObject
#---------- Depth First Visitor ----------
class DFVisitor(IEGenObject):
def __init__(self):
#---------- State members ----------
#Will be True if we are within a function, False otherwis... | [
"lamielle@cs.colostate.edu"
] | lamielle@cs.colostate.edu |
1270547d683a15d46dcba368745d6f9d8a4a63fd | c646ad2dfab80f7183076dde82a82e6e1a6222d2 | /athenatools/migrations/0021_auto_20190310_1802.py | 80ac23bf864276666e7f2ae06dfa0036f6cc49eb | [
"MIT"
] | permissive | taojy123/AthenaTools | b7f5a799dca60237fb69f312f5a913964ae00097 | 612b113c5c9aeb0e6612242540fa05b7f0ac02c5 | refs/heads/master | 2023-07-21T06:32:15.638271 | 2023-07-19T09:42:01 | 2023-07-19T09:42:01 | 141,523,525 | 9 | 2 | MIT | 2023-06-30T22:19:13 | 2018-07-19T04:14:20 | Python | UTF-8 | Python | false | false | 2,397 | py | # -*- coding: utf-8 -*-
# Generated by Django 1.11.17 on 2019-03-10 10:02
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('athenatools', '0020_auto_20190310_1740'),
]
operations = [
migrations.Alte... | [
"taojy123@163.com"
] | taojy123@163.com |
ce991260a7e6c3aa07a348aed0fc5b6a06f621dd | 3d19e1a316de4d6d96471c64332fff7acfaf1308 | /Users/T/tlevine/do_floats_break_the_datatable.py | ca732952aa668563159bca0a2b24b53642ebc4ac | [] | no_license | BerilBBJ/scraperwiki-scraper-vault | 4e98837ac3b1cc3a3edb01b8954ed00f341c8fcc | 65ea6a943cc348a9caf3782b900b36446f7e137d | refs/heads/master | 2021-12-02T23:55:58.481210 | 2013-09-30T17:02:59 | 2013-09-30T17:02:59 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 150 | py | from scraperwiki.sqlite import save
save([],{"chainsaw":float(334.00023)})from scraperwiki.sqlite import save
save([],{"chainsaw":float(334.00023)}) | [
"pallih@kaninka.net"
] | pallih@kaninka.net |
0e1f8fb4c87029d81455a43272cd900f200b5f9e | 51575eeda79a6e12c8839046721168e5cc5b6774 | /gns/inference/optimization/tune.py | b369718420e2fe4eae814ede4bb9deea5eb6b764 | [] | no_license | rfeinman/GNS-Modeling | 59ad26efea4045c7dae98e98263d1193d53052b8 | 2c6b3400bfbb30f8f117042722fbcca2a8e9cb98 | refs/heads/master | 2023-06-08T21:22:27.914054 | 2021-07-08T14:17:56 | 2021-07-08T14:17:56 | 274,778,209 | 22 | 7 | null | null | null | null | UTF-8 | Python | false | false | 1,624 | py | import numpy as np
import torch
def get_param_grid(pblur, peps, nbins_blur, nbins_eps):
blur_grid = np.linspace(-50, pblur, nbins_blur)
eps_grid = np.linspace(-2, 1, nbins_eps-1)
eps_grid = np.append(eps_grid, peps)
param_grid = np.meshgrid(blur_grid, eps_grid)
param_grid = np.stack(param_grid, a... | [
"rfeinman16@gmail.com"
] | rfeinman16@gmail.com |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.