id
stringlengths
1
265
text
stringlengths
6
5.19M
dataset_id
stringclasses
7 values
/MindsDB-23.8.3.0.tar.gz/MindsDB-23.8.3.0/mindsdb/integrations/handlers/replicate_handler/replicate_handler.py
import replicate import pandas as pd from mindsdb.integrations.libs.base import BaseMLEngine from typing import Dict, Optional import os import types from mindsdb.utilities.config import Config class ReplicateHandler(BaseMLEngine): name = "replicate" @staticmethod def create_validation(target, args=None,...
PypiClean
/Kamaelia-0.6.0.tar.gz/Kamaelia-0.6.0/Examples/SoC2006/RJL/P2PStreamPeer/p2pstreampeer.py
import time from Axon.Component import component from Kamaelia.Chassis.Pipeline import Pipeline from Kamaelia.File.Writing import SimpleFileWriter from Kamaelia.File.TriggeredFileReader import TriggeredFileReader from Kamaelia.Protocol.HTTP.HTTPClient import SimpleHTTPClient from Kamaelia.Protocol.Torrent.TorrentP...
PypiClean
/Mopidy-Podcast-3.0.1.tar.gz/Mopidy-Podcast-3.0.1/mopidy_podcast/feeds.py
import datetime import email.utils import re import uritools from mopidy import models from . import Extension try: import xml.etree.cElementTree as ElementTree except ImportError: import xml.etree.ElementTree as ElementTree def parse(source): if isinstance(source, str): url = uritools.uricompo...
PypiClean
/ModbusGuiApp-1.1-py3-none-any.whl/modbus_gui_app/database/db_handler.py
import asyncio import json import logging import sqlite3 from concurrent.futures.thread import ThreadPoolExecutor class Backend: """ This class is used to instantiate a connection to the database and provides the methods needed to deal with that connection. """ def __init__(self): self._c...
PypiClean
/Calamari-1.0.3.tar.gz/Calamari-1.0.3/calamari/interfaces/irc_interface.py
from calamari.interfaces import CalamariInterface from twisted.words.protocols import irc from twisted.internet import reactor, protocol, ssl from threading import Thread class IRCBot( irc.IRCClient ): def connectionMade(self): irc.IRCClient.connectionMade(self) def connectionLost(self, reason): ...
PypiClean
/NetComp-0.2.3.tar.gz/NetComp-0.2.3/netcomp/linalg/matrices.py
from scipy import sparse as sps from scipy.sparse import issparse import numpy as np _eps = 10**(-10) # a small parameter ###################### ## Helper Functions ## ###################### def _flat(D): """Flatten column or row matrices, as well as arrays.""" if issparse(D): raise ValueError('Cann...
PypiClean
/Bubot_WebServer-0.1.15-py3-none-any.whl/BubotObj/OcfDevice/subtype/WebServer/APImixin/Resource.py
from aiohttp.web import json_response, Response from Bubot.Core.DeviceLink import DeviceLink from Bubot.Helpers import Helper class Resource: @staticmethod async def action_get_list(request): result = dict( items=[] ) if not request.query.get('items_only'): resu...
PypiClean
/Django_patch-2.2.19-py3-none-any.whl/django/template/loader_tags.py
import posixpath from collections import defaultdict from django.utils.safestring import mark_safe from .base import ( Node, Template, TemplateSyntaxError, TextNode, Variable, token_kwargs, ) from .library import Library register = Library() BLOCK_CONTEXT_KEY = 'block_context' class BlockContext: def __in...
PypiClean
/ChaCha20-1.1.1.tar.gz/ChaCha20-1.1.1/README.md
# ChaCha ChaCha20 stream cipher implementation To install the current release: ``` $ pip install ChaCha20 ``` How to use the ChaCha20 stream cipher: ``` from ChaCha20 import ChaChaStream key = bytes(32) # key can be any byte object with 32 bytes of data nonce = bytes(12) # nonce can be any byte object with 12 bytes ...
PypiClean
/MSOIoofs-1.0.tar.gz/MSOIoofs-1.0/flood_tool/analysis.py
import os import math import numpy as np import pandas as pd import matplotlib import matplotlib.pyplot as plt __all__ = ['plot_risk_map'] def plot_postcode_density(postcode_file=(os.path.dirname(__file__) +'/resources/postcodes_unlabelled.csv'), coor...
PypiClean
/AIBias-Oddgeir-0.1.0.tar.gz/AIBias-Oddgeir-0.1.0/aibias/metrics.py
import numpy as np import aibias.dataset as ds #=================================================== # DISPARATE IMPACT #=================================================== def DisparateImpact(dataset,reference='label'): """ The ratio in probability of favorable outcomes between unprivileged ...
PypiClean
/MuPhyN-0.1.1.post4-py3-none-any.whl/muphyn/packages/core/application/box_library/box_library_data.py
import os from datetime import date from typing import Callable, List, Any, Dict, Optional from PyQt6.QtCore import QSize, QRect, QPoint from PyQt6.QtGui import QPixmap, QIcon, QPainter, QColor from muphyn.utils.paths import ROOT_DIR from muphyn.packages.core.base import loadCode from muphyn.packages.core.applicatio...
PypiClean
/BO4ML-0.3.1.tar.gz/BO4ML-0.3.1/BanditOpt/HyperParameter.py
import numpy as np from numpy.random import randint, rand from abc import abstractmethod from BanditOpt.ParamRange import paramrange,p_paramrange,one_paramrange class HyperParameter(object): def __init__(self, bounds, var_name, name,cutting=None, default=None, hType="C"): if isinstance(bounds,(list,tuple,)...
PypiClean
/CosmoTech_Acceleration_Library-0.3.0.tar.gz/CosmoTech_Acceleration_Library-0.3.0/CosmoTech_Acceleration_Library/Modelops/core/io/model_metadata.py
import logging from datetime import datetime from CosmoTech_Acceleration_Library.Modelops.core.common.redis_handler import RedisHandler from CosmoTech_Acceleration_Library.Modelops.core.utils.model_util import ModelUtil logger = logging.getLogger(__name__) class ModelMetadata(RedisHandler): """ Model Metada...
PypiClean
/Dililatum-0.1.tar.gz/Dililatum-0.1/dililatum/place.py
# Dililatum: a quest system for simple RPGs # Copyright (C) 2010 Niels Serup # This file is part of Dililatum. # # Dililatum 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 License, ...
PypiClean
/KingPaint-1.3-py3-none-any.whl/king/core/king_figure.py
import matplotlib.pyplot as plt from .king_decorater import singleton @singleton class KingFigure: def __init__(self): # plt.rcParams['toolbar'] = 'none' self.fig = plt.figure() self.ax = self.fig.add_axes([0, 0, 1, 1]) self.canvas = self.fig.canvas self.artists = self.ax.a...
PypiClean
/Goog_API-0.22.tar.gz/Goog_API-0.22/Goog_API/Goog_API_Calendar_Metodos.py
from __future__ import print_function from concurrent.futures import ThreadPoolExecutor, as_completed from datetime import datetime,timedelta,date #Imports de la API de Google from googleapiclient import errors from googleapiclient.discovery import build from google_auth_oauthlib.flow import InstalledAppFlow from g...
PypiClean
/MergePythonSDK.ticketing-2.2.2-py3-none-any.whl/MergePythonSDK/ticketing/model/encoding_enum.py
import re # noqa: F401 import sys # noqa: F401 from typing import ( Optional, Union, List, Dict, ) from MergePythonSDK.shared.model_utils import ( # noqa: F401 ApiTypeError, ModelComposed, ModelNormal, ModelSimple, cached_property, OpenApiModel, change_keys_js_to_python,...
PypiClean
/Appium-Python-Client-2.11.1.tar.gz/Appium-Python-Client-2.11.1/appium/webdriver/extensions/clipboard.py
# 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 # distributed under t...
PypiClean
/MolMod-amg-0.0.3.tar.gz/MolMod-amg-0.0.3/MolMod/BasicTools.py
import numpy import os import struct class BasicTools: def __init__(self): "" def ReadBIN(self, filename, nodescription=False, code=[0,0,0,0], dimensions=[0], datapos=0, printout=False ): if printout: print("ReadBIN is working...") shift = 32 f = open(filename, 'rb')#open for binary reading _orde...
PypiClean
/HTTPEncode-0.1.tar.gz/HTTPEncode-0.1/httpencode/form.py
from cStringIO import StringIO import cgi import urllib from httpencode.format import Format def load_form(fp, content_type): environ = { 'REQUEST_METHOD': 'POST', 'CONTENT_TYPE': content_type, 'QUERY_STRING': '', } if hasattr(fp, 'file'): # Unwrap, because we know we wo...
PypiClean
/Electrum-CHI-3.3.8.tar.gz/Electrum-CHI-3.3.8/packages/pip/_internal/vcs/git.py
from __future__ import absolute_import import logging import os.path import re from pip._vendor.packaging.version import parse as parse_version from pip._vendor.six.moves.urllib import parse as urllib_parse from pip._vendor.six.moves.urllib import request as urllib_request from pip._internal.exceptions import BadCom...
PypiClean
/Django_patch-2.2.19-py3-none-any.whl/django/http/response.py
import datetime import json import mimetypes import os import re import sys import time from email.header import Header from http.client import responses from urllib.parse import quote, urlparse from django.conf import settings from django.core import signals, signing from django.core.exceptions import DisallowedRedir...
PypiClean
/Findig-0.1.0-py3-none-any.whl/findig/__init__.py
from contextlib import contextmanager, ExitStack from functools import wraps from os.path import join, dirname from threading import Lock import traceback from werkzeug.local import LocalManager from werkzeug.routing import Map, RuleFactory from werkzeug.utils import cached_property from werkzeug.wrappers import BaseR...
PypiClean
/Beaver-36.3.1-py3-none-any.whl/beaver/config.py
import logging import os import re import socket import warnings from conf_d import Configuration from beaver.utils import eglob from beaver.glob_safe_config_parser import GlobSafeConfigParser class BeaverConfig(): def __init__(self, args, logger=None): self._logger = logger or logging.getLogger(__name__...
PypiClean
/EpiTator-1.3.5.tar.gz/EpiTator-1.3.5/epitator/structured_incident_annotator.py
from __future__ import absolute_import from .annotator import Annotator, AnnoTier from .annospan import AnnoSpan, SpanGroup from .structured_data_annotator import StructuredDataAnnotator from .geoname_annotator import GeonameAnnotator from .resolved_keyword_annotator import ResolvedKeywordAnnotator from .spacy_annotato...
PypiClean
/Bluebook-0.0.1.tar.gz/Bluebook-0.0.1/pylot/component/static/pylot/vendor/mdeditor/bower_components/codemirror/mode/haskell/haskell.js
CodeMirror.defineMode("haskell", function() { function switchState(source, setState, f) { setState(f); return f(source, setState); } // These should all be Unicode extended, as per the Haskell 2010 report var smallRE = /[a-z_]/; var largeRE = /[A-Z]/; var digitRE = /[0-9]/; var hexitRE = /[0-9A-...
PypiClean
/BitEx-2.0.0b3.zip/BitEx-2.0.0b3/bitex/api/REST/bitstamp.py
import logging import hashlib import hmac import warnings # Import Third-Party # Import Homebrew from bitex.api.REST import RESTAPI from bitex.exceptions import IncompleteCredentialsError from bitex.exceptions import IncompleteCredentialConfigurationWarning log = logging.getLogger(__name__) class BitstampREST(REST...
PypiClean
/DiamondGAN-0.0.tar.gz/DiamondGAN-0.0/README.txt
# DiamondGAN Tensorflow implementation of DiamondGAN. The pre-trained generator is provided, which is trained to translate the MRI brain from T1&T2 to FLAIR&DIR. ![DiamondGAN](https://github.com/dongliangcao/diamondGAN/blob/main/diamondGAN.png) ## Requirement numpy tensorflow tensorflow_addons SimpleITK ...
PypiClean
/BenchExec-3.17.tar.gz/BenchExec-3.17/doc/DEVELOPMENT.md
<!-- This file is part of BenchExec, a framework for reliable benchmarking: https://github.com/sosy-lab/benchexec SPDX-FileCopyrightText: 2007-2020 Dirk Beyer <https://www.sosy-lab.org> SPDX-License-Identifier: Apache-2.0 --> # BenchExec: Development Reference This file contains documentation that is only relevant ...
PypiClean
/CellPhoneDBu-1.1.1.7-py3-none-any.whl/cellphonedb/tools/generate_data/parsers/parse_interactions_inweb.py
import os import zipfile import pandas as pd import requests from tools.app import current_dir, output_dir from tools.interactions_helper import _only_uniprots_in_df def generate_interactions_inweb(inweb_inbiomap_namefile, database_proteins_namefile): if not inweb_inbiomap_namefile: inweb_inbiomap_namef...
PypiClean
/Bluebook-0.0.1.tar.gz/Bluebook-0.0.1/pylot/component/static/pylot/vendor/mdeditor/bower_components/codemirror/mode/sieve/sieve.js
CodeMirror.defineMode("sieve", function(config) { function words(str) { var obj = {}, words = str.split(" "); for (var i = 0; i < words.length; ++i) obj[words[i]] = true; return obj; } var keywords = words("if elsif else stop require"); var atoms = words("true false not"); var indentUnit = config...
PypiClean
/Chips-python-2.2.3.tar.gz/Chips-python-2.2.3/chips/compiler/macro_expander.py
from .register_map import * from .instruction_utils import * sn = 0 def unique(): global sn label = "macro_" + str(sn) sn += 1 return label def push_pop(instructions): """substitue push and pop macros with real instructions""" new_instructions = [] i = 0 while i < len(instructions)...
PypiClean
/Cowpox-6-py3-none-any.whl/cowpox/recipes/android.py
# This file is part of Cowpox. # # Cowpox 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 License, or # (at your option) any later version. # # Cowpox is distributed in the hope that i...
PypiClean
/Montreal-Forced-Aligner-3.0.0a3.tar.gz/Montreal-Forced-Aligner-3.0.0a3/docs/source/user_guide/workflows/dictionary_generating.rst
.. _g2p_dictionary_generating: Generate pronunciations for words ``(mfa g2p)`` =============================================== We have trained several G2P models that are available for download (:xref:`pretrained_g2p`). .. warning:: Please note that G2P models trained prior to 2.0 cannot be used with MFA 2.0. ...
PypiClean
/Fattoush-0.4.0.tar.gz/Fattoush-0.4.0/src/fattoush/README.md
Fattoush ======== Fattoush is a package that combines lettuce, webdriver and sauce to make a tasty UI testing salad. Running ------- Fattoush provides its own test runner which invokes lettuce such that it can run in saucelabs, with support of parallel test runs. $ fattoush --parallel=webdriver By default Fat...
PypiClean
/FuseBase-0.0.5.tar.gz/FuseBase-0.0.5/fusebase/__init__.py
from time import time from typing import NamedTuple, Dict, Union, Optional # from stat import S_IFDIR, S_IFLNK, S_IFREG # from pathlib import Path # from errno import * import logging import os BLK_SIZE = 512 # must be power of two on macos try: UID = os.getuid() GID = os.getgid() except AttributeError: ...
PypiClean
/Create-Multi-Langs-0.1.1.tar.gz/Create-Multi-Langs-0.1.1/README.md
# Create-Multi-Langs Create-Multi-Langs is a package to create code for multi-lingual sites development, ## Features - Use CSV file grid table as translated source data instead of JSON to better manage translations. - Output code language support python, go, javascript(ES6), typescript. - No more map or dict like so...
PypiClean
/FullMonty-0.1.20.tar.gz/FullMonty-0.1.20/fullmonty/terminalsize.py
import os import shlex import struct import platform import subprocess def get_terminal_size(): """ getTerminalSize() - get width and height of console - works on linux,os x,windows,cygwin(windows) originally retrieved from: http://stackoverflow.com/questions/566746/how-to-get-console-windo...
PypiClean
/Auptimizer-2.0.tar.gz/Auptimizer-2.0/src/aup/compression/torch/parameter_expressions.py
import numpy as np def choice(options, random_state): ''' options: 1-D array-like or int random_state: an object of numpy.random.RandomState ''' return random_state.choice(options) def randint(lower, upper, random_state): ''' Generate a random integer from `lower` (inclusive) to `upper` ...
PypiClean
/OTLModel/Classes/Onderdeel/Ecoraster.py
from OTLMOW.OTLModel.BaseClasses.OTLAttribuut import OTLAttribuut from OTLMOW.OTLModel.Classes.Abstracten.ComplexeGeleiding import ComplexeGeleiding from OTLMOW.OTLModel.Datatypes.BooleanField import BooleanField from OTLMOW.OTLModel.Datatypes.KlEcoPaalmateriaal import KlEcoPaalmateriaal from OTLMOW.OTLModel.Datatypes....
PypiClean
/CellProfiler-4.2.6.tar.gz/CellProfiler-4.2.6/cellprofiler/gui/app.py
import platform import sys import sentry_sdk import wx import wx.lib.inspection from cellprofiler_core.preferences import get_telemetry_prompt from cellprofiler_core.preferences import get_telemetry from cellprofiler_core.preferences import set_telemetry from cellprofiler_core.preferences import set_telemetry_prompt ...
PypiClean
/Firefly-vis-2.0.4.tar.gz/Firefly-vis-2.0.4/src/Firefly/static/lib/Tween.js
var _Group = function () { this._tweens = {}; this._tweensAddedDuringUpdate = {}; }; _Group.prototype = { getAll: function () { return Object.keys(this._tweens).map(function (tweenId) { return this._tweens[tweenId]; }.bind(this)); }, removeAll: function () { this._tweens = {}; }, add: function (t...
PypiClean
/Cantiz-PyChromecast-3.2.2.tar.gz/Cantiz-PyChromecast-3.2.2/pychromecast/discovery.py
import logging import socket from uuid import UUID import zeroconf DISCOVER_TIMEOUT = 5 _LOGGER = logging.getLogger(__name__) class CastListener(object): """Zeroconf Cast Services collection.""" def __init__(self, add_callback=None, remove_callback=None): self.services = {} self.add_callba...
PypiClean
/DLTA-AI-1.1.tar.gz/DLTA-AI-1.1/DLTA-AI-1.1/DLTA_AI_app/mmdetection/configs/_base_/models/mask_rcnn_r50_fpn.py
model = dict( type='MaskRCNN', backbone=dict( type='ResNet', depth=50, num_stages=4, out_indices=(0, 1, 2, 3), frozen_stages=1, norm_cfg=dict(type='BN', requires_grad=True), norm_eval=True, style='pytorch', init_cfg=dict(type='Pretrained', ...
PypiClean
/Nuitka_fixed-1.1.2-cp310-cp310-win_amd64.whl/nuitka/nodes/ClassNodes.py
from nuitka.PythonVersions import python_version from .ExpressionBases import ExpressionChildrenHavingBase from .IndicatorMixins import MarkNeedsAnnotationsMixin from .LocalsScopes import getLocalsDictHandle from .OutlineNodes import ExpressionOutlineFunctionBase class ExpressionClassBody(MarkNeedsAnnotationsMixin, ...
PypiClean
/HiCMatrix-15-py3-none-any.whl/hicmatrix/lib/cool.py
import os import logging log = logging.getLogger(__name__) from datetime import datetime from copy import deepcopy import math import time import gc import cooler import h5py import numpy as np from scipy.sparse import triu, csr_matrix, lil_matrix, dok_matrix import pandas as pd from hicmatrix.utilities import toStr...
PypiClean
/Lenpy-0.1.1.tar.gz/Lenpy-0.1.1/lenpy/text.py
import pygame, os from lenpy import locals pygame.font.init() class Text(): def __init__(self, text:str, font_name:str, size:int, font_dir=None, color=None, antialias=True, background=None, italic=False, bold=False, underline=False, xcenter=False, ycenter=False, sysfont=False): # Define las variables ...
PypiClean
/MergePythonSDK.ticketing-2.2.2-py3-none-any.whl/MergePythonSDK/crm/api/passthrough_api.py
import re # noqa: F401 import sys # noqa: F401 from MergePythonSDK.shared.api_client import ApiClient, Endpoint as _Endpoint from MergePythonSDK.shared.model_utils import ( # noqa: F401 check_allowed_values, check_validations, date, datetime, file_type, none_type, validate_and_convert_ty...
PypiClean
/Mail-2.1.0.tar.gz/Mail-2.1.0/mail/helper.py
from email import Utils from email.MIMEText import MIMEText from email.MIMEBase import MIMEBase from email.MIMEMultipart import MIMEMultipart from email import Encoders import logging import mimetypes import os import smtplib log = logging.getLogger(__name__) class MailError(Exception): "Generic problem buidling ...
PypiClean
/GeoBasesDev-6.0.0a27.tar.gz/GeoBasesDev-6.0.0a27/GeoBases/GlobeAssets/ThreeWebGL.js
var THREE=THREE||{};if(!window.Int32Array){window.Int32Array=Array;window.Float32Array=Array}THREE.Color=function(b){this.setHex(b)}; THREE.Color.prototype={autoUpdate:!0,copy:function(b){this.r=b.r;this.g=b.g;this.b=b.b;this.hex=b.hex;this.__styleString=b.__styleString},setRGB:function(b,d,e){this.r=b;this.g=d;this.b=...
PypiClean
/Covid19Dashboard_ah1062-0.0.13.tar.gz/Covid19Dashboard_ah1062-0.0.13/Covid19Dashboard_ah1062/covid_news_handling.py
import requests import json import os package_dir = os.path.dirname(os.path.realpath(__file__)) # MY API KEY: 41335430eabc4a6ea4818b233d6a92d1 TO STORE def get_news_data(): """Call the covid_news_handling module, and fetch new articles in relation to Covid-19 :return: list of article objects returned by th...
PypiClean
/Kerapu-2.0.3.tar.gz/Kerapu-2.0.3/kerapu/lbz/ZorgVraag.py
import csv from typing import Optional, Dict, List, Tuple from kerapu import clean_code, LEN_SPECIALISME_CODE, LEN_ZORG_VRAAG_CODE, clean_str, clean_date class ZorgVraag: """ Klasse voor zorgvragen. """ # ------------------------------------------------------------------------------------------------...
PypiClean
/Glances-3.4.0.3.tar.gz/Glances-3.4.0.3/glances/plugins/glances_fs.py
"""File system plugin.""" from __future__ import unicode_literals import operator from glances.compat import u, nativestr, PermissionError from glances.logger import logger from glances.plugins.glances_plugin import GlancesPlugin import psutil # SNMP OID # The snmpd.conf needs to be edited. # Add the following to ...
PypiClean
/CloudFerry-1.55.2.tar.gz/CloudFerry-1.55.2/cloudferry/lib/os/clients.py
import logging import re import time import threading import traceback from keystoneclient import exceptions as ks_exceptions from keystoneclient.v2_0 import client as v2_0_client from novaclient.v2 import client as nova from neutronclient.v2_0 import client as neutron from glanceclient.v1 import client as glance from...
PypiClean
/FreePyBX-1.0-RC1.tar.gz/FreePyBX-1.0-RC1/freepybx/public/js/dojox/lang/functional/scan.js.uncompressed.js
define("dojox/lang/functional/scan", ["dojo/_base/kernel", "dojo/_base/lang", "./lambda"], function(d, darray, df){ // This module adds high-level functions and related constructs: // - "scan" family of functions // Notes: // - missing high-level functions are provided with the compatible API: // scanl, scanl1, scan...
PypiClean
/Adeepspeed-0.9.2.tar.gz/Adeepspeed-0.9.2/deepspeed/runtime/data_pipeline/data_routing/basic_layer.py
# DeepSpeed Team from deepspeed.utils import logger from torch import Tensor from torch.nn import Module from ..constants import * from deepspeed.ops.random_ltd.dropping_utils import gpt_sample_tokens, bert_sample_tokens, GatherTokens, ScatterTokens #####based on the paper random-ltd: https://arxiv.org/abs/2211.115...
PypiClean
/AyiinXd-0.0.8-cp311-cp311-macosx_10_9_universal2.whl/fipper/methods/messages/send_cached_media.py
from datetime import datetime from typing import Union, List, Optional import fipper from fipper import raw, enums from fipper import types from fipper import utils class SendCachedMedia: async def send_cached_media( self: "fipper.Client", chat_id: Union[int, str], file_id: str, ...
PypiClean
/Flask-CKEditor-0.4.6.tar.gz/Flask-CKEditor-0.4.6/flask_ckeditor/static/standard/plugins/specialchar/dialogs/lang/ug.js
/* Copyright (c) 2003-2020, CKSource - Frederico Knabben. All rights reserved. For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license */ CKEDITOR.plugins.setLang("specialchar","ug",{euro:"ياۋرو بەلگىسى",lsquo:"يالاڭ پەش سول",rsquo:"يالاڭ پەش ئوڭ",ldquo:"قوش پەش سول",rdquo:"قوش پەش ئوڭ",ndas...
PypiClean
/DLTA-AI-1.1.tar.gz/DLTA-AI-1.1/DLTA_AI_app/mmdetection/mmdet/models/roi_heads/mask_heads/grid_head.py
import numpy as np import torch import torch.nn as nn import torch.nn.functional as F from mmcv.cnn import ConvModule from mmcv.runner import BaseModule from mmdet.models.builder import HEADS, build_loss @HEADS.register_module() class GridHead(BaseModule): def __init__(self, grid_points=9, ...
PypiClean
/FreePyBX-1.0-RC1.tar.gz/FreePyBX-1.0-RC1/freepybx/public/js/dojox/grid/enhanced/_PluginManager.js.uncompressed.js
define("dojox/grid/enhanced/_PluginManager", [ "dojo/_base/kernel", "dojo/_base/lang", "dojo/_base/declare", "dojo/_base/array", "dojo/_base/connect", "./_Events", "./_FocusManager", "../util" ], function(dojo, lang, declare, array, connect, _Events, _FocusManager, util){ var _PluginManager = declare("dojox.gr...
PypiClean
/Electrum-Zcash-Random-Fork-3.1.3b5.tar.gz/Electrum-Zcash-Random-Fork-3.1.3b5/lib/coinchooser.py
from collections import defaultdict, namedtuple from math import floor, log10 from .bitcoin import sha256, COIN, TYPE_ADDRESS, is_address from .transaction import Transaction from .util import NotEnoughFunds, PrintError # A simple deterministic PRNG. Used to deterministically shuffle a # set of coins - the same set...
PypiClean
/Flask-AppBuilder-jack-3.3.4.tar.gz/Flask-AppBuilder-jack-3.3.4/flask_appbuilder/security/mongoengine/manager.py
from datetime import datetime import json import logging from typing import List, Optional import uuid from werkzeug.security import generate_password_hash from .models import Permission, PermissionView, RegisterUser, Role, User, ViewMenu from ..manager import BaseSecurityManager from ... import const as c from ...mo...
PypiClean
/cardtrader_wrapper-0.3.1.tar.gz/cardtrader_wrapper-0.3.1/cardtrader/schemas/blueprint.py
__all__ = ["Blueprint"] from typing import Dict, List, Optional, Union from pydantic import Field, validator from cardtrader.schemas import BaseModel class Property(BaseModel): """ The Property object contains information used in a blueprint property. Attributes: name: property_type: ...
PypiClean
/Finance-Ultron-1.0.8.1.tar.gz/Finance-Ultron-1.0.8.1/ultron/ump/trade/ml_feature.py
import numpy as np import ast from ultron.kdutils import regression from ultron.ump.core import env from ultron.ump.core.fixes import xrange, six from ultron.ump.technical.wave import calc_wave_std from ultron.ump.technical.atr import calc_atr_std from ultron.ump.technical.jump import calc_jump g_market_trade_year = 2...
PypiClean
/Flask-Statics-Helper-1.0.0.tar.gz/Flask-Statics-Helper-1.0.0/flask_statics/static/angular/i18n/angular-locale_sr-cyrl.js
'use strict'; angular.module("ngLocale", [], ["$provide", function($provide) { var PLURAL_CATEGORY = {ZERO: "zero", ONE: "one", TWO: "two", FEW: "few", MANY: "many", OTHER: "other"}; function getDecimals(n) { n = n + ''; var i = n.indexOf('.'); return (i == -1) ? 0 : n.length - i - 1; } function getVF(n, opt_pre...
PypiClean
/125softNLP-0.0.1-py3-none-any.whl/kashgari/embeddings/base_embedding.py
# author: BrikerMan # contact: eliyar917@gmail.com # blog: https://eliyar.biz # file: base_embedding.py # time: 2019-05-20 17:40 import json import logging import pydoc from typing import Union, List, Optional, Dict import numpy as np from tensorflow import keras import kashgari from kashgari.processors import Cla...
PypiClean
/Jug-2.3.0.tar.gz/Jug-2.3.0/jug/subcommands/graph.py
import os from sys import stderr from .. import task from . import SubCommand from subprocess import check_call, CalledProcessError __all__ = [ 'graph' ] def handle_tasklet(tlet): '''Find the first non-Tasklet dependency and return its name''' dep = next(tlet.dependencies()) if isinstance(dep, tas...
PypiClean
/MTGProxyPrinter-0.25.0.tar.gz/MTGProxyPrinter-0.25.0/mtg_proxy_printer/model/card_list.py
# 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 License, or # (at your option) any later version. # This program is distributed in the hope that it will be useful, # bu...
PypiClean
/IMMP-0.12.1.tar.gz/IMMP-0.12.1/bin/immp-migrate-hangoutsbot.py
from argparse import ArgumentParser, FileType from asyncio import get_event_loop from collections import defaultdict from functools import partial import json import logging import os.path import re import anyconfig from requests import Session from tortoise import Tortoise from tortoise.transactions import atomic fr...
PypiClean
/MaterialDjango-0.2.5.tar.gz/MaterialDjango-0.2.5/bower_components/promise-polyfill/Promise.js
function MakePromise (asap) { function Promise(fn) { if (typeof this !== 'object' || typeof fn !== 'function') throw new TypeError(); this._state = null; this._value = null; this._deferreds = [] doResolve(fn, resolve.bind(this), reject.bind(this)); } function handle(deferred) { var me = this; if (th...
PypiClean
/Flask_AdminLTE3-1.0.9-py3-none-any.whl/flask_adminlte3/static/plugins/codemirror/mode/javascript/javascript.js
(function(mod) { if (typeof exports == "object" && typeof module == "object") // CommonJS mod(require("../../lib/codemirror")); else if (typeof define == "function" && define.amd) // AMD define(["../../lib/codemirror"], mod); else // Plain browser env mod(CodeMirror); })(function(CodeMirror) { "use s...
PypiClean
/B9gemyaeix-4.14.1.tar.gz/B9gemyaeix-4.14.1/weblate/trans/migrations/0156_alter_change_action.py
from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ("trans", "0155_java_format"), ] operations = [ migrations.AlterField( model_name="change", name="action", field=models.IntegerField( choi...
PypiClean
/Djblets-3.3.tar.gz/Djblets-3.3/docs/releasenotes/3.3.rst
.. default-intersphinx:: django3.2 djblets3.x python3 ========================= Djblets 3.2 Release Notes ========================= **Release date**: June 19, 2023 Installation ============ Djblets 3.3 is compatible with Django_ 3.2 and Python 3.7-3.11. To install Djblets 3.3, run: .. code-block:: console $...
PypiClean
/Nevow-0.14.5.tar.gz/Nevow-0.14.5/examples/athenademo/typeahead.py
from nevow import tags as T, rend, loaders, athena, url from formless import annotate, webform from twisted.python import util animals = {u'elf' : u'Pointy ears. Bad attitude regarding trees.', u'chipmunk': u'Cute. Fuzzy. Sings horribly.', u'chupacabra': u'It sucks goats.', u'ninja'...
PypiClean
/DendroPy-4.6.1.tar.gz/DendroPy-4.6.1/src/dendropy/model/continuous.py
############################################################################## ## DendroPy Phylogenetic Computing Library. ## ## Copyright 2010-2015 Jeet Sukumaran and Mark T. Holder. ## All rights reserved. ## ## See "LICENSE.rst" for terms and conditions of usage. ## ## If you use this work or any portion there...
PypiClean
/CloudFerry-1.55.2.tar.gz/CloudFerry-1.55.2/cloudferry/data_storage.py
from cloudferry.cfglib import CONF from cloudferry.lib.utils import log LOG = log.getLogger(__name__) # we don't want to create connection to database on module import - so that # we will create it only on first database call # also we don't want all users to install redis-client CONNECTION = [None] def redis_so...
PypiClean
/Functions_Main-0.2-py3-none-any.whl/Functions/Functions.py
import random import time import os import shutil import string from DataBase import * import DataBase from PIL import Image def DataBase_Save(dict, key, value): os.chdir(r"C:\Users\Intel\AppData\Local\Programs\Python\Python311") Dict = f"{dict}" Dict2 = f"{[key]}" Dict3 = f' = "{value}"' Dict...
PypiClean
/CAVA-2.0.7-py3-none-any.whl/cava/ensembldb/main.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
/MeUtils-2023.8.29.13.9.44-py3-none-any.whl/meutils/ai_nlp/Untitled-1(1).py
from typing import List from meutils.pipe import * patterns = [ r'([。!?\?])([^"\'])', r'(\.{6})([^"\'])', r'(\.{3,}[^\.\s])', r'([。!?\?]["\'])([^,。!?\?])' ] combined_pattern = '|'.join(patterns) def split_text(text_input: str, chunk_size: int=500, overlap_ratio: float=0.2) -> List[str]: # 连续标点句...
PypiClean
/FlaskCms-0.0.4.tar.gz/FlaskCms-0.0.4/flask_cms/static/js/ckeditor/plugins/a11yhelp/dialogs/lang/eo.js
/* Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved. For licensing, see LICENSE.md or http://ckeditor.com/license */ CKEDITOR.plugins.setLang("a11yhelp","eo",{title:"Uzindikoj pri atingeblo",contents:"Helpilenhavo. Por fermi tiun dialogon, premu la ESKAPAN klavon.",legend:[{name:"Ĝeneralaĵo...
PypiClean
/GB2260-v2-0.2.1.tar.gz/GB2260-v2-0.2.1/gb2260_v2/data/curated/revision_200012.py
from __future__ import unicode_literals name = '200012' division_schema = { '110000': '北京市', '110101': '东城区', '110102': '西城区', '110103': '崇文区', '110104': '宣武区', '110105': '朝阳区', '110106': '丰台区', '110107': '石景山区', '110108': '海淀区', '110109': '门头沟区', '110111': '房山区', '11011...
PypiClean
/githubkit-0.10.7-py3-none-any.whl/githubkit/rest/git.py
from typing import TYPE_CHECKING, Dict, List, Literal, Optional, overload from pydantic import BaseModel, parse_obj_as from githubkit.utils import UNSET, Missing, exclude_unset from .models import ( Blob, GitRef, GitTag, GitTree, GitCommit, ShortBlob, BasicError, ValidationError, ...
PypiClean
/Intercaat-3.11.tar.gz/Intercaat-3.11/intercaat/intercaatWrapper.py
import intercaat.intercaat_functions as icaat import sys def intercaat(pdb: str, qc: str, ic: str, mi: int = 4,di: str = "yes",cc: str = "yes", sr: float = 1.4, vi = [], fp: str = "./", qhull = False): arg1 = pdb arg2 = qc.split(',') arg3 = ic.split(',') arg4 = int(mi) arg5 = di arg6 = cc a...
PypiClean
/GRPy.tar.gz/Tensor.py
# TODO: Either expand or phase out the formalTensor class. Implement the sym # attribute # The required imports import sympy import numpy as np import itertools from copy import deepcopy class formalTensor(object): def __init__(self,rank,symbol): self.symbol = sympy.Symbol(symbol) self.rank = rank ...
PypiClean
/Mathics_Django-6.0.0-py3-none-any.whl/mathics_django/web/media/js/mathjax/localization/fa/MathML.js
MathJax.Localization.addTranslation("fa","MathML",{version:"2.7.9",isLoaded:true,strings:{BadMglyph:"mglyph \u0646\u0627\u0645\u0646\u0627\u0633\u0628: %1",BadMglyphFont:"\u0642\u0644\u0645 \u0646\u0627\u0645\u0646\u0627\u0633\u0628: %1",MathPlayer:"MathJax \u0646\u062A\u0648\u0627\u0646\u0633\u062A MathPlayer \u0631\u...
PypiClean
/KegLogin-0.5.4.tar.gz/KegLogin-0.5.4/readme.rst
.. default-role:: code .. role:: python(code) :language: python ========== KegLogin ========== .. image:: https://circleci.com/gh/level12/keg-login.svg?style=svg :target: https://circleci.com/gh/level12/keg-login .. image:: https://codecov.io/github/level12/keg-login/coverage.svg?branch=master :target: https:/...
PypiClean
/energon_prometheus_exporter_test-0.0.1-py3-none-any.whl/torchdistill-test/examples/hf_transformers/custom/dataset.py
from datasets import load_dataset from transformers import PretrainedConfig, default_data_collator from torchdistill.common.constant import def_logger from torchdistill.datasets.registry import register_collate_func logger = def_logger.getChild(__name__) GLUE_TASK2KEYS = { 'ax': ('premise', 'hypothesis'), 'c...
PypiClean
/CSUMMDET-1.0.23.tar.gz/CSUMMDET-1.0.23/mmdet/datasets/langconv.py
from copy import deepcopy import re try: import psyco psyco.full() except: pass from .zh_wiki import zh2Hant, zh2Hans # try: # from zh_wiki import zh2Hant, zh2Hans # except ImportError: # from zhtools.zh_wiki import zh2Hant, zh2Hans import sys py3k = sys.version_info >= (3, 0, 0) if py3k: U...
PypiClean
/FanFicFare-4.27.0.tar.gz/FanFicFare-4.27.0/fanficfare/adapters/adapter_potionsandsnitches.py
# Copyright 2011 Fanficdownloader team, 2018 FanFicFare team # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
PypiClean
/HILO-MPC-1.0.3.tar.gz/HILO-MPC-1.0.3/hilo_mpc/modules/dynamic_model/dynamic_model.py
from __future__ import annotations from copy import deepcopy import platform from typing import Optional, Sequence, TypeVar, Union import warnings import casadi as ca import numpy as np from ..base import Base, Vector, Equations, RightHandSide, TimeSeries from ..machine_learning.base import LearningBase from ...uti...
PypiClean
/BYONDTools-0.1.8.zip/BYONDTools-0.1.8/CHANGELOG.rst
================= 0.1.8 - 9/10/2015 ================= * Added support for OpenSS13 to dmmfix * Fixed dmmfix again. ================= 0.1.7 - 3/6/2015 ================= * Added pyparsing-based list() parser to DMM system * DMMFix lives again! * Move from print() to logging for console logging. * Renamed ss13_makeinha...
PypiClean
/Brian2-2.5.4-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl/brian2/codegen/runtime/cython_rt/cython_rt.py
import platform import numpy from brian2.core.base import BrianObjectException from brian2.core.functions import Function from brian2.core.preferences import BrianPreference, prefs from brian2.core.variables import ( ArrayVariable, AuxiliaryVariable, DynamicArrayVariable, Subexpression, ) from brian2....
PypiClean
/MultiRunnable-0.17.0a2-py3-none-any.whl/multirunnable/adapter/communication.py
__all__ = ["Event", "Condition"] from ..framework.adapter import BaseCommunicationAdapter, BaseLockAdapter, BaseAsyncLockAdapter, BaseAsyncCommunicationAdapter from ..factory import EventFactory, ConditionFactory from ..api import ( RLockOperator, EventOperator, ConditionOperator, EventAsyncOperator, Condi...
PypiClean
/FastFlask-1.2.32-py3-none-any.whl/flask/scaffold.py
import importlib.util import os import pkgutil import sys import typing as t from collections import defaultdict from functools import update_wrapper from json import JSONDecoder from json import JSONEncoder from jinja2 import FileSystemLoader from werkzeug.exceptions import default_exceptions from werkzeug.exceptions...
PypiClean
/ADA-sdk-2.9.tar.gz/ADA-sdk-2.9/ada/listener.py
import time import os import re from ada.features import Execution, TestCase, UploadImage def get_keyword_failed(data, keyword=""): for func in data: if func["status"] != "PASS": if keyword: keyword += "." keyword += func["kwname"] keyword = get_keyword...
PypiClean
/DLTA-AI-1.1.tar.gz/DLTA-AI-1.1/DLTA-AI-1.1/DLTA_AI_app/labelme/utils/sam.py
import sys from segment_anything import sam_model_registry, SamPredictor import numpy as np import matplotlib.pyplot as plt import cv2 import skimage.measure import torch # import mask_to_polygons from inference.py inside the inference class # from inference import mask_to_polygons # create a sam predictor class with...
PypiClean
/FreePyBX-1.0-RC1.tar.gz/FreePyBX-1.0-RC1/freepybx/public/js/dojox/html/metrics.js
define("dojox/html/metrics",["dojo/_base/kernel","dojo/_base/lang","dojo/_base/sniff","dojo/ready","dojo/_base/unload","dojo/_base/window","dojo/dom-geometry"],function(_1,_2,_3,_4,_5,_6,_7){ var _8=_2.getObject("dojox.html.metrics",true); var _9=_2.getObject("dojox"); _8.getFontMeasurements=function(){ var _a={"1em":0...
PypiClean
/Markdown-No-Lazy-Code-Extension-0.1.tar.gz/Markdown-No-Lazy-Code-Extension-0.1/README.rst
Markdown No Lazy Code Extension -------------------------------- .. image:: https://img.shields.io/travis/atodorov/Markdown-No-Lazy-Code-Extension/master.svg :target: https://travis-ci.org/atodorov/Markdown-No-Lazy-Code-Extension :alt: Build status .. image:: https://pypip.in/download/Markdown-No-Lazy-Code-Ext...
PypiClean
/Finance-JindowinData-0.0.7.tar.gz/Finance-JindowinData-0.0.7/jdwdata/RetrievalAPI/customized.py
from jdwdata.RetrievalAPI.ddb_customized import cusomize_sequence as get_ddb_data from jdwdata.RetrievalAPI.ddb_customized import cusomize_sequence_by_map as get_ddb_data_by_map from jdwdata.RetrievalAPI.file_customized import cusomize_sequence as get_file_data from jdwdata.RetrievalAPI.file_customized import cusomize_...
PypiClean