blob_id stringlengths 40 40 | directory_id stringlengths 40 40 | path stringlengths 3 281 | content_id stringlengths 40 40 | detected_licenses listlengths 0 57 | license_type stringclasses 2
values | repo_name stringlengths 6 116 | snapshot_id stringlengths 40 40 | revision_id stringlengths 40 40 | branch_name stringclasses 313
values | visit_date timestamp[us] | revision_date timestamp[us] | committer_date timestamp[us] | github_id int64 18.2k 668M ⌀ | star_events_count int64 0 102k | fork_events_count int64 0 38.2k | gha_license_id stringclasses 17
values | gha_event_created_at timestamp[us] | gha_created_at timestamp[us] | gha_language stringclasses 107
values | src_encoding stringclasses 20
values | language stringclasses 1
value | is_vendor bool 2
classes | is_generated bool 2
classes | length_bytes int64 4 6.02M | extension stringclasses 78
values | content stringlengths 2 6.02M | authors listlengths 1 1 | author stringlengths 0 175 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0038e8bb52dc6ebb2349f86f36abea352f53deb8 | f92a525a2c91b12d0bd710ce40e44312324a5bd4 | /code/sandpit/echostate.py | 958c2e482c3ec2ee82add7842fad429151f5f54f | [] | no_license | dhuppenkothen/BlackHoleMagic | 735f71ef9120157a912d0d7b78a5fbbc37bcb36b | 17f353fe3fc9eaa5a2083b578ce141a4fedbc80e | refs/heads/master | 2021-01-17T18:08:44.507248 | 2016-11-22T21:03:44 | 2016-11-22T21:03:44 | 27,083,555 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,448 | py | ### This is an attempt at making an echo state network work"
## Some naming conventions (following Giannotis+ 2015)
## y: time series points at time t
## t: times at which the time series is measured
## N: number of hidden units
## v: input weights, of dimension Nx1
## x: hidden units, of length N (could be changed?)
... | [
"daniela.huppenkothen@nyu.edu"
] | daniela.huppenkothen@nyu.edu |
095083917773966edc0c2b1a6e709c702b1053f9 | 3469703501c75c7190c4d8c1f7529561df2448ba | /example/wallet/get_sub_account_transfer_history.py | 42c33b4acae9e169fd0df11390e8cdae8b91103b | [] | no_license | AbigalChulchill/binance-api-python | b5c745e98b5b4ab9873a7b4aaa8708bf9cf24496 | 544bbc152dd7accd0ac4f13faa7d254382c79e77 | refs/heads/master | 2022-04-20T18:03:31.889472 | 2019-12-20T14:21:12 | 2019-12-20T14:21:12 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 567 | py | from binance import RequestClient
from binance.constant.test import *
from binance.base.printobject import *
request_client = RequestClient(api_key=g_api_key, secret_key=g_secret_key)
sub_account_transfer_history = request_client.get_sub_account_transfer_history(email = "123@test.com",
startTime = None, endTim... | [
"heartbeat0415@yahoo.com"
] | heartbeat0415@yahoo.com |
599f1e8a2cfd0f500544975c8f34cebd3ba01126 | 3fdd9e2f5663c6b07420ff0047e20aa1d4dec0e9 | /uim/codec/writer/encoder/base.py | 4e8c0bc737fcc8fdaaf8c40c63558a5bc29fd7e2 | [
"Apache-2.0"
] | permissive | erdoukki/universal-ink-library | 39150814e1a11a5f15e7e66491784563e28e6de8 | 689ed90e09e912b8fc9ac249984df43a7b59aa59 | refs/heads/main | 2023-08-05T02:22:11.142863 | 2021-08-20T10:12:06 | 2021-08-20T10:12:06 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,034 | py | # -*- coding: utf-8 -*-
# Copyright © 2021 Wacom 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
#
# Unle... | [
"github@wacom.com"
] | github@wacom.com |
50ed8118fb1bb5a1f76605c49a03b902855585eb | 519f0b5308941e693d4768101225b75dbd34a14b | /chemoinformatics/molecule_web_database/_settings.py | 29cdc61edc89e91159f5cf52ee400dc153c31ad9 | [
"MIT"
] | permissive | gorgitko/bioinformatics-chemoinformatics | a3a5502f6b4c8e311098ada2fe1794b2d49af86d | b780783abe8ee7ccda88f92eacf1232c2456d046 | refs/heads/master | 2021-01-17T14:45:41.452341 | 2016-10-19T18:26:16 | 2016-10-19T18:26:16 | 55,147,152 | 4 | 1 | null | null | null | null | UTF-8 | Python | false | false | 4,539 | py | """
Django settings for molinf project.
Generated by 'django-admin startproject' using Django 1.9.2.
For more information on this file, see
https://docs.djangoproject.com/en/1.9/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/1.9/ref/settings/
"""
import os
# ... | [
"fg-42@seznam.cz"
] | fg-42@seznam.cz |
935e63a0c03212250310cdaa61a4e52029199dfb | 09d53368fcc2bb6deedeff7119385f1faeaf81df | /sentence_completion_by_HMM.py | 7199db4fee205e16c710190c9002bf927c567c8e | [] | no_license | Jverma/text-mining | e9372377526939919d743c5d9facc932d8bf0753 | 3af668076ae08dccad6368808bde080906e8edcf | refs/heads/master | 2020-06-08T05:32:07.358236 | 2013-12-03T04:17:28 | 2013-12-03T04:17:28 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,857 | py | """
A bigram langauge model for completing a sentence using Hidden Markov Methods.
Author : Janu Verma
http://www.math.ksu.edu/~jv291/
Twitter : @januverma
"""
import re
from collections import *
import random
import sys
########## Load the Data #########
"""
The data is a collections of text documents or a corpu... | [
"j.verma5@gmail.com"
] | j.verma5@gmail.com |
34040fa92ecd404a88488ce57826c60fb30b8f6a | b5e76345cc260960c032e690a9cc47099632af63 | /perceptron_example.py | 4a7d356d5b0990ef7d658e4633ea570d97e49e62 | [] | no_license | zgmartin/neural | 33213b5853faff1748ed5d28aad9d401c0e9428b | 300c97d948e2575729eedc3f28a97eca7f1cffc0 | refs/heads/master | 2020-04-16T00:17:18.052055 | 2015-05-04T17:35:24 | 2015-05-04T17:35:24 | 35,048,594 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 675 | py | """
Line perception test.
"""
import random
import neural
import numpy
from matplotlib import pyplot
def f(x):
return x
def is_above(x,y,f):
if y>f(x): return 1
else: return -1
test_set = []
for n in range(2000):
x = random.uniform(-10,10)
y = random.uniform(-10,10)
test_set.append([x,y,is_... | [
"zacharygilmartin@gmail.com"
] | zacharygilmartin@gmail.com |
c704cdb44596a02fbd9574844e661fb5a2ace221 | f5e46c48fc69b04abd3ef0d65f6a9d58273ae333 | /ClassifierTester.py | b218e5d4964f88a398e8c40c5df2afb254d947fd | [] | no_license | karthikmit/toy-chatbot | 3bdb330004bd5c74d7cde3c81cc9eea9224234f0 | 0aa6ec7d643f44903a7f83e406e9b43019b1ff48 | refs/heads/master | 2021-05-07T08:07:33.870013 | 2017-11-03T12:05:47 | 2017-11-03T12:05:47 | 109,254,069 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,654 | py | #ClassifierTester.py
import Classifier
import WordEmbedding
classifier = Classifier.IntentClassifier(WordEmbedding.WordEmbedding("./model.txt"))
data={
"greet": {
"examples" : ["hello","hey there","howdy","hello","hi","hey","hey ho"]
},
"pnr_status_query": {
"examples":[
"What is my pnr status 24... | [
"Karthikeyan.Subbaraj@go-mmt.com"
] | Karthikeyan.Subbaraj@go-mmt.com |
86c61de680717bd8e991c6ec92cababcefa73682 | 285888aa3c2252e7ac61137e57d5ffd5c7fe50b2 | /bookMng/migrations/0020_delete_cart.py | 1f8605f7abadb1ccc55b916b11a52fb6ff65a650 | [] | no_license | JeffreyLum/bookEx | 7c1d4c8fcdaf09914dff579858ba862ef94d3e10 | 031c00bb5a58b86c8ed05fd4e8e04642ef724586 | refs/heads/main | 2023-04-20T08:32:39.263747 | 2021-05-14T03:56:32 | 2021-05-14T03:56:32 | 333,901,258 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 279 | py | # Generated by Django 3.1.5 on 2021-05-04 20:43
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('bookMng', '0019_cart'),
]
operations = [
migrations.DeleteModel(
name='Cart',
),
]
| [
"jeffreylum81@gmail.com"
] | jeffreylum81@gmail.com |
4469aadcb30debab4a9987e742fc570b91900f7f | c2f8356fb3afdbbdfac5631b8d4df9ef0785e10f | /tap_appointment_plus/test/test_unit.py | c1638b196e51f9b83e4e0b1dcd13d5db782c0528 | [] | no_license | isabella232/tap-appointment-plus | f92c82ec06e5ba2162c87ff4c80cb4e48d14df8f | 2826a3ae3d3a26a5d768770a0a089c231dcd27bf | refs/heads/master | 2022-06-17T04:20:02.518208 | 2017-08-14T14:37:55 | 2017-08-14T14:37:55 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,298 | py | import unittest
import voluptuous
import tap_appointment_plus
import tap_appointment_plus.config
def generate_config():
return {
'site_id': 'abc',
'api_key': 'def',
'start_date': '2017-01-01T00:00:00Z',
'user_agent': 'test <test@fishtownanalytics.com>'
}
class TestUnit(unitt... | [
"cmcarthur@rjmetrics.com"
] | cmcarthur@rjmetrics.com |
6507617a5996b2599eeb66af63027b8ce92d7271 | eddd6e1ef8354f9a89bd9c63c27b6cb444bb98e9 | /tool/utils.py | ce589cc87812e68fddf75d59933620d797d9b352 | [] | no_license | chiekubo/FaceDetection1 | dbb917e8846fe72e60b48f31cec4e4b3a3ff141e | 42761188a526c9cbd50058ad3a7a582d8b682d18 | refs/heads/master | 2022-08-01T21:26:52.141932 | 2020-05-29T14:51:02 | 2020-05-29T14:51:02 | 267,883,087 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,036 | py | import numpy as np
def iou(box, boxes, isMin = False):
box_area = (box[2] - box[0]) * (box[3] - box[1])
area = (boxes[:, 2] - boxes[:, 0]) * (boxes[:, 3] - boxes[:, 1])
xx1 = np.maximum(box[0], boxes[:, 0])
yy1 = np.maximum(box[1], boxes[:, 1])
xx2 = np.minimum(box[2], boxes[:, 2])
yy2 = np.mi... | [
"807940470@qq.com"
] | 807940470@qq.com |
f84892a21094cad7f80bd823cb6494e6bc1bbe17 | 033beb1ecf6dd347a4fe608ef33a2a224776ef69 | /object_learn/object_save_one.py | 69c0aeb900ea1e1ff56dae771d60419ec3704a1b | [
"MIT"
] | permissive | MojaX2/vision_module | b9ab9a87af8b3e29a0cc84cb8dad05b998b56d7f | 607bbcc9a799c47ac2cd6d142d68d0d47a457e36 | refs/heads/master | 2020-04-01T19:36:14.039736 | 2018-10-24T15:42:25 | 2018-10-24T15:42:25 | 153,562,271 | 0 | 0 | null | 2018-10-18T04:10:57 | 2018-10-18T04:10:57 | null | UTF-8 | Python | false | false | 4,290 | py | import argparse
import os
import sys
import shutil
import rospy
import numpy as np
from PIL import Image
from tqdm import *
import cv2
from vision_module.msg import ObjectInfo
NUM_TO_SAVE = 1000
class SaveTrainImage():
def __init__(self, folder, num_to_save, image_id, obj_id):
self.save_id = int(image_i... | [
"zawa0319@gmail.com"
] | zawa0319@gmail.com |
37b40e5f9f9835752e00832a3f9b1efc8166a281 | a8547f73463eef517b98d1085430732f442c856e | /numpy/core/tests/test_longdouble.py | 9f4b9eddeecd2c0ffee07713482ebfef2b9e5381 | [] | no_license | EnjoyLifeFund/macHighSierra-py36-pkgs | 63aece1b692225ee2fbb865200279d7ef88a1eca | 5668b5785296b314ea1321057420bcd077dba9ea | refs/heads/master | 2021-01-23T19:13:04.707152 | 2017-12-25T17:41:30 | 2017-12-25T17:41:30 | 102,808,884 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 101 | py | ../../../../../../Cellar/numpy/1.13.3/lib/python3.6/site-packages/numpy/core/tests/test_longdouble.py | [
"Raliclo@gmail.com"
] | Raliclo@gmail.com |
fcf943c9a12f68cdbce93984752dc88ce47547dc | 3fa4a77e75738d00835dcca1c47d4b99d371b2d8 | /backend/telegram/models/chats/admin_log_event/admin_log_event_action_toggle_admin.py | 8cc707026c5b98d6b7ea0b8a0ae05a57598b13b7 | [
"Apache-2.0"
] | permissive | appheap/social-media-analyzer | 1711f415fcd094bff94ac4f009a7a8546f53196f | 0f9da098bfb0b4f9eb38e0244aa3a168cf97d51c | refs/heads/master | 2023-06-24T02:13:45.150791 | 2021-07-22T07:32:40 | 2021-07-22T07:32:40 | 287,000,778 | 5 | 3 | null | null | null | null | UTF-8 | Python | false | false | 2,080 | py | from typing import Optional
from django.db import models, DatabaseError
from telegram import models as tg_models
from core.globals import logger
from ...base import BaseModel
class AdminLogEventActionToggleAdminQuerySet(models.QuerySet):
def update_or_create_action(self, **kwargs) -> Optional['AdminLogEventActi... | [
"taleb.zarhesh@gmail.com"
] | taleb.zarhesh@gmail.com |
7ec6988b240e9685e8a4607ea508bba1012032bf | ccbe4b62d42fc599adac870c1fdf67366f8bcbad | /lossFuncs.py | 9744b1643c551277375a5b622394e04d665e3a84 | [] | no_license | dogasiyli-boun/keyhandshapediscovery | 17b940c95cd2761fed2c98b9b84f4c4bcc96b19d | 782d66c5bc5213b6ebff3bf16cd14251251efa9b | refs/heads/master | 2023-04-21T10:19:15.898091 | 2021-04-25T21:39:03 | 2021-04-25T21:39:03 | 326,433,973 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 521 | py | from keras import backend as K
def neg_l2_reg(activation):
return -weight_of_regularizer*K.mean(K.square(activation))
def neg_l2_reg2(activation, weight_of_regularizer):
return -weight_of_regularizer*(K.square(activation))
def penalized_loss(l2_val):
def loss(y_true, y_pred):
return K.mean(K.squa... | [
"dogasiyli@gmail.com"
] | dogasiyli@gmail.com |
f6e07d300711214276c1a08dc5305787c2e16965 | aacf985c4cd9d87822e0a2bd82cadc1da5e0d11c | /jyaang_robinliu106/old scripts/fetchHospital.py | 7d3f6f48fbd68aeba137c909aee16794a7385238 | [] | no_license | robinliu106/Project-2-jyaang_robinliu106 | 8d5d5fb49d3d825ee301687a056911b1c336f4ed | f443ea96599349ecbb4e676d430d2f0473a184df | refs/heads/master | 2020-12-24T11:37:21.013880 | 2016-11-14T01:45:43 | 2016-11-14T01:45:43 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,039 | py | #filename: fetchHospitals.py
import json
import urllib.request #request the JSON url
import datetime
import pymongo
#import dml
#from pymongo import MongoClient
#client = MongoClient('localhost',27017)
#set up mongodb connection
#client = dml.pymongo.MongoClient()
#repo = client.Response
#repo.authenticate("")
sta... | [
"noreply@github.com"
] | noreply@github.com |
15b0120a6df7223e01d2f3afa3879e7993d63438 | 174f848b62fb2ea0a1605e1aab70085ffd27ce50 | /beginning/age.py | 0540185272594c22e444e0b66ab14903a4e2d11f | [] | no_license | unet-echelon/by_of_python_lesson | cd71bd3890d42d49cc128ec1730371bf1b64dbfa | c6c5c917414ac98b6dfb582dc06c26d31ea5b30c | refs/heads/master | 2021-07-11T07:16:20.243347 | 2020-09-14T12:39:13 | 2020-09-14T12:39:13 | 201,041,106 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 191 | py | #!/usr/bin/env python3
age = 26
name = 'kernel'
print('Возраст {0} -- {1} лет'.format(name,age))
print('Почему {0} забаляэеться с этим Python?'.format(name)) | [
"aleguk@ukr.net"
] | aleguk@ukr.net |
82790cca6a6af7a174000f534c965d3708078922 | dc8cf6cdb7e41e049bcd962d25455a9761657a5f | /20mathFn.py | 98c7331cf54db3ab25e94dd7a82fdc95cf77b913 | [] | no_license | Shaheryarsaleem/Python-Demo | 88b13b4c7344eddbbf037360e9c5f5c8943fcb0a | 210ad599708415b90aeb27242c8c3bd461a28c14 | refs/heads/master | 2021-05-19T15:51:41.907176 | 2020-03-31T23:11:58 | 2020-03-31T23:11:58 | 251,951,067 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 166 | py | from math import *
number = 4.6
print(floor(number))
print(ceil(number))
number = -3.8
print(round(number))
print(abs(number))
print(min(7,2.1))
print(max(7,2.1))
| [
"shaheryarsaleem1@gmail.com"
] | shaheryarsaleem1@gmail.com |
8c2567a4b784ce24de31ec9eec73b66c17516a2d | d07a63ddd41f88ddb31ae451bde35cdda29ee98e | /coordinate_transformation/functions/domain.py | 82089535df4494d64af0c46249aef981e9dafad7 | [] | no_license | krisjuune/pre-post-noisi | 81f9f845f0b1e7a77646550df2769e80d28e242a | ab04f2e35a96ae142d1cc77cd1afc55181e4f2a1 | refs/heads/master | 2023-02-21T08:02:15.732731 | 2020-05-27T11:43:34 | 2020-05-27T11:43:34 | 223,137,623 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,482 | py | from pathlib import Path
import netCDF4 as nc4
import numpy as np
import numpy.ma as ma
def find_nearest(array, value):
"""
Find index of the element in a one-dimensional array
nearest to the value specified.
"""
array = np.asarray(array)
indx = (np.abs(array - value)).argmin()
return indx... | [
"kristiina.joon@gmail.com"
] | kristiina.joon@gmail.com |
3b909fb21f16eefae1b403bb3b13881e9ebbdbf1 | f56a439ecf33d713b3cafb1513cd28e02b11ee54 | /homework20_11_2019/Main.py | 24dd32191f0766e3893da8c803e23a7abcbba98e | [] | no_license | ElenaGavrilovaMMF/Python-Homework | 3348e417a9a3c3a849df2c84e9055b183f23c3c3 | be57d6b95dd6fedaef1975114755b24bc2e8945f | refs/heads/master | 2020-09-11T01:29:24.091372 | 2019-11-21T16:53:55 | 2019-11-21T16:53:55 | 221,895,089 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,834 | py | import random
import ActionBook
import ImportLibrary
library = ImportLibrary.createLibrary()
# Количество посетителей в библиотеке
userCount = random.randint(1, 5)
# Работа пользователя
userNumber = 1
while userCount != 0:
print("Посетитель номер ", userNumber)
userFunctionality = random.randin... | [
"noreply@github.com"
] | noreply@github.com |
174381d9dbc5ca6653d670f4e06be4f0bf6322c7 | 781e2692049e87a4256320c76e82a19be257a05d | /all_data/exercism_data/python/atbash-cipher/b9b8b95767434aa0871b2c8be48c53bd.py | f0b099a7bd55fe14b4e43829323d85f729c01d42 | [] | no_license | itsolutionscorp/AutoStyle-Clustering | 54bde86fe6dbad35b568b38cfcb14c5ffaab51b0 | be0e2f635a7558f56c61bc0b36c6146b01d1e6e6 | refs/heads/master | 2020-12-11T07:27:19.291038 | 2016-03-16T03:18:00 | 2016-03-16T03:18:42 | 59,454,921 | 4 | 0 | null | 2016-05-23T05:40:56 | 2016-05-23T05:40:56 | null | UTF-8 | Python | false | false | 486 | py | from string import ascii_lowercase, digits, maketrans, translate, whitespace, punctuation
def xcode(text, space=None):
xlate = maketrans(ascii_lowercase + digits, ascii_lowercase[::-1] + digits)
out = translate(text.lower(), xlate, whitespace + punctuation)
if space:
tmp = ""
for i in rang... | [
"rrc@berkeley.edu"
] | rrc@berkeley.edu |
a0a745860debb68c77f7b93110de4c23aa4f70ae | 5c87690a2ef17e204456224e6388d64b2f20ab12 | /test/functional/wallet_import_rescan.py | 9700ec41a880bfc9d5fd36c57927e9fb86ee178c | [
"MIT"
] | permissive | durgeshkmr/Libra-Coin | aee161b81315c9a8163170db370136b09def6712 | c40293ac5c8f289e4c06b46d0c7f3ca76ff591a6 | refs/heads/master | 2020-06-09T02:18:53.830023 | 2019-06-23T14:02:57 | 2019-06-23T14:02:57 | 193,351,213 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 9,624 | py | #!/usr/bin/env python3
# Copyright (c) 2014-2018 The Libra Core developers
# Distributed under the MIT software license, see the accompanying
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
"""Test wallet import RPCs.
Test rescan behavior of importaddress, importpubkey, importprivkey, and
importm... | [
"durgeshkmr4u@gmail.com"
] | durgeshkmr4u@gmail.com |
f6078be3422fecd7716db41f29450c62290212b6 | 6bf5526a561d825d89ee9f1b739221a2b32d1cb7 | /leads/migrations/0004_lead_organization.py | c735baac3f406923c25722abdb282b61df882bcc | [] | no_license | fdelacruz/djcrm | bac994d939da776fff8fe70c763743f6b7bd3bbb | 16e0c339e3b1e1e37c1c48c34c58b7263203f01d | refs/heads/main | 2023-07-06T21:19:39.561097 | 2021-08-11T21:24:24 | 2021-08-11T21:24:24 | 391,398,994 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 521 | py | # Generated by Django 3.1.4 on 2021-08-02 02:12
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('leads', '0003_auto_20210801_2057'),
]
operations = [
migrations.AddField(
model_name='lead',
... | [
"helloquico@gmail.com"
] | helloquico@gmail.com |
16608f71543a2fe1d5b8b46899fd4afec3deff67 | 4104ef21c5383458ef0005179b77f582ae87844c | /web/migrations/0009_auto_20150728_1334.py | 9321d918ca4040ea4a21f263470e94b1ce9fb7e9 | [] | no_license | kodiers/quests | 8580d4cacd5685e08989f28fc6825117b17ea146 | 006bfbd354c75f6baeac020112cf36adcee9b016 | refs/heads/master | 2021-01-18T22:25:00.676362 | 2016-05-23T23:08:18 | 2016-05-23T23:08:18 | 37,993,239 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,497 | py | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
from django.conf import settings
class Migration(migrations.Migration):
dependencies = [
('web', '0008_organizers_show_on_main_page'),
]
operations = [
migrations.CreateModel(
... | [
"kodiers@gmail.com"
] | kodiers@gmail.com |
f818b6399f525cc1aa9a6badce808a7bf8216776 | 717e6aeb996ff3b78f623c35d16b0cb64d9c83f4 | /A_Pyecharts/bar/Learn2.py | ff4841b777b6e412133a2b04ba44ba70ae05e767 | [] | no_license | yanghuizhi/Pyecharts_Learn_YHZ | 61297747207ceecb9d74915499f8cd028eefcd52 | 8e6b580df7224f2f98c715d36b122452453ad3fc | refs/heads/master | 2021-03-25T17:45:08.090987 | 2020-03-30T07:16:27 | 2020-03-30T07:16:27 | 247,636,939 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,022 | py | # !/usr/bin/env python
# -*- coding: utf-8 -*-
# Author: yanghuizhi
# Time: 2020/3/15 12:42 下午
from pyecharts.charts import Bar
import pyecharts.options as opts
from pyecharts.commons.utils import JsCode
from pyecharts.faker import Faker
from pyecharts.globals import ThemeType
"""
pyecharts Bar 主要配置学习
"""
... | [
"347818169@qq.com"
] | 347818169@qq.com |
4ccc6cc3eecf18aac8437a276cf90f38ab1eeac1 | 838c763669c3a889c6a7fd82b6a3904f446b09c1 | /reader.py | d45880f3c8be16a36b10146551de420feccfe41f | [
"MIT"
] | permissive | adamdempsey90/cinnamon | 0d569949bcf09161a70b685805e0dc8dc7ee7629 | baf9d62c52f77e717f987e37981451c69ce1a0b5 | refs/heads/master | 2021-08-19T04:54:24.809545 | 2020-04-19T18:00:37 | 2020-04-19T18:00:37 | 166,311,605 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 11,238 | py | import h5py
import numpy as np
import matplotlib.pyplot as plt
import matplotlib.colors as colors
class Sim():
def __init__(self,num,base='test_',with_ghost=False,dims=2):
with h5py.File(base + str(num) + '.h5','r') as file:
f = file['/Data']
self.time = float(f['time'][...])
... | [
"adamdemps@gmail.com"
] | adamdemps@gmail.com |
73938db0d5ed5dc6e4c025daa028c93ba6f042ef | bff30e238a322a390a35fffc3a0e44210c3e7436 | /Motor_Sarah.py | 301fd7112cf1aaa24eba54205120217bae9dd0af | [] | no_license | Timothysit/swc_invivo_analysis | 8dc00ca255d231ca8a2a1a1ca6716988c4966e4b | ae8eeeef802a95aac081a6d6d15cedc6a7044c44 | refs/heads/master | 2020-03-30T19:56:44.054399 | 2018-10-05T14:42:21 | 2018-10-05T14:42:21 | 151,566,481 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,335 | py |
#Analysis of motor movement
#Input is csv file (motorFile) out put is also csv file
#MotorFile = pd.read_csv('studentCourse_command.csv')
import pandas as pd
import numpy as np
# making a mini dataframe with fake data
# fake_motor_data = {'command':[0,10,15,-5,-10,-15,0], 'time':[0,1,2,3,4,5,6]}
# motor_df = pd.Data... | [
"saraholesen@hotmail.com"
] | saraholesen@hotmail.com |
e6e5336ab077801216fea9feeba853f708c60dda | 77e1db762bd012e0447b8275df6e24012a3aa82f | /android-unlock-patterns/android-unlock-patterns.py | 3633050be42eecf7bd09c207660bb66f41a5212c | [] | no_license | PigsGoMoo/LeetCode | 1e9d37507b04a238347bcc693e9be3d24313a46e | a5c9bc433ac6c54bebb83b9640273216512f41b8 | refs/heads/main | 2023-06-28T12:58:57.516464 | 2021-08-03T19:49:07 | 2021-08-03T19:49:07 | 362,915,227 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,516 | py | class Solution:
def __init__(self):
# We'll make our map of variables that are skipped
# We access it by using self.skip[x][y] where x and y are the numbers we're connecting.
self.skip = [[0] * 10 for _ in range(10)]
# Now set the values
self.skip[1][3] = self.s... | [
"33019839+PigsGoMoo@users.noreply.github.com"
] | 33019839+PigsGoMoo@users.noreply.github.com |
8e1cc89b07d89b78e4641642cd8d6beed7f2f9d7 | 1df24101037f5dd88fd756acabad52d3cb005960 | /manage.py | 42312add1dfebbd3c874160abb428ef4b6c144b3 | [] | no_license | Caiseyann/CodeWars_API | 9324cb0b627ba93407baa66729ac0da0ce690be6 | dfdee24a84ab5cc06d9c4bac95189a8038312689 | refs/heads/master | 2022-12-18T20:36:18.762783 | 2020-10-02T06:52:23 | 2020-10-02T06:52:23 | 299,637,614 | 0 | 0 | null | 2020-09-29T14:10:26 | 2020-09-29T14:10:25 | null | UTF-8 | Python | false | false | 656 | py | from app import create_app,db
from flask_script import Manager,Server
from app.models import User
from flask_migrate import Migrate, MigrateCommand
# Creating app instance
app = create_app('development')
manager = Manager(app)
migrate = Migrate(app,db)
manager.add_command('server',Server)
manager.add_command('db',... | [
"msyokimutua@gmail.com"
] | msyokimutua@gmail.com |
62b4bf8f303857f60e9a27468b20de57f71a6cc0 | 7a923ba531688401d023e299116109ebff4a40cc | /GuessingGame.py | 969f590aeaf5e8e2d22da2d22327e5c119f9ea81 | [] | no_license | artoyebi/pythontask3 | 248962c2fa6e404abc789378882f7c376b47b351 | 8bf964f8078dc0519eff56548ef0cce86dd4857f | refs/heads/master | 2022-04-22T09:35:19.761182 | 2020-04-19T03:44:57 | 2020-04-19T03:44:57 | 256,905,960 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,964 | py | import random
def randint(mini,maxi):
secretNumber=random.randint(mini,maxi)
return secretNumber
print("Number Guessing Game")
level=input("Please Choose Between Difficulty Level 1-3: ")
if level=="1":
print("Difficulty Level 1\nGuess A Number Between 1 and 10")
guess_count=0
guess_... | [
"61976986+artoyebi@users.noreply.github.com"
] | 61976986+artoyebi@users.noreply.github.com |
861ed03b50fc4b4ecb334880a08e25954ec6486a | be8d396b1622e7a765865a5e6046588229b62089 | /model/test_currency.py | 269f0710f80c292119be7afe286be2852d14fe21 | [
"Apache-2.0"
] | permissive | nimakaviani/demo-crypto-bot | 68983d799e50b646f3ac3d47ea8c963264acf34b | 59d61cdec675a038d7c0c46f71893a145df59b97 | refs/heads/master | 2021-08-31T22:39:58.752507 | 2017-12-17T07:49:41 | 2017-12-23T06:07:57 | 114,571,875 | 2 | 1 | null | null | null | null | UTF-8 | Python | false | false | 213 | py | import pytest
@pytest.fixture
def currency():
from model.account import Currency
return Currency("test-currency", 10)
def test_update(currency):
currency.update(15)
assert currency.value == 25
| [
"nkavian@us.ibm.com"
] | nkavian@us.ibm.com |
dc73cf6e9989804e2dc0f3c2877e0fff14501cb2 | ca7aa979e7059467e158830b76673f5b77a0f5a3 | /Python_codes/p02851/s504076203.py | 4b1b8ee55fac378d844e2fa9052da7b00644e874 | [] | 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 | 1,688 | py | def getN():
return int(input())
def getNM():
return map(int, input().split())
def getList():
return list(map(int, input().split()))
def getArray(intn):
return [int(input()) for i in range(intn)]
def input():
return sys.stdin.readline().rstrip()
def rand_N(ran1, ran2):
return random.randint(ran1,... | [
"66529651+Aastha2104@users.noreply.github.com"
] | 66529651+Aastha2104@users.noreply.github.com |
9f08b88ac5f5532156b9eae0a46fa0324b93ce00 | 3dd946915cdef29f7043c151deebc68200e3075c | /taxi/settings.py | cfa1e334cf53b1d657ea920ecf8f7697933080e8 | [] | no_license | PierceAndy/rpc-taxi-booking-sim | a3926bdf52b7f0130fe9bbe4a5ba3cd72fc30256 | 1cb1331d03e56f3cae19240662f6042fa3d2ea26 | refs/heads/master | 2021-06-19T05:49:09.490511 | 2019-06-01T08:29:09 | 2019-06-01T08:33:53 | 129,953,917 | 0 | 0 | null | 2021-06-10T20:26:33 | 2018-04-17T19:19:10 | Python | UTF-8 | Python | false | false | 1,166 | py | """
Django settings for taxi project.
Generated by 'django-admin startproject' using Django 2.0.3.
"""
import os
BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
# Quick-start development settings - unsuitable for production
# See https://docs.djangoproject.com/en/2.0/howto/deployment/checklis... | [
"pierceanderson.fu+github@gmail.com"
] | pierceanderson.fu+github@gmail.com |
39d76c5ac93ca62d22d8102da6ae57b798a0abc1 | 41b59a9c8381fa3a92f5d2c37c91261afb9c82c4 | /QCDEventShape/2017/MC/test/Run_QCD_test_76x_data_cfg.py | a70d898a68603a21318aca5063817cdfeee12de7 | [] | no_license | Sumankkundu/ChargedParticle | c6d4f90b55df49321df2ecd758bb1f39db896f8c | eb5bada24b37a58ded186d6e5d2d7bd00898fefe | refs/heads/master | 2023-07-15T03:34:33.377203 | 2021-08-31T05:01:32 | 2021-08-31T05:01:32 | 231,091,587 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,329 | py | import FWCore.ParameterSet.Config as cms
process = cms.Process("Test")
## switch to uncheduled mode
#process.options.allowUnscheduled = cms.untracked.bool(True)
#process.Tracer = cms.Service("Tracer")
process.load("PhysicsTools.PatAlgos.producersLayer1.patCandidates_cff")
process.load("PhysicsTools.PatAlgos.selectio... | [
"skundu91phys@gmail.com"
] | skundu91phys@gmail.com |
a4764a0a2e167cbde191dc1e9237743b359681a0 | a151cb067175a2e262fcee632e28382344a4fe07 | /support/proxyControl.py | 33aecfec2d243303baf2e4a467649b520c1964bd | [
"Apache-2.0"
] | permissive | mspieth/hdhr_browser_recorder | 9d92c15b1bc884da480a53b926dbea11efa229dd | 46c2af1dffe3d2ca8f505f97db57e97a3e9d711c | refs/heads/master | 2021-06-21T06:50:10.856287 | 2019-12-22T23:10:43 | 2019-12-22T23:10:43 | 194,482,825 | 1 | 0 | Apache-2.0 | 2021-06-11T17:56:55 | 2019-06-30T06:24:11 | Python | UTF-8 | Python | false | false | 14,328 | py | from io import BytesIO
import os
import socket
import struct
import asyncio
from contextlib import suppress
from . import crc32c
import logging
logger = logging.getLogger(__name__)
HDHOMERUN_DISCOVER_UDP_PORT = 65001
HDHOMERUN_CONTROL_TCP_PORT = 65001
HDHOMERUN_MAX_PACKET_SIZE = 1460
HDHOMERUN_MAX_PAYLOAD_SIZE = 14... | [
"mspieth@digivation.com.au"
] | mspieth@digivation.com.au |
b273a522405da407d7497a6ed50c640a6b3b2718 | 435a186432a75738f2f50e23376e88939cf483eb | /examine_plugin.py | 786af0cc202637b572f397b79b3ce4e380a0602c | [] | no_license | dwink/gst-examples | 1f5f3fc3ae571175b233b7748af6c036ad1394d8 | 1d0e29056442bb8d1b6584f03cbf09bdb286d688 | refs/heads/master | 2021-03-12T20:27:14.358893 | 2014-06-06T12:00:31 | 2014-06-06T12:00:31 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 868 | py | #!/usr/bin/env python3
# Examine a Plugin
import gi
gi.require_version("Gst", "1.0")
from gi.repository import Gst
Gst.init(None)
def main():
print("Using Gst: {}.{}.{}.{}".format(*Gst.version()))
registry = Gst.Registry.get()
playback = registry.find_plugin("playback")
if playback is not None:
... | [
"dave@dwink.net"
] | dave@dwink.net |
3313cca37c36ff5633dd7b08a512e1906a874299 | ac73eca2536edba153903328a2d0be7479f2d396 | /reverse.py | 780fb3839e87668b021a31b342cb336f43c4e21f | [] | no_license | fcamilalima/exercicios-python | cf7e63e8734172258da0efd4a330a1f2e4ecdb06 | eb32bd6b6e3e98a025804076af1348593826486b | refs/heads/main | 2023-07-31T06:30:22.558663 | 2021-09-30T23:50:02 | 2021-09-30T23:50:02 | 410,785,335 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 152 | py | def reverse(filename):
f =open(filename).read().split('\n')
g=f[::-1]
for i in g:
print(i)
return g
reverse('she.txt')
| [
"noreply@github.com"
] | noreply@github.com |
967aae2c9b64081141856dee77e6af6a40952980 | d637643039a2bdb97aef3485be24c6fc9bdc7177 | /RpiArduinoCommunication/RPiArduino/readSerialData.py | 9786df6cd2696e9fd0c5cfaddd787b210ab4b18a | [] | no_license | BusraOzer/InternetofThingsExamples | d3a437ca45112bbe05555c168aee596ffb714138 | b4857cc33db86b68140a5dfc24551f3c185734de | refs/heads/master | 2021-06-21T02:33:50.411855 | 2017-08-14T19:05:29 | 2017-08-14T19:05:29 | 100,300,236 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 198 | py | import serial
#Arduino'nun dosya yolu ve 9600 bps
#Eger bu dosya yolunu ogrenmek istiyorsaniz ls /dev/tty* i kullanabilirsiniz
ser=serial.Serial('/dev/ttyUSB0',9600)
while 1:
print(ser.readline())
| [
"busraozer.64@gmail.com"
] | busraozer.64@gmail.com |
0c8cb171fb64ea11da3f0d44dcaede3ef4a1c947 | 3f8f0ea5b5bbf2e6b0d569db078200d07b4f3b10 | /DjangoApp/anubis/models.py | 5ada46652cce7ae02e237a8dd6f37b513812fe62 | [] | no_license | Lsmuel/ETEtapa1_SamuelHurtado_007D | 8a401a3797eafc4743eaed9f0a5ded4fa0dbeba1 | e0df2df933caf5b277fac9d29ba0d1a4f4280784 | refs/heads/main | 2023-06-26T11:04:44.731804 | 2021-07-06T21:50:11 | 2021-07-06T21:50:11 | 381,492,965 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 747 | py | from django.db import models
# Create your models here.
class Colaboradores(models.Model):
rut = models.CharField(primary_key=True, max_length=10, verbose_name='rut')
image = models.ImageField(upload_to='images/', null=True, blank = True)
nombreComp = models.CharField(max_length=40, verbose_name='Nombre co... | [
"aamacanitan@gmail.com"
] | aamacanitan@gmail.com |
93989c16fa5b859400d6592f55c2c95cc9606f81 | 723a064ec3e0273e30ccab9b1a3c8acb58aa7b45 | /beat/Descarga.py | 55a7c9a05fab77fad362070bcf78feb528fef7ee | [] | no_license | jorge11696/7.-CELERY-PYTHON | c3a3131b12a442b7847c691ebaf7eba06db67232 | 904eebe5bf3957d0f9c6158818fda382259cbc73 | refs/heads/master | 2022-12-06T06:20:27.371703 | 2020-08-15T11:06:25 | 2020-08-15T11:06:25 | 287,726,655 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,612 | py | from celery import Celery
from celery.schedules import crontab
from bs4 import BeautifulSoup
from urllib.request import Request, urlopen
import pprint
import json
import re
dl = Celery()
pp = pprint.PrettyPrinter(indent=4)
@dl.on_after_configure.connect
def setup_periodic_tasks(sender, **kwargs):
sender.add_peri... | [
"jorgewebempresa@gmail.com"
] | jorgewebempresa@gmail.com |
1d056c81396c0deb5c63b84b521470c9728e0747 | ce0e9c993482fcb4f20a9151a15a43864ffcf02e | /wtformsexer/venv/bin/easy_install | 957a86eb4257b9abe8fa8cc6bcb155150312634b | [] | no_license | apandora-seertech/pythonexer | e95c5b89b0e8ecb1239236c1bfdd73083b6f5253 | 75bcaafe79e699bc881375cd1a2c5192f3509d0d | refs/heads/master | 2021-05-29T19:57:09.281328 | 2015-10-23T14:57:36 | 2015-10-23T14:57:36 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 282 | #!/Users/andrewandora/flasktraining/wtformstraining/venv/bin/python
# -*- coding: utf-8 -*-
import re
import sys
from setuptools.command.easy_install import main
if __name__ == '__main__':
sys.argv[0] = re.sub(r'(-script\.pyw|\.exe)?$', '', sys.argv[0])
sys.exit(main())
| [
"andrew.andora@seer-technologies.com"
] | andrew.andora@seer-technologies.com | |
12e7a08649d0b1c145f0beb96fbbc6ffee75a2d7 | 7f68e9cabee3d78cd9b312d6cc701a30e4a6b1c0 | /QODE/Applications/component_tests/test-Lanczos/degenerate-case/testLanczos.py | e42495363a706af58055316f6ca4fa9bbcccfc6c | [] | no_license | sskhan67/GPGPU-Programming- | b855ea4255d7917972e0bb25d3b262ae14b574ea | 9daa6ede30c8753ea7d4feb4b06bcc802578af53 | refs/heads/master | 2022-07-03T12:35:52.984388 | 2020-05-12T04:49:32 | 2020-05-12T04:49:32 | 256,408,543 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,591 | py | # (C) Copyright 2018 Anthony D. Dutoi
#
# This file is part of Qode.
#
# Qode is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any late... | [
"sayedkhan@dhcp-10-11-207-87.wireless.pacific.edu"
] | sayedkhan@dhcp-10-11-207-87.wireless.pacific.edu |
ffffee1166d50a0e214b19fc1af993b35be523e3 | b6739df812fbc321812310277407f6d90f1de8e7 | /Session2/SVM_with_sklearn.py | b6736252ed01b46d373b3dc900075dfd02a174b4 | [] | no_license | SonDuongHUST/DSLab_Training | eacb22511c47869c9c9ac44aa1624d6114dd5696 | 48cb4ef1ce009120b03e9fd53a0d70726f07f2b1 | refs/heads/master | 2022-09-26T17:24:53.021873 | 2020-06-09T07:25:09 | 2020-06-09T07:25:09 | 257,641,048 | 0 | 0 | null | 2020-04-22T00:17:51 | 2020-04-21T15:42:05 | Python | UTF-8 | Python | false | false | 1,732 | py |
import numpy as np
from sklearn.svm import LinearSVC
def load_data(path):
def sparse_to_dense(sparse_r_d, vocab_size):
r_d = [0.0 for i in range(vocab_size)]
ind_tfidf = sparse_r_d.split()
for index_tfidf in ind_tfidf:
index = int(index_tfidf.split(":")[0])
tfidf =... | [
"duonghongson1999@gmail.com"
] | duonghongson1999@gmail.com |
a9826ba4a43ea9f0095b716f50ec0537f5ef5130 | c7ca46fd2c84cb82ff270144de9565c104858484 | /src/borg/testsuite/benchmark.py | 1e70a101f2f92f9f5b88df7fc86c0ef881bc6f88 | [
"BSD-3-Clause",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | aeveris/borg | 07f232124bf72034ecbd6162f0eb1ac731f37bc1 | 4041bdf1690c1988557827b5af80a9ebb760139c | refs/heads/master | 2023-02-14T21:31:43.134214 | 2021-01-11T15:51:49 | 2021-01-11T15:51:49 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,863 | py | """
Do benchmarks using pytest-benchmark.
Usage:
py.test --benchmark-only
"""
import os
import pytest
from .archiver import changedir, cmd
@pytest.fixture
def repo_url(request, tmpdir, monkeypatch):
monkeypatch.setenv('BORG_PASSPHRASE', '123456')
monkeypatch.setenv('BORG_CHECK_I_KNOW_WHAT_I_AM_DOING'... | [
"tw@waldmann-edv.de"
] | tw@waldmann-edv.de |
19f120d58d3c87b2f9b24e49df5aa497f9961c58 | 11addfaa34cf33a50cdc2cc9616fd17e62337c87 | /support/scripts/w2adoc.py | 876edfa1debacbc8c0913fddcca866bf43594b4f | [] | no_license | sergey-yurchenko/BIK-App-Test | 27d5aeac9eff6591ca260ac8cec248592babdc35 | d3752d3a20695ac69a06b59ed9224f01bfb0134f | refs/heads/master | 2023-06-24T18:30:26.862307 | 2021-07-16T09:42:01 | 2021-07-16T09:42:01 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 717 | py | import os, sys
import subprocess
from typing import List
params = ""
cwd = os.getcwd()
file_list = os.listdir(cwd)
tdir = "adoc"
print("test")
for filename in file_list:
print(filename)
if filename.endswith(".docx"):
file_path = '"'+os.sep.join([cwd, filename])+'"'
adoc_path = '"'+os.sep.join([t... | [
"helms@dias.de"
] | helms@dias.de |
11dfab65b6124613750e7a9b42287f134b836d34 | 3c748e18e4955bf50f7f487d8733eb51cc0d18f8 | /jobscraper/bin/pip3.7 | af5e4a932993c427fb769f175329634d0506f073 | [
"MIT"
] | permissive | pyrish/scrapers | d1bf12d6fc1eb010278dc3b631afe51712e14f57 | c1f4e82dc7a054dfcd81d047406f78dd60b363b1 | refs/heads/master | 2021-04-15T14:00:20.132728 | 2019-10-06T05:32:46 | 2019-10-06T05:32:46 | 126,647,389 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 253 | 7 | #!/Users/mariano/Desktop/scrapers/jobscraper/bin/python3
# -*- coding: utf-8 -*-
import re
import sys
from pip._internal import main
if __name__ == '__main__':
sys.argv[0] = re.sub(r'(-script\.pyw?|\.exe)?$', '', sys.argv[0])
sys.exit(main())
| [
"mariano.vazquez@live.com"
] | mariano.vazquez@live.com |
37f2a774f750224dc8e9aa45726c5e4d43d15a98 | 78cb6dadc7599e01b078682b175f21be673ed199 | /289. Game of Life.py | 8f9a3ce969e8b1a9a93adcdce1c8c56a5b245d10 | [] | no_license | AlexWufan/leetcode-python | 5cf5f13dbc7d1e425fde646df618e50c488fa79f | 435323a9fcea6a4d09266785e88fb78735e0cc3e | refs/heads/master | 2021-01-13T00:49:49.870468 | 2018-04-13T18:44:19 | 2018-04-13T18:44:19 | 51,347,271 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 205 | py | class Solution(object):
def gameOfLife(self, board):
"""
:type board: List[List[int]]
:rtype: void Do not return anything, modify board in-place instead.
"""
tbc | [
"mengnanszw@gmail.com"
] | mengnanszw@gmail.com |
bb3d996477ea3256b3518ad93eab79a70b2c47b7 | b8de48551cbadf1738f3eafeb738b80dbcfc4494 | /students/jjakub/lessons/lesson05/assignment/database.py | eb7a6eb2f1b38f347d204479fb034ccbed6fad20 | [] | no_license | UWPCE-PythonCert-ClassRepos/py220BV201901 | 41a6d4a73109ca4b5b22675972397e7445e6b8bd | 23ceab6bcb0b9f086d72dfad9b021ac0b53095e8 | refs/heads/master | 2020-04-15T19:22:48.976024 | 2019-03-18T14:16:23 | 2019-03-18T14:16:23 | 164,947,759 | 0 | 6 | null | 2019-03-18T14:16:24 | 2019-01-09T22:25:01 | Python | UTF-8 | Python | false | false | 5,133 | py | # Database
# pylint: disable=too-many-locals
""""
Module to handle database operations
"""
import csv
import datetime
import logging
import sys
from pathlib import Path
from pymongo import MongoClient
MONGO = MongoClient(host='127.0.0.1', port=27017)
DB = MONGO['HPN_database']
PRDCT = DB["product"]
CUST = DB["custom... | [
"Jason.Jakubiak@t-mobile.com"
] | Jason.Jakubiak@t-mobile.com |
093eb01cb9bf4ae11cfb9818c5f70388bfd695f6 | 7bd4b4559ff802e3d7025023b71ea8e3820f906d | /download_free_PTtorrents_v2_debug_py2.py | a42c521b48863beccd3fa9e8e5a42368910472fd | [] | no_license | monokoo/ptscripts | 27da300cd6c4142f001bd5405966b90f0be64d37 | 0cce42dcd88689767b2abb83eef57f944192cdb6 | refs/heads/master | 2020-05-25T19:16:08.503194 | 2019-05-13T07:06:07 | 2019-05-13T07:06:07 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,807 | py | import bs4
import requests
import re
import os
# Complete the variables below:
# Some examples:
#site_name = "M-TEAM"
#site_url = "https://tp.m-team.cc/torrents.php"
#site_cookie = "c_lang_folder=cht; tp=I2ODOGYNDFmZDdhYWGI2ODU3ZDA1ZU3ZDAYxNDFmZDdhYWRhZmRlOA%3D%3D"
#url_half = "https://tp.m-team.cc/download.php?id="
... | [
"csx921124@gmail.com"
] | csx921124@gmail.com |
aab84e3b0cfa096c303cef34bb53750dc3f1ee59 | 618acf7dbdbadfd277530fdf028b08352037ab0d | /train_at.py | 684b8f66a3386c32c694b377abbf81df7e33569a | [] | no_license | lilujunai/Knowledge-Distillation-Zoo | cbf9e71778dbbb7dd977c5d8ec5ce347b7c291f8 | b7bce273d9ee85331a75f5423d7b65c8834b04df | refs/heads/master | 2020-12-11T21:13:00.838982 | 2019-02-16T09:06:14 | 2019-02-16T09:06:14 | 233,961,529 | 0 | 1 | null | 2020-01-15T00:12:48 | 2020-01-15T00:12:47 | null | UTF-8 | Python | false | false | 8,895 | py | from __future__ import print_function
import torch
import torch.nn as nn
import torch.nn.functional as F
import torch.backends.cudnn as cudnn
import torchvision.transforms as transforms
import torchvision.datasets as dst
import argparse
import os
import time
from util import AverageMeter, accuracy, transform_time
fro... | [
"huyibo871079699@163.com"
] | huyibo871079699@163.com |
ac9c78bb4e9952ff2ffcdc6feeb5a0e862a80e4b | 43a506c479f6a63c2bca2065db9f1febf890764c | /code/3/nums.py | d664655c0d7a984dc0ede630eb26025d4999b778 | [] | no_license | gui-rangel/fss16gui | de49d99a97b94519813d8f2e801e19ed80235023 | 44485a2e3c616304f9456dbba021d4a111be802a | refs/heads/master | 2020-11-28T16:38:11.381105 | 2016-12-08T17:27:43 | 2016-12-08T17:27:43 | 65,944,194 | 0 | 2 | null | null | null | null | UTF-8 | Python | false | false | 947 | py | def max(x,y) : return x if x>y else y
def min(x,y) : return x if x<y else y
class Num:
def __init__(i,name):
i.mu,i.n,i.m2,i.up,i.lo,i.name,i.pos = 0,0,0,-10e32,10e32,name,0
def add(i,x,count):
i.n += 1
x = float(x)
if x > i.up: i.up=x
if x < i.lo: i.lo=x
delta = x - i.mu
i.mu += delta/... | [
"guilherangel@hotmail.com"
] | guilherangel@hotmail.com |
d5415f607dd31adae279661a33d4bee445418136 | 76084379c92ba50a7dd273072c828e1fb886ac66 | /s3iotools/io/dataframe.py | 23a9451c51516f2e9c1369c1b027ddbd284b631c | [
"MIT"
] | permissive | MacHu-GWU/s3iotools-project | 19a08698b3f41fdb165a5df266860afdfe82d10e | 6e8a12d30792464c6ffa13cfb105578aed9f67da | refs/heads/master | 2020-04-25T18:05:13.116604 | 2019-05-20T13:00:02 | 2019-05-20T13:00:02 | 172,972,132 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 7,796 | py | # -*- coding: utf-8 -*-
"""
s3 IO tools.
"""
import attr
import pandas as pd
from six import string_types, StringIO, BytesIO, PY3
from ..compat import gzip_compress, gzip_decompress
@attr.s
class S3Dataframe(object):
"""
S3 object backed pandas DataFrame.
"""
s3_resource = attr.ib(default=None)
... | [
"husanhe@gmail.com"
] | husanhe@gmail.com |
716e24f833117790ab5298a92011c308a6ea8355 | 56be7f6b6a1243c532af9ea98310ccea165a1e66 | /day18/课件/day18mysite/app01/migrations/0002_publisher.py | fe58096c46afa0d01cbc643d0689ddf1f3992ce0 | [] | no_license | 214031230/Python21 | 55b0405ec4ad186b052cde7ebfb3f4bb636a3f30 | d7fc68d3d23345df5bfb09d4a84686c8b49a5ad7 | refs/heads/master | 2021-05-26T06:00:53.393577 | 2019-01-09T02:29:04 | 2019-01-09T02:29:04 | 127,778,172 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 569 | py | # -*- coding: utf-8 -*-
# Generated by Django 1.11.11 on 2018-08-19 04:19
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('app01', '0001_initial'),
]
operations = [
migrations.CreateModel(
... | [
"21403123@qq.com"
] | 21403123@qq.com |
fd9ff5a0d7cc102326adcbb8f214243b7df59c30 | 6bb599997d835672dc50c06ce59a517076835e35 | /cvety/admin.py | aec3dfb8cdc0fa8a13b81037369cd73339302a91 | [] | no_license | lookonkz/svadba | 3f5e8cae894b5d0391d669e85058ee670ec3577e | ba7407d1a17bd92a6e3bf873f3223e47fe1d27aa | refs/heads/master | 2021-09-06T04:33:44.867624 | 2018-02-02T10:55:29 | 2018-02-02T10:55:29 | 119,970,505 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 193 | py | from django.contrib import admin
from .models import Cvety
# Register your models here.
@admin.register(Cvety)
class AdminCvety(admin.ModelAdmin):
list_display = ["name", "id", "price"]
| [
"user1@iMac-user1.local"
] | user1@iMac-user1.local |
282fb2a3fc530178816655ec27adeb0f02038d26 | f81e953240152d3ee6f09b121d1afd3b2c6c21c5 | /setup.py | cae21648e4cfcfd5116a37e8246eafa0ada5d545 | [] | permissive | rasca/django-cuit | 0d9c54556d37f252fe5d899447803cbdcbf12926 | 94ccaad1ff2a1c17f82bbb734c48f94b3f022727 | refs/heads/master | 2021-05-16T03:00:36.884341 | 2019-01-03T00:43:13 | 2019-01-03T00:43:13 | 1,658,060 | 2 | 3 | BSD-3-Clause | 2019-01-03T00:43:14 | 2011-04-24T23:24:46 | Python | UTF-8 | Python | false | false | 458 | py | from distutils.core import setup
setup(
name='django-cuit',
version='0.1.dev',
author='Ivan Raskovsky (rasca)',
author_email='raskovsky@gmail.com',
packages=['cuit',],
license='BSD',
description='django app for verification of Argentinian AFIP CUITs',
long_description=open('README.rst')... | [
"raskovsky+git@gmail.com"
] | raskovsky+git@gmail.com |
95ac8d6e1cd48ef413e647eba9db8996cf4f9756 | 204ec78fcebcea9e1e1da4905cf3fad0a514b01f | /pyocd/commands/commander.py | dda3def7d561c8cd2b153987fadbdc9bd23fe83c | [
"Apache-2.0"
] | permissive | ARMmbed/pyOCD | 659340bf8753aa8e15a72890b8bea64dff2c2f42 | d4cdcf7e532cae17caad866839287bbe1e0d952b | refs/heads/master | 2023-05-31T13:45:15.797588 | 2020-10-12T13:55:47 | 2020-10-12T13:55:47 | 190,203,829 | 3 | 1 | Apache-2.0 | 2019-07-05T11:05:40 | 2019-06-04T13:09:56 | Python | UTF-8 | Python | false | false | 8,726 | py | # pyOCD debugger
# Copyright (c) 2015-2020 Arm Limited
# SPDX-License-Identifier: Apache-2.0
#
# 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... | [
"flit@me.com"
] | flit@me.com |
ffc316b832df3622880682ce1b1a0180196bb06f | 07006aa772d01e9099c0be3c0932e282ee209716 | /env/bin/django-admin | 53e0b21381ede57ca3cb9d67e77578718cd3533f | [] | no_license | trankmichael/merv | a1c80b26210ca653a70db3800c86e4be6ceb96d6 | a5bfdb83e5c0115f9dde4407b96a7a609873fd17 | refs/heads/master | 2021-01-16T02:27:22.218861 | 2016-05-13T23:58:46 | 2016-05-13T23:58:46 | 56,453,284 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 286 | #!/home/mumbosauce/merv/env/bin/python
# -*- coding: utf-8 -*-
import re
import sys
from django.core.management import execute_from_command_line
if __name__ == '__main__':
sys.argv[0] = re.sub(r'(-script\.pyw|\.exe)?$', '', sys.argv[0])
sys.exit(execute_from_command_line())
| [
"trankmichael@gmail.com"
] | trankmichael@gmail.com | |
fde1300aaf4414e664e6205cc6827f757613ff87 | 60f446736d8866350a52e0921c4bcbb265797780 | /util/mq.py | 768656c3ef5388569dc4af8c7a779fe5408f8179 | [] | no_license | yaeSakura/guest_sign | 9932dc6d1ea365ac273c4117c0a62e1d6d520723 | 5aaea0213f1b7951f71d3dfb3bd523b8447ee344 | refs/heads/master | 2022-12-15T14:13:38.245792 | 2018-02-28T03:26:07 | 2018-02-28T03:26:07 | 123,223,311 | 0 | 0 | null | 2022-12-07T23:46:01 | 2018-02-28T03:23:29 | Python | UTF-8 | Python | false | false | 4,859 | py | #! /usr/bin/env python
# -*- coding:utf-8 -*-
import pika
import logging
import threading
logger = logging.getLogger(__name__)
class Consumer():
EXCHANGE = 'location'
EXCHANGE_TYPE = 'direct'
# PUBLISH_INTERVAL = 1
QUEUE = 'text'
ROUTING_KEY = 'hola'
def __init__(self, event=None, process_fu... | [
"1668488211@qq.com"
] | 1668488211@qq.com |
ff3f382ed538349416ae4f342bfd129c0b9ba0e3 | 5277e5dffd03bc73e2de330072015c122c8b09c6 | /Method 8/ganuggets2.py | b941866c13789b30737ac3f2a0210df6c3dcec81 | [] | no_license | notesby/CARDALG | 5d6d67cea6fc91a56b0653414bd24014d1d949b1 | b28baa65fea107b947d51ab1956861e1a1852f7b | refs/heads/master | 2022-09-19T12:44:26.369511 | 2020-03-02T18:29:26 | 2020-03-02T18:29:26 | 176,398,678 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 22,337 | py | import numpy as np
import math
import random
from copy import copy
def encodeKey(index,value):
return "{},{}".format(index,value)
def decodeKey(key):
return list(map(lambda x: int(x),key.split(",")))
#returns an expression to get the transformed coordinates
# from the original dimensions to the 1 dimension ... | [
"hector2_10@hotmail.com"
] | hector2_10@hotmail.com |
2eb4ef768fc0f3d2c3c93937b8793072ef95e285 | 3dd9de9b7bd4c555a8426d59edf81ad60c6a6496 | /LuggageTrackerWebApp/migrations/0001_initial.py | 52589f5e690ed0fe4fe3d3a2a0ef11355f964c4b | [] | no_license | kpatel1293/LuggageTracker | 7eddeaf53f88b18d572a53ba23ccf1ef105ccfcd | f72292df41dc4d5b7bf2318a80df8cf0ba040a68 | refs/heads/master | 2023-05-21T12:59:21.503574 | 2021-06-09T00:30:50 | 2021-06-09T00:30:50 | 364,411,565 | 0 | 0 | null | 2021-06-09T00:30:50 | 2021-05-04T23:24:08 | JavaScript | UTF-8 | Python | false | false | 2,444 | py | # Generated by Django 3.2.3 on 2021-05-29 21:05
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
name='Airport',... | [
"kpatel1293@gmail.com"
] | kpatel1293@gmail.com |
29ad851548a733c2004a6f60535eca99397759b5 | 64943ee24949f6eb957515778f1b03f7bf17dabd | /rabbitmq/src/config.py | 757a2fb037c4459c92a880a487a92094c9287192 | [
"Apache-2.0"
] | permissive | upworkroozbeh/k8-test-data | d8a1c716fd6cf308805a42c686a205402d679d03 | c877639cee5c5b129a71cb7214564387d8d66406 | refs/heads/master | 2022-12-30T15:28:09.595343 | 2020-10-20T18:32:11 | 2020-10-20T18:32:11 | 305,796,737 | 0 | 0 | Apache-2.0 | 2020-10-20T18:19:19 | 2020-10-20T18:19:18 | null | UTF-8 | Python | false | false | 2,164 | py | import os
def get_envar(k, required=True):
val = os.environ.get(k, None)
if not val and required:
exit(f"{k} not supplied")
return val
class Config(object):
DEBUG = True
MINIO_ENDPOINT = get_envar("MINIO_ENDPOINT", required=True)
MINIO_ACCESS_KEY_ID = get_envar("MINIO_ACCESS_KEY_ID",... | [
"samarth@smalldaytech.com"
] | samarth@smalldaytech.com |
269e9e1b86bc64707b0de01397627cdcbd9ee4d4 | cb4ccf95b004425f6ae4957420b1a11a2b1e4357 | /PIC/data_create.py | c2da8c7960cf92496e693a8ec9a9042ff9dd51f4 | [] | no_license | Jaymondyu/J | bda6a35e86f29052d63c4c9e361fcaa013e04ffc | 473b7c16f4b7990e1c82ef64ffd53f066b44b457 | refs/heads/master | 2020-06-03T17:36:14.824264 | 2019-09-25T09:48:52 | 2019-09-25T09:48:52 | 191,665,585 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,393 | py |
import cv2
import os
def generate(dirname):
face_cascade = cv2.CascadeClassifier('haarcascade_frontalface_default.xml')
# eye_cascade = cv2.CascadeClassifier('haarcascade_eye.xml')
# 带眼镜的时候可以用下面这个
eye_cascade = cv2.CascadeClassifier('haarcascade_eye_tree_eyeglasses.xml')
# 创建目录
if (not os.pa... | [
"18875001129@163.com"
] | 18875001129@163.com |
ad2d96ef0ca49def732a77dd51abf52f2273c665 | db00cfab06c47708a792fef92c9878e4e4dc646a | /src/practices/practice/heap/heapq.py | 7018e6b48783d3f76ff9529c6aad9c458607f314 | [
"Apache-2.0"
] | permissive | rahul38888/coding_practice | cf001f5e95f22d56623f453bb6c9ebd0d4c2695b | 8445c379310aa189147c4805c43bed80aa9e9fac | refs/heads/main | 2023-08-16T10:16:45.896939 | 2021-09-30T03:35:17 | 2021-09-30T03:35:17 | 390,193,422 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,163 | py | from heapq import heapify, heappop, heappush
import math
class MinHeap:
def __init__(self):
self.heap = []
def setHeap(self,heap):
self.heap = heap
def getParent(self, i):
return math.floor((i - 1) / 2)
def getLeftChild(self, i):
return 2*i+1
def getRighChild(se... | [
"rahul.s@timesinternet.in"
] | rahul.s@timesinternet.in |
ff59967efcded29c65ebd694f14b298509f754d9 | d2f76d0f61a11f34d9fc3f9d3adc659ff5d718cf | /clase1/test_dr_lothar.py | 172894db1e0ac4db5f9ed2e13469bc0ecec922b1 | [
"MIT"
] | permissive | martinadwek/python_course | 2b37c6c6438123a71b3ff7c8e0a59a39dcdbaf26 | a2c29bed2c616e1382dd5768588af1e27312ce52 | refs/heads/main | 2023-01-09T19:49:52.228308 | 2020-11-11T21:52:29 | 2020-11-11T21:52:29 | 301,562,045 | 0 | 0 | MIT | 2020-10-11T20:21:29 | 2020-10-05T23:14:56 | null | UTF-8 | Python | false | false | 744 | py | import unittest
from clase1.dr_lothar import dr_lothar, dr_lothar_rec
class DrLotharTestCase(unittest.TestCase):
def test_even_number(self):
self.assertEqual(8, dr_lothar(6))
def test_odd_number(self):
self.assertEqual(7, dr_lothar(3))
def test_leq_zero_number(self):
with self.a... | [
"matiasdwek@gmail.com"
] | matiasdwek@gmail.com |
8b3e2dbf5c46821979c1ca48b41a984d33e0cfe9 | c1f00241c37d1dfabdd45ed8f6740f993b5f0e88 | /tools/time_conversion.py | 521501b9dd4ba79157e809626d804b6eff7f4e9e | [] | no_license | gxf8934/mobileManage | 9550c90f216b5b6489aa03b363df436233f2bd60 | 395b1b668969cca1c17dd84bcace1a1b0bbac5cb | refs/heads/master | 2022-09-29T08:01:16.849450 | 2020-06-08T06:59:16 | 2020-06-08T06:59:16 | 265,202,406 | 0 | 1 | null | 2020-06-05T09:00:36 | 2020-05-19T09:22:37 | HTML | UTF-8 | Python | false | false | 1,143 | py | # -*- coding:utf-8 -*-
# author:yangcong
# datetime:2020/5/14 11:19 上午
# software: PyCharm
import time
def timestamp_to_date(time_stamp):
'''
将时间戳转换为指定日志
:param time_stamp: timestamp
:return: %Y-%m-%d %H:%M:%S
'''
if time_stamp is None:
return None
date = time.strftime("%Y-%m-%d %... | [
"18335598934@163.com"
] | 18335598934@163.com |
8bcaa7d786ed39bcb15ec478a9664265c2efe24b | 164203a8a6e1dad22906dfef189ed7aacb975ff8 | /RNNBiLSTMCRFATTENTION/filesplit.py | 74930093ced4229f9effc5c916cbbc31fc8b87c9 | [] | no_license | JohnSkyReal/chapter-structure-recognition | f8701cafe27fcf36d0b7466061b74e59f7c9ed50 | 2efcac6c4e3f7a2ccabfbcf0bb87318c62813862 | refs/heads/master | 2021-04-23T00:19:08.146249 | 2020-03-31T07:27:10 | 2020-03-31T07:27:10 | 249,883,391 | 1 | 1 | null | 2020-03-31T07:27:12 | 2020-03-25T04:03:04 | Python | UTF-8 | Python | false | false | 765 | py | import random
fr=open('CORPUS.txt', encoding='utf-8')
sentences=fr.read().strip().split('\n\n')
fr.close()
random.shuffle(sentences)
num=len(sentences)
folder =10
trash=[]
for i in range(folder):
chosen=set()
while len(chosen)<num//folder:
id=random.randint(0, num-1)
while id in tras... | [
"noreply@github.com"
] | noreply@github.com |
fd156e1a6725e04bb2ae33ba8277a84892e0647c | 113e791a999542241da600a03d3225051c947cdb | /packages/examples/c/lib/shared/wscript | 8cfae402c907ba0cdd8be3c7e49c364ce00f29d1 | [
"MIT"
] | permissive | michelm/beehive | d1d2c310c4f4e55b53598069e4acc233a6a77418 | b1fc63b3c7227112f54f2d6dc2f9c0298e327a32 | refs/heads/master | 2016-08-08T15:06:12.460266 | 2013-10-02T20:18:52 | 2013-10-02T20:18:52 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 205 | #!/usr/bin/env python
# -*- encoding: utf-8 -*-
def build(bld):
bld.shlib(
target='cshlib-example',
source=bld.path.ant_glob('src/*.c'),
includes=['./include'],
export_includes=['./include']
)
| [
"michel.mooij@gmail.com"
] | michel.mooij@gmail.com | |
def7d53c45ac5636dbf465c21bd23e68f4c0277e | f2a678afb6152de57635c503ed532a205664b413 | /items/migrations/0001_initial.py | a97ac753a607b444c4082ac3d4068767d265ff07 | [] | no_license | phrac/onepercentgame | 4d4a6247d5f587a65faef8d05a22a2522de3e6f8 | 113d01a3c6641d90f1ce4674ec565ed40ee7c093 | refs/heads/master | 2016-09-16T00:49:36.489216 | 2015-08-30T21:30:51 | 2015-08-30T21:30:51 | 41,644,531 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 565 | py | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
class Migration(migrations.Migration):
dependencies = [
]
operations = [
migrations.CreateModel(
name='Item',
fields=[
('id', models.AutoField(verbose... | [
"derek@disflux.com"
] | derek@disflux.com |
a87f3be260a2ffc2d5615f2787bf040826b4e15c | e0797607cd1331f651b7bb0d5601786a8fbb0428 | /math/reverse_integer.py | c786aea993476a89d1aac4e70dddd64f85b75d3c | [] | no_license | samshaq19912009/Leetcode_in_Python_my_practise | c5b19babd381a311797e3a822971331e70ad51ae | 38619be61c62b91a227b335f7b5d951bcb0531d9 | refs/heads/master | 2021-01-17T17:19:54.011368 | 2016-07-25T17:43:01 | 2016-07-25T17:43:01 | 61,684,947 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 464 | py | """
Reverse digits of an integer.
Example1: x = 123, return 321
Example2: x = -123, return -321
Pay attention to overflow!!!!!!
"""
class Solution:
def reverse_int(self, x):
if x > 0:
flag = 1
else:
flag = -1
x = abs(x)
ans = 0
while x > 0:
... | [
"sccnju@gmail.com"
] | sccnju@gmail.com |
c8da836db2a3042a010ac8a9517324364b250c36 | a72f488701be69d46551c2dc0b4382cb2cb9d1a4 | /seiya/analysis/job.py | 97ecd674c57dff27fd7f0b0480d787ffe54ea1f8 | [] | no_license | Pinzi123/info | 90694050bd313a0fdd562d2717fdd5b39cac2b5d | 2f00eefe3b2785999ae9bb46144a1f6c3d546ca1 | refs/heads/master | 2020-04-04T23:51:59.445009 | 2018-11-06T12:52:12 | 2018-11-06T12:52:12 | 156,374,903 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,490 | py | from io import BytesIO
from sqlalchemy import func, Float, select, and_
import pandas as pd
import matplotlib as mpl
import matplotlib.pyplot as plt
from seiya.db import engine, Session, JobModel
def count_top10():
"""职位数排名前十的城市
"""
session = Session()
rows = session.query(
JobModel.city,
... | [
"995537534@qq.com"
] | 995537534@qq.com |
911dc1a4721c02884df0423246b265a52c5c38e8 | b914ee0f23ddafa487e5cb35c35c3d41517a47a8 | /Ornek2_7.py | 8874dbd3f5b9f090d4b56a7557a26203c85a08b6 | [] | no_license | suacalis/VeriBilimiPython | 0dc45402b09936c82cecca9d6447873d24d1b241 | 85dbfa98ccf1a6a4e8916d134dc1ad41f99535ad | refs/heads/main | 2023-08-24T17:03:48.627831 | 2021-09-28T07:28:21 | 2021-09-28T07:28:21 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 395 | py | '''
Örnek 2.7:
Kullanıcı tarafından girilen yarıçap (r) değerine göre bir dairenin çevresini
hesaplayan programı kodlayalım.
'''
import math #pi için gerekli
import easygui #enterbox(), msgbox() için gerekli
r = easygui.enterbox("Dairenin yarıçapı.:")
r = float(r) #girilen float tipine dönüştü.
Cevre = 2*math.p... | [
"noreply@github.com"
] | noreply@github.com |
313e8b9405659fc705d953a76b6a1501f1f048b7 | d1ec5016fc946a5b9558cb29ff6eb2579ac246bb | /utils.py | bf2c024dd31803c0ee71ecc6d8594a997427654c | [] | no_license | marilynle/Utils | 41f53642b38796902c17ab179e7eee5e3e791f92 | 777e73b3948cd1cb0e103aafa4d3aafc4cd9d2fc | refs/heads/master | 2021-01-03T03:42:19.091807 | 2016-12-09T06:53:05 | 2016-12-09T06:53:05 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 8,942 | py | import cv2
import numpy as np
import os
def batch(data, batch_size=32):
"""Create a new batch of data
Uses the size of the first element in the list to get the max index
Parameters
----------
data : list(numpy.ndarray) or numpy.ndarray
A list of the data to batch, or one array of data... | [
"joshua.greaves@googlemail.com"
] | joshua.greaves@googlemail.com |
fb4f7bf460cee7a3d927c2ecf3c4e57ffb78b877 | 981e949fd9bed8fff1c1a2e9965dfe2fad98735d | /food and entertainment/IndustriesDemand.py | 7b6255228ce866f885fd3aee54dcb746d6ebe162 | [] | no_license | ErikaNicole/Covid19-Environmental-and-Economic-Analysis | 41d25a5ae66138e949c8cbfa9bc09b7c29308969 | 3a83a7b151025f7e9b63c223a8292cda86a5bfaf | refs/heads/master | 2022-12-08T15:51:18.517674 | 2020-09-18T20:45:07 | 2020-09-18T20:45:07 | 295,363,681 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,036 | py | # Using Online Job Adverts as indicators of Industry's Status
import pandas as pd
import numpy as np
import matplotlib.pyplot as plt
import matplotlib.dates as md
import seaborn as sns
import datetime
sns.set_style('whitegrid')
# - - - - - - - - - - - - - - - - - - - - - - -
# 1. Collect OnlineJobAdverts Postings
d... | [
"63018077+ErikaNicole@users.noreply.github.com"
] | 63018077+ErikaNicole@users.noreply.github.com |
a1a6c37bea117ebdfa4eb7defc5ef80e649c0bad | fe948e8b11ab1b8a26e6c8c4b4973c97f747691c | /letor1.py | 7cdbdad514dcb2b5c48589d7ba7b98472caf8100 | [] | no_license | khansamad47/LETOR | 582898933ddc4f793fa7613150f605b6fab037ac | 47e28eb0c8b1a12d54568d6747b11b6a8d8f9c33 | refs/heads/master | 2020-12-24T11:38:09.029600 | 2016-11-06T21:28:31 | 2016-11-06T21:28:31 | 73,020,362 | 0 | 0 | null | 2016-11-06T21:32:13 | 2016-11-06T21:32:11 | null | UTF-8 | Python | false | false | 3,711 | py | import numpy as np
import pandas as pd
import logging
import os
import mimetypes
import re
#File logging
logger = logging.getLogger()
logger.setLevel(logging.DEBUG)
filename='LETOR'
formatter = logging.Formatter('%(asctime)s - %(levelname)s - %(message)s')
fh = logging.FileHandler('log_'+filename+'.txt')
fh.setLevel(l... | [
"amandp0@gmail.com"
] | amandp0@gmail.com |
9e1b9a64af56a30e72495aa962585606ff16f5c4 | 58ee73dcb5d50e1aaf3d52cf05547c95725d3d93 | /proj/urls.py | d213d5b5a91242764f6a7a9fb3d20d667c9470c2 | [] | no_license | Zanudaaa/kolkhoz | d3ae28c79db9dfce6c920b1d700d3a8eba9813e3 | c3a5f7adbc5112be4033ddbdcfbd2f5655a1c7e4 | refs/heads/master | 2020-09-12T06:41:26.549041 | 2019-11-18T19:00:18 | 2019-11-18T19:00:18 | 222,256,999 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,039 | py | """proj URL Configuration
The `urlpatterns` list routes URLs to views. For more information please see:
https://docs.djangoproject.com/en/2.1/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-based vi... | [
"Zanudaaa099@gmail.com"
] | Zanudaaa099@gmail.com |
480e50e61a4de904119a1f25a2d1f7019506f66c | a05ce7d365917c2ae6430e522381792a011d5979 | /atomtoolbox/gap.py | 3041ff805d1ffc5c30b69e00b8a5786062da505f | [
"MIT"
] | permissive | eschmidt42/AtomToolBox | 9d41770e9ebf545ac6cefce5c81226c14ee024c2 | 25b80675dcaa332fc0c0d702b60ea61dfe2501a0 | refs/heads/master | 2021-09-14T21:45:57.408383 | 2018-05-20T09:15:26 | 2018-05-20T09:15:26 | 113,569,858 | 1 | 0 | null | 2018-02-10T14:37:36 | 2017-12-08T12:00:18 | null | UTF-8 | Python | false | false | 4,937 | py | import sklearn
from sklearn.gaussian_process import kernels
import numpy as np
def get_GAP_matrix_v1(Phi, Phi_list, t, idx, L, beta=1., kernel=None):
beta = 1.
y = np.copy(t_e).ravel()
kernel = kernels.RBF(length_scale=1.)
X_S = Phi[idx,:]
C_NpNp = kernel(Phi)
C_NpS = kernel(Phi,Y=X_S)
C... | [
"11818904+eschmidt42@users.noreply.github.com"
] | 11818904+eschmidt42@users.noreply.github.com |
c5982e7ba0e42bb7a2188f72b2377db8bf9a6e8b | 339f3b1e0949fcccdd178e1ebfc0ac4ea6828de6 | /user.py | 672f0b9db55df5325afc1a37d1c3d7b9b8e52089 | [] | no_license | eduincarreno/Ejercicios_Python | bdb3df0298cc579ab581e35215b6e5ee79958f77 | 189d95b283579eb13b712a81b1299de062b498b9 | refs/heads/main | 2023-01-01T21:18:46.785448 | 2020-10-26T03:31:55 | 2020-10-26T03:31:55 | 307,252,122 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 471 | py |
def validar_usuario(nombre_usuario):
longitud=len(nombre_usuario)
nameuser=nombre_usuario.isalnum()
if nameuser== False:
print("El usuario debe tener letras y números")
if longitud < 6:
print("El usuario debe contener mínimo 6 caracteres")
if longitud > 12:
... | [
"noreply@github.com"
] | noreply@github.com |
375e958549538b806a2321d2c1da2b6620981bcf | ca0068d83ebeef49d24e5480b3e74012bbbf44a0 | /tests/test_security_api_key_cookie_description.py | 2cd3565b43ad688307d6f27ce8b4edd84d58cb60 | [
"MIT"
] | permissive | chbndrhnns/fastapi | e66d9485ed59b6018b10a01c1c2832419e91fac8 | b83709add4c5e0cc3dbcb5ecbbd019767c408abd | refs/heads/master | 2023-03-03T23:31:37.436961 | 2022-09-01T09:59:45 | 2022-09-01T09:59:45 | 245,459,912 | 0 | 0 | MIT | 2023-02-24T19:03:36 | 2020-03-06T15:53:14 | Python | UTF-8 | Python | false | false | 1,973 | py | from fastapi import Depends, FastAPI, Security
from fastapi.security import APIKeyCookie
from fastapi.testclient import TestClient
from pydantic import BaseModel
app = FastAPI()
api_key = APIKeyCookie(name="key", description="An API Cookie Key")
class User(BaseModel):
username: str
def get_current_user(oauth_... | [
"noreply@github.com"
] | noreply@github.com |
d3bef1bd1a41795e43168785fee2248e21cf3b84 | 54869fe38624f1c4338f8dc5dd5f0d89aa17c9e4 | /p12.py | 2ba9841678ede63d750d74eebd96ce2c57a59db1 | [] | no_license | qoqosz/Advent-of-Code-2020 | d3b3512eb3b59b7404189ad094a2cc3b8ddb07be | e27928482e8fc9f30aea3fed21e11f8d8743431d | refs/heads/master | 2023-02-05T22:17:45.767109 | 2020-12-24T21:20:57 | 2020-12-24T21:21:06 | 318,346,507 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,941 | py | # Part 1
with open('p12.txt') as f:
steps = [x.strip() for x in f]
direction = {0: 'E', 90: 'N', 180: 'W', 270: 'S'}
direction_inv = {v: k for k, v in direction.items()}
coords = {'E': [1, 0], 'N': [0, 1], 'W': [-1, 0], 'S': [0, -1]}
def turn(orientation, instruction):
sign = 1 if instruction[0] == 'L' else ... | [
"lukasz@bednarski.me"
] | lukasz@bednarski.me |
d52a217c41ef8b70b1df00bbde2336982e48d35b | 2f88b736f7c20081a2685b954d6c3bf2b5c3d50a | /article/admin.py | d34f999e1e936249ff99ff09c203b5e8430237f4 | [] | no_license | resaUndefined/android | 417b24a0dae35057365220b345b39fcab8cfbe8b | 21ceec9f6c4e5358a9555e09f1f0de5cde41b8f3 | refs/heads/master | 2021-01-23T18:44:37.538509 | 2017-09-14T13:40:36 | 2017-09-14T13:40:36 | 102,804,843 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 467 | py | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.contrib import admin
from article.models import Category,Post
class PostAdmin(admin.ModelAdmin):
list_display = ('title','category','created_on','last_modified','image')
list_filter = ('category','created_on')
search_fields = ('title','cont... | [
"resamuhammad96@gmail.com"
] | resamuhammad96@gmail.com |
f137282ec9b0f4d61f2f93dd1ba8b3c222be31fb | eb19e02e86a40f483e70b826aff8dc0b735e9827 | /supproject/models/siyou/model.py | 9793405bf79b248d478b01465d111e31804bebf4 | [] | no_license | decadeGuo/python | 22206950cf7432c9f505bf1c8fef5576f6315e3b | be277417df0b59490fc519c987750815c73986e1 | refs/heads/master | 2020-03-23T14:10:03.447349 | 2018-07-19T06:41:32 | 2018-07-19T06:41:32 | 141,660,696 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,839 | py | #coding:utf-8
from django.db import models
class Clear(models.Model):
uid = models.IntegerField(default=0)
p_id = models.IntegerField(default=0)
c_id = models.IntegerField(default=0)
l_id = models.IntegerField(default=0)
explain = models.CharField(max_length=200)
add_time = models.IntegerField... | [
"guodongbo@tbkt.cn"
] | guodongbo@tbkt.cn |
b26fa7154acf019d6ab62274c28e669627516f3a | b864557087e9a292ac45717d5e2487cefdf1ddba | /leetcode/168.py | fc152c041070d477e7fbd64d97c11fd0e51d5d41 | [] | no_license | gohdong/algorithm | 737ec8830b1d1754f52f3956022c9a063ba4976f | 5ea8f88fc1b3a30470053f459e528bf5c00da766 | refs/heads/master | 2023-08-06T09:30:04.670020 | 2021-10-07T09:28:39 | 2021-10-07T09:28:39 | 385,096,857 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 518 | py | class Solution:
def convertToTitle(self, columnNumber: int) -> str:
answer = ""
while columnNumber:
if columnNumber % 26:
answer = chr(64+columnNumber % 26) + answer
columnNumber = columnNumber - columnNumber % 26
else:
answer =... | [
"aldehf420@naver.com"
] | aldehf420@naver.com |
4e8fd8831a4f09be6415f01c5e318a134881b2d3 | bdbd9f2a63da5dd9b1394849587740cd21121bba | /bonus/visualizer.py | 2f5fb87e0a9b0d261b8c04c436b6ac791cacd4ae | [] | no_license | logn777/Lem_in42 | 7f6a3694c8694abada18192d899abf2d6a7f80f6 | 316ab6e9ec531d855310ba71cc58bb0afc59d749 | refs/heads/master | 2022-11-26T23:20:24.369928 | 2020-08-04T20:10:33 | 2020-08-04T20:10:33 | 284,273,141 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,535 | py | import sys
import json
import argparse
import contextlib
import pytweening
import time
import networkx as nx
import matplotlib
import matplotlib.pyplot as plt
#
import matplotlib.animation as animation
col_path = ['orange', 'magenta', 'cyan', 'brown', 'blue', '#f08c00', '#308bc0',
'#f9c030', '#23f012', '#497663', '... | [
"rmaple@oa-h5.msk.21-school.ru"
] | rmaple@oa-h5.msk.21-school.ru |
ba5e2c97e8f9ce3548daee04347b0d86a35a4d9e | 26d84a3b5716a9d27f3c14da36c07d8a5130790e | /condition_simulation.py | 794684ffebb0f1e083ef6938744c4b2b151ac339 | [] | no_license | allhailjustice/SynTEG | a217fded4582fa788086af928fa46dea1001a291 | 7a602f5629236773a95055d12e0761232cafc1a4 | refs/heads/master | 2023-08-23T01:30:33.661434 | 2021-10-25T14:38:13 | 2021-10-25T14:38:13 | 283,507,903 | 3 | 0 | null | null | null | null | UTF-8 | Python | false | false | 8,359 | py | import tensorflow as tf
import numpy as np
import time
import os
os.environ["CUDA_DEVICE_ORDER"] = "PCI_BUS_ID"
os.environ['CUDA_VISIBLE_DEVICES'] = "6"
os.environ['TF_CPP_MIN_LOG_LEVEL'] = '2'
tf.config.experimental.set_memory_growth = True
checkpoint_directory = "training_checkpoints_gan_new"
checkpoint_... | [
"noreply@github.com"
] | noreply@github.com |
a799c0a8fffef5b1328d74921d60a0fb43b2e3fc | 8de4c1a7ab9d09cc9a67f72fe5c492f3c5173ee7 | /nfldb/te_stats.py | 8118ce8341224fa78907dd7e86b39ae5d3af11d9 | [] | no_license | a-wang24/nfldb_ml | a200ae566fc8d1f7790e89b83a3a3d85476f84a2 | f088f78533fa98191d45c7bff01ded1c25fb030d | refs/heads/master | 2022-01-19T20:52:57.345881 | 2017-06-06T02:18:17 | 2017-06-06T02:18:17 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,424 | py | # -*- coding: utf-8 -*-
"""
Created on Sat May 13 22:13:15 2017
@author: Alan
Write TE stats to .csv
"""
import nfldb
import csv
import individual_stats as indst
import os
years = [2009, 2010, 2011, 2012, 2013, 2014, 2015, 2016]
position = 'TE'
limit = 60
sort_by = ['receiving_yds', 'receiving_tar', 'receiving_tds',... | [
"12wanga@gmail.com"
] | 12wanga@gmail.com |
298572da371a3f2684d72a4d215ccacc3301fc9d | 77176b06a717c65e311f4ec70722d5068851234b | /Windows/prepareDatabase/data_webscrapper.py | 52cf96b3c4a0a273eba703a8577768bfeac70728 | [] | no_license | miloszg/medBase | 3d4484192d1f34c500d175182617f7d90debf5ae | 6f804b034b59068b26a59a1652d468eafdb54f3a | refs/heads/master | 2023-06-09T11:42:40.599929 | 2019-12-08T23:18:09 | 2019-12-08T23:18:09 | 190,621,248 | 0 | 0 | null | 2023-05-30T19:15:06 | 2019-06-06T17:20:59 | Java | UTF-8 | Python | false | false | 2,979 | py | from bs4 import BeautifulSoup
from urllib.request import urlopen
import csv
class Drug:
def __init__(self, _name, _composition, _form, _category, _speciality, _effect, _info="", _dosage=""):
self.name = _name
self.composition = _composition
self.form = _form
self.category = _categ... | [
"[pawel.kankowski@gmail.com]"
] | [pawel.kankowski@gmail.com] |
cfa28847849eeeee9efc5aceb251c642fa49d9bf | 1db51ef25d4ededb70d83acfb5da6060aac728de | /mqtt2redis.py | 2de955b3ffcc25e01f0610874a960637e0526380 | [] | no_license | wowo/pihome-api | 8268d64d83a9d11bf0443c9a183b3fb530717069 | a28f19eeef0df0bee00e5aa7c7bdb7936b669b7e | refs/heads/master | 2023-08-03T06:43:51.154674 | 2023-07-23T19:25:37 | 2023-07-23T19:25:37 | 25,784,297 | 2 | 0 | null | 2023-03-31T14:40:16 | 2014-10-26T17:57:48 | Python | UTF-8 | Python | false | false | 947 | py | #!/usr/bin/python
from datetime import datetime
import json
import paho.mqtt.subscribe as subscribe
import redis
import sys
import time
sensor_key = 'temperature' if len(sys.argv) == 3 else sys.argv[3]
print('Starting topic %s key %s, parameter: %s' % (sys.argv[1], sys.argv[2], sensor_key))
redis = redis.StrictRedis... | [
"wojciech@sznapka.pl"
] | wojciech@sznapka.pl |
8c205a7d4003fa5e71c1b5a52726c951d55b0033 | 786027545626c24486753351d6e19093b261cd7d | /ghidra9.2.1_pyi/ghidra/graph/viewer/layout/GridLocationMap.pyi | f3f8d6ccb23e3486a6d68662f4b630f36b2434c5 | [
"MIT"
] | permissive | kohnakagawa/ghidra_scripts | 51cede1874ef2b1fed901b802316449b4bf25661 | 5afed1234a7266c0624ec445133280993077c376 | refs/heads/main | 2023-03-25T08:25:16.842142 | 2021-03-18T13:31:40 | 2021-03-18T13:31:40 | 338,577,905 | 14 | 1 | null | null | null | null | UTF-8 | Python | false | false | 2,437 | pyi | from typing import List
import ghidra.graph.viewer.layout
import java.lang
class GridLocationMap(object):
"""
An object that maps vertices to rows and columns and edges to their articulation points.
This class is essentially a container that allows layout algorithms to store results, which
can later... | [
"tsunekou1019@gmail.com"
] | tsunekou1019@gmail.com |
2d6d77393f75ae9de52060b26dbf15df2ef7702c | 1f979b6bb1d8b927e02b033077b7ac41f38c5dab | /bin/macho_find | 12d4b4713fd66f23976fd566543d287ccf74295d | [] | no_license | echo-wen/Pig-Meat-Sichuan | 829c8109386d291782a679e73853313acda60497 | cbf6166a399877e7a5bd9fa66b3de0c94d50cbab | refs/heads/master | 2022-11-29T15:40:07.354152 | 2020-08-11T02:25:00 | 2020-08-11T02:25:00 | 285,754,591 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 260 | #!/Users/wenzicheng/PycharmProjects/pig_meat/venv/bin/python
# -*- coding: utf-8 -*-
import re
import sys
from macholib.macho_find import main
if __name__ == '__main__':
sys.argv[0] = re.sub(r'(-script\.pyw|\.exe)?$', '', sys.argv[0])
sys.exit(main())
| [
"wen_zicheng01@gmail.com"
] | wen_zicheng01@gmail.com | |
5c08cc84bffdaff5f05d651e56959922d36161e0 | 05ae8138b976c372d70a5b41a317b32dfaa20883 | /Core_Python/Python Functions/Default Parameter Value.py | c18f8233110b1576a28fcc137df78fd3f7c1f4d7 | [] | no_license | infamousdarius/Python-Practice | 06a16acbf3a986661428999cf9e6f612abaea33f | e11db25fd5d0e29ebb7665c28044739fcfc02589 | refs/heads/master | 2020-06-21T09:34:29.141868 | 2019-07-19T14:37:16 | 2019-07-19T14:37:16 | 197,409,450 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 293 | py | # The following example shows how to use a default parameter value.
#
# If we call the function without parameter, it uses the default value:
def my_function(country="Norway"):
print("I am from " + country)
my_function("Sweden")
my_function("India")
my_function()
my_function("Brazil")
| [
"mrifat@tistatech.com"
] | mrifat@tistatech.com |
da382c1c7477d4ac48f29194bfba0eeb3520846a | 29c7cc5ad02157643a77c71922fb938ee381e125 | /venv/Scripts/django-admin.py | c0da0efeb1e330a4c80878ac561d84dcff9fed75 | [] | no_license | imklesley/PollsDjangoProject | 03c0f498f4b2bc2eb52ebecfd72c4a0e3742c198 | f3e42fcedfd58552bbf10a5f75c7b9f8eb85d7fe | refs/heads/main | 2023-01-24T14:51:52.237202 | 2020-11-23T04:39:58 | 2020-11-23T04:39:58 | 315,201,135 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 713 | py | #!C:\Users\imkle\PycharmProjects\PollDjangoCrashCourse\venv\Scripts\python.exe
# When the django-admin.py deprecation ends, remove this script.
import warnings
from django.core import management
try:
from django.utils.deprecation import RemovedInDjango40Warning
except ImportError:
raise ImportError(
'... | [
"imklesley@gmail.com"
] | imklesley@gmail.com |
324b8d7bdf5c6beb4960c52815263ed0c2e05028 | 2b7046b71f27831a13f9039cc2d2cbe4439732e1 | /routes.py | 258b981e06f8fd8534d9a99c4716af2a6a94998e | [] | no_license | mozillalives/thaiorders | 0fe9ac1274d9bfb3a865a39c23c61239f23e23d3 | 3e78f933604fdff3b42e5360ba85165cc23ef02c | refs/heads/master | 2020-04-06T04:31:14.543847 | 2012-05-19T03:12:19 | 2012-05-19T03:12:19 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 948 | py | """
Using redirect route instead of simple routes since it supports strict_slash
Simple route: http://webapp-improved.appspot.com/guide/routing.html#simple-routes
RedirectRoute: http://webapp-improved.appspot.com/api/webapp2_extras/routes.html#webapp2_extras.routes.RedirectRoute
"""
from webapp2_extras.routes import R... | [
"mozillalives@gmail.com"
] | mozillalives@gmail.com |
7b7b41ce739043d0a9f9a5c24d99b345beebe06e | 219ce374afe533c530eb10856e9e45c924df0ed2 | /src/applicationlayer/management/permission/views.py | 1f1496679afa993939ae184a57554b3fc2a67188 | [] | no_license | gladysforte/neko-api | dc60b95e9f2771f3d55fb58d81a9ed934d69b093 | 0168533623ccbe89bad8763e2ac88febc1a8fa05 | refs/heads/master | 2022-12-05T14:47:02.570100 | 2020-08-07T03:16:42 | 2020-08-07T03:16:42 | 285,589,420 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 385 | py | from rest_framework import viewsets, permissions
from src.applicationlayer.management.permission.serializers import PermissionSerializer
from src.entities import models
# Create your views here.
class PermissionViewSet(viewsets.ModelViewSet):
permission_classes = [permissions.AllowAny]
serializer_class = Per... | [
"gladys@tirsolutions.com"
] | gladys@tirsolutions.com |
053b4ae6bb4f8ac87dc20403abc872c543784cd4 | 1e65ca80032b1b5a4ab3631044c3d41a9f3dd035 | /01_Jump_to_Python/Chapter03/rhombus_v1.py | 2ef012fb11668bdbb5d71475d648db0bd3ffd592 | [] | no_license | bj730612/Bigdata | cdd398c56023c67a2e56c36151e9f2bca067a40a | 9bb38e30bb3728b4a4e75bc763fa858029414d4e | refs/heads/master | 2020-03-15T09:27:23.995217 | 2018-10-02T00:07:38 | 2018-10-02T00:07:38 | 132,075,198 | 0 | 0 | null | null | null | null | UHC | Python | false | false | 473 | py | #coding: cp949
while True:
i = 0
base=(int)(input("홀수를 입력하세요.(0 <- 종료): "))
num=(base+1)/2
if base%2 == 1:
while True:
if num > i:
print(" "*(int)(num-1-i),end="")
print("*"*(int)((2*i)+1))
i+=1
if num <= i:
... | [
"USER@test.com"
] | USER@test.com |
2f6fdb8b9c6bb35b20a53804169c36281fef88f5 | e39244b8dd2d8662098fdeed2e7850fa18d5d063 | /main.py | cbbe5e9bbcf28b68ab9a1e702089031fe6d5a5fc | [] | no_license | hawa0011/Rock-Pappers-Scissors | e23b476e3d8d36d857e3eddaa69d94400ade4f55 | 68999aa628d97a7ab12e017be661f0a7135ab63c | refs/heads/main | 2023-01-18T16:52:00.195354 | 2020-11-10T06:55:35 | 2020-11-10T06:55:35 | 311,571,731 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,065 | py | import random
rock = '''
_______
---' ____)
(_____)
(_____)
(____)
---.__(___)
'''
paper = '''
_______
---' ____)____
______)
_______)
_______)
---.__________)
'''
scissors = '''
_______
---' ____)____
______)
__________)
(____)
... | [
"noreply@github.com"
] | noreply@github.com |
23edf3fbfe1db234c24b79cd8c272514d314f1c4 | 6fa7f99d3d3d9b177ef01ebf9a9da4982813b7d4 | /m42wuSJtbRYC2HmRP_1.py | f66939f77888e2de21eaa38b6d7b1f8e7e9981c8 | [] | 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 | 95 | py |
from math import*
largest_exponential=lambda l:l.index(max(l,key=lambda x:x[1]*log(x[0])))+1
| [
"daniel.reich@danielreichs-MacBook-Pro.local"
] | daniel.reich@danielreichs-MacBook-Pro.local |
3def27b583f63a74db5c137ef944ba9fda166b39 | c64fceda8e55aff23f7eff27417c4d494b8792ec | /mypy-stubs/typeguard.pyi | 970ffe639a8f3e91d579b0bb7fda681c037f6c64 | [
"Apache-2.0"
] | permissive | AndrewLitteken/parsl | 946efd9d22c554da409a0f8248b17718339b727c | ec6c6a2a7fbae566006781338226fc13bc0d21ca | refs/heads/master | 2020-04-20T22:24:38.307883 | 2019-07-19T21:33:06 | 2019-07-19T21:33:06 | 169,138,369 | 2 | 2 | Apache-2.0 | 2019-04-28T22:13:49 | 2019-02-04T19:48:27 | Python | UTF-8 | Python | false | false | 269 | pyi |
# this type for runtime_validation is based on the
# "Decorators that do not change the signature of the function" section of
# https://github.com/python/mypy/issues/3157
from typing import TypeVar, List
Func = TypeVar('Func')
def typechecked(f: Func) -> Func: ...
| [
"noreply@github.com"
] | noreply@github.com |
438266feb6b85e6d9b6af66a9eb0986baff8c2c2 | d9821f540e10bd785e1f9959909958555ad2dfe2 | /SOM.py | 3eb1482082f1ca0dd7ba4b42eec89bc632347b46 | [] | no_license | tanjiawei23/EE7207 | f931425d11e4ea0267f3b7158788c487137fe626 | 97bec30d68539fb85ad12fc11f58fb7e7c3cec7f | refs/heads/main | 2023-08-14T14:45:42.707545 | 2021-09-30T19:54:37 | 2021-09-30T19:54:37 | 412,206,327 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,952 | py | import numpy as np
import pylab as pl
# 神经网络
class SOM(object):
def __init__(self, X, output, iteration, batch_size):
"""
:param X: 形状是N*D,输入样本有N个,每个D维
:param output: (n,m)一个元组,为输出层的形状是一个n*m的二维矩阵
:param iteration:迭代次数
:param batch_size:每次迭代时的样本数量
初始化一个权值... | [
"noreply@github.com"
] | noreply@github.com |
099ec43119f2ae5e0635eb44a1dbff6c88d3ed20 | 4730749ce5f0f4f652b688c7594badc1c357f1d6 | /LV.1/핸드폰 번호 가리기.py | 4553fb1630829f20ac62717e105e0e247257c327 | [] | no_license | RobertHan96/programmers_algorithm | 4de015278d7242ee79cd33047a6975a9c9d63c92 | 776777e14e33ca99571296defd28d145d6366bef | refs/heads/master | 2022-04-26T22:46:54.363542 | 2022-04-12T13:53:46 | 2022-04-12T13:53:46 | 233,599,487 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 574 | py | # 프로그래머스 모바일은 개인정보 보호를 위해 고지서를 보낼 때 고객들의 전화번호의 일부를 가립니다.
# 전화번호가 문자열 phone_number로 주어졌을 때,
# 전화번호의 뒷 4자리를 제외한 나머지 숫자를 전부 *으로 가린 문자열을 리턴하는 함수, solution을 완성해주세요.
# s는 길이 4 이상, 20이하인 문자열입니다.
def solution(phone_number):
numbers = list(phone_number)
return (len(numbers)-4) * "*" + ''.join(numbers[len(numbers)-4:])... | [
"yshan4329@gmail.com"
] | yshan4329@gmail.com |
1588a9be00f49bc54ab4f1f48fbf7fb544f9f999 | 5cb38042bdf1126609c1ad0a19edad47e3bdbc55 | /ProblemSet/ProblemSet4/getWordScore.py | ce8ff674b7494112773b10e64cce222e710e313d | [
"Giftware"
] | permissive | y0m0/MIT.6.00.1x | 0e14c05ed0ffefefce49d504de853d0db39ad02d | c10fa1615879f35f822d73d6fa209566ce66b47f | refs/heads/master | 2021-01-01T05:25:25.403150 | 2020-12-05T14:05:06 | 2020-12-05T14:05:06 | 57,986,412 | 180 | 95 | null | 2022-08-08T12:07:09 | 2016-05-03T17:03:36 | Python | UTF-8 | Python | false | false | 827 | py | def getWordScore(word, n):
"""
Returns the score for a word. Assumes the word is a valid word.
The score for a word is the sum of the points for letters in the
word, multiplied by the length of the word, PLUS 50 points if all n
letters are used on the first turn.
Letters are scored as in Scrab... | [
"lixi.daniele@gmail.com"
] | lixi.daniele@gmail.com |
2550065b7ba0f3c632729aed298ab54bc4201d84 | 9c40a40466ab5d29bdb42365f1f8531e5756154f | /MSM_test_fitkbar.py | fdb4b98006a2a3715f3c8fb707a8270b666db60d | [] | no_license | goldstar111/MSM_Thanasarn | 996bbd1d79bc0a84c4e2b45ad0965b64daf901c5 | 6b29e7a31d5ea278dad563cf3fd5428e662aa035 | refs/heads/master | 2021-09-14T14:05:15.710998 | 2018-05-14T21:35:43 | 2018-05-14T21:35:43 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,010 | py | import matplotlib
import numpy as np
import matplotlib.pyplot as plt
import pandas as pd
from pandas import DataFrame as df
from MSM_util import *
from lmfit import minimize, Minimizer, Parameters, Parameter, report_fit
import sys, scipy, numpy
import statsmodels
# print(scipy.__version__, numpy.__version__, sys.vers... | [
"lawofearth@gmail.com"
] | lawofearth@gmail.com |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.