blob_id stringlengths 40 40 | directory_id stringlengths 40 40 | path stringlengths 2 616 | content_id stringlengths 40 40 | detected_licenses listlengths 0 69 | license_type stringclasses 2
values | repo_name stringlengths 5 118 | snapshot_id stringlengths 40 40 | revision_id stringlengths 40 40 | branch_name stringlengths 4 63 | visit_date timestamp[us] | revision_date timestamp[us] | committer_date timestamp[us] | github_id int64 2.91k 686M ⌀ | star_events_count int64 0 209k | fork_events_count int64 0 110k | gha_license_id stringclasses 23
values | gha_event_created_at timestamp[us] | gha_created_at timestamp[us] | gha_language stringclasses 213
values | src_encoding stringclasses 30
values | language stringclasses 1
value | is_vendor bool 2
classes | is_generated bool 2
classes | length_bytes int64 2 10.3M | extension stringclasses 246
values | content stringlengths 2 10.3M | authors listlengths 1 1 | author_id stringlengths 0 212 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
7f8e92de14db9bad2e1cad5ac7d8a09da0fb4d12 | 8bd1ae9c1681ee8c1214a4e9cda29a503676c36d | /v1/gps.py | 418181c1a61dd0bdc1470bc0d6bc9a7e10955a77 | [] | no_license | zleffke/balloon | c15ef7e5614018022ca1f19ed2e4c82009352165 | 2943d303692b299e6d0866299d83a94d0839bf5b | refs/heads/master | 2021-07-06T02:28:17.304024 | 2021-05-22T20:25:18 | 2021-05-22T20:25:18 | 57,078,951 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 5,637 | py | #!/usr/bin/env python
##################################################
# GPS Interface
# Author: Zach Leffke
# Description: Initial GPS testing
##################################################
from optparse import OptionParser
import threading
from datetime import datetime as date
import os
import serial
import ma... | [
"zleffke@vt.edu"
] | zleffke@vt.edu |
48c20b5c2aa2b919066addf3f2316a64f8c38b3c | de2c61ae61ce873a9b622d410c8a2b2c2579ef3a | /google_health/tests/test_map_values.py | fbd90e753446de9ffe7b3927acfa88a1d5f6120f | [
"MIT"
] | permissive | JedGrabman/covidcast-indicators | cbd00e1530dc43f802b5ffdf199e8f59acf98c5c | d2a5a232431c8392c54bfc301dcb9beecc541b97 | refs/heads/main | 2023-01-20T23:29:17.577825 | 2020-10-28T14:18:02 | 2020-10-28T14:18:02 | 308,045,275 | 0 | 0 | MIT | 2020-10-28T14:38:51 | 2020-10-28T14:38:50 | null | UTF-8 | Python | false | false | 3,868 | py | import pytest
from os.path import join
import pandas as pd
import numpy as np
from delphi_google_health.map_values import derived_counts_from_dma, _dma_df_to_matrix
class TestMapValues:
def test_dummy_hrr(self):
# Create a dummy dataset
static_dir = join("..", "static")
dma_list = np.l... | [
"tbarnold@protonmail.ch"
] | tbarnold@protonmail.ch |
2efdc583ed742bce6daede58f08e6d65b7d392eb | 8e26bbe97e96212a8bebcbed415018c23ba4fd1a | /ds/binary-trees/CheckBalanced.py | 4ebde8a96acb7f86e063fd98bc7158b6b628b80d | [] | no_license | yashjaiswal1/CTCI-DSA | ba04d00f33d14de128bddafc29a823f5c7be1fdb | f392c4f86dea8bf29a42325c4d5004355a3b82f5 | refs/heads/master | 2023-05-29T00:47:49.387875 | 2021-06-13T07:31:23 | 2021-06-13T07:31:23 | 351,172,799 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,039 | py | class Node:
def __init__(self, key=None):
self.key = key
self.leftChild = None
self.rightChild = None
def isBalanced(localRoot):
if localRoot == None:
return True
else:
difference = abs(getHeight(localRoot.leftChild) -
getHeight(localRoot.ri... | [
"yashjaiswal1@outlook.com"
] | yashjaiswal1@outlook.com |
cafefe10c03e39adab28f4ab55ac8cd1d46afa94 | afb2d6491ac801778500bb5424488355828c3f08 | /construction_execution.py | 5b9f8f1ae4dc90d5997119db94b48235ed476605 | [
"MIT"
] | permissive | dsnaveen/meucci-python | 31bac8cd1a3c76ee082c40e7d47b1815fbc3096b | 1519f5076b3fb3e0e575200dd3a41d7a36547300 | refs/heads/master | 2021-06-01T04:23:40.584878 | 2016-07-05T07:22:04 | 2016-07-05T07:22:04 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,322 | py | """
Python code for blog post "mini-Meucci : Applying The Checklist - Steps 8-9"
http://www.returnandrisk.com/2016/06/mini-meucci-applying-checklist-steps-8-9.html
Copyright (c) 2016 Peter Chan (peter-at-return-and-risk-dot-com)
"""
#%matplotlib inline
from pandas_datareader import data
import numpy as np
import panda... | [
"returnandrisk@users.noreply.github.com"
] | returnandrisk@users.noreply.github.com |
35c2c078c3d6ff1d63ce2b376b5387b4eb97f1e7 | b5aa43c8db450c3bcacc8f28897eab684a8032a1 | /data/games/missiles/ui.py | 431fd970d43ec82007a75566bf14a29e0ec60f3b | [] | no_license | iminurnamez/Python_Arcade_Collab | 29a74cf2a6264969de9bae3c4a6ed23d6282e793 | 67702414ed30addd1bf46339bb458df34ed88f2a | refs/heads/master | 2021-04-15T07:32:18.573004 | 2018-05-13T14:29:19 | 2018-05-13T14:29:19 | 126,644,972 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,767 | py | import pygame as pg
from data.core import constants as prog_constants
from data.components.labels import Label
from . import constants
class UI(object):
def __init__(self, player, level):
font = prog_constants.FONTS["Fixedsys500c"]
self.level_label = Label(font, 16, "Level {}".format(level.level... | [
"easinerf@gmail.com"
] | easinerf@gmail.com |
69c34a6ee0995ab5c5ac58ef95ce650d85b3cfb3 | b7098b8a2c673cec6d4bfb9eab47bd9df2944292 | /7_문자열/5622.py | 379f4de148c422f45392fc7fadf89d21275a487a | [] | no_license | limgeonho/BOJ_stages | 0bc9e53aec129a34c6114d4b39c9a09de4e93bbb | c579124823df510b5ad84f95fb9ebdff5c9b762c | refs/heads/master | 2023-07-17T03:48:33.161536 | 2021-08-29T14:48:55 | 2021-08-29T14:48:55 | 389,390,588 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 460 | py | # 다이얼
s = input()
phone = {2: 'ABC', 3: 'DEF', 4: 'GHI', 5: 'JKL',
6: 'MNO', 7: 'PQRS', 8: 'TUV', 9: 'WXYZ'}
cnt = 0
for char in s:
for k, v in phone.items():
if char in v:
cnt += k+1
print(cnt)
# li = ['ABC', 'DEF', 'GHI', 'JKL', 'MNO', 'PQRS', 'TUV', 'WXYZ']
# word = input()
# cn... | [
"ghlim909@gmail.com"
] | ghlim909@gmail.com |
abeb393fe7e77610063af908b694f73c67e31c8f | 776fb2aecea006e14e39fb8a71ff9a9f447b6105 | /metarho/localsettings-dist.py | deae4e87021eece9b42c2a156011da7419128e3e | [] | no_license | TheProjecter/metarho | 1615c1e2f838e0676f9a3d6e4243906aa8bb9eb9 | 36654f34fbdaffb7146f2f8f4dc87b48ad39cc75 | refs/heads/master | 2021-01-10T15:13:31.244164 | 2010-05-28T21:50:25 | 2010-05-28T21:50:25 | 43,166,467 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,370 | py | # file localsettings-dist.py
#
# Copyright 2010 Scott Turnbull
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required b... | [
"streamweaver@mindspring.com"
] | streamweaver@mindspring.com |
d15e3bb52395ec126ac48230b4f647c49dd77d27 | d6beff28c32310a8835c3d34a882ff6d6dee89ab | /setup.py | 926353d559c620954512666519f611dddb494ccc | [] | no_license | mattvonrocketstein/goulash | ae0dfc87a8d8c44f924800bc7a0257bb756ac810 | cff9cb1e279a31394af7357f3f515a0b51cf5f62 | refs/heads/master | 2020-05-17T17:25:55.403433 | 2016-01-15T20:35:01 | 2016-01-15T20:35:01 | 7,263,061 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,764 | py | #!/usr/bin/env python
""" setup.py for goulash
"""
import os, sys
from setuptools import setup, find_packages
# make sure that finding packages works, even
# when setup.py is invoked from outside this dir
this_dir = os.path.dirname(os.path.abspath(__file__))
if not os.getcwd()==this_dir:
os.chdir(this_dir)
# make... | [
"matthewvonrocketstein@gmail-dot-com"
] | matthewvonrocketstein@gmail-dot-com |
106a0d9c89e4949c8b9f5af082852301f80aad4f | 72d7c721df1bfe8274ea17194498e869c4247d95 | /espn_api/baseball/__init__.py | 898b3e849003e8bfa622941b824501074687a039 | [
"MIT"
] | permissive | AdrianForsythe/ff-espn-api | f344287e6f74a057910ab0b140393ca3e4d5580f | ac82048e3f0397361c54dc5497df72bf9f29586f | refs/heads/master | 2022-09-21T03:47:18.813600 | 2022-07-31T21:49:06 | 2022-07-31T21:49:06 | 206,588,624 | 1 | 0 | MIT | 2019-09-05T14:49:49 | 2019-09-05T14:49:49 | null | UTF-8 | Python | false | false | 211 | py | __all__ = ['League',
'Team',
'Player',
'Matchup',
]
from .league import League
from .team import Team
from .player import Player
from .matchup import Matchup | [
"cwendt94@vt.edu"
] | cwendt94@vt.edu |
395ed5ce63deb82814dea454d7b5964dd380116c | f5b46d7a9f5583b5156ef03797ca2651b8c3e145 | /tubers/tubers/settings.py | 1f8101ef697b7a3bec9fbff550d2b25061de0cfc | [] | no_license | Ipshita30/lco-tubers | 96283240925a4ce9076ee29c2691698c2e83871d | 8a6f467ca7026222af7b56853614a000c723e609 | refs/heads/main | 2023-03-19T08:13:46.875529 | 2021-03-19T10:03:11 | 2021-03-19T10:03:11 | 349,349,308 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,341 | py | """
Django settings for tubers project.
Generated by 'django-admin startproject' using Django 3.1.7.
For more information on this file, see
https://docs.djangoproject.com/en/3.1/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/3.1/ref/settings/
"""
from pathlib ... | [
"Ipshitam.soni@gmail.com"
] | Ipshitam.soni@gmail.com |
92001a2b21623b944fec416bba71f5a2a3afe83f | e0029bbfe3158b1d590a102965ed0b11bdfa7ab8 | /pydicom/tests/test_pylibjpeg.py | e025cd854390112b259c3962b9f5839b98671ed1 | [
"MIT",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | ARteapartedelarte/pydicom | 1302eb969661c27cda908b56ebc3d6c572027a95 | 389b1ad97c1b3616851b37749e4bd2520755f0d1 | refs/heads/master | 2023-04-24T08:43:04.902001 | 2021-04-29T23:33:51 | 2021-04-29T23:33:51 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 29,695 | py | # Copyright 2020 pydicom authors. See LICENSE file for details.
"""Tests for the pixel_data_handlers.pylibjpeg_handler module."""
import pytest
import pydicom
from pydicom.data import get_testdata_file
from pydicom.encaps import defragment_data
from pydicom.filereader import dcmread
from pydicom.pixel_data_handlers.u... | [
"noreply@github.com"
] | ARteapartedelarte.noreply@github.com |
e40704c97d19358dd5216ad35e1b047a08393b37 | 6f0b9856f3c46557af1c58d86b16f1f93d0fe95f | /mcdonald/Python-dsstore-master/stdin.py | c8eea1e732e1fd55fc6faccdd2a8399f2b689436 | [
"MIT"
] | permissive | vito-lbs/35c3ctf-junior | 1acae908cbd16a6867ffc694de8d9d720319723f | 39f956714fd61f571a9de07078d062298b89936e | refs/heads/master | 2020-04-13T20:09:00.270495 | 2018-12-30T12:49:52 | 2018-12-30T12:49:52 | 163,422,441 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 221 | py | import dsstore
import os
import sys
if __name__ == "__main__":
d = dsstore.DS_Store(sys.stdin.read(), debug=False)
files = d.traverse_root()
print("Count: ", len(files))
for f in files:
print(f)
| [
"vito@legitbs.net"
] | vito@legitbs.net |
91ca1eae352c62b73172ecfd062b21b351e121ca | dbc2cd83ba5440262ce4ed20081e6d0ee995f243 | /problem/problem/urls.py | 1654a2a2258cdabccf0d91bfca7097b32ffd27df | [] | no_license | templargin/datepicker | 64ef313d0a20543c251c1b909dcb7584aaf0bbd4 | 335662bc283880a5a96023b82d0298f9ecae636e | refs/heads/master | 2022-12-05T10:36:19.850909 | 2020-08-30T05:19:09 | 2020-08-30T05:19:09 | 291,404,556 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 800 | py | """problem URL Configuration
The `urlpatterns` list routes URLs to views. For more information please see:
https://docs.djangoproject.com/en/3.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... | [
"templargin@gmail.com"
] | templargin@gmail.com |
97e0d5144b9a6ae3c4194a613b241057f387c463 | d97b7d689c39f73d38e35ad4431262a4b988c61f | /Python/python_new/sec07.py | 64a6973dd5602fcaef05eec74cd7d9609325ea07 | [] | no_license | jiye-stingray/Python | 58fefe46b100cbb3e8212f7de36a14cf4c27ee71 | 51c81230cedc64f6d63e43b1b7888db36a37c7db | refs/heads/main | 2023-07-01T05:07:35.821903 | 2021-07-30T00:29:19 | 2021-07-30T00:29:19 | 389,515,256 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,231 | py | # 클래스
# 선언
# class 클래스 명: (클래스명 첫 글자: 대문자, ex)Stu, StuInfo
# 함수~~
# class UserInfo:
# def __init__(self, name, hp, add):
# self.name = name
# print('Name:',self.name)
# user1 = UserInfo('Kim')
# user2 = UserInfo('Park')
# print(id(user1))
# print(id(user2))
# print('user1... | [
"noreply@github.com"
] | jiye-stingray.noreply@github.com |
fb92ee596bbf8cf147d7b2a163c82507d79b8efa | a8dd2eba427c91945a15511dfb507efc5ef204b3 | /odin/utils/scipy_interface.py | d61579b99df1ec941c4a5fd22cff09e1ad09f155 | [
"MIT"
] | permissive | sdi1100041/SLEIPNIR | 3ace6e15731b357148710fb40b02ce9a2121d0f0 | 02dd3eca8574899fd3f0e287b1a050e76e5ba0de | refs/heads/master | 2021-02-10T10:12:32.481825 | 2020-03-06T15:54:00 | 2020-03-06T15:54:00 | 244,372,898 | 3 | 1 | null | null | null | null | UTF-8 | Python | false | false | 18,088 | py | #Some minor adjustments to the original TensorFlow code
#for better logging
#
# Copyright 2016 The TensorFlow 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
#
#... | [
"manosangelis@gmail.com"
] | manosangelis@gmail.com |
6ee2d4096e128491473231d9eeb153b9099cd13b | 95b747c2ae2f95b5696c287db2d14087669fa3ca | /billie_pr/billie_pr/asgi.py | 2f772846f4ef8afbdb2e43f808d1b6df9fc1d213 | [] | no_license | victorsierraram/bille_vsr | 3bf6c43da2b260d3da382ed98bde5c9dc27d7599 | 0216ad43fbce489ae1ae72f2cd4f7ac5f0d8fd08 | refs/heads/master | 2022-12-28T23:56:57.486747 | 2020-09-25T15:53:41 | 2020-09-25T15:53:41 | 298,615,547 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 395 | py | """
ASGI config for billie_pr project.
It exposes the ASGI callable as a module-level variable named ``application``.
For more information on this file, see
https://docs.djangoproject.com/en/3.1/howto/deployment/asgi/
"""
import os
from django.core.asgi import get_asgi_application
os.environ.setdefault('DJANGO_SET... | [
"v.sierra@i2tic.com"
] | v.sierra@i2tic.com |
57dd010b386b4608b2bd455946413d12040e1b8f | ae4b91e269df7c80a0fa75ccc054d2241de82461 | /adder/adder.py | d685505a984ce254d2335f905e4bb083879dbb1d | [] | no_license | ydnatag/sifive-bsas-hdl-python | be48b32d1080f5b77fec7429b4f8ef86c8e02d41 | 3763300510eaa496b5d24fff4846494d3446a901 | refs/heads/master | 2023-02-24T14:51:19.310738 | 2019-11-21T17:05:16 | 2019-11-21T17:05:16 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,755 | py | from nmigen import *
from nmigen.cli import main
from nmigen.hdl.rec import Direction
class AxiStream(Record):
def __init__(self, width, direction=None, name=None, fields=None):
self.width = width
self.DATA_FIELDS = [('TDATA', width)]
if direction == 'sink':
layout = [('TDATA', ... | [
"andresdemski@gmail.com"
] | andresdemski@gmail.com |
7e40dfecbe5369523eaad88b5eb6aa6a9cc5f77a | 42bb1d9bcd38f30a37e3adb52da68dc0ec868535 | /clients/python_client/scikitlearn_iris_client.py | d77f1c361d48e059d4b62a453fb365528246cedd | [
"Apache-2.0"
] | permissive | zhaoyingjun/simple_tensorflow_serving | 828a7b76dd3ab39ca1dedbf1c5a4d8d7c4de1a86 | 8e6a2ac22a323905b2d3e05b6207ce43c6806470 | refs/heads/master | 2020-08-21T17:29:38.702132 | 2019-09-24T08:12:59 | 2019-09-24T08:12:59 | 216,208,646 | 0 | 1 | Apache-2.0 | 2019-10-19T13:12:23 | 2019-10-19T13:12:23 | null | UTF-8 | Python | false | false | 503 | py | #!/usr/bin/env python
import requests
def main():
endpoint = "http://127.0.0.1:8500"
input_data = {
"model_name": "default",
"model_version": 1,
"data": [[1.0, 2.0, 3.0, 4.0]]
}
result = requests.post(endpoint, json=input_data)
print(result.text)
input_data = {
"preprocess": Tr... | [
"tobeg3oogle@gmail.com"
] | tobeg3oogle@gmail.com |
5cae62a723fc75db2acb2a368ef8e647d0ff7cda | 8a92ed71ab5efc18c7221e7aef1b306a6d2657c8 | /General/List_data_type.py | 2a01ce6502e40c0d26d344bb6973cc07d6f9159e | [] | no_license | ksreddy1980/test | a163cff96ec535f0da46d6cd7d751b08ccb37a07 | 0ef300ec830e0eee9f68149d178b4ce25a6766ee | refs/heads/master | 2021-03-24T09:43:59.006443 | 2018-01-10T16:23:18 | 2018-01-10T16:23:18 | 116,905,860 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 398 | py | # Define a list
task= ['brush','bath','office','drinks']
print(task)
# Update a list
task[1]='Dryclean'
print(task)
#Print the length of the list
print(len(task))
#print an element of the list
print(task[2])
#print a part of the list
print(task[0:2])
#Concatination of list
list1=['computers','maths','Python','Ha... | [
"kskoteru@gmail.com"
] | kskoteru@gmail.com |
d87a4bf8c96e7786d39a38cdb4b518ff441e65a9 | 1528e85557dff16ea148d97c40c7667e1c3ec574 | /hackinstring.py | 47e9e42e0d387ed1d1562d02437a8eb40fe3d149 | [] | no_license | aashishksingh/HackerRankSoln | 6c2871e84046a900c36ab45f84ddef1a22af4c23 | 924381d02e9d62ea970d7f7e39f97f5834df600a | refs/heads/master | 2021-01-21T14:28:54.473289 | 2017-09-28T13:42:01 | 2017-09-28T13:42:01 | 95,291,343 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 602 | py | #!/bin/python3
import sys
q = int(input().strip())
for a0 in range(q):
s = input().strip()
lst=list(s)
# your code goes here
word='hackerrank'
d=[]
flag=False
for c in word:
d.append([c,-1])
# print(d)
#print(s.index('a'))
j=-1
for i in range(len(d)):
if d[i... | [
"noreply@github.com"
] | aashishksingh.noreply@github.com |
2f94c0237d53466948e828695d5b8374dbf238b1 | 182979d15a51397b1e0967b6be9271f4db9b9d18 | /Week 2/Searching and Sorting/Square Root.py | 037ffd7cd9014c8a59315b1708bf495154097664 | [] | no_license | Harini-Pavithra/GFG-11-Week-DSA-Workshop | 1d85115ad3985834456bcf5dc2e424ab65bc8e01 | f305a3a23fd37080e68d0f4d4eeedbcedf399fc9 | refs/heads/main | 2023-06-24T01:19:32.410996 | 2021-07-22T16:36:19 | 2021-07-22T16:36:19 | 317,279,085 | 18 | 10 | null | null | null | null | UTF-8 | Python | false | false | 1,065 | py | Square root
Given an integer x, find the square root of x. If x is not a perfect square, then return floor(√x).
Example 1:
Input:
x = 5
Output: 2
Explanation: Since, 5 is not a perfect
square, floor of square_root of 5 is 2.
Example 2:
Input:
x = 4
Output: 2
Explanation: Since, 4 is a perfect
square, so its sq... | [
"noreply@github.com"
] | Harini-Pavithra.noreply@github.com |
71df3b3b8eb6a2a73b6bcb40342bd58bc13029c7 | 0dcb8d16ca9a71197c5770b734699b0d6d063d25 | /app/views/main.py | 2f2803bd3a4ec4fb26e2d5d01c0e4e56e4fbda12 | [] | no_license | jingmeiliu/flask_restful_autodoc | ded6e87cc491cc483447ee0d31d913792995a6e1 | 4c6c140990697743a29a48dc7f8a881397647c14 | refs/heads/master | 2020-04-28T09:44:39.116124 | 2019-03-12T09:38:22 | 2019-03-12T09:38:22 | 175,178,457 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,662 | py | # 自动生成文档路由
from flask import Blueprint, redirect, url_for, render_template
from .. import get_app
main = Blueprint('main', __name__)
@main.route('/', methods=['GET'])
def index():
"""Redirect home page to docs page."""
return redirect(url_for('api.index'))
@main.route('/docs/<endpoint>', methods=['GET'])
de... | [
"m17610062085@163.com"
] | m17610062085@163.com |
aa48328ecabf25584e364dac5f0684067c919c3f | 4de615cb622b3f3b344aec0ad2f562e37534bda3 | /reading_code/01_if_else/02_if_else.py | 03dbb8a5b68974f44dd7512189c779b684249525 | [] | no_license | igin/academy_exercises | 9679c561f5ddec2b9a04ecfa5ffaff1f3d3ff7b6 | 6697f94f0a3a8525b15829e4354af8ddc3374f73 | refs/heads/main | 2023-03-03T21:42:26.049593 | 2021-02-21T10:04:54 | 2021-02-21T10:04:54 | 340,292,286 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 269 | py | x = 0.3
y = -10
if x > 5:
print("A1")
elif y > -30:
print("A2")
elif x < 10:
print("A3")
else:
print("A4")
if x * 4 < 1:
print("B1")
elif y * x > 0:
print("B2")
elif x == 0.3:
print("B3")
elif y < 0:
print("B4")
else:
print("B5")
| [
"n.pleschko@gmail.com"
] | n.pleschko@gmail.com |
123953571e2bab1ee932089a36b99f7da38c9c69 | 4db571a07884c56ad46fbb69a76018231d2a9d3b | /cogs/admin.py | cbd2a925d60c6762e8190725565be8913f58a32e | [] | no_license | noahgarrett/ThiccBot | fe89f4146df799d9fe347e909ac2c2c06f09e557 | 753a2e671e0ec674b2b09e3ae0118ac9d021b597 | refs/heads/main | 2023-08-10T15:57:56.086336 | 2021-09-21T15:33:18 | 2021-09-21T15:33:18 | 319,788,252 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 323 | py | import discord
from discord.ext import commands, tasks
from discord.utils import get
import asyncio
import youtube_dl
from random import choice
import os, json, random
import main
class Admin(commands.Cog):
def __init__(self, client):
self.client = client
def setup(client):
client.add_cog(Admin(clien... | [
"67662284+xsychgames@users.noreply.github.com"
] | 67662284+xsychgames@users.noreply.github.com |
726a7f16647c3a127386899bc01e7866d9b1e643 | 2740f4dfc5bde90663cb5c022751ff0b0620609d | /migrations/lifeline/add_column_issuetype.py | 9d040a8b7830fd60179d1f5001511363a2eeb22d | [
"MIT"
] | permissive | danielseetoh/twilio185 | 951a5883d99f1b40b09d4c18c9160840d75e0e80 | b9b60e230e7a10f00fe8a1fc0bc67ad7ad8db0d8 | refs/heads/master | 2021-01-10T12:51:41.648818 | 2016-05-01T20:48:09 | 2016-05-01T20:48:09 | 54,152,463 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 418 | py | import psycopg2 as db
import sys
# try:
# con = db.connect(database="lifeline", user="postgres", password="seetoh", host="localhost")
con = db.connect(database="lifeline", user="postgres", password="seetoh", host="localhost")
print 'Success!'
cur = con.cursor()
cur.execute("ALTER TABLE requests ADD COLUMN is... | [
"danielseetoh92@gmail.com"
] | danielseetoh92@gmail.com |
6523dca574371c5e6210bf67e62f3d1285e7cfb2 | c32d3849f6273a08c646ea54fb1e717743620389 | /example-1.py | 7faefbd992be07984b1a75c586e102b591a4940e | [] | no_license | aron-castle/python_learing_test | 838c60648b4291b8aef4ca2167a52a4b9a23f26e | 72c54b4be1a9d41e2f9970cc6bb76c7678c6d1aa | refs/heads/master | 2020-07-11T03:42:26.832168 | 2019-08-27T02:47:01 | 2019-08-27T02:47:01 | 204,437,361 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 430 | py | print("Type integers,each followed by Enter;or just Enter to finish")
total = 0
count = 0
while True:
line = input("integer:")
if line:
try:
number = int(line)
except ValueError as err:
print(err)
continue
total += number
count ... | [
"noreply@github.com"
] | aron-castle.noreply@github.com |
3ebcd7bdfa9db76a19a1a1858d267eb560ba1e32 | 4adecd7aafb73c3b01a3b6eb488d1232443dac35 | /manage.py | 17d3a8e8c04dadbc9d180f23c9d99df785f59f1b | [] | no_license | koleror/model-history | 17736c49e442ed35d941f6f91001f937e70d79d4 | 44cfe386486ba1e84bc142c12e962f3bbf6f43a7 | refs/heads/master | 2021-01-02T23:07:26.674177 | 2015-08-20T19:54:26 | 2015-08-20T19:54:26 | 41,084,768 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 256 | py | #!/usr/bin/env python
import os
import sys
if __name__ == "__main__":
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "model_history.settings")
from django.core.management import execute_from_command_line
execute_from_command_line(sys.argv)
| [
"defrance.hugo@gmail.com"
] | defrance.hugo@gmail.com |
26ca04971196860ed518734f0badf8c96387e75f | 64a919d43541b0114c3158afdb7b2f7fc98bd766 | /demo/countries/models.py | 8b8b46312e7c0e242f425f8239f7218f42c3cedf | [] | no_license | finebrush/takeatripsDA | 377c02330f0c29497d51e1e59c81a99606537e4f | 1b0a92ccbab25427d0274f1f812c91dfb3cc1dfb | refs/heads/master | 2022-12-25T07:22:24.645429 | 2019-12-02T06:44:56 | 2019-12-02T06:44:56 | 220,358,879 | 0 | 0 | null | 2022-12-08T06:50:42 | 2019-11-08T01:08:51 | JavaScript | UTF-8 | Python | false | false | 1,980 | py | from django.conf import settings
from django.db import models
from django.utils.translation import gettext_lazy as _
from demo.countries.choices import COUNTRY_TYPES
import uuid
class Country(models.Model):
name = models.CharField(_('Name'), max_length=64)
picture = models.ImageField(_('Picture'), null=True, ... | [
"finebrush.mlab@gmail.com"
] | finebrush.mlab@gmail.com |
15f50699320bda493f34379b9861414c24e815ce | 5f983115d507b2d6dc453e66bcb6d9f36c2b67f3 | /lambdaScripts/jobIssuer/lambda_function_v2.py | 20358b11647084966909af45153cb623e3b22fd8 | [] | no_license | TheMatrix97/CCBDA-Project | d51df1e17ad9cd5c72e5310f30dc35df227d5f39 | 3214ce9f149a70cd3f05f1a961dea6fb3f709452 | refs/heads/main | 2023-05-25T08:33:28.927858 | 2021-05-29T15:13:31 | 2021-05-29T15:13:31 | 364,298,823 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,961 | py | import json
import boto3
client = boto3.client('ecs')
def lambda_handler(event, context):
input_data = json.loads(event["body"])
res = {
'statusCode': 404,
'body': json.dumps("Method not implemented")
}
if input_data['command'] == "run":
if not exists_running_task():
... | [
"marc.catrisse@upc.edu"
] | marc.catrisse@upc.edu |
c688e3c586687d77aeb0923ad881816739ef16ac | d8dfb0a9c6bc69aa814a39339aebe774376f61ba | /dyndnsc/updater/noip.py | d5cca6a3c6a7bf8e00eda70923dec2bb1ec1269e | [
"MIT"
] | permissive | uservidya/python-dyndnsc | c2508202ad622ea2d77b3e485392d3a99f8ec2db | e73b45a7c3e4b7fa6a755ab7f3b9f2c3797978f8 | refs/heads/master | 2020-12-27T02:00:48.301037 | 2013-12-17T08:22:20 | 2013-12-17T08:22:20 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 597 | py | # -*- coding: utf-8 -*-
from .base import UpdateProtocol
class UpdateProtocolNoip(UpdateProtocol):
"""Protocol handler for www.noip.com"""
_updateurl = "https://dynupdate.no-ip.com/nic/update"
def __init__(self, options):
self.theip = None
self.hostname = options['hostname']
sel... | [
"pkremer@spurious.biz"
] | pkremer@spurious.biz |
11e8bfaa30fade9e2e8cbdb08801527898eb909f | 163bbb4e0920dedd5941e3edfb2d8706ba75627d | /Code/CodeRecords/2467/60707/313825.py | 9e7d486b1e47bb4e4c41e21933bd802f525f3d33 | [] | no_license | AdamZhouSE/pythonHomework | a25c120b03a158d60aaa9fdc5fb203b1bb377a19 | ffc5606817a666aa6241cfab27364326f5c066ff | refs/heads/master | 2022-11-24T08:05:22.122011 | 2020-07-28T16:21:24 | 2020-07-28T16:21:24 | 259,576,640 | 2 | 1 | null | null | null | null | UTF-8 | Python | false | false | 421 | py | if __name__ == "__main__":
n = int(input())
for i in range(n):
inp1 = input().split()
idx = int(inp1[2])
list1 = input().split(" ")
for j in range(len(list1)):
list1[j] = int(list1[j])
list2 = input().split(" ")
for k in range(len(list2)):
... | [
"1069583789@qq.com"
] | 1069583789@qq.com |
46fea0501fd3da99228b02967ae565548670757e | fc81cbe8e184205b4c38c6f945927cb9b5a763a1 | /20210715_Nadocording.py | 35fd236cc6879f650a4cd0868785f4db9ac0d9d2 | [] | no_license | leeyw9804/1day_1commit | 9107d7ac19b5e565008c810148996209bce75968 | b3a092767924eebfb878a77b077aaff13bf691cb | refs/heads/master | 2023-06-20T07:48:42.017758 | 2021-07-22T09:15:52 | 2021-07-22T09:15:52 | 385,814,495 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 661 | py | import requests
from bs4 import BeautifulSoup
url = "https://comic.naver.com/webtoon/list?titleId=675554"
res = requests.get(url)
soup = BeautifulSoup(res.text,"lxml")
cartoons = soup.find_all("div", attrs={"class":"rating_type"})
# title = cartoons[0].a.get_text()
# link = cartoons[0].a["href"]
# print(title, link... | [
"leeyw9804@naver.com"
] | leeyw9804@naver.com |
a4d1968b323bced963b0652a503afe708cd1172a | bf5850321813743c28e30e2c57cd172c7db2b549 | /point_grouper.py | 033109e2691255e785fb43eefde5029eb5406e70 | [] | no_license | rasake/CLiFFpy | 17bbc18bb5ac62843b514824bb9bea1248a3da11 | f763b6ec93428e269250a3e77422be0b14af1197 | refs/heads/master | 2022-07-09T03:17:34.851304 | 2020-05-14T09:48:30 | 2020-05-14T09:48:30 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,443 | py | import sys
import numpy as np
import cl_arithmetic as cla
GROUP_DISTANCE_TOLERANCE = .1
class PointGrouper(object):
def __init__(self, distance=cla.distance_wrap_2d_vec):
self.distance = distance
def group_points(self, points):
group_assignment = []
groups = []
group_index = ... | [
"tomasz.kucner@oru.se"
] | tomasz.kucner@oru.se |
35fdf253b0ebed1d4eb6a119aec0214ec76c5669 | 21701849de6a4284f05712e1a16fbaf731b317fb | /Eurosat data set creation.py | 3c6e49ccf0b362b5f0e1eea223a3ab13a42020ee | [] | no_license | leslie-toone/EuroSat | 69a914c8de3810af3251d77ddcc0184b08f96d20 | d6893978f71a52745aaa09b5383195c193be926f | refs/heads/main | 2023-05-18T21:16:43.574929 | 2021-06-08T13:04:45 | 2021-06-08T13:04:45 | 375,010,828 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,472 | py | # needed to download a subset of Eurosat data to run on Coursera Project
#found this code at
# https://colab.research.google.com/github/e-chong/Remote-Sensing/blob/master/EuroSAT%20Land%20Cover%20Classification/EuroSAT%20Land%20Use%20and%20Land%20Cover%20Classification%20using%20Deep%20Learning.ipynb
# processing ... | [
"noreply@github.com"
] | leslie-toone.noreply@github.com |
18c82fe5ded0fea0644f6620c0943a1364176281 | 5087b67363fb86005ffbdd6153baa257c15e6c4f | /src/ui/templates/home_map_template.py | ea5ead0b7e46c80ed445431d1c2290d0c895b98c | [] | no_license | juanchitot/domo | 8d015243da88269bd6d1e81896788e800f5e0c5c | 82dc543f342a8c50cd59680f3b570c7fa72037ff | refs/heads/master | 2021-01-22T08:32:54.036451 | 2014-06-22T01:05:59 | 2014-06-22T01:05:59 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 11,874 | py | # -*- coding: utf-8 -*-
# Form implementation generated from reading ui file './templates/home_map_template.ui'
#
# Created: Sun Jul 17 16:46:45 2011
# by: PyQt4 UI code generator 4.7.3
#
# WARNING! All changes made in this file will be lost!
from PyQt4 import QtCore, QtGui
class Ui_Form(object):
def setupU... | [
"juanchitot@gmail.com"
] | juanchitot@gmail.com |
4791043d856e97b2b100ec57dea56971d0aeed70 | d88b70150c2b4f840b5d240fc52cf5fdc320fbba | /snewpdag/plugins/renderers/TimeProfile.py | 2d61277fd121152be0696c77272baa6bd1bf53af | [
"BSD-3-Clause"
] | permissive | woonsinglau/snewpdag | b091fd3a1139f3d36e2a7306b7cdf58f6bdc4c02 | 6ea4795828b03d83b7756e37c789c0997b46b17a | refs/heads/master | 2023-07-10T16:41:32.043099 | 2021-08-23T19:20:13 | 2021-08-23T19:20:13 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,848 | py | """
Time profile renderer.
Configuration options:
in_field: optional, name of dictionary of input data
(otherwise look in payload dictionary itself)
in_xfield: name of data field for x values
in_yfield: name of data field for y values
title: profile title (top of plot)
xlabel: x axis label
... | [
"jeff.tseng@physics.ox.ac.uk"
] | jeff.tseng@physics.ox.ac.uk |
8b94756c525f05c760d71a62298896c0205a615d | 973f552142a150f24d8602cf91e45d5c764e1ddc | /wallpaper.py | 302b3f786853b369845406938a8a274679511cc4 | [] | no_license | fjcarnevale/redditwalls | 534d5f7267b8f37f34b97089f3ef1849a69c619f | 791eeb817fbb22123d0f121f631a3cc8d41954b5 | refs/heads/master | 2021-05-15T01:47:52.724836 | 2017-02-22T02:27:39 | 2017-02-22T02:27:39 | 19,913,350 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,245 | py | from google.appengine.ext import ndb
from google.appengine.api import images
import logging
import urllib
import urllib2
from reddit import RedditPost
from Imgur import Imgur
class Wallpaper(ndb.Model):
name = ndb.StringProperty()
height = ndb.IntegerProperty()
width = ndb.IntegerProperty()
reddit_link = ndb... | [
"fjcarnevale@gmail.com"
] | fjcarnevale@gmail.com |
ba30ef35957bc511059b6499e195315c68c62807 | 9d12082ad67b4f7d8088ea845a4266a3b3a85313 | /7OOP/useslots.py | 86108bc0548bfd0158dbb975a80d6ba8441121b5 | [] | no_license | bberzhou/LearningPython | e6f7ee9d44dae3547008aae33874639970a269a3 | aee82c60696a0ef93a351c7a9cf899387eeb9ce0 | refs/heads/master | 2023-05-14T03:38:44.251665 | 2021-06-06T13:49:59 | 2021-06-06T13:49:59 | 319,500,148 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,473 | py | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
from types import MethodType
"""
正常情况下,当我们定义了一个class,创建了一个class的实例后,
我们可以给该实例绑定任何属性和方法,这就是动态语言的灵活性。先定义class
s.set_age = MethodType(set_age, s) # 给实例绑定一个方法
但是,如果我们想要限制实例的属性怎么办?比如,只允许对Student实例添加name和age属性。
为了达到限制的目的,Python允许在定义class的时候,定义一个特殊的__slots__变量,来限制该clas... | [
"bberzhou@gmail.com"
] | bberzhou@gmail.com |
5a0cd00525e3c3cb0b52c1675cad1f2f129425d9 | 8bd69d678c49a2c8948238c5d40b6926e74d1b85 | /ijosephproject/ijosephproject/wsgi.py | 1ddbe7a7b2778fe66fc4800b6e6377702ef7e0c4 | [] | no_license | CarolineMadison/I_Joseph_Capstone_API | 925a84340d7627ff5b0fd14da3105b9310e13d65 | 4dff9410768d4af001b63987c8a87da4b1f46bef | refs/heads/master | 2023-08-28T23:23:40.783938 | 2020-04-03T03:09:48 | 2020-04-03T03:09:48 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 405 | py | """
WSGI config for ijosephproject 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/3.0/howto/deployment/wsgi/
"""
import os
from django.core.wsgi import get_wsgi_application
os.environ.setdefault('DJANG... | [
"brownleecaroline@gmail.com"
] | brownleecaroline@gmail.com |
271feb2b84b4112e4bd627459950a98dc3607a91 | 7ebde4e79f33057df38f22b14cf1932da45884b5 | /Python/Container With Most Water.py | 2d17e89d9630eaae4ef79c0404c53e2b7e08d24f | [] | no_license | xiaochenai/leetCode | 1400fae8c3033fee71ba0f7ea36acf6555323403 | acca8ed2e9628787468eb15b27f4bd552ee2bffd | refs/heads/master | 2021-01-20T00:58:55.956367 | 2014-10-29T02:44:31 | 2014-10-29T02:44:31 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 687 | py | # Given n non-negative integers a1, a2, ..., an, where each represents a point at coordinate (i, ai). n vertical lines are drawn such that the two endpoints of line i is at (i, ai) and (i, 0). Find two lines, which together with x-axis forms a container, such that the container contains the most water.
# Note: You may... | [
"xzl0036@auburn.edu"
] | xzl0036@auburn.edu |
42b8973417a853d323cb5d8ef0b0f89525ed9a6d | f8981c67954828e4a1a0249fbdcb36d099090cd9 | /Module6/running_system_commands.py | 04cf75695cfd3473026925398e6b279ed502b06d | [] | no_license | shreyakapadia10/Using-Python-to-Interact-with-the-Operating-System | fc67a82bc0950c0d9b2faa39f33c25459f72b505 | 57aef8af9137f6df5bdff76f4d138e527b5b6cbf | refs/heads/master | 2022-12-27T18:39:37.837440 | 2020-10-03T07:04:54 | 2020-10-03T07:04:54 | 300,818,093 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 277 | py | import subprocess
subprocess.run(["date"])
print("subprocess.run(['sleep', '2']) will wait for 2 seconds")
subprocess.run(["sleep", "2"])
print("Trying to list a file that doesn't exist using ls")
result = subprocess.run(["ls", "no_such_file.txt"])
print(result.returncode)
| [
"shreyakapadia8@gmail.com"
] | shreyakapadia8@gmail.com |
295d9752bf723b60685cdbca89a38e56b90d8dc3 | e59fe240f0359aa32c59b5e9f581db0bfdb315b8 | /galaxy-dist/lib/galaxy/jobs/runners/cli_shell/rsh.py | b0f8f686cedc4a0ec40089a03c1d706686c805a4 | [
"CC-BY-2.5",
"AFL-2.1",
"AFL-3.0",
"CC-BY-3.0",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | subway/Galaxy-Distribution | dc269a0258471597d483687a0f1dd9e10bd47448 | d16d6f9b6a8b7f41a218c06539863c8ce4d5a73c | refs/heads/master | 2021-06-30T06:26:55.237251 | 2015-07-04T23:55:51 | 2015-07-04T23:55:51 | 15,899,275 | 1 | 2 | null | 2020-10-07T06:17:26 | 2014-01-14T10:47:28 | Groff | UTF-8 | Python | false | false | 2,376 | py | """
Interface for remote shell commands (rsh, rcp) and derivatives that use the same syntax (ssh, scp)
"""
import logging
import os
import subprocess
import tempfile
import time
from galaxy.util.bunch import Bunch
from galaxy.jobs.runners.cli_shell import BaseShellExec
log = logging.getLogger( __name__ )
__all__ = ... | [
"sabba_88@hotmail.com"
] | sabba_88@hotmail.com |
6cb46e4ef46fcf6d1ad70681126112b9aa1a7a2f | 96c7d259859593efa2db89f7434603f941dcc1d1 | /main/admin.py | 23fd591572d9c84f6055b46656185584e2051029 | [] | no_license | nishadprinja/squawker-django | b688387bf466d942f4914c251c0f2f2d20683a40 | b493223651b9f31f497831bbddaee0b16e356f51 | refs/heads/master | 2021-01-11T11:27:45.074632 | 2016-12-07T05:13:57 | 2016-12-07T05:13:57 | 72,485,860 | 0 | 0 | null | 2016-10-31T23:12:55 | 2016-10-31T23:12:55 | null | UTF-8 | Python | false | false | 209 | py | from django.contrib import admin
from .models import Squawk
class SquawkAdmin(admin.ModelAdmin):
list_display = ('message', 'time')
# Register your models here.
admin.site.register(Squawk, SquawkAdmin)
| [
"np327@cornell.edu"
] | np327@cornell.edu |
8036f2a754eff7c3f8a0f966552344286da13109 | fb76a350867ce54c238eb308072863ba30ca963f | /blogweb/templatetags/__init__.py | 164a81f67d0807fd8adf841b37d12d59c7ea29a8 | [] | no_license | Mayankmansha61/blogproject | 3b241889794e644fc6a57dc20a717742d2c10a39 | a9582a1bec3f0220197dd83e1e5c7c0d301e9b98 | refs/heads/master | 2020-06-23T23:34:38.523475 | 2019-07-25T08:07:06 | 2019-07-25T08:07:06 | 198,785,397 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 24 | py | from .query_data import* | [
"mayankbhargav1919@gmail.com"
] | mayankbhargav1919@gmail.com |
c9c25fcb8aae1505003866b2b770810e6a17a3dc | 5f0c43ee76bf8465aa66c51183b2d4aae83c8294 | /cml/models.py | dff17ebe32ba20f2470998a9021c33949d085fc5 | [
"BSD-2-Clause"
] | permissive | mikamiel/django-cml | 9769012956f34ea6cea5e1aef275ed680d0853a3 | 2f7bd597db937365e2d642f81063cf891e312b0d | refs/heads/master | 2020-08-07T10:22:40.515044 | 2019-10-02T07:42:43 | 2019-10-02T07:42:43 | 213,410,148 | 0 | 0 | null | 2019-10-07T14:46:49 | 2019-10-07T14:46:49 | null | UTF-8 | Python | false | false | 757 | py | from __future__ import absolute_import
from django.db import models
from django.conf import settings
class Exchange(models.Model):
class Meta:
verbose_name = 'Exchange log entry'
verbose_name_plural = 'Exchange logs'
exchange_type_choices = {
('import', 'import'),
('export', ... | [
"artem.merkulov@gmail.com"
] | artem.merkulov@gmail.com |
9e883ec19a4d9b1f4eb852f53c30ab1e8894bf01 | 83303b3d43e4f2090e42f337f4aeb535dd1fbc7a | /a_power_N.py | af0ebf0c6a6a2d97ca502367ee0ed5e3b33018b0 | [] | no_license | chen2319/python_knight_dialer | 00630bce7027db7d4ed77924b2895185d9a9f5d0 | 71dc96d4abb5224cc73f41fa49db18e6af88256e | refs/heads/master | 2020-04-02T20:14:14.760950 | 2018-11-20T03:55:10 | 2018-11-20T03:55:10 | 154,762,120 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,519 | py | # 算法问题描述: 计算a的N次方, N为整数
import time
# 算法1:直接暴力计算,不解释
# O(n) (3的400000次方,6秒左右 (Mac Pro))
def a_power_n_1(a, n):
res = 1
i = 0
while i < n:
res = res * a
i = i + 1
return res
# 算法2:分治法,考虑N是奇数还是偶数。偶数 f(n) = f(n/2)*f(n/2), 奇数 f(n) = f(n-1/2)*f(n-1/2)
# O(logN) (3的400000次方,0.3秒左右 (Mac P... | [
"yangch3@cisco.com"
] | yangch3@cisco.com |
5f417589e0415b83f561b35af56742aa54ca7b5a | aa6e885d78fd68f9132bfe373eb58c42117cb11e | /MitsuiSumitomo/A.py | e0648ad9006215dfc0a3e9d24e0c4eb3301c86eb | [] | no_license | Arcprm4/HelloGit | a7beb3ab6a3d0b82e7aa23147e86ce2c0eadb5bd | 84ec5c8ebee2e9d7fe676445775e566bae694e1c | refs/heads/master | 2020-11-30T06:27:05.243440 | 2020-02-01T23:10:42 | 2020-02-01T23:10:42 | 230,331,818 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 364 | py | import math
import collections
import itertools
import sys
import bisect
from heapq import heappop,heappush,heapify
sys.setrecursionlimit(10**6)
def MAP(): return list(map(int,input().split()))
def INT(): return int(input())
def FLOAT(): return float(input())
MOD = 10**9+7
m1,d1 = MAP()
m2,d2 = MAP()
i... | [
"te2dshin@gmail.com"
] | te2dshin@gmail.com |
e7cba753f66de4c18380a281e36285c32cab048c | 35235f241d8626db8dc9a8acb47942bfc6130782 | /main/middlewares.py | f2ac9fb94c8d06986d46cb17b799d0f408c593b9 | [] | no_license | shbviews/RESTOCK-MONITOR | b771bddfe9c7d0240296ecb1272f35ccbe1b3db6 | d02fbdef60e8db0f7cdd8317d2322523675db4a3 | refs/heads/master | 2021-04-24T20:54:17.780167 | 2017-11-03T06:54:02 | 2017-11-03T06:54:02 | 117,135,194 | 6 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,094 | py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
# Sneaker Notify
# author - Yu Lin
# https://github.com/yulin12345
# admin@yulin12345.site
# Define here the models for your spider middleware
#
# See documentation in:
# http://doc.scrapy.org/en/latest/topics/spider-middleware.html
from colorama import Fore, Style
from ... | [
"admin@yulin12345.site"
] | admin@yulin12345.site |
e6fc96486cceb79968c2bdc05c4bca8b68bd2196 | d5e7d991dc853612e74869d81059ab5f162d7f59 | /gen2-human-pose/main.py | 638c123245a6b3888ac020ed31d8532b2fe04219 | [
"MIT"
] | permissive | AMB-technology-playground/depthai-experiments | b0ca1d3e7f531db7d51b4edac95d8d5aa5fd5fa3 | b3f72a2a1dfc27f3c55d987482141db6815c0f0c | refs/heads/master | 2023-09-05T23:00:21.804683 | 2021-10-15T09:42:17 | 2021-10-15T09:42:17 | 415,680,320 | 0 | 0 | MIT | 2021-10-10T19:25:12 | 2021-10-10T19:25:11 | null | UTF-8 | Python | false | false | 6,923 | py | import argparse
import threading
from pathlib import Path
from depthai_sdk.managers import PipelineManager, NNetManager, BlobManager, PreviewManager
from depthai_sdk import FPSHandler, Previews, getDeviceInfo, downloadYTVideo
from pose import getKeypoints, getValidPairs, getPersonwiseKeypoints
import cv2
import depth... | [
"noreply@github.com"
] | AMB-technology-playground.noreply@github.com |
3386aa1a676bffd3f77461d5c78939e3d8d3b997 | 74b97e20b06a58ada94278f82ce511403fcddf21 | /test/scenarios/kusto/output/ext_default_folder/src/kusto/azext_kusto/generated/action.py | cd132ab68ad34d41cac5d438142449e4f78d287f | [
"LicenseRef-scancode-generic-cla",
"MIT"
] | permissive | Azure/autorest.az | b171eb495efdb815dc051dface3800c3e5e35b8e | 64f403a5fe74be28e46a90b6b77f8d2bc9a12baf | refs/heads/master | 2023-09-01T13:22:21.784354 | 2022-11-01T02:34:12 | 2022-11-01T02:34:12 | 226,059,721 | 24 | 17 | MIT | 2023-02-08T00:46:07 | 2019-12-05T09:04:00 | Python | UTF-8 | Python | false | false | 10,230 | 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"
] | Azure.noreply@github.com |
85de6259bd21760c8e6bdb9417861277e6c5a064 | bdf7bc061652e3683d0fc9d021ff30357bf2aeb5 | /spinoffs/oryx/oryx/core/interpreters/inverse/core.py | b624cc2f4853479ef46f16d61e7c1851cc3389f8 | [
"Apache-2.0"
] | permissive | danbaker76/probability | 1843e8f81d93579ceca25080ff7ac5ce3024482d | 64203e2668703220168abeae82c3ac1e9b50424c | refs/heads/master | 2022-11-29T06:29:17.878450 | 2020-08-05T05:23:10 | 2020-08-05T05:24:16 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 13,316 | py | # Copyright 2020 The TensorFlow Probability Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law o... | [
"gardener@tensorflow.org"
] | gardener@tensorflow.org |
fe7aaf443019bb4a2a55ba525bbd0e0e5ae91a3f | 3965ebf2125cfe1ee375f9ed6c4be393e780f482 | /process/CubeConstants.py | 61b613bc8bcf6a5c97876680c977a4dee4cf1ced | [] | no_license | treephones/RubikMosaic | 37a909b0e50685635d8d6800e735b994c99adf8b | 989830b97ed4dd77cb9765b789a084f763914675 | refs/heads/master | 2023-07-05T16:48:18.270905 | 2021-08-14T21:15:50 | 2021-08-14T21:15:50 | 373,982,965 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 434 | py | VERTICES = (
(1, -1, -1),
(1, 1, -1),
(-1, 1, -1),
(-1, -1, -1),
(1, -1, 1),
(1, 1, 1),
(-1, -1, 1),
(-1, 1, 1),
)
EDGES = (
(0,1),
(0,3),
(0,4),
(2,1),
(2,3),
(2,7),
(6,3),
(6,4),
(6,7),
(5,1),
(5,4),
(5,7)
)
FACES = (
(0,1,2,3), #RE... | [
"moezbajwa@hotmail.com"
] | moezbajwa@hotmail.com |
f6710cab1e177e9f9db7f1ca51161835ab62137c | bf4b911f97aa4796508bddc1331d0ac8c0ae9dd5 | /quickreport/gui_utils.py | 59c7ebd0010bb66861efc54d6b83c159bc09d8c2 | [
"ISC"
] | permissive | ricpol/quickreport | d8b42944c2c3d25c552fbb8d105d8b7fb838718c | d59c860f128a723b4b024242bb0bc49c62f8a688 | refs/heads/master | 2021-03-13T00:01:57.530891 | 2012-12-04T14:23:34 | 2012-12-04T14:23:34 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 767 | py | # -*- coding: utf8 -*-
"""Quickreport
Utilita' per la gui di Quickreport.
==========================================
:version: vedi quickreport.__version.py__
:copyright: Riccardo Polignieri 2012
:license: ISC
"""
import wx
import wx.lib.newevent
def ask_path(parent_window):
dlg = wx.FileDialog(parent_window, m... | [
"ric.pol@libero.it"
] | ric.pol@libero.it |
a58977ab0eab755a78944597ba8efe93299a9cc7 | cb47dc98d6789b17398ec12b9c27905a9ab2ff1f | /scanner.py | 77d6df1fc028a71f4246f380187f1b3ee3a28358 | [] | no_license | nebstarmalala/network_scanner | 5b0ca1b517d3bab6d0ec097e38b9387e2e6e8dd8 | cac91d397e0182ec427bec811fd1d1651050e740 | refs/heads/master | 2022-12-18T16:10:47.778524 | 2020-08-30T18:57:28 | 2020-08-30T18:57:28 | 291,532,833 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,168 | py | #!/usr/bin/env python
import subprocess
def bash(command):
return subprocess.check_output(['bash', '-c', command])
def nmap_scan(ip):
print("Scanning TCP ports on " + ip)
print("------------------------------------\n")
res = bash('nmap -T4 -p1-65535 %s | grep"open"' % ip).splitlines()
ports = []
... | [
"nebstartrizzle@gmail.com"
] | nebstartrizzle@gmail.com |
da01e6382b6d4724c849c3608ea60a9335ad79bf | 49d904eda93c11c4563d6d9b257246d5907b562c | /food_platform/migrations/0001_initial.py | 9a0735fdee6e77b18b1d2428ed5c8f1278c79a48 | [] | no_license | abrusebas1997/realreal | b182586e31051b5a1e8e8f8e7010c98f0b4033d1 | 3f3771e44cd0c6e7150bc986e2b38eff404bff11 | refs/heads/master | 2022-11-18T04:49:53.218561 | 2020-07-20T07:50:40 | 2020-07-20T07:50:40 | 278,265,723 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,804 | py | # Generated by Django 2.2.7 on 2020-07-20 06:56
from django.conf import settings
import django.contrib.auth.models
import django.contrib.auth.validators
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
class Migration(migrations.Migration):
initial = True
... | [
"sebastianabarca@Sebastians-MacBook-Pro.local"
] | sebastianabarca@Sebastians-MacBook-Pro.local |
f0843180bc9b65d61f04683f3da57a11775d3631 | f0b8a36f343ff94b04a8dda3cf1629f9faf11c83 | /Simple Text classifiers/20Newsgroup dataset based basic DNN Classifiers/20ng_classifier - RNN.py | 53b9868ad73dbbab96cf2cd30f4990068370fa41 | [
"MIT"
] | permissive | tejasurya/Text_Classification_using_Neural_Networks | 0731c82c867b59fb4682a1482b104f1b0f61215c | d4852780e6c86843aee768d306d19428c8cb9c7f | refs/heads/master | 2022-04-25T11:01:54.775855 | 2020-04-28T10:09:06 | 2020-04-28T10:09:06 | 259,592,758 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,693 | py | # -*- coding: utf-8 -*-
"""
Created on Tue Feb 6 15:55:01 2018
@author: HP
"""
# -*- coding: utf-8 -*-
"""
Created on Mon Feb 5 14:31:43 2018
@author: HP
"""
import os
import pandas as pd
import nltk
import gensim
from gensim import corpora, models, similarities
from nltk.corpus import stopwords
from nltk.tokeniz... | [
"hltejasurya@hotmail.com"
] | hltejasurya@hotmail.com |
cd2cb50e8b49ee90f5cbf9eeb526f2f1166169e7 | ce083128fa87ca86c65059893aa8882d088461f5 | /python/pytest-labs/.venv/lib/python3.6/site-packages/facebook_business/adobjects/adruleevaluationspec.py | 4480f554fadb01249a0b941d34d8e43f3d4e8247 | [] | no_license | marcosptf/fedora | 581a446e7f81d8ae9a260eafb92814bc486ee077 | 359db63ff1fa79696b7bc803bcfa0042bff8ab44 | refs/heads/master | 2023-04-06T14:53:40.378260 | 2023-03-26T00:47:52 | 2023-03-26T00:47:52 | 26,059,824 | 6 | 5 | null | 2022-12-08T00:43:21 | 2014-11-01T18:48:56 | null | UTF-8 | Python | false | false | 2,133 | py | # Copyright 2014 Facebook, Inc.
# You are hereby granted a non-exclusive, worldwide, royalty-free license to
# use, copy, modify, and distribute this software in source code or binary
# form for use in connection with the web services and APIs provided by
# Facebook.
# As with any software that integrates with the Fa... | [
"marcosptf@yahoo.com.br"
] | marcosptf@yahoo.com.br |
b5de1597546ebf95d936671f6c05e9fd990fff3f | e49edb54a747c33b95108872de2536cce9ee3ec1 | /src/evaluate/non_rg_metrics.py | 1216e61dd116063b993a0f848f2ea8345b284651 | [] | no_license | anusha66/TextGen-Deep-Learning | 74714f4bd2f0728664863f1f5acc1b8cb5c68856 | a1cfad2d40d3bd5067508696acffddb74b0d5421 | refs/heads/master | 2021-04-05T23:59:33.562388 | 2018-05-27T00:03:53 | 2018-05-27T00:03:53 | 124,617,587 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,331 | py | import sys
from pyxdameraulevenshtein import normalized_damerau_levenshtein_distance
full_names = ['Atlanta Hawks', 'Boston Celtics', 'Brooklyn Nets', 'Charlotte Hornets',
'Chicago Bulls', 'Cleveland Cavaliers', 'Detroit Pistons', 'Indiana Pacers',
'Miami Heat', 'Milwaukee Bucks', 'New York Knicks', 'Orlando Magic',... | [
"ubuntu@ip-172-31-10-194.us-west-2.compute.internal"
] | ubuntu@ip-172-31-10-194.us-west-2.compute.internal |
5a0258d2f04e9677afeaca8f0973b94b89eac1e4 | 1063018a00e9aef63402a4e76102c6ab0dce9302 | /my3_1.py | 88bd705027147a51c80df1166aef959b71aa5988 | [] | no_license | seoeugenee/algorithmStudy | 8b48864633b322786c8346730e29b8bc00127457 | 00e2d8c84097155eb4bd4c236e3afa3e3ac53977 | refs/heads/main | 2023-07-17T23:55:37.826323 | 2021-08-31T16:31:48 | 2021-08-31T16:31:48 | 400,388,241 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 117 | py | n = 1260
count = 0
money = [500, 100, 50, 10]
for m in money:
count += n // m
n %= m
print(count)
| [
"noreply@github.com"
] | seoeugenee.noreply@github.com |
56d35a738ab699c2cc0e2d1cfdf90e576b4a8f65 | 7507795830d4113bfd63c73fb764bb967edec266 | /desafio_032.py | 32431ab67f9b2487c5e3c036d834d184290b1113 | [] | no_license | OtherU/Python_Cursos_online | e631ed99ddb04d0e69465d1c7be3147fa8678209 | 796c044a33a227cdc368c27f8fc984413f075a18 | refs/heads/master | 2020-05-18T12:52:32.543779 | 2019-05-01T13:39:48 | 2019-05-01T13:39:48 | 184,421,457 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 588 | py | # ------ Modules ------ #
from datetime import date
# ------ Header & Footers ------ #
header = str(' Desafio 032 ')
subfooter = ('-'*68)
footer = ('='*68)
# ------ Header ------ #
print('{:=^68}'.format(header))
# ------ Body ------ #
ano = int(input('Digite 0 para analisar o ano atual ou digite um ano: '))
print()... | [
"annuit-coeptis@hotmail.co.jp"
] | annuit-coeptis@hotmail.co.jp |
204abf2e1db41b95502b3d8ec44918d588887b80 | 6721542d3cc44c50a5d40e3f3a6ac49b266069d6 | /Python_algorithms_and_functions/sync_v1.py | 5ad281b0d568940d4c02c3988a396f0613d1fb4a | [] | no_license | LuizaM21/Learn_python | c943245b5c2101bf93bb4704dc56c72213b99098 | e9c6f1213de287b671fd6eff20453843cfcd2786 | refs/heads/master | 2021-07-11T19:21:38.613300 | 2020-07-10T19:54:31 | 2020-07-10T19:54:31 | 151,253,553 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,094 | py | """Modul de sincronizare a doua fisere."""
from __future__ import print_function
import sys
import os
import time
import shutil
if len(sys.argv) < 3:
print("Nu am primit 2 parametri")
sys.exit(1)
parametru_1 = sys.argv[1]
parametru_2 = sys.argv[2]
# verifcia daca primul parametru este director
if not os.pat... | [
"luiza.mihaiuc@gmail.com"
] | luiza.mihaiuc@gmail.com |
35114d1d0d2e97b10c9a8423a1abe59454670407 | 6e331f2713952958669aaeaf95bf653582390b54 | /.idea/3.py | 1f4bfb51c3bf243f125498dacd6b23fb69e836e5 | [] | no_license | XQ96/huawei_online_programming | be1576abde9624588a64f382cc8f1fde12d842d5 | 3e0070fc8bfeaa66fcefb5dcb6dab83b0cf6abc2 | refs/heads/master | 2020-04-27T20:38:57.382389 | 2019-03-20T11:24:18 | 2019-03-20T11:24:18 | 174,665,543 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,179 | py | # -*- coding:utf-8 -*-
# @Author:xuqi
# @time:2019/3/7 10:39
# @File:3.py
'''
题目描述
明明想在学校中请一些同学一起做一项问卷调查,为了实验的客观性,他先用计算机生成了N个1到1000之间的随机整数(N≤1000),对于其中重复的数字,只保留一个,把其余相同的数去掉,不同的数对应着不同的学生的学号。然后再把这些数从小到大排序,按照排好的顺序去找同学做调查。请你协助明明完成“去重”与“排序”的工作(同一个测试用例里可能会有多组数据,希望大家能正确处理)。
Input Param
n 输入随机数的个数
inputArray ... | [
"mf1832199@smail.nju.edu.cn"
] | mf1832199@smail.nju.edu.cn |
d981be4bb28ee793707e5fb9eda4573c006d75af | 8d0b4e03c605f517bd92615975806588d4770034 | /tracking/twodim/matutil.py | 0dbfb3e2063ace1e3d159b7e94f1644f14e8252d | [] | no_license | ezhou7/CS563 | 0c2b4c4db94de44a50e2444744c175f39019a0ea | 223cfb5be34d8a8dbf652bb9c9462c34079760a8 | refs/heads/master | 2021-08-23T14:06:04.140224 | 2017-12-05T05:35:56 | 2017-12-05T05:35:56 | 107,323,625 | 0 | 0 | null | 2017-10-18T22:37:22 | 2017-10-17T21:03:03 | Python | UTF-8 | Python | false | false | 541 | py | import numpy as np
from tracking.twodim import bcell
def many_to_many_dists(group1: np.array, group2: np.array) -> np.array:
p1 = group1[:, bcell.BEG_POS_INDEX:bcell.END_POS_INDEX]
p2 = group2[:, bcell.BEG_POS_INDEX:bcell.END_POS_INDEX]
p1 = p1.reshape((p1.shape[0], p1.shape[1], 1))
p2 = p2.reshape(... | [
"noreply@github.com"
] | ezhou7.noreply@github.com |
8be61fd1d4a1401aa590c93db9ba7735e637b88c | b09359f45057a91a4f532c5cb5b1cc44bc86a8e1 | /app.py | 2746a449b48ced0a42534f949fddc1c895208806 | [] | no_license | AnitaVaish/cosmosTracker | 374f081e116aa9e2896b16d7fde23f76c24bcf89 | 109acd614991de801fdf6c21a76d8a391f4f729e | refs/heads/main | 2023-04-22T00:46:19.601138 | 2021-05-15T10:13:34 | 2021-05-15T10:13:34 | 367,356,946 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 1,805 | py | from config import application, scheduler
from schedule_message import schedule_message
from schedule_report import schedule_report
from schedule_users_reset import schedule_users_reset
import tracker_application
from utils.constant_variables import INITIAL_MESSAGE_HOUR, INITIAL_MESSAGE_MINUTES, REPORT_HOUR, REPORT_MI... | [
"anita.vaish@cosmosthrace.com"
] | anita.vaish@cosmosthrace.com |
d3593d8c300ad70e69bb82d3d61b0b2704d1da09 | 6b687ec14f44d5724f5f58696291dcf8f98d8c55 | /lesson2/exmpl_for_3.py | 8ba2987194fa5c769a28a4f857e1ebbde4cd8e9b | [] | no_license | SvyatZanozdra/LP_projects | b215305199b454d74aa070f0586744b4c124a02c | 2e648c700d275e77bc7652ed5690c7699d9db837 | refs/heads/master | 2020-09-21T10:20:24.526915 | 2019-12-08T09:56:16 | 2019-12-08T09:56:16 | 224,763,333 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 393 | py | from exmpl_if_3 import discounted
stock = [
{'name': 'iPhone Xs Plus', 'stock': 24, 'price': 65432.1, 'discount': 25},
{'name': 'Samsung Galaxy S10', 'stock': 8, 'price': 50000.0, 'discount': 10},
{'name': '', 'stock': 18, 'price': 10000.0, 'discount': 10}
]
for phone in stock:
phone['final_price'] = discou... | [
"ZanozdraSV@yandex.ru"
] | ZanozdraSV@yandex.ru |
1eafb2a7ad82c3c27f689f825cced52edcbf1a0c | 46b432cd3557038c454601367b878f889c9b6a8f | /naomi/tutorial13/test_hmm_beam.py | 627af3b1bcdc7893c2fcc0165fd28222731d08bd | [] | no_license | tmu-nlp/NLPtutorial2019 | 84ceec06568fd9d899a686658fb8851466133375 | d77d199c50cd37d70e462209a7bfcd4dee9140a1 | refs/heads/master | 2020-05-14T13:34:05.336594 | 2019-09-25T02:25:41 | 2019-09-25T02:25:41 | 181,814,723 | 1 | 0 | null | 2019-08-01T18:53:54 | 2019-04-17T04:04:06 | Python | UTF-8 | Python | false | false | 5,641 | py | from collections import defaultdict
import numpy as np
# 入力
# train-input.txt
# a_X b_Y a_Z
# train-answer.txt
# T <s> X 1.000000
# E X a 0.666667
def train_hmm():
in_path = '../../test/05-train-input.txt'
in_path = '../../data/wiki-en-train.norm_pos'
out_path = 'trained_model.txt'
emission = defaultd... | [
"naomi@komachi.live"
] | naomi@komachi.live |
d37a223d39efa8a3b2a59efcd47746197fd813f0 | 59754dd50b71346da2b26d77eb5ad33d55ec4cbc | /models.py | 5d529df7f1d044a98f66dcdf3b6b01eec45383d6 | [] | no_license | AllenCall/ICBC | 4380d431d40b45b13ef4d5494a4302d7fa9df12f | d1ac3037dd352d7cd0b399f0bb868a48d470177e | refs/heads/master | 2020-09-21T09:54:01.795286 | 2019-12-04T01:34:30 | 2019-12-04T01:34:30 | 224,552,485 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,072 | py | from exts import db
class User(db.Model):
__tablename__ = 'user'
id = db.Column(db.Integer,autoincrement=True,primary_key=True)
email = db.Column(db.String(50))
userName = db.Column(db.String(50))
passWord = db.Column(db.String(10))
balance = db.Column(db.Float,default=0)
article_tag_table = d... | [
"310315734@qq.com"
] | 310315734@qq.com |
2f095febfca64956c65edf32419e1d73c16ff423 | 88928147ef247c4112caa08cc4a20d262d614066 | /src/reportgen/reportgen.py | 67c891f410ebd1b961b7ca2b9822700dc2b1a116 | [] | no_license | HSIYJND/TreeCrownDelineation | 0d5671f7be846b9a7af32b84b03617f921e57335 | 0d628a80fe055556488ac7b119d79c22297782f2 | refs/heads/master | 2021-06-22T04:54:44.792478 | 2017-08-27T21:49:51 | 2017-08-27T21:49:51 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 12,076 | py | '''
Created on May 1, 2017
@author: arvind
'''
from jinja2 import Environment, FileSystemLoader
import datetime
import numpy as np
from weasyprint import HTML
import cv2
import georasters as gr
from matplotlib import pyplot as plt
import gdal
import shapefile
from osgeo import osr
import pylab as py
from os import li... | [
"Nishant Agarwal"
] | Nishant Agarwal |
21f0e590ada159ab80fccd55fd6750e45b800aad | d75c1f9645c8c80ca33c0c461e3c39ea3ec30b9b | /app/recipe/tests/test_tags_api.py | d48d403914c6f5977bd13278c1c83f52672fca68 | [
"MIT"
] | permissive | ahrav/recipe-app-api | f47af2c99ced8cf6e9e193744b56557a81922379 | 31c0ff9bda5b12113c78eb314549c2cb0243db25 | refs/heads/master | 2020-05-27T05:50:21.674371 | 2019-06-22T13:12:50 | 2019-06-22T13:12:50 | 188,508,173 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,018 | py | from django.contrib.auth import get_user_model
from django.urls import reverse
from django.test import TestCase
from rest_framework import status
from rest_framework.test import APIClient
from core.models import Tag, Recipe
from recipe.serializers import TagSerializer
TAGS_URL = reverse('recipe:tag-list')
class ... | [
"ahravdutta02@gmail.com"
] | ahravdutta02@gmail.com |
efae90dda347c3f09c8f1505cdd2780152074765 | 7a5ddd25569adc8d48fb5abdb5786dafd760e0e2 | /env/bin/pyrcc5 | 8bb2f6faec39aa12284c097f045778c77c4134d6 | [] | no_license | roblivesinottawa/MoviesDatabasePyQt | 07c064be7a0cb187a4e287a61b9e426b81856edb | cf10721cee7075b12afe2b77520830382f389dba | refs/heads/main | 2023-05-01T18:39:54.426668 | 2021-05-12T18:31:50 | 2021-05-12T18:31:50 | 366,515,885 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 300 | #!/Users/macbookpro/Desktop/programming/may(2021)/MovieDatabasePyQt/movies_database_gui/env/bin/python3
# -*- coding: utf-8 -*-
import re
import sys
from PyQt5.pyrcc_main import main
if __name__ == '__main__':
sys.argv[0] = re.sub(r'(-script\.pyw|\.exe)?$', '', sys.argv[0])
sys.exit(main())
| [
"tech.rob@icloud.com"
] | tech.rob@icloud.com | |
81fee8688ffc59c38c493d59ce1bb7103d87c201 | fc7023a9c35ca34e682e9fb1b4d97f4a0a7064d4 | /demo/classes.py | 1806e9ffd858257725ec6c748f7d8a8b442c52db | [] | no_license | fredcollman/sublime-config | 22472551806f7f9b9e3cd009cfdced49930878c5 | bcee840b95e05e37b445724c2e576bae6b6b16e9 | refs/heads/master | 2021-01-19T09:02:36.379880 | 2017-08-11T14:12:20 | 2017-08-11T14:12:20 | 87,714,232 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 616 | py | class Hello:
"""Remember to include docs"""
def __init__(self, arg):
self.arg = arg
class Goodbye:
some_attr = False
def scope(self):
return "this is a method"
def nest_scope(self):
for thing in range(10):
for another in "string":
yield... | [
"fredcollman@gmail.com"
] | fredcollman@gmail.com |
fff80535ba22ef4b7f28c7d8d2d614570d6ad082 | 52c35b0715b216a3bf901d4a468fa74b104953b6 | /3-绘图函数/ellipse.py | a63676e249413ca982a16ca5706a334edcdb2a95 | [] | no_license | McFlyWYF/opencv-for-python | 3d05886b4eb02352f9d1c3dd6cf58d18570c9e6c | 478c103bb422e25547fe0683dfb4b4043cdbbc20 | refs/heads/master | 2020-03-27T15:01:21.736794 | 2018-09-29T13:55:18 | 2018-09-29T13:55:18 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 351 | py | import cv2
import numpy as np
'''
矩形
'''
img = np.zeros((512,512,3),np.uint8)
#中心点坐标,长轴和短轴长度,沿逆时针方向旋转的角度
cv2.ellipse(img, center=(256, 256), axes=(100, 50), angle=0, startAngle=0, endAngle=180, color=255,
thickness=-1)
cv2.imshow('image',img)
cv2.waitKey(0)
cv2.destroyAllWindows() | [
"1650043869@qq.com"
] | 1650043869@qq.com |
94dedfc1b2dffc2c11e82f14a5410aa0e7d7c4f1 | 2b033667a8b0b97d7080f55575169179e48c8cd8 | /D01.py | c33083251fb32bce8f1d026235ad79e758e3582e | [] | no_license | aa033793336/python | 277c4413b7d0f396a87495464bd6fb1c9f6b50f6 | 30776659c12354de75c02daa6a1db4ebde98eea9 | refs/heads/main | 2023-03-07T17:51:23.188021 | 2021-02-19T01:53:04 | 2021-02-19T01:53:04 | 330,838,673 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 109 | py | import numpy as np
#D01#1
a = np.arange(0,21,1)
print(a)
#D01#2
b=a[::2]
print(b)
#D01#3
c=a[::3]
print(c) | [
"75462113+aa033793336@users.noreply.github.com"
] | 75462113+aa033793336@users.noreply.github.com |
dd04c8572915ba1c43e29a3fe90bfbfb03645720 | 144565da9ebb7dc07e781fc09dbb7d83fc434eb4 | /lintcode algo ladder/608. Two Sum II - Input array is sorted.py | e5fe6c00e94890a42634716e88b0943978dbbf39 | [] | no_license | liulehui/LintcodeSolution | 853ed81667dfa5aabbb20fd6e677285f90716ef6 | b9bf9b4192bd2130824193a0088c4f2ab396310f | refs/heads/master | 2020-04-14T00:06:40.704674 | 2019-08-23T06:03:39 | 2019-08-23T06:03:39 | 163,524,911 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 435 | py | # coding:utf-8
def twoSum(self, nums, target):
# write your code here
left,right = 0,len(nums) - 1
while left<right:
if nums[left] + nums[right] < target:
left += 1
if nums[left] + nums[right] > target:
right -= 1
... | [
"imliulehui@gmail.com"
] | imliulehui@gmail.com |
f057ed39140d159384543a563041daf49702ac65 | eeacfabfb918c9b0f922a4f6a96e50e63f029fad | /search_engine.py | 419fe701ec44fda3b35011c0be75a83a1e1fdee9 | [] | no_license | lch743/Python | f36af505f24cd88ab9900354d14f6a62f71f108c | c5bf64def9703842eefab2423347d16a9ae4478d | refs/heads/master | 2021-01-20T15:44:20.024352 | 2012-12-11T08:07:16 | 2012-12-11T08:07:16 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,291 | py | #Feeling Lucky
#In Unit 6, we implemented a page ranking algorithm, but didn't finish the final
#step of using it to improve our search results. For this question, you will use
#the page rankings to produce the best output for a given query.
#Define a procedure, lucky_search, that takes as input an index, a ranks
#d... | [
"lch743@gmail.com"
] | lch743@gmail.com |
749cd9a3101a7cb68ab10d36816e911dddd50b77 | 3118d4fc5078e96fd71b408f03aa5ed9aecdc2df | /common/common_fun.py | 2cb04b34046c85f4bd3d5f575cfef83c919d80cd | [] | no_license | chengming0719/zhanyebao_app002 | 28bcf651f43a2838d6f3c82f89ca76bb8047edb7 | 37883e2643c69b9b06192ad31682fdda93fee665 | refs/heads/master | 2023-01-07T11:41:23.489839 | 2020-11-09T07:37:49 | 2020-11-09T07:37:49 | 311,258,568 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,606 | py | from baseView.baseView import BaseView
from common.desired_caps import appium_desired
from selenium.common.exceptions import NoSuchElementException
import logging, time, csv
from selenium.webdriver.common.by import By
from os import path
class Common(BaseView):
cancelBtn=(By.ID,'android:id/button2')
skipBtn=(B... | [
"18296158516@163.com"
] | 18296158516@163.com |
e03af5270cca1a0058b33f9fa5933d1aee3d2b07 | 77e78a55375bc515ed6b2c247d8cf4bec05d3bc8 | /sloane_amazing_graphs/fly_straight_dammit.py | 4f5ac9d6e2cc4e84999405af1872cbbff1fd685f | [] | no_license | GuidoDipietro/python_art | 63079df616726fee21ee13cbe501c4b01aa0bd5b | 5d9be0f1c697922c111eb3417157fb65516bb68c | refs/heads/master | 2022-12-09T03:32:05.037248 | 2020-09-07T14:27:34 | 2020-09-07T14:27:34 | 289,156,751 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 567 | py | # Fly straight, dammit!
# https://oeis.org/A133058
# 31/aug/2020 | Guido Dipietro
import matplotlib.pyplot as plt
# CONSTS #
COLOR = "#b20000"
POINTS = 1200
# SEQUENCE DEFINITION #
def divs(n):
return set([x for x in range(2,n+1) if n%x==0])
def genner(ind, n):
div = divs(n) & divs(ind)
if ind<2: num = 1
els... | [
"dipietroguido@gmail.com"
] | dipietroguido@gmail.com |
6576f6ade43f4f4218e63728c5722a9762a7b0f2 | 86cb696cc44c45ecd9f707d620e9b92f9eebb91f | /main/examples/grid.py | f5f63e5b4e6eb30653cb0201c51e3448bc5b90ed | [] | no_license | etschgi1/GOL | 1032c9b9e9f28c3ff6f125f770581a4a77c88670 | bdbe5fc31066195cab356f88e1f158193eaa6c62 | refs/heads/master | 2023-02-09T01:53:30.586337 | 2021-01-05T21:02:07 | 2021-01-05T21:02:07 | 326,028,640 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 370 | py | from tkinter import *
root = Tk() # window initialises
test_label = Label(root, text="Hello World!").grid(
row=0, column=0) # create a widget, also valid bc obj oriented
test_label2 = Label(root, text="Test Text") # create a widget
# use grids
# same as row = 1 col = 5 only relative position
test_label2.grid(r... | [
"elias.wachmann@gmail.com"
] | elias.wachmann@gmail.com |
e6d928ad07d679a7f2fe24fcd018ad39e11ec5c1 | 305567bc6e1f8c771fcf299a743f26e9e90ef268 | /character/character_eval.py | 7decbf79a3477af57dae5e6d047d26e59df1ba9c | [] | no_license | gugug/tensorflow_demo | ee6a1a5d53dc84fb7f4f359dc6843aa0ee57d763 | c027dbf2f85be6f6ada740240db9b5082268e42e | refs/heads/master | 2021-04-26T22:21:59.658150 | 2018-09-05T14:37:56 | 2018-09-05T14:37:56 | 124,079,845 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 8,440 | py | # coding=utf-8
"""
测试过程
"""
import character
__author__ = 'gu'
import time
import tensorflow as tf
import character_inference
import numpy as np
import input_data
from crawl_textmind_data import input_textmind_data
from Emotion_Lexicon import data_helper
MOVING_AVERAGE_DECAY = 0.99 # 活动平均衰减率
MODEL_SAVE_PATH = "char... | [
"734093894@qq.com"
] | 734093894@qq.com |
ade516ca679c9523f360daeceed1aef37c571bbd | 6a52627de2f88be818d3517847d84f20827bfa99 | /clients/models.py | 2eb0aeb32ed5f363e45e26228fbffdb74fb6b2cb | [] | no_license | rizwanmeo/sabzi_mandi | 46a8a3c6516a3aa4b234342dbd2328e96ce86a24 | cd801fd9ffebceff051791ecee6486468d9cdbf7 | refs/heads/master | 2023-04-29T05:49:17.670068 | 2023-02-05T16:02:32 | 2023-02-05T16:02:32 | 231,114,753 | 0 | 0 | null | 2023-04-21T22:34:15 | 2019-12-31T16:04:41 | Python | UTF-8 | Python | false | false | 274 | py | from django.db import models
from shops.models import Shop
from sabzi_mandi.models import BasicInfo
class Client(BasicInfo):
shop = models.ForeignKey(Shop, on_delete=models.CASCADE)
class Meta:
unique_together = [('shop', 'name'), ('shop', 'identifier')]
| [
"rizwan_meo@rocketmail.com"
] | rizwan_meo@rocketmail.com |
3488f61c7f8dbd0d52a96c6bd8d46df6dbcdb89e | b6542f17c21b76aa237fefcfa303105922602ce5 | /Tasks/Statistic/81_linear_regression.py | c667538f6e0009b989be1626c6a0c45f82dc1538 | [] | no_license | AV272/Python | 9b1963c798c491f86e0f73b2b684ec444b761d6f | b66e79bd9c4814cc286e48ecad70591865024baf | refs/heads/master | 2023-06-08T14:47:26.292007 | 2021-07-05T11:28:39 | 2021-07-05T11:28:39 | 283,837,397 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 271 | py | x = [95, 85, 80, 70, 60]
y = [85, 95, 70, 65, 70]
n = len(x)
sumx = sum(x)
sumy = sum(y)
mx = sumx/n
my = sumy/n
sumx2 = sum(map(lambda x: x**2, x))
xy = sum([x[i]*y[i] for i in range(n)])
b = (n*xy - sumx*sumy)/(n*sumx2 - sumx**2)
a = my - b*mx
print(round(a + 80*b,3))
| [
"noreply@github.com"
] | AV272.noreply@github.com |
0fa68f4a8ee766434f5c0958d2a0b2b6b4571a32 | 83ef08951ce01c53a3a794bdf0f03a1a2ba195ea | /ml_api.py | 5bfee834172a3567e3fbf3f9c63c53c157c7bd44 | [] | no_license | chart90/movielens-stream-search | 8f4e81dd8b8f56a16a6913cc9e93302e3a99ecaa | 442d665627ac7ff0ddd892709aedf85e95c0f059 | refs/heads/master | 2022-12-10T06:21:46.597721 | 2018-02-25T23:30:43 | 2018-02-25T23:30:43 | 122,883,585 | 0 | 0 | null | 2021-06-01T21:49:57 | 2018-02-25T22:27:12 | Python | UTF-8 | Python | false | false | 2,788 | py | import requests
import json
import os
from urllib.parse import urlencode
import pickle as pkl
import config
from time import time
class MovieLens:
def __init__(self):
self.headers = {
'Accept': 'application/json, text/plain, */*',
'Accept-Encoding': 'gzip, deflate',
'Ca... | [
"chrishart90@gmail.com"
] | chrishart90@gmail.com |
503fa6b7abb0cfb33690e14f68ad1975d785840f | b4efe7a85bbde01cd47189bcc0298594baae7a14 | /code/89.py | 4d92fda40c156d24ca30d75475b4fd4045bc92f6 | [] | no_license | HarshaaArunachalam/guvi | c200e05dc0c259bfabfc0ee58c1ab9b6412b89a7 | 67c87e8fe50d645036333649759b5b1a40369004 | refs/heads/master | 2020-05-31T06:27:27.104793 | 2019-06-11T18:31:43 | 2019-06-11T18:31:43 | 190,141,812 | 0 | 2 | null | null | null | null | UTF-8 | Python | false | false | 80 | py | name=input()
name=list(name)
let=sorted(name)
for i in let:
print(i,end="")
| [
"noreply@github.com"
] | HarshaaArunachalam.noreply@github.com |
197073fdfefb60a514635179e44d1d165ed7e417 | b5ca937ce81b8a45e35e57b4a1781816889f4705 | /FactorInt.py | e64d5311c56aa5b595b0bd920e91a00f296f2a26 | [] | no_license | susuk4/Homework2_CholYoon | 4fe5c0d2375fcf7c815a23e9304b9f1d98e5ec60 | 3c3f8f2b7c8c318c101560f213a11aadc07b9b84 | refs/heads/master | 2020-12-24T13:29:00.690774 | 2013-04-22T06:00:27 | 2013-04-22T06:00:27 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,032 | py | class FactorInt:
def __Init__(self, integer):
#initialize class with initial string, and denominator and check if it is integer
if type(integer) == int:
self.n = integer
if not isAlreadyPrime():
self.denominator = [7,5,3,2]
self.string = ""
... | [
"susuk4@uw.edu"
] | susuk4@uw.edu |
5234a4cc2cf0abf2e9f870ed1fb4f98ab451e479 | 5636cb0c282d03e91a830d30cec3bd54c225bd3b | /Divers/TP_SPE_Supplementaires/TD_euler/TD_euler_implicite_explicite.py | b48efbfc92b6aac69464492e094bfc63101c73d2 | [] | no_license | xpessoles/Informatique | 24d4d05e871f0ac66b112eee6c51cfa6c78aea05 | 3cb4183647dc21e3acbcbe0231553a00e41e4e55 | refs/heads/master | 2023-08-30T21:10:56.788526 | 2021-01-26T20:57:51 | 2021-01-26T20:57:51 | 375,464,331 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,909 | py | ### TD sur les méthodes d'Euler explicite et implicite et étude de la stabilité et rapidité
#Importation des modules
import matplotlib.pyplot as plt
import math
import numpy as np
import time
### question 1
#relation de récurrence de la méthode d'Euler explicite yk+1=yk+hf(yk,tk)
# pour l'équation choisie domega/dt=(K... | [
"xpessoles.ptsi@free.fr"
] | xpessoles.ptsi@free.fr |
de8048db0aac82d89d7511c3c607134e5810c5f8 | f82f71fc98c0fb0f26ee05206857be2569140349 | /backend/app.py | 249f3c8e096ea8b815c652913d11cc676e135e3f | [] | no_license | JasonGilman18/Spotify-Mood-Search | 6a43b83b23375d4e71990419f6a98c41a3ba9d9b | e73dd58c37bf12c0cdc839735fcc141abb829c4b | refs/heads/master | 2023-01-10T16:52:58.003698 | 2020-11-17T16:54:11 | 2020-11-17T16:54:11 | 303,192,046 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,574 | py | from flask import Flask, jsonify, render_template
from flask.helpers import send_file
from flask_restful import Resource, Api
from flask_cors import CORS
import os.path
import rank
app = Flask(__name__, static_folder="frontend/static", template_folder='frontend')
CORS(app)
api = Api(app)
class frontend(Resource):
... | [
"jasongilman18@gmail.com"
] | jasongilman18@gmail.com |
c9a5516f0128c5bc1c1d48f74acd33bed59f97fd | 537d28fb2142331e27c84ebf2c16bad77aceb24e | /cslee201907/bit0729/test0809_pca.py | c2fd4b09ccd0c675214da1d7269552e87374abb8 | [] | no_license | gema0000/bit2019 | c27c3cec8d8d3a0907ade41523ce1c5ee86337b6 | 2f44ad3956b387186935374d9a488ad40a13bcaf | refs/heads/master | 2020-07-03T05:19:41.051447 | 2019-10-26T23:56:25 | 2019-10-26T23:56:25 | 201,796,021 | 4 | 2 | null | null | null | null | UTF-8 | Python | false | false | 1,930 | py | from sklearn.datasets import load_breast_cancer
from sklearn.model_selection import train_test_split
cancer = load_breast_cancer()
X_train, X_test, y_train, y_test = train_test_split(cancer.data, cancer.target,
random_state=1)
print(X_train.shape)
print(X_test.shape)... | [
"gema0000@naver.com"
] | gema0000@naver.com |
dce3ff7ebba6c050682e6e0bac39c91f54dca34f | 0054d1400952895b3480bc5c912ee2f19bea122c | /plugin.video.yatp/server.py | f6642f62ea459f46896786f28e354eff2a930047 | [] | no_license | Inter95/tutvguia | a143bd2525d218882f6e7431c998eadbd47f229f | 49ca0e894a8a28bf79e995221025c96171ea25a0 | refs/heads/master | 2022-12-25T17:58:54.353580 | 2017-08-25T08:44:59 | 2017-08-25T08:44:59 | 44,966,893 | 2 | 1 | null | 2022-12-14T13:06:23 | 2015-10-26T12:29:18 | Python | UTF-8 | Python | false | false | 1,430 | py | # coding: utf-8
# Module: server
# Created on: 01.07.2015
# Author: Roman Miroshnychenko aka Roman V.M. (romanvm@yandex.ua)
# License: GPL v.3 https://www.gnu.org/copyleft/gpl.html
"""
Torrent streamer WSGI server
"""
import sys
import xbmc
from libs.server.addon import Addon
addon = Addon()
if not addon.start_serve... | [
"inter95@netzero.com"
] | inter95@netzero.com |
7ced65cfc3ef47676dd8e95513ae0b9a0d7fa43f | ffd2ce990cf15efa5705a30ae3a1ebe5b44eaef9 | /hoth/base.py | 43afa46f6c81a2a7b14b721dba96ff45abddf012 | [] | no_license | andre-deregle/hoth_framework | 8ad6277f73582bd9fd378a056f3b75f4951a55c5 | 998ef9a78ee019787e040ae533f2659345c3ccd6 | refs/heads/master | 2021-01-10T14:30:34.744408 | 2015-12-15T15:09:49 | 2015-12-16T10:09:53 | 47,707,565 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 2,078 | py | import os
import time
from bs4 import BeautifulSoup
from selenium import webdriver
class Base:
DRIVER = None
PAGE_HTML = None
def start_driver(self, driver_type="Firefox", path=None, remote=False):
"""!
Method that starts Selenium webdriver.
Args:
driver... | [
"abon.lits@gmail.com"
] | abon.lits@gmail.com |
c865ab16fb282ca2fcd60d1db0446fbe307de26c | 9b5d06139061f6de33d81d9611495600d2c86df0 | /newsfeed_template.py | ca32da9441830095fad3bb168b2db67afe1d03dc | [] | no_license | rakesh82/Flask-Example | 28fa0795ce344f2d55f40b87b1cefe0cd6ef5231 | ebe1aac105ba32aa5e0e535722ed535efc8bbe44 | refs/heads/master | 2022-12-18T04:03:59.156295 | 2020-09-25T11:24:58 | 2020-09-25T11:24:58 | 298,550,990 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 826 | py | ###
# newsfeed_template.py - multiple news feeds and uses of Jinja templates
###
import feedparser
from flask import Flask
from flask import render_template
app = Flask(__name__)
# Feeds channel
NEWS_FEED = {
'bbc': "http://feeds.bbci.co.uk/news/rss.xml",
'cnn': "http://rss.cnn.com/rss/edition... | [
"noreply@github.com"
] | rakesh82.noreply@github.com |
e70e33f6e6b8c38ee246fdd13f744f958336a9b2 | c50e7b5a9597980f7b659fa4294f065b152ef9cf | /jogo_da_velha_utilizando_arrays_funções_e_estrutura_para_faça.py | f319d511dae456ffad5e8ed63f5958fbd7eeb6ae | [] | no_license | crishonsou/modern_python3_bootcamp | aab60ede8f8bec4cb38dc81e896823795460ea5b | 086e0e97dacaf05862fa8d73184b217cf5688114 | refs/heads/main | 2022-12-24T00:00:03.621358 | 2020-10-06T15:35:26 | 2020-10-06T15:35:26 | 301,769,578 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,954 | py | import sys
def menu():
continuar=1
while continuar:
continuar = int(input("0. Sair \n"+
"1. Jogar novamente\n"))
if continuar:
jogador_1 = input('Digite o nome do jogador 1: ')
jogador_2 = input('Digite o nome do jogador... | [
"noreply@github.com"
] | crishonsou.noreply@github.com |
43bacb73308ce17131c7af16d237c8beaddd291b | 0c8e23c3bc701cd043edcc99dc61c0a910985406 | /main.py | b085f31d1c6def8eecf4ac856e4b7ad6edbdd4ce | [
"MIT"
] | permissive | talisonfc/DevOpsAssistent | 55137d8596c286aeb057338bed36c5e12d455ea8 | 0a9b41c65d3dfbaec5210bdc7794be83042f1b52 | refs/heads/master | 2021-04-11T21:36:31.683842 | 2020-03-21T20:45:17 | 2020-03-21T20:45:17 | 249,056,981 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,670 | py | # -*- coding: utf-8 -*-
import speech_recognition as sr
from controllers import DBController
dbController = DBController.DBController()
mapOfHandlers = {
"adicionar banco de dados": dbController.addDB,
"meus bancos de dados": dbController.show,
"remover banco de dados": dbController.removeDB,
"conect... | [
"tfccomputation@gmail.com"
] | tfccomputation@gmail.com |
94cc4e4ccf09fb0aac8357be15b814d889a2fdba | 778607e1cc3636326057b43f90713e683f05621c | /pyUtil/pimon_temp.py | df90a5702f77c3ad3d07850d1699b3ddce964d48 | [] | no_license | fgrehl/esxi-raspi | f9ddb2419aed901e324efd4d833bd11b4b6ee674 | 639d7c2838f4a7c5d615c39164d4586cfdfdadbf | refs/heads/main | 2023-01-09T05:29:22.682287 | 2020-11-15T12:21:10 | 2020-11-15T12:21:10 | 311,383,029 | 4 | 1 | null | null | null | null | UTF-8 | Python | false | false | 451 | py | #!/usr/bin/python
import time
import sys
from pimonLib import *
def main(argv):
if (argv):
SECONDS = int(argv[0])
else:
SECONDS = 10
print('Polling CPU temperature every {} seconds...'.format(str(SECONDS)))
pimon = PiMon()
while True:
timestamp = int(time.time())
pr... | [
"git@virten.net"
] | git@virten.net |
54634da9ef0f9cbf589a83574d5307aaa0f2557e | 83a1c7251ff2d4d0090760227245856e28edfeac | /10/ascii_knot.py | 54b56fdfed56f7e07e21971d65e74f5b4d063a4a | [] | no_license | mkolas/advent2017 | db6e6c758247a3d1f153608227ed3ffcf8cd9c23 | 40706b7e4af6f1e9f08f1a3ce3d28749a3cc661a | refs/heads/master | 2021-09-01T05:41:10.714619 | 2017-12-25T05:44:48 | 2017-12-25T05:44:48 | 112,755,382 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,160 | py | list_ = [x for x in range(256)]
size = len(list_)
lengths = [ord(x) for x in "183,0,31,146,254,240,223,150,2,206,161,1,255,232,199,88"]
lengths.extend([17, 31, 73, 47, 23])
position = 0
skip = 0
def wrap_slice(list_, position, size):
if position + size > len(list_):
return list_[position:] + list_[:(positi... | [
"barrelrolled@gmail.com"
] | barrelrolled@gmail.com |
a4b85e3f638f3efabd6247858c62d1c3b21e8722 | 42de376efe849a6c205b56f3f1093aec4742bfc4 | /battleship.py | 4592ec5aa24b3e3c41df9ac90abcc6694e616962 | [] | no_license | Ihsara/battleship | 397551d70eedd92be8698eda0b98b702b71a457b | 346cbcb20d272bccf311ce1280e558165a485a6b | refs/heads/master | 2021-06-21T01:06:13.687996 | 2019-09-19T02:48:14 | 2019-09-19T02:48:14 | 209,442,670 | 0 | 0 | null | 2021-04-20T18:41:25 | 2019-09-19T02:12:40 | Python | UTF-8 | Python | false | false | 264 | py |
DEFAULT_SIZE = (10, 10)
PVE = 'pve'
PVP = 'pvp'
MODES = [PVE, PVP]
def play_battleship(board_size=DEFAULT_SIZE, playmode=PVE):
return 1
if __name__ == '__main__':
play_battleship(board_size=DEFAULT_SIZE, playmode=PVE)
| [
"longchau21@gmail.com"
] | longchau21@gmail.com |
de3cc0898496f0289168f3bbfa565960cb719813 | dbe0db719e6d8a8c7e9974c590a3199e5792fde8 | /blog/views.py | bf70355cfd8d1ffceadc2eac61be622ae9e9a1db | [] | no_license | PurunStar/Hosting | bbde7f069cf780554ad999e4c811699e04888d06 | 71f5aea468351b394d1e653d145289b545075a5e | refs/heads/master | 2023-04-28T23:58:49.774782 | 2019-06-28T02:23:05 | 2019-06-28T02:23:05 | 194,189,733 | 0 | 0 | null | 2023-04-21T20:33:00 | 2019-06-28T02:03:03 | JavaScript | UTF-8 | Python | false | false | 3,648 | py | from django.shortcuts import render, get_object_or_404, redirect, HttpResponse
from .models import Blog , Comment
from django.utils import timezone
from django.core.paginator import Paginator
from django.contrib.auth.decorators import login_required
from .forms import BlogForm
# Create your views here.
def home(reques... | [
"maxlevel1324@naver.com"
] | maxlevel1324@naver.com |
71475e313cdac46415bf31dbe3f90cf158e2b1bb | 6b5bbdbc3e6f54b312738103b8c348a05b8f81db | /Code/calibration.py | e606912ded5d664deb0ed1f26928680ea689b3a4 | [
"MIT"
] | permissive | irvingliao/CarND-Advanced-Lane-Lines | 39ec388828391b19c979bb4cc78eb641b6638dcf | f9d136e0440285efb564d41c05c1346a2cd7c5c5 | refs/heads/master | 2020-04-12T18:44:07.744844 | 2018-12-27T08:34:11 | 2018-12-27T08:34:11 | 162,688,995 | 0 | 0 | MIT | 2018-12-21T08:39:36 | 2018-12-21T08:39:36 | null | UTF-8 | Python | false | false | 2,673 | py | #%% [markdown]
# ## First, I'll compute the camera calibration using chessboard images
#%%
import numpy as np
import cv2
import glob
import matplotlib.pyplot as plt
import matplotlib.image as mpimg
from IPython import get_ipython
#%%
get_ipython().run_line_magic('matplotlib', 'qt')
# prepare object points, like (0,0... | [
"irvingliao@gmail.com"
] | irvingliao@gmail.com |
1674fe95e66f1a1515e0f9f2041ce6e82087a29a | 2537756cb251008eacd247db82a26c43967e1381 | /sdk/python/test_data/pipelines/pipeline_with_importer_and_gcpc_types.py | 98431d362cbd686875944fc8fdff87db3846f011 | [
"Apache-2.0"
] | permissive | TheMichaelHu/pipelines | 074edf3b08e2877a996061bacdf4b9563270cc5b | 4c6abe5afcc1b0511f0d0ab91b7ec4522da5a1df | refs/heads/master | 2022-12-10T18:34:08.540736 | 2022-11-02T00:31:45 | 2022-11-02T00:31:45 | 241,268,119 | 0 | 0 | Apache-2.0 | 2020-02-18T04:00:31 | 2020-02-18T04:00:30 | null | UTF-8 | Python | false | false | 1,626 | py | # Copyright 2022 The Kubeflow Authors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in... | [
"noreply@github.com"
] | TheMichaelHu.noreply@github.com |
dff6ff1934280c768a14f7a374a59512e2cf35bb | c7f4cc258c3f18a80bd94378bc826b59d0b6bb1d | /python/modules/argparse/test.py | c13d50c6a84db48a0ab3a7719ff84104042c66df | [] | no_license | CoptimT/basic | 92799e48e5ac264b4af61bc65041320d9c928489 | e98a9bd3efcaf9cccb6514996c0318a833ae7b06 | refs/heads/master | 2020-03-14T22:56:05.207429 | 2018-08-01T09:53:02 | 2018-08-01T09:53:02 | 131,832,240 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,499 | py | #!/bin/env python
# -*- coding: UTF-8 -*-
import argparse
def test1():
parser = argparse.ArgumentParser()
parser.add_argument('echo')
args = parser.parse_args()
print(args)
print(args.echo)
# > python test.py ofo
# Namespace(echo='ofo')
# ofo
def test2():
parser = ar... | [
"zhangxw17@lenovo.com"
] | zhangxw17@lenovo.com |
6c9607cf91f8f75cb437f6ebc6042a0b2bc5cbd7 | 3c124cd9758886b331e6dd1ee146ac3ab0b369a4 | /period3/32414845dailyahead/XGB.py | c665eafed23d815ba0acdece459166289b61d755 | [] | no_license | WzcTHU/LMP_Forecast | 3ff109fb4da402cfd7d093d9ee13586e4082497a | c5794cfef0b3c778e35502aa5ddbaac1446e65b2 | refs/heads/master | 2020-05-17T01:30:12.789552 | 2019-04-25T13:00:39 | 2019-04-25T13:00:39 | 183,426,832 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,299 | py | from DataStandardScaler import *
from DataCut import *
from SummaryResults import *
from xgboost import XGBRegressor
from sklearn.externals import joblib
import scipy.io as sio
print('Cutting dataset...')
data = DataCut('data/x.csv', 'data/y.csv')
data.cut()
print('Data standardizating...')
data_scaler = DataStandar... | [
"zhengche16@mails.tsinghua.edu.cn"
] | zhengche16@mails.tsinghua.edu.cn |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.