id stringlengths 1 8 | text stringlengths 6 1.05M | dataset_id stringclasses 1
value |
|---|---|---|
/htmd-pdb2pqr-0.0.2.tar.gz/htmd-pdb2pqr-0.0.2/pdb2pqr/main.py | __date__ = "5 April 2010"
__author__ = "Todd Dolinsky, Nathan Baker, Jens Nielsen, Paul Czodrowski, Jan Jensen, Samir Unni, Yong Huang"
from optparse import OptionParser, OptionGroup
import time
from .src import utilities
from .src.errors import PDB2PQRError
from .src.hydrogens import *
__version__ = "FIXME"
fro... | PypiClean |
/py-pde-0.32.2.tar.gz/py-pde-0.32.2/examples/jupyter/Discretized Fields.ipynb | ```
import sys
sys.path.append('../..') # add the pde package to the python path
import pde
# define a simple grid
grid = pde.UnitGrid([32, 32])
grid.plot()
# define scalar field, initially filled with zeros
field = pde.ScalarField(grid)
field.average
# do computations on the field
field += 1
field.average
# defin... | PypiClean |
/diffpy.utils-3.1.0.tar.gz/diffpy.utils-3.1.0/src/diffpy/utils/wx/gridutils.py | import wx
def getSelectionRows(grid):
"""Indices of the rows that have any cell selected.
"""
rows = grid.GetNumberRows()
rset = set()
if grid.GetSelectedCols():
rset.update(range(rows))
rset.update(grid.GetSelectedRows())
for r, c in grid.GetSelectedCells():
rset.add(r)
... | PypiClean |
/pulumi_azure_nextgen-0.6.2a1613157620.tar.gz/pulumi_azure_nextgen-0.6.2a1613157620/pulumi_azure_nextgen/network/latest/get_route.py |
import warnings
import pulumi
import pulumi.runtime
from typing import Any, Mapping, Optional, Sequence, Union
from ... import _utilities, _tables
__all__ = [
'GetRouteResult',
'AwaitableGetRouteResult',
'get_route',
]
@pulumi.output_type
class GetRouteResult:
"""
Route resource.
"""
def ... | PypiClean |
/okpy-1.18.1.tar.gz/okpy-1.18.1/client/sources/doctest/__init__.py | from client import exceptions as ex
from client.sources.common import importing
from client.sources.doctest import models
import logging
import os
import traceback
log = logging.getLogger(__name__)
def load(file, name, assign):
"""Loads doctests from a specified filepath.
PARAMETERS:
file -- str; a filep... | PypiClean |
/intel_tensorflow_avx512-2.13.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl/tensorflow/python/tpu/tpu_feed.py | import itertools
import numpy as np
from tensorflow.python.compiler.xla.experimental import xla_sharding
from tensorflow.python.framework import dtypes
from tensorflow.python.framework import ops
from tensorflow.python.framework import tensor_shape
from tensorflow.python.ops import array_ops
from tensorflow.python.tp... | PypiClean |
/spyder-terminal-1.2.2.tar.gz/spyder-terminal-1.2.2/spyder_terminal/server/static/components/minimist/index.js | module.exports = function (args, opts) {
if (!opts) opts = {};
var flags = { bools : {}, strings : {}, unknownFn: null };
if (typeof opts['unknown'] === 'function') {
flags.unknownFn = opts['unknown'];
}
if (typeof opts['boolean'] === 'boolean' && opts['boolean']) {
flags.allBoo... | PypiClean |
/pulumi_azure_nextgen-0.6.2a1613157620.tar.gz/pulumi_azure_nextgen-0.6.2a1613157620/pulumi_azure_nextgen/apimanagement/v20191201preview/tag_by_operation.py |
import warnings
import pulumi
import pulumi.runtime
from typing import Any, Mapping, Optional, Sequence, Union
from ... import _utilities, _tables
__all__ = ['TagByOperation']
class TagByOperation(pulumi.CustomResource):
def __init__(__self__,
resource_name: str,
opts: Optional... | PypiClean |
/conan-server-2.0.10.tar.gz/conan-server-2.0.10/conan/internal/api/new/meson_exe.py | from conan.internal.api.new.cmake_lib import source_cpp, source_h, test_main
conanfile_exe = """from conan import ConanFile
from conan.tools.meson import MesonToolchain, Meson
from conan.tools.gnu import PkgConfigDeps
class {{package_name}}Conan(ConanFile):
name = "{{name}}"
version = "{{version}}"
packa... | PypiClean |
/qubo-nn-0.2.5.tar.gz/qubo-nn-0.2.5/qubo_nn/problems/quadratic_assignment.py | import numpy as np
from qubo_nn.problems.problem import Problem
class QuadraticAssignment(Problem):
def __init__(self, cfg, flow_matrix, distance_matrix, P=200):
self.flow_matrix = flow_matrix
self.distance_matrix = distance_matrix
self.P = P
if cfg["problems"]["QA"].get("debug", ... | PypiClean |
/librec-auto-0.2.13.tar.gz/librec-auto-0.2.13/librec_auto/core/util/BBO.py | from librec_auto.core.util import Status
from librec_auto.core.util.errors import *
import optuna
# Borrowed from https://stackoverflow.com/questions/58820574/how-to-sample-parameters-without-duplicates-in-optuna
# Prevents repeated parameter values in the sampling. It seems like this should be the default
# behavior.... | PypiClean |
/RsCMX_Signaling-4.0.120-py3-none-any.whl/RsCMX_Signaling/Implementations/Configure/Signaling/Nradio/Cell/Srs/Resource/Rmapping.py | from ........Internal.Core import Core
from ........Internal.CommandsGroup import CommandsGroup
from ........Internal.Types import DataType
from ........Internal.StructBase import StructBase
from ........Internal.ArgStruct import ArgStruct
from ........Internal.ArgSingleList import ArgSingleList
from ........Internal.A... | PypiClean |
/azure_mgmt_botservice-2.0.0b3-py3-none-any.whl/azure/mgmt/botservice/_azure_bot_service.py |
from copy import deepcopy
from typing import Any, Optional, TYPE_CHECKING
from azure.core.rest import HttpRequest, HttpResponse
from azure.mgmt.core import ARMPipelineClient
from msrest import Deserializer, Serializer
from . import models
from ._configuration import AzureBotServiceConfiguration
from .operations impo... | PypiClean |
/ruletarusa-0.8.tar.gz/ruletarusa-0.8/README.md | # Ruleta rusa
## _Proyecto con fines académicos_
Si quieres testear este paquete, te recomiendo hacerlo con el siguiente código:
```
import ruletarusa as rr
def menu():
"""Funció que conté el menú del programa"""
print("---------------------- RULETA RUSA ------------------------")
print("----------------... | PypiClean |
/katalytic_images-0.9.4.tar.gz/katalytic_images-0.9.4/src/katalytic/images/__init__.py | import errno
from pathlib import Path
try:
import cv2
except ImportError: # pragma: no cover
msg = [
"Please install one of the following:",
"pip install opencv-python # the most popular",
"pip install opencv-python-headless # the most popular, without GUI fu... | PypiClean |
/CHJ-1.0.2.tar.gz/CHJ-1.0.2/_CSS/Length.py |
from __future__ import absolute_import, division
from __future__ import print_function, unicode_literals
from _CHJ import CHJ
from _TFL import TFL
import _CHJ._CSS
import _CHJ._CSS._TRBL_
import _TFL._Meta.Object
from _TFL._Meta.Once_Property import Once_Pro... | PypiClean |
/pulsarbat-0.0.9.tar.gz/pulsarbat-0.0.9/docs/development.rst | :html_theme.sidebar_secondary.remove:
:nosearch:
===========
Development
===========
Contributions are welcome, and they are greatly appreciated! Every little bit helps, and credit will always be given. This page assumes the reader has some familiarity with contributing to open-source Python projects using GitHub.
P... | PypiClean |
/qiskit_qryd_provider-0.4.5.tar.gz/qiskit_qryd_provider-0.4.5/qiskit_qryd_provider/pcp_gate.py | from cmath import exp
from typing import List
from typing import TYPE_CHECKING
from qiskit.circuit import Gate
from qiskit.circuit import Parameter
from qiskit.circuit import QuantumCircuit
from qiskit.circuit.equivalence_library import SessionEquivalenceLibrary
from qiskit.circuit.library import CPhaseGate
from qiski... | PypiClean |
/ivy-testing-release-0.0.0.1.tar.gz/ivy-testing-release-0.0.0.1/ivy/functional/frontends/paddle/tensor/tensor.py | import ivy
import ivy.functional.frontends.paddle as paddle_frontend
from ivy.func_wrapper import (
with_supported_dtypes,
with_unsupported_dtypes,
)
from ivy.functional.frontends.paddle.func_wrapper import _to_ivy_array
class Tensor:
def __init__(self, array, dtype=None, place="cpu", stop_gradient=True):... | PypiClean |
/modeltranslation-lokalise-0.2.0.tar.gz/modeltranslation-lokalise-0.2.0/modeltranslation_lokalise/signals.py | from functools import partial
from django.db.models.signals import pre_save, post_save, post_delete
from modeltranslation.translator import translator
from modeltranslation.utils import get_translation_fields
from .lokalise_client import create_or_update_translations, delete_translations
def register_translation(mo... | PypiClean |
/open-nre-0.1.1.tar.gz/open-nre-0.1.1/opennre/module/pool/max_pool.py | import torch
import torch.nn as nn
import torch.nn.functional as F
import numpy as np
class MaxPool(nn.Module):
def __init__(self, kernel_size, segment_num=None):
"""
Args:
input_size: dimention of input embedding
kernel_size: kernel_size for CNN
padding: paddin... | PypiClean |
/dagster_cloud-1.4.11.tar.gz/dagster_cloud-1.4.11/dagster_cloud/workspace/kubernetes/utils.py | import copy
import re
import time
from typing import Optional
import kubernetes
from dagster._utils.merger import merge_dicts
from dagster_k8s.client import DagsterKubernetesClient
from dagster_k8s.models import k8s_model_from_dict
from kubernetes import client
from ..user_code_launcher.utils import (
determinist... | PypiClean |
/Pypicor-1.0.4-py3-none-any.whl/build/lib/build/lib/build/lib/build/lib/build/lib/pypicor/baq.py | import pandas as pd
import requests
from requests.auth import HTTPBasicAuth
from pypicor import credentials as creds
def GetBAQ(baq_name : str, parameters : dict = {}, filters : dict = {}, select : list = []):
# Get a BAQ from Epicor
# str: baq_name = Name of the BAQ to run
# Dictionary: parameters = Dicti... | PypiClean |
/borgweb-0.3.0.tar.gz/borgweb-0.3.0/docs/internals.rst | .. include:: global.rst.inc
.. _internals:
Internals
=========
This page documents the internal workings of |project_name|.
What we use
-----------
* Flask and Werkzeug - Python web micro-framework and http toolbox
* Bootstrap and jQuery - CSS framework, Javascript library
* |project_name_backup| - for doing the ba... | PypiClean |
/karrio.dpdhl-2023.5.1-py3-none-any.whl/karrio/providers/dpdhl/tracking.py | import dpdhl_lib.tracking_response as tracking
import dpdhl_lib.tracking_request as dpdhl
import typing
import karrio.lib as lib
import karrio.core.models as models
import karrio.providers.dpdhl.error as error
import karrio.providers.dpdhl.utils as provider_utils
import karrio.providers.dpdhl.units as provider_units
... | PypiClean |
/scikit-tensor-0.1.tar.gz/scikit-tensor-0.1/sktensor/cp.py | import logging
import time
import numpy as np
from numpy import array, dot, ones, sqrt
from scipy.linalg import pinv
from numpy.random import rand
from .core import nvecs, norm
from .ktensor import ktensor
_log = logging.getLogger('CP')
_DEF_MAXITER = 500
_DEF_INIT = 'nvecs'
_DEF_CONV = 1e-5
_DEF_FIT_METHOD = 'full'
_... | PypiClean |
/django_skote-0.0.9-py3-none-any.whl/django_skote/static/django_skote/js/pages/echarts.init.js | function getChartColorsArray(e){if(null!==document.getElementById(e)){var t=document.getElementById(e).getAttribute("data-colors");if(t)return(t=JSON.parse(t)).map(function(e){var t=e.replace(" ","");return-1===t.indexOf(",")?getComputedStyle(document.documentElement).getPropertyValue(t)||t:2==(e=e.split(",")).length?"... | PypiClean |
/djbs-0.1.4.tar.gz/djbs-0.1.4/django/contrib/flatpages/migrations/0001_initial.py | from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
("sites", "0001_initial"),
]
operations = [
migrations.CreateModel(
name="FlatPage",
fields=[
(
"id",
models.Au... | PypiClean |
/ase_core-3.23.0b1.post2-py3-none-any.whl/ase/calculators/kim/kimmodel.py | import numpy as np
from ase.calculators.calculator import Calculator
from ase.calculators.calculator import compare_atoms
from . import kimpy_wrappers
from . import neighborlist
class KIMModelData:
"""Initializes and subsequently stores the KIM API Portable Model
object, KIM API ComputeArguments object, and... | PypiClean |
/auto_augmentation-0.3.tar.gz/auto_augmentation-0.3/src/autoaug/child_networks/bad_lenet.py | import torch.nn as nn
# class Bad_LeNet(nn.Module):
# # 1. I reduced the channel sizes of the convolutional layers
# # 2. I reduced the number of fully ocnnected layers from 3 to 2
# #
# # no. of weights: 25*2 + 25*2*4 + 16*4*10 = 250+640 = 890
# def __init__(self):
# super().__init__()
#... | PypiClean |
/django-bootstrap-customizer-0.2.0.tar.gz/django-bootstrap-customizer-0.2.0/bootstrap_customizer/static/bootstrap/dist/js/bootstrap.js | (function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('jquery'), require('popper.js')) :
typeof define === 'function' && define.amd ? define(['exports', 'jquery', 'popper.js'], factory) :
(global = global || self, factory(global.bootstrap = {}, globa... | PypiClean |
/os_sys-2.1.4-py3-none-any.whl/edit/rpc.py | import builtins
import copyreg
import io
import marshal
import os
import pickle
import queue
import select
import socket
import socketserver
import struct
import sys
import threading
import traceback
import types
def unpickle_code(ms):
"Return code object from marshal string ms."
co = marshal.loads(ms)
ass... | PypiClean |
/mesh_common-0.1.6-py3-none-any.whl/mesh_common/concurrency.py | import concurrent.futures
from typing import Any, Callable, Mapping, Optional, Sequence
from nhs_context_logging.logger import LoggingThreadPoolExecutor
def concurrent_tasks(
parallels: list[tuple[str, Callable, Sequence[Any]]],
raise_if_ex: bool = True,
with_results=True,
max_workers: Optional[int] ... | PypiClean |
/pocketbasex-0.8.2-py3-none-any.whl/pocketbase/services/log_service.py | from __future__ import annotations
from dataclasses import dataclass
from typing import Union
from urllib.parse import quote
import datetime
from pocketbase.services.utils.base_service import BaseService
from pocketbase.models.utils.list_result import ListResult
from pocketbase.models.log_request import LogRequest
fr... | PypiClean |
/productmd-1.36.tar.gz/productmd-1.36/doc/discinfo-1.0.rst | ========================
Discinfo file format 1.0
========================
.discinfo files can be found on Fedora installation media and
provide media information to Anaconda installer.
File Format
===========
.discinfo is a plain-text file containing following fields, one value per line:
::
timestamp: float
... | PypiClean |
/nonebot_plugin_oddtext-0.2.0.tar.gz/nonebot_plugin_oddtext-0.2.0/nonebot_plugin_oddtext/cxh.py | pinyin = {
"㐀": "qiu",
"㐁": "tian",
"㐂": "xi",
"㐅": "wu",
"㐆": "yin",
"㐇": "jiu",
"㐈": "ru",
"㐉": "ding",
"㐊": "shi",
"㐋": "tu",
"㐌": "si",
"㐍": "zhao",
"㐎": "wen",
"㐏": "wu",
"㐐": "nu",
"㐑": "dong",
"㐒": "zhao",
"㐓": "ke",
"㐔": "xiang",
"㐖... | PypiClean |
/revolt-sdk-1.0.1.tar.gz/revolt-sdk-1.0.1/revoltsdk/__init__.py | __version__ = '1.0.1'
__all__ = ['Revolt']
from concurrent.futures import ThreadPoolExecutor
from urllib.request import urlopen, Request
from datetime import datetime, timezone, timedelta
from multiprocessing import RLock
from threading import Timer
from uuid import uuid4
import locale
import time
import json
from ty... | PypiClean |
/HsOpenAPIDeviceBind-1.3.3.tar.gz/HsOpenAPIDeviceBind-1.3.3/hsbind/network_utils.py |
import netifaces
import psutil
from hsbind.common_utils import get_logger
logging = get_logger(__name__)
invalid_macs_start_str = (
'00-05-69',
'00-1c-14',
'00-0c-29',
'00-50-56',
'08-00-27',
'0a-00-27',
'00-03-ff',
'00-15-5d'
)
def get_psutil_mac_address_list() -> dict:
mac_ad... | PypiClean |
/mowl_borg-0.2.0-py3-none-any.whl/mowl/kge/model.py | from pykeen.triples.triples_factory import TriplesFactory
from pykeen.models import ERModel
from pykeen.training import SLCWATrainingLoop
import tempfile
import torch as th
from torch.optim import Adam, Optimizer
import os
import mowl.error as err
import logging
logging.basicConfig(level=logging.INFO)
class KGEModel... | PypiClean |
/google-cloud-bare-metal-solution-1.4.2.tar.gz/google-cloud-bare-metal-solution-1.4.2/google/cloud/bare_metal_solution/__init__.py | from google.cloud.bare_metal_solution import gapic_version as package_version
__version__ = package_version.__version__
from google.cloud.bare_metal_solution_v2.services.bare_metal_solution.async_client import (
BareMetalSolutionAsyncClient,
)
from google.cloud.bare_metal_solution_v2.services.bare_metal_solution... | PypiClean |
/az-iranian-bank-gateways-1.9.0.tar.gz/az-iranian-bank-gateways-1.9.0/azbankgateways/banks/idpay.py | import json
import logging
import requests
from azbankgateways.banks import BaseBank
from azbankgateways.exceptions import BankGatewayConnectionError, SettingDoesNotExist
from azbankgateways.exceptions.exceptions import BankGatewayRejectPayment
from azbankgateways.models import BankType, CurrencyEnum, PaymentStatus
f... | PypiClean |
/pov-fabric-helpers-0.3.tar.gz/pov-fabric-helpers-0.3/pov_fabric.py | import hashlib
import os
import posixpath
import subprocess
import string
import sys
import tempfile
import textwrap
import urlparse
from StringIO import StringIO
from contextlib import closing
from pipes import quote # TBD: use shlex.quote on Python 3.2+
from fabric.api import (
run, sudo, quiet, settings, cd, e... | PypiClean |
/pulumi_google_native-0.31.2a1689827148.tar.gz/pulumi_google_native-0.31.2a1689827148/pulumi_google_native/compute/beta/get_interconnect_attachment.py |
import copy
import warnings
import pulumi
import pulumi.runtime
from typing import Any, Mapping, Optional, Sequence, Union, overload
from ... import _utilities
from . import outputs
__all__ = [
'GetInterconnectAttachmentResult',
'AwaitableGetInterconnectAttachmentResult',
'get_interconnect_attachment',
... | PypiClean |
/test-tracaccountmanager.tar.gz/acct_mgr-0.4/dist/TracAccountManager-0.5dev-r12398/acct_mgr/admin.py |
import inspect
import re
from genshi.builder import tag
from genshi.core import Markup
from trac.core import Component, TracError, implements
from trac.config import Option
from trac.perm import PermissionSystem
from trac.util.datefmt import format_datetime, to_datetime
from trac... | PypiClean |
/alauda-celery-3.1.25rc1.tar.gz/alauda-celery-3.1.25rc1/docs/getting-started/brokers/sqlalchemy.rst | .. _broker-sqlalchemy:
==================
Using SQLAlchemy
==================
.. admonition:: Experimental Status
The SQLAlchemy transport is unstable in many areas and there are
several issues open. Unfortunately we don't have the resources or funds
required to improve the situation, so we're looking ... | PypiClean |
/sense2-0.3.7-py3-none-any.whl/conans/model/workspace.py | import os
from collections import OrderedDict
import yaml
from conans.client.graph.graph import RECIPE_EDITABLE
from conans.errors import ConanException
from conans.model.editable_layout import get_editable_abs_path, EditableLayout
from conans.model.ref import ConanFileReference
from conans.paths import CONANFILE
fro... | PypiClean |
/textgrid_tools-0.0.8-py3-none-any.whl/textgrid_tools/grid/audio_synchronization.py | from logging import Logger, getLogger
from typing import Optional
import numpy as np
from textgrid import IntervalTier, TextGrid
from textgrid_tools.globals import ExecutionResult
from textgrid_tools.helper import check_is_valid_grid, samples_to_s
from textgrid_tools.validation import InvalidGridError, ValidationErro... | PypiClean |
/ydk-models-cisco-ios-xr-6.6.3.tar.gz/ydk-models-cisco-ios-xr-6.6.3/ydk/models/cisco_ios_xr/_meta/_Cisco_IOS_XR_watchd_cfg.py | from ydk._core._dm_meta_info import _MetaInfoClassMember, _MetaInfoClass, _MetaInfoEnum
from ydk._core._dm_meta_info import ATTRIBUTE, REFERENCE_LIST, REFERENCE_LEAFLIST, REFERENCE_BITS, REFERENCE_UNION
from ydk._core._dm_meta_info import REFERENCE_CLASS, REFERENCE_IDENTITY_CLASS, REFERENCE_ENUM_CLASS, ANYXML_CLASS
fro... | PypiClean |
/dnb_arelle-0.1.0-py3-none-any.whl/arelle/ValidateXbrl.py | try:
import regex as re
except ImportError:
import re
from arelle import (ModelDocument, XmlUtil, XbrlUtil, XbrlConst,
ValidateXbrlCalcs, ValidateXbrlDimensions, ValidateXbrlDTS, ValidateFormula, ValidateUtr)
from arelle import FunctionIxt
from arelle.ModelObject import ModelObject
from arelle.... | PypiClean |
/nose-alert-0.9.1.tar.gz/nose-alert-0.9.1/nosealert/notifications.py | import warnings
from .platform import PLATFORM, OSX, LINUX
from os import path
IMAGES_DIR = path.join(path.dirname(__file__), 'images')
def get_icon_name(success):
name = 'ok' if success else 'error'
return 'dialog-%s' % name
def get_icon(success):
"""
Returns icon as binary data depending on given... | PypiClean |
/streamrandom-0.0.1.tar.gz/streamrandom-0.0.1/streamrandom.py | from __future__ import unicode_literals
from random import Random, BPF, RECIP_BPF
from uuid import UUID
from unicodedata import normalize
from cryptography.hazmat.primitives.ciphers import Cipher
from cryptography.hazmat.primitives.ciphers.algorithms import AES
from cryptography.hazmat.primitives.ciphers.modes import... | PypiClean |
/rupersonaagent-0.1.0-py3-none-any.whl/internet_memory_model/search/base.py | import asyncio
from abc import ABCMeta, abstractmethod
from contextlib import suppress
from enum import Enum, unique
from urllib.parse import urlencode, urlparse
from bs4 import BeautifulSoup
from search.exceptions import NoResultsOrTrafficError
from .utils import CacheHandler, get_rand_user_agent
@unique
class Ret... | PypiClean |
/Mathics_Django-6.0.0-py3-none-any.whl/mathics_django/web/media/js/mathjax/localization/fa/fa.js | MathJax.Localization.addTranslation("fa",null,{menuTitle:"\u0641\u0627\u0631\u0633\u06CC",fontDirection:"rtl",version:"2.7.9",isLoaded:true,domains:{_:{version:"2.7.9",isLoaded:true,strings:{CookieConfig:"MathJax \u06CC\u06A9 \u06A9\u0644\u0648\u0686\u06A9 \u062A\u0646\u0638\u06CC\u0645\u0627\u062A \u06A9\u0627\u0631\u... | PypiClean |
/sadie_antibody-1.0.2.tar.gz/sadie_antibody-1.0.2/src/sadie/reference/reference.py | from __future__ import annotations
import logging
from pathlib import Path
from time import sleep
from typing import Any, Dict, List, Optional, Tuple, Union
from urllib.parse import quote as url_quote
import pandas as pd
import requests
from Bio.Seq import Seq
from Bio.SeqRecord import SeqRecord
from sadie.reference... | PypiClean |
/cumm_cu102-0.4.11-cp37-cp37m-win_amd64.whl/cumm/tensorview/tvio.py | from typing import Any, Union
from typing import Dict, Hashable
import numpy as np
from cumm import tensorview as tv
import json
from collections import abc
from functools import reduce
JSON_INDEX_KEY = "__cumm_io_json_index"
NPDTYPE_TO_JSONARRAY_MAP = {
np.dtype(np.uint64): tv.uint64,
np.dtype(np.uint32): t... | PypiClean |
/raptus.recipe.torii-1.0b1.tar.gz/raptus.recipe.torii-1.0b1/raptus/recipe/torii/README.txt | Supported options
=================
The recipe supports the following options:
.. Note to recipe author!
----------------------
For each option the recipe uses you should include a description
about the purpose of the option, the format and semantics of the
values it accepts, whether it is mandatory or op... | PypiClean |
/altimate_dataminion-0.0.8-py3-none-any.whl/altimate_models/base/metadata_profiler.py | import decimal
from altimate_models.base.extractor import SQLAlchemyExtractor
from altimate_models.base.profiler import SQLAlchemyProfiler
from altimate_models.base.source import DataSource
from altimate_models.shared_models import Policy
from altimate_profiler.builders.metadata_query_builder import MetadataQueryBuild... | PypiClean |
/skytime-0.16.1-py3-none-any.whl/sktime/registry/_base_classes.py | __author__ = ["fkiraly"]
import pandas as pd
from sktime.alignment.base import BaseAligner
from sktime.annotation.base import BaseSeriesAnnotator
from sktime.base import BaseEstimator, BaseObject
from sktime.classification.base import BaseClassifier
from sktime.classification.early_classification import BaseEarlyClas... | PypiClean |
/amazon-textract-textractor-1.3.2.tar.gz/amazon-textract-textractor-1.3.2/textractor/utils/search_utils.py |
try:
import numpy as np
except ImportError:
# No need to log it here as numpy is only used if SentenceTransformers is used
# The latter has numpy as dependency.
pass
import math
import editdistance
from textractor.data.constants import SimilarityMetric
from textractor.exceptions import MissingDependen... | PypiClean |
/dgl_cu92-0.7a210408-cp36-cp36m-manylinux1_x86_64.whl/dgl/dataloading/neighbor.py | from .dataloader import BlockSampler
from .. import sampling, subgraph, distributed
class MultiLayerNeighborSampler(BlockSampler):
"""Sampler that builds computational dependency of node representations via
neighbor sampling for multilayer GNN.
This sampler will make every node gather messages from a fixe... | PypiClean |
/z3c.widgets.flashupload-1.0c1.zip/z3c.widgets.flashupload-1.0c1/src/z3c/widgets/flashupload/resources/upload.js | function z3cFlashUploadStartBrowsing(){
// tells flash to start with browsing
if(window.fuploader){
window.document["fuploader"].SetVariable("startBrowse", "go");
}else if(document.fuploader){
document.fuploader.SetVariable("startBrowse", "go");
}
}
function z3cFlashUploadEnableBrowseBu... | PypiClean |
/watchhub-2020.12.1.tar.gz/watchhub-2020.12.1/README.rst | python-watchhub
================
.. image:: https://travis-ci.com/imduffy15/python-watchhub.svg?branch=master
:target: https://travis-ci.com/imduffy15/python-watchhub
:alt: Build Status
.. image:: https://coveralls.io/repos/github/imduffy15/python-watchhub/badge.svg
:target: https://coveralls.io/github/imduff... | PypiClean |
/ixnetwork_restpy-1.1.10.tar.gz/ixnetwork_restpy-1.1.10/ixnetwork_restpy/testplatform/sessions/ixnetwork/vport/protocolstack/ancpvlanrange_4792f9d284c8f7853c65149155d5c72e.py | import sys
from ixnetwork_restpy.base import Base
from ixnetwork_restpy.files import Files
if sys.version_info >= (3, 5):
from typing import List, Any, Union
class AncpVlanRange(Base):
"""
The AncpVlanRange class encapsulates a required ancpVlanRange resource which will be retrieved from the server every... | PypiClean |
/smscx-0.1.11.tar.gz/smscx-0.1.11/smscx_client/model/new_group_response.py | import re # noqa: F401
import sys # noqa: F401
from smscx_client.model_utils import ( # noqa: F401
ApiTypeError,
ModelComposed,
ModelNormal,
ModelSimple,
cached_property,
change_keys_js_to_python,
convert_js_args_to_python_args,
date,
datetime,
file_type,
none_type,
v... | PypiClean |
/righteous_fa-1.2.1-py3-none-any.whl/righteous/quantification.py | import numpy as np
import pandas as pd
def qvalues( pvalues, pi0=None ):
m = float(len(pvalues))
assert(m>0)
pvalues.sort()
if pi0 is None:
pi0 = 1.
num_p, p_sum, qs = 0, 0.0, []
for p,coord,coord2 in pvalues:
num_p += 1
p_sum += p
q = pi0*p*(m/float(num_p))
... | PypiClean |
/packagetest109-0.109.tar.gz/packagetest109-0.109/devdoo/datafilter.py |
import re
import ast
import bson
from check import Check
from convert import Convert
# TODO:: Refator completamente classe DataFilter
class DataFilter:
# --------------------------------
# __init__
# --------------------------------
def __init__(self, params, status):
list_params = self.__to_l... | PypiClean |
/django-bootstrap-modal-forms-3.0.4.tar.gz/django-bootstrap-modal-forms-3.0.4/bootstrap_modal_forms/static/js/bootstrap5.modal.forms.min.js | const modalFormCallback=function(e){let t=document.querySelector(e.modalID),n=t.querySelector(e.modalContent),o=bootstrap.Modal.getInstance(t);null===o&&(o=new bootstrap.Modal(t,{keyboard:!1})),fetch(e.formURL).then(e=>e.text()).then(e=>{n.innerHTML=e}).then(()=>{o.show();let n=t.querySelector(e.modalForm);n&&(n.setAtt... | PypiClean |
/seanalgorithms2-0.2-py3-none-any.whl/seanalgorithms/divide_and_conquer/strassen_matrix_multiplication.py | from __future__ import annotations
import math
def default_matrix_multiplication(a: list, b: list) -> list:
"""
Multiplication only for 2x2 matrices
"""
if len(a) != 2 or len(a[0]) != 2 or len(b) != 2 or len(b[0]) != 2:
raise Exception("Matrices are not 2x2")
new_matrix = [
[a[0][... | PypiClean |
/fastapi-crudrouter-mongodb-0.0.7.tar.gz/fastapi-crudrouter-mongodb-0.0.7/fastapi_crudrouter_mongodb/core/router/embed/CRUDEmbedRouterRepository.py | from bson import ObjectId
from ...models.mongo_model import MongoModel
async def get_all(db, id: str, parent_collection_name: str, embed_name: str, model: MongoModel) -> list:
"""
Get all embeded documents from the database
"""
try:
documents = db[parent_collection_name].aggregate([
... | PypiClean |
/Dovetail-1.0beta2.tar.gz/Dovetail-1.0beta2/dovetail/util/exception.py | def pp_exception(exception):
"""Pretty-print an exception"""
return "{0}: {1}".format(type(exception).__name__, str(exception))
def stack_trace():
"""Obtains then prints a formatted stack-trace to std_err"""
from sys import exc_info, stderr
exc_type, exc_value, exc_traceback = exc_info()
from t... | PypiClean |
/alipay-sdk-python-pycryptodome-3.3.202.tar.gz/alipay-sdk-python-pycryptodome-3.3.202/alipay/aop/api/domain/KbdishInfo.py | import json
from alipay.aop.api.constant.ParamConstants import *
from alipay.aop.api.domain.KbdishPracticeInfo import KbdishPracticeInfo
from alipay.aop.api.domain.KbdishSkuInfo import KbdishSkuInfo
from alipay.aop.api.domain.KbdishMaterialBindingInfo import KbdishMaterialBindingInfo
from alipay.aop.api.domain.KbdishP... | PypiClean |
/tb-rest-client-3.5.tar.gz/tb-rest-client-3.5/tb_rest_client/models/models_pe/page_data_contact_basedobject.py | # Copyright 2023. ThingsBoard
#
# 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 writi... | PypiClean |
/tulip-1.3.0.tar.gz/tulip-1.3.0/doc/index.rst | TuLiP User's Guide
==================
Welcome to TuLiP, the Temporal Logic Planning Toolbox. This user's guide is
intended for people who are interested in making use of TuLiP to synthesize
reactive controllers for hybrid systems and perform related functions.
Contents:
.. toctree::
:numbered:
:maxdepth: 2
... | PypiClean |
/overcooked_ai-1.1.0.tar.gz/overcooked_ai-1.1.0/README.md |   [](https://badge.fury.io/... | PypiClean |
/verbcl_graph4nlp_cuda102-0.1.0-py3-none-any.whl/graph4nlp/pytorch/modules/evaluation/bleu.py | from graph4nlp.pytorch.modules.evaluation.base import EvaluationMetricBase
from graph4nlp.pytorch.modules.evaluation.bleu_tool.bleu import Bleu
class BLEU(EvaluationMetricBase):
"""
The BLEU evaluation metric class.
Parameters
----------
n_grams: list[int]
The BLEU's n_gram parameter. ... | PypiClean |
/django-quickbooks-0.6.4.2.tar.gz/django-quickbooks-0.6.4.2/django_quickbooks/validators.py | from django_quickbooks import QUICKBOOKS_ENUMS
from django_quickbooks.exceptions import VALIDATION_MESSAGES, ValidationCode
from django_quickbooks.exceptions import ValidationOptionNotFound, ValidationError
def obj_type_validator(value):
from django_quickbooks.objects.base import BaseObject
return isinstance(... | PypiClean |
/gym-robotics-1.0.1.tar.gz/gym-robotics-1.0.1/gym_robotics/envs/hand/reach.py | import os
from typing import Union
import numpy as np
from gym.utils.ezpickle import EzPickle
from gym_robotics.envs.hand_env import MujocoHandEnv, MujocoPyHandEnv
FINGERTIP_SITE_NAMES = [
"robot0:S_fftip",
"robot0:S_mftip",
"robot0:S_rftip",
"robot0:S_lftip",
"robot0:S_thtip",
]
DEFAULT_INITIA... | PypiClean |
/xdgappdirs-1.4.4.3.tar.gz/xdgappdirs-1.4.4.3/README.rst | ============
xdgappdirs
============
This is a fork and almost drop-in replacement of `appdirs
<https://pypi.org/project/appdirs/>`_ that follows the XDG BaseDir Spec on macOS
when the relevant ``XDG_*`` environment variables are available. For instance,
on macOS, when ``XDG_CONFIG_HOME`` is set to ``/Users/steve/.co... | PypiClean |
/eyes17-1.0.27-py3-none-any.whl/eyes17GUI/MPU6050.py | import sys, time, math, os.path
from . import utils
from .QtVersion import *
import pyqtgraph as pg
import numpy as np
from . eyes17 import eyemath17 as em
from eyes17.SENSORS import MPU6050
from eyes17.SENSORS.supported import supported,nameMap
from eyes17.sensorlist import sensors as sensorHints
class Expt(QWidg... | PypiClean |
/cyscs-0.1.tar.gz/cyscs-0.1/c/scs/linsys/direct/external/AMD_README.txt | AMD, Copyright (c) 2009-2012 by Timothy A. Davis (http://www.suitesparse.com),
Patrick R. Amestoy, and Iain S. Duff. All Rights Reserved. AMD is available
under alternate licences; contact T. Davis for details.
AMD: a set of routines for permuting sparse matrices prior to
factorization. Includes a version in C... | PypiClean |
/coriolis_eda-2.5.4-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl/coriolis/designflow/technos.py | import sys
import os
import socket
from pathlib import Path
from .task import ShellEnv
__all__ = [ 'Where', 'setupCMOS', 'setupCMOS45' ]
class Where ( object ):
coriolisTop = None
allianceTop = None
cellsTop = None
checkToolkit = None
def __init__ ( self, checkToolkit=None ):
... | PypiClean |
/xkcd.py-1.0.4-py3-none-any.whl/xkcd/comic.py | from datetime import datetime
from html import unescape
from os.path import split
from random import randint
from urllib.parse import urlparse
from typing import Optional
from requests import get
XKCD_BASE_URL = "https://xkcd.com/"
XKCD_WIKI_BASE_URL = "https://explainxkcd.com/"
class Comic:
"""
A class t... | PypiClean |
/django-thesaurus-0.0.2.tar.gz/django-thesaurus-0.0.2/thesaurus/migrations/0001_initial.py | from __future__ import unicode_literals
from django.db import migrations, models
import django.db.models.deletion
import parler.models
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
name='Collection',
... | PypiClean |
/waymo_open_dataset_tf_2_1_0-1.3.1-cp36-cp36m-manylinux2010_x86_64.whl/waymo_open_dataset/utils/transform_utils.py | """Utils to manage geometry transforms."""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import tensorflow as tf
__all__ = [
'get_yaw_rotation', 'get_yaw_rotation_2d', 'get_rotation_matrix',
'get_transform'
]
def get_yaw_rotation(yaw, name=None... | PypiClean |
/safegate_pro-2021.7.6-py3-none-any.whl/homeassistant/components/numato/sensor.py | import logging
from numato_gpio import NumatoGpioError
from homeassistant.components.sensor import SensorEntity
from homeassistant.const import CONF_ID, CONF_NAME, CONF_SENSORS
from . import (
CONF_DEVICES,
CONF_DST_RANGE,
CONF_DST_UNIT,
CONF_PORTS,
CONF_SRC_RANGE,
DATA_API,
DOMAIN,
)
_L... | PypiClean |
/diffusersTangkhode-0.0.1.tar.gz/diffusersTangkhode-0.0.1/src/diffusers/pipelines/semantic_stable_diffusion/pipeline_semantic_stable_diffusion.py | import inspect
from itertools import repeat
from typing import Callable, List, Optional, Union
import torch
from transformers import CLIPImageProcessor, CLIPTextModel, CLIPTokenizer
from ...models import AutoencoderKL, UNet2DConditionModel
from ...pipeline_utils import DiffusionPipeline
from ...pipelines.stable_diffu... | PypiClean |
/yuuno-core-1.3.1.zip/yuuno-core-1.3.1/yuuno/yuuno.py | # -*- coding: utf-8 -*-
# Yuuno - IPython + VapourSynth
# Copyright (C) 2017 StuxCrystal (Roland Netzsch <stuxcrystal@encode.moe>)
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation, eith... | PypiClean |
/msgraph_beta_sdk-1.0.0a9-py3-none-any.whl/msgraph/generated/users/item/people/item/person_item_request_builder.py | from __future__ import annotations
from dataclasses import dataclass
from kiota_abstractions.get_path_parameters import get_path_parameters
from kiota_abstractions.method import Method
from kiota_abstractions.request_adapter import RequestAdapter
from kiota_abstractions.request_information import RequestInformation
fro... | PypiClean |
/dials-0.0.1.tar.gz/dials-0.0.1/algorithms/integration/image_integrator.py |
from __future__ import absolute_import, division, print_function
import logging
logger = logging.getLogger(__name__)
class TimingInfo(object):
"""
A class to contain timing info.
"""
def __init__(self):
self.read = 0
self.initialize = 0
self.process = 0
self.final... | PypiClean |
/chatnoir_pyterrier-2.0.8-py3-none-any.whl/chatnoir_pyterrier/retrieve.py | from dataclasses import dataclass, field
from functools import reduce
from itertools import islice
from typing import Set, Optional, Iterable, Union, Any, Dict
from chatnoir_api import Index, Result, Slop, MinimalResult, ExplainedResult, \
MinimalResultStaging, ResultStaging, ExplainedMinimalResult, \
Explaine... | PypiClean |
/TOPSIS-Karanbir-101803235-0.1.tar.gz/TOPSIS-Karanbir-101803235-0.1/topsis_analysis/topsispackage.py | def topsis(inputname,w,im,outputname):
import pandas as pd
import sys
import os
def is_numeric1(t):
try:
t=float(t)
if (isinstance(t, int)==True or isinstance(t, float)==True):
return True
except:
print("Not a numeric value in columns 2... | PypiClean |
/py-az-cli-0.1.8.tar.gz/py-az-cli-0.1.8/pyaz/logicapp/__init__.py | from .. pyaz_utils import _call_az
def delete(name, resource_group, slot=None, yes=None):
'''
Delete a logic app.
Required Parameters:
- name -- name of the logic app.
- resource_group -- Name of resource group. You can configure the default group using `az configure --defaults group=<name>`
... | PypiClean |
/tensorflow_cpu_aws-2.14.0rc1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl/tensorflow/python/keras/utils/generic_utils.py | """Python utilities required by Keras."""
import binascii
import codecs
import importlib
import marshal
import os
import re
import sys
import threading
import time
import types as python_types
import warnings
import weakref
import numpy as np
from tensorflow.python.keras.utils import tf_contextlib
from tensorflow.py... | PypiClean |
/boto3_type_annotations_with_docs-0.3.1.tar.gz/boto3_type_annotations_with_docs-0.3.1/boto3_type_annotations/cloudtrail/paginator.py | from typing import Dict
from typing import List
from datetime import datetime
from botocore.paginate import Paginator
class ListPublicKeys(Paginator):
def paginate(self, StartTime: datetime = None, EndTime: datetime = None, PaginationConfig: Dict = None) -> Dict:
"""
Creates an iterator that will ... | PypiClean |
/limnoria-2023.8.10.tar.gz/limnoria-2023.8.10/src/httpserver.py | import os
import cgi
import socket
from threading import Thread
import supybot.log as log
import supybot.conf as conf
import supybot.world as world
import supybot.utils.minisix as minisix
from supybot.i18n import PluginInternationalization
_ = PluginInternationalization()
if minisix.PY2:
from BaseHTTPServer impor... | PypiClean |
/criteo_api_retailmedia_sdk-2023.7.0.230831-py3-none-any.whl/criteo_api_retailmedia_v2023_07/model/common_line_item_response.py | import re # noqa: F401
import sys # noqa: F401
from criteo_api_retailmedia_v2023_07.model_utils import ( # noqa: F401
ApiTypeError,
ModelComposed,
ModelNormal,
ModelSimple,
cached_property,
change_keys_js_to_python,
convert_js_args_to_python_args,
date,
datetime,
file_type,
... | PypiClean |
/scs_core-2.8.9-py3-none-any.whl/scs_core/interface/interface_conf.py | from collections import OrderedDict
from scs_core.data.json import PersistentJSONable
# --------------------------------------------------------------------------------------------------------------------
class InterfaceConf(PersistentJSONable):
"""
classdocs
"""
__FILENAME = "interface_conf.json"
... | PypiClean |
/iceberg_penguins.search-0.3.1.tar.gz/iceberg_penguins.search-0.3.1/src/iceberg_penguins/search/data/png_dataset.py | import torch
import os.path
from scipy import misc
from .base_dataset import BaseDataset, get_transform
from .image_folder import make_dataset
from PIL import Image
from PIL import ImageFilter
from pdb import set_trace as st
import random
import numpy as np
import time
class PngDataset(BaseDataset):
def initialize(... | PypiClean |
/lbrlabs_pulumi_harness-0.0.6a1688229249.tar.gz/lbrlabs_pulumi_harness-0.0.6a1688229249/lbrlabs_pulumi_harness/platform/sumologic_connector.py |
import copy
import warnings
import pulumi
import pulumi.runtime
from typing import Any, Mapping, Optional, Sequence, Union, overload
from .. import _utilities
__all__ = ['SumologicConnectorArgs', 'SumologicConnector']
@pulumi.input_type
class SumologicConnectorArgs:
def __init__(__self__, *,
acc... | PypiClean |
/tgapp-turbopress-0.0.5.tar.gz/tgapp-turbopress-0.0.5/turbopress/public/ckeditor/lang/de.js | /*
Copyright (c) 2003-2011, CKSource - Frederico Knabben. All rights reserved.
For licensing, see LICENSE.html or http://ckeditor.com/license
*/
CKEDITOR.lang.de={dir:'ltr',editorTitle:'WYSIWYG-Editor, %1, drücken Sie ALT 0 für Hilfe.',toolbars:'Editor Symbolleisten',editor:'WYSIWYG-Editor',source:'Quellcode',newPage... | PypiClean |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.