id stringlengths 1 265 | text stringlengths 6 5.19M | dataset_id stringclasses 7
values |
|---|---|---|
/CodeTalker-1.1.tar.gz/CodeTalker-1.1/codetalker/pgm/translator.py |
from tokens import Token
import types
import inspect
import copy
from nodes import AstNode
from errors import CodeTalkerException
class TranslatorException(CodeTalkerException):
pass
class Translator:
def __init__(self, grammar, **defaults):
self.grammar = grammar
self.register = {}
... | PypiClean |
/FamcyDev-0.3.71-py3-none-any.whl/Famcy/_items_/input_form/input_form.py | import Famcy
import json
class input_form(Famcy.FamcyCard):
"""
This is a category of card
that group all submittable
blocks together.
"""
def __init__(self, layout_mode=Famcy.FamcyLayoutMode.recommend, **kwargs):
super(input_form, self).__init__(layout_mode=layout_mode, **kwargs)
self.configs["method"] = "... | PypiClean |
/Electrum-CHI-3.3.8.tar.gz/Electrum-CHI-3.3.8/electrum_chi/electrum/names.py |
def split_name_script(decoded):
# This case happens if a script was malformed and couldn't be decoded by
# transaction.get_address_from_output_script.
if decoded is None:
return {"name_op": None, "address_scriptPubKey": decoded}
# name_register TxOuts look like:
# NAME_REGISTER (name) (val... | PypiClean |
/Hikka_Pyro_New-2.0.103-py3-none-any.whl/hikkapyro/methods/chats/restrict_chat_member.py |
from datetime import datetime
from typing import Union
import hikkapyro
from hikkapyro import raw, utils
from hikkapyro import types
class RestrictChatMember:
async def restrict_chat_member(
self: "hikkapyro.Client",
chat_id: Union[int, str],
user_id: Union[int, str],
permissions... | PypiClean |
/ChatAudio-2023.4.25.9.51.6-py3-none-any.whl/chatllm/qa.py |
from langchain.chains import RetrievalQA
from langchain.prompts.prompt import PromptTemplate
from langchain.vectorstores import FAISS
# ME
from meutils.pipe import *
from chatllm.chatllm import ChatLLM
RetrievalQA.return_source_documents = True
class QA(object):
def __init__(self, chatllm: ChatLLM, faiss_ann: ... | PypiClean |
/Muntjac-1.1.2.tar.gz/Muntjac-1.1.2/muntjac/addon/colorpicker/color_picker_application.py |
from StringIO import StringIO
from math import pi
from datetime import datetime as Date
from muntjac.addon.colorpicker.color import Color
from muntjac.application import Application
from muntjac.ui.check_box import CheckBox
from muntjac.ui.window import Window
from muntjac.ui.embedded import Embedded
from muntjac... | PypiClean |
/Firefly%20III%20API%20Python%20Client-1.5.6.post2.tar.gz/Firefly III API Python Client-1.5.6.post2/firefly_iii_client/model/tag_read.py | import re # noqa: F401
import sys # noqa: F401
from firefly_iii_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,... | PypiClean |
/Colr-0.9.1.tar.gz/Colr-0.9.1/colr/__init__.py | from .base import (
__version__,
ChainedBase,
get_codes,
strip_codes,
)
from .colr import ( # noqa
Colr,
InvalidArg,
InvalidColr,
InvalidFormatArg,
InvalidFormatColr,
InvalidEscapeCode,
InvalidRgbEscapeCode,
InvalidStyle,
auto_disable,
closing_code,
codeforma... | PypiClean |
/DI_engine-0.4.9-py3-none-any.whl/dizoo/classic_control/cartpole/entry/cartpole_c51_main.py | import os
import gym
from tensorboardX import SummaryWriter
from easydict import EasyDict
from ding.config import compile_config
from ding.worker import BaseLearner, SampleSerialCollector, InteractionSerialEvaluator, AdvancedReplayBuffer
from ding.envs import BaseEnvManager, DingEnvWrapper
from ding.policy import C51P... | PypiClean |
/Indian_Speech_Lib-1.0.7.tar.gz/Indian_Speech_Lib-1.0.7/Indian_Speech_Lib/Automatic_Transcripts/combine_script.py | import sys
import os
import json
import shutil
class Time(object):
mins = 0
sec = 0
def __init__(self,mins,sec):
self.mins = mins
self.sec = sec
def changeMins(self,mins):
self.mins = mins
def changeSecs(self,sec):
self.sec = sec
#------------------------------------------------------... | PypiClean |
/BananaPY-1.1.1.tar.gz/BananaPY-1.1.1/bananapy/Client.py | import aiohttp
class Error(Exception):
"""
Error that is caused when the client returns a status code other than 200 (success).
"""
pass
class Client:
"""
Main Client of BananAPI.
Params:
token (str): The BananAPI token.
"""
def __init__(self, token, session=None):
... | PypiClean |
/EMO_AI-0.0.5-py3-none-any.whl/EMO_AI/model_api.py |
__all__ = ['mish', 'Mish', 'EmoModel', 'label2int', 'get_model', 'load_tokenizer', 'setup_tokenizer', 'print_emotion',
'get_output', 'get_model_exp']
# Cell
# necessary evil
import torch
import torch.nn as nn
import torch.nn.functional as F
import os
# Cell
# from https://github.com/digantamisra98/Mish/bl... | PypiClean |
/CodeKitLang-0.4.tar.gz/CodeKitLang-0.4/codekitlang/compiler.py |
import collections
import logging
import os
import re
def _(s):
return s
Fragment = collections.namedtuple(
'Fragment',
(
'pos', # fpos of fragment start
'line', # line number of fragment
'column', # column number of fragment
'command', # NOOP, STOR, LOAD, JUMP
... | PypiClean |
/Firefly%20III%20API%20Python%20Client-1.5.6.post2.tar.gz/Firefly III API Python Client-1.5.6.post2/firefly_iii_client/model/autocomplete_piggy_balance_array.py | import re # noqa: F401
import sys # noqa: F401
from firefly_iii_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,... | PypiClean |
/MutPy-Pynguin-0.7.1.tar.gz/MutPy-Pynguin-0.7.1/mutpy/test_runners/base.py | import sys
from abc import abstractmethod
from collections import namedtuple
from mutpy import utils, coverage
class BaseTestSuite:
@abstractmethod
def add_tests(self, test_module, target_test):
pass
@abstractmethod
def skip_test(self, test):
pass
@abstractmethod
def run(sel... | PypiClean |
/AwesomeTkinter-2021.11.8-py3-none-any.whl/awesometkinter/bidirender.py | import os
import platform
import tkinter as tk
import re
from bidi.algorithm import get_display
if not __package__:
__package__ = 'awesometkinter'
from .menu import RightClickMenu
UNSHAPED = 0
ISOLATED = 1
INITIAL = 2
MEDIAL = 3
FINAL = 4
operating_system = platform.system() # current operating system ('Windo... | PypiClean |
/FreePyBX-1.0-RC1.tar.gz/FreePyBX-1.0-RC1/freepybx/public/js/dijit/_editor/plugins/FullScreen.js | define("dijit/_editor/plugins/FullScreen",["dojo/aspect","dojo/_base/declare","dojo/dom-class","dojo/dom-geometry","dojo/dom-style","dojo/_base/event","dojo/i18n","dojo/keys","dojo/_base/lang","dojo/on","dojo/_base/sniff","dojo/_base/window","dojo/window","../../focus","../_Plugin","../../form/ToggleButton","../../regi... | PypiClean |
/AyiinXd-0.0.8-cp311-cp311-macosx_10_9_universal2.whl/fipper/node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts |
/// <reference lib="es2015.symbol" />
interface SymbolConstructor {
/**
* A method that determines if a constructor object recognizes an object as one of the
* constructor’s instances. Called by the semantics of the instanceof operator.
*/
readonly hasInstance: unique symbol;
/**
* A... | PypiClean |
/FrameDynamics-0.1.8.tar.gz/FrameDynamics-0.1.8/README.md | # FrameDynamics
FrameDynamics is a python package that provides numerical simulations for the
field of pulse sequence development in magnetic resonance.
A coupling Hamiltonian is modulated in the toggling or interaction frame
according to the specified pulse sequence and offset frequencies.
The trajectory of the... | PypiClean |
/B9gemyaeix-4.14.1.tar.gz/B9gemyaeix-4.14.1/docs/devel/translations.rst | Managing translations
=====================
.. _adding-translation:
Adding new translations
-----------------------
New strings can be made available for translation when they appear in the base file,
called :guilabel:`Template for new translations` (see :ref:`component`).
If your file format doesn't require such a ... | PypiClean |
/MatchZoo-test-1.0.tar.gz/MatchZoo-test-1.0/matchzoo/utils/early_stopping.py |
import typing
import torch
import numpy as np
class EarlyStopping:
"""
EarlyStopping stops training if no improvement after a given patience.
:param patience: Number fo events to wait if no improvement and then
stop the training.
:param should_decrease: The way to judge the best so far.
... | PypiClean |
/Cubane-1.0.11.tar.gz/Cubane-1.0.11/cubane/svgicons/management/commands/create_svgicons.py | from __future__ import unicode_literals
from django.conf import settings
from django.core.management import call_command
from django.core.management.base import BaseCommand, CommandError
from cubane.svgicons import get_svgicons_filename
from cubane.svgicons import get_combined_svg
from cubane.lib.resources import get_r... | PypiClean |
/DB_helper-1.1.0.tar.gz/DB_helper-1.1.0/DB_helper/__init__.py | import sqlite3
def create_db():
'''
Если у вас нет файла БД, то создайте его здесь.
Функция вернет название файла
'''
with open('data.db','w'):
pass
return 'data.db'
def _get_connection(file_name):
'''
Подключение к БД
'''
return sqlite3.connect(file_name)
class DataBase:
... | PypiClean |
/ChemSpiPy-2.0.0.tar.gz/ChemSpiPy-2.0.0/README.rst | ChemSpiPy
=========
.. image:: https://img.shields.io/pypi/v/ChemSpiPy.svg?style=flat
:target: https://pypi.python.org/pypi/ChemSpiPy
.. image:: https://img.shields.io/pypi/l/ChemSpiPy.svg?style=flat
:target: https://github.com/mcs07/ChemSpiPy/blob/master/LICENSE
.. image:: https://img.shields.io/travis/mcs0... | PypiClean |
/BigJob2-0.54.post73.tar.gz/BigJob2-0.54.post73/util/bigjob_usage.py |
# <markdowncell>
# # Generating BigJob Usage Statistics out of Redis entries
# Read `cus` and `pilots` from Redis
# <codecell>
import pandas as pd
import matplotlib.pyplot as plt
import os, sys
import archive
import datetime
import ast
# <codecell>
# Attempt to restore old data frame
cus_df = None
pilot_df = None... | PypiClean |
/CRIkit2-0.4.4.tar.gz/CRIkit2-0.4.4/crikit/ui/dialog_AnscombeParams.py | import sys as _sys
import os as _os
import numpy as _np
# Generic imports for QT-based programs
from PyQt5.QtWidgets import (QApplication as _QApplication,
QDialog as _QDialog)
# Import from Designer-based GUI
from crikit.ui.qt_CalcAnscombeParameters import Ui_Dialog
# Generic imports f... | PypiClean |
/MetaSBT-0.1.2.tar.gz/MetaSBT-0.1.2/metasbt/modules/index.py | __author__ = "Fabio Cumbo (fabio.cumbo@gmail.com)"
__version__ = "0.1.0"
__date__ = "Apr 27, 2023"
import argparse as ap
import errno
import hashlib
import math
import multiprocessing as mp
import os
import shutil
import sys
import time
from functools import partial
from logging import Logger
from pathlib import Path
... | PypiClean |
/Mopidy-MusicBox-Darkclient-1.1.tar.gz/Mopidy-MusicBox-Darkclient-1.1/README.rst | *****************************
Mopidy-MusicBox-Darkclient
*****************************
Mopidy MusicBox Webclient (MMW) is a frontend extension and JavaScript-based web client especially
written for Mopidy
Darkclient is dark theme for MMW. Can be used as standalone Mopidy plugin without upstream MMW.
Features
=======... | PypiClean |
/Editra-0.7.20.tar.gz/Editra-0.7.20/src/edimage.py | __author__ = "Cody Precord <cprecord@editra.org>"
__svnid__ = "$Id: edimage.py 54209 2008-06-14 04:57:51Z CJP $"
__revision__ = "$Revision: 54209 $"
#-----------------------------------------------------------------------------#
from extern.embeddedimage import PyEmbeddedImage
catalog = {}
index = []
splashwarn = Py... | PypiClean |
/Meraki_Auto_Sync-1.190-py3-none-any.whl/autosync/mnetutils/sync.py | import asyncio
import threading
from random import randrange
from meraki.exceptions import AsyncAPIError
from autosync import lib, const, model
def set_sync(org_id: str, net_id: str, product: str, is_golden: bool):
"""
Args:
org_id:
net_id:
product:
is_golden:
Returns:
... | PypiClean |
/flask_more-0.2.1.tar.gz/flask_more-0.2.1/docs/api.md | # @api
Basically, Flask-More does most of the work using the `@api` decorator, which does not disturb the existing routing view. The functionality adds validation of the request data, handles the request body data automatically, and helps you describe the api's functionality in more detail.
## Validation
```python
f... | PypiClean |
/Flask_Simple_Serializer-1.1.3-py3-none-any.whl/flask_simple_serializer/serializers.py | import six
from werkzeug.datastructures import MultiDict
from collections import OrderedDict
from wtforms.form import Form
from wtforms_alchemy import ModelForm
def serializer_factory(base=Form):
class BaseSerializer(base):
def __init__(self, data_dict=None, model_instance=None, **kwargs):
... | PypiClean |
/Clearmatch-1.0.0-py3-none-any.whl/clearmatch/clearmatch.py |
from matplotlib.pyplot import bar, show, suptitle
import numpy as np
import pandas as pd
records_dict = {}
names = ["Missing", "Nonmissing"]
missing_count = [0, 0]
class ClearMatch:
def __init__(self, host_col, host_data, key_col, key_data, value_cols):
"""A constructor for the ClearMatch class
... | PypiClean |
/Marl-Factory-Grid-0.1.2.tar.gz/Marl-Factory-Grid-0.1.2/marl_factory_grid/environment/actions.py | import abc
from typing import Union
from marl_factory_grid.environment import rewards as r, constants as c
from marl_factory_grid.utils.helpers import MOVEMAP
from marl_factory_grid.utils.results import ActionResult
class Action(abc.ABC):
@property
def name(self):
return self._identifier
@abc.a... | PypiClean |
/AI-Starter-3.0.7.tar.gz/AI-Starter-3.0.7/dxc/ai/publish_microservice/publish_microservice.py | import Algorithmia
from Algorithmia.errors import AlgorithmException
import shutil #serializing models
import urllib.parse #input data
from git import Git, Repo, remote
import os
import pickle
from IPython.display import YouTubeVideo
from IPython.core.magic import register_line_cell_magic
import urllib.request, json
fr... | PypiClean |
/EOmaps-7.0-py3-none-any.whl/eomaps/scripts/open.py | import sys
import os
import click
try:
# make sure qt5 is used as backend
import matplotlib
matplotlib.use("qt5agg")
except Exception:
click.echo("... unable to activate PyQt5 backend... defaulting to 'tkinter'")
def _identify_crs(crs):
from eomaps import Maps
if crs == "web":
crs ... | PypiClean |
/GP_Framework_BYU_HCMI-0.0.10.tar.gz/GP_Framework_BYU_HCMI-0.0.10/gp_framework/phenotype/blackjack.py | from enum import Enum, auto
from typing import List
import random
import struct
from gp_framework.bytegenotype import ByteGenotype
from gp_framework.phenotype.phenotype import PhenotypeConverter
class Card(Enum):
ace = auto()
two = auto()
three = auto()
four = auto()
five = auto()
six = auto(... | PypiClean |
/CheckM2-1.0.1.tar.gz/CheckM2-1.0.1/checkm2/predictQuality.py | from checkm2 import modelProcessing
from checkm2 import metadata
from checkm2 import prodigal
from checkm2 import diamond
from checkm2.defaultValues import DefaultValues
from checkm2.versionControl import VersionControl
from checkm2 import keggData
from checkm2 import modelPostprocessing
from checkm2 import fileManager... | PypiClean |
/KindleComicConverter_headless-5.5.2-py3-none-any.whl/kindlecomicconverter/shared.py |
import os
from hashlib import md5
from html.parser import HTMLParser
from distutils.version import StrictVersion
from re import split
from traceback import format_tb
class HTMLStripper(HTMLParser):
def __init__(self):
HTMLParser.__init__(self)
self.reset()
self.strict = False
self... | PypiClean |
/BIA_OBS-1.0.3.tar.gz/BIA_OBS-1.0.3/BIA/static/dist/node_modules/tailwindcss/src/util/normalizeScreens.js | * @typedef {object} Screen
* @property {string} name
* @property {boolean} not
* @property {ScreenValue[]} values
*/
/**
* A function that normalizes the various forms that the screens object can be
* provided in.
*
* Input(s):
* - ['100px', '200px'] // Raw strings
* - { sm: '100px', md: '200px' } // Ob... | PypiClean |
/Django-ArrayAccum-1.6.1.tar.gz/Django-ArrayAccum-1.6.1/django/db/models/aggregates.py | from django.db.models.constants import LOOKUP_SEP
def refs_aggregate(lookup_parts, aggregates):
"""
A little helper method to check if the lookup_parts contains references
to the given aggregates set. Because the LOOKUP_SEP is contained in the
default annotation names we must check each prefix of the l... | PypiClean |
/Byond_API-0.2.2.tar.gz/Byond_API-0.2.2/README.md | # Byond-API
A simple and convenient extension that can be used to work with the servers of the game Space Station 13 based on the BayStation build.
supported builds = ["bay", "paradise"]
## Examples
```
from Byond_API import ByondAPI
servers = ByondAPI()
servers.add_server("ss220", "bay" ('game.ss220.space' ,7725))
s... | PypiClean |
/DeDist-0.1.tar.gz/DeDist-0.1/dedist/dedist.py | import numpy as np
from scipy.stats import mvn
from multiprocessing import Pool
def multi_fun(inputs):
''' Function to apply mvnun in paralell
Parameters
----------
inputs : list
[0], array, lower bounds
[1], array, upper bounds
[2], array, means
[3], array, covariance ... | PypiClean |
/MaiConverter-0.14.5-py3-none-any.whl/maiconverter/converter/simaitomaima2.py | from typing import List, Tuple, Optional
from ..maima2 import (
MaiMa2,
BPM,
HoldNote as Ma2HoldNote,
TouchHoldNote as Ma2TouchHoldNote,
SlideNote as Ma2SlideNote,
)
from ..simai import (
SimaiChart,
pattern_to_int,
TapNote,
HoldNote,
SlideNote,
TouchHoldNote,
TouchTapNo... | PypiClean |
/Ammonia-0.0.16.tar.gz/Ammonia-0.0.16/ammonia/mq.py | from kombu import Consumer, Producer, Connection, Exchange, Queue
from ammonia import settings
# ---------------------------------- task mq ---------------------------------- #
class TaskConnection(Connection):
hostname = settings.TASK_URL
class TaskExchange(Exchange):
def __init__(self, name=None, chann... | PypiClean |
/Diofant-0.14.0a2.tar.gz/Diofant-0.14.0a2/docs/modules/combinatorics/permutations.rst | .. _combinatorics-permutations:
Permutations
============
.. module:: diofant.combinatorics.permutations
.. autoclass:: Permutation
:members:
.. autoclass:: Cycle
:members:
.. _combinatorics-generators:
.. autofunction:: _af_parity
Generators
----------
.. module:: diofant.combinatorics.generators
.. aut... | PypiClean |
/CGOL-0.9.5.tar.gz/CGOL-0.9.5/README.md | # CGOL · [](https://pypi.org/project/CGOL/) [](https://github.com/INeido/CGOL/releases) .
.. toctree::... | PypiClean |
/Neodroid-0.4.9-py36-none-any.whl/neodroid/messaging/fbs/FBSModels/FReaction.py |
# namespace: Reaction
import flatbuffers
class FReaction(object):
__slots__ = ["_tab"]
@classmethod
def GetRootAsFReaction(cls, buf, offset):
n = flatbuffers.encode.Get(flatbuffers.packer.uoffset, buf, offset)
x = FReaction()
x.Init(buf, n + offset)
return x
# FReac... | PypiClean |
/FreePyBX-1.0-RC1.tar.gz/FreePyBX-1.0-RC1/freepybx/public/js/dijit/MenuItem.js | require({cache:{"url:dijit/templates/MenuItem.html":"<tr class=\"dijitReset dijitMenuItem\" data-dojo-attach-point=\"focusNode\" role=\"menuitem\" tabIndex=\"-1\"\n\t\tdata-dojo-attach-event=\"onmouseenter:_onHover,onmouseleave:_onUnhover,ondijitclick:_onClick\">\n\t<td class=\"dijitReset dijitMenuItemIconCell\" role=\... | PypiClean |
/ClueDojo-1.4.3-1.tar.gz/ClueDojo-1.4.3-1/src/cluedojo/static/dojox/io/OAuth.js | if(!dojo._hasResource["dojox.io.OAuth"]){
dojo._hasResource["dojox.io.OAuth"]=true;
dojo.provide("dojox.io.OAuth");
dojo.require("dojox.encoding.digests.SHA1");
dojox.io.OAuth=new (function(){
var _1=this.encode=function(s){
if(!s){
return "";
}
return encodeURIComponent(s).replace(/\!/g,"%21").replace(/\*/g,"%2A").rep... | PypiClean |
/DJModels-0.0.6-py3-none-any.whl/djmodels/contrib/gis/gdal/prototypes/raster.py | from ctypes import POINTER, c_bool, c_char_p, c_double, c_int, c_void_p
from functools import partial
from djmodels.contrib.gis.gdal.libgdal import GDAL_VERSION, std_call
from djmodels.contrib.gis.gdal.prototypes.generation import (
chararray_output, const_string_output, double_output, int_output,
void_output,... | PypiClean |
/ImSwitchUC2-2.1.0.tar.gz/ImSwitchUC2-2.1.0/imswitch/imcontrol/model/managers/detectors/ThorcamManager.py | import numpy as np
from imswitch.imcommon.model import initLogger
from .DetectorManager import DetectorManager, DetectorAction, DetectorNumberParameter, DetectorListParameter
class ThorcamManager(DetectorManager):
""" DetectorManager that deals with TheImagingSource cameras and the
parameters for frame extra... | PypiClean |
/Fileseq-1.15.2.tar.gz/Fileseq-1.15.2/src/fileseq/constants.py | from __future__ import absolute_import
import re
# The max frame count of a FrameSet before a MaxSizeException
# exception is raised
MAX_FRAME_SIZE = 10000000
class _PadStyle(object):
def __init__(self, name):
self.__name = name
def __hash__(self):
return hash(str(self))
def __repr__(s... | PypiClean |
/AyDictionary-0.0.4.tar.gz/AyDictionary-0.0.4/README.md | ## AyDictionary: A Dictionary Module for Python
<!-- [](https://travis-ci.org/geekpradd/AyDictionary) -->
[](https://pypi.python.org/pypi/... | PypiClean |
/ArseinTest-4.8.8.tar.gz/ArseinTest-4.8.8/arsein/Getheader.py | import aiohttp
import asyncio
from arsein.Encoder import encoderjson
from arsein.PostData import method_Rubika,httpfiles,_download_with_server
from json import loads
from pathlib import Path
from arsein.Clien import clien
class Upload:
def __init__(self, Sh_account:str):
self.Auth = Sh_account
self... | PypiClean |
/MokaPlayer-0.8.5.7.tar.gz/MokaPlayer-0.8.5.7/mokaplayer/core/playlists/__init__.py | import enum
import peewee
from mokaplayer.core.database import Song
class AbstractPlaylist:
""" Abstract class for a playlist
"""
class OrderBy(enum.Enum):
""" Enum for the different way to order a playlist
"""
DEFAULT = enum.auto()
ARTIST = enum.auto()
ALBUM = en... | PypiClean |
/AstroCabTools-1.5.1.tar.gz/AstroCabTools-1.5.1/astrocabtools/mrs_subviz/src/viewers/canvas_interaction/centroidAreaSelectionCanvas/panOnClick.py | import numpy
import weakref
from pubsub import pub
import matplotlib.pyplot as _plt
from matplotlib.backends.backend_qt5agg import FigureCanvasQTAgg as FigureCanvas
from .zoomOnWheel import ZoomOnWheel
class PanOnClick(ZoomOnWheel):
"""Class providing pan & zoom interaction to a matplotlib Figure.
Left bu... | PypiClean |
/MolScribe-1.1.1.tar.gz/MolScribe-1.1.1/README.md | # MolScribe
This is the repository for MolScribe, an image-to-graph model that translates a molecular image to its chemical
structure. Try our [demo](https://huggingface.co/spaces/yujieq/MolScribe) on HuggingFace!

If you use MolScribe in your research, please cite our [paper](https://p... | PypiClean |
/AyiinXd-0.0.8-cp311-cp311-macosx_10_9_universal2.whl/fipper/node_modules/tr46/index.js | "use strict";
var punycode = require("punycode");
var mappingTable = require("./lib/mappingTable.json");
var PROCESSING_OPTIONS = {
TRANSITIONAL: 0,
NONTRANSITIONAL: 1
};
function normalize(str) { // fix bug in v8
return str.split('\u0000').map(function (s) { return s.normalize('NFC'); }).join('\u0000');
}
fu... | PypiClean |
/FortranBinary-21.2.1.tar.gz/FortranBinary-21.2.1/README.rst | ====================
FortranBinary README
====================
Package for handling of FORTRAN binary data with python.
Installation:
-------------
To install the latest releaase from PyPI::
pip install numpyXtns
Alternatively, download the source from the repository install via pip, descend
into the top-level ... | PypiClean |
/NudeNet-2.0.9-py3-none-any.whl/nudenet/detector.py | import os
import cv2
import pydload
import logging
import numpy as np
import onnxruntime
from progressbar import progressbar
from .detector_utils import preprocess_image
from .video_utils import get_interest_frames_from_video
def dummy(x):
return x
FILE_URLS = {
"default": {
"checkpoint": "https://... | PypiClean |
/Autoneuro-master_new-0.0.1.tar.gz/Autoneuro-master_new-0.0.1/EDA.py | import numpy as np
import pandas as pd
import logger
'''from sklearn.decomposition import PCA
from imblearn.over_sampling import RandomOverSampler, SMOTE
from imblearn.under_sampling import RandomUnderSampler
from sklearn.feature_selection import VarianceThreshold
from sklearn.preprocessing import StandardScaler
from s... | PypiClean |
/CoCoMiCo-0.2.1.tar.gz/CoCoMiCo-0.2.1/src/cocomico/__main__.py | import argparse
from cocomico.pipeline import benchmark_mode , run_mode
from cocomico.utils import is_valid_dir , is_valid_file, check_valid_dir
import os
import time
import pkg_resources
import sys
VERSION = pkg_resources.get_distribution("cocomico").version
LICENSE = """ Copyright (C) 2022 Maxime Lecomte - David She... | PypiClean |
/HTSeq-0.13.5.tar.gz/HTSeq-0.13.5/README.md | 
[](https://htseq.readthedocs.io)
# HTSeq
**DEVS**: https://github.com/htseq/htseq
**DOCS**: https://htseq.readthedocs.io
A Python library to facilitate processing and anal... | PypiClean |
/Flask-CKEditor-0.4.6.tar.gz/Flask-CKEditor-0.4.6/flask_ckeditor/static/standard/plugins/specialchar/dialogs/lang/ru.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","ru",{euro:"Знак евро",lsquo:"Левая одинарная кавычка",rsquo:"Правая одинарная кавычка",ldquo:"Левая двойная кавычк... | PypiClean |
/EtherollApp-2020.322-py3-none-any.whl/etherollapp/etheroll/settings_screen.py | import os
import shutil
from kivy.properties import BooleanProperty, NumericProperty
from pyetheroll.constants import ChainID
from etherollapp.etheroll.constants import KEYSTORE_DIR_SUFFIX
from etherollapp.etheroll.settings import Settings
from etherollapp.etheroll.ui_utils import SubScreen, load_kv_from_py
from ethe... | PypiClean |
/Markdown-Editor-1.0.7.tar.gz/Markdown-Editor-1.0.7/markdown_editor/libs/codemirror-5.15.2/keymap/emacs.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 stric... | PypiClean |
/FixedEffectModel-0.0.5.tar.gz/FixedEffectModel-0.0.5/fixedeffect/fe/did.py | from ..utils.DemeanDataframe import demean_dataframe
from ..utils.FormTransfer import form_transfer
from ..utils.CalDf import cal_df
from ..utils.CalFullModel import cal_fullmodel
from ..utils.WaldTest import waldtest
from ..utils.OLSFixed import OLSFixed
from ..utils.ClusterErr import clustered_error, is_nested,min_cl... | PypiClean |
/FuzzyClassificator-1.3.84-py3-none-any.whl/pybrain/rl/environments/simple/renderer.py | __author__ = 'Thomas Rueckstiess, ruecksti@in.tum.de'
from pylab import plot, figure, ion, Line2D, draw, arange
from pybrain.rl.environments.renderer import Renderer
import threading
import time
class SimpleRenderer(Renderer):
def __init__(self):
Renderer.__init__(self)
self.dataLock = threading... | PypiClean |
/Djinja-0.7.tar.gz/Djinja-0.7/website_example/settings.py |
DEBUG = True
TEMPLATE_DEBUG = DEBUG
ADMINS = (
# ('Your Name', 'your_email@example.com'),
)
MANAGERS = ADMINS
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.', # Add 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
'NAME': '', # Or path to d... | PypiClean |
/7Wonder-RL-Lib-0.1.1.tar.gz/7Wonder-RL-Lib-0.1.1/docs/searchindex.js | Search.setIndex({"docnames": ["index"], "filenames": ["index.rst"], "titles": ["Welcome to 7Wonder-RL-Lib\u2019s documentation!"], "terms": {"index": 0, "modul": 0, "search": 0, "page": 0, "master": [], "file": [], "creat": [], "sphinx": [], "quickstart": [], "wed": [], "mai": [], "10": [], "21": [], "53": [], "31": []... | PypiClean |
/Django-Pizza-16.10.1.tar.gz/Django-Pizza-16.10.1/pizza/blog/migrations/0002_auto.py | import datetime
from south.db import db
from south.v2 import SchemaMigration
from django.db import models
class Migration(SchemaMigration):
def forwards(self, orm):
# Adding M2M table for field formats on 'Blog'
m2m_table_name = db.shorten_name(u'blog_blog_formats')
db.create_table(m2m_ta... | PypiClean |
/KratosMultilevelMonteCarloApplication-9.3.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl/KratosMultiphysics/MultilevelMonteCarloApplication/tools.py | import KratosMultiphysics
class ParametersWrapper(object):
"""
Class for handling the project parameters with different solver settings.
This class is used by Monte Carlo and Multilevel Monte Carlo algorithms.
Input:
- project_parameters: Kratos parameters
"""
def __init__(self,project_pa... | PypiClean |
/Music-Player-1.0.5.1.tar.gz/Music-Player-1.0.5.1/MusicPlayer/apis/netEaseApi.py |
__author__ = 'cyrbuzz'
import re
import json
import logging
import urllib.parse
from collections import namedtuple
from apiRequestsBase import HttpRequest, ignored
from netEaseEncode import encrypted_request, hashlib
logger = logging.getLogger(__name__)
SongInfo = namedtuple(
'SongInfo', ['music_id', 'url', ... | PypiClean |
/MAVR-0.93.tar.gz/MAVR-0.93/scripts/annotation/gff_examine.py | __author__ = 'mahajrod'
import os
import argparse
import pprint
from collections import OrderedDict
import matplotlib
matplotlib.use('Agg')
os.environ['MPLCONFIGDIR'] = '/tmp/'
import matplotlib.pyplot as plt
plt.ioff()
import numpy as np
from BCBio.GFF import GFFExaminer
from BCBio import GFF
from RouToolPa.Collec... | PypiClean |
/Jellyfin_CLI-1.6-py3-none-any.whl/jellyfin_cli/jellyfin_client/JellyfinClient.py | from aiohttp import ClientSession
from jellyfin_cli.jellyfin_client.data_classes.View import View
from jellyfin_cli.jellyfin_client.data_classes.Shows import Episode, Show
from jellyfin_cli.jellyfin_client.data_classes.Movies import Movie
from jellyfin_cli.jellyfin_client.data_classes.Audio import Audio, Album
class I... | PypiClean |
/Office365-REST-Python-Client-2.4.3.tar.gz/Office365-REST-Python-Client-2.4.3/office365/runtime/client_runtime_context.py | import abc
from time import sleep
from typing import TypeVar
from office365.runtime.client_request_exception import ClientRequestException
from office365.runtime.client_result import ClientResult
from office365.runtime.http.http_method import HttpMethod
from office365.runtime.http.request_options import RequestOptions... | PypiClean |
/IsPycharmRun-1.0.tar.gz/IsPycharmRun-1.0/pb_py/playertitle_pb2.py |
from google.protobuf import descriptor as _descriptor
from google.protobuf import message as _message
from google.protobuf import reflection as _reflection
from google.protobuf import symbol_database as _symbol_database
# @@protoc_insertion_point(imports)
_sym_db = _symbol_database.Default()
import enum_define_pb2 ... | PypiClean |
/Dendrite_Neural_Networks-0.0.9-py3-none-any.whl/PreTrain/kmeans/bkmeans.py | import numpy as np
from sklearn.cluster import KMeans
from sklearn.metrics.pairwise import euclidean_distances
def bkmeans(x_train, y_train, boxes, eps=0.05):
classes = np.unique(y_train)
counter = 0
flag = 0
if len(classes)<=2:
# Analyzed patterns
pos = np.where(classes[1] == y... | PypiClean |
/Kapok-0.2.1-cp35-cp35m-win_amd64.whl/kapok/rvogp.py | import collections
import time
import numpy as np
def rvogfwdvol(hv, ext, inc, kz, rngslope=0.0):
"""RVoG forward model volume coherence.
For a given set of model parameters, calculate the RVoG model coherence.
Note that all input arguments must be arrays (even if they are one element
array... | PypiClean |
/Argonaut-0.3.4.tar.gz/Argonaut-0.3.4/argonaut/public/ckeditor/_source/plugins/forms/dialogs/textfield.js | /*
Copyright (c) 2003-2010, CKSource - Frederico Knabben. All rights reserved.
For licensing, see LICENSE.html or http://ckeditor.com/license
*/
CKEDITOR.dialog.add( 'textfield', function( editor )
{
var autoAttributes =
{
value : 1,
size : 1,
maxLength : 1
};
var acceptedTypes =
{
text : 1,
password :... | PypiClean |
/GRADitude-0.1.3-py3-none-any.whl/graditudelib/correlation_specific_gene.py | import pandas as pd
from scipy.stats import spearmanr
from scipy.stats import pearsonr
def corr_specific_gene_vs_all(feature_count_table,
feature_count_start_column,
feature_count_end_column,
name_column_with_genes_name,
... | PypiClean |
/AASMessenger_Server-1.0.1.tar.gz/AASMessenger_Server-1.0.1/server/server/main_window.py | from PyQt5.QtWidgets import QMainWindow, QAction, qApp, QLabel, QTableView
from PyQt5.QtGui import QStandardItemModel, QStandardItem
from PyQt5.QtCore import QTimer
from server.stat_window import StatWindow
from server.config_window import ConfigWindow
from server.add_user import RegisterUser
from server.remove_user i... | PypiClean |
/DynamicForms-0.74.8-py3-none-any.whl/dynamicforms_legacy/action.py | import uuid as uuid_module
from enum import IntEnum
from typing import Iterable, List, Union
from django.utils.translation import gettext_lazy as _
from rest_framework.serializers import Serializer
from .settings import DYNAMICFORMS
class ActionBase(object):
def __init__(self, action_js: str, name: Union[str, N... | PypiClean |
/MedPy-0.4.0.tar.gz/MedPy-0.4.0/medpy/core/logger.py |
# build-in module
import sys
import logging
from logging import Logger as NativeLogger
# third-party modules
# own modules
# constants
# code
class Logger (NativeLogger):
r"""Logger to be used by all applications and classes.
Notes
-----
Singleton class i.e. setting the log level changes the o... | PypiClean |
/GalSim-2.4.11-cp37-cp37m-manylinux_2_17_i686.manylinux2014_i686.whl/galsim/phase_psf.py |
from heapq import heappush, heappop
import numpy as np
from .gsobject import GSObject
from .gsparams import GSParams
from .angle import radians, degrees, arcsec, Angle, AngleUnit
from .image import Image, _Image
from .bounds import _BoundsI
from .wcs import PixelScale
from .interpolatedimage import InterpolatedImage
... | PypiClean |
/EnergyFlow-1.3.2.tar.gz/EnergyFlow-1.3.2/energyflow/efm.py | r"""# Energy Flow Moments
Energy Flow Moments (EFMs) are tensors that can be computed in
$\mathcal O(M)$ where $M$ is the number of particles. They are useful for many
things, including providing a fast way of computing the $\beta=2$ EFPs, which
are the scalar contractions of products of EFMs.
The expression for a (n... | PypiClean |
/MufSim-1.2.2.tar.gz/MufSim-1.2.2/mufsim/insts/mcpgui.py | from mudclientprotocol import (
McpMessage, McpPackage, mktoken
)
from mufsim.errors import MufRuntimeError
from mufsim.insts.base import Instruction, instr
from mufsim.interface import network_interface
import mufsim.stackitems as si
existing_dialogs = {}
def get_dlog(dlogid):
global existing_dialogs
... | PypiClean |
/EQSN-0.0.8.tar.gz/EQSN-0.0.8/eqsn/gates.py | import multiprocessing
import logging
import numpy as np
from eqsn.qubit_thread import SINGLE_GATE, MERGE_SEND, MERGE_ACCEPT, MEASURE, \
MEASURE_NON_DESTRUCTIVE, GIVE_STATEVECTOR, DOUBLE_GATE, \
CONTROLLED_GATE, NEW_QUBIT, ADD_MERGED_QUBITS_TO_DICT, CONTROLLED_TWO_GATE
from eqsn.shared_dict import SharedDict
fr... | PypiClean |
/Minio_hung-0.0.7.1.tar.gz/Minio_hung-0.0.7.1/src/minio_hung/ReadMinio.py | from importlib.resources import read_text
from minio import Minio
import pandas as pd
from io import BytesIO
import os
def readcsv(ACCESS_KEY,PRIVATE_KEY,BUCKET_NAME,OBJECT_NAME):
client = Minio(
"apilakedpa.apps.xplat.fis.com.vn",
access_key=ACCESS_KEY,
secret_key=PRIVATE_KEY,
secu... | PypiClean |
/Firefly_III_API_Client-2.0.5.0-py3-none-any.whl/firefly_iii_client/paths/v1_budgets_id_limits_limit_id_transactions/get.py | from dataclasses import dataclass
import typing_extensions
import urllib3
from urllib3._collections import HTTPHeaderDict
from firefly_iii_client import api_client, exceptions
from datetime import date, datetime # noqa: F401
import decimal # noqa: F401
import functools # noqa: F401
import io # noqa: F401
import re... | PypiClean |
/FreePyBX-1.0-RC1.tar.gz/FreePyBX-1.0-RC1/freepybx/public/js/dojox/mobile/app/SceneController.js.uncompressed.js | define("dojox/mobile/app/SceneController", ["dijit","dojo","dojox","dojo/require!dojox/mobile/_base"], function(dijit,dojo,dojox){
dojo.provide("dojox.mobile.app.SceneController");
dojo.experimental("dojox.mobile.app.SceneController");
dojo.require("dojox.mobile._base");
(function(){
var app = dojox.mobile.app;
va... | PypiClean |
/EmBCI-0.1.2.tar.gz/EmBCI-0.1.2/README_zh.md | # 用户使用说明
- 开机自动运行主程序 `只在PC上测试了,使用crontab是个很好的办法`
- 屏幕显示波形以及一些信息 `GUI写有初始Menu,选择任务比如显示波形,显示信息,等等,关于ScreenGUI的一切使用可以看 utils/visualization.py 里面的 Screen_GUI 类,比较简易的实现GUI功能,按钮绑定回调函数,run_me1.py就是示例`
- 如果想要orangepi自动连接wifi,需在开机前提供一个无密码的wifi,或者使用orangepi作为热点让电脑连接
## 开机自动运行控制
[cron](https://en.wikipedia.org/wiki/Cron)
# 开发人员... | PypiClean |
/NuPlone-2.2.0.tar.gz/NuPlone-2.2.0/docs/changes.rst | Changelog
=========
2.2.0 (2023-06-14)
------------------
- Support Plone 6
[ale-rt]
2.1.4 (2023-01-04)
------------------
- Sitemenu: Add a helper method to add submenus to existing categories.
[thet]
- Update pre-commit config.
[thet]
- Update buildout, test and CI infrastructure.
[thet]
2.1.3 (2022-09... | PypiClean |
/DJModels-0.0.6-py3-none-any.whl/djmodels/core/management/commands/loaddata.py | import functools
import glob
import gzip
import os
import sys
import warnings
import zipfile
from itertools import product
from djmodels.apps import apps
from djmodels.conf import settings
from djmodels.core import serializers
from djmodels.core.exceptions import ImproperlyConfigured
from djmodels.core.management.base... | PypiClean |
/LogTrace-0.1.2.tar.gz/LogTrace-0.1.2/README.txt | LogTrace
========
|Build Status|
Aggregate messages to produce a log entry representing a single event or
procedure. The purpose of this module is to easily asssociate log
messages together that belong together.
::
import logging
from logtrace import LogTrace
logger = logging.getLogger(__name__)
tr... | PypiClean |
/MaterialDjango-0.2.5.tar.gz/MaterialDjango-0.2.5/bower_components/neon-animation/guides/neon-animation.md | ---
title: neon-animation
summary: "A short guide to neon-animation and neon-animated-pages"
tags: ['animation','core-animated-pages']
elements: ['neon-animation','neon-animated-pages']
updated: 2015-05-26
---
# neon-animation
`neon-animation` is a suite of elements and behaviors to implement pluggable animated trans... | PypiClean |
/Electrum-CHI-3.3.8.tar.gz/Electrum-CHI-3.3.8/electrum_chi/electrum/gui/qt/password_dialog.py |
import re
import math
from PyQt5.QtCore import Qt
from PyQt5.QtGui import QPixmap
from PyQt5.QtWidgets import QLineEdit, QLabel, QGridLayout, QVBoxLayout, QCheckBox
from electrum.i18n import _
from electrum.plugin import run_hook
from .util import icon_path, WindowModalDialog, OkButton, CancelButton, Buttons
def ... | PypiClean |
/Doxhooks-0.6.0.zip/Doxhooks-0.6.0/doxhooks/filetrees.py | import os
import re
from doxhooks.errors import DoxhooksDataError, DoxhooksLookupError
__all__ = [
"FileTree",
"normalise_path",
]
_starts_with_sep = re.compile(r"[\\/]" if os.name == "nt" else "/").match
_is_explicit_relative_path = re.compile(
r"\.$|\.[\\/]" if os.name == "nt" else r"\.$|\./"
).matc... | PypiClean |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.