blob_id stringlengths 40 40 | directory_id stringlengths 40 40 | path stringlengths 2 283 | content_id stringlengths 40 40 | detected_licenses listlengths 0 91 | license_type stringclasses 2
values | repo_name stringlengths 3 135 | snapshot_id stringlengths 40 40 | revision_id stringlengths 40 40 | branch_name stringlengths 4 68 | visit_date timestamp[ns]date 2015-07-25 20:53:29 2023-09-06 10:46:05 | revision_date timestamp[ns]date 1970-01-01 00:00:00 2037-05-03 13:00:00 | committer_date timestamp[ns]date 1970-01-01 00:00:00 2036-02-09 17:40:36 | github_id int64 1.61k 691M ⌀ | star_events_count int64 0 209k | fork_events_count int64 0 110k | gha_license_id stringclasses 24
values | gha_event_created_at timestamp[ns]date 2012-06-03 10:21:33 2023-09-14 21:59:50 ⌀ | gha_created_at timestamp[ns]date 2008-03-27 23:40:48 2023-09-13 22:40:33 ⌀ | gha_language stringclasses 250
values | src_encoding stringclasses 27
values | language stringclasses 1
value | is_vendor bool 2
classes | is_generated bool 2
classes | length_bytes int64 6 10M | extension stringclasses 289
values | filename stringlengths 1 218 | content stringlengths 6 10M |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
3317d3770cc209f0539261e736b956ffb6107e87 | 9db595cc5a27cb10bbcd6ea3f4ceb8db24abade3 | /OSE_Modules/MainWindow.py | 6210c0ea7ca3666ec59c79bb6d2ab690ef141404 | [] | no_license | jspada200/OSE-Thesis | 3a0cb79a50d648961e147361b0aa5b2fce752ed4 | 890a625c02e799524e748f1a8985b58496f53b23 | refs/heads/master | 2021-01-23T05:30:10.811244 | 2017-09-05T11:14:25 | 2017-09-05T11:14:25 | 102,471,342 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 10,510 | py | MainWindow.py | from PyQt4 import QtGui
from PyQt4 import uic
import backend_canvas as canvas
import NodeGraph
import AttrPanel
import datatypes
import globalvars
import json
APP_ROOT = globalvars.APP_ROOT
# --------- APP INFO --------
VERSION = "0.8"
DATE = "July 2017"
NOTES = ""
class MainWindow(QtGui.QMainWindow):
"""Main W... |
bdfd5f517e7cca226dc8a2ec605d73ec00fb7586 | d2353c8f0dd4ac395c9aa285414924db6dcb9f60 | /coding/views.py | ecfbac3d85be22dbabbfa44c8e480a6dcaaa5b9b | [] | no_license | hgu2019capstone/sideProject2 | c764f379d11158fb248c6285fac93ad55a78f8e1 | 2a100a469d205ef86e2c31ec7760cbacdb4f7c5e | refs/heads/master | 2020-04-28T14:58:44.028867 | 2019-03-13T05:59:49 | 2019-03-13T05:59:49 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 561 | py | views.py | from django.shortcuts import render
from django.http import HttpResponse, HttpResponseRedirect
from codemirror import CodeMirrorTextarea
from django import forms
from .forms import CodingForm
from .models import Coding
def get_code(request):
if request.method == 'POST':
form = CodingForm(request.POST)
... |
6005bfdcef5d0cb7c07cf1e7d62b944527d789e6 | 79085fc1890dff3e3f74ab032004954c0e226824 | /fabfile.py | 2cbda728336c500f83debab44064eabbcc619e35 | [
"MIT"
] | permissive | sulbig/puresnmp | fbc0aa777032e6eae73e6b2c951a4268e250b4bb | 385c733c23b19a71f93f7a4fa08321a933bb7ec3 | refs/heads/develop | 2021-01-16T08:54:26.436697 | 2016-09-12T19:16:08 | 2016-09-12T19:16:08 | 67,974,059 | 0 | 0 | null | 2016-09-12T03:53:41 | 2016-09-12T03:53:40 | null | UTF-8 | Python | true | false | 105 | py | fabfile.py | import fabric.api as fab
@fab.task
def doc():
with fab.lcd('docs'):
fab.local('make html')
|
8cfd1cda193ab2e128de3f8eb1e1387fff11916c | 42369fe8d20577e32df3f1d6cbce99de33cb1f3e | /HPC_Scripts/bonds_analysis.py | 7258f6701f957fcab98e48aef4aff9a004122c89 | [] | no_license | Kuan-Louis/LAMMPS_Simulation | 948c5e0bfecc4c70b6a5dd320cbc7b3e21ae0df0 | ec82ecb1cc8c5058fa09c4dfbccf7f999ec65268 | refs/heads/master | 2022-01-14T19:49:50.361832 | 2019-05-14T15:58:32 | 2019-05-14T15:58:32 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 9,068 | py | bonds_analysis.py | # Modified by Yiming Xu from source below.
#
# lammps.py (2011/03/29)
# An ASE calculator for the LAMMPS classical MD code available from
# http://lammps.sandia.gov/
# The environment variable LAMMPS_COMMAND must be defined to point to the
# LAMMPS binary.
#
# Copyright (C) 2009 - 2011 Joerg Meyer, joerg.meyer@ch... |
ed4e8756666e76c3f9796b9fafcead1264345e08 | 4161a0e030d20460730886b1f1dc9f68d3c75862 | /qino/uiImpl/Ui_SerialDialog.py | 7f2b2a52181c7fbbd3bb931c5864b06574a25410 | [] | no_license | n3wtron/qino | 2a48d2f1519fc629d16be86f5fc8189de9efc3e9 | fc4348d8242f660ee1c0e0c4bf1fa3844460ac2d | refs/heads/master | 2020-06-01T11:48:10.386768 | 2013-02-28T15:19:04 | 2013-02-28T15:19:04 | 7,386,861 | 1 | 1 | null | null | null | null | UTF-8 | Python | false | false | 2,679 | py | Ui_SerialDialog.py | # -*- coding: utf-8 -*-
# Form implementation generated from reading ui file 'ui/serialdialog.ui'
#
# Created: Mon Nov 19 15:19:20 2012
# by: PyQt4 UI code generator 4.9.3
#
# WARNING! All changes made in this file will be lost!
from PyQt4 import QtCore, QtGui
try:
_fromUtf8 = QtCore.QString.fromUtf8
except... |
67e329a835b68dcaacda1e24f9b74c5b22e3df2b | 77cf71c5a6268c1eb40a45eebd295ed2b2846e2c | /SFXGLWidget.py | ef65b28c97b9f3d351de1584dc907534fd79612b | [] | no_license | qm210/aMay2yn | 15d2e95d07fd553ecee409a41502575fa2947b5f | 32c390f601d2a78bcc2d63aea2822e1786d84553 | refs/heads/master | 2020-08-16T20:36:39.663245 | 2020-04-11T00:54:52 | 2020-04-11T00:54:52 | 215,549,769 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,583 | py | SFXGLWidget.py | #!/usr/bin/env python
#
# #
# # # THIS IS WHAT QM HAD TO STEAL FROM NR4 (and modify it accordingly)
# #
#
#
# toy210 - the team210 live shader editor
#
# Copyright (C) 2017/2018 Alexander Kraus <nr4@z10.info>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Genera... |
da81ab33766621d62a32c69c734444877e710e45 | 3587e4c248005c6df500caea7ee18675d8676022 | /Clients/Python/DBSAPIOLD/dbsCgiTestCreateBlock.py | 8cc8bf31f26049128f93f5acac94ec2b12b4435e | [] | no_license | bbockelm/DBS | 1a480e146010e3d6b234ba5ee471f7c87a4877e6 | 4e47d578610485e0503fc1270c7d828064643120 | refs/heads/master | 2021-01-16T18:18:29.989833 | 2012-08-21T15:01:05 | 2012-08-21T15:01:05 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,665 | py | dbsCgiTestCreateBlock.py | #!/usr/bin/env python
#
# Unit tests for the DBS CGI implementation.
import sys
from dbsCgiApi import DbsCgiApi, DbsCgiObjectExists
from dbsException import DbsException
from dbsFile import DbsFile
from dbsFileBlock import DbsFileBlock
from dbsEventCollection import DbsEventCollection
from dbsPrimaryDataset import Dbs... |
7e3532c232a918a26050e7083b34323002a9c52a | d790794e89151dd9ae5222bdb310ffc15e603464 | /Personal Project/common/constants.py | ecefeb902416083820fff69188a8a5088d91b39a | [] | no_license | sujithnj88/DataScience | df1f2b3e049227def6a9a8543800c7f98065c797 | b08b7f176f49c1c78c86af4e6f79eaecb7b7b9b9 | refs/heads/main | 2023-06-18T07:09:25.784709 | 2021-07-21T12:08:32 | 2021-07-21T12:08:32 | 384,730,960 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 27 | py | constants.py | matchType = ["ODI", "T20I"] |
8cf0d0426ae1b5c6eff5348de21785efb14bc3a7 | 7cecf963edd20fcc6c2a4a055f7a4c7abf4c2907 | /temp/flask-echarts/server.py | d82719bb5551a05df951695ae651cd671c810ef8 | [] | no_license | beom205/shelter_dog | 0a454a6a8a03c8f6da18d589cf34f8620419b155 | 74bd9f616ad1534c9b2ca12bae024f4f5994307a | refs/heads/master | 2022-08-02T13:18:56.118326 | 2019-12-18T06:15:40 | 2019-12-18T06:15:40 | 268,316,776 | 0 | 0 | null | 2020-05-31T16:16:30 | 2020-05-31T16:16:29 | null | UTF-8 | Python | false | false | 3,547 | py | server.py | #이미지 클릭 시 그래프 출력
from pyecharts import Bar3D
from pyecharts_javascripthon.api import TRANSLATOR
from flask import Flask, escape, request, render_template
import requests
import pandas as pd
# import matplotlib as mpl
REMOTE_HOST = "https://pyecharts.github.io/assets/js"
app = Flask(__name__)
#구별 년도별 인구수가 들어간 리스트
dat... |
d5cf4742042ecd5db534265b30f07bbc94aab9dc | 9e240df82553553088b8676065493ce19ecb73d3 | /Assignment3/Matrix/Matrix.py | ad553ea0d18a38d2d85b95cf04682f1cab51d90b | [] | no_license | KyleBlud/ComputationalPhysics | be517d1c077c00ebdea3e27d7ad412a60c2b30ec | d65a2998fb0c6bd35d21a425d8a5859d5b24c17c | refs/heads/master | 2021-07-11T11:21:45.334828 | 2017-10-12T01:10:40 | 2017-10-12T01:10:40 | 102,968,598 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 241 | py | Matrix.py | '''
Author: Kyle Bludworth
Course: Physics 420
Creation date: September 24, 2017
'''
import numpy as np
from numpy.linalg import solve
A = np.array([[1, 1, 1], [2, 4, 6], [2, 12, 30]])
b = np.array([[-1], [0], [0]])
x = solve(A, b)
print(x) |
7e9aaafa7006403aa29a92e06a286f61a4d14146 | 4bd3298905c3aab7e327af30d8bb93801fa09204 | /python_code/old_joystick_control.py | db4eefb81dcdc9e24e9e50a6cd266c808658ff3d | [] | no_license | hariharsubramanyam/UAV_Team_Sem1 | e62972260b5d7af1bc0415479857198c736c1550 | c367489b6379a169c0551aedfb3063409469e3ca | refs/heads/master | 2016-09-06T19:34:49.321714 | 2013-08-25T00:02:01 | 2013-08-25T00:02:01 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,504 | py | old_joystick_control.py | #!/usr/bin/python
import pygame
import serial
import time
# Just a bit of boilerplate to start from next time
pygame.init()
pygame.joystick.init()
while not pygame.joystick.get_init():
print "Joystick not yet initialized. Trying again..."
pygame.joystick.init()
joy = pygame.joystick.Joystick(0)
joy.init()
... |
72f3e34367f3010dc8d5eab939af01ae24579ae2 | 70ad737b27abdd4d5720b6c0209d36f32031fd36 | /IOT HOME/serversocket.py | 9d857e1ba64425fa336f62663c74dafb09e00901 | [
"MIT"
] | permissive | Dongwon-tuna/Sea-water | f0cf3253d5224ce79466d07a30fa1228bb48e333 | f507282feaeaec00fa005233f02642d4137099f7 | refs/heads/master | 2021-01-06T09:54:29.709765 | 2020-03-05T14:00:16 | 2020-03-05T14:00:16 | 241,287,944 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 462 | py | serversocket.py | from socket import *
serverSock = socket(AF_INET, SOCK_STREAM)
serverSock.bind(('', 8080))
serverSock.listen(1)
connectionSock, addr = serverSock.accept()
print(str(addr),'에서 접속이 확인되었습니다.')
data = connectionSock.recv(1024)
print('받은 데이터 : ', data.decode('utf-8'))
if data.decode('utf-8') == 'HIGH':
print("Turn ... |
ed59873f2c81fdb7f0d450ee421292f319aebcf4 | 69458bc0cfbade4ceedf8b63795e0beaf3aa9229 | /tests/cli/test_rasa_interactive.py | 8ee4a66a57ecef7014cae46fb614d804457ae7c2 | [
"Apache-2.0",
"LicenseRef-scancode-generic-cla",
"MIT"
] | permissive | pasqualebasile/rasa | 4c4865c73685fc0e72cf7096809f27e7f83200b4 | f9613c9eac49d105968d6b346aa471a767e5fdc2 | refs/heads/master | 2020-08-09T13:47:58.309812 | 2019-11-08T20:24:30 | 2019-11-08T20:24:30 | 209,354,850 | 1 | 0 | Apache-2.0 | 2019-09-18T16:27:09 | 2019-09-18T16:27:09 | null | UTF-8 | Python | false | false | 2,262 | py | test_rasa_interactive.py | import argparse
from typing import Callable, Text
from unittest.mock import Mock
from _pytest.monkeypatch import MonkeyPatch
from _pytest.pytester import RunResult
import rasa
from rasa.cli import interactive, train
def test_interactive_help(run: Callable[..., RunResult]):
output = run("interactive", "--help")
... |
1a1213eb08850c66d9579c93be386ea0b4821b8c | 2117f90c6b1cbc4dafbe25534565217756ef72d2 | /Final/Bootcamp/best_classifier_generator.py | 70f8ce82924d65dd183675e7cae7e3fc2432ba2b | [] | no_license | robmasocco/MOBD-prj | 42b548bf02e8ab8378b0cc684781f2cb9d6b332d | 0c2255092ea52de5b966646cd2fc0018db4e26fd | refs/heads/master | 2022-11-07T03:32:19.336870 | 2020-06-23T09:37:08 | 2020-06-23T09:37:08 | 272,371,571 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 7,225 | py | best_classifier_generator.py | """
Authors: Alessandro Tenaglia, Roberto Masocco
Project: MOBD-prj
File: SVM_rbf_GridSearch.py
Date created: 19/06/2020
Description: Script to generate and save best classifier.
"""
import pickle
from sklearn.impute import KNNImputer
from sklearn.preprocessing import StandardScaler
from sklearn.s... |
9d1bfbef743894c4fa9a94f7c031588525ed22a6 | 185598d82c11d42e453486fd4004432d106c0fd8 | /Apc/apc_package.py | 05a13df44bc8418ff9c31279194b360b6b2656da | [] | no_license | yxgr-copilot/DOF_TaiWan | 253e5e4ca0bcd1832d81cd06226a62f7c96a945c | bb7fb517295a14a36f2576b62341fc1f97628d08 | refs/heads/master | 2023-05-27T01:27:42.546192 | 2020-01-15T12:41:41 | 2020-01-15T12:41:41 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,579 | py | apc_package.py | from datetime import datetime
from pickle import load
from re import findall, S
from tool import *
with open('apc_package_source.pkl', 'rb') as pkl:
pkl_list = load(pkl)
summon_stk, apc_package, job_dict = pkl_list
# 获取当前日期,做ID计数器
start_id = int(datetime.now().strftime('%Y%m%d') + '00')
# 获取主要工作目录
main_dir = Get... |
79bc98f38eb7550ab848b3baa387801a8fefe130 | 8790cea399d734a31326522e7619266cdf71a210 | /getter.py | c2c639d2d74e2d65648fb18ef3c8bb539dc9d5ee | [] | no_license | yaniv-aknin/forofour | 2a1329072d485f663c16ccec7bc2588f1864acd5 | b98cbb11efd9957b476b1c0e5ec15025051958b3 | refs/heads/master | 2020-05-31T03:25:14.530405 | 2009-07-31T10:18:33 | 2009-07-31T10:18:33 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,293 | py | getter.py | import urllib2
import re
from parser import AnchorExtractor
import errors
contentTypeFilter = re.compile('^text/html(;.*)$')
def isKnownContentType(handle):
return contentTypeFilter.match(handle.headers.get('content-type', ''))
def getURL(url, timeout, linkFound, target, fetchContent):
result = None
try... |
37a72d6160014af204fb5ae6c5c9eca84b4d6906 | f19cc4e99b265ae41ad6e5c16f023c1e68d11126 | /Stess.py | 7a80a65c9ad9ab88157b1b83af91f42ab902ccf3 | [] | no_license | aezakmi007/CPU-STRESS-ALERT-SYSTEM-IOT | b9e3cdbed265f5a6b8c1839711ddf9fcd12453dd | bfb7f487e50c6aa6abd1a2a11c8f54b179f494ef | refs/heads/main | 2023-03-31T23:29:41.990723 | 2021-04-11T06:04:34 | 2021-04-11T06:04:34 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 680 | py | Stess.py | import psutil
from boltiot import Bolt
api_key = "a1d04b0c-01e4-4542-bafa-116090c8f0ae"
device_id = "BOLT293335"
cpu_Threshold = 0.4
clientId = Bolt(api_key, device_id)
interval = 5
def control_green_color(pin, value):
response = clientId.digitalWrite(pin, value)
def control_red_color(pin, value):
response = c... |
24c30947639e0d077da820d92747cb8bfd0b99d5 | a7699acc9413966e426d914470e6e37cc4c9c13d | /config.py | c720cc57e1cb3cb08d69d4ea467e377728499d56 | [] | no_license | yimiqisan/huwai | 300090c58930ee2d3a42a6aea5fdd24c13302078 | ae4f8ba8e39534aa94894b291b80f8685ba0b7d2 | refs/heads/master | 2021-01-10T21:33:30.464330 | 2012-07-11T14:21:38 | 2012-07-11T14:21:38 | 2,111,904 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,793 | py | config.py | #!/usr/bin/env python
# encoding: utf-8
"""
config.py
Created by 刘 智勇 on 2011-09-24.
Copyright (c) 2011 __MyCompanyName__. All rights reserved.
"""
import os
import redis
from mongokit import Connection
from logging import basicConfig, DEBUG
import uimethods, uimodules
SITE_ID = u'917d450c728b4f62b6ac9bac1beb01ba'
D... |
5c6bc04994c8faeafd48a63629dd1caaae6306bc | 916af2c628e0198912e7fae38b2faadea45b032b | /tgbot/command/add_admin.py | 476f2b0b056af8d7abfe924b6cf21d00bac623e6 | [] | no_license | YunOSC/TG-tlkio-bot | 8702d6bcc20ce35d7060040f84411612e9f7a2d3 | 21e9c0e3d08e0fe4c39a31982cd59dee0a79f676 | refs/heads/master | 2022-12-09T05:46:29.429206 | 2019-01-21T13:28:34 | 2019-01-21T13:28:34 | 148,919,852 | 0 | 0 | null | 2022-12-08T02:54:20 | 2018-09-15T16:34:54 | Python | UTF-8 | Python | false | false | 597 | py | add_admin.py |
from tgbot.command import Command
from utils import *
class AddAdmin(Command):
def __init__(self, bot, cmd):
super(AddAdmin, self).__init__(bot, cmd)
def invoke(self, msg):
pass
def process(self, msg):
tgId = msg.chat.id
from_user = User.fromSave(msg.from_user)
i... |
b763e0e8ee9df397eaabe0236a02af95f1c33bec | e69c5fb55a6c69a14f5ace76f25000ab9400b82b | /Dennis/Server/server_socket.py | bcaf639da63acbb5086c26075bd5d58e4e7be56c | [] | no_license | dennis-arroyo/Data-Communication | 86b94a29dc0aedfcd1297287332bcb6e36e1d4d1 | 1fe976ff636b87d71c0abb94bf483b600cbe6e7d | refs/heads/master | 2020-04-04T21:29:29.113281 | 2018-12-11T12:00:19 | 2018-12-11T12:00:19 | 156,288,098 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,143 | py | server_socket.py | import socket
import random
from _thread import *
# HOST = '127.0.0.1'
HOST = socket.gethostbyname("")
# HOST = socket.gethostname()
# Pixel's raspberry pi ip address
# HOST = "192.168.43.83"
# Home router raspberry pi ip address
# HOST = "192.168.8.166"
PORT = 7575
clients = {}
# player = 1
text_field = "Players... |
946d9f2cd45e75cc20ef57d4056d010f467efd48 | d2ae3842ecd0903486371a9e87aa883200ec1a7b | /data/resources/program_types.py | 284d20855dbafc82b8dd9fec4195a6cfde0001ea | [] | no_license | NancyHebert/tssbe | cc99c85c324d872390f20ed1ca4ca9cc317da78f | 20f4ce72e4b9f2a13ebde4d6e178abe58c15a2df | refs/heads/master | 2020-09-20T13:31:32.991916 | 2019-11-28T00:22:11 | 2019-11-28T00:22:11 | 224,496,898 | 0 | 0 | null | 2019-11-28T00:22:47 | 2019-11-27T18:51:51 | Python | UTF-8 | Python | false | false | 2,422 | py | program_types.py | import falcon
import json
from data.models.program_types import program_types
from data.models.program_type import program_type
from data.resources.utils.alchemyencode import encoder
from data.resources.utils.options_mixin import OptionMixin
from data.resources.schemas.program_types import schema_post
# from data.reso... |
091ebce71df9672d7188567e3569a8d657e50bf9 | 77c3f5696d937e04ae6c34cb14a823424ecabad3 | /fetch_data.py | ebd5ce569d6cac8b2977d67c56105a04769a8d42 | [] | no_license | justinlboyer/forecast_data | 9abbe37602c695bc2bdeba9f482289b2a0ba3c97 | 253be0497732e3d2de219b8c3135a784b2be3dfb | refs/heads/master | 2020-04-10T15:47:44.865469 | 2018-12-10T05:51:35 | 2018-12-10T05:51:35 | 161,123,177 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 369 | py | fetch_data.py | import requests
import json
import pandas as pd
#%%
ws_url = 'https://api.weather.gov/gridpoints/OKX/32,34/forecast/hourly'
def get_data(url):
headers = {'accept': 'application/geo+json'}
response = requests.get(url, headers=headers)
jData = json.loads(response.text)
data = pd.read_json(json.dumps(j... |
d6e8703a47ee29523950dc7f45c60e3a47aa3b4d | cbfe77e7a07403177e6ac72877eb9c8b5f34df60 | /Simulations/Test.py | 2756a87403668d7d8cbcd575aefad24bc180bbaa | [
"MIT"
] | permissive | BoettigerLab/polychrom | 4042b2c898072eb887dcf86d335063c7d9c800c5 | 5b495f210e911fb458c6014e1a975dfe007b3a27 | refs/heads/master | 2023-05-12T15:14:16.586315 | 2023-05-02T01:08:43 | 2023-05-02T01:08:43 | 373,875,569 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 452 | py | Test.py | import sys
import os
import numpy as np
import ast
import pandas as pd
from LEBondUpdater import bondUpdater
import polychrom
from polychrom.starting_conformations import grow_cubic
from polychrom.hdf5_format import HDF5Reporter, list_URIs, load_URI, load_hdf5_file
from polychrom.simulation import Simulation
from pol... |
9d362d23a111f3fa0b9221f2a8b63e66a5df834c | 3bbcc456d3a340a376d63b39d9131109c602e5f8 | /0123_Subset8.py | 760227948003d652e9d8ae541fe554d46e2429b4 | [] | no_license | Daineeeng/Subway | a9f05b828969610e2b667217f3e11ee7db344f4e | 58805ff4897ab67765c003f18d70d1c562a3242c | refs/heads/master | 2020-03-08T02:03:42.153098 | 2018-04-05T14:12:49 | 2018-04-05T14:12:49 | 127,848,504 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,241 | py | 0123_Subset8.py | import pandas as pd
Report = pd.read_csv('C:/Users/DAIN/환경설비팀요청자료2/for_대합실미세먼지/7.Report_Final.csv')
Fdust = pd.read_csv('C:/Users/DAIN/환경설비팀요청자료2/for_터널미세먼지/7.Fdust_Final.csv')
df = Report
# df = Fdust
df_row = df.shape[0]
#
i = 0
spring_dust = []
spring_temp = []
summer_heat = []
summer_rain = []
a... |
4eed06961f927f75b66eb121b0f0253efb028fa9 | 57dfecb85b439cb3506d2d16a4b6c0f53f8131b8 | /code/getFriend_Follower.py | b418d6bf541d87ff6067da56ca84e789a0ceaab2 | [
"MIT"
] | permissive | Alvi-Rahman/Learning-from-Tweets__Opportunities-and-Challenges-to-Inform-Policy-Making-During-Dengue-Epidemic | a9a2ac99e1adb7b7196828a589ce310d6304931c | 4272080f4b99db91d173ae45a14b62241c765f03 | refs/heads/master | 2023-07-23T14:56:38.754607 | 2021-09-01T01:36:35 | 2021-09-01T01:36:35 | 401,860,057 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,397 | py | getFriend_Follower.py | import tweepy
import re
from tweepy import Stream
from tweepy import OAuthHandler
from tweepy.streaming import StreamListener
CONSUMER_KEY = 'tmQA8jMSgOC7iQf5m71tnkcqI'
CONSUMER_SECRET = 'loivHciSuBh7tQYnljgVpxxUYna3dZBEYBlgQ6uxKfFXOWth7Y'
ACCESS_KEY = '1016000990489657345-FQVnuSXmuG8Q0tdmFpIh81lIdDg8B1'
ACCESS_SECR... |
5cda72b43e47d89e64da2c3230e188654bc4f9d9 | ac3371b2dd54f2798a2e9790bec6df217ee3bff6 | /bin/check-immutability.py | 6f01366ad50f7cf99f866b21dfe2229a821f891d | [
"MIT"
] | permissive | exercism/problem-specifications | 58daa426b863366132740aad7e9f6e1032e015b3 | b287cf50f11aad22f6c628035d096d422d5b9048 | refs/heads/main | 2023-09-01T20:42:03.378442 | 2023-08-24T20:44:51 | 2023-08-24T20:44:51 | 17,259,886 | 233 | 472 | MIT | 2023-09-14T14:26:39 | 2014-02-27T18:40:48 | Ruby | UTF-8 | Python | false | false | 1,580 | py | check-immutability.py | #!/usr/bin/env python
import json
import subprocess
import sys
oldf = sys.argv[1]
newf = sys.argv[2]
immutable_keys = ('property', 'input', 'expected')
# Use jq to flatten the test data, and parse it
old = json.loads(subprocess.run([f"jq -r '[.. | objects | select(.uuid != null)]' {oldf}"], stdout=subprocess.PIPE,... |
f1a87b8d369e844d0ee7cef825b86ec09d8a51f7 | 42dfe432f39818f054075fd63c2781e26eab0132 | /project1/application.py | e19d9f87d93795929d18f7f60703a0a779d46ed7 | [] | no_license | Jeanstaquet/Project1_CS50_WEB | b28c1cd8d54869520659c5f4433b76db6a36959a | 2667610d78e80ab7b6bde94fa221ae7df20a21d4 | refs/heads/master | 2020-11-30T04:44:15.120292 | 2019-12-26T22:22:04 | 2019-12-26T22:22:04 | 230,305,461 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,511 | py | application.py | import os
import json
from flask import Flask, session, render_template, request, url_for
from flask_session import Session
from sqlalchemy import create_engine
from sqlalchemy.orm import scoped_session, sessionmaker
app = Flask(__name__)
# Check for environment variable
if not os.getenv("DATABASE_URL"):
raise Ru... |
0ece76b776f1a2a8a35c05184706318e5ec8eb69 | 4829a1bece2d84cd54e3042873ec5d0ab237122c | /main.py | ff38e7f02be94b6a44a07ee344f9c4272401a4b2 | [] | no_license | LukaAndrojna/masterchef | 68ff4507cda2e3c3512c173e470aad2bb919816a | c385109e7d590a25f1c935a796dd76fc71c34a06 | refs/heads/main | 2023-04-19T17:09:54.286521 | 2021-05-18T19:05:35 | 2021-05-18T19:05:35 | 368,639,469 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 618 | py | main.py | import numpy as np
import matplotlib.pyplot as plt
from models.competition import Competition
def main():
competitors = 20
simulations = 10000
results = list()
for _ in range(simulations):
competition = Competition(competitors)
results.append(competition.run())
bins = np.ara... |
ed2c4b74092554962abb95257a795b2ad0f00adb | d9ae8abae85a36934f69659bea698f658578dbba | /workflow/9.1.train_iterative.py | 65939326f6694367dad5901105ffca5a78cea84d | [] | no_license | mahkons/WorldModel | d2dc56da36dcd7edbf45362510805526e37e0dae | c15bc0df4fc4e2c2ea92154943c510efaafeb858 | refs/heads/master | 2020-09-24T01:40:49.375248 | 2020-01-27T12:04:59 | 2020-01-27T12:04:59 | 225,631,975 | 0 | 0 | null | 2020-01-27T12:05:00 | 2019-12-03T13:53:02 | Python | UTF-8 | Python | false | false | 2,261 | py | 9.1.train_iterative.py | import subprocess
import argparse
from tqdm import tqdm
def create_parser():
parser = argparse.ArgumentParser()
parser.add_argument('--env', type=str, default='LunarLanderContinuous-v2')
parser.add_argument('--device', type=str, default='cpu')
parser.add_argument('--memtype', type=str, default='Classic... |
fbbd25af6784343968edf02593877d2a8850cbc8 | ee36ca6598eea9996ece7dc8342e41eacb425973 | /student_portal_crawler/test/test_browser.py | a560c6483b509e3b99d748cedb20e85753a3cd40 | [
"MIT"
] | permissive | StudioAquatan/student_portal_crawler | dd26dda96054d33fc47695cd379ab0d0b19609e5 | b3cfda41451fa7f0c08f4d50f2e8264bf9363a79 | refs/heads/master | 2021-09-10T07:43:40.894641 | 2018-03-22T09:29:28 | 2018-03-22T09:29:28 | 121,407,394 | 0 | 0 | MIT | 2018-03-22T09:29:29 | 2018-02-13T16:37:36 | HTML | UTF-8 | Python | false | false | 4,371 | py | test_browser.py | import contextlib
from unittest import TestCase
from unittest.mock import MagicMock, patch
from typing import Optional
from nose.tools import ok_, eq_
from student_portal_crawler.browser import PortalBrowser
from student_portal_crawler.page import Page
from student_portal_crawler.parser import SupportedPages
class T... |
1ebc2cf454dc4ee24f88263364701cc8a2a631cb | c00e388448b5f42152af48b70fb56f98d1c747f9 | /elasticapm/transport/http_base.py | 1f4053a2e3eaeb2f139692cbc9c3cb02dc823b2b | [
"BSD-3-Clause"
] | permissive | laerteallan/apm-agent-python | 2bd86080f047203d294887c3d80c58fe67c96008 | 62e494fa032e69bf4999cbc0efb30b80093ad5ba | refs/heads/master | 2020-03-31T11:04:42.238926 | 2018-11-13T12:53:45 | 2018-11-13T12:53:45 | 152,162,450 | 2 | 0 | BSD-3-Clause | 2018-10-09T00:08:13 | 2018-10-09T00:08:13 | null | UTF-8 | Python | false | false | 2,029 | py | http_base.py | # -*- coding: utf-8 -*-
from elasticapm.contrib.async_worker import AsyncWorker
from elasticapm.transport.base import AsyncTransport, Transport
class HTTPTransportBase(Transport):
scheme = ["http", "https"]
def __init__(self, parsed_url, verify_server_cert=True):
self.check_scheme(parsed_url)
... |
91de9c4a97388b2d4173fe6c9b3ceaa22ab8941d | 30da876e48affb8557fb8c264ba4050c4ff50573 | /train_model.py | 639fde5ef5d4f6a73062e5723db6f93581f19af6 | [] | no_license | smalldatabrains/python-gameAI | 158398ba87b5f8804781988daa873dde51def1cd | 77fe85247afdc577c4bde12ccf06ff9f028b078c | refs/heads/master | 2020-03-23T07:20:17.829068 | 2018-07-17T09:18:17 | 2018-07-17T09:18:17 | 141,264,759 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 801 | py | train_model.py | from keras.models import Sequential
from keras.layers import Dense, Activation, Flatten, Convolution2D, Permute, Dropout
from keras.optimizers import Adam
from keras.callbacks import TensorBoard
model=Sequential()
model.add(Conv2D(32,(3,3),padding='same',input_shape=x_train.shape[1:]))
model.add(Activation('relu'))
... |
2f2819163da2816ab8cd4851fb75344c522c3cf5 | f312fcd24d94be8b32e2d1e50643b01c619aa23b | /tensorboard/plugins/mesh/test_utils.py | 34390d6d2a2b0bf41497ffb9f107f3c7d464a18a | [
"Apache-2.0"
] | permissive | tensorflow/tensorboard | bf316fc5d47f78ef980dd2106c99207892a508d5 | 5961c76dca0fb9bb40d146f5ce13834ac29d8ddb | refs/heads/master | 2023-09-03T23:59:03.264261 | 2023-08-30T22:24:07 | 2023-08-30T22:24:07 | 91,379,993 | 6,766 | 2,063 | Apache-2.0 | 2023-09-14T20:55:56 | 2017-05-15T20:08:07 | TypeScript | UTF-8 | Python | false | false | 3,367 | py | test_utils.py | # Copyright 2019 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
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applica... |
f8463efc519f4aa899d8810c253c3c5f8bf35a74 | 7efac68ec6d9f149d06e04491add60b649aa04dc | /utils/utils.py | fb049820f4740d8c380e6dc76c71ea98fc8efb4e | [] | no_license | trung1309vn/person_detection_yolov3 | 9fa366239915825e9831262b2d2a394d20e8fd59 | 71bf2ba1c2757d0639e175eadeeed2de37d8b024 | refs/heads/master | 2020-12-13T16:05:48.010342 | 2020-01-20T06:39:26 | 2020-01-20T06:39:26 | 234,466,248 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,830 | py | utils.py | """
aioz.aiar.truongle - May 20. 2019
"""
import cv2
import os
import colorsys
import json
import numpy as np
from termcolor import colored
from PIL import Image
from sklearn.utils.linear_assignment_ import linear_assignment
def check_dir(directory, pr_flat=True):
if os.path.isdir(directory):
if pr_flat:
... |
f4fdcc5f8ae10e64ad6e1cf890795b1252d909b3 | 49333ef48ccbdd29504733acc3fbe2e5a268e2ca | /packtSnatch.py | b1276aec01ad107b9e689859b00c268c75f9efb8 | [
"MIT"
] | permissive | PatOConnor43/packtSnatch | 34f3943c206a8cb4af374cf99f185b0216153708 | 8e4224b6c68c23a2b3d7c22215d5d39fe74feb06 | refs/heads/master | 2020-12-03T00:14:36.839957 | 2017-07-02T05:52:41 | 2017-07-02T05:52:41 | 96,004,483 | 0 | 0 | null | 2017-07-02T05:33:27 | 2017-07-02T05:33:27 | null | UTF-8 | Python | false | false | 5,127 | py | packtSnatch.py | '''
@author: TJ Nelson
Order and Download Tool for Packtpub Free Learning
'''
import ssl
import os
import shutil
from requests.adapters import HTTPAdapter
from requests.packages.urllib3.poolmanager import PoolManager
import requests
import argparse
from bs4 import BeautifulSoup as bs4
parser = argparse.ArgumentParser(... |
7cc003cf9349621fa58b096d2514aae16890f48d | 5b8f75a3e6d7b2af185e3670ce8aeb4e88ed5c9b | /homework/home_work_guessing_numbers.py | 3e7db2802b0b1c619d462fbb13e72a5e20d44436 | [] | no_license | kiriloid/Python_tryouts | 0a02a494704c4522d9f70bb5cc0e751ef0563b97 | 725854fe7e9fa22a5a2ba88411f7a9158f7c7f54 | refs/heads/master | 2020-06-10T17:41:49.881950 | 2018-03-27T11:00:27 | 2018-03-27T11:00:27 | 75,918,280 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 402 | py | home_work_guessing_numbers.py | print('Soft for guessing numbers from 1 to 5')
print("Please enter the number from 1 to 5")
a = input('Is it less then 3 (y/n):')
if a == 'y':
b = input('Is it 1 (y/n):')
if b != 'y':
print('Your number is 2')
else:
c = input('Is it 4 (y/n):')
if c != 'y':
d = input('Your... |
5e291e4b7e4675bce45974cfffa418f537cce99e | 43bb84e3aa665bc89e7d72335f08267a31860798 | /validate_sptx/test_field_of_view.py | b93c3768c495a57b763b152244d68b49cb53e3da | [
"MIT"
] | permissive | spacetx/sptx-format | d7cb30e8c81c28145923c7c93d5b3f6542f98feb | c21c01b9a47546b6dba23fc0973379a5e2e988a5 | refs/heads/master | 2020-03-25T07:10:53.442317 | 2018-08-31T14:38:45 | 2018-08-31T14:38:45 | 143,546,242 | 2 | 2 | MIT | 2018-09-07T16:19:38 | 2018-08-04T16:47:11 | Python | UTF-8 | Python | false | false | 1,337 | py | test_field_of_view.py | import os
import pytest
from .util import SpaceTxValidator, package_root
schema_path = os.path.join(package_root, 'schema', 'field_of_view', 'field_of_view.json')
validator = SpaceTxValidator(schema_path)
example = os.path.join(package_root, 'examples', 'field_of_view', 'field_of_view.json')
def test_field_of_view... |
9be952ba0691f03d35600595b38a183b16bd418a | 518bf342bc4138982af3e2724e75f1d9ca3ba56c | /solutions/2156. Find Substring With Given Hash Value/2156.py | 05d0e1257967ffe131be2166896e94ab3d6368df | [
"MIT"
] | permissive | walkccc/LeetCode | dae85af7cc689882a84ee5011f0a13a19ad97f18 | a27be41c174565d365cbfe785f0633f634a01b2a | refs/heads/main | 2023-08-28T01:32:43.384999 | 2023-08-20T19:00:45 | 2023-08-20T19:00:45 | 172,231,974 | 692 | 302 | MIT | 2023-08-13T14:48:42 | 2019-02-23T15:46:23 | C++ | UTF-8 | Python | false | false | 480 | py | 2156.py | class Solution:
def subStrHash(self, s: str, power: int, modulo: int, k: int, hashValue: int) -> str:
maxPower = pow(power, k, modulo)
hash = 0
def val(c: str) -> int:
return ord(c) - ord('a') + 1
for i, c in reversed(list(enumerate(s))):
hash = (hash * power + val(c)) % modulo
if ... |
1e26121a49c95fb86c895eb6f5cd9720d914d299 | 5027b9b2a0e803deb02c875374c433533cc1c8f4 | /debug.py | 949345d2636cd00c999f27650ffc2862b4b66712 | [] | no_license | bobfrank/pydebug | aa4208e08f246f5639cff4a752f647f989730923 | 84c8b7842ea144c6a174e6107dfc5fe23320cda5 | refs/heads/master | 2016-09-05T15:57:08.883601 | 2012-04-09T16:51:18 | 2012-04-09T16:51:18 | 3,945,930 | 3 | 1 | null | null | null | null | UTF-8 | Python | false | false | 22,050 | py | debug.py | from __future__ import with_statement
import os
import sys
import threading
import pickle
import traceback
import shutil
import time
import cmd
import uuid
import socket
import base64
import select
import signal
import ctypes
import errno
import contextlib
import inspect
import dis
try:
import _thread
except Import... |
6d0cbc5807ce622944666f8fe3c97bcccdc73330 | 51dbc2e433a8d109b17dc8bed8fce88896031d92 | /maintainmood/migrations/0003_status.py | 01948826ec6099d452d9f8c2e78ededa1bd77b86 | [] | no_license | rfcabasag/Mood | 85bf163a392b476199953b5724d477a6c92ec5f6 | d31ad099afe13a11f09dc60b73fc0add35a16718 | refs/heads/master | 2023-05-03T10:22:57.295805 | 2019-05-23T09:23:06 | 2019-05-23T09:23:06 | 168,290,153 | 1 | 0 | null | 2023-04-21T20:32:37 | 2019-01-30T06:18:52 | HTML | UTF-8 | Python | false | false | 823 | py | 0003_status.py | # Generated by Django 2.1.3 on 2019-02-20 16:30
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('SignUp', '0001_initial'),
('maintainmood', '0002_auto_20190220_1315'),
]
operations = [
migrations.... |
24d6a4fd67c701b259cc2658796acf08074c6b68 | 97118a484b20e188e6469fa8652f2a20f159745d | /crawlerservice/cache/fscache.py | 2881cfb0a4df5b284f1e5519ab1aa9315fb2671e | [] | no_license | Justinyj/ruyiwebcrawl | 7cf7805d2d1b4a6c3fc7341ab47a2aba096a5323 | 6f7205b00f1a105f4505cf4ee571f2c53762dc3e | refs/heads/master | 2020-07-13T07:24:23.531659 | 2016-11-16T02:18:02 | 2016-11-16T02:18:02 | 73,888,981 | 0 | 2 | null | null | null | null | UTF-8 | Python | false | false | 2,113 | py | fscache.py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
# Author: Yuande Liu <miraclecome (at) gmail.com>
#
# 1. directory hierarchy: raw/{lastest, snapshot(url+date)}, meta/*.log.
# purpose: if URL is deleted by website.
# 2. log name: ip+date.log
# purpose: tornado setup on different machine, rsync log merge.
# 3. log co... |
e91662ca381b96122041084de304776eb1f1dc55 | 0b2deec9f85e4dd54cedb10f3f6004e6a7aa8047 | /wx_server.py | f7d9d1172f80484290b3600853dcae0aff6bb6e9 | [] | no_license | BarryZM/Chinese-chatbot | e2c60de372253bede80eb208e8a8ed3eb401fe2b | 5826aded8d6b063c4a84b6d004f53b18fbf02df9 | refs/heads/master | 2022-03-29T06:30:44.904856 | 2020-01-11T15:34:58 | 2020-01-11T15:34:58 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,515 | py | wx_server.py | # -*- coding: utf-8 -*-
# @Author : fanzfeng
import sys, codecs
import web
import hashlib
import weixin.receive as receive
import weixin.reply as reply
from final_bot import one_bot, random, re
from bot_config import *
# import concurrent
try:
sys.stdout = codecs.getwriter("utf-8")(sys.stdout.detach())
except:... |
81558735b1304f19a782cc8da6895ccc59241254 | bca74fb3429a670b30c6de08a22ef869d1d6a0b4 | /lab6/fold/fold.py | ab98789184d61cbcd7a115e7f3a6b06b1eeac2db | [] | no_license | gsdeange/CSC-101 | df7b5c11b9c4a5b8e1a46710584250019adb60e5 | 1a17b6e06880a32fa539aaa380220b9d122c5093 | refs/heads/master | 2020-04-16T09:07:12.837640 | 2019-11-25T19:07:00 | 2019-11-25T19:07:00 | 165,451,624 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 367 | py | fold.py | numList = []
def sum(numList):
sum = 0
for i in numList:
sum+=i
return sum
def index_of_smallest(numList):
if(len(numList) <= 0):
return -1
smallest = numList[0]
smallindex = 0
for i in range(len(numList)):
if(numList[i] < smallest):
smallest = numList[i]
... |
5de4beccd82aafb112800e20e7827a2314e8222f | 1a758ef862f733d98ddd8ebc8ade5cefd95c24f2 | /customers/factories/address.py | 4e47c608fb01ab15628d4f2fb4fb09163f0e7731 | [] | no_license | ajajul/ReactJS_Python | f116b35394666c5b3f2419eb5d8d7aeb077d4a24 | 08310d56fa88f326ddbfdd4b189f2a3a71f76d99 | refs/heads/master | 2020-03-19T03:16:57.510672 | 2018-06-01T10:36:36 | 2018-06-01T10:36:36 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 711 | py | address.py | import factory
from django.db.models.signals import post_save
from . import CustomerFactory
from customers.models.address import Address
@factory.django.mute_signals(post_save)
class AddressFactory(factory.django.DjangoModelFactory):
customer = factory.SubFactory(CustomerFactory)
name = factory.Faker('state... |
6426090059e4477912f626879e6565cc693beecd | 5b6853d636cb12708834e2baec247b33bb4e4e20 | /chimp_weather/utils/observation/observation.py | 4b946a5835447df0bbf862a9c2aa6ccbfa050ce4 | [] | no_license | jgsogo/chimp_weather | 7f370a1791d0232ca903227816f64df984e93ffd | c9e2e2691eefddc75bfdc2d5dbc4ec7c86e0c267 | refs/heads/master | 2021-01-25T12:02:44.321232 | 2015-02-27T14:27:21 | 2015-02-27T14:27:21 | 31,063,084 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,236 | py | observation.py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
from datetime import datetime, timedelta
from chimp_weather.utils.mesh.point import Point
class ObservationData(Point):
def __init__(self, longitude, latitude):
super(ObservationData, self).__init__(x=longitude, y=latitude)
@property
def longitude(s... |
0fe5d8a6322522540a3ddc140e7b95077fc18c3c | 37db38fe74c59553aebeadbb83b7c4ff616a0ab3 | /djangoTemplate/main/apps/first_app/views.py | 24cd8ec916c0156df95033962f6dc0dc8b0ac02f | [] | no_license | voidnote/Django | 9ae3cbf4c51a86ac9d485ed583d892c79ead9576 | 1d6cbcfdeecf998939e0a777fe6478ff7a66421b | refs/heads/master | 2021-01-19T20:41:02.211223 | 2017-04-26T19:52:52 | 2017-04-26T19:52:52 | 88,532,684 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 145 | py | views.py | from django.shortcuts import render, redirect
# from .models import <name>
def index(request):
return render(request, "first_app/index.html")
|
da212ded7a09c8223b39563e4c0fa66df3458fac | d0b09f8e29f1c0d9a889943dc7fe48811b8dc074 | /data/analyze.py | 5d8fd83d3d1fbf74e475ce8e22258457094fecba | [] | no_license | ashtonteng/BrainMusicController | c6c2ab2a1317cc30b4fe2304fb751e3bed8cba6c | fb990ac9e3ff620464c5a8721b8b2e07d15f632d | refs/heads/master | 2021-07-11T10:11:05.946434 | 2017-10-11T07:21:31 | 2017-10-11T07:21:31 | 106,515,216 | 0 | 0 | null | 2017-10-11T06:38:48 | 2017-10-11T06:38:48 | null | UTF-8 | Python | false | false | 1,021 | py | analyze.py | import numpy as np
from numpy.linalg import inv
import matplotlib.pyplot as plt
off_data = np.genfromtxt('museOff2.csv', delimiter=',', skip_header=1)
on_data = np.genfromtxt('museOn2.csv', delimiter=',', skip_header=1)
# alphas = [off_data[:,8], on_data[:,8]]
for i in range(8, 12):
print('alpha, off vs on')
print(... |
3523b6b8ca5fe74c94c9d6c68d74da0830568034 | 8fcc2e9a717ce84825b186e112a87fffae19f333 | /CH05/scaling.py | 722834dd71aceae38cdfa52e812f83c7840c2675 | [] | no_license | woogie-s/OpenCV-Python | 70ac82b5eb7e1ce7761e657e366cc511c111bbbd | 6b1891d35a11ab9501bd66357b291aa6cffc2459 | refs/heads/main | 2023-03-17T07:39:21.242483 | 2021-03-08T12:52:33 | 2021-03-08T12:52:33 | 309,363,678 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,072 | py | scaling.py | # 5-02. 영상의 확대와 축소
import sys
import numpy as np
import cv2
src = cv2.imread('ref/rose.bmp') # src.shape=(320, 480)
if src is None:
print('Image load failed!')
sys.exit()
# 결과영상 크기 dsize 또는 x와 y방향 스케일 비율 fx, fy 중 하나는 입력해주어야 함.
# dsize가 (0, 0)이면 fx와 fy값을 이용해 결정
dst1 = cv2.resize(src, (0, 0), fx=4, fy=4, in... |
ae661343b03969bc009cd8793be3c3830e868fe6 | de6b0b90110f1f629fa445f1ea59f24838ecce3a | /code_monk/arrays_strings/palindrome.py | 52b9cbb77d08af838fce253f9d97ccbd0c358709 | [] | no_license | karnikamit/Algos | 43d915495c6d4679b7175a6afb45cb70c18b013e | 43521de94ff7d8c3e2bef943f458f15123cea899 | refs/heads/master | 2020-12-24T05:39:43.987714 | 2017-10-04T10:37:18 | 2017-10-04T10:37:18 | 35,757,003 | 1 | 0 | null | 2016-10-30T06:28:48 | 2015-05-17T07:52:23 | Python | UTF-8 | Python | false | false | 269 | py | palindrome.py | # -*- coding: utf-8 -*-
__author__ = 'karnikamit'
cases = int(raw_input())
for _ in xrange(cases):
ip_string = raw_input()
if ip_string == ip_string[::-1]:
print 'YES {}'.format('EVEN' if len(ip_string) % 2 == 0 else 'ODD')
else:
print 'NO'
|
69ed7d362e4079117d4171270c60c9588b743ee2 | 938c4b8966b388f16cc6a32abab8b66efc18e500 | /services/elasticsearch/eservice.py | 55ee32b36dc22549796c40fe857a1766ceecbb4b | [] | no_license | MiklukhoPognaly/vacation-planner-middleware | 361364a8ea357e62e5dc057e668422451f8cb928 | eb85f4fbed4812d280d385dc0c58ed762cf4b331 | refs/heads/master | 2023-03-12T01:09:13.278506 | 2021-03-01T19:23:32 | 2021-03-01T19:23:32 | 221,511,469 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,810 | py | eservice.py | # -*- coding: utf-8 -*-
import requests
import json
from elasticsearch import Elasticsearch, helpers
import os
import uuid
from config import elastic_url as el
from config import main_logger
# create a new instance of the Elasticsearch client class
elastic = Elasticsearch(el)
def script_path():
"""
a simple f... |
e0cddca532e8d6eb58324dbdca4c2f559fd5834d | c90a78681d4d6670ed5ba803873062bda600a0f8 | /ep1.py | acfc2e4b746bca8148e54f63bc52b7c58b5026ce | [] | no_license | davelindley/LeonTutorial | 1c11a1652adad43cbd4a97693e587ebd8bd3b54a | 1af0aa4cdedfdadebe27ca0525f0a14e61e4c9eb | refs/heads/master | 2020-04-24T00:57:07.016233 | 2019-02-20T01:48:56 | 2019-02-20T01:48:56 | 171,581,224 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 1,092 | py | ep1.py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
Episode 1 - Data types - Strings, Integers, Lists
Goal Output:
#basics
leon
4
['bud light', 'yeungling', 'reef donkey', 'jai alai']
---------------
#multiplication
leonleonleonleon
4
16
4444
yeunglingyeungling
---------------
#slicing (like this[3])
o
n
l
e
-... |
1cf60097f02b51091ade3f34a43446752dd978dd | 41df3884786cbb4fc8f5565443efb02e01d1f1ff | /common/Excel.py | 119d9eefc12b45346c682350d3f5e87198a3820a | [] | no_license | xingye1129/autotest | ef215f6a5b3d1d6ad85f60e9d16b455865e9b139 | bbe6301be30af627853f877bed5abfa425270844 | refs/heads/master | 2020-12-02T21:29:22.957874 | 2020-01-05T12:59:46 | 2020-01-05T12:59:46 | 231,120,987 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,582 | py | Excel.py | #coding:utf8
import os
import xlwt,xlrd
from xlutils.copy import copy
class Read:
"""
用来读取Excel文件中的内容
"""
def __init__(self):
#整个exce工作簿缓存
self.workbook = None
#当前的sheet页
self.sheet = None
#当前sheet的行数
self.rows = 0
#当前读到的行数
self.r = ... |
f8a6801ab3de7c0d7fda1ba64a700e853096748d | 9d5e6c08935725bbe7252f141dcd85d758515baa | /box_score_bref_v2.py | 471456e8fd26376f80d2fb56078f735e375c215a | [] | no_license | ncalkins89/NBA_data | 85fee590b76fb5370370a57872236981f0e7eb74 | ae1f4c0611b2acb83a3d7a0044afbc3eb635d5ab | refs/heads/master | 2021-04-28T19:22:47.179044 | 2020-08-26T21:16:48 | 2020-08-26T21:16:48 | 121,894,871 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 6,026 | py | box_score_bref_v2.py | from bs4 import BeautifulSoup
import re
import requests
import pandas as pd
import numpy as np
import datetime
import scraper_utilities as su
# TODO: restructure the passing around of identifiers (date, team, etc.) so that script can more effecively
# be run for SINGLE games. Currently, all ID columns can only be add... |
1f0f5485866ff1eda37c20e4a2ff12611fc5f411 | 034218bcbb524fb4bfb20754a994774e1e84fd9e | /mindsdb/scraps.py | 5fdf4571bbfd0afdd5df94c55164c13363d800e0 | [
"MIT"
] | permissive | bpx-energy/mindsdb | 6a5bdae2d851414d7c77999a20c0066057d9685d | 8bf8bd830642a83be0de28a5ccc914a948bb9d4c | refs/heads/master | 2020-06-17T22:13:01.498419 | 2019-07-09T20:38:37 | 2019-07-09T20:38:37 | 196,075,941 | 1 | 0 | MIT | 2019-07-11T14:40:18 | 2019-07-09T20:05:59 | Python | UTF-8 | Python | false | false | 4,278 | py | scraps.py | '''
This file contains bits of codes that we might want to keep for later use,
, but that are are currently not used anywhere in the codebase.
'''
# Previously in: mindsdb/libs/helpers/train_helpers.py
def getAllButOnePermutations(possible_columns):
permutations = {}
for col in possible_columns:
poss... |
5ef76ab8963e4be741b08a1c09990598bbe980a7 | 8417d56f8037e0ba36e6f9400ebff6bcc31384a8 | /blackjack_simulator.py | dd5d4024662938955c4d066a5ef4002de001f5cf | [
"MIT"
] | permissive | BonsaiAI/gym-blackjack-sample | a8e4048fe552b9d43b0bfca11aeb9e9b957d5116 | d8cd368e488befc62c7bd15894097d4bb394704c | refs/heads/master | 2021-01-24T09:34:42.349635 | 2017-08-09T18:54:29 | 2017-08-09T18:54:29 | 69,302,450 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,474 | py | blackjack_simulator.py | import gym
import time
from functools import reduce
import bonsai
from bonsai_gym_common import GymSimulator, logging_basic_config
ENVIRONMENT = 'Blackjack-v0'
RECORD_PATH = None
SKIPPED_FRAME = 1
RECORDING_TIME = 40*60*60
class BlackJackSimulator(GymSimulator):
def __init__(self, env, skip_frame, record_path)... |
6e936ec4e80dae684fd4eaff8296e19d40c9188a | 98998f7ca78398530f6f8f8f8a0ec29cb8fc2f05 | /evenum.py | 46fd4f4360b7705238ada091e36b6215de73e6fb | [] | no_license | suryaaathhi/guvi-program | e1fd299de569f1563ef052366cda1bd31ecbdfb4 | 15610ba842e9363df802a4274419018a1a4a67a0 | refs/heads/master | 2020-05-23T02:02:26.644486 | 2019-08-11T02:16:12 | 2019-08-11T02:16:12 | 186,595,340 | 0 | 1 | null | null | null | null | UTF-8 | Python | false | false | 96 | py | evenum.py | val=int(input())
val1=int(input())
for i in range(val+1,val1):
if(i%2==0):
print(i)
|
764c8ece8db428cca6dcd98ca973e12d90c70c2a | 94d1a4bb2228a93078e291389ea66e51c4225b19 | /Linuxp/autowork/hostops/fabric/host_fabric.py | f20c7943f295817be54d94501e125b1b390b20bf | [] | no_license | beike2020/source | 04b68a22dadb6485546c93a5649700a758464738 | ed5ed9c4857815b676b86b7438670590a5b8f059 | refs/heads/master | 2020-12-24T21:10:49.463514 | 2016-06-09T05:33:19 | 2016-06-09T05:33:19 | 58,797,943 | 1 | 2 | null | null | null | null | UTF-8 | Python | false | false | 5,320 | py | host_fabric.py | #!/usr/bin/env python
#fab -f host_fabric.py [-H 192.168.1.22,192.168.1.23,192.168.1.24] [-l list] [-- 'cmd'] go
#fab [-f host_fabric.py] [-g 192.168.1.21] [-R role] [-t local-timeout] [-T remote-timeout] [-w] [-P asyn] host_type
import time
from fabric.api import *
from fabric.colors import *
from fabric.context_man... |
8d78da1a0db5c88d9552be8fbd927bbcc122a4b3 | e7ff238731967647b71d2fe5caa7b2bf4c6eb671 | /jstorm-core/src/main/py/storm/ttypes.py | cb232d8861f00ca84c3dbf058c65fd4ef6436130 | [
"Apache-2.0"
] | permissive | alibaba/jstorm | 79062e31c3cfe29a9b3aa34ba9ecdb19645a278b | 0e228558b43f452c7a82400e24d2d9772d09c41e | refs/heads/master | 2023-06-22T06:00:57.468002 | 2023-06-16T07:13:49 | 2023-06-16T07:13:49 | 12,554,530 | 4,159 | 2,079 | Apache-2.0 | 2022-11-03T10:34:09 | 2013-09-03T03:53:16 | Java | UTF-8 | Python | false | true | 176,491 | py | ttypes.py | #
# Autogenerated by Thrift Compiler (0.9.2)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py:utf8strings
#
from thrift.Thrift import TType, TMessageType, TException, TApplicationException
from thrift.transport import TTransport
from thrift.protocol import TBinaryProtocol, ... |
4ace4648a5956079e6023666cd8b9f15d4b2ffbf | 87fe99837ee7f8b8e2dac4fd69ab8645f14c219d | /Spacing/Show Glyphs Using This Glyph As Metrics Key.py | 3b29b7afae83e5abb2b98dfe084bf6f3d8d6c543 | [] | no_license | weiweihuanghuang/wei-glyphs-scripts | 8ce2df3f2a46d5efdc530fb565b5bd35b66ec090 | 5a105cbe7631edd667691567388386dfb1dc19b9 | refs/heads/master | 2023-05-11T05:55:24.805693 | 2023-05-05T02:53:41 | 2023-05-05T02:53:41 | 33,481,430 | 43 | 9 | null | 2021-09-15T02:54:03 | 2015-04-06T12:43:38 | Python | UTF-8 | Python | false | false | 637 | py | Show Glyphs Using This Glyph As Metrics Key.py | #MenuTitle: Show Glyphs Using This Glyph as Metrics Key
# -*- coding: utf-8 -*-
__doc__="""
"""
import GlyphsApp
import collections
thisFont = Glyphs.font
selectedLayers = [l for l in thisFont.selectedLayers if l.parent.name != None]
stringOfGlyphs = ""
for l in selectedLayers:
for g in thisFont.glyphs:
thisGlyp... |
89cbf1cb0075ede55ecfdd656bed30341f3917aa | 2516d121d52ce797fd40c0bc9d49551273f195a9 | /setup.py | f03cb3c6d4a045bdf8d33ca9becb3ff4d33d375f | [
"BSD-2-Clause-Views",
"BSD-2-Clause"
] | permissive | RafaelMarinheiro/SfM_Init | 1271007b5040ac90d428576b72b7d113c1457dd5 | 5a04ef6cbcdd527d0b4d6d393477bb56096d5e4a | refs/heads/master | 2021-01-24T15:06:46.311717 | 2014-12-10T04:38:48 | 2014-12-10T04:38:48 | 27,015,027 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,288 | py | setup.py | from distutils.core import setup
from Cython.Build import cythonize
from distutils.extension import Extension
"""
Use this setup.py script to compile and install the cython/C++ extensions for solving global
Structure from Motion translations problems. These allow using C++ functions (linking with
ceres-solver) from py... |
1305869a9d6802b28f5f2f0e0e234110075d91f7 | e6f52ff0611f1eaf9ea095a01c0ddf981558e0b3 | /trac_cucumber/trac_cucumber.py | 4010ba6026a8e8dc8a193dcc3ff61dc3d8bfc083 | [] | no_license | nightscape/trac_cucumber_plugin | db3f22b981bd4dc7b342080ab3da765b1bcc1237 | fdb436779835ed02b780c4c851980949c9e705f2 | refs/heads/master | 2021-01-16T21:04:37.162785 | 2009-07-29T11:07:24 | 2009-07-29T11:07:24 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,150 | py | trac_cucumber.py | from trac.core import *
from trac.config import ExtensionOption
from trac.wiki.api import IWikiMacroProvider
from interfaces import *
from pkg_resources import resource_filename
class TracCucumberPlugin(Component):
implements(IWikiMacroProvider)
# definition of extension points
database = ExtensionOpti... |
772e2ffa49e1e9ecf0781da622278f739494054d | 4d2af70b4027abaead545099bb0da889bc472e34 | /instruments/nanovoltmeter.py | 8335ff63b2af5b92c8dd6439d78535dc1fd50cf2 | [] | no_license | nikhartman/measurements | 8f47261f7ffd97e35d7b46d9dac25d6cd712a762 | 16bab40e728d86a4b97a059b28fe0b6740b83ace | refs/heads/master | 2021-01-18T18:35:09.596241 | 2015-01-17T18:45:36 | 2015-01-17T18:45:36 | 8,974,342 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,420 | py | nanovoltmeter.py | """ This is a set of classes for different types of measurements utilizing the
Keithley 2182(A) nanovoltmeter. If it turns out that I only use one class in
here, this should be merged with instruments.py """
from __future__ import division
import time
import instruments #creates the source object
cl... |
374b85e0b6f666ccaff3be957daa75afa7704442 | 702965e55d23c7611993651789adf8b9fafb090c | /jobs/PeerChecker.py | 52969b7b2da5ca9f3bfe10a211adb73ced504ac4 | [] | no_license | tomrittervg/checker | 6f7c9fee7683a5627144ab2b94cd477bd7db0295 | 788f19098c98a8cbf1d8e5217a7846b20969a4c3 | refs/heads/master | 2022-08-09T18:25:43.139568 | 2022-07-22T06:12:47 | 2022-07-23T12:58:39 | 50,396,909 | 4 | 1 | null | 2022-07-23T12:58:40 | 2016-01-26T02:26:03 | Python | UTF-8 | Python | false | false | 3,091 | py | PeerChecker.py | #!/usr/bin/env python3
from __future__ import absolute_import
from builtins import str
import os
import base64
import logging
import datetime
import imaplib
import requests
from . import JobBase
from . import JobSpawner
class PeerChecker(JobSpawner.JobSpawner):
class IndividualPeerChecker(JobBase.JobBase):
... |
9c5ca9b4d9ef900e01e5cf7d89ec6645daa90689 | c46260c40054c0499e0a6871e4d3fe2d6d8aa9c0 | /Pdf2txt/PdftoTxt3.py | 884ac32edb60495709859baa39712f8b63ac5fe8 | [] | no_license | iiot-tbb/learngit | 1d6f5c234f1c36016be5489c7ec605f666bbba16 | dfa3106d05bcbb0da39b9bf71f7a0698322130f7 | refs/heads/master | 2020-08-30T01:30:07.632602 | 2019-12-07T13:09:59 | 2019-12-07T13:09:59 | 218,225,081 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,069 | py | PdftoTxt3.py | #!/usr/bin/env python
# coding=utf-8
from pdfminer.pdfinterp import PDFResourceManager,PDFPageInterpreter
from pdfminer.converter import TextConverter
from pdfminer.layout import LAParams
from pdfminer.pdfpage import PDFPage
from io import StringIO
import sys
def convert_pdf_to_txt(path):
rsrcmgr =PDFResourceManage... |
6e743f7fe76dc4f91fb12c289f76fe8cfd57aeb0 | 61ba555290135459ab781e63d66aec29ee412a9e | /classifier.py | dab76a62141849ff7d6d0c8ad835a0483e276f1a | [
"MIT"
] | permissive | Shoot-to-root/fakeNewsDetectionML | 76cb3fadedd76121880ecf6890e74c4108a9d0f2 | 56661c66c7a551b18ec6ac536fbeb4940dc7fb16 | refs/heads/master | 2020-05-07T10:01:55.486778 | 2019-06-30T17:30:42 | 2019-06-30T17:30:42 | 180,402,173 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,502 | py | classifier.py | # -*- coding: utf-8 -*-
"""
Created on Mon Oct 15 22:07:10 2018
@author: sone_e
"""
from sklearn.model_selection import cross_val_score
from sklearn.naive_bayes import MultinomialNB
from sklearn.metrics import classification_report
from sklearn.linear_model import LogisticRegression
from sklearn.linear_mo... |
cc5bc83bfa9780acbfa8985ea869fd05b0627d5a | 9ae62c6ac4ca35948ea821b040820927ae3eb78e | /CursoEmVideo - Exercícios/Desafio 47 - Pares entre 1 e 50.py | 2cfd13c981261874f2b08246e883bcb9c8038dba | [] | no_license | ParzivalMarcos/EstudosPython | 971955eb57d2df2daa1ff7be9324351c7bd1c719 | ab839dea6c9f5abbc4d582b12d2bba1a632a1a13 | refs/heads/master | 2020-12-03T10:00:51.374156 | 2020-01-29T15:20:02 | 2020-01-29T15:20:02 | 231,277,392 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 146 | py | Desafio 47 - Pares entre 1 e 50.py | # Crie um programa que mostre na tela todos os numeros pares que estão no intervalo entre 1 e 50
for c in range(0, 50, 2):
print(c, end=' ')
|
2c144ba86999c7b39fa92dc48df3d8e934bb210a | a2a7b8ab5b15afa9201e46a5f55fc3791b456c7d | /file_directory_creation_and_movement/tNames.py | 820ce9060e6eef0cb8d2a57fca0870b8f26eebc7 | [
"Apache-2.0"
] | permissive | tjhlovexyb/Automate-Work-In-Python | 20cd9302d96d1b4302d86b6099a36fae1103e79d | 7c6f690c9199e8b8e005630c1c30f2961b469e4e | refs/heads/master | 2020-11-29T07:17:52.757341 | 2019-12-19T09:26:27 | 2019-12-19T09:26:27 | 230,055,904 | 0 | 0 | null | 2019-12-25T06:48:00 | 2019-12-25T06:47:59 | null | UTF-8 | Python | false | false | 758 | py | tNames.py |
"""
测试文件
"""
import os
# 获取创新文件夹名
def getDirNames(path):
dirNames =[]
for root ,dirs ,files in os.walk(path):
for file in files:
if os.path.splitext(file)[-1] =='.pdf':
dirNames.append(file)
def main():
base_path = 'G:/WeChatDownload/码农有道 - pdf'
testName = "2018-1... |
5e38c780817b138dfc6ea4e877d0bbb32b146435 | 6c19ad40a3cbf32759bf71949ea0bbdd91e2bcb7 | /project/app/shared/apps.py | 8369402a730377af3fab4e2a059024e77065d7c6 | [] | no_license | rmaceissoft/open-elections-peru | 0ec9453fdcf10d2ab83e12ed65d0fd5ab5597c66 | 73155d49b062d358e073b745540d588d0c9f5b65 | refs/heads/master | 2023-04-11T02:13:08.634414 | 2021-04-16T18:24:24 | 2021-04-16T18:24:29 | 358,420,423 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 173 | py | apps.py | from django.apps import AppConfig
class Config(AppConfig):
name = "app.shared"
label = "app_shared"
verbose_name = "Shared"
def ready(self):
pass
|
6c4695a320921b10f70d9e9c5bb4a246510591a4 | cf65eed9ba6cab607ef6ad4ac61dffa415f9b814 | /PythonPractise/HammingDistance.py | ed8ba123e67ab48631537cf221f16c4d16afb32f | [] | no_license | sreeharsham/GIT-Upload | d2ea3417de9f54384abb3ce72b4d60d1c49cf1cd | d5210eae58530a234b8054d78be2c83ee31cf537 | refs/heads/master | 2022-12-09T10:31:02.676328 | 2018-10-31T05:45:42 | 2018-10-31T05:45:42 | 155,483,062 | 0 | 3 | null | 2022-11-23T07:46:14 | 2018-10-31T01:57:49 | Python | UTF-8 | Python | false | false | 270 | py | HammingDistance.py | def toBin(x,y):
print("{0:b}".format(x))
print("{0:b}".format(y))
toBin(1,4)
#
# def toBinary(number):
# # num = str(number)
# print(number, type(number))
#
#
#
# if __name__ == "__main__":
# # toBinary(int(input("Enter number:")))
# pass |
6202e593a46d76a8feba88c0c9e3ed1a95f944a5 | 99a28a288eada8dd2b062debbc7d541e1de5c16f | /pyethapp/tests/test_jsonrpc.py | caf5eeb4df9dbcd5dd05c34df26033a1c874db9c | [
"MIT"
] | permissive | karlfloersch/pyethapp | 8fef565b262eb429a08bc95d2a428c82fa91cb8b | 47df0f592533dded868f052dd51d37ebe57e612f | refs/heads/dev_env | 2021-09-12T13:27:49.854579 | 2018-01-03T14:14:06 | 2018-01-03T14:14:06 | 110,370,508 | 8 | 7 | MIT | 2018-03-30T11:10:59 | 2017-11-11T18:40:30 | Python | UTF-8 | Python | false | false | 33,856 | py | test_jsonrpc.py | # -*- coding: utf8 -*-
from builtins import hex
from builtins import str
from builtins import range
from builtins import object
import os
from os import path
from itertools import count
import json
import gevent
import gc
import pytest
import rlp
import serpent
import ethereum
import ethereum.config
import ethereum.to... |
41915b45b7f5551e76c32795cfe55fb071712b7b | c243181ac3a10389b44eeb7092f6c3133341cdff | /demo/test/with_BaroboLink/driveTo.py | 84ce5834392f3b8c7d1393bdec5eb724eaa8040f | [] | no_license | davidko/PyBarobo | ffe1161462c589f3d6fe351fec85d6a7ae28b29e | 0589a364d06fcaeaa383f8230240ce23140b73b9 | refs/heads/master | 2021-01-23T20:14:44.706918 | 2014-08-26T18:26:15 | 2014-08-26T18:26:15 | 12,310,413 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 341 | py | driveTo.py | #!/usr/bin/env python
from barobo import Linkbot
import time
if __name__ == "__main__":
linkbot = Linkbot()
linkbot.connectBaroboLink()
linkbot.resetToZero()
print ("Moving joints to 90 degrees...")
linkbot.driveTo(90, 90, 90)
time.sleep(1)
print ("Moving joints to 0 degrees...")
link... |
83bbf13b3d6e96ecfeb5e1367f59abfa7e24a549 | 709312ad7ae583301768e8e6284a7b74c91aa168 | /venv/Lib/site-packages/pyqtbuild/version.py | 78bab6a5296a3f5ed31ab8f96e608cd58110e617 | [] | no_license | abhiraj2/khdownloader | d89fb3ed9f8cfd63a0fd56a394f8c62624cf4016 | ff10474af5e3b6ef07be65b087be2b2aa75eb893 | refs/heads/master | 2023-02-04T05:20:21.713431 | 2020-12-24T19:15:34 | 2020-12-24T19:15:34 | 317,094,861 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 61 | py | version.py | PYQTBUILD_VERSION = 0x010600
PYQTBUILD_VERSION_STR = '1.6.0'
|
bd9f774dbe8f26475cc8539d385520db789c2c58 | 0a3155bb2315b353401160ded30a5d1d51230aca | /provoke/provoke.py | 75e069645b1b979fd3f2b3a0096a4ee71d51884e | [
"MIT"
] | permissive | ahmedalishaikh/pyprovoke | 0997dfb635290407f997349d4f7a9ba2df357a0d | 45e2420839ed90ad3751be63897a16ee6a6c87cc | refs/heads/master | 2021-03-05T19:10:03.185397 | 2020-03-11T05:02:31 | 2020-03-11T05:07:51 | 246,144,895 | 1 | 0 | MIT | 2020-03-11T05:02:32 | 2020-03-09T21:22:59 | Dockerfile | UTF-8 | Python | false | false | 1,933 | py | provoke.py | import functools
import json
import os
RCFILE = ".invokerc"
def _get_mtime_from_rcfile(path: str):
if not os.path.exists(RCFILE):
return None
with open(RCFILE, "r") as fp:
rc_obj = json.load(fp)
try:
return rc_obj["provoke"]["file_mtime_record"][path]
except IndexError:
... |
850e14728c20fb0c87157f9858f70d15ebdf3bd0 | c0a1394d832943ef5d1cf1426a47452b43923866 | /sent_anal/predictor/sent_anal_predictor.py | b13238296163e05c7af7d0cef8739ba7c2713389 | [] | no_license | nguyenvanhoang7398/AllenNLP | af450ed373e423e0c0fed50b0f50ab1cd65f6b82 | a0a1bb3dfc2329423d8b5da1e89fc0a50a0e0622 | refs/heads/master | 2020-04-09T21:59:43.157434 | 2018-12-10T14:11:19 | 2018-12-10T14:11:19 | 160,617,622 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 814 | py | sent_anal_predictor.py | from allennlp.common import JsonDict
from allennlp.data import DatasetReader, Instance
from allennlp.models.model import Model
from allennlp.predictors import Predictor
from overrides import overrides
from typing import List
@Predictor.register("sentence_classifier_predictor")
class SentenceClassifierPredictor(Predic... |
dd94d1776f44548e6e791853fcf963ae31698cdc | eb954584d48315f248d0459c90ba93456bc2915c | /Level4/LinkedLists/List Cycle.py | 4d362e2b3827cabdabc7ad1f631954aca3f72672 | [] | no_license | Sauvikk/practice_questions | 366f701f763ea00576b80989e4d5428a618e8d4e | e678314b143e4cbf8cab28b6d924121345d1359b | refs/heads/master | 2020-04-06T04:12:56.605428 | 2016-07-22T18:18:28 | 2016-07-22T18:18:28 | 58,483,630 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,136 | py | List Cycle.py | # Given a linked list, return the node where the cycle begins. If there is no cycle, return null.
#
# Try solving it using constant additional space.
#
# Example :
#
# Input :
#
# ______
# | |
# \/ |
# 1 -> 2 -> 3 -> 4
#
# Return the node corresponding ... |
294b34ba38c8af51273c19642cc4cd70aa24cb40 | c5362bee7a846745cc71dea26dfd0b7ac7a37211 | /src/components/tests/test_spr.py | fd546231c0da010c81e52d9c832b6867547bf619 | [] | no_license | holaanna/nuclear-plant-crack-inspection-pipeline | 4f28dab4a9ff98f93a960611623e88312dec3d48 | 4f57ac51f27affa21b09188c6131c2af6bc7b3ec | refs/heads/master | 2023-03-16T01:16:24.460742 | 2019-10-21T01:37:58 | 2019-10-21T01:37:58 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 417 | py | test_spr.py | # -*- coding: utf-8 -*-
import os
import sys
sys.path.append("../")
from spr import SQLiteSPR
class_names = ("crack_prob", "no_crack_prob")
probabilities = ( 0.5, 0.3 )
spr = SQLiteSPR()
spr.open("test2.db")
spr.reset(class_names)
video_pk=spr.add_video("test.avi",320,200,100,25)
frame_pk=spr.add_... |
e9d5c3da9bfe1cdb8e9232279785b0315ea9b597 | 6ae101e2b2b19f63af4e5879d80a05d35bfd3fb6 | /Swap two numbers without using temporary variables.py | 374a7b95190aa7c6d7948dad4acc41f7df7dac63 | [] | no_license | Prakruthi94/Pylearning | 21242ac012bd8f426916603f5514f795ca15a7c2 | 39cc99d5b5ddaac707f6ff5b005b90ca48fa84dc | refs/heads/master | 2020-03-31T05:10:39.776106 | 2019-01-19T11:35:28 | 2019-01-19T11:35:28 | 151,936,253 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 228 | py | Swap two numbers without using temporary variables.py | def swap(ele1,ele2):
ele1,ele2=ele2,ele1
return ele1,ele2
def main():
ele1=eval(input("Enter the element1 to swap"))
ele2=eval(input("Enter the element2to swap"))
print("After swap",swap(ele1,ele2))
main()
|
48037b542e3d5ccc64b72fed8750e13989f0ff25 | 33a747246dab38960c25520d5232d5a37dfe2a01 | /weixin/wechat_spider.py | b991badbb1ca1ed25a352ecc87a4c164885b8ca8 | [] | no_license | Yxiaokuan/spider | 6a79a950d170ea20dae13001697b9c214872f345 | e51a398c7fdee1b1814c50c5a3121ce9a193e302 | refs/heads/master | 2022-04-02T16:01:18.104056 | 2020-02-11T03:49:44 | 2020-02-11T03:49:44 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,839 | py | wechat_spider.py | '''
@author:KongWeiKun
@file: wechat_spider.py
@time: 18-1-1 下午9:18
@contact: 836242657@qq.com
'''
import re
import itchat
from echarts import Echart, Legend, Pie
itchat.auto_login()
# itchat.send(u'你好','filehelper') #以文件传输的方式发送文件
#获取好友列表
friends = itchat.get_friends(update=True)[0:]
for i in friends:
print(i)... |
9acf7bc6eb38b49a756280483c8af7cf6f3ac269 | 210b21d5e5556808e7c52d99dffc278ea3abba39 | /src/organisation/views.py | 34a32f62abe3e7e914d833c1791199884c72cae6 | [] | no_license | rinkurajole/appointment-system | ad50d64f5c27de6ac0c7ac001e2e799cc9b1a82a | 52956638e55198f43b04258a6232b90ebbbabde2 | refs/heads/master | 2021-01-20T11:31:54.370291 | 2015-09-01T14:11:21 | 2015-09-01T14:11:21 | 40,468,507 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,404 | py | views.py | """
ViewSet for Organisation,OrganisationLocation and LocationContact.
"""
from rest_framework import viewsets
from organisation.serializers import OrganisationSerializer
from organisation.serializers import OrganisationLocationSerializer
from organisation.serializers import LocationContactSerializer
from organisation... |
7e37a8e7c678e5a5f317c709cc02e1f9269c898c | 2a7fcfaacd0d26d32b96e44b0ff6043a224d43ba | /RepairSoft/app/models.py | 13b57915176415d2063c833aada7ce588e1ede3d | [] | no_license | sharypovandrey/RepAIrSoft | bdb515dd62a243928be47d93f06c0e48c3fafac2 | 8f8789ab6734a17d7126ea603368fee18e27185c | refs/heads/master | 2020-04-02T03:24:27.461417 | 2019-01-25T08:25:07 | 2019-01-25T08:25:07 | 153,963,837 | 2 | 0 | null | null | null | null | UTF-8 | Python | false | false | 1,671 | py | models.py | """
Definition of models.
"""
from django.db import models
# Create your models here.
class TechnicalPerson(models.Model):
name = models.CharField(max_length=50, blank=True, null=True)
def __str__(self):
return self.name
class Building(models.Model):
name = models.CharField(max_len... |
3dd47a110fdff0ab1d28b8d6d32f098f3c8d15e6 | ecf2d3b1f9c73c8f91a9846e87528ec6655d3380 | /PY/Sully/Sully.py | af519ccae039b18c82018bf2927eeac7eaf61f79 | [] | no_license | etranchi/DrQuine | 16b7ad400ab58c5eaecd37ec0fff44d54d8e2a70 | 236abaeddf57b5257101df69a6c9287b407c40fb | refs/heads/master | 2020-07-02T17:38:44.277142 | 2019-10-21T12:46:46 | 2019-10-21T12:46:46 | 201,608,815 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 745 | py | Sully.py | #!/Users/etranchi/.brew/Cellar/python/3.7.3/bin/python3
import os
import sys
import subprocess
VAL = 5
exist = os.access("Sully_5.py", os.F_OK)
if exist:
VAL -= 1
if VAL < 0:
sys.exit()
next_file = "Sully_" + str(VAL) + ".py"
fp = open(next_file, "w+")
os.chmod(next_file, 0o777)
str = '#!/Users/etranchi/.brew/Cellar/... |
d694c5fe2c6cfba92cff786e22b9dae066a192dd | 82bf77f8944304e719e4a2bbd8719213b6aed1bb | /app/__init__.py | e9207332e0af878ee4b0e15eadf2b954e59552b2 | [] | no_license | lsxliron/DOT | c70d240913d74ea1cd812a235041b8ebb4bbe78c | 73b3f26dc38c8067a5da5f275151309e2ba4a3af | refs/heads/master | 2020-04-10T02:49:14.987672 | 2017-05-04T03:20:41 | 2017-05-04T03:20:41 | 51,126,142 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 633 | py | __init__.py | from flask import Flask
from flask_sqlalchemy import SQLAlchemy
#UPLOAD_FOLDER = "/var/folders/zj/55tydjfj3p53bccqkdpxm_3c0000gn/T"
UPLOAD_FOLDER = "/home/lsxliron/DOT/tmp"
app = Flask(__name__)
app.config['UPLOAD_FOLDER'] = UPLOAD_FOLDER
app.config.from_object('config')
db = SQLAlchemy(app)
#TOTO: REMOVE CORS
@app.a... |
df14b1180cd18000e2a4de7dde3c9a095f5122b0 | 6ae7a07cb077edcd581ec11224b79fc8df191f9e | /src/actors/Fruit.py | 4cd987c1a92a38149df4b0fb4d86e262a49ec2f7 | [
"MIT"
] | permissive | SkylarKelty/AI | 082804bf857f424c94e18b16bb5e0089469d00fc | f6835057236006160515c197e4df121006a088d2 | refs/heads/master | 2016-09-09T19:56:07.718770 | 2013-09-01T15:01:45 | 2013-09-01T15:01:45 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 548 | py | Fruit.py | from Actor import Actor
#
# A Tree object
# Spawns fruit to eat
#
class Fruit(Actor):
# Init
def __init__(self, tree):
Actor.__init__(self, "An apple", 0x147514)
self.ignoreBlocking = True
self.lifetime = 0
self.tree = tree
self.edible = True
self.hungerValue = 10
self.canPass = True
#
# Tick
#
... |
f1f16d88fef43dd30acabcd0fc597ad4190b9ba5 | 130a98632d2ab4c171503b79e455b7aa27a1dda4 | /models/official/nlp/modeling/models/electra_pretrainer.py | ccda52009c9c92342350529a1689595ac02ab9ed | [
"Apache-2.0",
"MIT"
] | permissive | aboerzel/German_License_Plate_Recognition | d7fc0314295f5cf0c9d7ae9c93a795e3ef1c5787 | 6fc53292b1d3ce3c0340ce724c2c11c77e663d27 | refs/heads/master | 2023-01-30T18:08:37.339542 | 2023-01-07T07:41:36 | 2023-01-07T07:41:36 | 245,586,430 | 34 | 12 | MIT | 2023-01-07T07:41:37 | 2020-03-07T07:16:51 | Python | UTF-8 | Python | false | false | 12,872 | py | electra_pretrainer.py | # Copyright 2020 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
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applica... |
3eef94f139307c40624e4620ee7dbaa8aa867a6d | 4ea23c1565669386424bd9844ab1de4a26e579d8 | /DataCollection/polymorphism/person.py | 2a4912e729f35058fff4a625e4ce5f0252aac802 | [] | no_license | Jishasudheer/phytoncourse | bf0ce8b137c66921c4a98e6b17a74467773baebd | 9c222a3d0a6dd220f69bb344d27ef97154f55d4f | refs/heads/master | 2023-08-31T15:16:26.048596 | 2021-09-16T02:13:10 | 2021-09-16T02:13:10 | 406,445,394 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 361 | py | person.py | #overloading .....same method name different number of arguments
#overriding....same method name same number of arguments
class Person:
def show(self,num1):
self.num1=num1
print(self.num1)
class Student:
def show(self,num1,num2):
self.num1=num1
self.num2=num2
print(self.... |
26cda68e1ff0e0ff183d301b1356ff8644eb17d2 | b086db4b484bef1f022d382f165fcfc9c9da779f | /views.py | 2e70a203e457c02a03ac3feff7066e67f1d5ccb5 | [] | no_license | tomiplaz/my-coins | 2a72742050404b2f720436308b50cd3047650a49 | 1945b3a86bca0304bce1c61c5ecaeae378d86019 | refs/heads/master | 2021-06-10T11:14:35.663778 | 2021-01-10T19:24:28 | 2021-01-10T19:24:28 | 147,840,812 | 1 | 0 | null | null | null | null | UTF-8 | Python | false | false | 4,333 | py | views.py | from decimal import Decimal
from functools import reduce
from tabulate import tabulate
TWO_PLACES = Decimal('0.01')
RED = '\033[91m'
GREEN = '\033[92m'
ENDC = '\033[0m'
def get_buys_total_value(key, my_data):
_history = my_data.get('history')
return reduce(
lambda x, y: x + y,
[Decimal(trade[k... |
2e139d2283ddf9b64497164ae3b6de720c4f50f0 | 4f2b0c9d4171abc460c9392e116ffe5b682953ac | /pysaurus/video/video_runtime_info_schema.py | 88006d1bb4f5206f2206bc5c9d69fae89213261b | [
"MIT"
] | permissive | notoraptor/pysaurus | d1e48f9dce7a35a5f01fc329f1baefbdfe012c41 | 0b01b6def8f25d39d6c1e1c407c3378b718da8a0 | refs/heads/master | 2023-08-06T13:08:56.412858 | 2023-08-06T04:35:52 | 2023-08-06T04:36:13 | 125,208,748 | 0 | 0 | MIT | 2023-02-16T07:15:14 | 2018-03-14T12:26:13 | JavaScript | UTF-8 | Python | false | false | 413 | py | video_runtime_info_schema.py | from pysaurus.core.json_type import Type
from pysaurus.core.schematizable import Schema
class VideoRuntimeInfoSchema(Schema):
__slots__ = ()
def __init__(self):
super().__init__(
[
Type("size", "s", 0),
Type("mtime", "m", 0.0),
Type("driver_... |
67c4c7456185092dca9e757ab33b423d29be4bff | b766a3df5bc61da27c736b4df0d8350ca73f43e2 | /robot-server/tests/integration/protocols/load_custom_labware.py | b59f93568159a02f4ea892171349ac6f2de23f0c | [
"Apache-2.0",
"LicenseRef-scancode-warranty-disclaimer"
] | permissive | Corey-ONeal/opentrons-app_ws-remote | e771005badf0037f2a295838202072cbfae99ebd | a255b76c8a07457787d575da12b2d5bdb6220a91 | refs/heads/master | 2023-06-17T02:12:37.177932 | 2021-07-07T12:28:20 | 2021-07-07T12:28:20 | 383,791,062 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 302 | py | load_custom_labware.py | metadata = {
'protocolName': 'custom',
'author': 'Opentrons <protocols@opentrons.com>',
'apiLevel': '2.4'
}
def run(ctx):
ctx.load_labware(
load_name='test_1_reservoir_5ul',
location=1,
namespace="custom_beta",
label="custom1",
version=1
)
|
fbf9ea1a06d3c327999f91dadc1e7d9bdc98348b | fed4f3cbc2d736baeb184aa5533c07fc8e5b3308 | /Instructor_v3.0.py | 1c0426e967826fe68d5938401abb9b80bf21bf4c | [] | no_license | willyyooan/INTD210-Raspberry-Pi-thon | eb011f14ee0895c5894ed4d0a605d35325f9e7a3 | 986fcd49da7bbee781e60d3e3e6a6d0fd9bb04c8 | refs/heads/main | 2023-03-28T00:55:02.885991 | 2021-03-30T16:35:50 | 2021-03-30T16:35:50 | 340,246,086 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 14,070 | py | Instructor_v3.0.py | from guizero import App, Text, PushButton, Window
import paho.mqtt.publish as pub
import paho.mqtt.client as mqtt
#pip install paho-mqtt
##VARIABLES##
appW = 750 #width of the window
appH = 500 #height of the window
appBG = (112,112,112) #dark grey
if_text = "If the Bomb is showing a:"
instr = "The difuser needs to d... |
b16de45c33c9377ea66c8eb585f19c134928da77 | 039f2c747a9524daa1e45501ada5fb19bd5dd28f | /ABC012/ABC012d.py | 69b1c6b8563cb62bfcfaf8f48acc866968e4adb1 | [
"Unlicense"
] | permissive | yuto-moriizumi/AtCoder | 86dbb4f98fea627c68b5391bf0cc25bcce556b88 | 21acb489f1594bbb1cdc64fbf8421d876b5b476d | refs/heads/master | 2023-03-25T08:10:31.738457 | 2021-03-23T08:48:01 | 2021-03-23T08:48:01 | 242,283,632 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 626 | py | ABC012d.py | # ABC012d
import sys
input = sys.stdin.readline
sys.setrecursionlimit(10**6)
n, m = map(int, input().split())
d = [[10**8]*n for i in range(n)]
for i in range(n):
d[i][i] = 0 # 自身のところに行くコストは0
def warshall_floyd(d):
#d[i][j]: iからjへの最短距離
for k in range(n):
for i in range(n):
for j in r... |
bd7e099d31d9ef4702070b8131f51ffcda87cec0 | 026ba8593b3b364ec44797e345d25324be53f9cf | /pydantic_cli/tests/test_examples_simple_with_boolean_custom.py | f77dfa91a9fe9b9d81f47526db04c2e5ae878b6e | [
"MIT"
] | permissive | mpkocher/pydantic-cli | e8d21dd094aabb18f39935a2351c0f297f4d163e | d67ab8b265fd9ed045d27ecd904a04b8185481fa | refs/heads/master | 2023-07-10T16:13:15.750640 | 2022-04-06T23:14:34 | 2022-04-06T23:14:34 | 197,854,268 | 109 | 9 | MIT | 2023-06-30T23:53:36 | 2019-07-19T23:22:18 | Python | UTF-8 | Python | false | false | 869 | py | test_examples_simple_with_boolean_custom.py | from pydantic_cli.examples.simple_with_boolean_custom import Options, example_runner
from . import _TestHarness, HarnessConfig
class TestExamples(_TestHarness[Options]):
CONFIG = HarnessConfig(Options, example_runner)
def test_simple_01(self):
self.run_config(
[
"--input_... |
edfe114eb9e7531b15f6d3d75ec34ed777840ee6 | cc5372a89ff146c60b5b6b5080598f988fcdf118 | /flask_redis.py | 7634654d3d5da866d5668e7687776c98405da223 | [
"Apache-2.0"
] | permissive | flash286/flask-redis | 2a69c489a257a4225b162a60583cf598fbbe1f97 | 1e6528597f5f41a0a718106c6ecf1ed20ce7445b | refs/heads/master | 2021-01-22T16:25:05.518663 | 2015-10-21T13:59:57 | 2015-10-21T13:59:57 | 44,668,216 | 0 | 1 | null | 2015-10-21T10:13:34 | 2015-10-21T10:13:34 | null | UTF-8 | Python | false | false | 2,765 | py | flask_redis.py | from rediscluster import RedisCluster
import warnings
try:
import redis
except ImportError:
# We can allow custom provider only usage without redis-py being installed
redis = None
__all__ = ('Redis', 'FlaskRedis')
__version__ = '0.1.0'
class FlaskRedis(object):
def __init__(self, app=None, strict=Fa... |
a04fb5ad8b5abb4bc051d48da48bd10b632204ed | 2ec2cd988224d69a031d145d15475c44144a661e | /admin/forms/popup.py | abc5c98d3ec7426e63b96a420dcdb380ff0d0c60 | [] | no_license | tatyana12/Django- | dfd620ef924c190ba319522fde7548c00e4822c1 | cadc053776e23ecc542be99ae8c755c5a8b0c084 | refs/heads/master | 2020-03-15T15:53:42.688022 | 2018-05-09T01:07:59 | 2018-05-09T01:07:59 | 132,223,075 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 384 | py | popup.py | from django.forms import ModelForm
from real_estate_app.conf.settings import MEDIA_PREFIX
class PopUpModelForm(ModelForm):
class Media:
css = {
'all':[
MEDIA_PREFIX+"css/popup.css",
]
}
js = [
"/admin-media/js/jquery.min.js",
"/admin-media/js/jquery.init.js",
#MEDIA_PREFIX+"js/real_estate... |
361323ec7097cb00811b68a7c428f3a2504e6f67 | cf6a9f323617a0bf31aadeba521e665a67f1a0b7 | /api_urls.py | 6aab503f0362bb8d1b37aaccbf9513d6bb4babd6 | [] | no_license | TipoftheHats/donation-tracker | 938d8064a5b62364e83c9f3e7a2a659867a030ff | fcf3ab5c750161ab2bda21b1d2daecd5d1bd2659 | refs/heads/master | 2021-10-12T05:41:17.380915 | 2021-09-30T18:55:03 | 2021-09-30T18:55:03 | 64,485,602 | 4 | 3 | null | 2021-09-30T18:55:04 | 2016-07-29T14:10:00 | Python | UTF-8 | Python | false | false | 412 | py | api_urls.py | from django.conf.urls import url
from .views import api
app_name = 'tracker'
urlpatterns = [
url(r'^$', api.root, name='root'),
url(r'^search/$', api.search, name='search'),
url(r'^add/$', api.add, name='add'),
url(r'^edit/$', api.edit, name='edit'),
url(r'^delete/$', api.delete, name='delete'),
... |
a514688215ed3a041425627ae301138af4927a2f | 152f8c72bcb315bc0cf40ec389a97898cbc057c3 | /_sadm/listen/webhook/repo/vcs/git.py | cd9d822591026adbf75df70a2bc4c0c713a9c0d6 | [
"BSD-3-Clause"
] | permissive | jrmsdev/pysadm | 0a205cf7b4bf647461d480403051b5f88f82090b | 0d6b3f0c8d870d83ab499c8d9487ec8e3a89fc37 | refs/heads/master | 2022-06-11T07:33:53.847565 | 2019-11-13T04:25:00 | 2019-11-13T04:25:00 | 186,210,706 | 1 | 0 | BSD-3-Clause | 2022-06-03T22:45:36 | 2019-05-12T04:19:14 | Python | UTF-8 | Python | false | false | 557 | py | git.py | # Copyright (c) Jeremías Casteglione <jrmsdev@gmail.com>
# See LICENSE file.
from _sadm import log
from _sadm.utils.vcs import git
from _sadm.utils.vcs import vcs
__all__ = ['GitRepo']
class GitRepo(object):
def hook(self, action, args):
repodir = args.get('repo.path', 'NOREPOPATH')
log.debug("hook action %s r... |
a99adb1f2d2e9dfe408bd137acfa9fbd0c956317 | 9f6a21cd73104c40004d6fbebf6c274c60ef95c5 | /cafir-10/input_data.py | b9461a3171a100be2a84cfecc838ea32398dc9e4 | [
"Unlicense"
] | permissive | zouhongwei/TensorFlow_learn | 7ecb2c20f75f9b63f6ef334780916293a1d8cb47 | 9f46f5bf9cbe6bcc7b3834a5b39c21d395b03fe2 | refs/heads/master | 2021-07-10T17:31:05.424815 | 2017-10-12T13:08:50 | 2017-10-12T13:08:50 | 106,693,613 | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 3,102 | py | input_data.py | import tensorflow as tf
import os
import numpy as np
def read_files(file_dir, is_train = True, batchsize = 16, is_shuffle = True):
'''read the data and return image & label batch
Args:
file_dir: data path, string
is_train: bool, if True, then read train data, otherwise read test data
batchsize: int, ... |
ef2894320224bd9c38a628f785f836f78b861f02 | a97e2b28205e944ee6913add9143c9cc25626fdf | /evolution_02/setup.py | e66b58d94f95a6ab1966b204235d3e534ed5de69 | [
"ISC"
] | permissive | lanzhiwang/httpbin-learn | 380875e70c6bf895a5f8271dba746f0cf9ad89cc | 0296983e56688b449cea831fba027c0f53ca826b | refs/heads/master | 2021-06-29T01:52:54.041507 | 2019-11-29T09:04:39 | 2019-11-29T09:04:39 | 224,763,590 | 1 | 0 | null | 2021-03-20T02:18:48 | 2019-11-29T02:39:50 | Python | UTF-8 | Python | false | false | 1,170 | py | setup.py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import os
import sys
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
if sys.argv[-1] == 'publish':
os.system("python setup.py sdist upload")
sys.exit()
setup(
name='httpbin',
version='111015',
install_... |
9dee761a5b9945d1cbd9fc0a8fde54c792101fb0 | 9a72288cb6b15de88fa868cc9c024912bdafe9f1 | /config.py | 83c5773f55277f5ca3b1125736fa15b8b6c0fffb | [] | no_license | duytk5/Captcha-Recognition-Pytorch | 1f2622b742c5ac9ada67953cb6b01d1f3b846193 | 52f80fed9d4b400af617cad7af9aac24cd1beb67 | refs/heads/master | 2020-04-28T21:37:04.932323 | 2019-08-07T16:01:41 | 2019-08-07T16:01:41 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 2,312 | py | config.py | import torch
class Config:
lr = 0.0001
batch_size = 64
DATA_PATH = "/content/dataset/"
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
cnt_train = 150000
cnt_test = 100
size_image = (10, 50)
# length_seq = 29
length_seq = 55
x, y = size_image
input_di... |
507e76d0f1d27600b1289d9e57a7ac0ed9be9c6c | 931630f559f05e811c7c5cf51e0e2be8eda67bc9 | /bin/merged_demuxer.py | cadbc1116d6e4620d2bbfc358633d4349bbf0a54 | [
"MIT"
] | permissive | lefeverde/Mr_Demuxy | 598dee255841ac8e56c71cc1ab08cb6f9e78b69c | a71f829714c9d18b7b6f2dd3eeea5b3e8b8dcecd | refs/heads/master | 2022-12-09T10:33:14.885259 | 2022-11-14T16:05:34 | 2022-11-14T16:05:34 | 79,943,299 | 7 | 2 | null | null | null | null | UTF-8 | Python | false | false | 198 | py | merged_demuxer.py | #!/usr/bin/python
from mr_demuxy import merged_demuxer_dist
def main():
merged_class = merged_demuxer_dist.MergedDemuxer()
merged_class.main_loop()
if __name__ == '__main__':
main()
|
0349fae078029eddb43ab7de5c73ed6eb7647ac1 | 1dcf2299ef0599a0209b151bee37adeab4d027cd | /euler013.py | ba856073297b63ec65a061b86bd5907e292dbd5a | [] | no_license | sabriozgur/euler-python | be683632e316a8fb30bd88be5da12114f2736e0f | efc53042227464d5706c8061138de3ccf78a9621 | refs/heads/master | 2021-08-17T04:02:39.920891 | 2017-11-20T19:27:29 | 2017-11-20T19:27:29 | null | 0 | 0 | null | null | null | null | UTF-8 | Python | false | false | 5,401 | py | euler013.py | """
Question : 13
Start Time : 10.11.17 01:09
End Time : 10.11.17 01:12
Total Time Spent : 00:03
Complexity : O(n)
Answer : 5537376230
"""
numbers = """37107287533902102798797998220837590246510135740250
46376937677490009712648124896970078050417018260538
74324986... |