blob_id stringlengths 40 40 | directory_id stringlengths 40 40 | path stringlengths 3 616 | 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 777
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 149
values | src_encoding stringclasses 26
values | language stringclasses 1
value | is_vendor bool 2
classes | is_generated bool 2
classes | length_bytes int64 3 10.2M | extension stringclasses 188
values | content stringlengths 3 10.2M | authors listlengths 1 1 | author_id stringlengths 1 132 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
72d7294ff5ad1f06d357da58ada0fb115ed59c6e | d24a6e0be809ae3af8bc8daa6dacfc1789d38a84 | /ABC/ABC151-200/ABC190/A.py | 2dc4094c45ab83aaac5f6866e3c4f197b3e157a5 | [] | no_license | k-harada/AtCoder | 5d8004ce41c5fc6ad6ef90480ef847eaddeea179 | 02b0a6c92a05c6858b87cb22623ce877c1039f8f | refs/heads/master | 2023-08-21T18:55:53.644331 | 2023-08-05T14:21:25 | 2023-08-05T14:21:25 | 184,904,794 | 9 | 0 | null | 2023-05-22T16:29:18 | 2019-05-04T14:24:18 | Python | UTF-8 | Python | false | false | 502 | py | def solve(a, b, c):
if c == 0:
if b >= a:
return 'Aoki'
else:
return 'Takahashi'
else:
if a >= b:
return 'Takahashi'
else:
return 'Aoki'
def main():
a, b, c = map(int, input().split())
res = solve(a, b, c)
print(res)
... | [
"cashfeg@gmail.com"
] | cashfeg@gmail.com |
bc18007a717e92dad6c5f793ceb31f91ad7bb8a8 | eff0422ed21d7b1b6a870efbc1b969e30b9d2897 | /fabtools/tests/test_vagrant_version.py | 8fec58e230befa79ac31805d7300e4b42022080d | [
"BSD-2-Clause"
] | permissive | fabtools/fabtools | 561ecec02227f48d84e0ff9c5e659d32819e6413 | 5fdc7174c3fae5e93a16d677d0466f41dc2be175 | refs/heads/master | 2023-08-01T15:55:56.871793 | 2019-09-16T09:19:00 | 2019-09-16T09:19:00 | 2,325,793 | 308 | 55 | BSD-2-Clause | 2021-06-04T01:02:55 | 2011-09-05T01:44:24 | Python | UTF-8 | Python | false | false | 1,268 | py | import unittest
from mock import patch
class _Success(str):
@property
def failed(self):
return False
class TestVagrantVersion(unittest.TestCase):
def test_vagrant_version_1_3_0(self):
with patch('fabtools.vagrant.local') as mock_local:
mock_local.return_value = _Success("V... | [
"ronan.amicel@gmail.com"
] | ronan.amicel@gmail.com |
9fa570042bd60ed44e495699919da044b67f6599 | dd3b8bd6c9f6f1d9f207678b101eff93b032b0f0 | /basis/AbletonLive10.1_MIDIRemoteScripts/pushbase/clip_control_component.py | d03b661d1f355bccee1a18a5179912ab0e409c38 | [] | no_license | jhlax/les | 62955f57c33299ebfc4fca8d0482b30ee97adfe7 | d865478bf02778e509e61370174a450104d20a28 | refs/heads/master | 2023-08-17T17:24:44.297302 | 2019-12-15T08:13:29 | 2019-12-15T08:13:29 | 228,120,861 | 3 | 0 | null | 2023-08-03T16:40:44 | 2019-12-15T03:02:27 | Python | UTF-8 | Python | false | false | 27,188 | py | # uncompyle6 version 3.4.1
# Python bytecode 2.7 (62211)
# Decompiled from: Python 2.7.16 (v2.7.16:413a49145e, Mar 2 2019, 14:32:10)
# [GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.57)]
# Embedded file name: /Users/versonator/Jenkins/live/output/mac_64_static/Release/python-bundle/MIDI Remote Scripts/pushbase/cli... | [
"jharrington@transcendbg.com"
] | jharrington@transcendbg.com |
8d91955a195e9bf88115635ed8997b216f7814d9 | 4ebeaa3d8dbe4f5ecb1c9d69530f2cee2539c7d4 | /datahub/ninwen.py | 0abeb78571b72ca68f4d80cbad33158b720b9307 | [
"BSD-2-Clause"
] | permissive | tianhm/stock | 0867fb7ce0cef4bf75d38650096ffe026580f0a0 | ed31ff4df90e70c58572121bc75f447e5ce108a1 | refs/heads/master | 2023-09-05T20:08:01.286323 | 2023-08-22T15:07:04 | 2023-08-22T15:07:04 | 108,801,947 | 0 | 0 | BSD-3-Clause | 2023-09-11T23:55:16 | 2017-10-30T04:34:12 | Python | UTF-8 | Python | false | false | 9,807 | py | # -*- coding: utf-8 -*-
# @Time : 2021/9/6 8:21
# @File : ninwen.py
# @Author : Rocky C@www.30daydo.com
# 宁稳网
import json
import os
import random
import time
from parsel import Selector
import requests
import warnings
import datetime
import re
import pandas as pd
import validate_key
import pickle
import loguru
warnin... | [
"jinweizsu@gmail.com"
] | jinweizsu@gmail.com |
bedb1ebe76b92f643cf76628ca2fed73920daa9e | b49e31fefcdd6acb5eb791f2fd3ba2ec80b84e2f | /DEMO/python/antchain_sdk_demo/__init__.py | 54660c33b26f64e6d666ac1e179909cf50da19cd | [
"MIT",
"Apache-2.0"
] | permissive | sdk-team/antchain-openapi-prod-sdk | e2e58d41ef7197ad7b0f0e1777e437ff019131da | 4af1da6f11a2771e373f4a8904904427f06f1887 | refs/heads/master | 2023-03-16T01:44:59.860216 | 2021-03-07T05:46:38 | 2021-03-07T05:46:38 | 276,055,425 | 0 | 0 | MIT | 2020-06-30T09:29:03 | 2020-06-30T09:29:02 | null | UTF-8 | Python | false | false | 21 | py | __version__ = '2.4.0' | [
"sdk-team@alibabacloud.com"
] | sdk-team@alibabacloud.com |
c8640b5fccd56d423cdbf764864f28b14e1d8e59 | abfa9440fb67805d710c2d70fac354444c22b5f8 | /services/rest/main.py | 14e541f0e9431eb314ddf60fa7a80077ea9a0274 | [
"MIT"
] | permissive | KINGdotNET/chainbb | 1e9373442676f4fea96f8a5d5ece444c95392487 | 67fc1749b721d6950835e6c45042880842181850 | refs/heads/master | 2021-05-06T23:41:25.224868 | 2017-11-21T22:52:38 | 2017-11-21T22:52:38 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 14,614 | py | from flask import Flask, jsonify, request
from pprint import pprint
from pymongo import MongoClient
from bson.json_util import dumps
from flask_cors import CORS, cross_origin
from mongodb_jsonencoder import MongoJsonEncoder
from steem import Steem
import os
ns = os.environ['namespace'] if 'namespace' in os.environ els... | [
"aaron.cox@greymass.com"
] | aaron.cox@greymass.com |
bba4fd67e94ae71583cf7f433709f6cad7bacfc7 | 9743d5fd24822f79c156ad112229e25adb9ed6f6 | /xai/brain/wordbase/nouns/_luxury.py | e4dee89c8349b6b4fdb26c26725c56453c0f4872 | [
"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 | 499 | py |
#calss header
class _LUXURY():
def __init__(self,):
self.name = "LUXURY"
self.definitions = [u'great comfort, especially as provided by expensive and beautiful things: ', u'something expensive that is pleasant to have but is not necessary: ', u'something that gives you a lot of pleasure but cannot be done often... | [
"xingwang1991@gmail.com"
] | xingwang1991@gmail.com |
0d23c9eb3813079255485d6d28ebbb4baf1276dc | a512ee52b68f4058d25e4c74972087d20e81965c | /tests/services/test_storage_service.py | 81177f8f54fabec8bdb1b0e1797a14be8193130f | [] | no_license | joshmarshall/tornadorax | 359e236f0bc3f5da81309ee21b610e7f387f2d8d | fc35a08dca8cce8e6c7fa38091c0840a5285790e | refs/heads/master | 2023-08-14T09:42:37.061544 | 2020-02-10T01:18:48 | 2020-02-10T01:18:48 | 33,112,657 | 1 | 0 | null | 2016-01-19T04:55:34 | 2015-03-30T08:53:49 | Python | UTF-8 | Python | false | false | 15,257 | py | import json
import hashlib
import random
try:
from string import letters
except ImportError:
from string import ascii_letters as letters
try:
import urlparse
except ImportError:
import urllib.parse as urlparse
from tornado.testing import AsyncTestCase, gen_test
from testnado.service_case_helpers impo... | [
"catchjosh@gmail.com"
] | catchjosh@gmail.com |
04df1bf0937573a45683f42a2a2164d6ce0d1f49 | b05761d771bb5a85d39d370c649567c1ff3eb089 | /venv/lib/python3.10/site-packages/poetry/core/_vendor/packaging/__about__.py | d6a5b918dbed4d5f6e27b58b4269032a25063f14 | [] | no_license | JawshyJ/Coding_Practice | 88c49cab955eab04609ec1003b6b8c20f103fc06 | eb6b229d41aa49b1545af2120e6bee8e982adb41 | refs/heads/master | 2023-02-19T10:18:04.818542 | 2023-02-06T21:22:58 | 2023-02-06T21:22:58 | 247,788,631 | 4 | 0 | null | null | null | null | UTF-8 | Python | false | false | 96 | py | /home/runner/.cache/pip/pool/87/d4/0e/025817939d425545df0f67630cef17ef3d832a39c8c6411c9821da9537 | [
"37465112+JawshyJ@users.noreply.github.com"
] | 37465112+JawshyJ@users.noreply.github.com |
7f45c773c3dd9aefea08cb9a9711902e9d32e7e8 | 3adf1035314c70514e7acefb13c5489e41fab30e | /stock/migrations/0001_initial.py | a3d8387afb1f6899b25333d2103a84a4be428dba | [
"Apache-2.0"
] | permissive | nowanys/GreaterWMS | 9597bcb2eee25e5c803355d9e7373b62c03af909 | 51baefe3a10016575411133bbc6eb4625d794d82 | refs/heads/master | 2023-02-24T06:14:04.318108 | 2021-01-26T06:57:45 | 2021-01-26T06:57:45 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,077 | py | # Generated by Django 3.1.4 on 2021-01-18 02:23
from django.db import migrations, models
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
name='StockBinModel',
fields=[
('id', models.Auto... | [
"singosgu@gmail.com"
] | singosgu@gmail.com |
2b4b4aa93d84385b2cdcabc1169aa211a0ecf359 | 0fd5793e78e39adbfe9dcd733ef5e42390b8cc9a | /python3/12_Logging/a_builtin_logging/16_logging_json.py | e96163fa788ef205f6df9a6c57247576641c0168 | [] | no_license | udhayprakash/PythonMaterial | 3ea282ceb4492d94d401e3bc8bad9bf6e9cfa156 | e72f44e147141ebc9bf9ec126b70a5fcdbfbd076 | refs/heads/develop | 2023-07-08T21:07:33.154577 | 2023-07-03T10:53:25 | 2023-07-03T10:53:25 | 73,196,374 | 8 | 5 | null | 2023-05-26T09:59:17 | 2016-11-08T14:55:51 | Jupyter Notebook | UTF-8 | Python | false | false | 1,015 | py | import json
import logging
import logging.config
class JsonFormatter:
ATTR_TO_JSON = [
"created",
"filename",
"funcName",
"levelname",
"lineno",
"module",
"msecs",
"msg",
"name",
"pathname",
"process",
"processName",
... | [
"uday3prakash@gmail.com"
] | uday3prakash@gmail.com |
99a7a7f6f37e668b259ef80193a305341646509f | 0818a9020adc6e25b86060a8e84171d0b4958625 | /test_demo/learn_mxnet/main.py | 32fe35b55545b1f1f14cb4d73be8713c45578381 | [] | no_license | wgwangang/mycodes | 2107becb6c457ed88b46426974a8f1fa07ed37dd | 9fa48ca071eacf480034d1f69d3c05171d8a97d2 | refs/heads/master | 2020-03-28T07:58:45.017910 | 2018-03-14T07:21:14 | 2018-03-14T07:21:14 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 320 | py | import mxnet as mx
from mxnet import sym
from mxnet import symbol
net = mx.sym.Variable('data')
net = mx.sym.FullyConnected(data=net, weight=net,name='fc1', num_hidden=128)
net2 = symbol.FullyConnected(data=net,weight=net, name='fc1', num_hidden=128)
print(sym)
print(symbol)
mx.viz.plot_network(symbol=net).render()
| [
"yinpenghhz@hotmail.com"
] | yinpenghhz@hotmail.com |
bea8ea31a5a292c4e98de4927510a0929e68ac71 | c247293cbd83e8b70b23e658b7ae69c05210669a | /test/test_transformers.py | 54b6125eba7b5a6718df8ef7fb25d9cab7e11bb5 | [
"BSD-2-Clause",
"LicenseRef-scancode-secret-labs-2011",
"BSD-3-Clause",
"LicenseRef-scancode-generic-cla",
"BSL-1.0",
"Apache-2.0"
] | permissive | mtmd/pytorch | cdc26d2ae4afb159d7e805be73ea691aff511e2e | 5e6c1246490e6c9934ba426c6ad8adab2387b5ce | refs/heads/main | 2023-07-20T10:02:14.721772 | 2023-07-17T22:14:59 | 2023-07-17T22:15:03 | 314,725,853 | 0 | 0 | NOASSERTION | 2020-11-21T03:39:59 | 2020-11-21T03:39:58 | null | UTF-8 | Python | false | false | 122,023 | py | # Owner(s): ["module: nn"]
import contextlib
from functools import partial
import sys
import torch
import torch.nn as nn
import torch.nn.functional as F
from torch.nn.parameter import Parameter
import unittest
from unittest.mock import patch, MagicMock, ANY
import math
from torch.backends.cuda import sdp_kernel, SDPBa... | [
"pytorchmergebot@users.noreply.github.com"
] | pytorchmergebot@users.noreply.github.com |
699c42fa3bf5aa3e7036983a7ba52eef403977dd | 2f638d47a9681cbb2caab865702ddca39a0456d3 | /djangocms_misc/basic/app_template/views.py | 34e07fb3adb9556429404f527e27f54219269bc9 | [
"MIT"
] | permissive | bnzk/djangocms-misc | b0d1a1950b3d8c7752ea661c74bc08bfbd0360a6 | 8869384305ef7ff8538af986f4854bcfde7257de | refs/heads/develop | 2023-06-08T10:12:11.275012 | 2023-05-30T13:00:34 | 2023-05-30T13:00:34 | 66,085,267 | 1 | 1 | MIT | 2023-02-04T07:49:28 | 2016-08-19T13:43:34 | Python | UTF-8 | Python | false | false | 410 | py | from django.views.generic import ListView, DetailView
from .models import AppTemplate
from .views_utils import PublishedViewMixin, AutoSlugMixin, LanguageChooserEnhancerMixin
class AppTemplateListView(PublishedViewMixin, ListView):
model = AppTemplate
class AppTemplateDetailView(
AutoSlugMixin,
Publish... | [
"bnzk@bnzk.ch"
] | bnzk@bnzk.ch |
d1ddbd8e8f4dfdb9b410d931a174d498c0ea422f | 84f1fea102aeb2d324e8ad3908e1765d04a0a730 | /manage.py | 61ffa52ca3f12cdb094726d77de51bf55c8f649f | [
"Apache-2.0"
] | permissive | Natsoye/explorer | c205f8eb8d08705c2c4ee4ee45c28f7d0a534b10 | 638c70204d6001d9c5c56701917a6273a02c90cf | refs/heads/master | 2021-08-30T10:42:56.371192 | 2021-08-17T15:43:04 | 2021-08-17T15:43:04 | 181,131,891 | 2 | 0 | Apache-2.0 | 2021-08-17T15:43:05 | 2019-04-13T06:43:15 | Python | UTF-8 | Python | false | false | 256 | py | #!/usr/bin/env python
import os
import sys
if __name__ == "__main__":
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "blockexplorer.settings")
from django.core.management import execute_from_command_line
execute_from_command_line(sys.argv)
| [
"mflaxman@gmail.com"
] | mflaxman@gmail.com |
f5ac3e553479901461c99d71fd770afbce1fe15f | 45f93a9d47204d76b8bf25a71dfb79403e75c33c | /Trees_and_Graphs/Bellmen-Ford-Algorithm.py | 147fdc8e118ce15efcd43136f824d40cbe359e4f | [] | no_license | tahmid-tanzim/problem-solving | 0173bce1973ac3e95441a76c10324c0e1b0a57c3 | 6ddb51de6772130f209474e76f39ca2938f444f0 | refs/heads/master | 2023-06-25T02:18:03.690263 | 2023-06-20T06:58:46 | 2023-06-20T06:58:46 | 137,173,850 | 4 | 1 | null | 2022-03-30T08:28:41 | 2018-06-13T06:44:25 | Python | UTF-8 | Python | false | false | 1,960 | py | #!/usr/bin/python3
"""
Bellman Ford Algorithm
Single-Source - Shortest Path (SSSP)
Dynamic Programming
Time complexity - O(n^2)
"""
class Graph:
def __int__(self):
self.adjacencyList = []
if __name__ == "__main__":
# inputs = (
# {
# "start": "A",
# "vertices": ("A", ... | [
"tahmid.tanzim@gmail.com"
] | tahmid.tanzim@gmail.com |
b8572b1bb7ec82b1467e1ed2653aca1c2a3d07b4 | caa10e2a97ebbeea69027b3f35f8fe096d9a6ef2 | /backend/manage.py | 8439f43d3ecddada36719d83f8f0baecb2c891d6 | [] | no_license | crowdbotics-apps/m-201-oct-dev-13649 | 0da5d7457951e5853a55f2ce700e0ecb40cd0a8d | 042c7e9a73c160138b0d69ef294da4af0e9f1e54 | refs/heads/master | 2022-12-30T00:28:43.972381 | 2020-10-20T13:16:56 | 2020-10-20T13:16:56 | 305,697,927 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 638 | py | #!/usr/bin/env python
"""Django's command-line utility for administrative tasks."""
import os
import sys
def main():
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "m_20_oct_dev_13649.settings")
try:
from django.core.management import execute_from_command_line
except ImportError as exc:
r... | [
"team@crowdbotics.com"
] | team@crowdbotics.com |
e58d118d8660ed80dce0203b57e55c19fe6d55fb | 974d04d2ea27b1bba1c01015a98112d2afb78fe5 | /test/collective/test_communication_stream_allreduce_api.py | 60386a6262ff257ec272578a19e1b583f84a3960 | [
"Apache-2.0"
] | permissive | PaddlePaddle/Paddle | b3d2583119082c8e4b74331dacc4d39ed4d7cff0 | 22a11a60e0e3d10a3cf610077a3d9942a6f964cb | refs/heads/develop | 2023-08-17T21:27:30.568889 | 2023-08-17T12:38:22 | 2023-08-17T12:38:22 | 65,711,522 | 20,414 | 5,891 | Apache-2.0 | 2023-09-14T19:20:51 | 2016-08-15T06:59:08 | C++ | UTF-8 | Python | false | false | 1,685 | py | # Copyright (c) 2022 PaddlePaddle Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by appli... | [
"noreply@github.com"
] | PaddlePaddle.noreply@github.com |
f8bc55e2cd75960e261d70dec8161f5a44faaa63 | 494af1db6ac6a72b738d79053a8084c3afd1dbd2 | /smartapp/urls.py | ea82d10e5d8b824dba8bfc8c28204ba5502ada1c | [
"MIT"
] | permissive | ae200/SmartApp | b21f0e031a558341b18ea7ca5787f726e1d09fb5 | b24bb7139e65976428ceec1e9d082f2eac52fd24 | refs/heads/master | 2023-01-15T05:26:31.005542 | 2020-07-16T21:52:31 | 2020-07-16T21:52:31 | 132,465,331 | 1 | 1 | MIT | 2023-01-06T05:24:56 | 2018-05-07T13:34:30 | Python | UTF-8 | Python | false | false | 3,510 | py | """smartapp URL Configuration
The `urlpatterns` list routes URLs to views. For more information please see:
https://docs.djangoproject.com/en/3.0/topics/http/urls/
Examples:
Function views
1. Add an import: from my_app import views
2. Add a URL to urlpatterns: path('', views.home, name='home')
Class-base... | [
"dandaoluks@gmail.com"
] | dandaoluks@gmail.com |
b4b9f787181c6c79a53b128b8e22d735c4638e6c | afa52cfab070818eb08fb9a456b0defcf2df5ebd | /tools/upgrade/errors.py | 26d6437bea9c810823d82964c742119199b1b3a1 | [
"MIT"
] | permissive | vkoukoutsas/pyre-check | a128d77a6d56b50639496025cc458873db7b21c5 | 73fa0dda836c413a86879eb9ef8ba0538e29d615 | refs/heads/master | 2020-07-22T11:09:00.988050 | 2019-09-08T19:56:23 | 2019-09-08T19:57:41 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,582 | py | # Copyright (c) 2016-present, Facebook, Inc.
#
# This source code is licensed under the MIT license found in the
# LICENSE file in the root directory of this source tree.
# pyre-unsafe
import itertools
import json
import sys
from typing import Any, Dict, List, Optional, Tuple
from .postprocess import LOG
def json_... | [
"facebook-github-bot@users.noreply.github.com"
] | facebook-github-bot@users.noreply.github.com |
1eb27ae6c2701ba03d0d277c21d91755f6868825 | 48c62c3693e419257d1e26fd065bf92801f4ef4d | /django_lets_go/custom_xml_emitter.py | 16d19cabf07e9e99990e9f976ae2d4747bf3a91a | [
"MIT"
] | permissive | callhub/django-lets-go | 0da70777331adb9c0637f7b03154bdff7dd8a026 | 70e9016a91b1db06685a7d0cf9ee414e49375fe8 | refs/heads/master | 2021-01-25T13:11:21.140612 | 2014-09-23T16:17:29 | 2014-09-23T16:17:29 | 123,537,598 | 0 | 0 | null | 2018-03-02T06:03:26 | 2018-03-02T06:03:25 | null | UTF-8 | Python | false | false | 2,153 | py | #
# Django-Lets-go License
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this file,
# You can obtain one at http://mozilla.org/MPL/2.0/.
#
# Copyright (C) 2011-2014 Star2Billing S.L.
#
# The Initial Developer of the Original Code... | [
"areski@gmail.com"
] | areski@gmail.com |
d382ac9e7cbdb1e20a269d0296a00a0cd13c0279 | b96f1bad8a74d31d8ff79bc955813bfcd17d7b26 | /Longest Valid Parentheses3.py | 96a38c4d67c9185d78a04d0b65099873753c94b3 | [] | no_license | brianhu0716/LeetCode-Solution | e7177af15e84e833ce8ab05027683ed4ac489643 | 158a4359c90b723545b22c4898047274cc1b80a6 | refs/heads/main | 2023-07-11T05:29:56.783795 | 2021-08-28T12:53:14 | 2021-08-28T12:53:14 | 374,991,658 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,757 | py | # -*- coding: utf-8 -*-
"""
Created on Sat Feb 6 21:37:21 2021
@author: Brian
"""
"""
Created on Sat Feb 6 19:30:57 2021
@author: Brian
"""
# -*- coding: utf-8 -*-
"""
Created on Sat Feb 6 19:30:57 2021
@author: Brian
"""
# -*- coding: utf-8 -*-
"""
Created on Sat Feb 6 21:37:21 2021
@author: Brian
"""
"""
... | [
"85205343+brianhu0716@users.noreply.github.com"
] | 85205343+brianhu0716@users.noreply.github.com |
11749c8f04b7a5cd3b1187f627182c30f5104806 | 03ff89c04cd325d3f7b4266c59e39011f5b466ba | /ogs5_transectplot/venv/lib/python2.7/site-packages/pip/_vendor/urllib3/packages/ordered_dict.py | 21e600c6185e1e25a66b80ef799d7a187d428236 | [] | no_license | timohouben/python_scripts | dabd35a7778fc459beddd5286141d405af32be1c | 15c622645725560c6450cd31ff194aa95394bfc9 | refs/heads/master | 2021-02-03T21:14:29.916525 | 2020-02-27T15:02:04 | 2020-02-27T15:02:04 | 243,537,745 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 9,197 | py | # Backport of OrderedDict() class that runs on Python 2.4, 2.5, 2.6, 2.7 and pypy.
# Passes Python2.7's test suite and incorporates all the latest updates.
# Copyright 2009 Raymond Hettinger, released under the MIT License.
# http://code.activestate.com/recipes/576693/
try:
from thread import get_ident as _get... | [
"timo.houben@ufz.de"
] | timo.houben@ufz.de |
3032790ef87d1235ba183234e61a2382394daf55 | 7bcec8a9c6a240ec0888bec4179f536046464005 | /moviesys/moviesys/.history/library/views_20210325010105.py | 41322bcdbacdcc67f0951a400f57f5fc6504fbbb | [] | no_license | yifanzhang13/MovieManagementSystem_group5 | c64e5810914c3d33ae6cd94e8eed5dc5a3962181 | 4cca1a4299311681d69b2347ca8d7b02e0846ebc | refs/heads/main | 2023-03-29T08:30:26.655108 | 2021-04-01T15:42:52 | 2021-04-01T15:42:52 | 344,417,874 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,720 | py | from django.shortcuts import render
from .models import Movies, Users, Ratings, Links, Tags
from django.db import connection
from django.views import generic
from django.shortcuts import get_object_or_404
from django.http import HttpResponseRedirect
from django.urls import reverse
from library.forms import SearchMovieF... | [
"yifancheung13@gmail.com"
] | yifancheung13@gmail.com |
f53fbcd0fb56c46f2908629aafc5eecc2a3e9377 | 2af74fe66cd24eb63814477bc93b409ff971dcc2 | /backend/test_24647/settings.py | 05b71697ee5df0aaf60fdeda09c89b9f8ffc8e31 | [] | no_license | crowdbotics-apps/test-24647 | 3852044942b8e31a2f2636984015112369a67559 | 403ab427de342341739bd821fe7facebe14629f7 | refs/heads/master | 2023-03-05T16:23:50.487393 | 2021-02-21T19:30:25 | 2021-02-21T19:30:25 | 340,983,176 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,017 | py | """
Django settings for test_24647 project.
Generated by 'django-admin startproject' using Django 2.2.2.
For more information on this file, see
https://docs.djangoproject.com/en/2.2/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/2.2/ref/settings/
"""
import os... | [
"team@crowdbotics.com"
] | team@crowdbotics.com |
c33900bba020c0bda8c2bba886b7750ff883dd66 | 141545126466a00f32247dfa40e067ec049b0fa4 | /Programming Fundamentals Python/07 Data Types and Variables/Pounds to Dollars.py | 2887f8e7bcfe398e6a0111998e1cf147e5f3e69a | [] | no_license | RadkaValkova/SoftUni-Web-Developer | 83314367172a18f001e182b4e57f7ca0502ad1fc | 61d3414373498bb6009ae70e8d17f26cd2d88ea5 | refs/heads/main | 2023-06-01T02:11:06.606370 | 2021-06-29T19:39:19 | 2021-06-29T19:39:19 | 325,611,606 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 91 | py | british_pound_value = float(input())
usd = british_pound_value * 1.31
print(f'{usd:.3f}') | [
"radka_valkova@abv.bg"
] | radka_valkova@abv.bg |
c87233b316d1cde9beb727f774ac0a744257d918 | e1ffebca6a0f185663c779462e3ca27866f557b8 | /week1/Project1/api/urls.py | 6d299dbdab8ff4ebcaebb95a5661e680c6a213b5 | [] | no_license | asselyer/Backend2019 | d8d85d7850261880fe4aeef9092b0a8c7b1b6767 | ec5931e2bd22ec62e68592a4199c00184f4dacc3 | refs/heads/master | 2020-07-24T13:38:21.246351 | 2019-12-04T03:16:27 | 2019-12-04T03:16:27 | 207,944,768 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 423 | py | from django.urls import path, include
from api import views
urlpatterns = [
path('projects/', views.ProjectList.as_view(), name='project_list'),
path('projects/<int:pk>', views.ProjectDetail.as_view(), name='project_detail'),
path('tasks/', views.TaskList.as_view(), name='task_list'),
path('tasks/<int... | [
"asel.yer98@gmail.com"
] | asel.yer98@gmail.com |
49ffa16b8391b7ab4ce364bdc4d7a5b5e37759e8 | d73e73bad3d797bbfa82971ac44e424e7e163fe6 | /mimic_learner/comparsion_learners/cart_scratch.py | 257f6261c6c76b2d76a50064ea52f7e72e36c284 | [] | no_license | Guiliang/statistical-DRL-interpreter | 80bdd885c1d3029a48654118667c0071f3e4a8d8 | 033d79e45579fb7ddd824c8e04d245d0285741f3 | refs/heads/master | 2023-07-24T21:50:56.323738 | 2021-01-04T05:28:20 | 2021-01-04T05:28:20 | 241,288,171 | 1 | 0 | null | 2023-07-23T06:00:02 | 2020-02-18T06:22:52 | Python | UTF-8 | Python | false | false | 6,793 | py | import numpy as np
class CART(object):
def __init__(self, tree='cls', criterion='gini', prune='depth', max_depth=4, min_criterion=0.05):
self.feature = None
self.label = None
self.n_samples = None
self.gain = None
self.left = None
self.right = None
self.thre... | [
"gla68@sfu.ca"
] | gla68@sfu.ca |
c1a9d7614dee9add2fb785fc83ec7bedfbff2655 | 1419418226b6ba0f510649daaf62b71554cc2284 | /amatrice/make_gps.py | f3e7202422146a69bb69df5e38665b74a0eaa03f | [] | no_license | shineusn/mylife | 2ef48a777e39be2ef746c3dad16ea963d5b23e5e | 61dfa72d9047551746d26b7fe01fb5c2f1f0657a | refs/heads/master | 2020-03-22T13:44:42.422127 | 2018-02-13T18:09:43 | 2018-02-13T18:09:43 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,978 | py | from numpy import genfromtxt,sqrt
out='/Users/dmelgar/Amatrice2016/GPS/neu_Oct26th/'
stafile='/Users/dmelgar/Amatrice2016/GPS/gps_Oct26th.sta'
threshold=0.005 #In m
#sta=genfromtxt('/Users/dmelgar/Amatrice2016/GPS/offsets.txt',usecols=0,dtype='S')
#lonlat=genfromtxt('/Users/dmelgar/Amatrice2016/GPS/offsets.txt',useco... | [
"dmelgar@berkeley.edu"
] | dmelgar@berkeley.edu |
af5d3aef501bd267cbd20147636139c54f4ecdca | 42fe2827d14a82043ade9393beaedf53e22a69f5 | /bebop_ws/devel/lib/python2.7/dist-packages/mav_state_machine_msgs/msg/__init__.py | 577c4b1523728ce85c4360d739c38db39e97fb3c | [] | no_license | cjbanks/bebop-software-framework | a3714646545e9d7d71299a365814bc87437f5e14 | 7da1bbdef4e84aa0ed793cfaad9fe133959ebe21 | refs/heads/master | 2023-04-30T17:52:23.255302 | 2020-11-18T18:32:41 | 2020-11-18T18:32:41 | 368,626,051 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 150 | py | /home/chris/bebop-software-framework/bebop_ws/devel/.private/mav_state_machine_msgs/lib/python2.7/dist-packages/mav_state_machine_msgs/msg/__init__.py | [
"Chewie_Alex@nder1"
] | Chewie_Alex@nder1 |
1463098d36cf7bdefe89981ed0bf1c123c701674 | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p03569/s302751603.py | 4c25973ce80b184d1269be33c4a741981577c714 | [] | 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 | 598 | py | import sys
from collections import Counter
s = input()
n = len(s)
ns = []
no = []
for i in range(n):
if s[i] != "x":
ns.append(s[i])
no.append(i)
no = [-1] + no + [n]
m = len(no)
sa = []
for i in range(m-1):
sa.append(no[i+1] - no[i] - 1)
if ns != ns[::-1]:
prin... | [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
0a1bbb4c953fe1a11da5f00cdc77fb7901b5af27 | 75452de12ec9eea346e3b9c7789ac0abf3eb1d73 | /build/zircon/populate_zircon_public.py | 7c7d07c57d69742b00f01e9cb616b92c007143f3 | [
"BSD-3-Clause"
] | permissive | oshunter/fuchsia | c9285cc8c14be067b80246e701434bbef4d606d1 | 2196fc8c176d01969466b97bba3f31ec55f7767b | refs/heads/master | 2022-12-22T11:30:15.486382 | 2020-08-16T03:41:23 | 2020-08-16T03:41:23 | 287,920,017 | 2 | 2 | BSD-3-Clause | 2022-12-16T03:30:27 | 2020-08-16T10:18:30 | C++ | UTF-8 | Python | false | false | 4,949 | py | #!/usr/bin/env python3.8
# Copyright 2019 The Fuchsia Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import json
import os
import shutil
import sys
SCRIPT_DIR = os.path.dirname(os.path.abspath(__file__))
FUCHSIA_ROOT = os.path.dirnam... | [
"commit-bot@chromium.org"
] | commit-bot@chromium.org |
7305f6254d6dca7956dbd70d1542a09a54f2670c | b6559661c06efc7e69096c4fedc08509545c2602 | /tests/test_dh_prime_generators/test_two_ton.py | 5e0dd6ee048d2e57478030c20a9579c501c1be2b | [
"MIT"
] | permissive | Zapix/mtpylon | ed29d8c67ab2b6b3fd8c6d84fc129e6e143600ff | b268a4e2d1bc641cace1962ea68de73c1156e44c | refs/heads/dev | 2023-06-27T09:13:20.268691 | 2021-08-05T20:08:18 | 2021-08-05T20:08:18 | 306,233,058 | 9 | 0 | MIT | 2021-08-05T20:07:23 | 2020-10-22T05:34:36 | Python | UTF-8 | Python | false | false | 9,108 | py | # -*- coding: utf-8 -*-
import pytest
from aioresponses import aioresponses # type: ignore
from mtpylon.dh_prime_generators.two_ton import generate, SAFE_PRIME_URL
two_ton_responses = [
{
'p': {
'human': '29,749,001,914,257,905,533,821,621,796,385,130,351,804,895,306,933,420,788,210,276,585,8... | [
"zap.aibulatov@gmail.com"
] | zap.aibulatov@gmail.com |
de63cc8f0fc0605459e386f4e4681be42967ca58 | 93f47ba04fc18c4e537f0a48fe6232e2a89a4d30 | /examples/adspygoogle/adwords/v201406/campaign_management/add_experiment.py | 0016c83287c0eebaeadcbcc187dafc3aba38b067 | [
"Apache-2.0"
] | permissive | jasonshih/googleads-python-legacy-lib | c56dc52a1dab28b9de461fd5db0fcd6020b84a04 | 510fad41ecf986fe15258af64b90f99a96dc5548 | refs/heads/master | 2021-04-30T22:12:12.900275 | 2015-03-06T15:35:21 | 2015-03-06T15:35:21 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,712 | py | #!/usr/bin/python
#
# Copyright 2013 Google Inc. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required b... | [
"msaniscalchi@google.com"
] | msaniscalchi@google.com |
19c43377525c88e3507724542a581786aad55373 | 6188f8ef474da80c9e407e8040de877273f6ce20 | /python_modules/libraries/dagster-fivetran/dagster_fivetran_tests/test_asset_defs.py | b7b03f9b2586e8537bfca4c70fd41ec34123525b | [
"Apache-2.0"
] | permissive | iKintosh/dagster | 99f2a1211de1f3b52f8bcf895dafaf832b999de2 | 932a5ba35263deb7d223750f211c2ddfa71e6f48 | refs/heads/master | 2023-01-24T15:58:28.497042 | 2023-01-20T21:51:35 | 2023-01-20T21:51:35 | 276,410,978 | 1 | 0 | Apache-2.0 | 2020-07-01T15:19:47 | 2020-07-01T15:13:56 | null | UTF-8 | Python | false | false | 5,327 | py | import pytest
import responses
from dagster import AssetKey, DagsterStepOutputNotFoundError
from dagster._legacy import build_assets_job
from dagster_fivetran import fivetran_resource
from dagster_fivetran.asset_defs import build_fivetran_assets
from dagster_fivetran.resources import (
FIVETRAN_API_BASE,
FIVETR... | [
"noreply@github.com"
] | iKintosh.noreply@github.com |
67dbe2876b4fdc551b2fc9988b78fa0932c92363 | 8067ca3d96d00080df5d54aa5bc2ec33b7fc3035 | /Hexagonal Grid.py | bae5ce1e331b29f864651624619e26579cdf6bc1 | [
"Apache-2.0"
] | permissive | Ashutosh-gupt/HackerRankAlgorithms | 9620bd12c66a9f26f08949a292b3baad79387227 | 439bf2e31fd395d19d40f79e969153e50e5358b5 | refs/heads/master | 2022-12-24T18:56:53.263797 | 2016-10-05T03:14:07 | 2016-10-05T03:14:07 | 376,810,303 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,112 | py | # -*- coding: utf-8 -*-
"""
You are given a hexagonal grid of size 2xN. Your task is to construct the grid with 2x1 dominoes. The dominoes can be
arranged in any of the three orientations shown below. To add to the woes, certain cells of the hexogonal grid are
blackened i.e., no domino can occupy that cell. Can you con... | [
"zhangdanyangg@gmail.com"
] | zhangdanyangg@gmail.com |
059e84c2f1ff6af24c13aa2c403890209360ddbc | 6fa7f99d3d3d9b177ef01ebf9a9da4982813b7d4 | /WLKF79mxKnhjtrFRB_13.py | 19738ce84620bcbc808363c11292586b2032ab08 | [] | 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 | 181 | py |
def is_good_match(lst):
if len(lst) % 2 != 0:
return "bad match"
lst1 = [x for x in lst[0::2]]
lst2 = [x for x in lst[1::2]]
return [x + y for x,y in zip(lst1, lst2)]
| [
"daniel.reich@danielreichs-MacBook-Pro.local"
] | daniel.reich@danielreichs-MacBook-Pro.local |
065966e1fbabe141ee422c8cc29b6acefaf67a49 | 3545c3a5ede04aeb229c3da9792f1430959bbb0e | /BLOGGER/users/forms.py | f0c26fca518965f8952077f9858abb3d3c76ff61 | [] | no_license | Gourav2000/DJ3 | 6050315e4a65501b3f59617ad8bf174fbdaa8074 | bab01fa5fda0f8c274ed9e75d32306ff8d087355 | refs/heads/master | 2022-12-01T02:47:06.222790 | 2020-07-13T09:00:56 | 2020-07-13T09:00:56 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 306 | py | from django import forms
from django.contrib.auth.models import User
from django.contrib.auth.forms import UserCreationForm
class UserRegisterForm(UserCreationForm):
email=forms.EmailField();
class Meta:
model=User
fields=["username","email","password1",'password2'];
| [
"parajbhattacharjee123@gmail.com"
] | parajbhattacharjee123@gmail.com |
fef662ef6fd908b5b68e87d622023d04aa854e13 | 13f55c8fc102c64a8924d83579aeb0bd563daeb9 | /src/aria2p/cli/commands/add_magnet.py | d5e2d71da5711321591a2f8000b059a88e037584 | [
"ISC"
] | permissive | wqcsim/aria2p | e67b8b7d5c5afffc22d3728d3f8c89e5b24bfc29 | 6cdc9a1ef5ed0413fffa3be4885f4b5325177660 | refs/heads/master | 2023-07-26T20:02:05.134854 | 2021-08-26T20:47:20 | 2021-08-26T20:47:20 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,058 | py | """Command to add magnets."""
import sys
from typing import List
from aria2p.api import API
from aria2p.utils import read_lines
def add_magnets(
api: API,
uris: List[str] = None,
from_file: str = None,
options: dict = None,
position: int = None,
) -> int:
"""
Add magnet subcommand.
... | [
"pawamoy@pm.me"
] | pawamoy@pm.me |
9f8044eff2a26ebffb2ef7e386df954dd5e218e3 | d0a2ff39d48dbcf6b019c7c7530bcda1a398e2be | /python_for_data_analysis/Chapter_2/chapter2.py | a60592d6087c79b204769f0779d3261e7e4605b2 | [] | no_license | foxcodenine/books | 2711fd8be596bc7fcbd4c00d6a0573acb29dee3f | 100624b41484f853ab3e850fb33d99d0dd65d4f3 | refs/heads/master | 2023-03-08T05:54:18.270243 | 2022-06-21T19:22:40 | 2022-06-21T19:22:40 | 205,091,163 | 0 | 0 | null | 2023-03-05T12:57:12 | 2019-08-29T05:57:41 | JavaScript | UTF-8 | Python | false | false | 1,689 | py | # IPYTHON $ JUPYTER NOTEBOOK
# from ipython shell you can do #run to run it:
# %run hello_world.py
# ______________________________________________________________________
# ipython use pretty-print.
from numpy.random import randn
data = {i: randn() for i in range(7)}
# _________________________________________... | [
"foxcode9@gmail.com"
] | foxcode9@gmail.com |
d14bab7577070de6f6d2a27551adc98ce5c40c9f | a663eb28d9c5e05d505a94aba511649b68e951cf | /pytype/tests/test_attr.py | f25b8569123f084b7e28653c08ae1bcd5c3a0fc2 | [
"Apache-2.0",
"MIT"
] | permissive | CyberFlameGO/pytype | 603240757291e066aad4259ce0b93221d90a4710 | c8cbeea997634455b5abcb27c76c58aa0dfc25ae | refs/heads/master | 2023-07-02T14:39:55.343774 | 2021-08-06T21:55:02 | 2021-08-06T21:55:02 | 393,544,239 | 0 | 0 | NOASSERTION | 2021-08-07T01:12:39 | 2021-08-07T01:10:49 | null | UTF-8 | Python | false | false | 19,895 | py | # Lint as: python3
"""Tests for attrs library in attr_overlay.py."""
from pytype.tests import test_base
class TestAttrib(test_base.TargetIndependentTest):
"""Tests for attr.ib."""
def test_basic(self):
ty = self.Infer("""
import attr
@attr.s
class Foo(object):
x = attr.ib()
... | [
"rechen@google.com"
] | rechen@google.com |
d3911e4c9f0cb924b32844dc531ca096d2def61c | 06c2bc496f9e285f06e4c3c71f14d5716f411d89 | /source/webapp/migrations/0007_auto_20210504_1243.py | 10b149d9e4237d16899b45386bb911ca394c7078 | [] | no_license | Beknasar/Coin_collection | 37a9e77cc00270dfcb9d0cb5916f985cec4c591d | 091860f98e7dc81d460ab0cbcb6ca1d7fdeffda8 | refs/heads/master | 2023-06-09T16:25:30.473134 | 2021-06-25T09:31:13 | 2021-06-25T09:31:13 | 365,229,399 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 700 | py | # Generated by Django 2.2 on 2021-05-04 12:43
import django.core.validators
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('webapp', '0006_auto_20210503_1327'),
]
operations = [
migrations.AlterField(
model_name='coin',
... | [
"680633@gmail.com"
] | 680633@gmail.com |
2726900ca710ad9b236b6180dcd2909b84e4d9e7 | 2b2af3a4924f74d0be10370f25121c015f37aba0 | /EVLA_pipe_statwt.py | 0def7573ebcbc6c607a05ab4529f67a8883704f1 | [] | no_license | tomr-stargazer/VLA_pipeline_custom | 98ba3cec311ccc8fa37e0d3424a3c97da1816669 | cf5720588ded8c7dd88cf5ecda4df82824183078 | refs/heads/master | 2020-04-02T08:01:25.574938 | 2018-10-22T23:54:22 | 2018-10-22T23:54:22 | 154,225,698 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,334 | py | ######################################################################
#
# Copyright (C) 2013
# Associated Universities, Inc. Washington DC, USA,
#
# This library is free software; you can redistribute it and/or modify it
# under the terms of the GNU Library General Public License as published by
# the Free Software Fo... | [
"t.rice90@gmail.com"
] | t.rice90@gmail.com |
5f80c5d519dbfcbcd70511459f0737348f4fd5b2 | 1566f14c336e67c77001b620df55f68f14b4e2c5 | /tests/bench.py | aeb901e3a963ea48ce486f3ec163f0a3bbe2d442 | [
"BSD-3-Clause"
] | permissive | wolfmetr/django-cacheops | 9645088c2f20f12aad955fc5ec7aaa2742ab4f41 | ce56df88f341c3a4c22a58d0cd0557e92838d89a | refs/heads/master | 2021-01-18T08:46:22.312893 | 2013-12-03T12:58:06 | 2013-12-03T12:58:06 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,379 | py | from cacheops import invalidate_obj
from cacheops.conf import redis_client
from .models import Category, Post
count_key = Category.objects.all()._cache_key(extra='count')
def invalidate_count():
redis_client.delete(count_key)
def do_count():
Category.objects.cache().count()
def do_count_no_cache():
Cate... | [
"suor.web@gmail.com"
] | suor.web@gmail.com |
065fe50031eb0f2ee2bd0f6c17af9744ac523539 | f3b233e5053e28fa95c549017bd75a30456eb50c | /ptp1b_input/L82/82-bs_wat_20Abox/set_1ns_equi.py | 28657cb7707bdfb592da52d7aa486e0d2ea88321 | [] | no_license | AnguseZhang/Input_TI | ddf2ed40ff1c0aa24eea3275b83d4d405b50b820 | 50ada0833890be9e261c967d00948f998313cb60 | refs/heads/master | 2021-05-25T15:02:38.858785 | 2020-02-18T16:57:04 | 2020-02-18T16:57:04 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 916 | py | import os
dir = '/mnt/scratch/songlin3/run/ptp1b/L82/wat_20Abox/ti_one-step/82_bs/'
filesdir = dir + 'files/'
temp_equiin = filesdir + 'temp_equi.in'
temp_pbs = filesdir + 'temp_1ns_equi.pbs'
lambd = [ 0.00922, 0.04794, 0.11505, 0.20634, 0.31608, 0.43738, 0.56262, 0.68392, 0.79366, 0.88495, 0.95206, 0.99078]
for j in... | [
"songlin3@msu.edu"
] | songlin3@msu.edu |
f41f0aeac0150a5016682fef4713dad35084986b | 0b40458397355319e74f421b5903b6bdbdb5ee9c | /accounts/migrations/0007_remove_userprofile_friends.py | 1acf280c35ce724833ff78fa83c547be53db7390 | [] | no_license | OllyDorvelus/visumic | bae61c7768ed1fa0b76134dbd715e2f1ece3143d | 884a7c89bd562ef7e2e33a01a3239a48b038ac40 | refs/heads/master | 2022-12-09T10:02:06.921966 | 2018-03-01T03:12:43 | 2018-03-01T03:12:43 | 122,236,678 | 1 | 0 | null | 2022-12-08T00:39:38 | 2018-02-20T18:17:26 | HTML | UTF-8 | Python | false | false | 398 | py | # -*- coding: utf-8 -*-
# Generated by Django 1.11 on 2017-04-29 23:16
from __future__ import unicode_literals
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('accounts', '0006_auto_20170401_2124'),
]
operations = [
migrations.RemoveField(
... | [
"ollydorvelus@gmail.com"
] | ollydorvelus@gmail.com |
968ecbcdd00c75509c462e5effc5495acb927ec4 | e41b0bb4f8f835082f8c559101b94dc5f64976ae | /exp/exp34.py | ce1607b45bd2258286f1bebbbc233ab9b7fc5b4e | [] | no_license | voytekresearch/pacological | 5e6f5aba0ede883594863a56b4702f907d458a90 | 306f953f456e87298322065308ad4e2fbbe6d7f7 | refs/heads/master | 2021-01-21T15:34:35.003245 | 2018-12-03T01:00:26 | 2018-12-03T01:00:26 | 37,220,244 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,989 | py | #! /usr/bin/env python
# -*- coding: utf-8 -*-
"""PAC as selective amplification and information transmission."""
import numpy as np
import matplotlib.pyplot as plt; plt.ion()
if __name__ == "__main__":
from pacological.exp.exp6 import run
import sys
import pandas as pd
import os
from itertools im... | [
"Erik.Exists@gmail.com"
] | Erik.Exists@gmail.com |
c30f6710203806ad57e0d9cfcaad2b3e8c7ed1fb | 2990b0841b63f300a722107933c01c7237a7976b | /all_xuef/程序员练级+Never/xuef code/xuef_code_python/python_cookbook_code/1. 数据结构和算法/1.6 字典中的键映射多个值.py | 735e481d02cb5f19c48205d6c10befff0a5121b4 | [] | no_license | xuefengCrown/Files_01_xuef | 8ede04751689e0495e3691fc5d8682da4d382b4d | 677329b0189149cb07e7ba934612ad2b3e38ae35 | refs/heads/master | 2021-05-15T04:34:49.936001 | 2019-01-23T11:50:54 | 2019-01-23T11:50:54 | 118,802,861 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 1,196 | py | """
问题
怎样实现一个键对应多个值的字典(也叫 multidict)?
解决方案
一个字典就是一个键对应一个单值的映射。
如果你想要一个键映射多个值,那么你就需要将这多个值放到另外的容器中, 比如列表或者集合里面。
比如,你可以像下面这样构造这样的字典:
d = {
'a' : [1, 2, 3],
'b' : [4, 5]
}
e = {
'a' : {1, 2, 3},
'b' : {4, 5}
}
"""
"""
选择使用列表还是集合取决于你的实际需求。
如果你想保持元素的插入顺序就应该使用列表,
如果想去掉重复元素就使用集合(并且不关心元素的顺序问题)。
"""
"""
你可以很... | [
"643472092@qq.com"
] | 643472092@qq.com |
8e000e5070188bf89462da25f306d558f36ec373 | 4fca17a3dbc3e74ba7e46bd7869eb6d138e4c422 | /_1551_Minimum_Operations_to_Make_Array_Equal.py | c1ce0ef2b3b5d7928801d2d186042277770336b7 | [] | no_license | mingweihe/leetcode | a2cfee0e004627b817a3c0321bb9c74128f8c1a7 | edff905f63ab95cdd40447b27a9c449c9cefec37 | refs/heads/master | 2021-06-19T07:46:46.897952 | 2021-05-02T05:13:17 | 2021-05-02T05:13:17 | 205,740,338 | 3 | 0 | null | null | null | null | UTF-8 | Python | false | false | 281 | py | class Solution(object):
def minOperations(self, n):
"""
:type n: int
:rtype: int
"""
last = 2 * (n - 1) + 1
avg = (last + 1) / 2
res = 0
for i in xrange(n/2):
res += avg - (i*2 + 1)
return res
| [
"hemingwei2017@gmail.com"
] | hemingwei2017@gmail.com |
031545508eb0cde90949a94355460d23108404d2 | 4a1b61cf551db7843050cc7080cec6fd60c4f8cc | /2020/백준문제/Other/1018_체스판 다시 칠하기.py | 15e56f6ea95ea6eb5167092167e29d02dcf8c5b5 | [] | no_license | phoenix9373/Algorithm | 4551692027ca60e714437fd3b0c86462f635d8ff | c66fd70e14bb8357318e8b8f386d2e968f0c4d98 | refs/heads/master | 2023-08-24T10:01:20.798430 | 2021-10-15T07:57:36 | 2021-10-15T07:57:36 | 288,092,774 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,008 | py | n, m = map(int, input().split()) # m*n
arr = [list(input()) for i in range(n)]
# 왼쪽 맨 위가 W일때, B일때를 나누어 구함.
# 최대 row = (n - 8) index까지 가능.
max_r = n - 8 # 2
max_c = m - 8
s = ['W', 'B']
count = []
for char in s:
for r in range(0, max_r + 1):
for c in range(0, max_c + 1):
test = [row[c:c+8] for ro... | [
"phoenix9373@naver.com"
] | phoenix9373@naver.com |
5662acc9dfbb5eccbc2f255113862a6a02a9523d | bb150497a05203a718fb3630941231be9e3b6a32 | /framework/e2e/jit/test_Pad2D_25.py | 43af560c2452752f47a1cc5b0ee2f2d14862faf8 | [] | no_license | PaddlePaddle/PaddleTest | 4fb3dec677f0f13f7f1003fd30df748bf0b5940d | bd3790ce72a2a26611b5eda3901651b5a809348f | refs/heads/develop | 2023-09-06T04:23:39.181903 | 2023-09-04T11:17:50 | 2023-09-04T11:17:50 | 383,138,186 | 42 | 312 | null | 2023-09-13T11:13:35 | 2021-07-05T12:44:59 | Python | UTF-8 | Python | false | false | 608 | py | #!/bin/env python
# -*- coding: utf-8 -*-
# encoding=utf-8 vi:ts=4:sw=4:expandtab:ft=python
"""
test jit cases
"""
import os
import sys
sys.path.append(os.path.abspath(os.path.dirname(os.getcwd())))
sys.path.append(os.path.join(os.path.abspath(os.path.dirname(os.getcwd())), "utils"))
from utils.yaml_loader import Ya... | [
"825276847@qq.com"
] | 825276847@qq.com |
ae24899f5d7f723d07cb58f1c053b40315c20c77 | d5c67ac21a5210d36c74bfd0a4d45c91ab3c1879 | /Spyder/python机器学习应用/学生上网分析/学生上网分析之上网时长聚类.py | 39c78009f51ebda23804e3ee7586778083623f24 | [] | no_license | HanKin2015/ACM | 93036222eb5e382e5a1269c0208c58bba4ad5af7 | 040779ce4a3e88c40c7beb9cba6a33aa3695bf50 | refs/heads/master | 2022-03-03T05:15:51.053240 | 2021-12-20T14:18:14 | 2021-12-20T14:21:11 | 57,268,602 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,295 | py | # -*- coding: utf-8 -*-
"""
Created on Wed Aug 23 16:03:02 2017
@author: HanKin
"""
# -*- coding: utf-8 -*-
'''
对上网时长时间进行聚类
'''
import numpy as np
from sklearn.cluster import DBSCAN
from sklearn import metrics#计算方法
import matplotlib.pyplot as plt
mac2id=dict()
onlinetimes=[]
f=open('TestData.txt'... | [
"1058198502@qq.com"
] | 1058198502@qq.com |
5154a4e9ad8557de0e8b54229abfaae3972c2128 | 6c9b8812e1f5e1f6bc881265ce9de9efeb22869d | /model_zoo/obj_detection/rpn.py | 63b8ffae98cd091045ca49ae3bcdde701b367885 | [] | no_license | maxme1/model_zoo | a194582362ab07e2b40dfd43fc5e0aa60f7289cf | ef34432cbd7eb912ba976cd1448427f3cc3ff6f5 | refs/heads/master | 2022-07-12T10:08:43.279906 | 2022-06-23T18:37:57 | 2022-06-23T18:37:57 | 90,151,979 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,542 | py | import numpy as np
import torch.nn as nn
from torch.nn import functional
class RPN(nn.Module):
def __init__(self, in_channels, mid_channels, kernel_size, num_anchors):
super().__init__()
self.standardise = nn.Conv2d(in_channels, mid_channels, kernel_size, padding=kernel_size // 2)
self.cla... | [
"maxs987@gmail.com"
] | maxs987@gmail.com |
e732fc6870ede2af1dff4d1fd378f33fa5b4cb66 | 485412a223a244544e8e099c0425b580224b1026 | /iCount/tests/test_summary.py | 0c46bf3fbe8f0cfcef2b527b37eee20122d2c826 | [
"MIT"
] | permissive | dblenkus/iCount | c18de739e0a16385fd023202d05645ae7ea80be8 | 9d54a49f98f7393fa9003834ba0173bb5f70b61a | refs/heads/master | 2020-06-23T10:44:43.894222 | 2016-11-23T09:41:12 | 2016-11-23T09:41:12 | 74,653,274 | 0 | 0 | null | 2016-11-24T08:32:09 | 2016-11-24T08:32:08 | null | UTF-8 | Python | false | false | 12,726 | py | # pylint: disable=missing-docstring, protected-access
import unittest
import tempfile
import warnings
from iCount.analysis import summary
from iCount.tests.utils import make_file_from_list, make_list_from_file, get_temp_file_name
def _make_types_length(annotation, subtype='biotype', excluded_types=None):
"""
... | [
"zmrzlikar.jure@gmail.com"
] | zmrzlikar.jure@gmail.com |
cf0cb9b68aefd4e7d4cc1752125b10ee68486cd7 | c9ffc4b4d2bec921d7f7acbdcd3b2dda85c62a07 | /example_taxi/example/serializers.py | e707a860f0c63fb6bb37fda6952de28f402e2544 | [] | no_license | gridl/taxi-app-channels2 | 1c07f7e6832b743e4593653c633c377579756313 | 7958a071a37b0b90c2847a521f4196d4443318a2 | refs/heads/master | 2020-03-30T19:48:05.692197 | 2018-04-19T13:19:49 | 2018-04-19T13:19:49 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,134 | py | from django.contrib.auth import get_user_model
from rest_framework import serializers
from .models import Trip
class UserSerializer(serializers.ModelSerializer):
password1 = serializers.CharField(write_only=True)
password2 = serializers.CharField(write_only=True)
def validate(self, data):
if dat... | [
"hermanmu@gmail.com"
] | hermanmu@gmail.com |
1be012a64757e907d83446fe8297da8be07d1ca7 | 879ac03dd910d152170d6d1e3ff4d5e522b14d79 | /Tutorial/02. 30 Days of Code/025. Day 24; More Linked Lists.py | d5beb71d16b8a7bc1ee33d88692932b22a6858e9 | [] | no_license | dispe1/Hackerrank-Solutions | ae47920d7761546fd2ef753c1b4f9ae087aaed2a | 67b792dc2cb2933eb1f1565100ea13b0c9783fba | refs/heads/master | 2020-07-11T21:25:39.824667 | 2019-12-10T12:00:12 | 2019-12-10T12:00:12 | 204,646,756 | 4 | 3 | null | null | null | null | UTF-8 | Python | false | false | 1,186 | py | # Problem: https://www.hackerrank.com/challenges/30-linked-list-deletion/problem
# Difficulty : Easy
# Score : 30
class Node:
def __init__(self,data):
self.data = data
self.next = None
class Solution:
def insert(self,head,data):
p = Node(data)
if head==None:
... | [
"lkjim0757@naver.com"
] | lkjim0757@naver.com |
dc343080a3e6d41edc7e4dd758414b296f10372e | 0a1742760b617db58d13bec3d715d83d4f552bdb | /scripts/delnopm.py | e6d88e6657644f1097cd0eee3bc9096c03d5e1e6 | [
"MIT"
] | permissive | rezvorck/vkbot | 1a97709e4bf3ec51e02af17ecc88bc0ceac59058 | f0e3a9ce4c6384bca3939960996e449d98d6ae46 | refs/heads/master | 2021-01-01T16:53:12.262398 | 2017-07-20T15:48:15 | 2017-07-20T15:48:15 | 97,942,346 | 1 | 0 | null | 2017-07-21T11:48:01 | 2017-07-21T11:48:00 | null | UTF-8 | Python | false | false | 436 | py | import logging
import scriptlib
# noinspection PyUnusedLocal
def main(a, args):
friends = scriptlib.getFriends(a, fields='can_write_private_message')
to_del = []
for j in friends:
if not j['can_write_private_message']:
to_del.append(str(j['id']))
logging.info('Found id{} ({... | [
"kalinochkind@gmail.com"
] | kalinochkind@gmail.com |
c54de06cec40dc1412ffe45eae83c0d130d2c7ec | e7efae2b83216d9621bd93390959d652de779c3d | /hyperv/datadog_checks/hyperv/check.py | aa4d44f2a269738f8b3d15872dcfd9dd47ce87f9 | [
"BSD-3-Clause",
"LicenseRef-scancode-unknown-license-reference",
"MIT",
"BSD-3-Clause-Modification",
"Unlicense",
"Apache-2.0",
"LGPL-3.0-only",
"LicenseRef-scancode-public-domain",
"BSD-2-Clause",
"CC0-1.0"
] | permissive | DataDog/integrations-core | ee1886cc7655972b2791e6ab8a1c62ab35afdb47 | 406072e4294edff5b46b513f0cdf7c2c00fac9d2 | refs/heads/master | 2023-08-31T04:08:06.243593 | 2023-08-30T18:22:10 | 2023-08-30T18:22:10 | 47,203,045 | 852 | 1,548 | BSD-3-Clause | 2023-09-14T16:39:54 | 2015-12-01T16:41:45 | Python | UTF-8 | Python | false | false | 427 | py | # (C) Datadog, Inc. 2021-present
# All rights reserved
# Licensed under a 3-clause BSD style license (see LICENSE)
from datadog_checks.base.checks.windows.perf_counters.base import PerfCountersBaseCheckWithLegacySupport
from .metrics import METRICS_CONFIG
class HypervCheckV2(PerfCountersBaseCheckWithLegacySupport):
... | [
"noreply@github.com"
] | DataDog.noreply@github.com |
c5de719c57b09e8105dec4d270d58fd962cd0482 | 1c6283303ceb883add8de4ee07c5ffcfc2e93fab | /Jinja2/lib/python3.7/site-packages/uhd_restpy/testplatform/sessions/ixnetwork/traffic/trafficitem/configelement/frameratedistribution/frameratedistribution.py | 9e82189eba96293027ad24081a8cab44a50a6e6d | [] | no_license | pdobrinskiy/devcore | 0f5b3dfc2f3bf1e44abd716f008a01c443e14f18 | 580c7df6f5db8c118990cf01bc2b986285b9718b | refs/heads/main | 2023-07-29T20:28:49.035475 | 2021-09-14T10:02:16 | 2021-09-14T10:02:16 | 405,919,390 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,774 | py | # MIT LICENSE
#
# Copyright 1997 - 2020 by IXIA Keysight
#
# 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, ... | [
"pdobrinskiy@yahoo.com"
] | pdobrinskiy@yahoo.com |
ab5a2cf7646ee4c873d6f8e1b936ef25d22e2781 | 39f9cdff9eca95b1018d2b869cb08c1b71905ead | /Lesson03/re_lang.py | 994273c73af1c078d431f1a4978dca42dcde6449 | [] | no_license | alexbaryzhikov/design-of-computer-programs | a900ec246a1d174da7fba4f209471aa44dfa7486 | 7b4b212b528a0164cbd283110426bb7e0a0f46ce | refs/heads/master | 2020-03-23T03:57:44.165186 | 2018-07-15T21:06:28 | 2018-07-15T21:06:28 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,107 | py | # Specifications
def test_search():
a, b, c = lit('a'), lit('b'), lit('c')
abcstars = seq(star(a), seq(star(b), star(c)))
dotstar = star(dot)
assert search(lit('def'), 'abcdefg') == 'def'
assert search(seq(lit('def'), eol), 'abcdefg') == None
assert search(a, 'not the start') == 'a'
assert ... | [
"aleksiarts@gmail.com"
] | aleksiarts@gmail.com |
7b31f1cabe8e6e6e069065a085ffe735af6feec8 | 17575d8276d36cf5b32d0b6645fb5dd1b5c0962a | /algorithm/elements/height_balanced.py | 8ea07d761515626c6b9a234ae01c1f9b9e141ba4 | [] | no_license | upul/WhiteBoard | 2f720acc1b1c1e0002f8e0d7842c23707c58debe | e81feb8172add6b893fb4496a590c43f863a0346 | refs/heads/master | 2022-09-26T21:07:25.271461 | 2021-05-13T13:31:27 | 2021-05-13T13:31:27 | 47,049,709 | 8 | 20 | null | 2022-09-23T22:34:42 | 2015-11-29T04:20:21 | Jupyter Notebook | UTF-8 | Python | false | false | 1,267 | py |
from collections import namedtuple
class BinaryTreeNode:
def __init__(self, data=None, left=None, right=None):
self.data = data
self.left = left
self.right = right
def is_balanced_binary_tree(tree):
BalancedStatusWithHeight = namedtuple(
'BalancedStatusWithHeight', ('balanced... | [
"upulbandara@gmail.com"
] | upulbandara@gmail.com |
69422396b91bb1ec63437d92310092788a861501 | 385ed58325dd0cc75bdb9fd3e61c5e005f7a4f28 | /source/hall/src/hall/entity/hall_friend_table.py | c51ba891d473e4cdeb55af31c3bcbe92f12a95d2 | [] | no_license | csirui/hall37 | 17dfa4e4f1f8bf719d0c11ac7738fa4c14fd06db | 5c4eb4b2bf57bbbee4731470c830d8d81915d603 | refs/heads/master | 2021-09-04T03:55:12.460035 | 2018-01-15T15:12:30 | 2018-01-15T15:12:30 | 117,560,615 | 0 | 3 | null | null | null | null | UTF-8 | Python | false | false | 10,494 | py | # -*- coding=utf-8
'''
Created on 2016年9月5日
好友/熟人自建桌模板
负责好友桌的建桌/进入流程
本模块不负责配置,由各个游戏管理自建桌需要的配合
只需要配置符合规范即可
@author: zhaol
'''
import random
import freetime.util.log as ftlog
import poker.util.timestamp as pktimestamp
from hall.entity.hallconf import HALL_GAMEID
from hall.entity.todotask import TodoTaskHelper, \
To... | [
"cg@ibenxi.com"
] | cg@ibenxi.com |
545e9c52abe5d51cda54bc57e2d7a1abfa427f33 | 6db97ab761d59452c05611354637dfb2ce693c96 | /setup.py | 373a4c95fc18def50d4a44b1db4c7823a36f17d9 | [
"MIT"
] | permissive | Mahdi-Soheyli/compas_fab | e885efbdd5531ae5f245bf02b2f1acce0a308680 | 0e7d426903a5d9a1bca947cd7a1251031c4c71b4 | refs/heads/master | 2020-05-02T16:53:13.265526 | 2019-03-20T13:37:37 | 2019-03-20T13:37:37 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,309 | py | #!/usr/bin/env python
# -*- encoding: utf-8 -*-
from __future__ import absolute_import, print_function
import io
import re
from glob import glob
from os.path import abspath, basename, dirname, join, splitext
from setuptools import find_packages, setup
requirements = [
'compas==0.4.10',
'roslibpy>=0.4.0',
... | [
"casas@arch.ethz.ch"
] | casas@arch.ethz.ch |
d80e039f2b571e04b30e70764e043f515fe553ee | f8fe280d9ebd953e8a5f65aa2d81bbfc0472b7fd | /cachalot/tests/write.py | a227f5b55ca01c3380c1ea1c7dc128cba17c4d1e | [] | no_license | androidsx/django-cachalot | c33acfe06c3943c8f4fd30cf32f6fa29d56a377b | 39597a2658d700516ccb238ca8f83f2c94980d30 | refs/heads/master | 2020-12-14T09:48:18.837681 | 2016-08-07T19:32:36 | 2016-08-07T19:32:36 | 65,150,484 | 0 | 0 | null | 2016-08-07T19:30:57 | 2016-08-07T19:30:55 | Python | UTF-8 | Python | false | false | 37,022 | py | # coding: utf-8
from __future__ import unicode_literals
from django.contrib.auth.models import User, Permission, Group
from django.contrib.contenttypes.models import ContentType
from django.core.exceptions import MultipleObjectsReturned
from django.core.management import call_command
from django.db import connection,... | [
"bordage.bertrand@gmail.com"
] | bordage.bertrand@gmail.com |
58f5a3c0db2393623589440672e2123e1cb50dd6 | 7136e5242793b620fa12e9bd15bf4d8aeb0bfe7a | /examples/adspygoogle/dfp/v201103/get_all_companies.py | f8f7073f8e259464c0e996abd799d0c872d58852 | [
"Apache-2.0"
] | permissive | hockeyprincess/google-api-dfp-python | 534519695ffd26341204eedda7a8b50648f12ea9 | efa82a8d85cbdc90f030db9d168790c55bd8b12a | refs/heads/master | 2021-01-10T10:01:09.445419 | 2011-04-14T18:25:38 | 2011-04-14T18:25:38 | 52,676,942 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,729 | py | #!/usr/bin/python
#
# Copyright 2011 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... | [
"api.sgrinberg@7990c6e4-1bfd-11df-85e6-9b4bd7dd5138"
] | api.sgrinberg@7990c6e4-1bfd-11df-85e6-9b4bd7dd5138 |
070406b840ca91f2dc2ea9342d6a45aed96919b4 | abf4bfa1db4b9bacac3ffb7ab6aeee2e85b8667d | /minerva/controllers/system.py | 5562535ac1c0260f71bec732ad9ab09bb101cf6a | [
"MIT"
] | permissive | gitter-badger/minerva-1 | 0fac217c37992329fe83b1e4b366696ccc97a6aa | 9825c5494e83051afcfdec20771b64475fa35c84 | refs/heads/master | 2022-12-13T05:53:01.959423 | 2020-09-09T02:33:18 | 2020-09-09T02:33:18 | 293,982,383 | 1 | 0 | null | 2020-09-09T02:35:10 | 2020-09-09T02:35:10 | null | UTF-8 | Python | false | false | 1,252 | py | # pylint: disable=unidiomatic-typecheck
import json
from d3rlpy.gpu import get_gpu_count
from flask import Blueprint, jsonify
from ..models.experiment import Experiment, ExperimentSchema
from .project import _process_metrics
system_route = Blueprint('system', __name__)
@system_route.route('/status', methods=['GET'... | [
"takuma.seno@gmail.com"
] | takuma.seno@gmail.com |
ce66b322309d1345c6a6b04b0e3be71b501b9bbd | 868ac4e558cf5fe945e8b557564f34f79b3ad01e | /purity_fb/purity_fb_1dot8dot1/apis/arrays_api.py | fa76199d59e1896ea44edf7fa710b2e552b63c86 | [
"Apache-2.0"
] | permissive | mabdelhafez/purity_fb_python_client | f4253ce8497fb3cff648e0a0cd1e567f48129fa7 | a9856875b3df43b4302a2e4addd1a6b71f51f5ce | refs/heads/master | 2022-04-20T09:24:22.031408 | 2020-04-20T22:11:32 | 2020-04-20T22:15:44 | 257,372,596 | 0 | 0 | NOASSERTION | 2020-04-20T18:40:24 | 2020-04-20T18:40:23 | null | UTF-8 | Python | false | false | 33,413 | py | # coding: utf-8
"""
Pure Storage FlashBlade REST 1.8.1 Python SDK
Pure Storage FlashBlade REST 1.8.1 Python SDK, developed by [Pure Storage, Inc](http://www.purestorage.com/). Documentations can be found at [purity-fb.readthedocs.io](http://purity-fb.readthedocs.io/).
OpenAPI spec version: 1.8.1
Cont... | [
"tlewis@purestorage.com"
] | tlewis@purestorage.com |
c796a865d390b4c419a61d3e70f78ed63e05345c | 0d043a8bf4f1dbeaadba8690f028016487ce8f6d | /actor/apps.py | d886f2eb326b367e6b994b7a1a5e76c64581c27a | [] | no_license | neldomarcelino/parque | 74db6d750c74dce81f53f09cab19e5a0ecf862ac | 273ec6ec8a67fb78f8068f212f61e73ca2fd754c | refs/heads/main | 2022-06-20T01:36:09.232552 | 2022-06-09T21:04:08 | 2022-06-09T21:04:08 | 226,638,782 | 0 | 0 | null | 2022-04-22T23:25:01 | 2019-12-08T08:47:20 | Python | UTF-8 | Python | false | false | 90 | py | from django.apps import AppConfig
class ActorConfig(AppConfig):
name = 'actor'
| [
"guerzeneldo@gmail.com"
] | guerzeneldo@gmail.com |
6ebe68c85e467dcf90b2f16afae750ba710e29da | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p02900/s183018985.py | 26a0dfad96b01c45de7664128068ededb63e7367 | [] | 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 | 207 | py | from fractions import gcd
A,B=map(int,input().split())
p=set([1])
g=gcd(A,B)
for d in range(2,g):
while g%d==0:
p.add(d)
g//=d
if (d*d>=g): break
if g>=2:
p.add(g)
print(len(p))
| [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
15fa11d56b13546651fcfbffea19ed57d799c6fe | fb6d4b48f836b002605ffac15a48b6721a3f5508 | /day4/loop5.py | 5531ff28820af3cb650f002476dd5fa2b61287ae | [] | no_license | aravindanath/GlobeMasterAutomation | 72c7fa1854309a67fc988bf1724f36c1270d1e46 | e02fe2361ec965f8429c32d4b814f647e15fe425 | refs/heads/master | 2021-05-19T17:30:53.932495 | 2020-04-01T17:05:40 | 2020-04-01T17:05:40 | 252,048,477 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 74 | py | i = 1
while i < 10:
print(i)
if i == 3:
break
i += 1
| [
"aravindanath86@gmail.com"
] | aravindanath86@gmail.com |
6889e85cc3123edb30ca517b5957ce75bd2bac61 | 95495baeb47fd40b9a7ecb372b79d3847aa7a139 | /swagger_client/models/i_console_user.py | f159b1559b5b8777fa48a6f57cad912d863bbf0f | [] | no_license | pt1988/fmc-api | b1d8ff110e12c13aa94d737f3fae9174578b019c | 075f229585fcf9bd9486600200ff9efea5371912 | refs/heads/main | 2023-01-07T09:22:07.685524 | 2020-10-30T03:21:24 | 2020-10-30T03:21:24 | 308,226,669 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,000 | py | # coding: utf-8
"""
Cisco Firepower Management Center Open API Specification
**Specifies the REST URLs and methods supported in the Cisco Firepower Management Center API. Refer to the version specific [REST API Quick Start Guide](https://www.cisco.com/c/en/us/support/security/defense-center/products-programmi... | [
"pt1988@gmail.com"
] | pt1988@gmail.com |
cf7a9e665afaffe4e6462083af381e40b8547bc4 | bde6ed092b7b29703737e11c5a5ff90934af3d74 | /AtCoder/ABC/001/a.py | 3d32bd925bddb7222fc59c4b5b344e37ab26caf4 | [] | no_license | takecian/ProgrammingStudyLog | 2ab7ea601e0996b3fa502b81ec141bc3772442b6 | 94485d131c0cc9842f1f4799da2d861dbf09b12a | refs/heads/master | 2023-04-28T16:56:18.943574 | 2023-04-18T06:34:58 | 2023-04-18T06:34:58 | 128,525,713 | 4 | 0 | null | 2022-12-09T06:15:19 | 2018-04-07T12:21:29 | Python | UTF-8 | Python | false | false | 105 | py | # https://atcoder.jp/contests/abc001/tasks/abc001_1
H1 = int(input())
H2 = int(input())
print(H1 - H2)
| [
"takecian@gmail.com"
] | takecian@gmail.com |
5a06f3632960fa777547ed5e03bf7d29df9e7fe3 | 6a2bfeaec1998675bb539d4ecd64aba04a4f047e | /manage.py | daa4358e274988b74194f48776764498d254ac50 | [] | no_license | arifbd2221/E-commerce-Django-Tokenized-Restful-Api | 38412b979a3b3f28e537080387e8eaceea363a44 | c54b25da74b1c365c2633eafe98925f97d3abd43 | refs/heads/master | 2020-07-18T10:40:13.558785 | 2019-09-04T04:29:59 | 2019-09-04T04:29:59 | 206,231,082 | 6 | 0 | null | null | null | null | UTF-8 | Python | false | false | 637 | py | #!/usr/bin/env python
"""Django's command-line utility for administrative tasks."""
import os
import sys
def main():
os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'django_react_auth.settings')
try:
from django.core.management import execute_from_command_line
except ImportError as exc:
ra... | [
"mohidulhoque216@gmail.com"
] | mohidulhoque216@gmail.com |
9af971e9e11904e32f099a08e326fd7f04508864 | 06096594942104b976e3c4dc785320517128a1ba | /tests/test_space/test_skopt_space.py | 6f2ee86ff599fdbb5acff81b7c5f3aa54b1d09ea | [
"MIT"
] | permissive | shaoeric/hyperparameter_hunter | 082fc556fb313235c747ac08b2ba5a9a1907bb40 | 3709d5e97dd23efa0df1b79982ae029789e1af57 | refs/heads/master | 2021-04-08T05:13:42.653573 | 2020-03-21T01:22:12 | 2020-03-21T01:22:12 | 248,743,697 | 0 | 0 | MIT | 2020-03-20T11:55:29 | 2020-03-20T11:55:28 | null | UTF-8 | Python | false | false | 21,450 | py | """Tests the tools defined by :mod:`hyperparameter_hunter.space.dimensions` and
:mod:`hyperparameter_hunter.space.space_core`
Notes
-----
Many of the tests defined herein (although substantially modified) are based on those provided by
the excellent [Scikit-Optimize](https://github.com/scikit-optimize/scikit-optimize)... | [
"hunter@mcgushion.com"
] | hunter@mcgushion.com |
461981baa6d5e7e3e901b71df7640e0723b32d40 | 719853613b5b96f02072be1fde736d883e799f02 | /server/accounts/urls.py | 106d5275a4cf4eb733a549e205bf7f2113d2753e | [
"MIT"
] | permissive | anmolkabra/opensurfaces | 5ba442123586533a93eb29890fa1694e3efdbfe8 | a42420083a777d7e1906506cc218f681c5cd145b | refs/heads/master | 2020-03-20T01:11:05.182880 | 2018-06-13T14:55:45 | 2018-06-13T14:55:45 | 137,068,945 | 0 | 0 | MIT | 2018-06-12T12:32:53 | 2018-06-12T12:32:52 | null | UTF-8 | Python | false | false | 178 | py | from django.conf.urls import patterns, url
from accounts.views import admin_shell
urlpatterns = patterns(
'',
url(r'^admin-shell/$', admin_shell, name='admin-shell'),
)
| [
"sbell@cs.cornell.edu"
] | sbell@cs.cornell.edu |
c7cfcaf109b00f593c5d0e7c165d89cac1516f38 | b289a2c1b42e17a2338c5414b6831f9cd44cb2dd | /valarie/executor/system.py | 496768e72ee769b6de032fc723323797ee8f093f | [
"MIT"
] | permissive | phnomcobra/valarie | fa2d3136092c80aeaca5474afe0ce726e36ade25 | 83bedeb50be5ab385c0851bf53044ee583e1adfd | refs/heads/master | 2022-10-27T21:38:23.669304 | 2022-10-20T12:44:03 | 2022-10-20T12:44:03 | 163,562,318 | 0 | 0 | MIT | 2022-10-09T03:30:39 | 2018-12-30T04:49:11 | JavaScript | UTF-8 | Python | false | false | 898 | py | #!/usr/bin/python3
"""This module implements system for the executor module."""
from subprocess import Popen, PIPE
from valarie.controller import logging
def system(command: str) -> int:
"""This function executes a command on the system.
Standard out and standard error emit into the logger.
Args:
... | [
"phnomcobra@gmail.com"
] | phnomcobra@gmail.com |
c91dfca5f72120badcf9148ba66d5d8015240b3d | 056863ff17af7121b0348db31bf28836ff584e4a | /53.py | 157faab99a5c9c28d7742036e8fdb561f6a72687 | [] | no_license | saranya258/python | 1face016cdd52c55df6fd6493f5f2aa5bcae9212 | df2274ad72bd36b7eb8cf4a4d2360e40dc902ee0 | refs/heads/master | 2020-06-07T14:19:32.476586 | 2019-07-10T08:53:32 | 2019-07-10T08:53:32 | 193,040,334 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 77 | py | r=int(input())
m=0
i=0
while(r>0):
i=r%10
m=m+i
r=r//10
print(m)
| [
"noreply@github.com"
] | saranya258.noreply@github.com |
15c9115c35dcba355e97459f453a66e4f5821cd0 | cc9cf69b1534dc0d9530b4ff485084162a404e34 | /leetcode/without/leetcode_70.py | 1f25e342333eabed2950b304d24f79fb7ef1c40e | [] | no_license | NASA2333/study | 99a58b2c9979201e9a4fae0c797391a538de6f45 | ba63bc18f3c788090e43406315497329b00ec0a5 | refs/heads/master | 2021-05-03T22:26:52.541760 | 2018-02-07T02:24:55 | 2018-02-07T02:24:55 | 104,988,265 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 923 | py | '''
You are climbing a stair case. It takes n steps to reach to the top.
Each time you can either climb 1 or 2 steps. In how many distinct ways can you climb to the top?
Note: Given n will be a positive integer.
Example 1:
Input: 2
Output: 2
Explanation: There are two ways to climb to the top.
1. 1 step + 1 step
2. 2... | [
"422282539@qq.com"
] | 422282539@qq.com |
430b5945a07208c04556532b109363bdb908ea52 | 25b914aecd6b0cb49294fdc4f2efcfdf5803cc36 | /homeassistant/components/balboa/binary_sensor.py | b73872b664710068013ef6e8b5b0aeb2da9c9692 | [
"Apache-2.0"
] | permissive | jason0x43/home-assistant | 9114decaa8f7c2f1582f84e79dc06736b402b008 | 8bf6aba1cf44ee841de063755c935ea78040f399 | refs/heads/dev | 2023-03-04T01:14:10.257593 | 2022-01-01T12:11:56 | 2022-01-01T12:11:56 | 230,622,861 | 1 | 1 | Apache-2.0 | 2023-02-22T06:15:07 | 2019-12-28T14:45:43 | Python | UTF-8 | Python | false | false | 1,768 | py | """Support for Balboa Spa binary sensors."""
from homeassistant.components.binary_sensor import (
BinarySensorDeviceClass,
BinarySensorEntity,
)
from .const import CIRC_PUMP, DOMAIN, FILTER
from .entity import BalboaEntity
FILTER_STATES = [
[False, False], # self.FILTER_OFF
[True, False], # self.FIL... | [
"noreply@github.com"
] | jason0x43.noreply@github.com |
cea2ec05a0670b294d79a17e8de73449644a3eb6 | 48e124e97cc776feb0ad6d17b9ef1dfa24e2e474 | /sdk/python/pulumi_azure_native/authorization/v20190901/get_policy_definition_at_management_group.py | 287a80a7cda013c3317067e3b4fba4c14062bbe9 | [
"BSD-3-Clause",
"Apache-2.0"
] | permissive | bpkgoud/pulumi-azure-native | 0817502630062efbc35134410c4a784b61a4736d | a3215fe1b87fba69294f248017b1591767c2b96c | refs/heads/master | 2023-08-29T22:39:49.984212 | 2021-11-15T12:43:41 | 2021-11-15T12:43:41 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,524 | 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
fro... | [
"noreply@github.com"
] | bpkgoud.noreply@github.com |
d140cf5c10646c09460c5fb577904cce75daf311 | cf3e9398e4a1a8b41aa12e3ef42aa2a73bff2507 | /src/compiler/frontend_test.py | bf75f5b52ccb47538806e8ac975c5e988e14b86b | [
"Apache-2.0",
"MIT"
] | permissive | fritzo/pomagma | fb207e8bfd77c7ac592ddb27d5fd3213da50a532 | ad2bf9c12eb58190f2761608c053ac89d3ddf305 | refs/heads/master | 2023-02-24T16:54:31.981623 | 2023-02-10T23:17:42 | 2023-02-10T23:17:42 | 4,943,857 | 12 | 0 | NOASSERTION | 2023-02-10T23:17:43 | 2012-07-08T05:22:16 | C++ | UTF-8 | Python | false | false | 465 | py | import pomagma.util
from pomagma.compiler import __main__ as main
from pomagma.compiler.util import find_theories
from pomagma.util.testing import for_each
@for_each(find_theories())
def test_compile(filename):
with pomagma.util.in_temp_dir():
main.compile(
filename,
symbols_out='t... | [
"fritz.obermeyer@gmail.com"
] | fritz.obermeyer@gmail.com |
e03fbd20f95a8dd0e7069256533d364d13b34279 | 35f9def6e6d327d3a4a4f2959024eab96f199f09 | /developer/lab/tools/NVIDIA/FasterTransformer/sample/PyTorch/utils/gpt.py | dd5efbb375c41e6f402ef254744b89e62b291c41 | [
"Apache-2.0",
"CAL-1.0-Combined-Work-Exception",
"CAL-1.0",
"MIT",
"CC-BY-SA-4.0",
"LicenseRef-scancode-free-unknown"
] | permissive | arXiv-research/DevLab-III-1 | ec10aef27e1ca75f206fea11014da8784752e454 | c50cd2b9154c83c3db5e4a11b9e8874f7fb8afa2 | refs/heads/main | 2023-04-16T19:24:58.758519 | 2021-04-28T20:21:23 | 2021-04-28T20:21:23 | 362,599,929 | 2 | 0 | MIT | 2021-04-28T20:36:11 | 2021-04-28T20:36:11 | null | UTF-8 | Python | false | false | 12,159 | py | # Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by appli... | [
"noreply@github.com"
] | arXiv-research.noreply@github.com |
f44507616b1b518b8c703ba0fcb821c34c829762 | f9ff9ffc9d5e48b63c137382e1d3299a518215ec | /microbenchmarks/simple_rcnn/graph_rewrites_LP.py | 1678cb7a1ba243db64bb23867ba9f7518894425a | [] | no_license | mkuchnik/PlumberApp | 240b760cf0250a68253153950bf9a85014c35499 | 6123f5bce36eec7dc75b6b9298054b493d930bdc | refs/heads/main | 2023-04-16T08:32:54.829454 | 2022-03-13T04:08:37 | 2022-03-13T04:08:37 | 459,011,430 | 12 | 0 | null | null | null | null | UTF-8 | Python | false | false | 49,559 | py | from absl import app
from absl import flags
import shutil
import pprint
import tensorflow as tf
import tensorflow.compat.v1 as tf1
import graphsurgeon
import gen_util
import pandas as pd
try:
import dataloader
except ImportError:
try:
import resnet_flags
except ImportError:
import dataset... | [
"michaelkuchnik@gmail.com"
] | michaelkuchnik@gmail.com |
44564d43c1934ab6625863de0fc90ab17d11dada | 9afbcb367de9bf055d531d285bc299a9ca3040fe | /next_partial.py | 6290584281b1e87c10e787a4fd4eb350d01744a1 | [] | no_license | mysqlplus163/aboutPython | a41a5bc2efd43b53d4acf96e7477e80c022cf657 | fa7c3e6f123158011d8726b28bfcd0dee02fa853 | refs/heads/master | 2020-03-21T05:06:19.949902 | 2018-03-14T16:04:54 | 2018-03-14T16:04:54 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 653 | py | #! /usr/bin/env python
# -*- coding: utf-8 -*-
# __author__ = "Q1mi"
# Email: master@liwenzhou.com
"""
Python Web编程实战(小绿书)里面学到的知识点
"""
# 1.使用next获取循环中符合条件的值
a1 = -1
for i in range(1, 10):
if not i % 4:
a1 = i
break
print(a1)
a2 = next((i for i in range(1, 10) if not i % 4), -1)
print(a2)
# 2.执行... | [
"liwenzhou7@gmail.com"
] | liwenzhou7@gmail.com |
bf4ed8e20cfbcef2a691f202e56011fc09f79742 | 444a9480bce2035565332d4d4654244c0b5cd47b | /research/nlp/mass/src/transformer/self_attention.py | 5a21c5aaf31b296c7e83ef88ba3d0b095f8fca39 | [
"Apache-2.0",
"LicenseRef-scancode-unknown-license-reference",
"LicenseRef-scancode-proprietary-license"
] | permissive | mindspore-ai/models | 7ede9c6454e77e995e674628204e1c6e76bd7b27 | eab643f51336dbf7d711f02d27e6516e5affee59 | refs/heads/master | 2023-07-20T01:49:34.614616 | 2023-07-17T11:43:18 | 2023-07-17T11:43:18 | 417,393,380 | 301 | 92 | Apache-2.0 | 2023-05-17T11:22:28 | 2021-10-15T06:38:37 | Python | UTF-8 | Python | false | false | 3,168 | py | # Copyright 2020 Huawei Technologies Co., Ltd
#
# 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... | [
"chenhaozhe1@huawei.com"
] | chenhaozhe1@huawei.com |
4b92a27efd3b3a79589583a27bfec2e8f52dbb20 | 888e79392cb660be5799cc5bd25d76bcfa9e2e2c | /doctorus/doctorus/doctype/estados_de_evaluacion/estados_de_evaluacion.py | 3ce28a77294e67d9b00cbd7cdc44cba53e700881 | [
"MIT"
] | permissive | Nirchains/doctorus | 269eadee5754612c521d1c6193d5fe7bbfdb3b8a | 38d39270742dfdae6597a06713952df01a2c3e9d | refs/heads/master | 2020-03-17T07:09:30.046005 | 2019-05-08T06:51:50 | 2019-05-08T06:51:50 | 133,386,354 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 272 | py | # -*- coding: utf-8 -*-
# Copyright (c) 2019, HISPALIS DIGITAL and contributors
# For license information, please see license.txt
from __future__ import unicode_literals
import frappe
from frappe.model.document import Document
class EstadosdeEvaluacion(Document):
pass
| [
"nirchains@gmail.com"
] | nirchains@gmail.com |
7443f4fff300825d8d672d4aa3125b64f6155161 | 5254c3a7e94666264120f26c87734ad053c54541 | /Entregas/Entrega Semana N°7/vida.py | e9cdc579900b67a214dad9a18b6c5ae8437809ea | [] | no_license | ccollado7/UNSAM---Python | 425eb29a2df8777e9f892b08cc250bce9b2b0b8c | f2d0e7b3f64efa8d03f9aa4707c90e992683672d | refs/heads/master | 2023-03-21T17:42:27.210599 | 2021-03-09T13:06:45 | 2021-03-09T13:06:45 | 286,613,172 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 954 | py | # -*- coding: utf-8 -*-
"""
Created on Mon Sep 28 14:23:33 2020
@author: Claudio Collado
"""
#Ejercicio 7.1
from datetime import datetime
def segundos_nacimiento(fecha):
''''Funcion que recibe una fecha del tipó dd/mm/AAAA'
(día, mes, año con 2, 2 y 4 dígitos, separados con barras normales)
y... | [
"46108725+ccollado7@users.noreply.github.com"
] | 46108725+ccollado7@users.noreply.github.com |
f72f1f8975ef40e6fe9352bd48103f7ec16d903e | 12362aa3c315e2b72ed29193ee24e3fd7f1a57db | /LeetCode/0232-Implement Queue using Stacks/main.py | 2261e5e4e7a767227fb8f251fe8dd92dd750aff4 | [] | no_license | PRKKILLER/Algorithm_Practice | f2f4662352516965777605ccf116dd7945c4b94a | 73654b6567fdb282af84a868608929be234075c5 | refs/heads/master | 2023-07-03T23:24:15.081892 | 2021-08-09T03:55:12 | 2021-08-09T03:55:12 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,302 | py | """
Implement the following operations of a queue using stacks.
push(x) -- Push element x to the back of queue.
pop() -- Removes the element from in front of queue.
peek() -- Get the front element.
empty() -- Return whether the queue is empty.
Example:
MyQueue queue = new MyQueue();
queue.push(1);
queue.push(2); ... | [
"dw6000@163.com"
] | dw6000@163.com |
8bf3648d4e9800f14bf2caa630487f844621f7e0 | ec21d4397a1939ac140c22eca12491c258ed6a92 | /instances/sapl23/Products/ILSAPL/skins/sk_sapl/pysc/.svn/text-base/votacao_restaurar_situacao_inicial_pysc.py.svn-base | 3bea46fc54a0e53dd862c413918976db43459968 | [] | no_license | wpjunior/proled | dc9120eaa6067821c983b67836026602bbb3a211 | 1c81471295a831b0970085c44e66172a63c3a2b0 | refs/heads/master | 2016-08-08T11:59:09.748402 | 2012-04-17T07:37:43 | 2012-04-17T07:37:43 | 3,573,786 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 394 | ## Script (Python) "votacao_restaurar_situacao_inicial_pysc"
##bind container=container
##bind context=context
##bind namespace=
##bind script=script
##bind subpath=traverse_subpath
##parameters=cod_materia
##title=
##
try:
context.zsql.votacao_restaurar_parlamentar_zsql(cod_materia=cod_materia)
context.zsql.v... | [
"root@cpro5106.publiccloud.com.br"
] | root@cpro5106.publiccloud.com.br | |
80cef7f808746a77dbe20e6a66357fe24b83d06b | 6819a924ee1cff66f508e85e26f826c1f0b08267 | /feeds.py | bc0b5e9d1d4101041835ec6fa1683aea521cf0da | [
"MIT"
] | permissive | joskid/snippify | 94245539a96a0327b8f431c51598673ef951d2ba | b692a941a7a46959df9aff064b7ad056d0125484 | refs/heads/master | 2021-01-18T05:25:51.818175 | 2011-06-16T20:13:05 | 2011-06-16T20:13:17 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,079 | py | """ For now there are """
from django.contrib.syndication.feeds import Feed, FeedDoesNotExist
from django.core.exceptions import ObjectDoesNotExist
from django.contrib.auth.models import User
from taggit.models import Tag
from snippets.models import Snippet
class LatestSnippets(Feed):
""" Get latest global snipp... | [
"alexandru.plugaru@gmail.com"
] | alexandru.plugaru@gmail.com |
4197891e02e3bd1e8943643b9c545370a44a5c14 | 73e7f93353ff6fa706ec644ac24d87de970b7115 | /src/keyboard_handler/__init__.py | 74f3084f3ed6eb49189a7a608a115df20629d888 | [
"MIT"
] | permissive | wafiqtaher/TheQube | 59c873bf7554088a8d436b58c2f0b6e72e6660d9 | fcfd8a68b15948e0740642d635db24adef8cc314 | refs/heads/master | 2022-04-07T10:52:50.469554 | 2020-01-27T14:07:33 | 2020-01-27T14:07:33 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 181 | py | # -*- coding: utf-8 -*-
from main import KeyboardHandler, KeyboardHandlerError
__all__ = ["KeyboardHandler", "KeyboardHandlerError", "WXKeyboardHandler", "WXPanelKeyboardHandler"]
| [
"andre@oire.org"
] | andre@oire.org |
07ddf970dc79e9698f5e51a218ff3857d2095bd4 | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p03186/s117979946.py | 86c1d20329340bc1f926ab78103e45762038a3ec | [] | 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 | 113 | py | a,b,c=map(int,input().split())
if c<=b:
print(c+b)
else:
if c-b<=a:
print(c+b)
else:
print(a+b+b+1) | [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
4f3ccf728dfe75aae7e2984b5f59f776001750f0 | 53fab060fa262e5d5026e0807d93c75fb81e67b9 | /backup/user_372/ch22_2020_03_31_23_32_56_982191.py | ce25e75a074e8b3a8f3aa789366088cc04c78302 | [] | 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 | 133 | py | cigarros = int(input('Quantos cigarros você fuma por dia? ')
anos = int(input('Há quantos anos você fuma? ')
a=(365*cigarros)*anos | [
"you@example.com"
] | you@example.com |
90143fc733d7a98aaff3c395f14752f60520d6cf | f576f0ea3725d54bd2551883901b25b863fe6688 | /sdk/authorization/azure-mgmt-authorization/azure/mgmt/authorization/v2021_07_01_preview/aio/operations/_access_review_instances_assigned_for_my_approval_operations.py | 84b325b2e4ec07044f743f0ce2f9663982f87889 | [
"MIT",
"LicenseRef-scancode-generic-cla",
"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 | 9,720 | py | # pylint: disable=too-many-lines
# 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) AutoRe... | [
"noreply@github.com"
] | Azure.noreply@github.com |
b02c815984671705a915af7da9c06659b7232120 | 48d232cc6dcf57abf6fca9cbbef8943e189acb04 | /cake-thief.py | 4544306cd668b4d93270e1585e8aca5e3bb9d888 | [] | no_license | csusb-005411285/CodeBreakersCode | dae796ba4262770e0a568e9c27597a041db0775c | 8f218164e1b9e42c1a928d22ef5a76328abb66a2 | refs/heads/master | 2022-01-12T09:11:33.668338 | 2021-12-27T04:45:13 | 2021-12-27T04:45:13 | 232,490,141 | 1 | 1 | null | 2021-01-29T23:09:14 | 2020-01-08T06:02:11 | Python | UTF-8 | Python | false | false | 789 | py | def max_duffel_bag_value(cake_tuples, weight_capacity):
if weight_capacity == 0:
return 0
cache = {}
for i in range(weight_capacity + 1):
cache[i] = 0
for weight in range(weight_capacity + 1): # 4
max_value_at_weight = 0
for cake in cake_tuples: # (2, 1)
m... | [
"noreply@github.com"
] | csusb-005411285.noreply@github.com |
1d90f7404d9cf3abc78760441a556f49047fbccc | b0eddf070767a08ea41a474eb424c51b81b856a9 | /week-5/monday/character.py | e7a02b28a926a8b461f86f3774307c3cced10f91 | [] | no_license | green-fox-academy/florimaros | fdd645c8ed6620e2b5021a2feca056049438a951 | 39741ea40e18441877c61a7fdf20b832cccf247a | refs/heads/master | 2021-05-30T14:35:57.456067 | 2016-02-25T19:53:44 | 2016-02-25T19:53:44 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 421 | py | class Character():
def __init__(self, name, hp, damage):
self.name = name
self.hp = hp
self.damage = damage
def drink_potion(self):
self.hp += 10
def strike(self, opponent):
opponent.hp -= self.damage
def get_status(self):
life_status = "dead"
if... | [
"flori.maros.adw@gmail.com"
] | flori.maros.adw@gmail.com |
55366f7b56526ec007a05e15bef779b09f10e3bd | c175c4e3560c6c66ec2b0c4b439cd586878b44a5 | /prplatform/submissions/migrations/0016_answer_uploaded_file.py | aede969729e418c53d85a3ea901af39719f4650a | [
"MIT"
] | permissive | piehei/prplatform | fd30e2e388597583b9ef0e59462ea9643f7244ba | f3248b66019f207bb06a4681a62057e175408b3e | refs/heads/master | 2020-03-09T17:09:47.893706 | 2019-09-18T15:24:58 | 2019-09-18T15:24:58 | 128,902,940 | 3 | 0 | null | null | null | null | UTF-8 | Python | false | false | 487 | py | # Generated by Django 2.1.2 on 2018-11-13 13:12
from django.db import migrations, models
import prplatform.submissions.models
class Migration(migrations.Migration):
dependencies = [
('submissions', '0015_auto_20181109_1251'),
]
operations = [
migrations.AddField(
model_name=... | [
"ph@extreg.com"
] | ph@extreg.com |
966ea3d3546ffdf38dbbf81b30f804d781107f46 | 16076240644897ad0529a4cb7543e19dd5fc539a | /etl.py | ebf228080aabfd1519962b4734fac2b7a61292a0 | [] | no_license | MZ195/DEND-Data-Warehouse_AWS | a2eef32a6d372cd556868549c9422316dfeb2be0 | 47f96f91444a15e81386a9a4698dd5263fdb9f6e | refs/heads/master | 2022-10-14T18:12:34.309750 | 2020-06-10T09:33:30 | 2020-06-10T09:33:30 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,415 | py | import configparser
import psycopg2
from logging import getLogger
from sql_queries import copy_table_queries, insert_table_queries
log = getLogger(__name__)
def load_staging_tables(cur, conn):
"""Loading the data from S3 buckets into the staging tables of Redshift
Keyword arguments:
cur -- the curser of... | [
"40984264+MZ195@users.noreply.github.com"
] | 40984264+MZ195@users.noreply.github.com |
7387fc2c2fcc75e354b688ee8bb357bc9a6e723c | 4c0328c7fa7805cdd196cf890695ec1a8a438a5f | /devel/lib/python2.7/dist-packages/pal_navigation_msgs/msg/_JoyTurboActionFeedback.py | cc6cd8e2ac73cf99bf0acb00754793a923898078 | [] | no_license | SebsBarbas/iRob_KTH | d98dfce8692bdd4d32ce3a4d72daa8d022976c0a | c164c9d12efcab56b4871fc5bb5538df5849a42e | refs/heads/main | 2023-01-23T10:49:59.073113 | 2020-12-04T18:49:53 | 2020-12-04T18:49:53 | 318,595,723 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 12,040 | py | # This Python file uses the following encoding: utf-8
"""autogenerated by genpy from pal_navigation_msgs/JoyTurboActionFeedback.msg. Do not edit."""
import sys
python3 = True if sys.hexversion > 0x03000000 else False
import genpy
import struct
import pal_navigation_msgs.msg
import genpy
import actionlib_msgs.msg
impor... | [
"ssbl@kth.se"
] | ssbl@kth.se |
be99e2028248897425d63985f3a164926c163f06 | d41d18d3ea6edd2ec478b500386375a8693f1392 | /plotly/validators/scatterpolargl/__init__.py | ca20fdc223e891433052b3060c7dc3fe90e4a0e9 | [
"MIT"
] | permissive | miladrux/plotly.py | 38921dd6618650d03be9891d6078e771ffccc99a | dbb79e43e2cc6c5762251537d24bad1dab930fff | refs/heads/master | 2020-03-27T01:46:57.497871 | 2018-08-20T22:37:38 | 2018-08-20T22:37:38 | 145,742,203 | 1 | 0 | MIT | 2018-08-22T17:37:07 | 2018-08-22T17:37:07 | null | UTF-8 | Python | false | false | 1,266 | py | from ._visible import VisibleValidator
from ._unselected import UnselectedValidator
from ._uid import UidValidator
from ._thetaunit import ThetaunitValidator
from ._thetasrc import ThetasrcValidator
from ._theta import ThetaValidator
from ._textsrc import TextsrcValidator
from ._text import TextValidator
from ._subplot... | [
"adam.kulidjian@gmail.com"
] | adam.kulidjian@gmail.com |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.