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
68b967ecf18d576758cf05e889919944cfc34dcd
6d4e831b99a80755e3f4f2cdd5a84f3669b87f54
/entity.py
003e31b62887a77b8336e2e09ddade5bc427db20
[]
no_license
r-parvulescu/opportunity_chain_simulation
949189bbfd25028a3837d7bbd9da90fa7ff92ff1
145a05e6592dacbb4ed869203b70006f2b144a48
refs/heads/master
2021-01-15T03:49:09.211909
2020-03-18T02:11:56
2020-03-18T02:11:56
242,868,597
0
1
null
2020-09-08T02:00:50
2020-02-24T23:47:23
Python
UTF-8
Python
false
false
3,462
py
entity.py
""" generalised behaviour for actors and vacancies """ from mesa import Agent from random import shuffle import numpy as np class Entity(Agent): """ superclass for vacancy and actor agents not intended to be used on its own, but to inherit its methods to multiple other agents """ def __init__(sel...
46babde9c26a944c9d29121b6bbf89a32f242a81
311f83a8b5820d42100a58bd9c4140a5ba0f00e1
/Epic_painting/Dynamic/sun.py
404aa74ba516ea002adb6f47b810c9f053476d9e
[]
no_license
artemjasan/Epic_drowing
c885ac30bf5038ff13fd110b39316bec2e22db52
b722535469728f9c84bc976bcb0c0a020f0edabd
refs/heads/master
2022-12-11T10:56:25.942523
2020-08-17T07:30:33
2020-08-17T07:30:33
288,107,137
0
0
null
null
null
null
UTF-8
Python
false
false
1,140
py
sun.py
import simple_draw as sd import random # sd.resolution = (1400, 900) # Prepare data for the sun function def sun_prepare(xpoint, ypoint, radius, color, angle): delta_list = [] radius_list = [] for delta in range(0, 360, angle): delta_list.append(delta) radius_list.append(random.randint(ra...
e736991f364ba9ff709348e4b1f612b1e9673281
c545c5c770ea9809a1731b4e3e1edb2e65dc9f09
/app/__init__.py
055c0ee02d6c1111ec7bc572befab21c24c693f4
[]
no_license
arunachalam-07/flask_project
6742905e3282f2832602e1d89e018081cddbf618
1f0ae2997e38a34f448d1e8de27020d65aac6704
refs/heads/master
2021-07-10T22:44:23.862826
2020-02-13T13:55:03
2020-02-13T13:55:03
238,738,287
0
1
null
2021-03-20T02:47:14
2020-02-06T16:54:02
Python
UTF-8
Python
false
false
164
py
__init__.py
from flask import * app=Flask(__name__) from app import views from app import admin_views from app import usr_reg from app import cookie from app import db_connect
07215403750be53994ae36727b6f790202b88697
43197176aa442bef2e7da094dc3ee17a30676a16
/Random_Album_Art_Generator/Random Album art creator.py
a9c82d11223c3331be510c9df36dc53e30e4d986
[]
no_license
kannan-mayoo/python-projects
9eb728adc7ebb12f6dc3b41281e236f34e41a145
f4ed98f66cf9aa36be6c7712a2432be43a072f8d
refs/heads/master
2020-08-01T17:30:58.291073
2019-09-26T10:52:55
2019-09-26T10:52:55
211,061,049
0
0
null
null
null
null
UTF-8
Python
false
false
2,326
py
Random Album art creator.py
# Inspiration: [Fake Album Covers](https://fakealbumcovers.com/) from IPython.display import Image as IPythonImage from PIL import Image from PIL import ImageFont from PIL import ImageDraw import requests from xml.etree import ElementTree as ET def display_cover(top,bottom ): name='album_art_raw.png' alb...
18d3f58048b7e5d792eb2494ecc62bb158ac7407
b520f5ea9a27377347d2916198b29b25fca5e64f
/app.py
a9cd02ce1ecd4a43d2eaa0ed5e6e021013d4cb59
[]
no_license
dashdanw/rpi-home-control
d45af1ed08385fafc73c59571733d1cb54642d5b
5d4a93a39f152bdf2f7363f9d19231bc75827a7d
refs/heads/master
2020-04-01T22:29:13.838698
2018-10-20T20:53:23
2018-10-20T20:53:23
153,711,080
0
0
null
null
null
null
UTF-8
Python
false
false
706
py
app.py
from flask import Flask from flask import render_template from flask import make_response import json from lib import powerswitch app = Flask(__name__) @app.route('/') def hello_world(): return render_template('index.html') @app.route('/on/') def on(): state = powerswitch.on() return json.dumps(state) ...
869284fa531a93c1b9812ed90a560d0bb2f87e97
f6cd31033cee39c6451f5c72da92e8f9b08ccb03
/ML-youtube/Video2.py
5d2f9d5e3f258fb729cfee64e755718168e7b7ec
[]
no_license
mickaelthebox/cathy-machine-learning
acb44956c3bb036d632c98855f494844aaae6820
909c9ffc633be2f2004e0f9dbe7727a8887184a8
refs/heads/master
2023-03-25T21:13:12.651637
2021-03-23T08:49:16
2021-03-23T08:49:16
281,100,895
0
0
null
2021-03-23T08:49:17
2020-07-20T11:43:30
Python
UTF-8
Python
false
false
383
py
Video2.py
# fonction pour voir quel est le plus grand entre l'energie limite et l'enerve potentiel def ep (m,h,el,g=9.8): E=m*h*g if E<el: print ("le plus grand est : el") else: print ("le plus grand est : E") ep(3,4,5) #fontion fibonaci 0 1 1 2 3 5 8 13 def fibonaci(n): for i in range(0,n,): ...
d126efa91b964a3a374d546bb860b39ae26dfa22
f78648f6dc653abc63f4f98006e39f92e3468a63
/examples/py/test.py
5c0af297f8007f9dd4eb39395b4af523cc99e7a6
[]
no_license
AngusK/codelab_bazel
9e6f5482ef02a753356ce8884e266efa4e350a2d
9ed72191ae52731bd22546cedd5cb70383dda326
refs/heads/master
2023-04-07T19:30:18.061805
2023-03-17T02:27:23
2023-03-17T02:27:23
212,827,420
2
0
null
2023-03-17T02:27:24
2019-10-04T13:58:45
Starlark
UTF-8
Python
false
false
396
py
test.py
"""A tiny example binary for the native Python rules of Bazel.""" import unittest from bazel_tutorial.examples.py.lib import GetNumber from bazel_tutorial.examples.py.fibonacci.fib import Fib class TestGetNumber(unittest.TestCase): def test_ok(self): self.assertEqual(GetNumber(), 42) def test_fib(self): ...
e582787a912f479830ed99575b2c6adb8088b4e5
f9cc6226f1a20572099d1c7b77565ff3ec816a22
/searchEngine/server.py
d26f1bb60f0c2badd0e7081f10221c3bff1eb10d
[]
no_license
ranikamadurawe/IRProject-Sinhala-Song-Browser
e9e253eb66b2d8d3c0969a81fb4c23a3e42b9f68
3551bbda36ef92fc497ec7c688105f42af174be3
refs/heads/master
2023-03-27T08:56:32.121895
2020-07-03T11:20:06
2020-07-03T11:20:06
266,347,455
0
2
null
2021-04-01T03:34:11
2020-05-23T13:58:31
Python
UTF-8
Python
false
false
796
py
server.py
from flask import Flask, request from flask import jsonify from preprocessing import QueryProcessor from flask_cors import CORS app = Flask(__name__) CORS(app) qp = QueryProcessor() @app.route('/search_general', methods=['POST']) def query(): message = None searchQuery = request.json['searchQuery'] resul...
cf0cf028d5f67e8deca8ebd3ad76d9c1e3563002
dff9b4cc506980bda50e685b3c2a69d08d52f59d
/generate_extract_table
abc9fa41d3ddac80981710a8cabea7a92867585e
[]
no_license
ozancaglayan/smt
900cc38c46ae9c102f9dfa7b389168c0b3bdf64b
19957a8581e416c889535acd1d80bb17259d8a65
refs/heads/master
2021-01-01T15:17:14.915359
2015-07-10T15:38:28
2015-07-10T15:38:28
36,491,995
0
1
null
2015-11-04T11:52:07
2015-05-29T08:40:33
Python
UTF-8
Python
false
false
1,237
generate_extract_table
#!/usr/bin/python2 import sys import argparse """ This program generates an extract table having the following format: <S1> <S2> <S3> ... <Sn> ||| <T1> <T2> <T3> ... <Tk> ||| 0-0 Each line is a mapping from a source sentence to target sentence with special delimiter characters. You can give the output of this s...
f8bf7e2d8f06bbd00f04047153833c07bf483fd3
026a76a42e1f70a4ac68ff431ec2c04f8a6f4283
/PyRPG/apps.py
edd59959b77d15a47e0e61d9fd033120d221a016
[]
no_license
Nikopaul31/TutoDjango
e43d85bea164da0d902a79364fe21a55b03d5ad7
b7659e3ae77ed721213004f7b5ae1616befb3f27
refs/heads/master
2021-05-23T01:17:30.460172
2020-04-05T06:17:05
2020-04-05T06:17:05
253,168,877
0
0
null
null
null
null
UTF-8
Python
false
false
85
py
apps.py
from django.apps import AppConfig class PyrpgConfig(AppConfig): name = 'PyRPG'
2ad28dc49155ef9817c78c061235c29aaf9f40db
d004f08b9fbeade1d18635e0309cebefddc3d1fd
/tests/ncl_test.py
5066d5fd1e510be3569e4caf66052a4a89e4950d
[ "BSD-2-Clause", "MIT" ]
permissive
cgat-developers/cgat-apps
873d1290b86edde34a24ee8a7dc0c9b91d72bd7b
1ec3733ca0b9bb6ee2931201fc0c329b9e079564
refs/heads/master
2023-05-28T02:41:21.827292
2022-03-17T14:22:49
2022-03-17T14:22:49
120,880,809
31
15
NOASSERTION
2022-03-17T14:22:50
2018-02-09T08:46:41
Python
UTF-8
Python
false
false
3,615
py
ncl_test.py
"""test high-level interface.""" import unittest import random import tempfile import shutil import os from cgat.NCL import * class TestNCLSimpleNegativeIntervals(unittest.TestCase): def setUp(self): self.mIndex = NCLSimple def testBuild1(self): index = self.mIndex() self.assertRais...
ab5bd5cbb42c41140e60e9d284b044ae79ac6894
b4ea78b8b33e2dee808290e8f87038108b12cf7b
/Python-learning/类和迭代器/类和迭代器.py
bfcf4452f6ffc30f5a8ea1d041fd7b24a9ce29ee
[]
no_license
liang2713020/Learning
d275ddfb8032d49f42143dc71bfd52fdeacb8932
fbfdc12ce2877af4be020082885519334523c8ab
refs/heads/master
2021-01-22T19:55:06.788211
2015-07-26T13:54:19
2015-07-26T13:54:19
null
0
0
null
null
null
null
UTF-8
Python
false
false
1,248
py
类和迭代器.py
#------------------------------------------------------------------------------- # Name: 迭代器和类 # Purpose: # # Author: Administrator # # Created: 19/02/2014 # Copyright: (c) Administrator 2014 # Licence: <your licence> #----------------------------------------------------------------------...
6d8cbf56389a2e87c6aabd9c99591c6651487ea0
afd9d503e20957fd57b42880923c7aa1898163cb
/病案系统升级/病案系统升级.py
859b908422c76169315a3f97f3b797d01236f81a
[]
no_license
jabzer/pyCode
80bf9a4b31fe9d680ec0bb7f0713a90fb948ed80
70f52219a4e40c2f3064d1f450223cab9a341eb3
refs/heads/master
2021-04-12T04:28:38.234494
2018-07-11T09:37:49
2018-07-11T09:37:49
125,951,365
0
0
null
null
null
null
UTF-8
Python
false
false
2,381
py
病案系统升级.py
# -*- coding: utf-8 -*- # 先拷贝配置文件,版本号不对就通过FTP下载新文件夹,版本号对就直接启动程序 import os, ftplib, configparser, shutil f = ftplib.FTP('10.11.0.10') f.login() def ftpconnect(host='10.11.0.10'): f = ftplib.FTP(host) f.login() print('{0} connect success'.format(host)) return f def downLoadFile(ftp,loaclpath,remotepat...
645547c4134b661d191125fde5b599edcdc3d029
36c34a4430d1c867faa96cd959418c5bbaf9159c
/main.py
740e5c2dbf50c2b182fa270febe912ec6e4c861d
[]
no_license
HtmlSeniorDev/TestAlfa
77400d54ea5954da1f3965f859fea8aaeaba1464
a0c3dd0b82ddf3ca818acef9ebf129f2410104cb
refs/heads/master
2022-04-25T13:47:20.345117
2020-04-30T14:57:41
2020-04-30T14:57:41
null
0
0
null
null
null
null
UTF-8
Python
false
false
6,642
py
main.py
import datetime import csv from Models.LocalData import LocalData from Logic.CalculateBonuses import Bonus_1, Bonus_2, Bonus_3, Bonus_4 from tabulate import tabulate EMPLOYEES_LIST = [] class EmployeesPr: contract = None max_bonus_two = 100000 # максимальный бонус по 2 коду бонуса """сумма по 1,2,3,4""" ...
9c565fc4739755a917480b0ed09231041472284c
1442b1785a71794801b2e09febc5ce220a4562f1
/HT_8/domains/main.py
cdabab819dc1086f42e499debd28e4111b65f45a
[]
no_license
yarik335/GeekPy
64acfc91502601d02525be9fb03ba527a15e3450
e8806d56f2a458c4548113170191bc3b017754d3
refs/heads/master
2021-05-15T19:27:07.822718
2018-01-24T13:55:01
2018-01-24T13:55:01
107,698,688
0
0
null
null
null
null
UTF-8
Python
false
false
4,433
py
main.py
""" Це все записати в: JSON, XLS, TXT, CSV файли (для самих крутих в sqlite) Також повинен бути механізм отримання інформації лише про одного або список вказаних авторів по айдішнику автора(придумайте як це зробити) Використовувати requests+bs4 Домашка рахується зарахованою якщо ви даєте посилання на репозиторій де є ...
43a93028aa6a8fb5f7d025c7d2f1491df19da6c7
879e930f576576448bfcea39e55fb46bd48ce270
/melody_util/test_util.py
b3793b8ee78f16ae6c0ccde1fcc12f209f9616a4
[]
no_license
leixiaolin/smartMusic_v2
e1387b5b0b2b4d1f5a29cb350b6f52e4b96ff182
463b908f2f1a761628be99eae6e80a0c5221a65b
refs/heads/master
2021-10-07T17:35:52.353380
2021-09-29T02:46:52
2021-09-29T02:46:52
170,714,545
3
1
null
null
null
null
UTF-8
Python
false
false
6,941
py
test_util.py
import numpy as np test_codes = np.array(['[1000,1000;2000;1000,500,500;2000]', '[2000;1000,1000;500,500,1000;2000]', '[1000,1000;500,500,1000;1000,1000;2000]', '[1000,--(1000);1000,--(1000);500,250,250,1000;--(1000),1000]', '[...
2934f74a882435d78dbb7dbcd2f2e3735077334c
75a1ae7f93ec8a19e8b5e532f108b77fbe7fb99a
/src/DeepGenerativeModels/NeuralODE/adjoint_ode.py
896624867d669e36579876741297b1a07911eb65
[]
no_license
shulgin-egor/DeepGenerativeModels
202b5429cbe7f3906b82c4ee22b82742456ecb62
ffdc0993452de27812d890d5820f4465f8b918d0
refs/heads/master
2020-09-27T10:55:53.358574
2019-10-15T09:53:33
2019-10-15T09:53:33
null
0
0
null
null
null
null
UTF-8
Python
false
false
1,888
py
adjoint_ode.py
import torch from torch import nn def zip_map(zipped, update_op): return [update_op(*elems) for elems in zipped] def euler_update(h_list, dh_list, dt): return zip_map(zip(h_list, dh_list), lambda h, dh: h + dt * dh) def euler_step(func, dt, state): return euler_update(state, func(state), dt) class ...
178a37495f5d9137a152aaf448e4d58ffe20d81c
dcae3db884ee0c5217468a14111d8d8943786492
/src/story/story_service.py
89841143a1dc1f7646c2c2aeacb8810394e74fcc
[]
no_license
rdbatch02/short-messaging-story
c7f81e0e9ff9cb7a41cf501ddfb0febae9cc48e3
e7def89c9ae6d79e8396bb5dc373cf85fefac258
refs/heads/master
2020-03-26T17:32:33.101536
2018-09-17T23:55:47
2018-09-17T23:55:47
145,167,019
1
0
null
null
null
null
UTF-8
Python
false
false
1,480
py
story_service.py
from typing import Optional, List from src.story.domain.user import User from src.story.domain.stage import Stage from src.story.domain.schedule_record import ScheduleRecord from src.story.db.story_client import StoryClient class StoryService: client = StoryClient() def get_pending_starts(self) -> List[User...
ea6ed7b4531448884793e77f5b60bf99da1a35f3
096017db9ecf688ea56e577628579ea73969808f
/tests/test_flow/test_logging.py
c3d81dc2531cf046ce0f6c36b754b8d6a0804ea3
[ "Apache-2.0" ]
permissive
square/bionic
eb44d9d8b0c80b68c607c0f9327b39988b47ed4d
3b88338923bd84df2c48cb6bd3d282c6283305b9
refs/heads/master
2023-06-15T10:07:52.399855
2022-11-16T05:16:45
2022-11-16T05:16:45
204,986,901
107
24
Apache-2.0
2023-03-18T23:11:51
2019-08-28T17:29:02
Python
UTF-8
Python
false
false
3,479
py
test_logging.py
import logging import threading import pytest @pytest.mark.allows_parallel def test_logging_details(builder, log_checker, parallel_execution_enabled): """ Test the details of the log messages we emit. Since these messages are currently the best way to get visibility into what Bionic is doing, we have muc...
0fb8a2522816ffb2c6c4933df96de36ee0ee1b61
38941ac80bb2473baa8558d870daa53459688f35
/views/facets/journeys.py
d88506181356f98b987bc8f5374e0e6eee0bdcf0
[]
no_license
waxiao1214/flask
15ce2a710322e4b288c444bef9e365492fdbb626
f2f8aa551a9236ed9c64bc27d62741b363c043a8
refs/heads/master
2022-04-06T00:28:58.500293
2020-02-05T17:47:34
2020-02-05T17:47:34
null
0
0
null
null
null
null
UTF-8
Python
false
false
17,911
py
journeys.py
from bson import ObjectId from datetime import datetime from solariat_bottle.views.facets import * from solariat_bottle.db.journeys.customer_journey import CustomerJourney, STRATEGY_PLATFORM, STAGE_INDEX_SEPARATOR from solariat_bottle.db.journeys.customer_journey import STRATEGY_DEFAULT, JourneyType, STRATEGY_EVENT_TYP...
e312e5c0e01645cf1084d0947e23f914d49aece0
915f9d3e4030a8212996d81a2cf6a7711237633e
/ny_blog_flask/config.py
ab0d3d257bf0062b0b94edbf28cdebae6275ac47
[]
no_license
ilyaignatyev/python-web-otus-ru
bb03df1094539180a5e96d12809bfea6796c09be
3de0f8eeb4dbf9ec37b17ece0dde51c9e0f381ac
refs/heads/master
2022-12-23T00:05:53.906347
2020-04-23T22:22:53
2020-04-23T22:22:53
226,662,788
0
0
null
2022-12-08T04:01:42
2019-12-08T12:18:18
Python
UTF-8
Python
false
false
518
py
config.py
""" Конфигурация """ CSRF_ENABLED = True SECRET_KEY = 'sdjfgkjdfhgdfgdsfjhgeruiytiuerwyt324658973645' # Длина "Соли" для хешрования паролей PASSWORD_SALT_LENGTH = 100 SQLALCHEMY_DATABASE_URI = 'sqlite:///blog.sqlite' SQLALCHEMY_TRACK_MODIFICATIONS = False UPLOADS_FOLDER = 'uploads' ALLOWED_IMAGE_EXTENSIONS = {'...
66761305041fad8ac00f7fc734e5982c937ddf9b
f68fc42a129296d7d7e5a6e5fb0d57799192253c
/backend/app/crud/crud_job.py
3921714de12bff034195e99bd0fc8e10799160f1
[]
no_license
minhdang241/cloud-project-2021
dc0378017e320549fbd34fc4ea71f4c2f78f1398
64f5ddb468362122fd8f5d1592288d40abaee110
refs/heads/main
2023-08-11T10:34:03.832479
2021-09-19T10:20:48
2021-09-19T10:20:48
391,366,179
0
0
null
null
null
null
UTF-8
Python
false
false
1,402
py
crud_job.py
from pydantic import BaseModel # pylint: disable=no-name-in-module from sqlalchemy.orm import Session, joinedload from sqlalchemy import func, distinct from app.db.postgres import models from .crud_base import CRUDBase class JobCreate(BaseModel): title: str company_name: str company_location: str sh...
ef55a27501d0a802ecb05c94fc5930d3d377ab29
a8a590a9bb413a8ddfa2b9a0f9fc624e982b763e
/junit-xml-demo.py
f7ac4395c0b9fedd268a0a68893844db3bd40024
[ "MIT" ]
permissive
lehoang318/junit-xml-demo
f664c44afba0384299f6ae33bc0ab09509f90fc0
adee9476848396dcb29e47b2b549af345266cb52
refs/heads/main
2023-01-13T01:08:37.621338
2020-11-15T13:40:41
2020-11-15T13:40:41
313,039,315
0
0
null
null
null
null
UTF-8
Python
false
false
1,718
py
junit-xml-demo.py
import sys def isPython2(): version = sys.version return version.startswith('2.') import junit_xml class Testcase (junit_xml.TestCase): Count = 0 def __init__(self, description): self.tcId = Testcase.Count Testcase.Count += 1 self.description = description ...
4aa989aed3922a31dc1b5c99c05bf5b94e43febf
063a5c98d12e69036c0013fee375bf3b7516eff4
/fdist/exchange/file_loader.py
c1cdfdcd58390193a92b68e68909fd42af459925
[]
no_license
mikemey/fdist
2dc476f8cb7f1c96d834d323eb74dd8f9ad67c48
3df21349008dcde05cdd551ac928cac82af88bd1
refs/heads/master
2020-05-21T04:47:18.997993
2017-04-12T13:37:40
2017-04-12T13:37:40
51,709,952
0
0
null
null
null
null
UTF-8
Python
false
false
6,475
py
file_loader.py
import logging import os import shutil import socket import traceback from time import sleep from fdist.exchange import read_data_from, send_data_to from fdist.exchange.file_store import FileStore from fdist.globals import SHARE_DIR, md5_hash, hashed_file_path from fdist.log_actor import LogActor from fdist.messages i...
5bd6fbd8d0222fc94070ef79ea189673303b16f7
c7043c0c9f90bfb3c802e2b4fe0d9fa90f9f2749
/test/embedder-test.py
f90a4f1cf6d0f84e969ed344264b8cd5a9443ed1
[]
no_license
sudeeprp/GitaReader
61dd99458bc14c2b50bdb703a68548cf65b84e87
4e7d958d109fbe97b2fd7d9d95d97fa15fa6d768
refs/heads/master
2021-07-05T04:11:54.154929
2021-04-13T16:52:18
2021-04-13T16:52:18
229,794,627
0
0
null
null
null
null
UTF-8
Python
false
false
1,782
py
embedder-test.py
import unittest import embedder class DelimiterTest(unittest.TestCase): def test_normal_is_delimited(self): normal_para = { "id": "*", "chapter": "Chapter 2", "shloka": "2-16", "content": [{ "type": "extref", "destination": "[vishNu purANa], ...
69b5cec3b8b475ae87017ba012e067b6ad945d14
3cd73fee918daa691ea1658ec28615f7e525e85c
/VE581/HW2/Traffic_CNN.py
4d0ba642dc6adf1df8f824dcb2565b6ed2463692
[ "MIT" ]
permissive
cangyu/LambdaFlow
4d093ca9cc9f51354673aa69e21a882480038136
407a952bdf98f6ca161291fe50c5c903c72efb28
refs/heads/master
2020-03-18T06:10:05.071247
2019-07-23T13:41:23
2019-07-23T13:41:23
134,379,390
1
1
null
null
null
null
UTF-8
Python
false
false
9,178
py
Traffic_CNN.py
import pickle from matplotlib import pyplot as plt import numpy as np from random import randint import os import tensorflow as tf from PIL import Image from sklearn.metrics import confusion_matrix import skimage """Load dataset""" training_file = 'data/train.p' validation_file = 'data/valid.p' testing_file = 'data/t...
ba9fea987ad2a6ca5d8acc266e471e6813239fdf
cfc910e79352ccb40c9221f7f0ee09fe51956513
/apps/courses/adminx.py
8dc979e2c5cc96e66651ae69728383609ad5a4f9
[]
no_license
hzj7510/whaleOnline
eddcdfafef759b5d3bc38921e3f6d657fc11d869
9f282aacb27ff7d196cce7f2e8e507f2077a241c
refs/heads/master
2021-01-22T03:30:26.929959
2017-06-01T03:11:30
2017-06-01T03:11:30
92,382,650
0
0
null
null
null
null
UTF-8
Python
false
false
1,995
py
adminx.py
# _*_ coding: utf-8 _*_ import xadmin from .models import Course, CourseSource, Lesson, Video, BannerCourse class LessonInline(object): model = Lesson extre = 0 class CourseSourceInline(object): model = CourseSource extre = 0 class CourseAdmin(object): list_display = ['name', 'desc', 'detail'...
a2c7e6b124bdfbc2573b148c75bbe7c10487885f
07564c75c1f37f2e0304720d1c01f23a27ef3469
/190.ReverseBits/solution.py
3714451fe33f48fdbc790604ba2cd5a385a7ae32
[]
no_license
ynXiang/LeetCode
5e468db560be7f171d7cb24bcd489aa81471349c
763372587b9ca3f8be4c843427e4760c3e472d6b
refs/heads/master
2020-05-21T18:27:16.941981
2018-01-09T22:17:42
2018-01-09T22:17:42
84,642,017
0
0
null
null
null
null
UTF-8
Python
false
false
446
py
solution.py
#https://discuss.leetcode.com/topic/10069/python-ac-with-63ms-3lines #https://discuss.leetcode.com/topic/9811/o-1-bit-operation-c-solution-8ms/2 class Solution: # @param n, an integer # @return an integer def reverseBits(self, n): ans = 0 for i in range(32): if n != 0: ...
dd462976bd30f1e6236b00380c8845cef9fb5552
54b09cdc12a11ccc2a87bf14aa0e7493034134b4
/server/api/views.py
9e09b830b1abb5a6c81fe4b68d3e0424ace7a79e
[]
no_license
rennancockles/decorado
7cf3d50004b41a77a844501d459e8c27bb7d79b7
a165e2d9033bd66c95f7b7784aea9eef01176161
refs/heads/master
2021-04-26T23:20:07.839687
2018-03-07T02:35:35
2018-03-07T02:35:35
123,975,035
0
0
null
null
null
null
UTF-8
Python
false
false
1,534
py
views.py
# -*- coding: utf-8 -*- from __future__ import unicode_literals from rest_framework import status from rest_framework.decorators import api_view from rest_framework.response import Response from rest_framework.generics import ListAPIView from django.contrib.auth.models import User from django.contrib.auth import auth...
b948ce6e55f90004daa742256c47c3c75a51d5d3
9e0009d67e5fcfbe7898e1f127db38cff008d7b8
/vhpidirect/shared/py/vunit/run.py
e7ef9c7026481e86847d7d7232ad4fb420aad339
[ "Apache-2.0", "CC-BY-4.0", "LicenseRef-scancode-unknown-license-reference" ]
permissive
ghdl/ghdl-cosim
4c47c3ab2a853cd63fd8d29f4dd8ef97f1c2bff5
623f17f59aa2d33fb453fbbe9680ac00f88511f8
refs/heads/master
2023-09-03T10:44:21.770869
2023-02-26T21:00:19
2023-02-26T21:00:33
255,051,526
40
10
Apache-2.0
2023-08-17T08:53:22
2020-04-12T09:44:25
C
UTF-8
Python
false
false
1,072
py
run.py
from vunit import VUnit from os import makedirs, getenv from pathlib import Path from shutil import copyfile import re def post_func(results): """ Copy args.json to vunit/cosim/*.json """ report = results.get_report() cosim_args_dir = Path(report.output_path) / "cosim" try: makedirs(st...
44093efeb7d15a7873a76aa4eaa07439b91679fa
b8c3ec3c0f5aa911b7f0544232414c17c4ad9a9d
/datausage/Data.py
d22c36ab9d445afe4f3e9e679ea601d1676f7faf
[]
no_license
FWRobins/PNA
e495e54b288574bce25c6243df76acefcd86d5d1
de6e06cc952e8b6c63ddc482fee72a0d4b663ddc
refs/heads/master
2023-03-25T06:07:12.368512
2021-03-19T07:52:10
2021-03-19T07:52:10
343,689,230
0
0
null
null
null
null
UTF-8
Python
false
false
1,648
py
Data.py
##when we used limited data, this was a test to see if more data will be needed before the month ends import pandas as pd import wget import datetime from datetime import date, timedelta from easygui import * import pyautogui import csv import os ##get amount topped up topup = pyautogui.prompt(text='Was there a topup...
00bf743939bafdc12295c595f52f5db974476959
33b60c16821174f741c89016a85dcd0041c475b9
/rooms/helpers.py
2fb0bcb6ddd0389709ddef73e6274de0ebeb1c63
[]
no_license
MAXWELLKANE/video-games-betting-app
67cb470297ef512e287b5c4b450dc975ca268397
c11c32790f30c10aadb50661dcaf5c67d4a8e04b
refs/heads/master
2023-05-31T00:23:13.187794
2019-09-17T00:08:35
2019-09-17T00:08:35
null
0
0
null
null
null
null
UTF-8
Python
false
false
3,976
py
helpers.py
from .models import Room, Game, Message from django.contrib.auth.models import User from datetime import datetime as dt def get_context(**kwargs): ''' Returns all rooms and game objects. Additional parameters can be passed (to be used for html templates). ''' objects = dict() if 'games' not...
0707770398a3e8735a7343a71ba646a06c3dc22e
f8c08409f235ed12a5da50b871755fcd73cbbcc4
/code/train_lm.py
00b106aa906cc8c426466ef85dad7fbc4fba1c8e
[]
no_license
jjc2718/deep-correlation
e7cfe4bfffec84db066ba87fe22d2921723feafb
16c5f3abf9f7e371b3cee49937cf69acfc357110
refs/heads/master
2021-09-06T07:52:25.606105
2018-02-03T21:08:02
2018-02-03T21:08:02
111,951,652
0
0
null
null
null
null
UTF-8
Python
false
false
2,868
py
train_lm.py
from __future__ import print_function, division import os import numpy as np import config as cfg import features.featurization as feat def process_args(): import argparse parser = argparse.ArgumentParser() parser.add_argument('-i', '--images_dir', default=cfg.images_dir) parse...
9af165138c363403620b043dbce70196d7b86fd2
585894397c5f6bba468c0d832277269abc900148
/week-21-activities/07-Models/07-Models-Solved/Solved/django/users/views.py
74bdcd2964888543c521f62fc217fa03024c1d0a
[]
no_license
philipstubbs13/activities-for-practice
07cc4d108fd8ead009c69753e8328926f67c6afc
05007aa87296a3e39a70f45007618869f946cd73
refs/heads/master
2022-11-22T06:03:57.587225
2018-06-10T21:34:39
2018-06-10T21:34:39
115,562,233
0
1
null
2022-11-03T14:16:13
2017-12-27T22:25:27
Python
UTF-8
Python
false
false
683
py
views.py
from django.shortcuts import render from django.shortcuts import get_object_or_404, render from django.http import Http404, HttpResponse from django.http import HttpResponse from .models import User def index(request): context = { 'name' : 'Adonis', 'users' : User.objects.all() } return render(request, 'use...
a35a982cd1f5fda0474ef93b73057ebba9989815
8b8dcb50d167aea78c346b4d22ad8bff06b6904b
/dopzaniatie.py
d1811dbb96677157fb89e60b3c2f59f59245dfed
[]
no_license
Asylbek1337/dopolnitelnoezadanie
22ee414994ee44de0b2fecd3fbaaafb126c5618f
edc350d5ac775855a73078e34eba86d69dbbd708
refs/heads/main
2023-01-15T02:19:08.244126
2020-11-23T14:16:43
2020-11-23T14:16:43
312,299,735
1
0
null
null
null
null
UTF-8
Python
false
false
1,664
py
dopzaniatie.py
#Задание 1:Задаем функцию сортировки выбором. def selection_sort(lst): #Задание 2: Внутри функции создаем цикл for, проходящий через элементы последовательности. for num in range(len(lst)): #Задание 3: Внутри цикла создаем переменную min_value и присвоим текущее значение индекса последовательности. ...
b04a780ab5dcb92fa334a7eee07067f1c0f2eb7d
8783c342b283e9b065e46af95c75fb08cdc8ab54
/http_control.py
6d85e93b63273292967ea9a00aac6b33aefc7b30
[ "MIT" ]
permissive
Chen-Ze/python-visa-server
7e2c172777a658847c7c66bc2bd4ce4b9de032a0
7b8fe27a09a24bc520901798772a1e771a48342b
refs/heads/master
2023-08-11T20:34:37.322989
2021-09-27T06:54:14
2021-09-27T06:54:14
398,513,155
0
2
null
null
null
null
UTF-8
Python
false
false
2,312
py
http_control.py
from http.server import BaseHTTPRequestHandler, HTTPServer from urllib.parse import urlparse, parse_qs, parse_qsl import logging import coloredlogs import deprecation import os import sys file_dir = os.path.dirname(__file__) sys.path.append(file_dir) src_dir = os.path.join(file_dir, "src") sys.path.append(src_dir) ...
b3a6dc9e79d17d39e5660674cafb7ba68f9717ac
fd2a90a83cfc8a749da9437315f496cdca5e35b4
/26-variable-scope/quiz.py
fe20618b6250b574aee9311ae64ea3a7602361be
[]
no_license
ynonp/gitlab-demos
d473fbb50ec629e62aa5b2c2713d02826e99d2f6
4bc508ccfe0b4705e36cee7368ae78f646d95764
refs/heads/master
2020-03-19T11:14:19.391727
2018-06-07T07:41:13
2018-06-07T07:41:13
136,441,571
0
0
null
null
null
null
UTF-8
Python
false
false
113
py
quiz.py
def main(): funcs = [] for i in range(4): funcs.append(lambda: print(i)) funcs[0]() main()
822a09f8db1e379d605efc05a30c13c9d0849f8d
a5b033f678c3e561023a5ed572779725482507c2
/week1/bitwise-manipulation/binary_gap.py
6d7c6c9f4f532b20006e8206ec881c15255b4fc7
[]
no_license
elaneyc/wallbreakers
f6efdd48fce1237f000e669715e06664e83fd7e1
bd07d64aaddf654ccca158eae6ce7a03e0fe4265
refs/heads/master
2020-06-08T00:48:35.900327
2019-07-22T19:26:03
2019-07-22T19:26:03
193,125,926
0
0
null
null
null
null
UTF-8
Python
false
false
631
py
binary_gap.py
class Solution(object): def binaryGap(self, N): """ :type N: int :rtype: int """ max_dist = 0 counter = 0 seen_one = False binary = bin(N) for i in range(len(binary)): if ((binary[i] == '1') and (not seen_one)): see...
ca81d5e736f23fa0614270342180aeff4b302b45
28acd54c032f1179b5bd777c36cda9aa0ce57f01
/c10ktools/management/commands/runserver.py
377b0924f8fae0526097286684cc22bcbf60c7a3
[]
no_license
azizur77/django-c10k-demo
6830748532ee5b659835bd13e58e67df8a05a8ec
92f41c6db0dbd7b1c7142ac63f128cf25c60d5ae
refs/heads/master
2020-12-31T04:16:51.273942
2013-11-14T16:54:42
2013-11-14T16:54:42
null
0
0
null
null
null
null
UTF-8
Python
false
false
1,004
py
runserver.py
import tulip import tulip.http def run(addr, port, wsgi_handler, loop=None, stop=None, **options): """ Alternate version of django.core.servers.basehttp.run running on Tulip. """ if loop is None: loop = tulip.new_event_loop() tulip.set_event_loop(loop) # The code that reads environ...
000bbd6a54982c99b7e705534baf0329838b5352
c24ed28fc3d39ad7f47c067b7369b75104debcd6
/config.py
b199ee8405fcd92cbebb890f13dce5d9e94be9b2
[]
no_license
jiangyy5318/tfpack-votenet
6d89cbcc0050d8182fef01154deeb76ac0531385
cb040a1d88414f1ca4f6d20ddc5d38d762e09bfb
refs/heads/master
2020-06-26T09:55:41.073397
2019-09-20T14:01:32
2019-09-20T14:01:32
199,601,870
0
0
null
null
null
null
UTF-8
Python
false
false
130
py
config.py
POINT_NUM = 20480 NH = 12 NS = NC = 10 POSITIVE_THRES = 0.3 NEGATIVE_THRES = 0.6 PROPOSAL_NUM = 1000 BATCH_SIZE = 8 POINT_DIM = 4
2ff006db9bc18b1454505e4010c41069a83de89b
8a93f530e7bfd201f8f0426f58560dc67546221c
/simulation/master_thesis/alpha_diversity.py
231d679b4e222b7e80ad4d8d4ccc9c34d58147e4
[]
no_license
nwatarai/work
6e46d8803d2ae7f6f3932695b7a0d9eeb1b9f056
fd4a940dae900ebd62d61103830d23ebd959429d
refs/heads/master
2021-01-22T22:24:12.499702
2017-08-23T06:09:13
2017-08-23T06:09:13
85,539,067
0
0
null
null
null
null
UTF-8
Python
false
false
473
py
alpha_diversity.py
import sys import pandas as pd import numpy as np from numpy import inf from matplotlib import pyplot as plt a = pd.read_csv(sys.argv[1], delimiter=",", header=0, index_col=0) a = a.transpose() ra = a / np.sum(a,axis=0) m = np.transpose(ra.values) def shannon(array): log = np.log(array) log[log == -inf] = 0 values...
8cf87f200ed503751fc93f7537708d4685e2f56a
5568aff0a26768458a31e27bd046e44a39063edf
/demo/oan.py
7cbe8739b6bcde468d2a885e9e281e32a1c2bf78
[]
no_license
Cuistiano/Benchmark
85bad141ae6779fbcaf1a60fe3cb2cea83f9958f
85ca410e3615574aed6527a857bf0a4e69ac1750
refs/heads/master
2022-09-27T18:36:05.915247
2020-06-08T03:40:13
2020-06-08T03:40:13
null
0
0
null
null
null
null
UTF-8
Python
false
false
16,478
py
oan.py
import torch import torch.nn as nn import numpy as np from util import batch_episym class AttentiveContextNorm(nn.Module): def __init__(self, channels, local_or_global=True, head=1): nn.Module.__init__(self) self.att = nn.Conv2d(channels, head, kernel_size=1) self.local_or_global = local_or...
0e1b3291fa1c439215d8cb62deabb6dc48309655
d0b2bfd3c3c5999667576141c5b7c28af837fc3d
/cyg_apu/code/account.py
900abdb74f9ecd616d2419660d5fd57afb34208e
[]
no_license
edisonguachamin/cyg
c34a55875e8be5824e9fa5e0e58f1216144154a3
2a400b6c3d33602684d9478f999253e696c8534b
refs/heads/master
2021-01-02T09:15:55.522581
2015-02-26T00:02:03
2015-02-26T00:02:03
31,244,324
0
1
null
null
null
null
UTF-8
Python
false
false
1,308
py
account.py
# -*- coding: utf-8 -*- ############################################################################## # # Copyright (C) 2014-Today # CyG xxxx # @autor: Edison Guachamin <edison.guachamin@gmail.com> # ############################################################################## import logging from datetime i...
ffb5a2df5deebe98f1ca57e3efccfc7f65e84483
3284325e42007a0307f0f49aae1280e48273c9ac
/206/assign_5/cgi-bin/addQuestion.py
6740b95880f634e6c15c517d76140a915ef00431
[]
no_license
condad/mcgill
0ec0f1473cddd88a2cfa77a6d2253d29a19b934d
53be745473c5ea4371470513958dc6c36ba660ba
refs/heads/master
2021-05-31T11:14:58.882935
2016-01-28T00:13:36
2016-01-28T00:13:36
null
0
0
null
null
null
null
UTF-8
Python
false
false
293
py
addQuestion.py
#!/usr/bin/env python import cgi, formgen def add(): form = cgi.FieldStorage() if form.has_key("question") and form["question"].value != "": file = open("../survey.ssv","a") file.write(form["question"].value + "\n") file.close() add() formgen.top() formgen.middle() formgen.bottom()
39119b011b3b3f136c0ca8469f0fb7de902fa7fa
aab3b70211a4d8d4dec6c4f89d1c5dbcee4dc15e
/restflaskpyexample/models/users/user.py
0624141a41667262ae57b1429c22fa69d24da049
[ "MIT" ]
permissive
armoredware/restflask
3d1cac81a7072de918625af2d9c13fc5bc8b79bb
3e4c8e38c95a1783981774994d4e3d9d84fc70b0
refs/heads/master
2020-03-23T00:34:07.301889
2018-07-13T17:13:36
2018-07-13T17:13:36
140,870,825
0
0
null
null
null
null
UTF-8
Python
false
false
4,629
py
user.py
import uuid from common.database import Database from common.utils import Utils import models.users.errors as UserErrors import models.users.constants as UserConstants __author__ = 'mjd' class User(object): def __init__(self, email, password, domains, memberlevel, token, APIkey, config, name, paid, paymentdue, a...
cb3177055a98db8065639be76fda53a42165987c
844c6ac669acda0c6378454f1ed7d7753500c7fa
/globalConstants.py
da07be10d5d00370cfb7cc5e8743d77c67dd9e20
[]
no_license
trevorbalint/MDSkmeans
59291c1cf6aee1f3ada8fb5a5520bac4b5ac918a
2259fdd8e2abc55ac3c5f1a71258b44d0b3468ba
refs/heads/master
2022-03-12T23:16:31.375906
2019-12-02T01:14:09
2019-12-02T01:14:09
null
0
0
null
null
null
null
UTF-8
Python
false
false
330
py
globalConstants.py
""" The constants for the project """ import logging import os # Set the logging level across all files loggingLevel = logging.DEBUG # Automatically get the location of the local dropbox folder if os.path.isdir("C:/Users/Trevor"): dropboxPath = "C:/Users/Trevor/Dropbox/" else: dropboxPath = "C:/Users/TrevHP/...
feea487b3768f436c3fbaa9629183eb2262d660e
d449d5f82fe0485ee635a6c0566c417f248df195
/Churn.py
5ba96744f87c0afd09a8957683805ad28257184c
[]
no_license
sagar8080/predictive_modeling
c39d693c02804c7255cb8bf68122c96642edd97b
d2cdececa9a84a6d7c9f1d2d4fe5aa6dc25efedd
refs/heads/master
2020-03-28T18:28:05.028886
2018-09-15T08:28:01
2018-09-15T08:28:01
148,883,746
0
0
null
null
null
null
UTF-8
Python
false
false
6,529
py
Churn.py
# Sagar's Project on Churn prediction using Predictive ModellingTechniques # import libraries import pandas as pd import numpy as np import matplotlib.pyplot as plt import seaborn as sns # read the data from csv file data = pd.read_csv('churn-data.csv') data.head() data.info() # Data PreProcessing ...
ebc792631bce4ce4e2955f3c391d1900f2d66d64
3f92c60bc6591ca284f3473ce33d51352ad70025
/online_judge/usermodule/urls.py
899fcd5ab4f03353e49e906525692de6e1007668
[]
no_license
ckrokad/Online-term-work-submission-and-assessment-labs
b064f8d1b4a86343d9122e7427029acd842dcb74
b6fc4cf014d61d031f3ce389f9b55881c18b28e2
refs/heads/master
2020-06-12T18:21:04.774426
2019-03-04T16:06:47
2019-03-04T16:06:47
null
0
0
null
null
null
null
UTF-8
Python
false
false
676
py
urls.py
from django.conf.urls import url from django.urls import path from .views import * from django.contrib.auth import views as auth_views urlpatterns = [ url(r'auth',auth_view), url(r'addstudent',addstudent), url(r'addfaculty',addfaculty), url(r'add_faculty',add_faculty), url(r'add_student',add_stude...
a669f739ce593d038654a5c7258b9bbe6db12c8d
a2691ce610904a1500c5ed59d7c4de5d6169c8f4
/hackerrank/valid_phone_num.py
1c20cd9953d6d310d854a97ff2c85abbc873e954
[]
no_license
leogao/examples
e439eb4e0c96d50d693e6385507348557408fd41
ec3a910f979b17d4038fa4748574b2c9f6980c77
refs/heads/master
2021-05-19T03:12:13.076912
2021-03-05T04:55:06
2021-03-05T04:55:06
18,282,237
0
0
null
null
null
null
UTF-8
Python
false
false
584
py
valid_phone_num.py
#!/usr/bin/env python # Problem # https://www.hackerrank.com/challenges/regex-1-validating-the-phone-number # Author : leogao def main(): N = int(raw_input()) assert 1<=N<=10 source = [] for x in xrange(N): Nx = raw_input() assert 1<=len(Nx)<=15 source.append(Nx) for y in xr...
cd4eca9c6ffa2b5723da702e5aa6ea69a7633614
6cd70e4dddf6d501c67fefca7f0f33622de9d454
/Discord Bot/.venv/RollingDice.py
6284edd7a2de3e3de0453ab87fb270d4051f673d
[]
no_license
TheJade/Python
63aa34af439c75a8f9829aa5559aeceeca052585
15c33ed170f2a7c1c706ceffebc230a6ce9d1979
refs/heads/master
2021-12-15T03:34:23.553370
2021-12-06T03:46:40
2021-12-06T03:46:40
216,894,866
0
1
null
null
null
null
UTF-8
Python
false
false
607
py
RollingDice.py
# bot.py import os import random from discord.ext import commands from dotenv import load_dotenv load_dotenv() TOKEN = os.getenv('DISCORD_TOKEN') bot = commands.Bot(command_prefix='!') @bot.command(name='d', help='Roll the dice " /d A B C " - A is sides \n - B is constant added \n - C number of dice rolled') async ...
239a9a43bafa6e50f467f7b33433ba4cbd38b76c
5ca1b5298d6e6544ee86a6378c93681e5d621294
/tests/conftest.py
db6eddedf0210085c634f8da434b28ccc56c62da
[]
no_license
Hellowlol/asserted
db2a9c63e447653077100d03eba1a976567d74a8
32af2e8b4ff262c66b12dd28fd53861f73108aac
refs/heads/master
2020-12-03T02:23:34.072748
2017-07-11T21:41:05
2017-07-11T21:41:05
95,933,095
1
0
null
null
null
null
UTF-8
Python
false
false
523
py
conftest.py
import os import sys import pytest PATH = os.path.abspath(os.path.join(os.path.dirname(__file__), '..')) HERE = os.path.abspath(os.path.join(os.path.dirname(__file__), 'txt')) sys.path.insert(0, PATH) import asserted from asserted import cli, example_class def pytest_addoption(parser): parser.addoption("--dev...
fc0b05362deecc01812dde0b4d2f5f6e40b0c6bb
59067192b3528e559d26d5f9ad39189b42a557f8
/apps/gear/models.py
b42b3e9788e18ed213364f8a371a35f03324bfb0
[]
no_license
thraxil/rigs
9ab089f25e79d9de1e76c59960326c376373640c
3552cb5069731d48d94533848e14cc74b4a9c318
refs/heads/master
2020-07-02T02:40:37.421767
2010-08-10T15:25:36
2010-08-10T15:25:36
null
0
0
null
null
null
null
UTF-8
Python
false
false
2,413
py
models.py
from django.db import models from django.contrib import admin from manufacturer.models import Manufacturer from link.models import Link, LinkInline from photo.models import Photo, PhotoInline from django.contrib.contenttypes import generic from django.forms import ModelForm import tagging from tagging import fields fro...
7c5b361dcc5e4dab16f89d99a1c104d9b0de9353
e3c5ef759d56c5046b8854d21e1507abc3ac3752
/bot_app/middlewares/objects.py
b07ed562c22345672cfa3d001b9d333e3e231c2d
[]
no_license
SOAPkelele/Service-for-identifying-similar-3D-objects
59f80c4db96b700be99f52a20b353b77368962e3
7c3640dca79c72e8452277dcc9f41e56951103ad
refs/heads/master
2023-05-20T17:02:47.057377
2021-06-09T10:35:29
2021-06-09T10:35:29
372,177,444
0
1
null
null
null
null
UTF-8
Python
false
false
708
py
objects.py
from aiogram.dispatcher.middlewares import BaseMiddleware class ObjectsMiddleware(BaseMiddleware): def __init__(self, model, index, context=None): super(ObjectsMiddleware, self).__init__() if context is None: context = {} self.context = context self.model = model ...
3cf7ccb559714038f80d1ffa7150cf572526c66e
a583763ead8e690b657c167e9c4b436d5aee2592
/main.py
1823153c4d679e660dd585922c28e1c741b781bd
[ "CC0-1.0", "LicenseRef-scancode-warranty-disclaimer" ]
permissive
brezerk/book_analyzer
265b2883a1f831c4360f3d7d3e521e32e9547eee
65f63675ea2f52bb6099e251759d417b8c4633b6
refs/heads/master
2023-06-15T07:10:47.254075
2021-07-06T23:43:18
2021-07-06T23:43:18
383,622,550
0
0
null
null
null
null
UTF-8
Python
false
false
4,663
py
main.py
#!env python # -*- coding: utf-8 -*- """ Test assigment: Your task is to write a program, BookAnalyzer, that analyzes such a log file. BookAnalyzer takes one command line argument: target‐size. BookAnalyzer then reads a market data log on standard input. As the book is modified, BookAnalyzer prints (on standard outpu...
7805e742ea328205634666fc17ca40f879a2e8ae
109dd7cea709d9fa88a600f5b4b54702bb516155
/messagefilterand.py
6c25c9d8d2454cc2cc9ac7264cbeefaf1fca6c86
[]
no_license
mlockett42/historygraph-poc
4ee4038f3b9a4d505acc2ab7c05c1b53c252ef2b
c5f71aa14e8bae227a43ca46dbbb964dc28f427a
refs/heads/master
2021-08-31T21:53:41.822997
2017-12-23T02:10:22
2017-12-23T02:10:22
73,806,537
2
0
null
null
null
null
UTF-8
Python
false
false
378
py
messagefilterand.py
#combine to filter and return all messages that match both from messagefilter import * from sqlalchemy import and_ class MessageFilterAnd(MessageFilter): def __init__(self, filter1, filter2): self.filter1 = filter1 self.filter2 = filter2 def getFilter(self): return ...
676fc37f9074d70e5e799058252a05019a994c75
45c1c64d7a2fe31c228ed19d06d0fc76671e970a
/services/grupo_produto_service.py
a4a06e45656bdf246d5345535d32a62f49b9d61f
[]
no_license
Cindyyt/cesta
8db5c1e402db3e088a5c7d5d2c3c4ecfe95b41f3
6fa324b10c03c3e46d3b57aea25fd4ad63bb9e0a
refs/heads/master
2023-08-14T20:04:33.800261
2021-10-12T13:19:16
2021-10-12T13:19:16
null
0
0
null
null
null
null
UTF-8
Python
false
false
155
py
grupo_produto_service.py
from pages.models import GrupoProduto class GrupoProdutoService(): def getById(self, pk): return GrupoProduto.objects.get(pk=pk)
73e1dd3ba099c84b17d86bcabf20a205e08e9e0b
209ba5f2193aca2cde82bb79df14717efadf5c4b
/AppVeranum/migrations/0001_initial.py
9ef4d5cc074678887ec765c103e2a1c30043f697
[]
no_license
0snola/semestral-veranum2
d0871caf6b1fdd8202be9633182008325128fd3e
7c6d12acbb491e6b3c445fdc358fefc6df9b4442
refs/heads/master
2023-06-01T08:58:42.320349
2021-06-27T02:20:18
2021-06-27T02:20:18
380,405,392
0
0
null
null
null
null
UTF-8
Python
false
false
1,259
py
0001_initial.py
# Generated by Django 3.2.4 on 2021-06-26 03:26 from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): initial = True dependencies = [ ] operations = [ migrations.CreateModel( name='Hotel', fields=[ ...
61056c7ecd894eb5469c5f72e9577c723d0e2e7a
2cc9d3eb1f60b379e760210c8a82003bb1b8fd1c
/base.py
d3156f3c802f0984854e7e297171eea1a13fa3e0
[]
no_license
vdnguyen58/darwin
3bba70d462a603090be10d46c97e4cd312671b5c
2df78b19e67689274676640b1a99c0b41c982f4b
refs/heads/master
2021-01-20T00:16:25.928234
2017-04-29T17:03:15
2017-04-29T17:03:15
89,104,636
1
0
null
null
null
null
UTF-8
Python
false
false
1,814
py
base.py
#!/usr/bin/python import time from Adafruit_PWM_Servo_Driver import PWM # Initialise the PWM device using the default address # bmp = PWM(0x40, debug=True) class RobotBase(): pwm = PWM(0x40, debug=True) servoMin = 175 servoMax = 625 def setServoPulse(self, channel, pulse): pulseLength = 1000000 ...
bee353a0f864924d2a16edb71606e85b74244fa0
45a41ff6108c5562d30a92319c8f81a0388bf34f
/models/graph_plot_line.py
ea0ac5cdf9c8e2a655d074d35b3fa58f15ac5485
[ "Apache-2.0" ]
permissive
logicmonitor/lm-sdk-python
3672e9177ee36811f491e7a79154b15d6f303543
0cdb8b3092c92e9646862a4a3c12b809fdc53f0b
refs/heads/master
2022-10-10T04:18:47.828792
2022-09-27T13:28:24
2022-09-27T13:28:24
93,185,902
5
7
Apache-2.0
2019-01-09T18:48:31
2017-06-02T16:48:46
null
UTF-8
Python
false
false
13,494
py
graph_plot_line.py
# coding: utf-8 """ LogicMonitor REST API LogicMonitor is a SaaS-based performance monitoring platform that provides full visibility into complex, hybrid infrastructures, offering granular performance monitoring and actionable data and insights. logicmonitor_sdk enables you to manage your LogicMonitor account...
3d44cb851c4e6e9c30f9fce9ba2c53bc595786b3
56ca07fc9b7fba9eb02b5e14fdefdb477734b6b1
/python/pythonProject/Test03.py
862b40e1e9911e37f6906f0c0f26b69d35b34bdb
[]
no_license
zhiyiTec/machineLearn
9a0b194735d8f2ed80b1f5157604014049bab537
836061b5012850fab0b5007e66996a45e928c627
refs/heads/main
2023-01-20T07:16:51.431642
2020-11-30T12:50:29
2020-11-30T12:50:29
314,558,010
0
0
null
null
null
null
UTF-8
Python
false
false
2,244
py
Test03.py
# def dayUp(df): # dayup = 1 # for i in range(365): # if i % 7 in [6, 0]: # dayup = dayup * (1 - 0.01) # else: # dayup = dayup * (1 + df) # return dayup # # # dayFactor = 0.01 # while dayUp(dayFactor) < 37.8: # dayFactor += 0.001 # print("工作日的努力参数是:{:.3f}".format(...
48677d73f6489ce789884a9dff5d50c23f47d8b3
b6b2be9866fd16699ad5c30a21bbcb70755f1e57
/FeatureExtraction/Text/WindowFeatureExtractor.py
77d65060b77e3f9a5e530e82c820cd707bb966dc
[]
no_license
simonhughes22/PythonNlpResearch
24a482c7036c568b063ec099176b393d45a0a86b
2bc2914ce93fcef6dbd26f8097eec20b7d0e476d
refs/heads/master
2022-12-08T17:39:18.332177
2019-10-26T12:48:33
2019-10-26T12:48:33
16,458,105
17
7
null
2022-12-07T23:38:17
2014-02-02T16:36:39
Jupyter Notebook
UTF-8
Python
false
false
2,559
py
WindowFeatureExtractor.py
__author__ = 'simon.hughes' from sklearn.feature_extraction import DictVectorizer from WindowFeatures import compute_middle_index from collections import Counter class WindowFeatureExtractor(object): """ A simple wrapper class that takes a number of window based feature extractor functions and applies the...
65aa85675393efa1a0d8e5bab4b1dbf388018c58
e38da43785fd803694289f189fde94857f04a106
/PS7.py
90407eab44585a2db5d79a8017ef53c81339c3f0
[]
no_license
Akiir3/Algorithms
f2dfc069d2dc945c6f1b7b76fba99088bb8f7b08
e499e0a19b2469c95d95cb28cfd958de6dc1aaed
refs/heads/master
2020-08-13T05:01:00.017353
2019-10-13T23:59:35
2019-10-13T23:59:35
214,911,583
0
0
null
null
null
null
UTF-8
Python
false
false
412
py
PS7.py
indelCost = 1 swapCost = 13 subCost = 12 noOp = 0 def alignStrings(x,y): nx = len(x) ny = len(y) S = matrix(nx+1, ny+1) #?? for i in range (nx+1) for j in range (ny+1) if i == 0: #if the string is empty S[i][j] = j #this will put all the letters from j in i elif j == 0: #if the second string ...
47c1ad4bd1ceffa38eef467ea8eb59dbd2fc2ebb
2eab85ac0547e769337fc42d3e3af4cc334e5b6d
/A3/A3_V1/packetSender.py
a32d927defb2a271ee1eaa14318e401e10ee3ca3
[ "MIT" ]
permissive
lingt-xyz/Data-Communications-Computer-Networks
ea1001ce68f12a66898b7c068e690a21430c3b39
79490b7177010525976fcad5ca3aa846765d4b2b
refs/heads/master
2020-03-28T21:55:12.631812
2019-11-08T01:41:59
2019-11-08T01:41:59
149,191,969
2
0
null
null
null
null
UTF-8
Python
false
false
5,305
py
packetSender.py
from packet import Packet from packetConstructor import PacketConstructor import threading import time class PacketSender: """ Packet represents a simulated UDP packet. """ # The next seq num for sent packets seq_num = 0 # The next seq num for acks that we're waiting for next_seq_num = 0 ...
24cdbbadc8ff1c7ad5d42eeb518cb6c2b34724a2
a3e7e9e61696367443a343c3aa69956d10bb6c96
/scripts/drafts/test_ansatz_elements.py
9575c533f03fd9b3162412a19aa181af15e11e3e
[]
no_license
ElenaStoyanovaC/VQE
16c69ba0df3ab426ff75503bfc6fcf6bbdbd3807
4270a7ec5783e29248c3cbef15749bde0917a903
refs/heads/master
2023-03-21T16:57:20.467505
2021-03-10T17:40:49
2021-03-10T17:40:49
null
0
0
null
null
null
null
UTF-8
Python
false
false
12,356
py
test_ansatz_elements.py
from openfermion import QubitOperator, FermionOperator from openfermion.transforms import jordan_wigner from src.utils import QasmUtils, MatrixUtils from src.ansatz_elements import AnsatzElement, DoubleExchange import itertools import numpy class EfficientDoubleExchange(AnsatzElement): def __init__(self, qubit_...
2843845848747c723d670cd3a5fcb7127153ac7e
0f377391aacc585ad21ebae6c77f8e95d4c8fd09
/main.py
78c9f9d47a1828e153a75137827b34c159088484
[]
no_license
theMatt19/python-iot-sim
6a7d2bfef7fec0bbfdbe4f08816c1d06fc1810aa
4fbf8ffdfab34ae6e2fabcb45e69ba52579364c7
refs/heads/main
2023-08-29T12:03:20.134035
2021-10-29T19:11:01
2021-10-29T19:11:01
null
0
0
null
null
null
null
UTF-8
Python
false
false
1,522
py
main.py
from flask import Flask from sim.toggle import ToggleSensor from sim.sensor import Sensor app = Flask(__name__) sensors = [ ToggleSensor(id="s-01", description="lampadina"), ToggleSensor(id="s-02", description="lampadina"), ToggleSensor(id="s-03", description="allarme atomico"), ToggleSensor(id="s-04...
f5bd41f4aaff616a332d80ec44c364ffc91c58f0
596b7ef9a8622046419ba4a9d9cae45b26455f2c
/q03_skewness_log/build.py
43cc673001c54bee70c938ddad05149297f0be71
[]
no_license
Sagar-saga/feature_engineering_project
7d1e5fad275667aa6e2b036b8207dfd192d0be75
eb2c7cbba1a0664fcbecc189cbbffde6968e0090
refs/heads/master
2021-05-07T20:42:17.804411
2017-11-05T17:50:01
2017-11-05T17:50:01
108,936,330
0
0
null
2017-10-31T02:49:37
2017-10-31T02:49:37
null
UTF-8
Python
false
false
414
py
build.py
# %load q03_skewness_log/build.py from scipy.stats import skew import pandas as pd import numpy as np data = pd.read_csv('data/train.csv') # Write code here: def skewness_log(df): df['SalePrice_New'] = np.log(df['SalePrice']) df['GrLivArea_New'] = np.log(df['GrLivArea']) skewed_slPri = skew(df['SalePrice...
d65f858c3ad06226b83d2627f6d38e03eae5b36c
9655efc19bfb3fb65a88a8a5f288076cff3946da
/phase_transition.py
0741f783f9a7fee190adbce39101733ff6499a59
[ "MIT" ]
permissive
rodrigo-pena/gssr
f95c99b012b90ccace9e8d509c29b0ebf2797a55
a3b1419001bb3fa990201fde07a7df8cac8f7d00
refs/heads/master
2023-07-20T18:03:32.244876
2023-07-07T11:47:35
2023-07-07T11:47:35
188,842,504
1
0
MIT
2023-07-07T11:47:36
2019-05-27T12:49:21
Jupyter Notebook
UTF-8
Python
false
false
5,499
py
phase_transition.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """Phase transition module """ import utils import datetime import itertools import numpy as np import recovery as rec import sampling as smp import graphs_signals as gs import pathos.multiprocessing as mp from tqdm import tqdm ## MAIN FUNCTIONS ## def grid_evalua...
f97a892e6e0aa258ad917c4a73a66e89b0dc3253
d60b55673151e5b8f1fe17181b7c51f6999492b5
/test.py
20d69d748d60b24ac96bd0c0e9a4819020075106
[ "MIT" ]
permissive
Zepyhrus/mtcnn-tensorflow
383bc5290470fe2e416df92b21a0e82efba859e5
6fb6f5cabc28486d2e627f3e2e03727cf4cbd5e0
refs/heads/master
2020-06-02T07:21:39.708643
2019-07-02T08:18:17
2019-07-02T08:18:17
191,081,548
0
0
null
null
null
null
UTF-8
Python
false
false
3,092
py
test.py
# coding: utf-8 # In[1]: import sys sys.path.extend(['detection', 'train']) # from detection folder from MtcnnDetector import MtcnnDetector from detector import Detector from fcn_detector import FcnDetector # from train folder from model_factory import P_Net, R_Net, O_Net import config as config from preprocess.uti...
f19d8aa2104240cc93a0146f1b14c635e7cd3a41
7365e5438f68eca8f9f09dfeabf187b672bf8c63
/fit_SIS.py
4eb2b3feb387fd8f911d2d644d952ae576328fb4
[ "MIT" ]
permissive
arwright3/wtgpipeline
dc161317088e4ceaa5eb4760cbc4bd7cb778957e
cd543873fdc2a4040aa2158aef5709b7d65525c0
refs/heads/master
2021-07-12T07:35:03.501764
2017-10-17T17:35:15
2017-10-17T17:35:15
106,625,068
1
0
null
2017-10-12T00:36:35
2017-10-12T00:36:35
null
UTF-8
Python
false
false
2,529
py
fit_SIS.py
#! /usr/bin/env python import ldac from numpy import * import shearprofile as sp import sys import os, subprocess import pylab if len(sys.argv) != 6: sys.stderr.write("wrong number of arguments!\n") sys.exit(1) catfile= sys.argv[1] clusterz=float(sys.argv[2]) center= map(float,sys.argv[3].split(',')) pixsc...
0e58834120c34b5152026bde6d089be19244e21a
5f786210a0aa920574244be6a541380515884edf
/ctp/option/test.py
62cfc1d163a270475eb374f6d8fe6e8d6fb8cdc2
[]
no_license
MeiQuant/heron-api
39297db2bde6efa860cbd12f5a3f69f9bfa5fcda
af7e30e002feada13bca0b0559f28dac591c2852
refs/heads/master
2021-01-09T06:19:54.287134
2017-02-14T02:03:40
2017-02-14T02:03:40
80,964,823
1
1
null
null
null
null
UTF-8
Python
false
false
401
py
test.py
import os from MdApi import MdApi class Adapter(MdApi): def __init__(self): super(Adapter, self).__init__() def connect(self): self.createFtdcMdApi(os.getcwd()) self.registerFront('tcp://180.168.146.187:10010') def onFrontConnected(self): print 'front succ...
c7e67862eada6506b2cc5d30a65e008ca28c4e87
2f8cade017ba9afdd5442e8bc4d9de396c8d880d
/simple_q_learning.py
c05200263cb86bbdc83223fa608e82f2267cb79c
[]
no_license
abhijitmajumdar/Simple_Q_Learning
1550b2b8ee1a5e0dd0883d960fe735bb0784f51f
ae9171a09b9740c3abbcf71adb74a18e20d10c4e
refs/heads/master
2021-07-16T21:37:50.615939
2017-10-24T06:48:23
2017-10-24T06:48:23
108,087,623
3
3
null
null
null
null
UTF-8
Python
false
false
12,365
py
simple_q_learning.py
import numpy as np import cv2 # Constants LOAD_AND_SAVE_LEARNED_MODEL = False SAVE_FILENAME = 'learned_grid.npy' GUI_REFRESH_RATE = 10 #ms GUI_UPDATE_STEP = 5000 SHOW_STEP = 500 # Grid definitions GRID_SIZE = (10,10) GRID_TERMINALS = [(3,3),(7,5)] GRID_OBSTACLES = [(2,2),(2,3),(2,8),(1,7)] GOAL = [(8,8)] # GUI values ...
d5907d29be64469d76bf454a5ded9302c46433d3
f13acd0d707ea9ab0d2f2f010717b35adcee142f
/AtCoder_Virtual_Contest/tessoku-book/do/main.py
0e2172aa86799ba2b91b955b502c4008e7081f6f
[ "CC0-1.0", "LicenseRef-scancode-public-domain" ]
permissive
KATO-Hiro/AtCoder
126b9fe89fa3a7cffcbd1c29d42394e7d02fa7c7
bf43320bc1af606bfbd23c610b3432cddd1806b9
refs/heads/master
2023-08-18T20:06:42.876863
2023-08-17T23:45:21
2023-08-17T23:45:21
121,067,516
4
0
CC0-1.0
2023-09-14T21:59:38
2018-02-11T00:32:45
Python
UTF-8
Python
false
false
627
py
main.py
# -*- coding: utf-8 -*- def main(): import sys input = sys.stdin.readline n = int(input()) ab = [list(map(int, input().split())) for _ in range(n)] # 絶対値の記号を外す = + / -で4通り考える # op1 * ai + op2 * bi > 0のときだけ加算 def f(op1, op2): summed = 0 for ai, bi in ab: tmp ...
64424b996f8fd21390ddae1a09fa6369a1eafcb9
25eebb62346275a469cc9c1fa72814d2484ae2ae
/API/test_movies.py
f96f0d829fe109096750444dad896621cfe2b6df
[]
no_license
dev-hospa/100DaysOfWeb
391bfd96c585e18ebcc6a6e16153c0e77f4e29dd
f56ecb1d1061227d7ca6d1c3720dd08db2f992d8
refs/heads/master
2020-06-08T17:29:25.262882
2019-07-08T17:23:13
2019-07-08T17:23:13
193,272,813
0
0
null
null
null
null
UTF-8
Python
false
false
3,698
py
test_movies.py
from apistar import test from movies import app, movies, MOVIE_NOT_FOUND client = test.TestClient(app) def test_list_movies(): response = client.get("/") assert response.status_code == 200 movies = response.json() assert len(movies) == 1000 assert type(movies) == list movie = movi...
c587cbf7ece27972da074e1c66f3f077f841a764
a277bd2f527a154a0ec78093e8608c386d772e84
/jenkins/ocr_regression.py
f302c96886d921611efa7a50d5a9a221aadf80c2
[ "BSD-2-Clause" ]
permissive
FuriousBerserker/OCRDebugRuntime
5c7025752fb76c09aa6f622649f242910972c0e7
5965cb6483c3b8be5a8e90d860b26f999886d66a
refs/heads/master
2021-01-25T12:31:16.076959
2018-02-17T06:33:09
2018-02-17T06:33:09
82,502,131
0
0
null
null
null
null
UTF-8
Python
false
false
3,690
py
ocr_regression.py
#!/usr/bin/env python import os # Make a copy of the local home because the regressions run # in place for now jobtype_ocr_regression = { 'name': 'ocr-regression', 'isLocal': True, 'run-cmd': '${JJOB_INITDIR_OCR}/ocr/jenkins/scripts/regression.sh', 'param-cmd': '${JJOB_INITDIR_OCR}/ocr/jenkins/scripts...
1e013fb75e8b1eb7709dc5edc70fc3eb39635d90
8f207224dab695f4eaeaace56f1b8a0df4f3f84f
/DFS/MaxIsland/MaxArea.py
ef3e083b616d9668a9100aefabd9b87a0ba5b69b
[]
no_license
luanshiyinyang/Algorithm
56e668d5ae8caa1c65cae07890e42d285ed079ca
634d1f4a92796a74fde77cf2a411ca8cc5df5802
refs/heads/master
2021-11-24T08:10:29.220314
2021-11-02T12:09:00
2021-11-02T12:09:00
160,944,779
8
5
null
null
null
null
UTF-8
Python
false
false
1,538
py
MaxArea.py
# -*-coding:utf-8-*- class Solution(object): def dfs(self, i, j, current_area, grid, max_value=None): # 开始遍历,标记访问 grid[i][j] = 2 # 向上走可行 if i > 0 and grid[i - 1][j] == 1: current_area = self.dfs(i - 1, j, current_area + 1, grid, ) if i < len(grid) - 1 and grid[i...
ccddbb4d06ff1cd7ea3b19c55427f1e2d1225203
e457ef64e939acc769d3b4609184f1603fdd875a
/fastavro/repository/__init__.py
18d39ab10c9129581ac5659bf267eb63bb2dfc17
[ "Apache-2.0", "MIT" ]
permissive
fastavro/fastavro
dbad8c55fabc9f22b16273ee1a926f22c840c694
40dfd526076446cc7f7eef97e40da216b910d047
refs/heads/master
2023-09-01T04:16:13.510802
2023-08-25T10:19:13
2023-08-25T11:05:36
3,845,895
430
105
MIT
2023-09-14T20:14:34
2012-03-27T16:29:38
Python
UTF-8
Python
false
false
210
py
__init__.py
from .base import AbstractSchemaRepository, SchemaRepositoryError from .flat_dict import FlatDictRepository __all__ = [ "AbstractSchemaRepository", "FlatDictRepository", "SchemaRepositoryError", ]
ec71e8986885cc18bcf252ba4fd27db04c09a9dd
f483545d7765c25d1b315027726dbd74bc77b98a
/02.교육/Python-응용SW개발/Project/day20190420/forEx01.py
64b3879fb94cf2f68ebc2b8910c267a36c8aa6a1
[]
no_license
niceman5/pythonProject
e51b44a50776100a63443d7da850ba4b8b00f5eb
3589fd200b56f68b856d2b4d2031c2a1135168a0
refs/heads/master
2023-07-10T16:12:57.756944
2023-06-27T08:13:54
2023-06-27T08:13:54
135,047,965
0
0
null
null
null
null
UTF-8
Python
false
false
918
py
forEx01.py
##data = [1,2,3] ##for n in data: ## print(n) ## ## ### string으로 loop가능 ##for str1 in 'Hello': ## print(str1) ## ##for n in range(1, 11): ## print(n,end=' ') ## ####for 변수 in 리스트/튜플/문자열 ## ####리스트 내포 ####[명령문 for 항목 in 객체] ####[명령문 for 항목 in 객체 if 조건] ## ##[print(i) for i in range(1, 11)] ##[print(i) for i...
c5772a279a4f7cadee27c308f620ab883ebe11ea
f47226bde488a0948689a83ebd357693b78673a2
/python-scripts/fabric-scripts/fabfile.py
75308225af5c419a4102889e7a4617316f4054a5
[]
no_license
madhukishore123/devops-python-1
62fb886359758e231a2f3692973234db3d085223
ccb0951540e8533d92f11af9918c90acf014da82
refs/heads/master
2020-07-24T04:37:13.751467
2019-01-14T12:25:23
2019-01-14T12:25:23
null
0
0
null
null
null
null
UTF-8
Python
true
false
3,204
py
fabfile.py
from fabric.api import * env.hosts=['172.31.45.239'] env.user='ansible' env.password='ansible' def add_key_rep(): sudo("wget -q -O - https://pkg.jenkins.io/debian/jenkins­ci.org.key | sudo apt-key add -") sudo("sudo sh -c 'echo deb http://pkg.jenkins.io/debian­stable binary/etc/apt/sources.list.d/jenkins.list'") ...
1ee927023e84f11add27d86b9449f3538dbabc75
2cc0058845c55602d123b673d03d0f65401539bf
/KRangeFormat.py
af2f4d20113bb2df2db2d70906f26889e10cbfc9
[]
no_license
SSKudos/PyCodes
5295abf3392fa64719912ca4cd52aa7bc3d3212a
939fb5af3e868dd538520ee908676122cd51da5d
refs/heads/main
2023-04-30T20:03:38.157990
2021-04-29T19:52:01
2021-04-29T19:52:01
311,798,715
0
0
null
null
null
null
UTF-8
Python
false
false
288
py
KRangeFormat.py
for x in range(1, 11): print('{0:2d} {1:6d} {2:8d}'.format(x, x*x, x*x*x)) ''' Prints 1 1 1 2 4 8 3 9 27 4 16 64 5 25 125 6 36 216 7 49 343 8 64 512 9 81 729 10 100 1000 '''
7a0e71e60f51e9c4c3439fd209a02352a6ef9adc
c87020df389bd991f7b28007572e330be629e22a
/napari/_qt/dialogs/_tests/test_preferences_dialog.py
69c3b0a93b2788079d6e4cddfb00943095e63452
[ "BSD-3-Clause" ]
permissive
liaprins-czi/napari
5d974e72da6cba914b60ac252c802affda2ac66d
a3d0a6ccf30e8feb29377f05badc81d06cbfb52b
refs/heads/master
2023-07-09T10:54:00.426740
2021-08-10T17:16:21
2021-08-10T17:16:21
394,710,073
0
0
BSD-3-Clause
2021-08-10T17:18:49
2021-08-10T16:29:03
Python
UTF-8
Python
false
false
211
py
test_preferences_dialog.py
from napari._qt.dialogs.preferences_dialog import PreferencesDialog def test_preferences_dialog_show(qtbot): dlg = PreferencesDialog() qtbot.addWidget(dlg) dlg.show() assert dlg.isVisible()
b8118bad3b5b869ae6cda18b87ca308f996293ce
175d78412ca70eb6cda5f4e3a591a8b335c86276
/train_stacking.py
3ea16a7d4142fa2f6117c6e6120ec6803ad76098
[]
no_license
taigangliu/BiLSTM-5mC
6955eabef579a12b4b888193a73ede6d44a484a9
39ae2507ee35f934d7998d08042b7029d9f9faa8
refs/heads/main
2023-09-04T14:02:48.401003
2021-10-30T04:37:48
2021-10-30T04:37:48
422,446,465
0
0
null
null
null
null
UTF-8
Python
false
false
5,533
py
train_stacking.py
from model_bilstm import BiLSTM from model_util import load_model import os import numpy as np import torch import random import torch.utils.data as data from sklearn.model_selection import KFold from sklearn.metrics import accuracy_score,confusion_matrix,roc_auc_score,roc_curve from get_data import get_pos_feature,get...
911b2e39c86b472560c627666548701157aa0f0e
4b9f8b9ab9afc4ee0ccf579cf5deb9aac9088c80
/Pi/servertest2.py
e052c3ccf886049b46f9132171cb25dc31f250ff
[]
no_license
Procinogen/Myo-Tests
fc31b2d1590783a60f5335fd2ffd5b85e757cdb3
b65e088b5f44785eb4aa8ada54c0d3a03743db09
refs/heads/main
2023-02-22T08:52:27.570767
2021-01-21T20:41:45
2021-01-21T20:41:45
331,749,088
0
0
null
null
null
null
UTF-8
Python
false
false
1,143
py
servertest2.py
import socket import pickle s = socket.socket() #host = socket.gethostname() #print("Hostname: " + str(host)) port = 12345 print("Port: " + str(port)) s.bind(('', port)) #-=+=-=+motor stuff+=-=+=- #Setup stuff import RPi.GPIO as GPIO import time GPIO.setmode(GPIO.BOARD) GPIO.setwarnings(True) #The juicy stuff def ...
f071ca1ecc67323c9c5407812e06714ea40faeb6
689d19292c4858f7cd30402d0eaf38405fb21ff5
/cjsite/crwdsource/migrations/0001_initial.py
45fe295cbd47c3ba227bdd3bbda4aae025742c20
[]
no_license
akhilraj95/CollgeDatabase
205f8cf9843f70477d11d9ee4a66fbc34c5ae625
2d615ed3bdf81b514f1d66d9721ef6cb78f47a08
refs/heads/master
2021-01-12T16:41:03.224118
2017-02-12T16:20:52
2017-02-12T16:20:52
71,425,194
0
1
null
null
null
null
UTF-8
Python
false
false
993
py
0001_initial.py
# -*- coding: utf-8 -*- # Generated by Django 1.10.5 on 2017-01-20 17:24 from __future__ import unicode_literals from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): initial = True dependencies = [ ('frontendapp', '0024_courses_visit_count...
5a6d5692ee44d0fd513cbb6c6a527af77aad8d0d
9114893d08bcb360ae63dfd5a7ab396eb98dbd64
/orders/forms.py
3e2b98cb9c17e42d66d2af72c42084ed85d3fba7
[]
no_license
Toluwalemi/dj-ecommerce-hyssop-store
50308e1011fa9e619cb156cf60948dc8e53bac2b
e8fbd07b7cb190cec11aa1ae2fd736e7bfe80858
refs/heads/main
2023-08-28T23:36:38.174890
2021-10-29T15:50:46
2021-10-29T15:50:46
null
0
0
null
null
null
null
UTF-8
Python
false
false
1,324
py
forms.py
from orders.models import Order from django import forms class OrderCreateForm(forms.ModelForm): class Meta: model = Order fields = ['first_name', 'last_name', 'email', 'telephone', 'address', 'postal_code', 'city', 'country', 'note', 'transport'] widget...
faaf49ed64a8631fefeccb5f27869e5df797d4a4
60fb506ff176bd954a847fcf656f2a2928e74e69
/cards.py
87dc718172324e2e3c9047d7da13c7565377358d
[]
no_license
EIIis/Blackjack
eaf0ecae777c811d0d99e3b284131a0ac1ea34b8
34ae163ce214b57f90777604f35ad4e67038289f
refs/heads/main
2023-08-15T03:07:35.962419
2021-10-01T14:14:46
2021-10-01T14:14:46
411,837,648
0
0
null
null
null
null
UTF-8
Python
false
false
5,442
py
cards.py
import random # File contains functions that will be called to run the game # Set of all cards represented in a matrix format with a list a list # Each card is represented by the two numbers in each element, the card representation is [rank, suit] # The first number is the rank, so 1 = Ace, 2 = 2, 3 = 3, 4 = 4, 5 = 5,...
8020fa1ae0bc0507216cdb638476983c624248f2
b643e7b9f421891f423a47ba2118cb73cb8812bb
/Server/GetDriverNameResponse.py
cb7010489b88ced76e573b63c52f03c0d446dcec
[]
no_license
juanlureguera/django-test
db855361291d94c452783fea0283923ac79ecdf7
20fc4711ade877cc26a9737d1a94a70452d06c1b
refs/heads/main
2023-04-22T00:07:28.837614
2021-05-14T13:41:53
2021-05-14T13:41:53
367,356,720
0
0
null
null
null
null
UTF-8
Python
false
false
457
py
GetDriverNameResponse.py
import json from Server.ServerResponse import ServerResponse class GetDriverNameResponse: def __init__(self, name): self.name = name def toJsonString(self): newJson = {} newJson['driverName'] = self.name return json.dumps(newJson) @staticmethod def fromJsonString(jso...
087cbfbb9eaf871257d141c8cbaac9a7b4c9cb1f
45fee0f32d442b8f15ef166c419e59bfadb9d5ed
/eco_connect/facts_service.py
6541e5fab145316378d9773d81e8eed272bfa4fe
[ "MIT" ]
permissive
ecorithm/eco_connect
422c1d17fb3c30bf91b33c198d3455610a4697df
2c185ffabf09b3f276dca5bb52d3c397e691eabf
refs/heads/master
2022-12-09T16:32:14.349391
2019-10-10T09:57:25
2019-10-10T09:57:25
118,977,780
0
0
MIT
2022-12-08T06:34:39
2018-01-25T23:02:13
Python
UTF-8
Python
false
false
52,847
py
facts_service.py
import pandas as pd from collections import namedtuple from operator import attrgetter from eco_connect.src.base_request import BaseRequest from eco_connect.src.request_parser import RequestParser from eco_connect.src.errors import RequestParserError class FactsService(BaseRequest): """A class to connect to Ecori...
edca4b132eb845d856c71e601cd2f37b88d29936
01de66bc478982722cb25120e9d15c39a235a051
/python3/DSP/wave_gui/SignalOperation_UI.py
01e110fcac19bf92640b56b3c6dcc4825e4ac961
[]
no_license
ptracton/experimental
2503c2e8ead7e5719d7aee612fb2ba4d219e6c87
7d4a27126f7f2a93f7216b9ea4eed15789599bf3
refs/heads/master
2020-06-08T08:21:43.100928
2018-04-08T04:54:22
2018-04-08T04:54:22
7,012,360
4
7
null
null
null
null
UTF-8
Python
false
false
762
py
SignalOperation_UI.py
#! /usr/bin/env python3 from PyQt4 import QtGui import LabelAndComboBox class SignalOperation_UI(QtGui.QDialog): def __init__(self, parent=None): super(SignalOperation_UI, self).__init__(parent) self.top_vbox = QtGui.QVBoxLayout() optionsList = ["ADD", "SUB", "MULT", "CONV", "FFT"] ...
b3c2c9369ac269d06ead7fecf73159dc1fe08724
5a7dbd39831f28ab21a0ad82981deb5396c82ba6
/Pages/Locators.py
725392c5a9ff4e7e49dd3786403789d4627c0482
[]
no_license
namdo1983/DemoSeleniumPython
f97d24891ae6b6d4a6a18138aee2b19ac271ab4c
0d30581eb42fc83a3f367723c309ee699236c60f
refs/heads/master
2022-12-15T01:38:36.079578
2021-04-12T07:16:14
2021-04-12T07:16:14
225,281,531
0
0
null
2022-12-08T08:14:21
2019-12-02T03:57:33
Python
UTF-8
Python
false
false
1,156
py
Locators.py
class Locator(object): # Login Page LOGIN_MENU = "//*[@id='__next']/div/header/div[3]/div/div[2]/div[2]/span/span" LOGIN_SUBMENU = "#__next > div > header > div.Container-sc-1fnsswg-0.itgICN > div > div.Userstyle__Root-xrezqc-0.fRWDhU > div:nth-child(3) > div > button:nth-child(1)" EMAIL_FIELD = "#email...
464a425a916dd6a878f447e770a3924b431505c7
8971fcba6dd7aeefc2ff006b68f2320a7bcd9d73
/backend/chalicelib/functions_postgresql.py
b2e68ccc91d5dc39073147f24182bbf1b817cda2
[]
no_license
MartijnHarmenzon/MAPtm-pool-rankings
f0b25d9dce4b3fecc1507aaae637451a39e41de9
0f54511f690d9fbb06da651a0a49b382afba7ea6
refs/heads/main
2023-08-25T08:44:50.431536
2021-10-15T13:55:37
2021-10-15T13:55:37
null
0
0
null
null
null
null
UTF-8
Python
false
false
3,886
py
functions_postgresql.py
import psycopg2 # from psycopg2.extensions import AsIs from psycopg2.extras import execute_values def select_one(params, sql): conn = None records = None try: conn = psycopg2.connect(**params) cur = conn.cursor() cur.execute(sql) records = cur.fetchone() cur.close(...
52c346a7459b1d13102b6a3480838b81340de64c
1bf56e7bfd0f5a778e5c66f2567deb8892cc13f6
/salome_run_code.py
c565e56d82872c468afef2fc94a066930d584411
[]
no_license
sooriyan1994/New_intersting_work
b985c917a7361a1748d7a5c5690a215cbc63458b
cd9175f9587ae3b78b5c217a9b9bb9730b6356b0
refs/heads/master
2020-06-01T01:04:04.989080
2019-12-15T19:43:09
2019-12-15T19:43:09
190,570,044
0
0
null
null
null
null
UTF-8
Python
false
false
2,772
py
salome_run_code.py
# -*- coding: utf-8 -*- import math import os from subprocess import Popen ''' We can write a file too with the desired results ''' SALOME_ROOT='/INSTALLABLES/salome_meca-2017/appli_V2017.0.2/salome' #root folder for salome ASTER_ROOT='/INSTALLABLES/aster' #root folder for asterstudy WORKING_DIR='/home/u...
1b3bce1c38ae10aaaa2bdb2280b3ae7f38a7dd5a
baecf528008edd6b9921b5a9712d7cf1d743edc5
/scripts/snmprec.py
99c4d0dd05256a9912c39bf1f6cfaa3ad799f44d
[ "BSD-3-Clause" ]
permissive
richb-hanover/websnmpsim
9d4bafbb86668968f3ab14de1058479a605debf8
68d294f8bda5159bee3a0bcffca6acc5e0e1409b
refs/heads/master
2018-12-31T17:03:54.856324
2013-10-27T21:24:41
2013-10-27T21:24:41
8,741,903
3
0
null
2013-10-27T21:24:42
2013-03-13T00:51:30
Python
UTF-8
Python
false
false
11,409
py
snmprec.py
# # SNMP Snapshot Data Recorder # # Written by Ilya Etingof <ilya@glas.net>, 2010-2013 # import getopt import time import sys from pyasn1.type import univ from pysnmp.proto import rfc1902, rfc1905 from pysnmp.entity import engine, config from pysnmp.carrier.asynsock.dgram import udp try: from pysnmp.carrier.asynso...
bedfed83988730e97859c3f2b6325b462ab62f16
73cd74c591adef99e36c35d80e6abc860f5eaeae
/SpotPicker/base.py
d9da88ed64b79d1977d98e56377dbc2756fdc5fe
[ "MIT" ]
permissive
PatTheSilent/SpotPicker
9950180da30df257e86e364904295430e30c9785
f59d9a1371c09d9dd48525a0137fdbbf68ed3695
refs/heads/master
2023-01-14T18:00:31.487729
2020-11-08T17:01:46
2020-11-08T17:01:46
311,054,282
0
0
null
null
null
null
UTF-8
Python
false
false
245
py
base.py
""" Basic stuff that we want available accross all classes goes here. """ import logging class Base: def __init__(self): self.logger = self.get_logger() @staticmethod def get_logger(): return logging.getLogger()
3d283db43866f8a9d79a0ddef14c774166a6f633
b292e2cf64ca2d5e7ebe0463f3e1f2ca67351bcb
/NCC_Mailers.py
1b8356588d3fca5d7eb574e97aa38bbd31c3b1a5
[]
no_license
haochenxiao666/jenkins_crumb
78bbd0bdec335a20ec978b28c74230d6ae68163a
967546f3e1c145cbe41eb65b6c1592c7e201596b
refs/heads/master
2022-12-16T22:14:53.478034
2020-09-24T05:41:03
2020-09-24T05:41:03
298,155,111
2
1
null
null
null
null
UTF-8
Python
false
false
51
py
NCC_Mailers.py
# ~*~ coding: utf-8 ~*~ NCC_Mailers = [ ]
a20c86e6655bfae0c9b7551aeec116a56d48543c
ee9231470f445022661406130c71bc6a3ce36d3e
/UI/app/migrations/0007_auto_20201124_1305.py
c59b698b07bca2b30c3d522a2176db413f1a41fe
[ "MIT" ]
permissive
sanilrod/Contactless-Attendence-System
dd9396d556315b631b172d84c62eeac439088d84
a0246047df139807dd636ca102b8151c456292ae
refs/heads/main
2023-04-17T03:26:36.664789
2021-04-26T16:48:43
2021-04-26T16:48:43
361,774,293
1
0
null
null
null
null
UTF-8
Python
false
false
617
py
0007_auto_20201124_1305.py
# Generated by Django 2.0 on 2020-11-24 07:35 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('app', '0006_auto_20201124_1145'), ] operations = [ migrations.AddField( model_name='attendance', name='image_path', ...
c7d3c332781dcd9e50db01471564b6f12f89b708
7722220531c7d7b884d3545dbc81f85a58a03a5b
/old/anothertest.py
f9570a9114f4c0cd675f41e4b6cd5cab5ad3e548
[]
no_license
KaiserFrost/LEI
d200f31c380da10e326588580306540d90efdebc
ba79cac783cab3d5297c2ec663ef670a2749526d
refs/heads/master
2022-11-16T19:07:44.704567
2020-07-18T12:20:41
2020-07-18T12:20:41
277,837,146
0
0
null
null
null
null
UTF-8
Python
false
false
1,429
py
anothertest.py
import wmi import win32com.client #wmi_conn = wmi.WMI() for local. w = wmi.WMI() for p in w.Win32_Product(): print (p) def wincom(): #cp = subprocess.run(["apt","list", "--installed"], stdout=subprocess.PIPE) #output = subprocess.check_output("apt list --installed", shell=True) #output = output.decode("ut...
217b2363d8787e25fc4d75c40b805f21f9b39b77
12ddc9a17656febd004197be6d6120b6a092dfa2
/ana_company.py
16fac1ea78295db37b532310f9161734ffc8a372
[]
no_license
Jun321/kaggle_project
f30b61ec197e5d8009d5038116c33816bd262d31
fdee5143b52679eef06517c6feb68d5428bcbefe
refs/heads/master
2020-12-25T17:13:04.985389
2018-08-12T13:43:47
2018-08-12T13:43:47
58,943,044
0
1
null
null
null
null
UTF-8
Python
false
false
1,904
py
ana_company.py
import matplotlib.pyplot as plt import numpy as np import pandas as pd import scipy.stats as stats import numpy as np import seaborn as sns import matplotlib.pyplot as plt matplotlib.style.use('ggplot') #!!!!!!!!!!TARGET::::::-----> 计算(拟合)概率密度函数和概率分布函数 for 连续性随机变量 x = np.append(np.random.randint(0, 100, 1000), np.ra...
a069523af77e7954737c76e7cb2afde2f75ed244
63b3e64d0f1290676cdc91c882e9d900eefa6e73
/instruments/8_foen/python/foen.py
5ebb98cda582cb7eeb0dc5cbf211254628e127b1
[]
no_license
KAZOOSH/MIMR
68cb983e2aa47636a438e71551d9b2f8be135c0c
994c7d70f4bc9e71ffa7880e0e2ad08ae551bd26
refs/heads/master
2022-10-15T08:54:37.444689
2022-09-15T15:38:16
2022-09-15T15:38:16
90,995,645
2
1
null
2017-10-02T20:24:52
2017-05-11T15:36:03
Python
UTF-8
Python
false
false
3,651
py
foen.py
#!/usr/bin/python import socket import sys from time import time from serial import Serial import struct import RPi.GPIO as GPIO print "Start Foen" '''init serial and network''' # open serial port to Arduino serial = Serial( "/dev/ttyACM0", 115200, bytesize=8, parity='N', timeout=0.01 ) # open UDP socket to liste...
21d1b822ab7c999c9147f8d2112e56daae5c82fd
5bffe3073204e845cda4b8fcba1e460973ef7d25
/portal/models/__init__.py
3516d97a22f09aa6d3e94ae12b1cb3796dab7817
[]
no_license
samirvasavada/fsai_repo
e1426044e9d4078889fd926983177e9be0fc9bab
e79d55a5781c9db6bf0e944dceb310f379ea0b33
refs/heads/master
2021-01-13T12:16:57.453309
2016-08-25T16:59:34
2016-08-25T16:59:34
null
0
0
null
null
null
null
UTF-8
Python
false
false
252
py
__init__.py
import datetime from django.conf import settings from django.contrib.auth import models as auth_models #Define any models you want to be created from user.portal_user import PortalUser from data.portfolio import Portfolio from data.stock import Stock
5e09a19ca04fbe8e4175485bb630b79eebcdbb2c
13f4a06cd439f579e34bf38406a9d5647fe7a0f3
/nn_ns/ply_yacc_tools/parses/PutPythonCodeIntoGramma/__main__.py
a755a0748213a1ead44f37a7e4b403dc02e0eb43
[]
no_license
edt-yxz-zzd/python3_src
43d6c2a8ef2a618f750b59e207a2806132076526
41f3a506feffb5f33d4559e5b69717d9bb6303c9
refs/heads/master
2023-05-12T01:46:28.198286
2023-05-01T13:46:32
2023-05-01T13:46:32
143,530,977
2
2
null
null
null
null
UTF-8
Python
false
false
1,689
py
__main__.py
__all__ = ''' main '''.split() from .example import __doc__ as example_doc from .PLY_YACC_Helper_YaccRules import parse_ex __doc__ = example_doc def main(argv=None): import argparse from seed.io.may_open import may_open_stdin, may_open_stdout parser = argparse.ArgumentParser( descripti...