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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
f41dca961cef3607897a66f7c776045d1445a669 | 234a4d04918792ff29a4de07555c48c1d82ba750 | /app/io/model.py | 4890b6a3b0c2cba87e1f2078a71a9604499be820 | [] | no_license | fodisi/mytwitter | dce1ca4cefd19f57cd829df4aadeaf72aaeb407a | f04101fd6a6c3fa96653960383626d7f1dc43d5e | refs/heads/master | 2020-03-23T16:40:28.016221 | 2018-07-23T18:35:42 | 2018-07-23T18:35:42 | 141,626,592 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,982 | py | #!/usr/bin/env python3
import uuid
import os
from .. import app
from werkzeug.utils import secure_filename
class FileManager():
ALLOWED_EXTENSIONS = set(['png', 'jpg', 'jpeg', 'gif'])
@staticmethod
def allowed_file(file_extension: str) -> bool:
return '.' in file_extension and \
fil... | [
"fodisi@users.noreply.github.com"
] | fodisi@users.noreply.github.com |
094346c7004d3bd374407f8c1186a0434d04d2e7 | 2948e8f6c464503da56a84dc5efb81769b564b78 | /bench_oneargs.py | 104d50560c45448f222982a4fb67d0fca47fbb4e | [] | no_license | mattip/cpyext-benchmarks | 8e21c8a40dcaf6cb65b8c43ac55cde36be9678a9 | cff9ee10a6fba1c66d74ebfdd69a6f3659bfba51 | refs/heads/master | 2020-05-15T23:55:50.839629 | 2018-03-24T09:34:26 | 2018-03-24T09:34:26 | 182,565,141 | 0 | 0 | null | 2019-04-21T17:53:23 | 2019-04-21T17:53:23 | null | UTF-8 | Python | false | false | 1,188 | py | import time
import simple
N = 10000000
X=100
def main():
a = time.time()
for i in xrange(N):
simple.onearg(None)
b = time.time()
print 'onearg(None): %.2f secs' % (b-a)
#
a = time.time()
for i in xrange(N):
simple.onearg(1)
b = time.time()
print 'onearg(1) : %.2f ... | [
"anto.cuni@gmail.com"
] | anto.cuni@gmail.com |
6752d2722d3bda62fba752b2b605cdcb9d1856a3 | 242086b8c6a39cbc7af3bd7f2fd9b78a66567024 | /python/PP4E-Examples-1.4/Examples/PP4E/Internet/Ftp/Mirror/cleanall.py | 2037c4926015a796439e38ec765f5bcd5f6d54d0 | [] | no_license | chuzui/algorithm | 7537d0aa051ac4cbe9f6a7ca9a3037204803a650 | c3006b24c4896c1242d3ceab43ace995c94f10c8 | refs/heads/master | 2021-01-10T13:05:30.902020 | 2015-09-27T14:39:02 | 2015-09-27T14:39:02 | 8,404,397 | 4 | 4 | null | null | null | null | UTF-8 | Python | false | false | 2,452 | py | #!/usr/bin/env python
"""
##############################################################################
extend the FtpTools class to delete files and subdirectories from a remote
directory tree; supports nested directories too; depends on the dir()
command output format, which may vary on some servers! - see Python's... | [
"zui"
] | zui |
2ef6230fc10093e5c9cd5f11c8018a8f323e0e69 | 97a2252c7df346b101fd5ee47a803804a08c0b9d | /eul129.py | cf972199e7aca7951bdc96f67fce63d1f787910e | [] | no_license | CosmicTomato/ProjectEuler | 6c4fbb4b9b40a2051bbe971ccd7dc76a7142aabe | 17fa511dd7e091b71398caeca72e30b4cd1e6d66 | refs/heads/master | 2020-04-08T19:10:47.502890 | 2019-08-21T23:29:36 | 2019-08-21T23:29:36 | 159,643,675 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 795 | py | #Prime square remainders
#Let pn be the nth prime: 2, 3, 5, 7, 11, ..., and let r be the remainder when (pn−1)^n + (pn+1)^n is divided by pn^2.
#For example, when n = 3, p3 = 5, and 4^3 + 6^3 = 280 ≡ 5 mod 25.
#The least value of n for which the remainder first exceeds 10^9 is 7037.
#Find the least value of n for w... | [
"noreply@github.com"
] | CosmicTomato.noreply@github.com |
65f11db104e4d4e2262d179e81a7e2484fd8ae7e | 7a4099cea66cbc29558ae261c59e154e2956bad3 | /communities/tools.py | 6c1c0a816d0737bb2be3f8d34f31c11ca42b8831 | [
"MIT"
] | permissive | genonfire/workcloud | 96f29ca3d3a05985aa6868295368b21c093dcd3e | 9547990a16b4ed45eabe5e6522f1ec5649caaf31 | refs/heads/master | 2023-08-29T02:51:34.322512 | 2023-08-28T03:48:10 | 2023-08-28T03:48:10 | 214,943,754 | 5 | 2 | MIT | 2023-08-10T09:18:42 | 2019-10-14T03:55:20 | Python | UTF-8 | Python | false | false | 2,108 | py | from django.utils import timezone
from core.permissions import (
AllowAny,
DenyAll,
IsAdminUser,
IsApproved,
)
from utils.constants import Const
from utils.debug import Debug # noqa
def destroy_forum(instance):
instance.option.delete()
instance.delete()
def delete_thread(instance):
ins... | [
"gencode.me@gmail.com"
] | gencode.me@gmail.com |
db21fd48373be3727415fa726b2a75ae47c9e614 | 13fa473a27eaa24e26138d4c0ab2c1487750759f | /club/club/doctype/trainings/trainings.py | c302b123d1a537e37e79e7b38c85030d1534a111 | [
"MIT"
] | permissive | joelios/Club | 45947f1112e18713e5cb6c6ed79b315bc62a232f | 61c3d8c476bae3a39698d601a481010a9b65bdb5 | refs/heads/master | 2020-03-15T00:23:55.684506 | 2018-05-04T10:24:31 | 2018-05-04T10:24:31 | 131,867,378 | 3 | 2 | null | null | null | null | UTF-8 | Python | false | false | 260 | py | # -*- coding: utf-8 -*-
# Copyright (c) 2018, libracore GmbH and contributors
# For license information, please see license.txt
from __future__ import unicode_literals
import frappe
from frappe.model.document import Document
class Trainings(Document):
pass
| [
"root@debian"
] | root@debian |
463a519ad7eeba518c706aa5032f89b830b82c91 | 6370e9393bfcd4a00a35bc8700d44569959cfe2c | /json2model/services/dynamic_model/dynamic_data_instances.py | 6b742f2d50b33f39b52a36202d3c010cec2cddd6 | [
"MIT"
] | permissive | Grusinator/django-json2model | d2ec63ce718422442bd3c8cd14a7f8d7d78c919f | fe06f4feb60b8a02859530556f91ca6a5978d6d1 | refs/heads/master | 2021-07-01T13:47:27.290210 | 2021-02-27T07:12:00 | 2021-02-27T07:12:00 | 224,200,623 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,034 | py | import logging
from abc import ABC
from django.conf import settings
from django.db.models.base import Model
from json2model.services import data_type_transform
from json2model.services.dynamic_model import dynamic_model_utils as dm_utils
from json2model.services.dynamic_model.i_json_iterator import IJsonIterator
log... | [
"grusinator@gmail.com"
] | grusinator@gmail.com |
8e1548e996f196e37d9f7be722f725555f3f5581 | b2ebe56c54072d1c7dd357aadbc152eca0c47a7c | /woche09/decorator_demo.py | 0da259e52d24b5add6bdc16c3ba9a18b25367dc7 | [] | no_license | tthelen/webtech16-public | 738914104a6d93c065d0f9a35288ffb6fb60b3b9 | 0ba91f4d8e8f036f0d47baa3bd761f9394347e60 | refs/heads/master | 2021-01-12T17:23:34.104049 | 2017-01-24T07:43:34 | 2017-01-24T07:43:34 | 71,556,763 | 7 | 3 | null | null | null | null | UTF-8 | Python | false | false | 583 | py |
def enterexit(f):
def wrap():
print("Enter '{}'".format(f.__name__))
f()
print("Exit '{}'".format(f.__name__))
return wrap
def log(enter, exit):
def enterexit(f):
def wrap():
if enter:
print("Enter '{}'".format(f.__name__))
f()
... | [
"tt@tobiasthelen.de"
] | tt@tobiasthelen.de |
5cee4711e911eee5600402146f2c5b9e989ae3f7 | e415e4cdab3d1cd04a4aa587f7ddc59e71977972 | /cookbook/1.Data Structures and Algorithms/1.11.Naming a Slice.py | 74f3ee25cef2d5aaf777c398ea06754a447f09d0 | [] | no_license | nixawk/hello-python3 | 8c3ebba577b39f545d4a67f3da9b8bb6122d12ea | e0680eb49d260c5e3f06f9690c558f95a851f87c | refs/heads/master | 2022-03-31T23:02:30.225702 | 2019-12-02T10:15:55 | 2019-12-02T10:15:55 | 84,066,942 | 5 | 7 | null | null | null | null | UTF-8 | Python | false | false | 1,606 | py | #!/usr/bin/python3
# -*- coding: utf-8 -*-
# Problem
# Your program has become an unreadable mess of hardcoded slice indices
# and you want to clean it up.
# Solution
# Suppose you have some code that is pulling specific data fields out of
# a record string with fixed fields.
###### 0123456789012345678901234567890... | [
"hap.ddup@gmail.com"
] | hap.ddup@gmail.com |
570e71661a0224a3effd5d478e13b016aa4b9927 | 33f32d78087491e989289c46e5d2df5400e23946 | /leetcode/Unsorted_Algorthm_Problems/Logger_Rate_Limiter.py | a1f34dc8fb6c3755a804b1330e4fbcf27d360060 | [] | no_license | xulleon/algorithm | 1b421989423640a44339e6edb21c054b6eb47a30 | b1f93854006a9b1e1afa4aadf80006551d492f8a | refs/heads/master | 2022-10-08T19:54:18.123628 | 2022-09-29T05:05:23 | 2022-09-29T05:05:23 | 146,042,161 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 697 | py | # https://leetcode.com/problems/logger-rate-limiter/
class Logger:
def __init__(self):
"""
Initialize your data structure here.
"""
self.logger = {}
def shouldPrintMessage(self, timestamp: int, message: str) -> bool:
"""
Returns true if the message should be p... | [
"leonxu@yahoo.com"
] | leonxu@yahoo.com |
129ce89af671d95d66da303320ba5764ff6537a4 | df7f13ec34591fe1ce2d9aeebd5fd183e012711a | /hata/discord/onboarding/onboarding_prompt_option/tests/test__validate_description.py | fd8399f7ec09870d0bcbea998f23225c382ddf17 | [
"LicenseRef-scancode-warranty-disclaimer"
] | permissive | HuyaneMatsu/hata | 63e2f6a2d7a7539fd8f18498852d9d3fe5c41d2e | 53f24fdb38459dc5a4fd04f11bdbfee8295b76a4 | refs/heads/master | 2023-08-20T15:58:09.343044 | 2023-08-20T13:09:03 | 2023-08-20T13:09:03 | 163,677,173 | 3 | 3 | Apache-2.0 | 2019-12-18T03:46:12 | 2018-12-31T14:59:47 | Python | UTF-8 | Python | false | false | 698 | py | import vampytest
from ..fields import validate_description
def test__validate_description__0():
"""
Tests whether `validate_description` works as intended.
Case: passing.
"""
for input_value, expected_output in (
(None, None),
('', None),
('a', 'a'),
):
ou... | [
"re.ism.tm@gmail.com"
] | re.ism.tm@gmail.com |
c3636b8e04c183bbfd91b55e97ab51feba8e2fdd | 1bba250d4bb338cba39245d1fd8fda17ced0db57 | /app/core/migrations/0006_tag.py | ef2c035496e173f7e9ef9b9352ef8ad01839358f | [
"MIT"
] | permissive | daryabsb/recipe-app-api | ba72601005a7ac90bcbc0de62fe5bdb0123a7471 | c41f22ebe5856054a0f3b03864ac07ce43a9c549 | refs/heads/master | 2021-03-21T22:26:32.204117 | 2020-04-14T09:24:54 | 2020-04-14T09:24:54 | 247,332,169 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 693 | py | # Generated by Django 3.0.3 on 2020-04-02 14:30
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('core', '0005_auto_20200401_1420'),
]
operations = [
migrations.CreateModel... | [
"daryabsb@gmail.com"
] | daryabsb@gmail.com |
9a036176c54b983a5aa429f94a41006ed7fab580 | d046fd4ac8e52ed8054199765893f7e1a71302f2 | /master/bt5/slapos_jio/SkinTemplateItem/portal_skins/slapos_hal_json_style/Computer_requestNewComputerCertificateFromJio.py | 3e4ae62c5e8b97329950992616a413f3388b71e3 | [] | no_license | jakop345/slapos.core | 7538418056be6541e9ee7a70d2d6b694e03daafc | 410dfb506b7ec17745365d573e7401f217b74ed4 | refs/heads/master | 2020-06-18T21:43:39.012812 | 2016-11-24T11:06:49 | 2016-11-24T11:06:49 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 373 | py | if REQUEST.other['method'] != "POST":
response.setStatus(405)
return ""
import json
computer = context
request = context.REQUEST
response = REQUEST.RESPONSE
context.Base_prepareCorsResponse(RESPONSE=response)
computer.generateCertificate()
return json.dumps({
'certificate': request.get('computer_certificate'... | [
"alain.takoudjou@nexedi.com"
] | alain.takoudjou@nexedi.com |
39d93fd9b91c516d6c3d3ef51e848b6ec6f57763 | 6d38a0339ed77ba06ea03744ad54eaea2ce3b49e | /practical 18/p18p3.py | 56b76f1de239bf519ceca121a90f6df5783ea48e | [] | no_license | Miguelmargar/ucd_programming1 | a0e15fe1f474684b1a5364c6f8bfa681db96d4b5 | c17cb2903ce41b9b714a4963f5fdc703b812a539 | refs/heads/master | 2020-03-28T23:21:15.586114 | 2018-11-23T16:29:15 | 2018-11-23T16:29:15 | 149,287,660 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 963 | py | #program to count for strings containing co at 1st two strings and e at 4th string
def code_check(str):
"""finds co and e in a string with letters inbetween but no other characters
assumes a string given
"""
#check for string to be bigger than 4 carachters
if len(str) < 4:
print(... | [
"miguelitalia@hotmail.com"
] | miguelitalia@hotmail.com |
8083e83a21d9f600d629d10cf06d63c6ac28b65f | dfe4d9f6b09109b22e76069b0f6e56993165e91d | /camp-python-2021-find-me-develop/config/settings/common/middleware.py | 6674f4ea74ad5fc3eea0de213b568c4c612e8991 | [] | no_license | rhanmar/oi_projects_summer_2021 | ef6b06e003a1c54583df4b006d141df924adeafb | 0879ade24685b628624dce06698f8a0afd042000 | refs/heads/main | 2023-08-25T04:02:46.284756 | 2021-09-17T03:29:16 | 2021-09-17T03:29:16 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 601 | py | MIDDLEWARE = (
'django.contrib.sessions.middleware.SessionMiddleware',
'corsheaders.middleware.CorsMiddleware',
'django.middleware.common.CommonMiddleware',
'django.middleware.http.ConditionalGetMiddleware',
'django.middleware.csrf.CsrfViewMiddleware',
'django.contrib.auth.middleware.Authenticat... | [
"dimontura@yandex.ru"
] | dimontura@yandex.ru |
d4b978eddb2f31ef5e9438c01dfe0853eb36e75c | 51b6d2fc53d5c632fcf01319842baebf13901e84 | /atcoder.jp/abc207/abc207_c/Main.py | e2fd6dd002fd19f986e8dbb2f6211080a1f7890c | [] | no_license | mono-0812/procon | 35db3b2c21eff74fbd7b52db07f249380f6834ef | 68a4b53880a228a0164052b23d1326363efcbc20 | refs/heads/master | 2023-05-30T17:02:58.935074 | 2021-06-27T12:15:10 | 2021-06-27T12:15:10 | 345,896,553 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,643 | py | import bisect,collections,copy,heapq,itertools,math,string,sys,queue,time
from typing import Union, ValuesView
input = lambda: sys.stdin.readline().rstrip()
def I(): return input()
def IS(): return input().split()
def II(): return int(input())
def IIS(): return map(int,input().split())
def LIIS(): return list(map(int,i... | [
"frisk02.jar@gmail.com"
] | frisk02.jar@gmail.com |
62d4f72cd84e34850eb0e4a71f7cf92cb671f242 | 16370542f68c830edb70a35e1eee7cf8ac39e3c6 | /scripts/run_gtest_angle_test.py | c2e335d7fc520775ec2013c154175c8401c74104 | [
"BSD-3-Clause",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | wmlabs/angle | c54f65864730c202220615552d35c76a19f204f9 | 7e427f51b3eb958063cf9dfd9b2ed65a317c6ba3 | refs/heads/master | 2022-10-27T23:33:39.941361 | 2020-09-25T10:01:41 | 2020-09-25T11:50:48 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,517 | py | #!/usr/bin/env python
# Copyright 2020 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
"""Runs an isolated non-Telemetry ANGLE test.
The main contract is that the caller passes the arguments:
--isolated-script-test-outp... | [
"commit-bot@chromium.org"
] | commit-bot@chromium.org |
5eae8fab804dcaf1212328636ac3c2bc5dc41dde | 32c56293475f49c6dd1b0f1334756b5ad8763da9 | /google-cloud-sdk/lib/googlecloudsdk/command_lib/compute/instance_groups/managed/rolling_action.py | 30b8ca75365e4826cf43b39ccd316ec1143290ff | [
"MIT",
"LicenseRef-scancode-unknown-license-reference",
"Apache-2.0"
] | permissive | bopopescu/socialliteapp | b9041f17f8724ee86f2ecc6e2e45b8ff6a44b494 | 85bb264e273568b5a0408f733b403c56373e2508 | refs/heads/master | 2022-11-20T03:01:47.654498 | 2020-02-01T20:29:43 | 2020-02-01T20:29:43 | 282,403,750 | 0 | 0 | MIT | 2020-07-25T08:31:59 | 2020-07-25T08:31:59 | null | UTF-8 | Python | false | false | 6,430 | py | # -*- coding: utf-8 -*- #
# Copyright 2017 Google LLC. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless requir... | [
"jonathang132298@gmail.com"
] | jonathang132298@gmail.com |
16536b8f5ec5c77bff7c2d81268df50f2fc1518b | ce7680ac0960fbd889edd7175a15a2ed2eecb484 | /supervised_learning/0x06-keras/5-main.py | b391bdb17063395b73ac74ce956352414627b9e0 | [] | no_license | macoyulloa/holbertonschool-machine_learning | d27075c37ddfc026a984f849a333458b9200f8d8 | 1d86c9606371697854878b833b810d73c9af7ee7 | refs/heads/master | 2020-12-22T10:11:42.232484 | 2020-11-05T04:08:15 | 2020-11-05T04:08:15 | 236,747,747 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,075 | py | #!/usr/bin/env python3
import numpy as np
import tensorflow as tf
build_model = __import__('1-input').build_model
optimize_model = __import__('2-optimize').optimize_model
one_hot = __import__('3-one_hot').one_hot
train_model = __import__('5-train').train_model
if __name__ == '__main__':
datasets = np.load('../da... | [
"malejacoy@hotmail.com"
] | malejacoy@hotmail.com |
99f2a2b2be01a6e17995c8d0f381009913de9a51 | 7df96c7a677fb987b9792cf74a695a0884f1fac8 | /backend/test_22152/settings.py | 34022c5feaecc6807fc563acf8221ad73459d9fd | [] | no_license | crowdbotics-apps/test-22152 | d355cd3fbdf49112d9ae5b6c60022903327d51ac | 4016085b692b261a2cd99e29ef28f70e3c975e21 | refs/heads/master | 2023-01-04T10:50:59.605487 | 2020-10-31T05:12:14 | 2020-10-31T05:12:14 | 308,808,319 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,182 | py | """
Django settings for test_22152 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 |
ebc3abca41209dde8bb1ac2264f9ec411ca5fb3a | c9eddcc8ae129d52ac08e59039a349827d78ac39 | /doc/examples/create-sampletype.py | fd5d7be138a1a767edda0c148a7fac7c7250f7d8 | [
"Apache-2.0"
] | permissive | ahmad-tarbeya/python-icat | 48335cedc256992e811f903616a593aadb45f194 | a54f76551c74eacddffe19f8f217e81cf221d551 | refs/heads/master | 2021-01-20T06:43:09.083208 | 2017-04-25T13:42:46 | 2017-04-25T13:43:22 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,211 | py | #! /usr/bin/python
#
# Create some sample sample types.
#
# This script should be run by a member of the samplewriter group
#
from __future__ import print_function
import icat
import icat.config
import sys
import logging
import yaml
logging.basicConfig(level=logging.INFO)
#logging.getLogger('suds.client').setLevel(lo... | [
"rolf.krahl@helmholtz-berlin.de"
] | rolf.krahl@helmholtz-berlin.de |
2c33484f0fb73c3cbc514b21ced8d47f5b740c67 | de428c011b56db862f05ec0ceab17b85f83f94b1 | /pythongame/game_data/items/item_wizards_cowl.py | fbbe4dd92a75a9905d6fa3ce3f4e4f5b50700e59 | [] | no_license | risooonho/python-2d-game | c6d1fceaf09c72a6f7573230a4a899bf79164b7f | 24b02646ed56f9017069b243b774e0ee46951aea | refs/heads/master | 2021-05-17T06:02:13.538699 | 2020-02-15T23:59:54 | 2020-02-15T23:59:54 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,254 | py | from pythongame.core.common import ItemType, Sprite
from pythongame.core.damage_interactions import player_receive_mana
from pythongame.core.game_data import UiIconSprite
from pythongame.core.game_state import Event, EnemyDiedEvent, GameState
from pythongame.core.item_effects import AbstractItemEffect
from pythongame.c... | [
"jonte.murray@gmail.com"
] | jonte.murray@gmail.com |
ff74bb24a551485f00a3497361ed0a52e25dea7f | 90c6262664d013d47e9a3a9194aa7a366d1cabc4 | /tests/storage/cases/test_KT1CSKPf2jeLpMmrgKquN2bCjBTkAcAdRVDy_alpha.py | 8a2af8cf9baa53d2cf451208b8d7bc8353a77feb | [
"MIT"
] | permissive | tqtezos/pytezos | 3942fdab7aa7851e9ea81350fa360180229ec082 | a4ac0b022d35d4c9f3062609d8ce09d584b5faa8 | refs/heads/master | 2021-07-10T12:24:24.069256 | 2020-04-04T12:46:24 | 2020-04-04T12:46:24 | 227,664,211 | 1 | 0 | MIT | 2020-12-30T16:44:56 | 2019-12-12T17:47:53 | Python | UTF-8 | Python | false | false | 1,160 | py | from unittest import TestCase
from tests import get_data
from pytezos.michelson.converter import build_schema, decode_micheline, encode_micheline, micheline_to_michelson
class StorageTestKT1CSKPf2jeLpMmrgKquN2bCjBTkAcAdRVDy_alpha(TestCase):
@classmethod
def setUpClass(cls):
cls.maxDiff = None
... | [
"mz@baking-bad.org"
] | mz@baking-bad.org |
69caeafc8936c91cec0cb41a3abe8f4b2ca6b8c3 | a140fe192fd643ce556fa34bf2f84ddbdb97f091 | /.history/practice_20200628121026.py | d81d184b72a8fa1905eb2139474218b4ebcbaa74 | [] | no_license | sangha0719/py-practice | 826f13cb422ef43992a69f822b9f04c2cb6d4815 | 6d71ce64bf91cc3bccee81378577d84ba9d9c121 | refs/heads/master | 2023-03-13T04:40:55.883279 | 2021-02-25T12:02:04 | 2021-02-25T12:02:04 | 342,230,484 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 480 | py | print(5)
print(-10)
print(3.14)
print(1000)
print(5+3)
print(2*8)
print(3*(3+1))
# 괄호안의 숫자가 우선 연산 된다. 일반적 수학공식과 같은 결과 도출
print('풍선')
print("나비")
print("ㅋㅋㅋㅋ")
print("ㅋ"*4)
# 문자와 숫자를 같이 연산가능하다.
# 참 / 거짓 boolean
print(5 > 10) # False
print(5 < 10) # True
print(True) # True
print(False) # False
print(not True) # Fals... | [
"sangha0719@gmail.com"
] | sangha0719@gmail.com |
5669e08704540b7d16b911dd29a517c99b105724 | d5a5ff1ed1f508c47e9506a552bf44844bcdc071 | /labor/views.py | b89304c2f6eaa410229cc2bca50e8ad327b28fc0 | [] | no_license | sintaxyzcorp/prometeus | 5c9dc20e3c2f33ea6b257b850ff9505621302c47 | 2508603b6692023e0a9e40cb6cd1f08465a33f1c | refs/heads/master | 2021-09-01T09:31:36.868784 | 2017-12-26T07:58:27 | 2017-12-26T07:58:27 | 113,787,842 | 0 | 1 | null | 2017-12-18T08:25:31 | 2017-12-10T22:16:28 | JavaScript | UTF-8 | Python | false | false | 7,855 | py | # -*- coding: utf-8 -*-
# Python's Libraries
from __future__ import unicode_literals
# Django's Libraries
from django.shortcuts import render
from django.shortcuts import redirect
from django.shortcuts import get_object_or_404
from django.core.urlresolvers import reverse
from django.views.generic import CreateView
fr... | [
"carloxdev@gmail.com"
] | carloxdev@gmail.com |
77489b4e7adc540fe67ff8b5ecdec179e2a1f569 | 7103e8c2f689d0d23254d98b6cce65606fbd474a | /solutions/241.py | dbcae62ed6e1cbacd64b99b6861fd570d9af1678 | [] | no_license | DanqiChang/leetcode-notes | 18bb10f329d214b805568d4c7270042ab97e3c1f | b81dd2bc5839e60dfa5efa712ed00e0876ca173e | refs/heads/master | 2020-03-28T20:25:10.612938 | 2018-09-17T04:32:42 | 2018-09-17T04:32:42 | 149,068,156 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,261 | py | """
{
"difficulty": "medium",
"link": "https://leetcode.com/problems/different-ways-to-add-parentheses/description/",
"category": ["divide-and-conquer"],
"tags": [],
"questions": []
}
"""
"""
思路:
- 返回当前input String的所有可能计算结果(一个list)
- 需要用try-except来判断是否是一个数,作为递归终止条件
"""
class Solution:
... | [
"huangyc96@gmail.com"
] | huangyc96@gmail.com |
a23593000fa3616e96b86f2c2b60ed33aee441f4 | bc9f66258575dd5c8f36f5ad3d9dfdcb3670897d | /lib/surface/container/fleet/service_directory/describe.py | 201acf43646d6ca71c3b20c5bf3bfcb686306c5f | [
"Apache-2.0",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | google-cloud-sdk-unofficial/google-cloud-sdk | 05fbb473d629195f25887fc5bfaa712f2cbc0a24 | 392abf004b16203030e6efd2f0af24db7c8d669e | refs/heads/master | 2023-08-31T05:40:41.317697 | 2023-08-23T18:23:16 | 2023-08-23T18:23:16 | 335,182,594 | 9 | 2 | NOASSERTION | 2022-10-29T20:49:13 | 2021-02-02T05:47:30 | Python | UTF-8 | Python | false | false | 1,199 | py | # -*- coding: utf-8 -*- #
# Copyright 2022 Google LLC. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless requir... | [
"cloudsdk.mirror@gmail.com"
] | cloudsdk.mirror@gmail.com |
fdd9769b3a583edeabcb4b190de098fc29f98526 | b01ae67eff0fb67e328509255f74593e19b0a784 | /101. Symmetric Tree.py | a573312508a0b56cbc90bd214df0913511100fd5 | [] | no_license | livelifeyiyi/myleetcode | 71a938b24a9538a7dca47c5c7b9ae7dc98ce6160 | a4687c0f4ebb494549f4ce5c1b22d1324bc41909 | refs/heads/master | 2021-01-10T08:15:45.770736 | 2017-01-19T02:03:31 | 2017-01-19T02:03:31 | 52,666,348 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 670 | py | # Definition for a binary tree node.
# class TreeNode(object):
# def __init__(self, x):
# self.val = x
# self.left = None
# self.right = None
class Solution(object):
def isSymmetric(self, root):
"""
:type root: TreeNode
:rtype: bool
"""
if root ==... | [
"xiaoya_0922@126.com"
] | xiaoya_0922@126.com |
cf4bdeee0f5a2ce04e2a6f13cf418c707ef21f9f | 7a30591411039d90ad9eb1c11b3a96fea15f4d66 | /Assignments/Brea/Python Labs/Making Change Lab Version 3.py | 178b2b61c29ad0e34b520346b8578cf6fb525201 | [] | no_license | PdxCodeGuild/class_mudpuppy | 60fe3cc06c23da8c8c08257a2b9b87f7593c9fb6 | 36e08862d1bbcc9a4b535d948199e569ecbdd115 | refs/heads/master | 2022-11-29T15:25:26.721828 | 2021-07-15T22:20:11 | 2021-07-15T22:20:11 | 248,027,316 | 5 | 2 | null | 2022-11-22T06:30:19 | 2020-03-17T17:06:14 | Python | UTF-8 | Python | false | false | 570 | py | # Making change lab version 3 March 20th, 2020
user_input = input("How many much money do you have?: $ ")
user_input = float(user_input)
user_input = round(user_input * 100)
user_dollars = user_input // 100
user_quarters = round(user_input % 100 // 25)
user_dimes = round(user_input % 25 // 10)
user_nickels = rou... | [
"your_email@youremail.com"
] | your_email@youremail.com |
48864bc4c7c0014c9ce9b41647f8c3674ce74389 | 9f853c038156510d091f0b4a5ddd141f73ce41e4 | /Deck.py | 10ae03946a713aff697db4d58f9a128cf0764646 | [] | no_license | ArtyomPV/blackjack_intensive | 5cf1cff3c717a8d6bf813447c67c8a181a921563 | ca194318a479f29b28f1f1303ce55ee2046222b2 | refs/heads/master | 2023-03-28T05:58:13.898419 | 2020-06-24T01:24:15 | 2020-06-24T01:24:15 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,052 | py | from itertools import product
from random import shuffle
from const import PRINTED, SUITS, RANKS
class Card:
def __init__(self, suit, rank, picture, points):
self.suit = suit
self.rank = rank
self.picture = picture
self.points = points
def __str__(self):
message = se... | [
"amurakho@gmail.com"
] | amurakho@gmail.com |
319a166ab5962c98eadae0f92c4a5f56b4f5fa05 | 59f60677d07c61fae8c0eb8a1ef23ed63b76a7dc | /backend/mobileapp_dev_1721/settings.py | 5c760fc169de9dd2d9e0b9a796eaf0f43276b253 | [] | no_license | crowdbotics-apps/mobileapp-dev-1721 | 70f7a6543dc1faaaed4815c07d99eac02f111207 | 04a8877ca69b7623c1f7a49612ff8a7bec5be72d | refs/heads/master | 2022-04-10T17:01:08.345424 | 2020-02-26T11:05:00 | 2020-02-26T11:05:00 | 243,175,175 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,738 | py | """
Django settings for mobileapp_dev_1721 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/
"""
i... | [
"team@crowdbotics.com"
] | team@crowdbotics.com |
96dfa159383eacf7d313a1c2e558bcd1789006da | a3d6556180e74af7b555f8d47d3fea55b94bcbda | /ash/webui/camera_app_ui/resources/utils/cca/commands/check_color_tokens.py | c00cca95a1a0c31161f66d3996f62185e18e333e | [
"BSD-3-Clause"
] | permissive | chromium/chromium | aaa9eda10115b50b0616d2f1aed5ef35d1d779d6 | a401d6cf4f7bf0e2d2e964c512ebb923c3d8832c | refs/heads/main | 2023-08-24T00:35:12.585945 | 2023-08-23T22:01:11 | 2023-08-23T22:01:11 | 120,360,765 | 17,408 | 7,102 | BSD-3-Clause | 2023-09-10T23:44:27 | 2018-02-05T20:55:32 | null | UTF-8 | Python | false | false | 5,848 | py | # Copyright 2023 The Chromium Authors
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import glob
import re
from cca import cli
# Ref: https://developer.mozilla.org/en-US/docs/Web/CSS/named-color
_CSS_NAMED_COLORS = """
aliceblue antiquewhite aqua aquamarine azur... | [
"chromium-scoped@luci-project-accounts.iam.gserviceaccount.com"
] | chromium-scoped@luci-project-accounts.iam.gserviceaccount.com |
c88a32ca5e109c448d7ca19fed0fce1fd23d0e61 | 888cfb7f0e16bb30408f89afda47a4418026ac6b | /_celery/standard_demo/proj/celery.py | 89ba514cbb90e1d92b83c3f21b5cbea9aa7da772 | [] | no_license | BennyJane/flask-demo | a4e5e224d999c7a898fb652047c511fe37718567 | 23965c0f31e6723dca8263c0e254ffea0f585471 | refs/heads/master | 2023-02-10T17:29:53.663476 | 2021-01-10T13:58:56 | 2021-01-10T13:58:56 | 297,965,363 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 322 | py | from celery import Celery
class CeleryConfig:
broker = 'redis://localhost:6379'
backend = 'redis://localhost:6379'
imports = ('proj.flask_linux_crontab',)
# todo 第一个参数以及 imports 必须是异步任务所在模块的名称
celery_app = Celery('app')
celery_app.config_from_object(CeleryConfig)
| [
"3355817143@qq.com"
] | 3355817143@qq.com |
1a396345ce88476d740c9401648c8d33681f1fea | 0d178d54334ddb7d669d212b11dd23ef5607cf8e | /Companies/Amazon/number of crates.py | 7bd4c8396a449c1c5c30338e2c8125dc2c2c862a | [] | no_license | mrunalhirve12/Python_CTCI-practise | 2851d2c61fd59c76d047bd63bd591849c0781dda | f41348fd7da3b7af9f9b2df7c01457c7bed8ce0c | refs/heads/master | 2020-04-17T11:09:29.213922 | 2019-09-28T02:36:24 | 2019-09-28T02:36:24 | 166,529,867 | 3 | 0 | null | null | null | null | UTF-8 | Python | false | false | 720 | py | import heapq
import math
def dist(total, arr, capacity):
if not total or not capacity:
return []
dict = {}
for i in range(len(arr)):
val = (arr[i][0]**2) if arr[i][0] else 0 + (arr[i][-1]**2) if arr[i][0] else 0
dist = math.sqrt(val)
diff = abs(capacity - dist)
dict... | [
"mrunalhirve@gmail.com"
] | mrunalhirve@gmail.com |
cc36c5d194ea11fb614a80af9d09f37f220a315f | 2d4380518d9c591b6b6c09ea51e28a34381fc80c | /CIM16/IEC61968/AssetModels/EndDeviceInfo.py | d442370220e046fee4fc2a5353ee93db1750ee82 | [
"MIT"
] | permissive | fran-jo/PyCIM | 355e36ae14d1b64b01e752c5acd5395bf88cd949 | de942633d966bdf2bd76d680ecb20517fc873281 | refs/heads/master | 2021-01-20T03:00:41.186556 | 2017-09-19T14:15:33 | 2017-09-19T14:15:33 | 89,480,767 | 0 | 1 | null | 2017-04-26T12:57:44 | 2017-04-26T12:57:44 | null | UTF-8 | Python | false | false | 2,997 | py | # Copyright (C) 2010-2011 Richard Lincoln
#
# 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, modify, merge, publish... | [
"fran_jo@hotmail.com"
] | fran_jo@hotmail.com |
1403bb2f5684b14ae0a20481ee0f680aff8ad939 | 89f3d392cbb1a79615426a166cb484ef7a868d61 | /SAMBALoader/ChipIdentifiers/CHIPID.py | fbb7a9e3fd481b92b4c70d3907157e667f8ac36c | [
"MIT"
] | permissive | fawzma/sam-ba-loader | 2b10f177cc76a654b3d897ba98676d785ff2043f | 3154cb1cbc3c45d30438fafa8955a4c6e423c9d8 | refs/heads/master | 2021-05-31T08:21:26.186228 | 2016-04-30T14:11:31 | 2016-04-30T14:11:31 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,040 | py | #
# Open Source SAM-BA Programmer
# Copyright (C) Dean Camera, 2016.
#
# dean [at] fourwalledcubicle [dot] com
# www.fourwalledcubicle.com
#
#
# Released under a MIT license, see LICENCE.txt.
from .import ChipIdentifier
class CHIPID(ChipIdentifier.ChipIdentifierBase):
"""CHIPID chip identifier mo... | [
"dean@fourwalledcubicle.com"
] | dean@fourwalledcubicle.com |
7f9d1fdc72aae76a739b84ba5e9be7e918020afa | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p03695/s442576551.py | 7eeb147b66a2777270a78e58a58d0e7ebb19cf4c | [] | 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 | 219 | py | with open(0) as f:
N, *a = map(int, f.read().split())
Set = set()
free = 0
for x in a:
x //= 400
if x < 8:
Set.add(x)
else:
free += 1
Ans = [max(1, len(Set)), len(Set)+free]
print(*Ans)
| [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
1781864eed9263616807a5997ce153882c95d2c4 | d46d5dff76d39adad092178c60dfefc6afea563a | /oberbankde/middlewares.py | c091646f27b11e0f805a86743c770ff407e40dbf | [] | no_license | daniel-kanchev/oberbankde | e1246afd4870de080299e1787d21d770126311b7 | 5d100c368dea02306b1a0a0f946c4a0a748b2b17 | refs/heads/main | 2023-03-21T18:58:40.426008 | 2021-03-17T13:03:25 | 2021-03-17T13:03:25 | 348,712,169 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,656 | py | # Define here the models for your spider middleware
#
# See documentation in:
# https://docs.scrapy.org/en/latest/topics/spider-middleware.html
from scrapy import signals
# useful for handling different item types with a single interface
from itemadapter import is_item, ItemAdapter
class OberbankdeSpiderMiddleware:... | [
"daniel.kanchev@adata.pro"
] | daniel.kanchev@adata.pro |
d128f37e97393bdf2e2143c0c90b41c05287b42e | d381cd66ff19b45715da954bdd578d95b60b7627 | /weibo/cron/realtime/config.py | 2052e54d869233485cf70d91775e4b0a5b1c9297 | [] | no_license | huxiaoqian/project | d817496f67ad1a930d4846a2c1fab9589f7af35a | 4e3db5a93d00b7b546fcd3bd6d0dcc63504daf8e | refs/heads/master | 2020-04-09T07:17:34.592855 | 2014-07-25T21:04:05 | 2014-07-25T21:04:05 | 22,255,717 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,445 | py | # -*- coding: utf-8 -*-
from flask import Flask
from flask.ext.sqlalchemy import SQLAlchemy
from xapian_weibo.xapian_backend import XapianSearch
REDIS_HOST = '192.168.2.31'
REDIS_PORT = 6379
COBAR_HOST = '192.168.2.31'
COBAR_PORT = 8066
COBAR_USER = 'cobar'
LEVELDBPATH = "/media/data/leveldb"
emotio... | [
"1257819385@qq.com"
] | 1257819385@qq.com |
053057170df400c0bfa233a8866adfbb5040192d | 19d47d47c9614dddcf2f8d744d883a90ade0ce82 | /pynsxt/swagger_client/models/quick_search_request.py | bd0ba62a0d976a57a688793d66ff5b83f349b197 | [] | no_license | darshanhuang1/pynsxt-1 | 9ed7c0da9b3a64e837a26cbbd8b228e811cee823 | fb1091dff1af7f8b8f01aec715682dea60765eb8 | refs/heads/master | 2020-05-25T14:51:09.932853 | 2018-05-16T12:43:48 | 2018-05-16T12:43:48 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,447 | py | # coding: utf-8
"""
NSX API
VMware NSX REST API # noqa: E501
OpenAPI spec version: 1.0.0
Generated by: https://github.com/swagger-api/swagger-codegen.git
"""
import pprint
import re # noqa: F401
import six
class QuickSearchRequest(object):
"""NOTE: This class is auto generated by the ... | [
"tcraft@pivotal.io"
] | tcraft@pivotal.io |
2c43a6c159c8c9e2f096bf987e1e09d4d20f54ed | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p02797/s496545132.py | d073d1157f965a80643c720bae61d24353813280 | [] | 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 | 607 | py | import sys
import itertools
# import numpy as np
import time
import math
import heapq
from collections import defaultdict
from collections import Counter
sys.setrecursionlimit(10 ** 7)
INF = 10 ** 18
MOD = 10 ** 9 + 7
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readl... | [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
7d06ab29c65f485f88783a7285c5ec60d8ee7da7 | f202ac96ff532c5dfba9914cc5b0c843c9ad34e1 | /parlai/agents/programr/config/brain/binaries.py | dff19691ae4d0c40a7f3f46b3297fa30eef3e9d4 | [
"MIT"
] | permissive | roholazandie/ParlAI | 3caf2c913bbe6a4c2e7e7eee5674d7786eca5427 | 32352cab81ecb666aefd596232c5ed9f33cbaeb9 | refs/heads/master | 2021-12-02T01:30:09.548622 | 2021-10-19T17:38:23 | 2021-10-19T17:38:23 | 187,677,302 | 0 | 0 | MIT | 2021-06-24T21:44:34 | 2019-05-20T16:31:52 | Python | UTF-8 | Python | false | false | 598 | py | import json
from dataclasses import dataclass, field
import yaml
@dataclass
class BrainBinariesConfiguration:
save_binary: bool = field(default=False)
load_binary: bool = field(default=False)
binary_filename: None = field(default=None)
load_aiml_on_binary_fail: bool = field(default=False)
@class... | [
"hilbert.cantor@gmail.com"
] | hilbert.cantor@gmail.com |
178e340acf9c801bdf1449e7deec541a2794ddff | 8e4bb58199f712320c34e7fc03e3f9315c256fc9 | /test/test_sync.py | 70ee586ed8a288b35760dfdbdf580df30163b677 | [
"MIT",
"Unlicense",
"LicenseRef-scancode-public-domain",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | wangkai2014/flower | 7f68eb567bbc40e095d3c01e4c611794c5e28d2d | fca53d83bc067e669215cf37a94ea1269108499d | refs/heads/master | 2021-01-19T19:08:26.819875 | 2013-09-14T08:00:57 | 2013-09-14T08:00:57 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 601 | py |
from flower.core.sync import *
def test_increment():
i = 0
i = increment(i)
assert i == 1
i = increment(i)
assert i == 2
def test_decrement():
i = 0
i = decrement(i)
assert i == -1
i = decrement(i)
assert i == -2
def test_combine():
i = 1
i = decrement(i)
asser... | [
"bchesneau@gmail.com"
] | bchesneau@gmail.com |
5738d605323f1df65a36d4c866ad91641926c774 | b9f4d7641ba95234fdf44db8e126a192b3ddc511 | /roadmap/cms_app.py | 9bde2c60de0eb9a433a36c6ac905efeafc20d33f | [
"MIT"
] | permissive | inspyration/django-roadmap | 9dd16b88c5c6112fa8819f431fbc9b30e19cf222 | 72cdc20bcd129ffb00395d5b1215fedbf59218b2 | refs/heads/master | 2021-01-24T14:33:51.661466 | 2014-03-11T07:15:13 | 2014-03-11T07:15:13 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 297 | py | """django-cms app for the ``roadmap`` app."""
from django.utils.translation import ugettext_lazy as _
from cms.app_base import CMSApp
from cms.apphook_pool import apphook_pool
class RoadmapApp(CMSApp):
name = _("Roadmap App")
urls = ["roadmap.urls"]
apphook_pool.register(RoadmapApp)
| [
"mbrochh@gmail.com"
] | mbrochh@gmail.com |
8715a30fb9e18c0c5c6486c13ee2d9933110b0ce | 2ed7f1e1f59832e91fe0402eca82ecf6fea2be40 | /0x0B-python-input_output/14-pascal_triangle.py | 8f8d421033ee8cbb280269a23d2fa2ede3c4afa8 | [] | no_license | Leidysalda/holbertonschool-higher_level_programming | abf3159db916ec293fc219b591e2c44f74afe3f3 | 46c04cdc7b76afbd79c650ff258f85aef7d2d5fe | refs/heads/master | 2020-09-29T02:40:47.437740 | 2020-09-23T05:37:10 | 2020-09-23T05:37:10 | 259,387,894 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 410 | py | #!/usr/bin/python3
"""PascalTriangle"""
def pascal_triangle(n):
"""
pascal
"""
if n <= 0:
return []
elif n == 1:
return[[1]]
else:
new_r = [1]
res = pascal_triangle(n - 1)
last_r = res[-1]
for i in range(len(last_r) - 1):
new_r.append... | [
"leidysalda1@gmail.com"
] | leidysalda1@gmail.com |
c3c181f9b2558d08fd2043a3ec2ed4ca96cacf68 | 66987af9a8d0fb22937182bba0246aee9a32b8ec | /generator.py | d08090a3f577ecc2c308564492a42c7665c71cda | [
"MIT"
] | permissive | sorrowyn/MultiDigitMNIST | 3826f2a7b795468464bbe45efe0cb2679d43c995 | f8f9aa28c1b65ebec13c9711fcd1470360189138 | refs/heads/master | 2023-06-11T15:03:29.173852 | 2021-07-02T12:54:44 | 2021-07-02T12:54:44 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,284 | py | import subprocess
import os
import os.path as osp
import numpy as np
from imageio import imwrite
import argparse
mnist_keys = ['train-images-idx3-ubyte', 'train-labels-idx1-ubyte',
't10k-images-idx3-ubyte', 't10k-labels-idx1-ubyte']
def check_mnist_dir(data_dir):
downloaded = np.all([osp.isfile(os... | [
"waltersun81@gmail.com"
] | waltersun81@gmail.com |
cc0e16a771bbee131a8b5adbecdc2aee7ac9bbf0 | 0a3f7842b5db5e50e437d7f3adb3653cc61037ab | /views/org.py | 583dd7507e4ff7561b73f62f4c2bdc7d59416876 | [] | no_license | code4sac/bikeandwalk | 625654a158767cee91106b70c564090399d53c5b | 080e7b9bfd88314b9cf0fb3a1ed4b1aa5cffeaed | refs/heads/master | 2023-02-10T14:37:02.353053 | 2020-03-10T23:32:49 | 2020-03-10T23:32:49 | 52,499,890 | 5 | 2 | null | 2023-02-02T02:36:24 | 2016-02-25T05:41:56 | JavaScript | UTF-8 | Python | false | false | 4,051 | py | from flask import request, session, g, redirect, url_for, \
render_template, flash, Blueprint
from bikeandwalk import db
from models import Organization
from views.utils import getTimeZones, printException, cleanRecordID
mod = Blueprint('org',__name__)
def setExits():
g.listURL = url_for('.org_list')
g.e... | [
"bill@williesworkshop.net"
] | bill@williesworkshop.net |
2537b87f9f840146846edfa6346c58c745f5713f | 61b86dee4dc477d6abbc7cd49693c5496928a976 | /venv/Lib/site-packages/pip/_vendor/html5lib/filters/lint.py | d39e6d7154768051ed3b36115f77b00af0c4d547 | [] | no_license | Spirovanni/techforce3 | 3a748a49025808ac1adabc38f9f3251a3d60a68f | 5e9e80df43a887ba32f35f82b0119a15f7483d07 | refs/heads/master | 2020-09-21T11:21:19.492747 | 2019-12-07T16:06:05 | 2019-12-07T16:06:05 | 224,771,839 | 0 | 0 | null | 2019-12-06T06:06:16 | 2019-11-29T03:42:04 | Python | UTF-8 | Python | false | false | 3,669 | py | from __future__ import absolute_import, division, unicode_literals
from pip._vendor.six import text_type
from . import base
from ..constants import namespaces, voidElements
from ..constants import spaceCharacters
spaceCharacters = "".join(spaceCharacters)
class Filter(base.Filter):
"""Lints the token stream fo... | [
"blackshieldsx@gmail.com"
] | blackshieldsx@gmail.com |
92a8a47d896181fc68493fd48379419f62e0f4df | 82b946da326148a3c1c1f687f96c0da165bb2c15 | /sdk/python/pulumi_azure_native/hybridcompute/v20210517preview/get_private_endpoint_connection.py | 4abe94217c01e7ab5252beeb4a02108fa129e453 | [
"Apache-2.0",
"BSD-3-Clause"
] | permissive | morrell/pulumi-azure-native | 3916e978382366607f3df0a669f24cb16293ff5e | cd3ba4b9cb08c5e1df7674c1c71695b80e443f08 | refs/heads/master | 2023-06-20T19:37:05.414924 | 2021-07-19T20:57:53 | 2021-07-19T20:57:53 | 387,815,163 | 0 | 0 | Apache-2.0 | 2021-07-20T14:18:29 | 2021-07-20T14:18:28 | null | UTF-8 | Python | false | false | 4,542 | 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"
] | morrell.noreply@github.com |
eee4de8e1ecd179ebe54b188008c0c73f44090b3 | 5261e86efbaa9fa4b01d5a4200f303bdd6248734 | /nos_robust_mic/main/trial1/lrtz_train.py | b483849461e1449bb4c53fe394908c3f1cb4dbaa | [] | no_license | Hyunjae-Kim/membrane_vowel_recog | d65d8538598d0ecfa9302047a4ca3d0846547202 | ca286f722d2f48b4234c3cb702bb1e6a0d4d3bd4 | refs/heads/master | 2022-11-10T11:48:38.594688 | 2020-06-26T01:45:29 | 2020-06-26T01:45:29 | 275,050,770 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,215 | py | import os
import time
import shutil
import argparse
import numpy as np
import matplotlib.pyplot as plt
import torch
import torch.nn as nn
import torch.nn.functional as F
import torch.utils as utils
import torch.nn.init as init
from torchvision import datasets
parser = argparse.ArgumentParser(description='..')
parser.... | [
"khj9481@gmail.com"
] | khj9481@gmail.com |
3a7167decb1fe1d32877d3c137ea72b214ebb7d8 | 5695d365852a5b9bc4f8092c8aba139530def229 | /hs_core/migrations/0019_baseresource_locked_time.py | 03b1a404e9543bacd82c8ff49b7750b197c54acd | [
"BSD-3-Clause",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | heliumdatacommons/commonsshare | 6863705e71be2fb9ef4a822e391d60cfcbc82a44 | 4336dc337ca2b36c2d0a0a7ea793af624c1356c7 | refs/heads/develop | 2021-05-11T14:12:53.511860 | 2020-04-15T20:48:38 | 2020-04-15T20:48:38 | 117,697,775 | 2 | 4 | BSD-3-Clause | 2020-03-31T14:08:15 | 2018-01-16T14:58:04 | Python | UTF-8 | Python | false | false | 410 | py | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('hs_core', '0018_merge'),
]
operations = [
migrations.AddField(
model_name='baseresource',
name='lock... | [
"hongyi@renci.org"
] | hongyi@renci.org |
53b6e680f41081036778e4175ce989dda51d1683 | b6d8049568e8068422bc4ac2b957972dc1ee0ab7 | /blueprints/aws_dynamo_db/management/delete_backup.py | f5b32bd3833739fbb3c7984bd60d4c599c9f9660 | [
"Apache-2.0"
] | permissive | CloudBoltSoftware/cloudbolt-forge | a6dffd52bd074ad48a61527502fcddf8113508ff | a5584a84841be49bea69df506a91d18cb3f215d8 | refs/heads/master | 2023-08-11T08:08:07.730807 | 2023-08-10T11:40:07 | 2023-08-10T11:40:07 | 39,207,603 | 37 | 44 | Apache-2.0 | 2023-09-14T20:06:44 | 2015-07-16T16:18:02 | Python | UTF-8 | Python | false | false | 866 | py | """
Delete AWS Dynamo DB backup.
"""
from resourcehandlers.aws.models import AWSHandler
from common.methods import set_progress
import boto3
def run(resource, **kwargs):
region = resource.aws_region
rh_id = resource.aws_rh_id
backup_name = resource.backup_name
backup_arn = resource.backup_arn
ha... | [
"klaratta@cloudboltsoftware.com"
] | klaratta@cloudboltsoftware.com |
de53b01b8a3e6f38d96a884e894028d7dc123c4f | 9752a5c73f7765531e3703ff0c3735ecf5ce9c95 | /dilutionTesting/dilutionRepeatability.py | 2274ea8481156b4347d99988f44f53abac4c3959 | [] | no_license | liggettla/FERMI | 1641b8fafe9c12bb39fd61b5a33b2caeecd625ce | 5cf421327f60fb992bdc8e861f45a05397ec6bfa | refs/heads/master | 2021-03-27T09:18:10.424098 | 2019-08-14T19:34:37 | 2019-08-14T19:34:37 | 47,150,912 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,974 | py | #The purpose of this script is to compare the dilution samples in the
#1.5.2015 sequencing analysis or similar dilutions to understand how often
#a given mutation shows up when capturing and sequencing the same source
#DNA multiple times
list18 = []
list19 = []
list20 = []
with open('../fermiData/vcfs/18_finalOutput.... | [
"alexander.liggett@gmail.com"
] | alexander.liggett@gmail.com |
ed25d68ea8d1be84c9b913da11e62efd0949ee89 | 93d4040a40de53ff214a3e4c35941fd2e4c37adf | /src/chemical_roles/utils.py | 3108a2b51d2f8566f4e4c6b9736a8a69d2ffb374 | [
"MIT",
"CC0-1.0"
] | permissive | LaYeqa/chemical-roles | 6e86e429ee1564a06afbfb02551cff950f8cd22e | 31a917e911075e3be7eea509e143d3ff48e942cc | refs/heads/master | 2023-03-28T15:52:19.790501 | 2021-04-02T18:37:45 | 2021-04-02T18:37:45 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,797 | py | # -*- coding: utf-8 -*-
"""Chemical relation curation utilities."""
import logging
from collections import defaultdict
from typing import Iterable, Mapping, Set, Tuple
import pandas as pd
import requests
from .resources import XREFS_PATH, get_xrefs_df
logger = logging.getLogger(__name__)
XREFS_COLUMNS = [
'so... | [
"cthoyt@gmail.com"
] | cthoyt@gmail.com |
64bfd70da16ade9b11707fdc8ebb0df72f7a0712 | 5eb35e6fa9d0d7b28b3478cd932a867f2fcd66cd | /stabilityai/pytorch/inference/docker/build_artifacts/torchserve-stabilityai-entrypoint.py | b6086736afd784ce30b1f8cad1c937e13ab43286 | [
"Apache-2.0"
] | permissive | aws/deep-learning-containers | 3f4bc3fa0a27eca35c2faeac282a3fc2891e8d40 | ba76fa031f29e323a67b29c1d863db5c3d95084c | refs/heads/master | 2023-09-01T13:55:25.697898 | 2023-08-31T16:41:44 | 2023-08-31T16:41:44 | 234,634,164 | 811 | 434 | NOASSERTION | 2023-09-14T17:59:08 | 2020-01-17T20:52:43 | Python | UTF-8 | Python | false | false | 1,721 | py | # Copyright 2019-2021 Amazon.com, Inc. or its affiliates. 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. A copy of
# the License is located at
#
# http://aws.amazon.com/apache2.0/
#
# or in the "license" fil... | [
"noreply@github.com"
] | aws.noreply@github.com |
f9884d10f49eded133be9dec09e8d042ec4f4126 | de24f83a5e3768a2638ebcf13cbe717e75740168 | /moodledata/vpl_data/329/usersdata/298/91268/submittedfiles/dec2bin.py | 292b8fbeb98e5575b522960da7ff11be45a947bb | [] | no_license | rafaelperazzo/programacao-web | 95643423a35c44613b0f64bed05bd34780fe2436 | 170dd5440afb9ee68a973f3de13a99aa4c735d79 | refs/heads/master | 2021-01-12T14:06:25.773146 | 2017-12-22T16:05:45 | 2017-12-22T16:05:45 | 69,566,344 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 881 | py | # -*- coding: utf-8 -*-
def algarismos(n):
alg=1
while (n//10)>0:
n=n//10
alg=alg+1
return alg
def numerosden(n):
pr=n
alg=1
while (n//10)>0:
n=n//10
alg=alg+1
inicial=pr//(10^(alg-1))
lista=[]
while (pr%10)>0:
k=pr%10
lista=list... | [
"rafael.mota@ufca.edu.br"
] | rafael.mota@ufca.edu.br |
16924b5007f2308472ff5aa7b30aba61fa04096a | e2ee124cfc25270586d97c4f4f8f21cee4c87be5 | /tools/read-arduino-py3 | adce6d5d7690b66df2bf381aa3e25f99c411adc0 | [] | no_license | concurrency/embedded | 91ce5b437340d1e6493ea44f353e103885ccb8dd | acef797a7ee359d58ea5ab44a8016a1a4b4ba47b | refs/heads/master | 2021-01-01T05:31:38.902257 | 2018-07-10T18:32:19 | 2018-07-10T18:32:19 | 24,795,139 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,192 | #!/usr/bin/python
# Read the debugging output from an Arduino board.
# Usage: read-arduino -h
# LEFT /dev/tty.usbserial-A901N3TL
# RIGHT /dev/tty.usbserial-A901N6CR
import sys, serial, getopt
from datetime import datetime
def usage ():
print ("read-arduino -b <baud-rate> <port>")
print ("Baud rate is optional, and... | [
"matt@jadud.com"
] | matt@jadud.com | |
030fe24a550ef8b5205628fe5d48c416d68a8e5c | 75103cfae636f115c75f1eac150dccc27027a7d7 | /qytang_6.3/qytang/qytang/models/test_dme.py | 7b02c9ed70e20359bffab99ad48339b521a3e87d | [] | no_license | cqbomb/Nexus_API | 9b914e071d495df8c444ea63d5eedfb3ff32293b | 3de0e20a6eb345ca1b10a968db93a1136c961d5a | refs/heads/master | 2022-10-18T21:46:13.633069 | 2018-11-19T08:22:07 | 2018-11-19T08:22:07 | 137,348,464 | 1 | 1 | null | 2022-10-01T14:00:41 | 2018-06-14T11:20:57 | Python | UTF-8 | Python | false | false | 662 | py | from N9K_Core_Info import *
from test_token import get_token
nxos1_url = "http://192.168.1.101/api/mo/sys/bd.json"
yang_headers = {'content-type': 'application/json', 'Cookie': "APIC-Cookie=" + get_token()}
def test_yang():
payload = {
"bdEntity": {
"children": [
{
"l... | [
"Childeryang@gmail.com"
] | Childeryang@gmail.com |
09cc02356e8127a8e27a3f9cb32b3cee77875940 | dac7095e7b5ad4dae993871c1ae45cbb7a5ce5f7 | /Character/23.Mayuri/Mayuri_O.py | 83a3da6d7f8613b2eece1382da930e014228edae | [] | no_license | Lastation/RenewalAniChaos | d12a8423f4b83cb019495c59ed059451e67e0483 | c3edb29af58925de55c11110ccaf927d2b5d1b39 | refs/heads/master | 2023-08-24T11:28:35.614844 | 2023-08-22T21:23:14 | 2023-08-22T21:23:14 | 246,617,812 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 658 | py | import Function as f;
const s = StringBuffer();
function main(cp)
{
MoveLocation("23.Mayuri_Bozo", f.heroID[cp], cp, "Anywhere");
if (f.delay[cp] == 0)
{
if (f.count[cp] == 0)
{
SetSwitch("Recall - Mayuri", Set);
if (cp < 3) SetSwitch("Unique - Mayuri1", Set);
else Se... | [
"ghtjd000129@naver.com"
] | ghtjd000129@naver.com |
9c8e0de4696e5d6506135bc3cb53fcd1510ebfe7 | 8e3e073661520ae9a5909f6a8a5ad0da1591b4ab | /data/eval_PLOS.py | 0d565c9d306e6f52f752c2483998f5202e9a9e2e | [
"MIT"
] | permissive | SC-SGS/covid19-pooling | b207f5e6745c83b6c73425cda13ecc6afcffc96d | 45bd9f76f574c8a2d7b3b6b35c3ac7c9a0d890e5 | refs/heads/master | 2023-04-03T10:06:12.808711 | 2020-10-02T14:10:30 | 2020-10-02T14:10:30 | 257,044,793 | 4 | 2 | MIT | 2020-10-02T14:10:31 | 2020-04-19T16:15:00 | Python | UTF-8 | Python | false | false | 1,685 | py | #!/usr/bin/python3
import sys, pickle
if not len(sys.argv) > 1:
print("call {} pickle-filename".format(sys.argv[0]))
sys.exit()
fd = open(sys.argv[1], 'rb')
obj = pickle.load(fd)
#print(obj)
pop = obj['countries']['DE']['population']
print("population", pop)
print("group_size", obj['group_size'])
for (i, ... | [
"dirk.pflueger@ipvs.uni-stuttgart.de"
] | dirk.pflueger@ipvs.uni-stuttgart.de |
201876e67b8ad5ad3bd66fc64af0dad2b57933c0 | 58cea667b91271f8d61a70b3eff93ef56814d99a | /reviews/management/commands/seed_reviews.py | e272532f7cff2a4c5a217b7e836b2a4ff355055f | [] | no_license | BKLemontea/AirBnB_CloneCoding | 06e900d0c2f1735ebc539172569205956bab7b52 | b88f9bb6d1bca6a10cb48206872c0a392ce436bf | refs/heads/master | 2022-12-11T00:17:47.066796 | 2020-05-04T12:56:28 | 2020-05-04T12:56:28 | 235,279,197 | 0 | 0 | null | 2022-12-10T20:47:58 | 2020-01-21T07:21:38 | Python | UTF-8 | Python | false | false | 1,303 | py | import random
from django.core.management.base import BaseCommand
from django_seed import Seed
from reviews import models as review_models
from users import models as user_models
from rooms import models as room_models
class Command(BaseCommand):
help = "This comman creates reviews"
def add_arguments... | [
"jyf1128@naver.com"
] | jyf1128@naver.com |
c006e1156d478021f6f6c66e953083b4e8ae627a | da26a2635b9b5c560b90aff63affeecd164a1447 | /bioagents/databases/cbio_client.py | 82180f8f5fdf45e22643d072e35dbae2bf2f83e4 | [
"BSD-2-Clause"
] | permissive | il692221/bioagents | 6c80d314acccefabe7356b549975701a9137538e | 2af1e8a23a5a14fc2e4b527222c99bf44d20cdc3 | refs/heads/master | 2021-01-13T10:35:23.211045 | 2016-09-14T21:17:32 | 2016-09-14T21:17:32 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,721 | py | import urllib, urllib2
import pandas
import StringIO
cbio_url = 'http://www.cbioportal.org/webservice.do'
def send_request(data, skiprows=None):
'''
Sends a web service requrest to the cBio portal with arguments given in
the dictionary data and returns a Pandas data frame on success.
'''
data_str ... | [
"ben.gyori@gmail.com"
] | ben.gyori@gmail.com |
8fa5b5a54952951647d87d00d7b1fe9a3bdaabeb | 5672737d1ff34bebfeb408426e52ed49df8be3bb | /graphgallery/nn/layers/pyg/median.py | caf47d2b49b61dbfb53742d72ed2161af49d6003 | [
"MIT"
] | permissive | sailfish009/GraphGallery | 5063ee43340a6ca8da9f2d7fb3c44349e80321b2 | 4eec9c5136bda14809bd22584b26cc346cdb633b | refs/heads/master | 2023-08-24T19:19:59.714411 | 2021-10-16T10:10:40 | 2021-10-16T10:10:40 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,072 | py | from torch_geometric.typing import Adj, OptTensor
import torch
from torch import Tensor
from torch.nn import Parameter
from torch_geometric.nn.inits import zeros
from torch_geometric.nn.conv import MessagePassing
# This works for higher version of torch_gometric, e.g., 2.0.
# from torch_geometric.nn.dense.linear impo... | [
"cnljt@outlook.com"
] | cnljt@outlook.com |
3bd5f427e4dddba23957070bdb65a7f68436604d | 2e682fd72e3feaa70e3f7bf2a3b83c50d783ec02 | /PyTorch/built-in/cv/pose_estimation/HRNet_MMPose_for_PyTorch/configs/body/2d_kpt_sview_rgb_img/topdown_heatmap/aic/res101_aic_256x192.py | 5a774d92b3727542ef58318765e051fbd3d855ac | [
"Apache-2.0",
"BSD-2-Clause",
"MIT",
"BSD-3-Clause",
"LicenseRef-scancode-generic-cla",
"LicenseRef-scancode-unknown-license-reference",
"GPL-1.0-or-later"
] | permissive | Ascend/ModelZoo-PyTorch | 4c89414b9e2582cef9926d4670108a090c839d2d | 92acc188d3a0f634de58463b6676e70df83ef808 | refs/heads/master | 2023-07-19T12:40:00.512853 | 2023-07-17T02:48:18 | 2023-07-17T02:48:18 | 483,502,469 | 23 | 6 | Apache-2.0 | 2022-10-15T09:29:12 | 2022-04-20T04:11:18 | Python | UTF-8 | Python | false | false | 4,253 | py | _base_ = [
'../../../../_base_/default_runtime.py',
'../../../../_base_/datasets/aic.py'
]
evaluation = dict(interval=10, metric='mAP', save_best='AP')
optimizer = dict(
type='Adam',
lr=5e-4,
)
optimizer_config = dict(grad_clip=None)
# learning policy
lr_config = dict(
policy='step',
warmup='li... | [
"zhangjunyi8@huawei.com"
] | zhangjunyi8@huawei.com |
b94e2e47d6a1fa4cf5db0223dd6c4f69bade28a4 | 79301280362415425f93cac81583378344a5d3b5 | /kari/Problem/forms.py | cde6a37a36631ab0bacfc97e9cfc4f542d360535 | [] | no_license | Mr-Phoebe/BOJ-V3 | 4768cb7148683c3274949a8a662dc1300d82d4a2 | a2c867a8acce3f3fe137c0a8942663b9b76c0370 | refs/heads/master | 2020-12-30T22:11:47.181704 | 2017-01-31T12:49:10 | 2017-01-31T12:49:10 | 64,660,104 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,325 | py | # -*- coding: utf-8 -*-
from django import forms
from ckeditor.widgets import CKEditorWidget
class addProblemForm(forms.Form):
PROB_PRIV_CH = (
('private','只有自己可见'), #only the author may view and modify it outside the contest
('protected','所有教师可见'), #the admin with the same root as the a... | [
"whn289467822@outlook.com"
] | whn289467822@outlook.com |
1846eae92b6cb5da37e8c69d73fa687c622e1fc9 | a5a2abaf5c7a681ebea71b4034d7b12dbd750455 | /libretto/templatetags/admin_extras.py | f470495cda97898d38306fa5af1b8720eca71d75 | [
"BSD-3-Clause"
] | permissive | matinfo/dezede | e8be34a5b92f8e793a96396f7ec4ec880e7817ff | 829ba8c251a0301741460e6695438be52d04a2fc | refs/heads/master | 2020-03-15T11:25:56.786137 | 2018-04-23T13:47:20 | 2018-04-23T13:47:20 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 913 | py | # coding: utf-8
from __future__ import unicode_literals
from django.template import Library
register = Library()
@register.assignment_tag(takes_context=True)
def get_fieldsets_and_inlines(context):
adminform = context['adminform']
model_admin = adminform.model_admin
adminform = list(adminform)
inli... | [
"bordage.bertrand@gmail.com"
] | bordage.bertrand@gmail.com |
5862127c76de1c3a3d107b4bd70af80618158811 | de24f83a5e3768a2638ebcf13cbe717e75740168 | /moodledata/vpl_data/46/usersdata/97/18602/submittedfiles/funcoes1.py | 5082e4d1833b588f26a487dc75b054c38f821ec7 | [] | no_license | rafaelperazzo/programacao-web | 95643423a35c44613b0f64bed05bd34780fe2436 | 170dd5440afb9ee68a973f3de13a99aa4c735d79 | refs/heads/master | 2021-01-12T14:06:25.773146 | 2017-12-22T16:05:45 | 2017-12-22T16:05:45 | 69,566,344 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,490 | py | # -*- coding: utf-8 -*-
from __future__ import division
def crescente (lista):
cont=0
for i in range(0,len(lista)-1,1):
if lista[i]<lista[i+1]:
cont=cont+1
if cont==len(lista)-1:
return True
else:
return False
#escreva as demais funções
def decrescente ... | [
"rafael.mota@ufca.edu.br"
] | rafael.mota@ufca.edu.br |
1afa99d053f239689bca374b9faafde860565b5b | d3dcbda2c798f24b43bd35ecc8ea40b2e494e646 | /milu_test3/wsgi.py | e61d3cb0426ec2fb16bcd673da0c1076f6e361e4 | [] | no_license | milu-buet/milu_test3 | 48e560d778a61c44fadfacf2adcad3374797cdf6 | 09790d829fddd09cdf9fd9525c8b6829b58d67e5 | refs/heads/master | 2021-01-18T22:10:58.079326 | 2015-06-24T09:15:55 | 2015-06-24T09:15:55 | 19,772,796 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 395 | py | """
WSGI config for milu_test3 project.
It exposes the WSGI callable as a module-level variable named ``application``.
For more information on this file, see
https://docs.djangoproject.com/en/1.6/howto/deployment/wsgi/
"""
import os
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "milu_test3.settings")
from django.... | [
"milu.buet@gmail.com"
] | milu.buet@gmail.com |
0f205e0bf41e96d5d15f228580d31a70c0bb430d | 2a94426d5f1622e9ca7a0d52925c3689104d2ae8 | /didi/trials/slopes.py | 3c4396377eff454d8e42cd7df70005b42576cb5b | [] | no_license | senen2/aidd | 2d081fe4ae5dcd3e6b28c6a95f7e5421c7ac9ef4 | 38d38d71146230c4064c133aa1e6f3675adcfe57 | refs/heads/master | 2021-01-17T12:39:27.402420 | 2016-06-12T21:52:43 | 2016-06-12T21:52:43 | 59,596,808 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 349 | py | '''
Created on 29/05/2016
@author: botpi
'''
from apiDB import DB
from apiplots import *
db = DB("didi")
districts = db.escape_string("select district_id from districts order by district_id")
for district in districts:
district_id = district["district_id"]
rows =
d, s, g = getacum("diditest.gaps", distri... | [
"senenbotello@gmail.com"
] | senenbotello@gmail.com |
e28e8bd4585528cf59618152984004d224b54a7a | 9137e1ccf070b3f9d92d8635662c569639910ae5 | /apps/modules/post/apis/post.py | b51b167aa8e2ec57f5e335d1dd6a477fef1623af | [
"BSD-2-Clause"
] | permissive | zhangning123798/osroom | 08e87a4c32e9d92807a66109e7074723279179cc | 21859b77b8980ccb8a5392f02c76bd552b2bf653 | refs/heads/master | 2020-05-26T10:00:38.658768 | 2019-05-23T08:48:03 | 2019-05-23T08:48:03 | 188,195,911 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,738 | py | # -*-coding:utf-8-*-
from flask import request
from apps.core.flask.login_manager import osr_login_required
from apps.configs.sys_config import METHOD_WARNING
from apps.core.blueprint import api
from apps.core.flask.permission import permission_required
from apps.core.flask.response import response_format
from apps.mod... | [
"624393877@qq.com"
] | 624393877@qq.com |
d039a8978fd993570cb97aa1af2bb005c7356455 | c609730a43596a2d3303f072fc97d9cf681fac7b | /cagey/koubei_new/koubei_new/spiders/pauto_koubei_new.py | d4b60bb6b6886dd5fbd5959953927e0276aa3e6f | [] | no_license | sinnettluo/ChenProject | 5403311c0c7b78c484145e16d692abff00d2a110 | 0e33ecf1683afb22f1deb4bd54294c41aed8a46b | refs/heads/master | 2023-03-22T23:48:08.430178 | 2020-09-02T15:05:02 | 2020-09-02T15:05:02 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 8,047 | py | # -*- coding: utf-8 -*-
import scrapy
import re
import json
import time
from koubei_new.items import PautoKoubeiItem
# from scrapy.conf import settings
import logging
website = 'pauto_koubei_new'
class PautoKoubeiNewSpider(scrapy.Spider):
name = website
# start_urls = ['http://price.pcauto.com.cn/cars/']
... | [
"1316446041@qq.com"
] | 1316446041@qq.com |
9bf08bbf3fc4ec0b282289e3cba9ec370f95b235 | ac5e52a3fc52dde58d208746cddabef2e378119e | /exps-gsn-edf.0/gsn-edf_ut=3.5_rd=1_rw=0.04_rn=4_u=0.075-0.325_p=harmonic-2/sched=RUN_trial=53/params.py | 20c29a81a4d0e053a5aa98e47e89ee85e2affde5 | [] | no_license | ricardobtxr/experiment-scripts | 1e2abfcd94fb0ef5a56c5d7dffddfe814752eef1 | 7bcebff7ac2f2822423f211f1162cd017a18babb | refs/heads/master | 2023-04-09T02:37:41.466794 | 2021-04-25T03:27:16 | 2021-04-25T03:27:16 | 358,926,457 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 252 | py | {'cpus': 4,
'duration': 30,
'final_util': '3.633048',
'max_util': '3.5',
'periods': 'harmonic-2',
'release_master': False,
'res_distr': '1',
'res_nmb': '4',
'res_weight': '0.04',
'scheduler': 'GSN-EDF',
'trial': 53,
'utils': 'uni-medium-3'}
| [
"ricardo.btxr@gmail.com"
] | ricardo.btxr@gmail.com |
85a657ee67066d3829ef1f4d70d76d4d79992d48 | 360ae1188ad79e71ccc72da0b9ae709bda678f91 | /ryu/tests/unit/services/protocols/bgp/utils/test_bgp.py | 6933a28b322b9637308498993e887b9c2ba75940 | [
"Apache-2.0"
] | permissive | faucetsdn/ryu | 47b3523e7ccb381f3bdf2877a3f9f01cb1876054 | d6cda4f427ff8de82b94c58aa826824a106014c2 | refs/heads/master | 2023-09-05T06:37:21.991029 | 2022-06-09T23:09:40 | 2022-06-09T23:09:40 | 2,945,007 | 385 | 215 | Apache-2.0 | 2022-11-13T10:50:25 | 2011-12-09T03:43:50 | Python | UTF-8 | Python | false | false | 7,560 | py | # Copyright (C) 2017 Nippon Telegraph and Telephone Corporation.
#
# 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... | [
"fujita.tomonori@lab.ntt.co.jp"
] | fujita.tomonori@lab.ntt.co.jp |
fed8af3b4d8d9cb4601a4b6130ba078a5dfb5c08 | 9d43b8a3b53001f25a347fd96e5c49538b0c509a | /mxshop/apps/users/migrations/0003_auto_20180410_2357.py | 512358b77ce32d46e79285141221a1e54ecfc141 | [] | no_license | w8833531/mxfresh | b81b7e4223536c6bedb049009386015935d33987 | 46b83fafdae8450491344c531de81a45ab5d8aae | refs/heads/master | 2021-04-09T15:53:50.829921 | 2018-08-08T01:41:14 | 2018-08-08T01:41:14 | 125,793,036 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 492 | py | # -*- coding: utf-8 -*-
# Generated by Django 1.11.6 on 2018-04-10 15:57
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('users', '0002_auto_20180327_1651'),
]
operations = [
migrations.AlterField(... | [
"w8833531@hotmail.com"
] | w8833531@hotmail.com |
8fbab79cf6bcd4ddd77ee67c1065d550af479167 | b7dca2e137c16bc2583e11f9a0d231a63642b04c | /poradnia/letters/migrations/0012_letter_created_by_staff.py | f721e83240e5662d29b46c42ed9daffccddc16b6 | [
"MIT"
] | permissive | watchdogpolska/poradnia | 4ebc521e8ccfab0113d1a47cdf4469b758e90bdd | d679321a764218002e2c87ac71dd549208949b7e | refs/heads/master | 2023-08-16T20:29:31.720709 | 2023-04-28T18:50:09 | 2023-04-28T18:50:09 | 35,786,536 | 24 | 23 | MIT | 2023-07-13T06:59:38 | 2015-05-17T23:06:17 | JavaScript | UTF-8 | Python | false | false | 794 | py | # Generated by Django 2.2.25 on 2021-12-30 10:46
from django.db import migrations, models
def migrate_created_by_is_staff(apps, schema_editor):
User = apps.get_model("users", "User")
Letter = apps.get_model("letters", "Letter")
Letter.objects.filter(created_by__in=User.objects.filter(is_staff=True)).upda... | [
"noreply@github.com"
] | watchdogpolska.noreply@github.com |
e54df7386022a349ac90e60fc83e4fa094b46a7f | a690439837c0ead177d822fc7c9868dd35ec74b3 | /scripts/99_archiv/led_red.py | 2d257e30bb72c6347fb76b68400e5bf7f15e62ac | [] | no_license | rosorioc/john_doe | 470c5494d581613bb76d403083431e15d90ecd03 | 50d2ff84f390e41aeef73a2b2c38f372b93ab3c3 | refs/heads/master | 2021-01-19T03:59:45.512597 | 2017-05-05T15:28:51 | 2017-05-05T15:28:51 | 87,345,434 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 350 | py | import RPi.GPIO as GPIO
import time
# Set GPIO to Broadcom system and set RGB Pin numbers
RUNNING = True
GPIO.setmode(GPIO.BCM)
red = 17
green = 18
blue = 27
GPIO.setmode(GPIO.BCM)
GPIO.setwarnings(False)
color = red
GPIO.setup(color,GPIO.OUT)
print "LED on"
GPIO.output(color,GPIO.HIGH)
time.sleep(1)
print "LED off... | [
"you@example.com"
] | you@example.com |
eb0848a86c1d7c3f7d10119b5224f37b399011b1 | 1ebbc0af6be6956d3c4b30908893f4a558dedba4 | /tests/utils/test_to_years.py | 7d0f9426686b045da2742a903c0b36cf3d74983f | [
"MIT"
] | permissive | Cangar00/easyGalaxy | d724f6869168527f6f62274bdf981a2410c8de58 | 08570d28dbb796c5c0626e598dee12dfc29f16b8 | refs/heads/master | 2021-05-11T23:32:54.752850 | 2019-12-02T08:47:39 | 2019-12-02T08:47:39 | 117,512,634 | 1 | 0 | null | 2018-01-15T07:36:42 | 2018-01-15T07:36:42 | null | UTF-8 | Python | false | false | 1,714 | py | import unittest
import ezgal.utils as utils
import numpy as np
class test_to_years(unittest.TestCase):
def test_from_gyrs( self ):
self.assertEqual( utils.to_years( 20, units='gyrs' ), 2e10 )
def test_to_gyrs( self ):
self.assertEqual( utils.to_years( 2e10, units='gyrs', reverse=True ), 20 )
def test_from... | [
"cmancone@gmail.com"
] | cmancone@gmail.com |
2449660850bfb9f434f6430fe4c343e134ed488c | 5284521d6349b7c700d376ed278eeadf431991d2 | /Models/__init__.py | 21cf6b9c4994b3a65188e5fa29d2428c80a0e034 | [] | no_license | Frost199/movies-api | dc5a8f7f6bd5fe4bb27fce64bfc782444252ac3f | 23fca7c19863388bd5a5f1ad43dbd055ba4ea6f1 | refs/heads/develop | 2022-12-05T01:17:03.479114 | 2020-09-02T17:54:35 | 2020-09-02T17:54:35 | 291,629,065 | 0 | 0 | null | 2020-09-02T17:54:36 | 2020-08-31T06:04:52 | Python | UTF-8 | Python | false | false | 138 | py | """
importing models
"""
from .movies.movie import MovieModel
from .users.user import UserModel
from .users.tracking import TrackingModel
| [
"emmaldini12@gmail.com"
] | emmaldini12@gmail.com |
aecb25f15f893fb4a8c2910e18230a66010138c6 | 2d7c21a793c8080a090ce8c9f05df38f6477c7c7 | /creator/files/migrations/0006_increase_description_length.py | 1185713a68e150e6c87e1a7e28c649dcbceef5ae | [
"Apache-2.0"
] | permissive | kids-first/kf-api-study-creator | c40e0a8a514fd52a857e9a588635ef76d16d5bc7 | ba62b369e6464259ea92dbb9ba49876513f37fba | refs/heads/master | 2023-08-17T01:09:38.789364 | 2023-08-15T14:06:29 | 2023-08-15T14:06:29 | 149,347,812 | 3 | 0 | Apache-2.0 | 2023-09-08T15:33:40 | 2018-09-18T20:25:38 | Python | UTF-8 | Python | false | false | 431 | py | # Generated by Django 2.1.7 on 2019-05-22 15:50
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('files', '0005_dev_tokens_unique_name'),
]
operations = [
migrations.AlterField(
model_name='file',
name='description... | [
"dankolbman@gmail.com"
] | dankolbman@gmail.com |
258282b1dcbda1a70c333022d0884b9b0acab255 | c1bd12405d244c5924a4b069286cd9baf2c63895 | /azure-mgmt-datafactory/azure/mgmt/datafactory/models/databricks_notebook_activity.py | b23a8fc21092da09a0511e31904f272ba2983dc3 | [
"MIT"
] | permissive | lmazuel/azure-sdk-for-python | 972708ad5902778004680b142874582a284a8a7c | b40e0e36cc00a82b7f8ca2fa599b1928240c98b5 | refs/heads/master | 2022-08-16T02:32:14.070707 | 2018-03-29T17:16:15 | 2018-03-29T17:16:15 | 21,287,134 | 1 | 3 | MIT | 2019-10-25T15:56:00 | 2014-06-27T19:40:56 | Python | UTF-8 | Python | false | false | 3,147 | py | # coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes ... | [
"lmazuel@microsoft.com"
] | lmazuel@microsoft.com |
6e9d7b93d1d0447efaa3ed0cf9d95a576d774f84 | 868a66fc60f314dfdb8f434f88d2e8d7c2a6552c | /src/analytics/mixins.py | d620cac085ebe4b6d2e881a031c46f8e3c2bb5ea | [] | no_license | RommelTJ/ecommerce | cdd7a1323ff505b70363f6abc2ce9dff9f52b0a5 | 694dab843b0ca2d4c7cd3b671c3fdb69f063d14b | refs/heads/master | 2023-08-14T22:54:23.368159 | 2023-05-31T05:07:30 | 2023-05-31T05:07:30 | 118,721,454 | 0 | 0 | null | 2023-07-25T20:47:48 | 2018-01-24T06:17:34 | Python | UTF-8 | Python | false | false | 420 | py | from .signals import object_viewed_signal
class ObjectViewedMixin(object):
def get_context_data(self, *args, **kwargs):
context = super(ObjectViewedMixin, self).get_context_data(*args, **kwargs)
request = self.request
instance = context.get('object')
if instance:
objec... | [
"rommeltj@gmail.com"
] | rommeltj@gmail.com |
f764952056f8265b5c6061cd255a7de8782f210d | 729076ae3517dccae0c7d5a6eb74870398474d8b | /inventory/admin.py | cac48deb11b2cbbb869d384e69f89fd78ded0964 | [] | no_license | dhanya1/tourism_info_for_ucc | 9ee57170e01197004143c0716fd3fbb527bdcaee | d20df58209cde03191dc0efc9c12aa62b60a0f16 | refs/heads/master | 2021-05-11T00:50:21.215088 | 2018-01-23T12:31:29 | 2018-01-23T12:31:29 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 173 | py | from django.contrib import admin
from .models import Item
class ItemsDisplay(admin.ModelAdmin):
list_display = ['title','amount']
admin.site.register(Item, ItemsDisplay)
| [
"dhanyasj01@gmail.com"
] | dhanyasj01@gmail.com |
a4be53696beab65381dad2c995c8ecb9520fdda2 | 44cbc067afcced7fac7ad7f4584d0d16d66bf5b4 | /tests/playbook/test_num_blocks_error_handling__count.py | 3e3b583f851aeb1d870d25af40d1288ff29375df | [
"Apache-2.0"
] | permissive | ElsevierSoftwareX/SOFTX_2020_231 | fb75820e99dbd6f2380146ecf5b8893d69942260 | e3ad95ebdc324ae308669d437ec60bd726580102 | refs/heads/master | 2023-01-18T22:53:04.785576 | 2020-11-18T11:52:39 | 2020-11-18T11:52:39 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,766 | py | import pytest
from io import StringIO
from ansiblemetrics.playbook.num_blocks_error_handling import NumBlocksErrorHandling
#script_blocks_rescue/always
script_0_1 = '- name: disable the server in haproxy\n\tshell: echo "disable server myapplb/{{ inventory_hostname }}" | socat stdio /var/lib/haproxy/stats\n\tdelegate_t... | [
"stefano.dallapalma0@gmail.com"
] | stefano.dallapalma0@gmail.com |
cf6839b07b6bf6e3356ee136243cc3dc6ca0da33 | 2352bc07e12b0256913559cf3485a360569ccd5e | /Practice/code_class/Crossin-practices/python_weekly_question/purchase_equipment.py | c2581637482d8623740fa45a9a3d05dae530d335 | [] | no_license | Dis-count/Python_practice | 166ae563be7f6d99a12bdc0e221c550ef37bd4fd | fa0cae54e853157a1d2d78bf90408c68ce617c1a | refs/heads/master | 2022-12-12T03:38:24.091529 | 2021-12-22T09:51:59 | 2021-12-22T09:51:59 | 224,171,833 | 2 | 1 | null | 2022-12-08T05:29:38 | 2019-11-26T11:07:00 | Jupyter Notebook | UTF-8 | Python | false | false | 1,006 | py | #-*- coding:utf-8 -*-
import itertools
# 装满 6 格,金额小于 10000
equipment = [690,1500,2100,1740,2140,2080]
def func1():
conb = itertools.combinations_with_replacement(equipment,6)
count = 0
for i in conb:
if sum(i) < 10000:
count += 1
return count
print(func1())
# 没有格子的限制,
def func... | [
"492193947@qq.com"
] | 492193947@qq.com |
ef6dddf5f6c1bc9816abce8b946f3b15e663b1e5 | b909406a1f838b2bb9e8eca90fd1bdf412e67286 | /16.图片去重/new/work.py | f0f3b0ff6d5af1bad6a3ff60f99269b9545eea8f | [] | no_license | kaishuibaicai/mini-Python-Projects | 2f12a5349e389c73080443443fcd293aae04a521 | e18d8bbecb8baaa345720011e67789b123523457 | refs/heads/master | 2021-09-13T02:55:12.429216 | 2018-04-24T04:44:33 | 2018-04-24T04:44:33 | 104,319,805 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 646 | py | import os, hashlib
with open('C:\\Users\\Administrator\\Desktop\\mini-Python-Projects\\16.图片去重\\new\\output_file.txt') as of:
doneList = of.readlines()
def GetFileMd5(filename):
if not os.path.isfile(filename):
return
myhash = hashlib.md5()
f = open(filename, 'rb')
while True:
... | [
"272251416@qq.com"
] | 272251416@qq.com |
825eaa05bdbc5e3795fba349624e9eda51e474ea | ac53ed07a534db727e57714f5fdd07950d22c170 | /Django/rest_demo/rest_demo/settings.py | 0651cbbff704273b1253c22508ffbb700c5aa1b7 | [
"MIT"
] | permissive | taoyan/python | b8847911068083481e34567716710abaf5bbe4be | 3fbb1e534ec91b33cd2ac690966d7253c2f5d757 | refs/heads/master | 2022-12-11T17:15:59.411554 | 2019-10-28T03:50:31 | 2019-10-28T03:50:31 | 147,048,609 | 1 | 0 | MIT | 2022-12-10T14:53:29 | 2018-09-02T02:39:40 | Python | UTF-8 | Python | false | false | 3,366 | py | """
Django settings for rest_demo project.
Generated by 'django-admin startproject' using Django 1.11.11.
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... | [
"allen.t.yan@cn.pwc.com"
] | allen.t.yan@cn.pwc.com |
e949a72de998684721e14e3c6d57123502a12552 | 0c325cf7a68ef51067ed8db566d525a20de5b635 | /python/pyecharts_test/Overlap_多种类型图表混合.py | 507a93a90a4e1c25b841745466b729f351fa4c79 | [] | no_license | alinzel/NOTES | 2ab6aa1ef1d601a9ae8c0d23c0df2bca7e1aa241 | 3e0594641a605580e920d0b08a251fbc99f34e2f | refs/heads/master | 2023-01-08T22:48:30.762625 | 2020-01-17T09:14:47 | 2020-01-17T09:14:47 | 175,339,492 | 0 | 0 | null | 2022-12-27T15:01:19 | 2019-03-13T03:28:08 | HTML | UTF-8 | Python | false | false | 1,034 | py | from pyecharts import Line, Bar, Overlap
'''
多个x y轴示例
'''
attr = ["{}月".format(i) for i in range(1, 13)]
v1 = [2.0, 4.9, 7.0, 23.2, 25.6, 76.7, 135.6, 162.2, 32.6, 20.0, 6.4, 3.3]
v2 = [2.6, 5.9, 9.0, 26.4, 28.7, 70.7, 175.6, 182.2, 48.7, 18.8, 6.0, 2.3]
v3 = [2.0, 2.2, 3.3, 4.5, 6.3, 10.2, 20.3, 23.4, 23.0, 16.5... | [
"944951481@qq.com"
] | 944951481@qq.com |
5f4bbc9ad78b413265d2a76354f916de0f5f54f7 | 41ede4fd3bfba1bff0166bca7aee80dcf21434c6 | /suvari/gtk2chain/reverses2/docbook-xml/actions.py | 0eb217128c60c3b40a03802a205108fcfb1305a2 | [] | no_license | pisilinux/playground | a7db4b42559a21cc72fd4c8649e0231ab6a3eb3c | e4e12fff8a847ba210befc8db7e2af8556c3adf7 | refs/heads/master | 2022-08-12T23:03:27.609506 | 2022-08-11T18:28:19 | 2022-08-11T18:28:19 | 8,429,459 | 16 | 22 | null | 2022-08-11T18:28:20 | 2013-02-26T09:37:11 | Python | UTF-8 | Python | false | false | 699 | py | #!/usr/bin/python
# -*- coding: utf-8 -*-
#
# Licensed under the GNU General Public License, version 3.
# See the file http://www.gnu.org/licenses/gpl.txt
from pisi.actionsapi import pisitools
from pisi.actionsapi import get
WorkDir="."
def install():
for version in ["4.1.2", "4.2", "4.3", "4.4", "4.5"]:
... | [
"suvarice@gmail.com"
] | suvarice@gmail.com |
2da413e75900cc077d113770c888fd386ebd31a0 | 9f8b67a8edba916331cf11618482252d54cbd0ca | /spice/model/feature_modules/build_feature_module.py | edc974f209764f8f7a27e7a0c034f265fd921535 | [] | no_license | rahilgholami/SPICE | 64913669b0d2d2b4fa4edd474465d0acd576584c | ed2aa953ff58ea4c11cc1495bb84fb9e789bf6c1 | refs/heads/main | 2023-05-13T02:53:04.320565 | 2021-06-11T02:55:27 | 2021-06-11T02:55:27 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 755 | py | from .convnet import ConvNet
from .mlp import MLP
from .cluster_resnet import ClusterResNet
from .resnet_stl import resnet18
from .resnet_cifar import resnet18_cifar
from .imagenet import ImageNet
def build_feature_module(fea_cfg_ori):
fea_cfg = fea_cfg_ori.copy()
fea_type = fea_cfg.pop("type")
if fea_typ... | [
"niuchuangnn@gmail.com"
] | niuchuangnn@gmail.com |
20ad9b4f333626b39a0b0825ab84658d534aebc9 | 9c0803dece75055663e7c015a2a68f14d9a89e77 | /model.py | 48e739c9d2a3a25cc6e37aea208db5fc645b3a67 | [
"MIT"
] | permissive | Monologuethl/Unet-CT | e6e075d7bea61a3f42593222acaea54f80cf90dd | a05386df9c5471dee8a62adc42746ad22cece323 | refs/heads/master | 2020-05-31T05:31:07.912745 | 2019-08-01T06:02:31 | 2019-08-01T06:02:31 | 190,117,989 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,412 | py | from keras.models import *
from keras.layers import *
from keras.optimizers import *
def unet(pretrained_weights=None, input_size=(256, 256, 1)):
inputs = Input(input_size)
conv1 = Conv2D(64, 3, activation='relu', padding='same', kernel_initializer='he_normal')(inputs)
conv1 = Conv2D(64, 3, activation='... | [
"2481871325@qq.com"
] | 2481871325@qq.com |
9b94740efa5355b832c73162eb91d4c504ddb2e3 | 486fa0a987ab1648de91efeb4b7ba8be3dd6b016 | /tutorial/logging/example3.customlogging.py | 4cb422101b8809fa23475c68731d56ddaa68ebff | [
"MIT"
] | permissive | ceccopierangiolieugenio/pyTermTk | 9f5103d6af9e93fe2572b61486919020d2007550 | f9c2a4d97f2cd04f0b86cf10661f63a61edae48e | refs/heads/main | 2023-08-30T20:58:39.239718 | 2023-08-02T22:51:02 | 2023-08-02T22:51:02 | 339,475,110 | 414 | 16 | MIT | 2023-08-31T23:16:10 | 2021-02-16T17:23:36 | Python | UTF-8 | Python | false | false | 2,045 | py | #!/usr/bin/env python3
# MIT License
#
# Copyright (c) 2021 Eugenio Parodi <ceccopierangiolieugenio AT googlemail DOT com>
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restricti... | [
"ceccopierangiolieugenio@googlemail.com"
] | ceccopierangiolieugenio@googlemail.com |
e5ad40ff4a449186393a787417acd34b7e146946 | f07a42f652f46106dee4749277d41c302e2b7406 | /Data Set/bug-fixing-5/8e310cd82698fa88108ad51f708dc7cad56a3039-<test_lbfgs_regression_maxfun>-fix.py | 3f62f84a721baf489a76f15a35ab21504198ffa2 | [] | no_license | wsgan001/PyFPattern | e0fe06341cc5d51b3ad0fe29b84098d140ed54d1 | cc347e32745f99c0cd95e79a18ddacc4574d7faa | refs/heads/main | 2023-08-25T23:48:26.112133 | 2021-10-23T14:11:22 | 2021-10-23T14:11:22 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 498 | py | @pytest.mark.parametrize('X,y', regression_datasets)
def test_lbfgs_regression_maxfun(X, y):
max_fun = 10
for activation in ACTIVATION_TYPES:
mlp = MLPRegressor(solver='lbfgs', hidden_layer_sizes=50, max_iter=150, max_fun=max_fun, shuffle=True, random_state=1, activation=activation)
with pytest.... | [
"dg1732004@smail.nju.edu.cn"
] | dg1732004@smail.nju.edu.cn |
d3ce11921292012817cdccdb5be803b5e92be94a | d4108d0e9c128d325dda16d0df9225071c28aff3 | /dynamic_matrix_min_cost.py | d40c0a8c2572b4968563b33f98649f1da453ea93 | [] | no_license | joysn/recursion-dynamic-programing | 84d660a6849918fc0c4727ab81135a4af0383710 | 03047a20b8a4ce593b4b1df53de1b801a346cc53 | refs/heads/master | 2022-01-27T18:15:17.157009 | 2022-01-15T04:02:14 | 2022-01-15T04:02:14 | 229,208,134 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,594 | py | # Find the min cost to reach 2,3
# input = [[1,3,5,8],[4,2,1,7],[4,3,2,3]]
####################################
####### METHODICAL APPROACH ########
####################################
def min_cost_part(dr,dc):
r = 0
c = 0
if dr > dc:
max_iter = dr
else:
max_iter = dc
min_cost = input[r][c]
... | [
"noreply@github.com"
] | joysn.noreply@github.com |
21b264b929a94e56f59ee62558a6c00dc772cdab | c9bc27f70a4bca5ce6acf346bfc25b5407502d00 | /ATIVIDADE G - FÁBIO 2a - CONDICIONAIS/fabio2a_q15.py | 5ed31478716ff58e354483fe48747a1f4aaf89cc | [] | no_license | lucascoelho33/ifpi-ads-algoritmos2020 | 2197bbc84ce9c027b3f1da006728448a846d7ffb | 1ce20a489adbfe7321817acd98d35f2efc0360ca | refs/heads/master | 2021-03-01T23:03:10.293013 | 2020-10-17T14:35:19 | 2020-10-17T14:35:19 | 245,650,273 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 761 | py | #15. Leia a quantidade de horas aula dadas por dois professores e o valor por hora recebido por cada um.
#Escreva na tela qual dos professores tem salário total maior.
def main():
qtd_horas1 = int(input('Quantidade de horas: '))
valor_recebido1 = float(input('Valor recebido: R$ '))
qtd_horas2 = int(input(... | [
"llucascoelho33@gmail.com"
] | llucascoelho33@gmail.com |
3220a976b602aef170d7afcf54470de1cca8c864 | da8d96b52704a2a539b2116ae11935a0dede2526 | /notebook/str_re_split.py | 7f3fa25dad2be2d7a57b6fe745e40394bb3bfa12 | [
"MIT"
] | permissive | renzhongpiao/python-snippets | 8ee8969195008c824a4a24cb8cca22927893fbef | dfa9367d5aee09444ec71522c9dd6360c1226e34 | refs/heads/master | 2023-08-07T14:52:11.758582 | 2021-09-29T20:01:43 | 2021-09-29T20:01:43 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 390 | py | import re
s_nums = 'one1two22three333four'
print(re.split('\d+', s_nums))
# ['one', 'two', 'three', 'four']
print(re.split('\d+', s_nums, 2))
# ['one', 'two', 'three333four']
s_marks = 'one-two+three#four'
print(re.split('[-+#]', s_marks))
# ['one', 'two', 'three', 'four']
s_strs = 'oneXXXtwoYYYthreeZZZfour'
pri... | [
"nkmk.on@gmail.com"
] | nkmk.on@gmail.com |
0e26378a2f9e9de8d6eb209f8eca0ca954e3b740 | 5b7ae29242b4bb8cc9dfad217b0df5c16d31dc1f | /2069.py | 89c6d5a338b0e1a91a2e275d5f9b35dd4c3a552e | [] | no_license | voidsatisfaction/Baekjoon-Online-Judge | 63ba03bb27f99283e37245e196857c5dbf3d1d32 | 7fe9338e35f5df9d59bd04eb72d4310ff216b337 | refs/heads/master | 2021-01-11T10:27:58.039240 | 2020-07-26T10:30:12 | 2020-07-26T10:30:12 | 79,091,570 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 756 | py | def seg_area(seg):
return (seg["r"] - seg["l"])**2
MAX = 32768
n = int(raw_input())
temp = [0 for _ in xrange(MAX)]
segs = []
for _ in xrange(n):
l,r = map(int, raw_input().split(' '))
if r > temp[l]:
temp[l] = r
for l in xrange(MAX):
if (temp[l] == 0):
continue
segs.append({ "l": l, "r": temp[l] }... | [
"lourie@naver.com"
] | lourie@naver.com |
8b00a295f4f742507b7c40c348e17fe441e8c6f0 | ea9ecb3cf53b8c50e173d42f60a792c26bd6c5e6 | /ansible/roles/ooni-collector/templates/archive-to-renamed.py.j2 | d3648273bd4d4b952ffee84c74586d2ef8d93f57 | [] | no_license | ooni/sysadmin | 5b919d3220c2c449482d7f5f679162c3a5930cbf | 90f3ff2c8a1b90c187304c0d6d69c013ac3ed374 | refs/heads/master | 2023-08-30T06:25:47.976055 | 2023-08-18T12:42:38 | 2023-08-18T12:42:38 | 22,812,838 | 39 | 16 | null | 2023-06-23T13:45:55 | 2014-08-10T16:09:38 | Jinja | UTF-8 | Python | false | false | 5,711 | j2 | #!/usr/bin/python
import time
import os
import yaml
import json
import traceback
from datetime import datetime
ARCHIVE_DIR = '{{ collector_data_dir }}/archive'
RENAMED_DIR = '{{ collector_data_dir }}/renamed'
# Must contain three directories failed, empty, invalid
ERRORED_DIR = '{{ collector_data_dir }}/errored'
RENA... | [
"arturo@filasto.net"
] | arturo@filasto.net |
90931281b406b827cb5df5974eebfc49f00bd4b4 | 0c177bfa72101a125c5a3f0a6e4971ff115e3423 | /src/compas_plotters/artists/polylineartist.py | c2cd9e32a7d557983cb662738dc7aa96ef69f2e2 | [
"MIT"
] | permissive | swsglobal/compas | 3a41f65515e0bb5b34a007f6ba1ebf8aa9d1e889 | 75072d9fcc1e2d0565c69d892ed16ead29b0f04a | refs/heads/main | 2023-06-01T16:16:27.914314 | 2021-06-09T09:02:59 | 2021-06-09T09:02:59 | 375,402,789 | 0 | 0 | MIT | 2021-06-09T15:25:14 | 2021-06-09T15:25:13 | null | UTF-8 | Python | false | false | 1,205 | py | from compas_plotters.artists import Artist
from matplotlib.lines import Line2D
__all__ = ['PolylineArtist']
class PolylineArtist(Artist):
""""""
zorder = 1000
def __init__(self, polyline, draw_points=False, linewidth=1.0, linestyle='solid', color=(0, 0, 0)):
super(PolylineArtist, self).__init_... | [
"vanmelet@ethz.ch"
] | vanmelet@ethz.ch |
1026c1fc0aadbc05ed4d3c28fcc1bf451670b9ba | 6fcfb638fa725b6d21083ec54e3609fc1b287d9e | /python/ppwwyyxx_tensorpack/tensorpack-master/examples/A3C-Gym/run-atari.py | 04aeaa0bafcd67c6c78e86c87a4419740c78e6f0 | [] | no_license | LiuFang816/SALSTM_py_data | 6db258e51858aeff14af38898fef715b46980ac1 | d494b3041069d377d6a7a9c296a14334f2fa5acc | refs/heads/master | 2022-12-25T06:39:52.222097 | 2019-12-12T08:49:07 | 2019-12-12T08:49:07 | 227,546,525 | 10 | 7 | null | 2022-12-19T02:53:01 | 2019-12-12T07:29:39 | Python | UTF-8 | Python | false | false | 3,308 | py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
# File: run-atari.py
# Author: Yuxin Wu <ppwwyyxxc@gmail.com>
import numpy as np
import tensorflow as tf
import os
import sys
import re
import time
import random
import argparse
import six
import cv2
from tensorpack import *
from tensorpack.RL import *
from common import ... | [
"659338505@qq.com"
] | 659338505@qq.com |
5e4720573b732b95c21ba3e149fea2f7ac736aa8 | 1bf9f6b0ef85b6ccad8cb029703f89039f74cedc | /src/confluent/azext_confluent/generated/commands.py | e143a660d17a3f6680f7f192bb1d73813785f2d8 | [
"MIT",
"LicenseRef-scancode-generic-cla"
] | permissive | VSChina/azure-cli-extensions | a1f4bf2ea4dc1b507618617e299263ad45213add | 10b7bfef62cb080c74b1d59aadc4286bd9406841 | refs/heads/master | 2022-11-14T03:40:26.009692 | 2022-11-09T01:09:53 | 2022-11-09T01:09:53 | 199,810,654 | 4 | 2 | MIT | 2020-07-13T05:51:27 | 2019-07-31T08:10:50 | Python | UTF-8 | Python | false | false | 2,182 | py | # --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incor... | [
"noreply@github.com"
] | VSChina.noreply@github.com |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.