source
stringlengths
3
86
python
stringlengths
75
1.04M
sending_schelude.py
#!/usr/bin/python # -*- coding: utf-8 -*- import schedule import time from threading import Thread print('Рассылка запущена...') def run_threaded(job_func): job_thread = Thread(target = job_func) job_thread.start() schedule.every().hour.at(":01").do(run_threaded, analise_sender) def job_sending(): while...
doji.py
## Complete Doji import threading import pandas as pd from queue import Queue import time import requests file = open("stock_pred.txt", "w") data = pd.read_csv("C:\\Users\\BEST BUY\\Desktop\\NASDAQ_20200331.csv") symbols = data.iloc[:100,0:1].values th = Queue(maxsize = 4000) def net_work(i): print(i[0]) strin...
classifier_process.py
from pylsl import StreamInfo, StreamOutlet, StreamInlet, resolve_byprop from multiprocessing import Process from BIpy.bci.inlets import WindowInlet import numpy as np import time def run_classifier(clf, in_source_id='myuid323457', out_source_id='classifier_output', stream_no=0, window_size=None): """Runs a real-t...
run_queries.py
import logging import multiprocessing import random import threading import time from sqlalchemy import create_engine logging.basicConfig() logging.getLogger("sqlalchemy_collectd").setLevel(logging.DEBUG) def worker(appname): e = create_engine( "sqlite:///file.db?plugin=collectd&collectd_program_name=%s...
pipelinePoolPerf.py
import time import threading import Queue import argparse import sys from uMediaServer.uMediaClient import MediaPlayer def proxy_thr(recv, send): while True: (ev, data) = recv.get() print "ev '%s' = (%s)" % (ev, data) send.put_nowait((ev, data)) def start_proxy(umc, send): recv = Queu...
__init__.py
import logging try: from Queue import Queue # PY2 except ImportError: from queue import Queue # PY3 from threading import Thread try: from urlparse import urljoin # PY2 except ImportError: from urllib.parse import urljoin # PY3 from bs4 import BeautifulSoup import requests from requests.exceptions ...
watchdog.py
# -*- coding: utf-8 -*- from kazoo.client import KazooClient import os import logging import time import signal from multiprocessing import Process main_dir = "/root/V3/project/" import sys reload(sys) sys.setdefaultencoding('utf-8') signal_dir = '/signal/taobao' + '_' + sys.argv[1] task_type = "accurate_taobao" key...
audio_reader.py
import fnmatch import os import re import threading import librosa import numpy as np import tensorflow as tf def find_files(directory, pattern='*.wav'): '''Recursively finds all files matching the pattern.''' files = [] for root, dirnames, filenames in os.walk(directory): for filename in fnmatch...
offline_walks.py
"""Dataset for offline random walks. This script loads graph walks that have been generated offline. It is intended to be imported by the Python data reader and used in a Skip-Gram algorithm. Data samples are sequences of vertex indices, corresponding to a graph walk and negative samples. """ import configparser impo...
send_commands.py
import time import threading import requests import copy from rassh.api.nonblocking_put_request import NonBlockingPutRequest from rassh.config.config import Config from rassh.datatypes import Grammar from rassh.datatypes.well_formed_command import WellFormedCommand class SendCommands(object): """This is the clas...
app.py
""" ================================================================== name: app.py purpose: the top module of the application time: Dec 21. 2020 version: v1.0.0 author: Shen Zhang ================================================================== """ """ ==============================================================...
daemon.py
#!/usr/bin/python3 """ Object used to define and create a daemon process on the guest machine that is subjected to testing. The daemon is responsible for receiving a test plan, executing it and returning the results. """ import socket import logging import signal import sys from time import sleep from threading impor...
SeBruteGUI.py
# -*- coding:utf-8 -*- # Date: 2021-10-18 # Author:kracer # Version: 1.0 from tkinter import * import tkinter.messagebox # 消息弹出框 import tkinter.filedialog # 文件选择框 from PIL import Image, ImageTk from threading import Thread from common import * from processOneIp import processOneIp from processManyIp im...
test_proxy.py
######## # Copyright (c) 2014 GigaSpaces Technologies Ltd. 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...
unsupervised_pretrain.py
# Copyright (c) 2020 PaddlePaddle 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 app...
core.py
import os import sys sys.path.insert(1, os.path.join(sys.path[0], '../')) import numpy as np import h5py import argparse import time import logging from sklearn import metrics from utils import utilities, data_generator, agument import tensorflow as tf slim = tf.contrib.slim import pandas as pd import matplotlib as m...
worker.py
import abc from copy import copy from dataclasses import dataclass, field import functools import multiprocessing from multiprocessing import synchronize import threading import time import typing as tp import stopit from pypeln import utils as pypeln_utils from . import utils from .queue import IterableQueue, Outpu...
gpu.py
import os, time, multiprocess import configparser import subprocess from compute.log import Log import json from compute.db import add_info, get_available_gpus, confirmed_used_gpu import random # 读compute/gpu.ini def get_gpu_info(): config_file_path = os.path.join(os.path.dirname(__file__), 'gpu.ini') config ...
crawler_thread.py
# SJTU EE208 # -*-coding:utf-8-*- import os import math import re import string import sys from typing import final import urllib import requests import urllib.error import urllib.parse import urllib.request from urllib.request import Request, urlopen import hashlib import threading import queue import time from bs4 im...
__init__.py
#!/usr/bin/python import base64 from binascii import hexlify from cryptography import x509 from cryptography.hazmat.backends import default_backend from cryptography.hazmat.primitives import hashes from distutils.spawn import find_executable from kvirt import common from kvirt.common import error, pprint, warning from...
nanny.py
import asyncio from datetime import timedelta import logging from multiprocessing.queues import Empty import os import psutil import shutil import threading import uuid import warnings import weakref import dask from dask.system import CPU_COUNT from tornado import gen from tornado.ioloop import IOLoop, TimeoutError f...
stream.py
# Tencent is pleased to support the open source community by making GNES available. # # Copyright (C) 2019 THL A29 Limited, a Tencent company. 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...
mergeTrainingNN.py
import pandas as pd import numpy as np from sklearn import model_selection,preprocessing from keras.preprocessing.image import ImageDataGenerator from datetime import datetime import matplotlib.pyplot as plt from datetime import datetime from keras import optimizers import sys, os,ast,json,copy,traceback,pathlib from ...
test_active_server_debugger.py
import socket import threading import time import unittest import sys from io import StringIO from egtsdebugger.active_server_debugger import ActiveEgtsServerDebugger from egtsdebugger.egts import * auth_packet = b"\x01\x00\x00\x0b\x00\x0f\x00\x01\x00\x01\x06\x08\x00\x01\x00\x38\x01\x01\x05\x05\x00\x00\xef" \ ...
port_scanner.py
from queue import Queue import threading import socket localhost = '127.0.0.1' queue = Queue() open_ports = [] def port_scanner(port): try: sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM) sock.connect((localhost, port)) return True except: return False def select_por...
pdv.py
# Copyright (c) 2011-2022, Lawrence Livermore National Security, LLC. # Produced at the Lawrence Livermore National Laboratory # Written by Mason Kwiat, Douglas S. Miller, and Kevin Griffin, Edward Rusu # e-mail: rusu1@llnl.gov # LLNL-CODE-507071 # All rights reserved. # This file is part of PDV. For details, see <UR...
localhost_Server.py
# # Created on Sat Oct 09 2021 # Author: Owen Yip # Mail: me@owenyip.com # import os, sys import threading import numpy as np import time import zmq import json pwd = os.path.abspath(os.path.abspath(__file__)) father_path = os.path.abspath(os.path.dirname(pwd) + os.path.sep + "..") sys.path.append(father_path) class...
engine.py
""" tick 文件记录 华富资产 """ import os import csv from threading import Thread from queue import Queue, Empty from copy import copy from collections import defaultdict from datetime import datetime from vnpy.event import Event, EventEngine from vnpy.trader.engine import BaseEngine, MainEngine from vnpy.trader.constant impor...
datasets.py
# Dataset utils and dataloaders import glob import math import os import random import shutil import time from itertools import repeat from multiprocessing.pool import ThreadPool from pathlib import Path from threading import Thread import cv2 import numpy as np import torch from PIL import Image, ExifTags from torch...
esempio4.py
from threading import Thread, Lock import time import logging from random import randrange mutex = Lock() sharedBuffer = '' def thread_writer(name): global sharedBuffer global mutex logging.info("WThread %s : starting", name) time.sleep(randrange(1,10)) mutex.acquire() sharedBuffer = r...
smtclient.py
# Copyright 2017,2020 IBM Corp. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agr...
main.py
import websockets import asyncio import base64 import json import pyaudio import os import spotipy from multiprocessing import Process, Queue, Pipe from configure import auth_key, SPOTIPY_CLIENT_ID, SPOTIPY_CLIENT_SECRET, SPOTIPY_REDIRECT_URI, SPOTIFY_USERNAME from ui import uifunc from ytm import start_yt_music from ...
homeguard.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # Copyright (c) 2015 Alexander Lokhman <alex.lokhman@gmail.com> # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, includin...
wirelessV3.py
# Matt Grimm # USAFA # Wireless nRF24L01+ Wireless Communication # 7 November 2016 import RPi.GPIO as GPIO import time import sys,signal import spidev import threading # READ HERE: So...pretty much, it's really hard to tell exactly where I am messing up with regards to protocol when I do not have a logic analyzer. I ...
PyMusic.py
import base64 # download库 import binascii import json import string from urllib import parse # player库 import tkinter from tkinter import Button from tkinter import Entry from tkinter import Scale from tkinter import Label from PIL import Image, ImageTk from tkinter import Toplevel from pymediainfo impo...
controller.py
import os import re import traceback from datetime import datetime from math import floor from pathlib import Path from threading import Thread from typing import List, Set, Type, Tuple, Optional from packaging.version import Version from bauh.api.abstract.controller import SearchResult, SoftwareManager, ApplicationC...
thread_queue.py
# The MIT License (MIT) # Copyright © 2021 Yuma Rao # Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated # documentation files (the “Software”), to deal in the Software without restriction, including without limitation # the rights to use, copy, modify, merge, ...
node.py
import hashlib import time import math import random import socket import sys from thread import * import threading from bitcoin import * import requests from time import mktime from datetime import datetime import ast elementlength=1000 #max number per array element, not number of elements vectorlength=32 #number of...
generator.py
#!/usr/bin/python3 import ctypes, os, threading, base64 from strgen import StringGenerator tokenid = "4030200023" class Discord: def __init__(self): self.regularExpression = ".([a-zA-Z0-9]{6})\.([a-zA-Z0-9]{27})" # This is the regular expression for discord. self.generated = 0 def ...
conexoes.py
import socket from threading import Thread from hashlib import sha256 from . import crud def start(): crud.start_bd() debug = False soc = socket.socket(socket.AF_INET, socket.SOCK_STREAM) def get_ip(): s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM) try: # doesn't even...
server.py
# Created by MysteryBlokHed on 21/02/2020. import socket from datetime import datetime from math import ceil from threading import Thread from time import sleep from .encryption import * from .exceptions import * from .status import * HEADERSIZE = 16 class Server(object): """ `port: int` - The port to host E...
calc_server.py
from math import factorial, sqrt from socket import * import threading class ThreadedServer(): def listenToClient(self, client, addr): print(addr, "logged in") while True: try: equation = client.recv(1024).decode() if equation == "exit!": ...
stock_scheduler_compute.py
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. # # Order Point Method: # - Order if the virtual stock of today is below the min of the defined order point # from odoo import api, models, tools import logging import threading _logger = logging.getLogger(__name__...
exe.py
import time import psutil import subprocess from threading import Thread from arpwitch import __exec_max_runtime__ as EXEC_MAX_RUNTIME from arpwitch.ArpWitch import timestamp from arpwitch.ArpWitch import logger class ArpWitchExec: subprocess_list = [] def async_command_exec_thread(self, exec_command, pac...
streaming.py
# Tweepy # Copyright 2009-2010 Joshua Roesslein # See LICENSE for details. import httplib from socket import timeout from threading import Thread from time import sleep from tweepy.models import Status from tweepy.api import API from tweepy.error import TweepError from tweepy.utils import import_simplejson, urlencod...
bootstrap.py
""" Bootstrap an installation of TLJH. Sets up just enough TLJH environments to invoke tljh.installer. This script is run as: curl <script-url> | sudo python3 - Constraints: - The entire script should be compatible with Python 3.6, which is the on Ubuntu 18.04+. - The script should parse in Pytho...
input.py
""" -------------------------------------------------- author: arthur meyer email: arthur.meyer.38@gmail.com status: final version: v2.0 --------------------------------------------------""" from __future__ import division import os import threading import numpy as np import tensorflow as tf fr...
utils.py
import logging import os import random import re import shutil import sqlite3 import string import subprocess import threading import time from btcproxy import BitcoinRpcProxy from bitcoin.rpc import RawProxy as BitcoinProxy from decimal import Decimal from ephemeral_port_reserve import reserve from lightning import L...
utils.py
import os import sys import re from time import sleep, time from subprocess import Popen, PIPE from multiprocessing import Process def config_ip(net): h1, h2, r1 = net.get('h1', 'h2', 'r1') h1.cmd('ifconfig h1-eth0 10.0.1.11/24') h1.cmd('route add default gw 10.0.1.1') h2.cmd('ifconfig h2-eth0 10.0.2...
wandb_run.py
import atexit from datetime import timedelta from enum import IntEnum import glob import json import logging import numbers import os import platform import re import sys import threading import time import traceback from types import TracebackType from typing import ( Any, Callable, Dict, List, Nam...
botclient.py
# coding: utf-8 from __future__ import absolute_import, with_statement, print_function, unicode_literals __version__ = '20.272.2127' # gzip_decode #__version__ = '20.260.0040' # binary #__version__ = '20.136.1222' #__version__ = '20.104.0843' #__version__ = '20.053.0012' #__version__ = '20.026.2002' #__version__ = '...
main_05_LSTM.py
import Redes.Red_LSTM as Interface import Auxiliary.preprocessingData as Data import Auxiliary.GPUtil as GPU import numpy as np import os from threading import Thread import pickle import tensorflow as tf ################################### os.environ["CUDA_VISIBLE_DEVICES"] = "0, 1, 2, 3" # To force tensorflow to...
run.py
from garcon import activity from garcon import decider from threading import Thread import time import boto3 import workflow # Initiate the workflow on the dev domain and custom_decider name. client = boto3.client('swf', region_name='us-east-1') workflow = workflow.Workflow(client, 'dev', 'custom_decider') deciderwor...
ECS_scheduler_new.py
#!/usr/bin/python3 from __future__ import print_function import os import datetime import configparser import time #import pytz from enum import Enum import paho.mqtt.client as mqtt from threading import Thread from queue import Queue heatMgrQueue = 0 ECS_COMMAND_OFF = b'1' ECS_COMMAND_ON = b'2' lastTemp...
jobs.py
# -*- coding: utf-8 -*- # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software ...
mavros_offboard_posctl_test_rover_v3.py
#!/usr/bin/env python3 import rospy import math import numpy as np from mavros_msgs.msg import Altitude, ExtendedState, State from mavros_msgs.srv import CommandBool, ParamGet, SetMode from geometry_msgs.msg import PoseStamped, Quaternion from pymavlink import mavutil from std_msgs.msg import Header from threading imp...
tests.py
# -*- coding: utf-8 -*- from __future__ import unicode_literals import errno import os import shutil import sys import tempfile import threading import time import unittest from datetime import datetime, timedelta from django.core.cache import cache from django.core.exceptions import SuspiciousFileOperation, Suspicio...
routes_frontend.py
import json import os import re import requests import shlex import socket import subprocess import sys import traceback import uuid from flask import current_app, render_template, request, redirect from pathlib import Path from threading import Thread from time import sleep from . import main from .re...
main.py
import random import requests import time import threading import base64 from termcolor import cprint file1 = open('Groups.txt', 'r') Lines = file1.readlines() file2 = open('People.txt', 'r') Line = file2.readlines() file3 = open('Proxies.txt', 'r') proxies = file3.readlines() file4 = open('UserAgents.txt', 'r') userAg...
stream.py
# coding=utf-8 import tkinter import threading import matplotlib.pyplot as plt from matplotlib.backends.backend_tkagg import FigureCanvasTkAgg from matplotlib.figure import Figure import numpy as np import utils logger = utils.get_logger() class StreamForm(object): def __init__(self, master): self.m...
blocking_rate_limiter_test.py
# Copyright 2019 Scalyr Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, so...
test_subprocess.py
import unittest from unittest import mock from test import support import subprocess import sys import platform import signal import io import os import errno import tempfile import time import selectors import sysconfig import select import shutil import gc import textwrap try: import ctypes except ImportError: ...
exchange_rate.py
from datetime import datetime import inspect import requests import sys import os import json from threading import Thread import time import csv import decimal from decimal import Decimal from .bitcoin import COIN from .i18n import _ from .util import PrintError, ThreadJob, make_dir # See https://en.wikipedia.org/w...
servidor.py
import socket import sys import traceback import time from threading import Thread HOST = 'localhost' # Symbolic name, meaning all available interfaces PORT = 33012 # Arbitrary non-privileged port listaClientes=[] class Mensaje(): def __init__(self,cliente_origen,cliente_destino,mensaje): self.clie...
multiprocess.py
import multiprocessing import time def worker(): name = multiprocessing.current_process().name print(name, 'Starting') time.sleep(100) print(name, 'Exiting') def my_service(): name = multiprocessing.current_process().name print(name, 'Starting') time.sleep(100) print(name, 'Exiting')...
emanemanager.py
""" emane.py: definition of an Emane class for implementing configuration control of an EMANE emulation. """ import copy import logging import os import threading from core import CoreCommandError, utils from core import constants from core.api.tlv import coreapi, dataconversion from core.config import ConfigGroup fr...
operatorInterface.py
#!/usr/bin/python3 import asyncio import threading from hardware import Controller from commands import SonicCommand, StopCommand, EncoderCommand, GyroCommand, VelocityCommand, PursuitCommand class OperatorInterface(): def __init__(self, drive): self.drive = drive self.controller = Controller() ...
weixin.py
# -*- coding: utf-8 -*- """ @author: 杨涛 """ import pymysql import os import random import threading import time import requests from bs4 import BeautifulSoup import json import pandas as pd import numpy as np import matplotlib.pyplot as plt from datetime import datetime from pandas import Series, DataFr...
main_window.py
#!/usr/bin/env python # # Electrum - lightweight Bitcoin client # Copyright (C) 2012 thomasv@gitorious # # Permission is hereby granted, free of charge, to any person # obtaining a copy of this software and associated documentation files # (the "Software"), to deal in the Software without restriction, # including witho...
status_monitor.py
# =============================================================================== # Copyright 2014 Jake Ross # # 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/licens...
classify_images.py
# ClaMDeepNet for classify multiple deep neural network # # Copyright (c) 2017 glmanhtu <glmanhtu@gmail.com> # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including w...
githubcloner.py
#!/usr/bin/env python3 # coding=utf-8 # ******************************************************************* # *** GithubCloner *** # * Description: # A script that clones public Github repositories # of users and organizations automatically. # * Version: # v0.1 # * Homepage: # https://github.com/mazen160/Github...
run_on_bots.py
#!/usr/bin/env python # Copyright 2014 The LUCI Authors. All rights reserved. # Use of this source code is governed under the Apache License, Version 2.0 # that can be found in the LICENSE file. """Automated maintenance tool to run a script on bots. To use this script, write a self-contained python script (use a .zip...
Backup.py
# ---------------------------------------------------------------------- # | # | Backup.py # | # | David Brownell <db@DavidBrownell.com> # | 2017-01-07 09:39:24 # | # ---------------------------------------------------------------------- # | # | Copyright David Brownell 2017-18. # | Distribut...
bert_prediction_generation.py
import json import os import logging import argparse import multiprocessing as mp from python_util.parser.xml.page.page import Page def generate_prediction_json(xml_files, json_path): json_dict = {} for xml_file in xml_files: # load the page xml file page_file = Page(xml_file) page_na...
CuPr_set_temperature.py
import sys import time import numpy as np from multiprocessing import Process, Pipe from PyQt5.QtWidgets import QApplication, QWidget, QVBoxLayout, QDoubleSpinBox, QHBoxLayout, QLabel, QPushButton # import of required devices and general modules # it should be included for possibility of a test run if len(sys.argv) > ...
sideinputs.py
# # Licensed to the Apache Software Foundation (ASF) under one or more # contributor license agreements. See the NOTICE file distributed with # this work for additional information regarding copyright ownership. # The ASF licenses this file to You under the Apache License, Version 2.0 # (the "License"); you may not us...
forces.py
"""Contains the classes that connect the driver to the python code. Copyright (C) 2013, Joshua More and Michele Ceriotti This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the Licen...
startcron.py
#!/usr/bin/python import sys import time import os import getpass import getopt import argparse import re import paramiko import socket import Queue import threading def sshDeploy(retry,hostname): global projectName global user global password global userInsightfinder global licenseKey global ...
test_unix_events.py
"""Tests for unix_events.py.""" import collections import contextlib import errno import io import os import pathlib import signal import socket import stat import sys import tempfile import threading import unittest from unittest import mock from test import support if sys.platform == 'win32': raise unittest.Ski...
lisp.py
# ----------------------------------------------------------------------------- # # Copyright 2013-2019 lispers.net - Dino Farinacci <farinacci@gmail.com> # # 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...
test_mix.py
import pdb import copy import pytest import threading import datetime import logging from time import sleep from multiprocessing import Process import sklearn.preprocessing from milvus import IndexType, MetricType from utils import * dim = 128 index_file_size = 10 collection_id = "test_mix" add_interval_time = 2 vecto...
solver_local.py
# -------------------------------------------------------------------------- # Source file provided under Apache License, Version 2.0, January 2004, # http://www.apache.org/licenses/ # (c) Copyright IBM Corp. 2016, 2017, 2018 # -------------------------------------------------------------------------- # Author: Olivier...
tracker.py
#!/usr/bin/env python # -*- coding: utf-8 -*- from time import time, sleep, mktime import datetime as dt import sched from random import randint import logging from logging.config import dictConfig import sys,os import signal from archery.bow import Daikyu as dict from threading import Timer #import zmq.green as zmq ...
bridge.py
#!/usr/bin/env python # # Copyright (c) 2018-2020 Intel Corporation # # This work is licensed under the terms of the MIT license. # For a copy, see <https://opensource.org/licenses/MIT>. # """ Rosbridge class: Class that handle communication between CARLA and ROS """ try: import queue except ImportError: impor...
ProjectSnapShots.py
#!/usr/bin/env python3 import string from subprocess import call import json import requests import smtplib from datetime import datetime, timedelta import threading GitHubUser = "" xxx = '' orgname = "" st = datetime.now().strftime('%Y-%m-%d') # Returns a list a given element from all git repos (ie, all of their s...
__init__.py
# -*- coding: UTF-8 -*- #virtualBuffers/__init__.py #A part of NonVisual Desktop Access (NVDA) #This file is covered by the GNU General Public License. #See the file COPYING for more details. #Copyright (C) 2007-2017 NV Access Limited, Peter Vágner import time import threading import ctypes import collection...
tcp.py
""" TCP transport classes Wire protocol: "len(payload) msgpack({'head': SOMEHEADER, 'body': SOMEBODY})" """ import errno import logging import os import queue import socket import threading import urllib import salt.ext.tornado import salt.ext.tornado.concurrent import salt.ext.tornado.gen import salt.ext.tornado...
__init__.py
''' PyMOL Molecular Graphics System Copyright (c) Schrodinger, Inc. Supported ways to launch PyMOL: If $PYMOL_PATH is a non-default location, it must be set and exported before launching PyMOL. From a terminal: shell> python /path/to/pymol/__init__.py [args] From a python main thread: >>> # with G...
plugin.py
from contextlib import suppress import io import logging import os import queue import sys import threading from time import sleep import traceback from .threadpool import SpiderFootThreadPool # begin logging overrides # these are copied from the python logging module # https://github.com/python/cpython/blob/main/Lib...
_vis.py
import inspect import os from threading import Thread from ._user_namespace import get_user_namespace, UserNamespace from ._viewer import create_viewer, Viewer from ._vis_base import get_gui, default_gui, Control, display_name, value_range, Action, VisModel, Gui from ..field import SampledField, Scene from ..field._sc...
collection.py
# Copyright 2009-present MongoDB, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in wri...
LoopService.py
import RPi.GPIO as GPIO import pyaudio import wave import numpy import threading import time import logging import math import os import sys import Adafruit_GPIO.SPI as SPI import Adafruit_MCP3008 from LoopChannel import LoopChannel from RecordChannel import RecordChannel from functools import reduce # os.close(sys...
test_s3boto3.py
import gzip import pickle import threading from datetime import datetime from textwrap import dedent from unittest import mock, skipIf from urllib.parse import urlparse from botocore.exceptions import ClientError from django.conf import settings from django.core.exceptions import ImproperlyConfigured from django.core....
external_executor.py
import json import os import pickle import shutil import subprocess import threading import traceback from pathlib import Path from queue import Queue from typing import Optional from .. import ROOT_DIR from ..benchmark.identifier import BenchmarkDescriptor from ..benchmark.result import BenchmarkResult, Failure, Time...
sidebyside.py
import multiprocessing import datetime import time import websocket from pprint import pprint import loghandler import configparser import csv import sys import cbpro from google.protobuf.json_format import MessageToDict from pymongo import MongoClient logger = loghandler.LogHandler().create_logger("sidebyside") co...
test_bot.py
import time import threading import six import pytest import irc.client import irc.bot import irc.server from irc.bot import ServerSpec __metaclass__ = type class TestServerSpec: def test_with_host(self): server_spec = ServerSpec('irc.example.com') assert server_spec.host == 'irc.example.com'...
Start.py
#coding: utf-8 #Source by edit:Slyvanas import re, os, sys, json, time, random, MySQLdb, ftplib, urllib2, socket, sqlite3, threading, traceback, binascii, ConfigParser, time as _time # Others sys.dont_write_bytecode = True sys.path.append(os.path.dirname(os.path.dirname(os.path.abspath(sys.argv[0])))) # Impor...
worker.py
import logging import os import queue import sys import threading import time from .server import Client from .utils import file_mtime log = logging.getLogger('deoplete.jedi.worker') workers = [] work_queue = queue.Queue() comp_queue = queue.Queue() class Worker(threading.Thread): _exc_info = None """Except...
3_atuador.py
#!/usr/bin/env python3 from SocketsTCP.TCP_Client import Client_TCP # Importa o módulo TCP from Serial.Serial_SR import Serial_SR # Importa o módulo Serial from threading import Thread # Importa as Threads from struct import pack # Usado para codificar as mensag...