id
stringlengths
1
265
text
stringlengths
6
5.19M
dataset_id
stringclasses
7 values
/Marmir-0.1.3.tar.gz/Marmir-0.1.3/mm/document_base.py
from document_writers import DocumentWriter from model_base import DataModel from config_base import ConfigBase from serializer_base import Serializer from grid_base import GridBase import logging log = logging.getLogger(__name__) class Document(DocumentWriter): """ Document reporesents the abstact view you ...
PypiClean
/AccessControl-5.5.tar.gz/AccessControl-5.5/HISTORY.rst
Pre 3.0 Changelog ================= 2.13.12 (2012-10-31) -------------------- - LP #1071067: Use a stronger random number generator and a constant time comparison function. 2.13.11 (2012-10-21) -------------------- - LP #966101: Recognize special `zope2.Private` permission in ZCML role directive. 2.13.10 (2012...
PypiClean
/ECPy-1.2.5.tar.gz/ECPy-1.2.5/src/ecpy/formatters.py
#python 2 compatibility from builtins import int,pow def list_formats(): return ("DER","BTUPLE","ITUPLE","RAW","EDDSA") def encode_sig(r,s,fmt="DER",size=0) : """ encore signature according format Args: r (int): r value s (int): s value fmt (str): 'DER'|'BTUPLE'|'ITUPLE'|'RAW...
PypiClean
/AppZoo-2023.4.25.19.12.44.tar.gz/AppZoo-2023.4.25.19.12.44/appzoo/streamlit_app/components_/streamlit_autorefresh/__init__.py
import os import streamlit.components.v1 as components # Create a _RELEASE constant. We'll set this to False while we're developing # the component, and True when we're ready to package and distribute it. # (This is, of course, optional - there are innumerable ways to manage your # release process.) _RELEASE = True #...
PypiClean
/CAMELS_library-0.3.tar.gz/CAMELS_library-0.3/scripts/images_1P/create_images.py
from mpi4py import MPI import numpy as np import sys,os,h5py import MAS_library as MASL sys.path.append('../analysis') import camel_library as CL ###### MPI DEFINITIONS ###### comm = MPI.COMM_WORLD nprocs = comm.Get_size() myrank = comm.Get_rank() #################################### INPUT ########################...
PypiClean
/Eden-2.1.14.zip/Eden-2.1.14/eden/edenLib/openGl/learn/shaders2D/shaders2D.py
import sys import ctypes as ct import numpy as np import math import OpenGL.GL as gl import OpenGL.GLUT as glut windowSize = 400 nrOfTriangles = 6 framesPerSecond = 24 milliSecondsPerFrame = 1000 / framesPerSecond # Must be integer # === Shader source code vertexSource = ''' uniform vec2 aspect; uniform float zoo...
PypiClean
/Caboodle-1.0.2.tar.gz/Caboodle-1.0.2/docs/agents/d3cryp7.md
d3cryp7 ======= d3cryp7 Challenge solving Agents This module is an implementation of the Agent specification and solves a Challenge using API calls to a d3cryp7 server. To use this Agent, create a new instance of it and call the `solve()` function. See the unit tests for this module for more information. - - - - - -...
PypiClean
/DLTKDL-51.0.8-py3-none-any.whl/dltkdl/tabledata/data.py
from ..imports import * from .. import utils as U from . import preprocessor as pp def load_from_dataframe(train_df, label_columns=[], date_columns=[], val_df=None, val_pct=0.1, is_regression=False, max_card=20, random_state=None, verbose=1): train_df = train_df.copy() # strip space f...
PypiClean
/123_object_detection-0.1.tar.gz/123_object_detection-0.1/object_detection/core/anchor_generator.py
from __future__ import absolute_import from __future__ import division from __future__ import print_function from abc import ABCMeta from abc import abstractmethod import six from six.moves import zip import tensorflow.compat.v1 as tf class AnchorGenerator(six.with_metaclass(ABCMeta, object)): """Abstract base cl...
PypiClean
/Ahem-0.2.1.tar.gz/Ahem-0.2.1/ahem/notification.py
from __future__ import unicode_literals from django.utils import timezone from django.template.loader import get_template from django.template import Context, Template from django.db.models.query import EmptyQuerySet from django.contrib.auth.models import AnonymousUser from ahem.tasks import dispatch_to_users from ah...
PypiClean
/MyMessenger-0.3.3-py3-none-any.whl/my_messenger/server/server.py
import sys import select import logging import time from socket import socket, AF_INET, SOCK_STREAM from ..jim.utils import send_message, get_message from ..jim.core import * from ..logger.config import logger_config from ..logger.decorators import Log from ..mongo_db.core import MongoRepo from .chat.chat import Chat ...
PypiClean
/FLAML-2.0.2-py3-none-any.whl/flaml/automl/automl.py
from __future__ import annotations import time import os import sys from typing import Callable, List, Union, Optional from functools import partial import numpy as np import logging import json from flaml.automl.state import SearchState, AutoMLState from flaml.automl.ml import train_estimator from flaml.automl.time_...
PypiClean
/CoCluReMiG-0.1-py3-none-any.whl/cocluremig/analyzer/commit/analyzers.py
from collections import Counter from typing import Dict, Iterable, Set, Union import git from cocluremig.analyzer.commit import aggregators, blob_inspectors from cocluremig.analyzer.commit.base_analyzer import RepoFileMetricAnalyzer def get_basic_commit_data(commit: git.Commit) -> Dict[str, Union[int, str, bool]]: ...
PypiClean
/Euphorie-15.0.2.tar.gz/Euphorie-15.0.2/src/euphorie/client/resources/oira/script/chunks/34113.4d6259241c03c4a9f0fe.min.js
"use strict";(self.webpackChunk_patternslib_patternslib=self.webpackChunk_patternslib_patternslib||[]).push([[34113],{36512:function(n,o,l){var t=l(87537),e=l.n(t),A=l(23645),c=l.n(A)()(e());c.push([n.id,".hljs{display:block;overflow-x:auto;padding:.5em;background:#2e3440}.hljs,.hljs-subst{color:#d8dee9}.hljs-selector-...
PypiClean
/IndianPinCodes-0.0.7.tar.gz/IndianPinCodes-0.0.7/README.md
[![Downloads](https://static.pepy.tech/personalized-badge/indianpincodes?period=total&units=none&left_color=grey&right_color=green&left_text=Downloads)](https://pepy.tech/project/indianpincodes) ![GitHub last commit](https://img.shields.io/github/last-commit/LpCodes/Pincode-Details?style=for-the-badge) ![PyPI](https...
PypiClean
/Moar-3.0.0.tar.gz/Moar-3.0.0/moar/thumbnailer.py
from __future__ import print_function import inspect import os from .engines.wand_engine import WandEngine from .storage import Storage from .thumb import Thumb from .optimage import optimage from .utils import parse_geometry RESIZE_OPTIONS = ('fill', 'fit', 'stretch') DEFAULTS = { 'resize': 'fill', 'upscal...
PypiClean
/0-orchestrator-1.1.0a7.tar.gz/0-orchestrator-1.1.0a7/zeroos/orchestrator/sal/healthchecks/log_rotator.py
import re import os import datetime from ..healthcheck import HealthCheckRun descr = """ Rotate know log files if their size hit 10G or more """ class RotateLogs(HealthCheckRun): def __init__(self, node): resource = '/nodes/{}'.format(node.name) super().__init__('log-rotator', 'Log Rotator', 'Sys...
PypiClean
/DpmModule-1.1.0-py3-none-any.whl/dpmModule/jobs/archmageTc.py
from ..kernel import core from ..kernel.core import VSkillModifier as V from ..character import characterKernel as ck from functools import partial from ..status.ability import Ability_tool from ..execution.rules import RuleSet, SynchronizeRule, ConcurrentRunRule from . import globalSkill from .jobclass import adventur...
PypiClean
/Loden_9000-1.0.0-py3-none-any.whl/Loden1/GridTK.py
from AbsGrid import aGrid, GridParams import tkinter as tk from tkinter import font class GridT(aGrid): def __init__(self, params=GridParams()): super().__init__(params) self._win = None self._cells = [] self._time_lapse = 1000 # milisecond default self._times = 0 ...
PypiClean
/FreePyBX-1.0-RC1.tar.gz/FreePyBX-1.0-RC1/freepybx/public/js/dojox/html/_base.js.uncompressed.js
define("dojox/html/_base", [ "dojo/_base/kernel", "dojo/_base/lang", "dojo/_base/xhr", "dojo/_base/window", "dojo/_base/sniff", "dojo/_base/url", "dojo/dom-construct", "dojo/html", "dojo/_base/declare" ], function (dojo, lang, xhrUtil, windowUtil, has, _Url, domConstruct, htmlUtil) { /* Status: dont know wher...
PypiClean
/Flask_AdminLTE3-1.0.9-py3-none-any.whl/flask_adminlte3/static/plugins/datatables-buttons/js/buttons.flash.min.js
(function(f){"function"===typeof define&&define.amd?define(["jquery","datatables.net","datatables.net-buttons"],function(q){return f(q,window,document)}):"object"===typeof exports?module.exports=function(q,r){q||(q=window);r&&r.fn.dataTable||(r=require("datatables.net")(q,r).$);r.fn.dataTable.Buttons||require("datatabl...
PypiClean
/Geode_GEM-0.12.0-py3-none-any.whl/geode_gem/ui/dialog/viewer.py
# Filesystem from pathlib import Path # GEM from geode_gem.ui.data import Icons from geode_gem.ui.utils import PixbufSize from geode_gem.ui.widgets.window import CommonWindow from geode_gem.widgets import GeodeGtk # GObject from gi.repository import Gdk, GdkPixbuf, GLib, Gtk # Translation from gettext import gettex...
PypiClean
/Faker-19.3.1.tar.gz/Faker-19.3.1/faker/providers/credit_card/fa_IR/__init__.py
from collections import OrderedDict from .. import CreditCard from .. import Provider as CreditCardProvider class Provider(CreditCardProvider): """Implement credit card provider for ``fa_IR`` locale. For all methods that take ``card_type`` as an argument, a random card type will be used if the supplied ...
PypiClean
/MultiEL-0.5.tar.gz/MultiEL-0.5/bela/utils/analysis_utils.py
# This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. from dataclasses import dataclass from typing import Any, Dict, Optional, List @dataclass class Entity: entity_id: str # E.g. "Q3312129" offset: int length: int text: str ...
PypiClean
/KADaP01-2.0.0-py3-none-any.whl/yolov5/utils/autobatch.py
from copy import deepcopy import numpy as np import torch from utils.general import LOGGER, colorstr from utils.torch_utils import profile def check_train_batch_size(model, imgsz=640, amp=True): # Check YOLOv5 training batch size with torch.cuda.amp.autocast(amp): return autobatch(deepcopy(model).tr...
PypiClean
/DDBridgeAccesslib-0.1.0.tar.gz/DDBridgeAccesslib-0.1.0/BridgeAccesslib/comm.py
import ctypes import numpy as np import numpy.typing as npt import logging # Typing NDArrayUint32 = npt.NDArray[np.uint32] class AcqInfo(ctypes.Structure): _fields_ = [("pulses_width", ctypes.c_uint32), ("pulses", ctypes.c_uint32), ("timer_reg", ctypes.c_uint16), (...
PypiClean
/Blue-DiscordBot-3.2.0.tar.gz/Blue-DiscordBot-3.2.0/bluebot/core/commands/help.py
from collections import namedtuple from typing import Union, List, AsyncIterator, Iterable, cast import discord from discord.ext import commands as dpy_commands from . import commands from .context import Context from ..i18n import Translator from ..utils import menus, fuzzy_command_search, format_fuzzy_results from...
PypiClean
/Glances-3.4.0.3.tar.gz/Glances-3.4.0.3/glances/autodiscover.py
import socket import sys from glances.globals import BSD from glances.logger import logger try: from zeroconf import __version__ as __zeroconf_version, ServiceBrowser, ServiceInfo, Zeroconf zeroconf_tag = True except ImportError: zeroconf_tag = False # Zeroconf 0.17 or higher is needed if zeroconf_tag: ...
PypiClean
/Interpretability-0.0.3-py3-none-any.whl/interpretability/model/SLIM/slim/create_slim_IP.py
import cplex import numpy as np from math import ceil, floor from .helper_functions import * from .SLIMCoefficientConstraints import SLIMCoefficientConstraints def create_slim_IP(input, print_flag = False): """ :param input: dictionary with the following keys %Y N x 1 np.array of labels (-1 or 1 o...
PypiClean
/FALCONN-1.3.1.tar.gz/FALCONN-1.3.1/external/pybind11/docs/advanced/misc.rst
Miscellaneous ############# .. _macro_notes: General notes regarding convenience macros ========================================== pybind11 provides a few convenience macros such as :func:`PYBIND11_MAKE_OPAQUE` and :func:`PYBIND11_DECLARE_HOLDER_TYPE`, and ``PYBIND11_OVERLOAD_*``. Since these are "just" macros that ...
PypiClean
/Caboodle-1.0.2.tar.gz/Caboodle-1.0.2/docs/challenges/spec.md
Spec ==== Specifications for Challenge objects This module defines abstract classes with compounding levels of functionality. Every Challenge should have a `get_data()` and `submit_data()` function. These specifications can not be instantiated and can only be used by a subclass that implements all of the required fun...
PypiClean
/CrawlerCodePythonTools-1.5.4.tar.gz/CrawlerCodePythonTools-1.5.4/pythontools/core/logger.py
from colorama import init from colorama import Fore, Back, Style import time, os, stdiomask from pythontools.core import tools init() logs = [] logPath = "" logFile = "" timeFormat = "%H:%M:%S" def init_log(path): global logFile, logPath logPath = path logFile = path + "/" + time.strftime("log_%Y_%m_%d_...
PypiClean
/CellProfiler-4.2.6.tar.gz/CellProfiler-4.2.6/cellprofiler/gui/preferences_view/_progress_watcher.py
import time import numpy import wx class ProgressWatcher: """ Tracks pipeline progress and estimates time to completion """ def __init__(self, parent, update_callback, multiprocessing=False): self.update_callback = update_callback # start tracking progress self.start_time = time.time...
PypiClean
/ONE-api-2.2.2.tar.gz/ONE-api-2.2.2/one/remote/base.py
from abc import abstractmethod import logging from iblutil.io import params as iopar from one.params import _PAR_ID_STR """tuple: Default order of precedence for download protocol""" PROC_PRECEDENCE = ('aws', 'http', 'globus', 'kachary') ALYX_JSON = { 'access_protocol': { ('aws', 'http', 'kachary', 'glob...
PypiClean
/3d-connectX-env-1.0.1.tar.gz/3d-connectX-env-1.0.1/README.md
# 3d-connectX-env [![BuildStatus][build-status]][ci-server] [![PackageVersion][pypi-version]][pypi-home] [![Stable][pypi-status]][pypi-home] [![Format][pypi-format]][pypi-home] [![License][pypi-license]](LICENSE) ![pattern1.gif](assets/pattern1.gif) [build-status]: https://travis-ci.com/youngeek-0410/3d-connectX-env...
PypiClean
/Mopidy-Mobile-1.10.0.tar.gz/Mopidy-Mobile-1.10.0/CHANGELOG.rst
1.10.0 2020-11-18 ----------------- - Require Android 5.1 or greater for Cordova app. - Add Dutch translation (courtesy of wimpie). - Update dependencies. 1.9.1 2019-12-05 ---------------- - Remove deprecated Mopidy Core API parameters. - Officially support Python 3. - Update dependencies. 1.9.0 2019-05-29 --...
PypiClean
/CellProfiler-4.2.6.tar.gz/CellProfiler-4.2.6/cellprofiler/gui/preferences_dialog/_preferences_dialog.py
import os import sys import matplotlib.cm import wx import wx.lib.scrolledpanel from cellprofiler_core.preferences import ALWAYS_CONTINUE_HELP from cellprofiler_core.preferences import CONSERVE_MEMORY_HELP from cellprofiler_core.preferences import DEFAULT_COLORMAP_HELP from cellprofiler_core.preferences import DEFAULT...
PypiClean
/Binner-0.3.0.tar.gz/Binner-0.3.0/binner/runtime_web_api.py
import cherrypy class RuntimeWebAPI(object): @cherrypy.expose @cherrypy.tools.json_in() def smallest(self, **params): json_request = cherrypy.request.json try: if isinstance(json_request, dict) and 'items' in json_request.keys() and 'bins' in json_request.keys(): items = enumerate_json(json_...
PypiClean
/D-Analyst-1.0.6.tar.gz/D-Analyst-1.0.6/main/analyst/glrenderer.py
try: import OpenGL.GL as gl except: from analyst import log_warn log_warn(("PyOpenGL is not available and Analyst won't be" " able to render plots.")) class _gl(object): def mock(*args, **kwargs): return None def __getattr__(self, name): return self.mock ...
PypiClean
/Flask-Restless-Zx-0.20.0.tar.gz/Flask-Restless-Zx-0.20.0/flask_restless/views.py
from __future__ import division from collections import defaultdict from functools import wraps import math import warnings from flask import current_app from flask import json from flask import jsonify as _jsonify from flask import request from flask.views import MethodView from mimerender import FlaskMimeRender fro...
PypiClean
/AbPyTools-0.3.2.tar.gz/AbPyTools-0.3.2/abpytools/analysis/sequence_alignment.py
from .analysis_helper_functions import load_alignment_algorithm, load_substitution_matrix class SequenceAlignment: """ Sequence alignment with two chain objects """ def __init__(self, target, collection, algorithm, substitution_matrix): """ :param chain_1: :para...
PypiClean
/M_Shape_AB_Ratio-0.0.1.post1.tar.gz/M_Shape_AB_Ratio-0.0.1.post1/src/ab_ratio/predict.py
import os, argparse from .detectFacialFeatures import process import shutil import pandas as pd import numpy as np import cv2 from pathlib import Path SRC_DIR = Path(__file__).resolve().parent.parent def main(args): file_path = [] top_to_hair = [] top_to_chin = [] a_b_ratio = [] black_overall = [] resul...
PypiClean
/Mathics_Django-6.0.0-py3-none-any.whl/mathics_django/web/media/js/mathjax/jax/output/SVG/fonts/Gyre-Pagella/Size6/Regular/Main.js
MathJax.OutputJax.SVG.FONTDATA.FONTS.GyrePagellaMathJax_Size6={directory:"Size6/Regular",family:"GyrePagellaMathJax_Size6",id:"GYREPAGELLASIZE6",32:[0,0,250,0,0,""],40:[1458,958,679,143,583,"583 1430c-245 -246 -360 -593 -360 -981v-398c0 -388 115 -735 360 -981c-6 -3 -11 -7 -16 -12s-9 -10 -12 -16c-256 256 -412 605 -412 1...
PypiClean
/NanoStat-1.6.0.tar.gz/NanoStat-1.6.0/nanostat/NanoStat.py
from nanomath import write_stats import nanoget from argparse import ArgumentParser, HelpFormatter import os import sys from nanostat.version import __version__ import textwrap as _textwrap class CustomHelpFormatter(HelpFormatter): def _format_action_invocation(self, action): if not action.option_strings ...
PypiClean
/MaterialDjango-0.2.5.tar.gz/MaterialDjango-0.2.5/bower_components/paper-slider/README.md
[![Build status](https://travis-ci.org/PolymerElements/paper-slider.svg?branch=master)](https://travis-ci.org/PolymerElements/paper-slider) ## <paper-slider> Material design: [Sliders](https://www.google.com/design/spec/components/sliders.html) `paper-slider` allows user to select a value from a range of value...
PypiClean
/Mathics_Django-6.0.0-py3-none-any.whl/mathics_django/web/media/js/mathjax/jax/output/HTML-CSS/config.js
MathJax.OutputJax["HTML-CSS"]=MathJax.OutputJax({id:"HTML-CSS",version:"2.7.9",directory:MathJax.OutputJax.directory+"/HTML-CSS",extensionDir:MathJax.OutputJax.extensionDir+"/HTML-CSS",autoloadDir:MathJax.OutputJax.directory+"/HTML-CSS/autoload",fontDir:MathJax.OutputJax.directory+"/HTML-CSS/fonts",webfontDir:MathJax.O...
PypiClean
/MetaCalls-0.0.5-cp310-cp310-manylinux2014_x86_64.whl/metacalls/node_modules/@types/node/url.d.ts
declare module 'url' { import { Blob as NodeBlob } from 'node:buffer'; import { ClientRequestArgs } from 'node:http'; import { ParsedUrlQuery, ParsedUrlQueryInput } from 'node:querystring'; // Input to `url.format` interface UrlObject { auth?: string | null | undefined; hash?: string...
PypiClean
/FirstAlexaSkills-0.2.0.tar.gz/FirstAlexaSkills-0.2.0/docs/tutorials.rst
=================================================== Examples of creating Alexa third-party skills (ASK) =================================================== First Alexa Skill (alexa_skill_first) ===================================== **Challenge:** Create your first Alexa third-party skill with the following features:...
PypiClean
/Flask-CKEditor-0.4.6.tar.gz/Flask-CKEditor-0.4.6/flask_ckeditor/static/standard/plugins/codesnippet/lib/highlight/README.md
# Highlight.js Highlight.js highlights syntax in code examples on blogs, forums and, in fact, on any web page. It's very easy to use because it works automatically: finds blocks of code, detects a language, highlights it. Autodetection can be fine tuned when it fails by itself (see "Heuristics"). ## Basic usage Li...
PypiClean
/Djaloha-0.4.2.tar.gz/Djaloha-0.4.2/djaloha/static/aloha.0.20/plugins/community/colorselector/lib/colorselector-plugin.js
define( [ 'aloha', 'aloha/jquery', 'aloha/plugin', 'aloha/floatingmenu', 'i18n!colorselector/nls/i18n', 'i18n!aloha/nls/i18n', 'css!colorselector/css/colorselector.css'], function (Aloha, jQuery, Plugin, FloatingMenu,i18n, i18nCore){ "use strict"; var GENTICS = window.GENTICS, $ = jQuery, ns = '...
PypiClean
/MezzanineFor1.7-3.1.10.tar.gz/MezzanineFor1.7-3.1.10/mezzanine/core/admin.py
from __future__ import unicode_literals from django.contrib import admin from django.contrib.auth import get_user_model from django.contrib.auth.admin import UserAdmin from django.forms import ValidationError, ModelForm from django.http import HttpResponseRedirect from django.shortcuts import redirect from django.util...
PypiClean
/FrameDuino-0.2.1.tar.gz/FrameDuino-0.2.1/frameduino/__init__.py
import time #CONSTANTS HIGH = "HIGH" LOW = "LOW" INPUT = "INPUT" OUTPUT = "OUTPUT" #ERRORS DRIVER_NOT_DEFINED = "Driver is not defined" # -1 class Pinguino(): pinCount = 17 driver = None debug = False def __init__(self, driver=None): if (driver != None): self.setDriver(d...
PypiClean
/AuthoritySpoke-0.9.1-py3-none-any.whl/authorityspoke/rules.py
from __future__ import annotations from copy import deepcopy from typing import Any, ClassVar, Dict, Iterator from typing import Optional, Sequence, Tuple, Union from pydantic import BaseModel, ValidationError from pydantic.class_validators import validator from legislice.enactments import Enactment, EnactmentPassag...
PypiClean
/GenIce-1.0.11.tar.gz/GenIce-1.0.11/genice/lattices/EMT.py
from genice.cell import cellvectors cell = cellvectors(a=15.621810598341442, b=15.621810598341442, c=25.483106896463806, C=120.0) waters = [ [0.15499999999999936, 0.6664999999999992, 0.30429999999999957], [0.3335000000000008, 0.48850000000000016, 0.3042999999999...
PypiClean
/Netzob-2.0.0.tar.gz/Netzob-2.0.0/src/netzob/Model/Vocabulary/AbstractField.py
#+---------------------------------------------------------------------------+ #| 01001110 01100101 01110100 01111010 01101111 01100010 | #| | #| Netzob : Inferring communication protocols | #+-...
PypiClean
/OBP_reliability_pillar_3-0.0.13.tar.gz/OBP_reliability_pillar_3-0.0.13/OBP_reliability_pillar_4/dynamodb/dynamodb_pitr_enabled.py
import logging from botocore.exceptions import ClientError from OBP_reliability_pillar_4.dynamodb.utils import list_dynamodb_tables logging.basicConfig(level=logging.INFO) logger = logging.getLogger() # Checks compliance for dynamodb-pitr-enabled def dynamodb_pitr_enabled(self) -> dict: """ :param self: ...
PypiClean
/dragonflow-4.0.0.tar.gz/dragonflow-4.0.0/doc/source/specs/redis_availability.rst
.. This work is licensed under a Creative Commons Attribution 3.0 Unsuported License. http://creativecommons.org/licenses/by/3.0/legalcode ================== Redis Availability ================== This spec describe the design of availability of Redis of DragonFlow. Problem Description =================== Dragon...
PypiClean
/CDS-1.0.1.tar.gz/CDS-1.0.1/cds/modules/deposit/loaders/loader.py
from __future__ import absolute_import import json from flask import request, has_request_context, current_app from invenio_rest.errors import RESTValidationError def _doi_context(): """Configure DOI Context.""" # Replace refs when we are in request context. context = dict(replace_refs=has_request_conte...
PypiClean
/IPRA-3.17.51-py3-none-any.whl/ipra/View2/checkForUpdateTopLevel.py
import subprocess import sys import threading from tkinter import messagebox import customtkinter import pkg_resources import requests from ConfigUtility import GetConfigSingletion from StringUtilityCTK import GetStringSingletionCTK class CheckForUpdateTopLevel(customtkinter.CTkToplevel): required = ['selenium',...
PypiClean
/Finance-Ultron-1.0.8.1.tar.gz/Finance-Ultron-1.0.8.1/ultron/ump/factor/buy/buy_dm.py
import math import numpy as np from ultron.ump.core.helper import pd_resample from ultron.ump.factor.buy.base import FactorBuyXD, BuyCallMixin from ultron.ump.technical.line import Line from ultron.ump.indicator.ma import calc_ma_from_prices class DoubleMaBuy(FactorBuyXD, BuyCallMixin): """示例买入动态自适应双均线策略""" ...
PypiClean
/HAL_9000-4.0.0.tar.gz/HAL_9000-4.0.0/HAL_9000/neural_network.py
import numpy as np import progressbar from terminaltables import AsciiTable from HAL_9000.utils import batch_iterator, bar_widgets class Brain: def __init__(self, loss, opt, val_data=None): self.layers = [] self.loss_fn = loss() self.opt = opt self.losses = {"train_loss": [], "val_...
PypiClean
/DIMEpy-1.0.1.tar.gz/DIMEpy-1.0.1/README.md
# DIMEpy: Direct Infusion MEtablomics processing in python [![Project Status: Active - The project has reached a stable, usable state and is being actively developed.](http://www.repostatus.org/badges/0.1.0/active.svg)](http://www.repostatus.org/#active) ![PyPI - Python Version](https://img.shields.io/pypi/pyversions/...
PypiClean
/MDCatch-2.5-py3-none-any.whl/mdcatch/external_job_cryolo_train.py
import argparse import json import os import time import subprocess from emtable import Table # run "pip3 install --user emtable" for system python CONDA_ENV = ". /home/gsharov/rc/conda.rc && conda activate cryolo-1.9.3" CRYOLO_TRAIN = "cryolo_train.py" CRYOLO_GEN_MODEL = "/home/gsharov/soft/cryolo/gmodel_phosnet_20...
PypiClean
/OASYS1-SRW-1.1.106.tar.gz/OASYS1-SRW-1.1.106/orangecontrib/srw/util/scanning_gui.py
import numpy from PyQt5.QtWidgets import QWidget, QVBoxLayout from PyQt5.QtCore import Qt from matplotlib import cm, rcParams from oasys.widgets.gui import FigureCanvas3D from matplotlib.figure import Figure from matplotlib.collections import LineCollection from matplotlib.colors import colorConverter, ListedColormap...
PypiClean
/Lemon-Library-3.7.0b0.tar.gz/Lemon-Library-3.7.0b0/Lemon/create_lemon_app.py
from os import mkdir, chdir import argparse parser = argparse.ArgumentParser(description='Create a Lemon app.') parser.add_argument('app_name', metavar='app_name', type=str) parser.add_argument('--version', action='version', version='V.1.0.0') app_code = """from Lemon.components import Component from Lemon.Server.se...
PypiClean
/DI_engine-0.4.9-py3-none-any.whl/ding/utils/default_helper.py
from typing import Union, Mapping, List, NamedTuple, Tuple, Callable, Optional, Any, Dict import copy from ditk import logging import random from functools import lru_cache # in python3.9, we can change to cache import numpy as np import torch import treetensor.torch as ttorch def get_shape0(data: Union[List, Dict, ...
PypiClean
/CslBot-0.21-py3-none-any.whl/cslbot/helpers/config.py
import configparser import re from os import mkdir from os.path import dirname, exists, join from pkg_resources import Requirement, resource_string from typing import Callable try: _config_file except NameError: _config_file = None # type: str def migrate_config(config_file, config_obj, send): exampl...
PypiClean
/KE-py-0.9.tar.gz/KE-py-0.9/KE/v3/user.py
from __future__ import with_statement, print_function, absolute_import from KE.base import Base class User(Base): def __init__(self, client=None, name=''): """User Object """ super(User, self).__init__(client=client) self.name = name @classmethod def from_json(cls, client...
PypiClean
/CAVA-2.0.7-py3-none-any.whl/cava/ensembldb/main_refseq.py
import datetime import gzip import os import pickle import sys from operator import itemgetter import pybedtools import requests import wget requests.packages.urllib3.disable_warnings() import pysam from cmmodule.utils import read_chain_file from cmmodule.mapgff import crossmap_gff_file failed_conversions = dict() ...
PypiClean
/Mopidy-GPIOcont-0.2.2.tar.gz/Mopidy-GPIOcont-0.2.2/mopidy_gpiocont/in_gpio.py
import logging logger = logging.getLogger(__name__) try: import RPi.GPIO as GPIO except ImportError: logger.error("GPIOcont: Could not open GPIO") logger.debug("GPIOcont: input_gpio.py called.") class in_GPIO(): def __init__(self, frontend, conf): self.frontend = frontend self.conf = ...
PypiClean
/KL_Audit_supportV2.6-1.0-py3-none-any.whl/AuditModule/core/applications/AuditManagement.py
import inspect from AuditModule.core.applications import Annotations from AuditModule.util import Logging as LOGG from AuditModule.common import AppConstants # from bin.util import CommonUtils from AuditModule.core.applications import AuditManagementModules from AuditModule.core.persistences import PersistenceAdaptor i...
PypiClean
/Heterogeneous_Highway_Env-0.0.3-py3-none-any.whl/src/vehicle/behavior.py
from typing import Tuple, Union import numpy as np from highway_env.road.road import Road, Route, LaneIndex from highway_env.utils import Vector from highway_env.vehicle.controller import ControlledVehicle from highway_env import utils from highway_env.vehicle.kinematics import Vehicle class IDMVehicle(ControlledVe...
PypiClean
/ChemDataExtractor-1.3.0-py3-none-any.whl/chemdataextractor/doc/document.py
from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals from abc import ABCMeta, abstractproperty import collections import io import json import logging import six from ..utils import python_2_unicode_compatible from .text ...
PypiClean
/MyQuery-0.0.6.tar.gz/MyQuery-0.0.6/README.md
# MyQuery ## 简介 基于 mysql-connector-python 的一个封装,提供了更简易的操作接口 基于 mysql-connector-python 文档:[文档](https://dev.mysql.com/doc/connector-python/en/connector-python-connectargs.html) ## 安装 ```bash pip install myquery ``` ## 使用示例 ### 1、数据库建表 ```sql CREATE TABLE `person` ( `id` int(11) NOT NULL AUTO_INCREMENT, `age` in...
PypiClean
/Cartopy-0.22.0-cp310-cp310-macosx_11_0_arm64.whl/cartopy/io/img_tiles.py
from abc import ABCMeta, abstractmethod import concurrent.futures import io from pathlib import Path import warnings from PIL import Image import numpy as np import shapely.geometry as sgeom import cartopy import cartopy.crs as ccrs class GoogleWTS(metaclass=ABCMeta): """ Implement web tile retrieval using ...
PypiClean
/Lasco-0.1.0.tar.gz/Lasco-0.1.0/docs/_build/html/_static/websupport.js
(function($) { $.fn.autogrow = function() { return this.each(function() { var textarea = this; $.fn.autogrow.resize(textarea); $(textarea) .focus(function() { textarea.interval = setInterval(function() { $.fn.autogrow.resize(textarea); }, 500); }) .blur(fu...
PypiClean
/FP-SMC-ALS-test1-0.0.1.tar.gz/FP-SMC-ALS-test1-0.0.1/smc/routing/route_map.py
import collections from smc.base.model import Element, ElementCreator, SubElement from smc.base.collection import rule_collection from smc.policy.rule import RuleCommon from smc.api.exceptions import CreateRuleFailed Metric = collections.namedtuple("Metric", "value") """ A metric is a simple namedtuple for returning ...
PypiClean
/GraphLab_Create-2.1-cp27-none-macosx_10_5_x86_64.macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.macosx_10_11_intel.macosx_10_11_x86_64.whl/graphlab/mxnet/context.py
"""Context management API of mxnet.""" from __future__ import absolute_import class Context(object): """Constructing a context. Parameters ---------- device_type : {'cpu', 'gpu'} or Context. String representing the device type device_id : int (default=0) The device id of the devic...
PypiClean
/Flask-CDN-Auto-1.5.4.tar.gz/Flask-CDN-Auto-1.5.4/README.md
# Flask-CDN [![Version](https://img.shields.io/pypi/v/flask-cdn.svg)](https://pypi.python.org/pypi/Flask-CDN) [![Build Status](https://travis-ci.org/libwilliam/flask-cdn.png)](https://travis-ci.org/libwilliam/flask-cdn) [![Coverage](https://coveralls.io/repos/libwilliam/flask-cdn/badge.svg)](https://coveralls.io/githu...
PypiClean
/EXtra_redu-0.0.8-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl/extra_redu/litfrm/selection.py
import numpy as np from enum import IntEnum from .utils import ( find_runs, find_ranges_of_patterns, compress_ranges_of_patterns, expand_ranges_of_cells, find_ranges, ) def row_selection(ptrn, rowsize=32): """Expand cell selection to row selection""" single = ptrn.ndim == 1 nfrm = ptrn.size if sin...
PypiClean
/KeyboardPaster-0.1.6-py3-none-any.whl/keyboardpaster/app.py
import time import re import json import pkg_resources from pynput.keyboard import Controller, Key from kivy.app import App from kivy.factory import Factory from kivy.properties import ObjectProperty, StringProperty from kivy.uix.textinput import TextInput from kivy.lang import Builder from kivy.clock import Clock fr...
PypiClean
/OPAF-0.9.2.tar.gz/OPAF-0.9.2/opaflib/lzw.py
__author__ = "Joe Bowers" __license__ = "MIT License" __version__ = "0.01.01" __status__ = "Development" __email__ = "joerbowers@gmail.com" __url__ = "http://www.joe-bowers.com/static/lzw" import struct import itertools CLEAR_CODE = 256 END_OF_INFO_CODE = 257 DEFAULT_MIN_BITS = 9 DEFAULT_MAX_BITS = 12 def compr...
PypiClean
/NREL-phygnn-0.0.24.tar.gz/NREL-phygnn-0.0.24/phygnn/model_interfaces/random_forest_model.py
import json import logging import numpy as np import pprint import os from sklearn.ensemble import RandomForestRegressor from phygnn.model_interfaces.base_model import ModelBase from phygnn.utilities.pre_processing import PreProcess logger = logging.getLogger(__name__) class RandomForestModel(ModelBase): """ ...
PypiClean
/Nitrous-0.9.3-py3-none-any.whl/turbogears/i18n/data/he_IL.py
languages={'el': u'\u05d9\u05d5\u05d5\u05e0\u05d9\u05ea', 'en': u'\u05d0\u05e0\u05d2\u05dc\u05d9\u05ea', 'zh': u'\u05e1\u05d9\u05e0\u05d9\u05ea', 'it': u'\u05d0\u05d9\u05d8\u05dc\u05e7\u05d9\u05ea', 'ar': u'\u05e2\u05e8\u05d1\u05d9\u05ea', 'cs': u"\u05e6'\u05db\u05d9\u05ea", 'et': u'\u05d0\u05e1\u05d8\u05d5\u05e0\u05d...
PypiClean
/CleanAdminDjango-1.5.3.1.tar.gz/CleanAdminDjango-1.5.3.1/django/template/debug.py
from django.template.base import Lexer, Parser, tag_re, NodeList, VariableNode, TemplateSyntaxError from django.utils.encoding import force_text from django.utils.html import escape from django.utils.safestring import SafeData, EscapeData from django.utils.formats import localize from django.utils.timezone import templ...
PypiClean
/ConTexto-0.2.0-py3-none-any.whl/contexto/utils/pre_ocr.py
import cv2 import matplotlib.pyplot as plt import numpy as np # Función auxiliar para graficar las imágenes def graficar_img(img, titulo="", dims=(15, 10)): """Función que grafica y muestra una imagen con Pyplot de Matplotlib. :param img: (numpy array). Imagen que se desea graficar :param titulo: (strin...
PypiClean
/ConceptNet-5.7.0.tar.gz/ConceptNet-5.7.0/conceptnet5/support_data/rw/README.txt
########################################################################################## # Stanford Rare Word (RW) Similarity Dataset # Minh-Thang Luong, Richard Socher, and Christopher D. Manning. # Computer Science Department # Stanford University ###################################################################...
PypiClean
/HalRing_Lib-1.1.0-py3-none-any.whl/halring/xml/xml_util.py
import xml.etree.ElementTree as et import xml.dom.minidom as mn # import numpy as np # import pandas as pd from collections import defaultdict from functools import reduce class XmlUtil(object): def __init__(self, xml_file): self._xml_file = xml_file def analysis_key_get_value(self, root_tag, tag_key...
PypiClean
/DiffCapAnalyzer-0.1.1.tar.gz/DiffCapAnalyzer-0.1.1/README.md
# DiffCapAnalyzer [![Build Status](https://travis-ci.com/nicolet5/DiffCapAnalyzer.svg?branch=master)](https://travis-ci.com/nicolet5/DiffCapAnalyzer) ![Python status](https://img.shields.io/badge/python-3.6%20%7C%203.7%20%7C%203.8-blue) ## Package for Battery Cycling Data Visualization and Analysis This package is inte...
PypiClean
/AlienInvasion_Raph692-0.1.0-py3-none-any.whl/sideways_shooter/ss_ship.py
import pygame class Ship: """A class to manage the behaviour of the player's ship.""" def __init__(self, ai_settings, screen): """Initialize the ship and set its starting position.""" self.screen = screen # Load the ship image and get its rect. self.image = pygame.image.load(...
PypiClean
/CWR-API-0.0.40.tar.gz/CWR-API-0.0.40/docs/source/cwr_standard/field_format.rst
================ CWR field format ================ CWR records are divided into fields, each following a clear pattern, which consists on defining the following properties: - Field name - Start index - Size - Format The field name is used only to help humans identifying the field, while the start index and size serv...
PypiClean
/AndN-0.2.3.tar.gz/AndN-0.2.3/AndroidQQ/package/head.py
import json from random import randint from AndTools import pack_b, get_random_bin, TEA from Jce_b import JceWriter, JceReader from pyproto import ProtoBuf def Pack_(info, data, Types, encryption, sso_seq=None, token=False): """组包 Types:包类型 通常是10 和11 encryption 加密方式 2 不需要token 1需要token sso_seq 包...
PypiClean
/FamcyDev-0.3.71-py3-none-any.whl/Famcy/bower_components/bootstrap/site/content/docs/5.0/migration.md
--- layout: docs title: Migrating to v5 description: Track and review changes to the Bootstrap source files, documentation, and components to help you migrate from v4 to v5. group: migration aliases: "/migration/" toc: true --- ## Dependencies - Dropped jQuery. - Upgraded from Popper v1.x to Popper v2.x. - Replaced L...
PypiClean
/GLAM-0.3.7-py3-none-any.whl/glam/matching/siamese/_dataset.py
import tensorflow as tf import pandas as pd import numpy as np from scipy.spatial import KDTree import string, re import os import random from tqdm import tqdm tqdm.pandas() from glam.utils import lookups, typo from glam.utils.utils import choose, build_address from glam.matcher import predict def generate_unit(s): ...
PypiClean
/Django-Pushy-1.0.2.tar.gz/Django-Pushy-1.0.2/pushy/models.py
import copy import json from django.conf import settings from django.db import models from django.utils.translation import ugettext_lazy as _ class PushNotification(models.Model): PUSH_INACTIVE = 0 PUSH_ACTIVE = 1 PUSH_NOT_SENT = 0 PUSH_SENT = 1 PUSH_IN_PROGRESS = 2 PUSH_CHOICES = ( ...
PypiClean
/Nuitka_winsvc-1.7.10-cp310-cp310-win_amd64.whl/nuitka/build/inline_copy/lib/scons-4.3.0/SCons/SConf.py
import SCons.compat import atexit import io import os import re import sys import traceback import SCons.Action import SCons.Builder import SCons.Errors import SCons.Job import SCons.Node.FS import SCons.Taskmaster import SCons.Util import SCons.Warnings import SCons.Conftest from SCons.Debug import Trace from colle...
PypiClean
/GraphLab_Create-2.1-cp27-none-macosx_10_5_x86_64.macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.macosx_10_11_intel.macosx_10_11_x86_64.whl/graphlab/toolkits/regression/_regression.py
import graphlab as _graphlab import graphlab.connect as _mt from graphlab.toolkits import _supervised_learning as _sl def create(dataset, target, features=None, validation_set = 'auto', verbose=True): """ Automatically create a suitable regression model based on the provided training data. To ...
PypiClean
/Bis-Miner-3.11.1.tar.gz/Bis-Miner-3.11.0/Orange/canvas/gui/splashscreen.py
from AnyQt.QtWidgets import QSplashScreen, QWidget, QApplication from AnyQt.QtGui import ( QPixmap, QPainter, QTextDocument, QTextBlockFormat, QTextCursor ) from AnyQt.QtCore import Qt from .utils import is_transparency_supported if hasattr(Qt, "mightBeRichText"): mightBeRichText = Qt.mightBeRichText else: ...
PypiClean
/ICP-2.1.1.tar.gz/ICP-2.1.1/ExamplesICPImageScanner/README
README for ExamplesICPImageScanner Directory ******************************************** This directory contains the following scripts: 1) RunICPImageScanner.py This example script illustrates how to use the ICPImageScanner class in the ICP module. This script scans tw...
PypiClean
/GooeyPy-0.2.tar.gz/GooeyPy-0.2/gooeypy/selectbox.py
import pygame from const import * import box import label import widget try: set except NameError: from sets import Set as set from cellulose import * class SelectBox(box.VBox): """ SelectBox([multiple, [expand]]) -> SelectBox widget ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Subcl...
PypiClean