id stringlengths 1 265 | text stringlengths 6 5.19M | dataset_id stringclasses 7
values |
|---|---|---|
/CC-dbgen-0.2.0.tar.gz/CC-dbgen-0.2.0/dbgen/cli/main.py | import argparse
import sys
from catalog import __version__
from importlib import import_module # type: ignore
commands = [
('run', 'dbgen.cli.run')]
def main(prog ='catalog', description='catalog command line tool',
version=__version__, commands=commands, hook=None, args=None):
parser = argparse.Ar... | PypiClean |
/GTW-1.2.6.tar.gz/GTW-1.2.6/_RST/Signed_Token.py |
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from __future__ import unicode_literals
from _GTW import GTW
from _TFL import TFL
from _TFL._Meta.Once_Property import Once_Property
from _TFL.I18N ... | PypiClean |
/Euphorie-15.0.2.tar.gz/Euphorie-15.0.2/src/euphorie/client/resources/oira/script/chunks/89968.33ca1b757cc9af077aef.min.js | (self.webpackChunk_patternslib_patternslib=self.webpackChunk_patternslib_patternslib||[]).push([[89968],{89968:function(e){e.exports=function(e){const a={$pattern:e.UNDERSCORE_IDENT_RE,keyword:"abstract alias align asm assert auto body break byte case cast catch class const continue debug default delete deprecated do e... | PypiClean |
/Buycoins%20Python%20SDK-0.0.1.tar.gz/Buycoins Python SDK-0.0.1/buycoins_sdk/client/client.py | from python_graphql_client import GraphqlClient
import base64
from requests import exceptions
from buycoins_sdk.commons import errors, type_to_field
from buycoins_sdk.commons.enums import Cryptocurrency, GetOrdersStatus, BuycoinsType, OrderSide, \
PriceType
from typing import Any, Dict, List
__all__ = [
'Buyco... | PypiClean |
/FamcyDev-0.3.71-py3-none-any.whl/Famcy/bower_components/bootstrap/site/assets/js/vendor/anchor.min.js | !function(A,e){"use strict";"function"==typeof define&&define.amd?define([],e):"object"==typeof module&&module.exports?module.exports=e():(A.AnchorJS=e(),A.anchors=new A.AnchorJS)}(this,function(){"use strict";return function(A){function d(A){A.icon=Object.prototype.hasOwnProperty.call(A,"icon")?A.icon:"",A.visible=Ob... | PypiClean |
/ABBA-QuPath-RegistrationExporter-0.4.2.tar.gz/ABBA-QuPath-RegistrationExporter-0.4.2/regexport/actions/download_biop_extensions.py | from pathlib import Path
from zipfile import ZipFile
from PySide2.QtCore import QThreadPool
from PySide2.QtWidgets import QFileDialog, QAction
from regexport.utils.parallel import Task
class SaveBiopExtensionsActionModel:
text = "-1. Download BIOP Extensions"
def submit(self, directory: Path):
impo... | PypiClean |
/Hocrox-0.3.0.tar.gz/Hocrox-0.3.0/hocrox/layer/augmentation/flip/random_horizontal_flip.py | import cv2
from hocrox.utils import Layer
class RandomHorizontalFlip(Layer):
"""RandomHorizontalFlip layer randomly flips an image horizontally.
Here is an example code to use the RandomHorizontalFlip layer in a model.
```python
from hocrox.model import Model
from hocrox.layer.augmentation.flip... | PypiClean |
/CT3-3.3.2-cp310-cp310-macosx_10_9_x86_64.whl/Cheetah/Tests/Regressions.py | try:
from cgi import escape as html_escape
except ImportError: # Python 3.8+
from html import escape as html_escape
import unittest
import Cheetah.NameMapper
import Cheetah.Template
from Cheetah.compat import unicode # noqa
class GetAttrException(Exception):
pass
class CustomGetAttrClass(object):
... | PypiClean |
/DjAIoT-23.6.21.1.tar.gz/DjAIoT-23.6.21.1/src/djaiot/device_data/models/measurement_unit.py | class MeasurementUnitBlobData(
_ModelWithDescriptionsMixInABC,
_ModelWithIntPKMixInABC,
_ModelWithObjectsManagerAndDefaultMetaOptionsMixInABC):
class Meta(
_ModelWithDescriptionsMixInABC.Meta,
_ModelWithObjectsManagerAndDefaultMetaOptionsMixInABC.Meta):
# TODO... | PypiClean |
/Flask-MDEditor-0.1.4.tar.gz/Flask-MDEditor-0.1.4/flask_mdeditor/static/mdeditor/js/lib/codemirror/addon/edit/matchbrackets.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) {
var ... | PypiClean |
/FiPy-3.4.4.tar.gz/FiPy-3.4.4/fipy/viewers/viewer.py | from __future__ import print_function
from __future__ import unicode_literals
from builtins import object
__docformat__ = 'restructuredtext'
__all__ = ["AbstractViewer"]
from future.utils import text_to_native_str
__all__ = [text_to_native_str(n) for n in __all__]
import sys
from future.utils import with_metaclass
... | PypiClean |
/Brian2-2.5.4-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl/brian2/input/timedarray.py | import numpy as np
from brian2.core.clocks import defaultclock
from brian2.core.functions import Function
from brian2.core.names import Nameable
from brian2.units.allunits import second
from brian2.units.fundamentalunits import (
Quantity,
check_units,
get_dimensions,
get_unit,
)
from brian2.utils.cach... | PypiClean |
/MovieKit-1.4.tar.gz/MovieKit-1.4/README.md | # MovieKit
### About
MovieKit is a python package that includes the class MovieDiary to store the movies you've watched in a pandas dataframe
and in a csv-file. Furthermore, it includes information about this movie like a personal evaluation, where you've
watched it and the category (e.g. cinema, netflix, etc.).
... | PypiClean |
/Melodie-0.7.0-cp38-cp38-win_amd64.whl/MelodieInfra/lowcode/astmani/model_static_inspector.py | import ast
import os
import sys
from typing import Dict, List, Optional, Type, TYPE_CHECKING, Union
import astunparse
import pprintast
if TYPE_CHECKING:
from Melodie import Agent, DataCollector, Environment, Model
def get_model_ast(model: 'Type[Model]'):
file = sys.modules[model.__module__].__file__
wit... | PypiClean |
/MatchZoo-2.2.0.tar.gz/MatchZoo-2.2.0/matchzoo/contrib/models/diin.py | import typing
import keras
import keras.backend as K
import tensorflow as tf
from matchzoo import preprocessors
from matchzoo.contrib.layers import DecayingDropoutLayer
from matchzoo.contrib.layers import EncodingLayer
from matchzoo.engine import hyper_spaces
from matchzoo.engine.base_model import BaseModel
from matc... | PypiClean |
/Adafruit_Blinka-8.20.1-py3-none-any.whl/adafruit_blinka/microcontroller/nova/pwmout.py | """PWMOut Class for Binho Nova"""
try:
from microcontroller.pin import pwmOuts
except ImportError:
raise RuntimeError("No PWM outputs defined for this board") from ImportError
from microcontroller.pin import Pin
# pylint: disable=unnecessary-pass
class PWMError(IOError):
"""Base class for PWM errors."""... | PypiClean |
/MatSense-0.4.0-py3-none-any.whl/matsense/visual/player1d.py | from collections import deque
import time
import matplotlib.pyplot as plt
from matplotlib import animation
from matplotlib.offsetbox import AnchoredText
import sys
from .player import Player
class Player1D(Player):
backend = "matplotlib"
## channels: number of data channels
## timespan: visible time span, in se... | PypiClean |
/BEAT_TEST-0.13.1.tar.gz/BEAT_TEST-0.13.1/econml/sklearn_extensions/model_selection.py | import numbers
import warnings
import sklearn
from sklearn.base import BaseEstimator
from sklearn.utils.multiclass import type_of_target
import numpy as np
import scipy.sparse as sp
from joblib import Parallel, delayed
from sklearn.base import clone, is_classifier
from sklearn.model_selection import KFold, StratifiedKF... | PypiClean |
/FP-SMC-ALS-test1-0.0.1.tar.gz/FP-SMC-ALS-test1-0.0.1/smc/core/addon.py | from smc.base.model import Element
from smc.base.structs import NestedDict
from smc.compat import is_api_version_less_than
from smc.elements.profiles import SandboxService, SandboxDataCenter
from smc.elements.tags import TrustedCATag
from smc.base.util import element_resolver
# TODO: This module feels like a mess, too... | PypiClean |
/CustomPipeline-0.0.3-py3-none-any.whl/rplibs/yaml/yaml_py2/representer.py | __all__ = ['BaseRepresenter', 'SafeRepresenter', 'Representer',
'RepresenterError']
from error import *
from nodes import *
import datetime
import sys, copy_reg, types
class RepresenterError(YAMLError):
pass
class BaseRepresenter(object):
yaml_representers = {}
yaml_multi_representers = {}
de... | PypiClean |
/HolmesV-2021.10.8.tar.gz/HolmesV-2021.10.8/mycroft/util/audio_utils.py | from copy import deepcopy
import os
import re
import subprocess
import mycroft.configuration
from mycroft.util.log import LOG
try:
import pyaudio
except ImportError:
pyaudio = None
def play_audio_file(uri: str, environment=None):
"""Play an audio file.
This wraps the other play_* functions, choosin... | PypiClean |
/AsynQueue-0.9.8.tar.gz/AsynQueue-0.9.8/asynqueue/info.py | import sys, traceback, inspect, threading
from contextlib import contextmanager
from twisted.internet import defer
from twisted.python import reflect
from asynqueue.va import va
pickle = va.pickle
unicode = va.unicode
def hashIt(*args):
"""
Returns a pretty much unique 32-bit hash for pretty much any
py... | PypiClean |
/Lsm_all_params_env-0.1.tar.gz/Lsm_all_params_env-0.1/Lsm_all_params_env/envs/opt_selfimple/deOpt.py | from opt_selfimple.opt import Optimization
from sko.DE import DE
import numpy as np
import scipy.stats as stats
import copy
hyperparams_DeOpt_default = {
'individual number': 50,
'mutation probability': 0.01,
'precision': 1e-7
}
conditions_DeOpt_default = {
'generate times': 20
}
optConfig_DeOpt_defau... | PypiClean |
/MaterialDjango-0.2.5.tar.gz/MaterialDjango-0.2.5/materialdjango/static/materialdjango/components/bower_components/web-animations-js/src/group-constructors.js |
(function(shared, scope, testing) {
function groupChildDuration(node) {
return node._timing.delay + node.activeDuration + node._timing.endDelay;
}
function constructor(children, timingInput, id) {
this._id = id;
this._parent = null;
this.children = children || [];
this._reparent(this.childr... | PypiClean |
/FamcyDev-0.3.71-py3-none-any.whl/Famcy/bower_components/bootstrap/js/src/carousel.js | import {
defineJQueryPlugin,
getElementFromSelector,
isRTL,
isVisible,
getNextActiveElement,
reflow,
triggerTransitionEnd,
typeCheckConfig
} from './util/index'
import EventHandler from './dom/event-handler'
import Manipulator from './dom/manipulator'
import SelectorEngine from './dom/selector-engine'
i... | PypiClean |
/FastNLP-1.0.1.tar.gz/FastNLP-1.0.1/fastNLP/core/utils/rich_progress.py | import sys
from typing import Any, Union, Optional
from rich.progress import Progress, Console, GetTimeCallable, get_console, TaskID, Live, Text, ProgressSample
from rich.progress import ProgressColumn, TimeRemainingColumn, BarColumn, TimeElapsedColumn, TextColumn
__all__ = [
'f_rich_progress'
]
from fastNLP.env... | PypiClean |
/Muntjac-1.1.2.tar.gz/Muntjac-1.1.2/muntjac/demo/sampler/features/trees/TreeSingleSelectExample.py | from muntjac.demo.sampler.ExampleUtil import ExampleUtil
from muntjac.api import \
HorizontalLayout, Button, Tree, TextField, Alignment
from muntjac.ui import button
from muntjac.data.property import IValueChangeListener
from muntjac.event.action import Action
from muntjac.event import action
from muntjac.ui.abs... | PypiClean |
/MetaGram-2.0.2.tar.gz/MetaGram-2.0.2/pyrogram/types/messages_and_media/game.py |
import pyrogram
from pyrogram import raw
from pyrogram import types
from ..object import Object
class Game(Object):
"""A game.
Use BotFather to create and edit games, their short names will act as unique identifiers.
Parameters:
id (``int``):
Unique identifier of the game.
t... | PypiClean |
/GB2260-v2-0.2.1.tar.gz/GB2260-v2-0.2.1/gb2260_v2/data/curated/revision_201701.py | from __future__ import unicode_literals
name = '201701'
division_schema = {
'110000': '北京市',
'110101': '东城区',
'110102': '西城区',
'110105': '朝阳区',
'110106': '丰台区',
'110107': '石景山区',
'110108': '海淀区',
'110109': '门头沟区',
'110111': '房山区',
'110112': '通州区',
'110113': '顺义区',
'11011... | PypiClean |
/Dero-0.15.0-py3-none-any.whl/dero/pandas.py | import os
import pandas as pd
import datetime
from numpy import nan
from dateutil.relativedelta import relativedelta
import sys
import numpy as np
import warnings, timeit
from sas7bdat import SAS7BDAT
import statsmodels.api as sm
from pandas.tseries.offsets import CustomBusinessDay
from multiprocessing.dummy import Poo... | PypiClean |
/Caboodle-1.0.2.tar.gz/Caboodle-1.0.2/caboodle/challenges/solve_media.py | from caboodle.challenges.spec import Challenge
import caboodle.challenges.util as util
import time
class SolveMediaTextChallenge(Challenge):
'''
A Challenge for Solve Media Text CAPTCHAs
A text CAPTCHA is the traditional type of CAPTCHA with obfuscated squiggly
text. This Challenge will locate it if it exists and... | PypiClean |
/Hate-Tweet-Map-2.0-2.0.tar.gz/Hate-Tweet-Map-2.0-2.0/hate_tweet_map/tweets_processor/TweetProcessor.py | import concurrent
import os
from concurrent.futures import ThreadPoolExecutor, Future, as_completed
from typing import Optional, List, Tuple
import geocoder
import requests
import urllib3.exceptions
import yaml
from feel_it import EmotionClassifier, SentimentClassifier
import spacy
import en_core_web_lg
import it_core... | PypiClean |
/Firefly_III_API_Client-2.0.5.0-py3-none-any.whl/firefly_iii_client/paths/v1_rules/post.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 |
/DeepCell_Toolbox-0.12.1.tar.gz/DeepCell_Toolbox-0.12.1/README.md | # 
[](https://github.com/vanvalenlab/deepcell-toolbox/actions)
[:
def __init__(self, networkapi_url, user, password, user_ldap=None):
"""Class constructor r... | PypiClean |
/Cubane-1.0.11.tar.gz/Cubane-1.0.11/cubane/backend/static/cubane/backend/js/cubane.backend.browse.js | (function (globals){
"use strict";
cubane.namespace('cubane.backend');
cubane.require('cubane.urls');
cubane.require('cubane.dialog');
/*
* Keeps track of selected items within the dialog window and the current
* selection box.
*/
var itemJson = [];
var initialIds = []
var browseBtn = null;
var thumbnailBtn = ... | PypiClean |
/EQcorrscan-0.4.4.tar.gz/EQcorrscan-0.4.4/eqcorrscan/core/__init__.py | import sys
import importlib
import warnings
__all__ = ['template_gen', 'match_filter', 'lag_calc', 'subspace']
_import_map = {}
_depreciated = ['template_gen.from_sfile', 'template_gen.from_contbase']
class EQcorrscanDeprecationWarning(UserWarning):
"""
Force pop-up of warnings.
"""
pass
class EQ... | PypiClean |
/DjangoDjangoAppCenter-0.0.11-py3-none-any.whl/DjangoAppCenter/simpleui/static/admin/simpleui-x/elementui/upload.js | module.exports =
/******/ (function (modules) { // webpackBootstrap
/******/ // The module cache
/******/
var installedModules = {};
/******/
/******/ // The require function
/******/
function __webpack_require__(moduleId) {
/******/
/******/ // Check if module is in ... | PypiClean |
/0x_contract_wrappers-2.0.0-py3-none-any.whl/zero_ex/contract_wrappers/erc20_token/__init__.py |
# pylint: disable=too-many-arguments
import json
from typing import ( # pylint: disable=unused-import
Any,
List,
Optional,
Tuple,
Union,
)
from eth_utils import to_checksum_address
from mypy_extensions import TypedDict # pylint: disable=unused-import
from hexbytes import HexBytes
from web3 impo... | PypiClean |
/JEMSVIDEOSDXL-0.8.1.tar.gz/JEMSVIDEOSDXL-0.8.1/stable_diffusion_videos/stable_diffusion_pipeline.py | import inspect
import math
import json
import time
from pathlib import Path
from typing import Callable, List, Optional, Union, Tuple
import numpy as np
import torch
from diffusers.configuration_utils import FrozenDict
from diffusers.models import AutoencoderKL, UNet2DConditionModel
from diffusers.pipeline_utils impor... | PypiClean |
/Django-4.2.4.tar.gz/Django-4.2.4/django/contrib/auth/backends.py | import warnings
from django.contrib.auth import get_user_model
from django.contrib.auth.models import Permission
from django.db.models import Exists, OuterRef, Q
from django.utils.deprecation import RemovedInDjango50Warning
from django.utils.inspect import func_supports_parameter
UserModel = get_user_model()
class ... | PypiClean |
/CNN4IE-0.1.9-py3-none-any.whl/cnn4ie/multi_cnn/predict.py | import torch
import os
from configparser import ConfigParser
import pickle
from cnn4ie.multi_cnn.train import Train
from cnn4ie.util.crf_util import get_tags, format_result
DEVICE = torch.device('cuda' if torch.cuda.is_available() else 'cpu')
class Predict():
def __init__(self):
self.model = None
... | PypiClean |
/Kr0nOs-3.4.1.tar.gz/Kr0nOs-3.4.1/kronbot/cogs/economy/economy.py | import calendar
import logging
import random
from collections import defaultdict, deque, namedtuple
from enum import Enum
from typing import Iterable, Union, cast
import discord
from kronbot.cogs.bank import is_owner_if_bank_global
from kronbot.cogs.mod.converters import RawUserIds
from kronbot.core import Config, ba... | PypiClean |
/ModelSEEDpy-freiburgermsu-0.3.1.4.tar.gz/ModelSEEDpy-freiburgermsu-0.3.1.4/modelseedpy_freiburgermsu/fbapkg/problemreplicationpkg.py |
from __future__ import absolute_import
from modelseedpy_freiburgermsu.fbapkg.basefbapkg import BaseFBAPkg
from optlang import Variable
import logging
# Base class for FBA packages
class ProblemReplicationPkg(BaseFBAPkg):
def __init__(self, model):
BaseFBAPkg.__init__(self, model, "problem replication", ... | PypiClean |
/NQPV-0.4b1-py3-none-any.whl/nqpv/vsystem/content/proof_tacits.py |
from __future__ import annotations
from typing import Any, List, Dict, Tuple
from nqpv.vsystem.log_system import RuntimeErrorWithLog
from nqpv.vsystem.var_scope import VarScope
from .qvarls_term import QvarlsTerm
from .qpre_term import *
from .proof_hint_term import *
from .proof_term import *
def construct_proof(... | PypiClean |
/CoAPthon3-1.0.2.tar.gz/CoAPthon3-1.0.2/coapthon/messages/option.py | from coapthon import defines
from coapthon.utils import byte_len
__author__ = 'Giacomo Tanganelli'
class Option(object):
"""
Class to handle the CoAP Options.
"""
def __init__(self):
"""
Data structure to store options.
"""
self._number = None
self._value = Non... | PypiClean |
/AIKIF-0.2.2.tar.gz/AIKIF-0.2.2/aikif/index.py |
import os
import sys
import codecs
root_folder = os.path.abspath(os.path.dirname(os.path.abspath(__file__)))
sys.path.append(root_folder)
import cls_log as mod_log
import config as mod_cfg
import lib.cls_filelist as mod_fl
silent = 'N'
if len(sys.argv) == 2:
if sys.argv[1] == 'Q':
silent = 'Y'
ndxPath ... | PypiClean |
/JyPlotter-0.9.4.tar.gz/JyPlotter-0.9.4/PyPlotter/awtGfx.py | import math
import java, pawt
from java import awt, applet
import Gfx
from Compatibility import *
driverName = "awtGfx"
########################################################################
#
# class Driver
#
########################################################################
white = java.awt.Color.WHITE... | PypiClean |
/Myghty-1.2.tar.gz/Myghty-1.2/lib/myghty/http/CGIHandler.py |
import myghty.interp
import myghty.request
import myghty.resolver
import myghty.session as session
import myghty.exception as exception
import myghty.http.HTTPHandler as HTTPHandler
from myghty.util import *
import os, sys, cgi
def handle(*args, **params):
return HTTPHandler.handle_http(CGIHandler, *args, **para... | PypiClean |
/Faker-19.3.1.tar.gz/Faker-19.3.1/faker/providers/address/en_AU/__init__.py | from ..en import Provider as AddressProvider
class Provider(AddressProvider):
city_prefixes = ("North", "East", "West", "South", "New", "Lake", "Port", "St.")
city_suffixes = (
"town",
"ton",
"land",
"ville",
"berg",
"burgh",
"borough",
"bury",
... | PypiClean |
/MnemoPwd-1.2.1-py3-none-any.whl/mnemopwd/pyelliptic/openssl.py |
# Copyright (c) 2014 Yann GUIBET <yannguibet@gmail.com>.
# All rights reserved.
#
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:
#
# 1. Redistributions of source code must retain the above copyright
# notice... | PypiClean |
/NiftiResampler-0.1.0.tar.gz/NiftiResampler-0.1.0/README.md | # Resample_Class
For resampling nifti images (likely for medical purposes)
## Installation
```
pip install NiftiResampler
```
### Usage
```python
from NiftiResampler.ResampleTools import ImageResampler, sitk
Resampler = ImageResampler()
base_image = sitk.ReadImage(image_path)
desired_dimensions = (0.975, 0.97... | PypiClean |
/JitsiProvS-0.10b1.tar.gz/JitsiProvS-0.10b1/jitsiprovs/libdata.py | def default_properties ():
props = []
props.append( ('net.java.sip.communicator.impl.gui.main.configforms.SHOW_ACCOUNT_CONFIG', 'false') )
props.append( ('net.java.sip.communicator.impl.gui.main.configforms.SHOW_OPTIONS_WINDOW', 'false') )
props.append( ('net.java.sip.communicator.impl.gui.main.configfo... | PypiClean |
/ConsenSys-Utils-0.2.0b1.tar.gz/ConsenSys-Utils-0.2.0b1/consensys_utils/config/schema/flask.py | import cfg_loader
from marshmallow import fields
from .gunicorn import GunicornConfigSchema
from .logging import LoggingConfigSchema
from .web3 import Web3ConfigSchema
from .wsgi import WSGIConfigSchema
class BaseConfigSchema(cfg_loader.ConfigSchema):
"""Base flask configuration schema
Describes and validat... | PypiClean |
/ClusterShell-1.9.1.tar.gz/ClusterShell-1.9.1/doc/sphinx/tools/clubak.rst | .. _clubak-tool:
clubak
------
.. highlight:: console
Overview
^^^^^^^^
*clubak* is another utility provided with the ClusterShell library that try to
gather and sort such dsh-like output::
node17: MD5 (cstest.py) = 62e23bcf2e11143d4875c9826ef6183f
node14: MD5 (cstest.py) = 62e23bcf2e11143d4875c9826ef6183f... | PypiClean |
/Discogs-APY-1.0.tar.gz/Discogs-APY-1.0/README.md | # Discogs-APY
A lightweight Python wrapper for the Discogs API.
### Usage
Initialise the client using your user token. No support for OAuth yet. Maybe I'll get around to it.
```
client = Discogs-APY.Client(user_token)
```
The client object has Release, Master, Artist, and Label methods. Calling them with a valid disco... | PypiClean |
/Mezzanine-6.0.0.tar.gz/Mezzanine-6.0.0/mezzanine/forms/models.py | from django.db import models
from django.utils.translation import gettext_lazy as _
from mezzanine.conf import settings
from mezzanine.core.fields import RichTextField
from mezzanine.core.models import Orderable, RichText, wrapped_manager
from mezzanine.forms import fields
from mezzanine.pages.models import Page
cla... | PypiClean |
/Mezzanine-6.0.0.tar.gz/Mezzanine-6.0.0/mezzanine/blog/feeds.py | from django.contrib.auth import get_user_model
from django.contrib.sites.models import Site
from django.contrib.syndication.views import Feed, add_domain
from django.shortcuts import get_object_or_404
from django.urls import reverse
from django.utils.feedgenerator import Atom1Feed
from django.utils.html import strip_ta... | PypiClean |
/BlueWhale3-3.31.3.tar.gz/BlueWhale3-3.31.3/Orange/widgets/utils/combobox.py | from AnyQt.QtCore import Qt
from AnyQt.QtGui import QBrush, QColor, QPalette, QPen, QFont, QFontMetrics
from AnyQt.QtWidgets import QStylePainter, QStyleOptionComboBox, QStyle
from orangewidget.utils.combobox import ComboBoxSearch, ComboBox
__all__ = [
"ComboBoxSearch", "ComboBox", "ItemStyledComboBox"
]
class ... | PypiClean |
/dirtrav-1.0.0.tar.gz/dirtrav-1.0.0/docs/tutorial/templates.rst | .. currentmodule:: flask
Templates
=========
You've written the authentication views for your application, but if
you're running the server and try to go to any of the URLs, you'll see a
``TemplateNotFound`` error. That's because the views are calling
:func:`render_template`, but you haven't written the templates yet... | PypiClean |
/CC-Adsorber-0.1.2.tar.gz/CC-Adsorber-0.1.2/adsorber/objects/adsorbate.py | import typing as typ
# External Modules
import numpy as np # type: ignore
from ase import Atoms # type: ignore
import ase.data # type: ignore
################################################################################
##############
# Adsorbates #
##############
class Adsorbate(object... | PypiClean |
/Flask-Cache2-0.13.1.tar.gz/Flask-Cache2-0.13.1/docs/_themes/flask_theme_support.py | from pygments.style import Style
from pygments.token import Keyword, Name, Comment, String, Error, \
Number, Operator, Generic, Whitespace, Punctuation, Other, Literal
class FlaskyStyle(Style):
background_color = "#f8f8f8"
default_style = ""
styles = {
# No corresponding class for the follow... | PypiClean |
/MTGProxyPrinter-0.25.0.tar.gz/MTGProxyPrinter-0.25.0/mtg_proxy_printer/document_controller/compact_document.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 |
/Hikka_TL_New-2.0.4-py3-none-any.whl/hikkatl/tl/types/storage.py | from ...tl.tlobject import TLObject
from typing import Optional, List, Union, TYPE_CHECKING
import os
import struct
from datetime import datetime
class FileGif(TLObject):
CONSTRUCTOR_ID = 0xcae1aadf
SUBCLASS_OF_ID = 0xf3a1e6f3
def to_dict(self):
return {
'_': 'FileGif'
}
... | PypiClean |
/BlueWhale3_Text-1.6.0-py3-none-any.whl/orangecontrib/text/widgets/owtopicmodeling.py | import functools
from typing import Any
import numpy as np
from AnyQt import QtGui, QtCore
from AnyQt.QtCore import pyqtSignal, QSize
from AnyQt.QtWidgets import (QVBoxLayout, QButtonGroup, QRadioButton,
QGroupBox, QTreeWidgetItem, QTreeWidget,
QStyleOptionVie... | PypiClean |
/FreePyBX-1.0-RC1.tar.gz/FreePyBX-1.0-RC1/freepybx/public/js/dijit/place.js | define("dijit/place",["dojo/_base/array","dojo/dom-geometry","dojo/dom-style","dojo/_base/kernel","dojo/_base/window","dojo/window","."],function(_1,_2,_3,_4,_5,_6,_7){
function _8(_9,_a,_b,_c){
var _d=_6.getBox();
if(!_9.parentNode||String(_9.parentNode.tagName).toLowerCase()!="body"){
_5.body().appendChild(_9);
}
var... | PypiClean |
/KratosOptimizationApplication-9.4-cp310-cp310-win_amd64.whl/KratosMultiphysics/OptimizationApplication/processes/optimization_problem_vtu_output_process.py | from typing import Any, Union
from abc import ABC, abstractmethod
from pathlib import Path
import KratosMultiphysics as Kratos
import KratosMultiphysics.kratos_utilities as kratos_utils
import KratosMultiphysics.OptimizationApplication as KratosOA
from KratosMultiphysics.OptimizationApplication.responses.response_func... | PypiClean |
/Cohen-0.7.4.tar.gz/Cohen-0.7.4/coherence/base.py |
# Copyright 2006,2007,2008 Frank Scholz <coherence@beebits.net>
import socket
import traceback
import copy
import logging
import os
from twisted.internet.tcp import CannotListenError
from twisted.internet import defer
from twisted.internet import reactor
from twisted.web import resource, static
from coherence import... | PypiClean |
/OPML_Methods-0.1.14.tar.gz/OPML_Methods-0.1.14/OPML_Methods/ExpRegres.py | from sympy import *
import numpy as np
import math
import matplotlib.pyplot as plt
import numexpr as ne
from .AdjGrad import *
from .brent import *
class ExpRegres:
def find(y, x, n, m, reg, L, sigma):
"""
Реализует модель экспоненциалной регрессии 3 видами регуляторов: L1, L2 и Стьюдента.... | PypiClean |
/MetaGram-2.0.2.tar.gz/MetaGram-2.0.2/pyrogram/types/messages_and_media/web_page.py |
import pyrogram
from pyrogram import raw
from pyrogram import types
from ..object import Object
class WebPage(Object):
# TODO: hash, cached_page
"""A webpage preview
Parameters:
id (``str``):
Unique identifier for this webpage.
url (``str``):
Full URL for this we... | PypiClean |
/MRFI-2.0.0.tar.gz/MRFI-2.0.0/docs/usage_easyconfig.md | # EasyConfig usage
## EasyConfig YAML format
YAML is a human readable format that uses white space indentation to represent levels and rows to represent list and dictionary items.
See [yaml.org](https://yaml.org).
### Full EasyConfig YAML template
```yaml title="full easyconfig template"
faultinject:
- type: act... | PypiClean |
/Antonina1-1.0.6.tar.gz/Antonina1-1.0.6/README.md | 📦 setup.py (for humans)
=======================
This repo exists to provide [an example setup.py] file, that can be used
to bootstrap your next Python project. It includes some advanced
patterns and best practices for `setup.py`, as well as some
commented–out nice–to–haves.
For example, this `setup.py` provi... | PypiClean |
/LibRecommender-1.3.0-cp38-cp38-macosx_10_9_x86_64.whl/libreco/bases/cf_base.py | import abc
import os
import random
from functools import partial
from itertools import islice, takewhile
from operator import itemgetter
import numpy as np
from scipy.sparse import issparse
from scipy.sparse import load_npz as load_sparse
from scipy.sparse import save_npz as save_sparse
from .base import Base
from ..... | PypiClean |
/Aesthete-0.4.2.tar.gz/Aesthete-0.4.2/aesthete/glypher/Phrase.py | import glypher as g
from aobject.utils import debug_print
import StringIO
import cairo
import time
import copy
import traceback
import sympy
import draw
import Entity
import Parser
import gutils
import lxml.etree as ET
# Comparison functions
ac = gutils.array_close
fc = gutils.float_close
fgte = gutils.float_greater_t... | PypiClean |
/Cobra2D-0.5.0.tar.gz/Cobra2D-0.5.0/src/cobra2d/duplication/duplication.py | from logging import StreamHandler, getLogger
from pathlib import Path
from typing import List, Optional, Union
from cobra.core import Gene, Group, Metabolite, Model, Reaction
from cobra.core.configuration import Configuration
from cobra.exceptions import OptimizationError
from cobra.util import linear_reaction_coeffic... | PypiClean |
/OctoPrint-1.9.2.tar.gz/OctoPrint-1.9.2/src/octoprint/plugins/softwareupdate/version_checks/git_commit.py | __author__ = "Gina Häußge <osd@foosel.net>"
__license__ = "GNU Affero General Public License http://www.gnu.org/licenses/agpl.html"
__copyright__ = "Copyright (C) 2014 The OctoPrint Project - Released under terms of the AGPLv3 License"
import errno
import logging
import subprocess
import sys
from ..exceptions import... | PypiClean |
/NEMO_stockroom-1.1.1-py3-none-any.whl/NEMO_stockroom/models.py | from datetime import datetime
from NEMO.models import BaseModel, Consumable, ConsumableWithdraw, Project, User
from django.db import models
from django.utils import timezone
class ConsumableRequest(BaseModel):
customer = models.ForeignKey(User, related_name="consumable_requester", help_text="The user who will use th... | PypiClean |
/Beads-0.1.4-py3-none-any.whl/beads/resources/ui/js/gui.js | var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
return new (P || (P = Promise))(function (resolve, reject) {
function fulfilled(value) { try { step(gene... | PypiClean |
/aleksis_core-3.1.5-py3-none-any.whl/aleksis/core/preferences.py | from django.conf import settings
from django.forms import EmailField, ImageField, URLField
from django.forms.widgets import SelectMultiple
from django.utils.translation import gettext_lazy as _
from colorfield.widgets import ColorWidget
from dynamic_preferences.preferences import Section
from dynamic_preferences.types... | PypiClean |
/NucleoATAC-0.3.4.tar.gz/NucleoATAC-0.3.4/nucleoatac/Occupancy.py | from scipy import signal, optimize, stats
import numpy as np
import matplotlib.pyplot as plt
import pyximport; pyximport.install(setup_args={"include_dirs":np.get_include()})
from pyatac.fragmentsizes import FragmentSizes
from pyatac.tracks import Track, CoverageTrack
from pyatac.chunk import Chunk
from pyatac.utils im... | PypiClean |
/FamcyDev-0.3.71-py3-none-any.whl/Famcy/node_modules/bower/packages/bower-config/README.md | # bower-config
> The Bower config (`.bowerrc`) reader and writer.
[Bower](http://bower.io/) can be configured using JSON in a `.bowerrc` file. For example:
{
"directory": "app/components/",
"timeout": 120000,
"registry": {
"search": [
"http://localhost:8000",
"https:... | PypiClean |
/Django_patch-2.2.19-py3-none-any.whl/django/contrib/admin/sites.py | from functools import update_wrapper
from weakref import WeakSet
from django.apps import apps
from django.contrib.admin import ModelAdmin, actions
from django.contrib.auth import REDIRECT_FIELD_NAME
from django.core.exceptions import ImproperlyConfigured
from django.db.models.base import ModelBase
from django.http imp... | PypiClean |
/Clippy-0.6.4.tar.gz/Clippy-0.6.4/clippy/clip.py | import sys
from typing import Callable, Optional, List
from .command_module import create_command_module
def clippy(func: Callable) -> Callable:
"""
Use this as an attribute on a function via `@clippy` to mark a function as available on the command line.
:param func: A callable function; passed by Pytho... | PypiClean |
/MCPoly-0.6.0.tar.gz/MCPoly-0.6.0/README.md | # MCPoly
Some methods to deal with some manipulation of computational chemistry, mostly about mechanical properties of polymers.

## Overview
`MCPoly` is a Python library to make some steps of computational chemistry easier. It includes some functions of drawing molecule structures, creati... | PypiClean |
/Kamaelia-0.6.0.tar.gz/Kamaelia-0.6.0/Tools/VideoPlayer.py | from Kamaelia.Util.Detuple import SimpleDetupler
from Kamaelia.Codec.YUV4MPEG import YUV4MPEGToFrame
from Kamaelia.UI.Pygame.VideoOverlay import VideoOverlay
try:
from Kamaelia.Audio.PyMedia.Output import Output
except ImportError:
print "Sorry, this code requires Pymedia to work."
print "If you want to u... | PypiClean |
/IM-client-1.7.0.post1.tar.gz/IM-client-1.7.0.post1/imclient/imclient.py |
try:
# To avoid annoying InsecureRequestWarning messages in some Connectors
import requests.packages
from requests.packages.urllib3.exceptions import InsecureRequestWarning
requests.packages.urllib3.disable_warnings(InsecureRequestWarning)
except ImportError:
pass
import json
import os
import subp... | PypiClean |
/Euphorie-15.0.2.tar.gz/Euphorie-15.0.2/src/euphorie/client/browser/training.py | from collections import OrderedDict
from datetime import date
from datetime import datetime
from euphorie import MessageFactory as _
from euphorie.client import survey
from euphorie.client import utils
from euphorie.client import utils as client_utils
from euphorie.client.model import Risk
from euphorie.client.model im... | PypiClean |
/FlowMagic-0.3.0.tar.gz/FlowMagic-0.3.0/README.md | #Installation :
` pip install FlowMagic`
# Usage :
```
import FlowMagic
```
### Denote 'main' function
Contains the code the app executes
```python
import FlowMagic
@FlowMagic.main
def process_invoice():
#...magically processing invoice
pass
# To call the main function
FlowMagic.start()
```
**Note**: Don... | PypiClean |
/Modelicares_Revised-1.0-py3-none-any.whl/modelicares/exps/__init__.py | __author__ = "Kevin Davies"
__email__ = "kdavies4@gmail.com"
__copyright__ = ("Copyright 2012-2014, Kevin Davies, Hawaii Natural Energy "
"Institute, and Georgia Tech Research Corporation")
__license__ = "BSD-compatible (see LICENSE.txt)"
import os
import re
import numpy as np
from itertools import ... | PypiClean |
/GaiaXPy-2.1.0.tar.gz/GaiaXPy-2.1.0/gaiaxpy/colour_equation/xp_filter_system_colour_equation.py | import math
from ast import literal_eval
from configparser import ConfigParser
from os import listdir
from pathlib import Path
from typing import Union, Optional
import numpy as np
import pandas as pd
from numpy import poly1d
from tqdm import tqdm
from gaiaxpy.config.paths import filters_path
from gaiaxpy.core.generi... | PypiClean |
/ExifRead-nocycle-3.0.1.tar.gz/ExifRead-nocycle-3.0.1/exifread/__init__.py | import struct
from typing import BinaryIO
from .exif_log import get_logger
from .classes import ExifHeader
from .tags import DEFAULT_STOP_TAG
from .utils import ord_, make_string
from .heic import HEICExifFinder
__version__ = '3.0.1'
logger = get_logger()
class InvalidExif(Exception):
pass
class ExifNotFound(... | PypiClean |
/Flask-CKEditor-0.4.6.tar.gz/Flask-CKEditor-0.4.6/flask_ckeditor/static/full/lang/lv.js | /*
Copyright (c) 2003-2020, CKSource - Frederico Knabben. All rights reserved.
For licensing, see LICENSE.md or https://ckeditor.com/license
*/
CKEDITOR.lang['lv']={"editor":"Bagātinātā teksta redaktors","editorPanel":"Bagātinātā teksta redaktora panelis","common":{"editorHelp":"Palīdzībai, nospiediet ALT 0 ","browseS... | PypiClean |
/GlobalPayments.Api-1.0.9.tar.gz/GlobalPayments.Api-1.0.9/globalpayments/api/utils/__init__.py | import base64
from datetime import datetime
import hashlib
import uuid
from xml.dom import minidom
class ElementTree(object):
"""
Wraps xml.dom.minidom to provide a simpler et
"""
doc = None
namespaces = {}
def __init__(self):
self.doc = minidom.Document()
self.namespaces['so... | PypiClean |
/ICityTool-0.1.1.tar.gz/ICityTool-0.1.1/ICityTool.py | import time
import numpy as np
import pandas as pd
import shutil
import sys
import os
import re
import subprocess
import openpyxl
import sklearn
from imblearn.over_sampling import SMOTE
from collections import Counter
from sklearn.preprocessing import LabelEncoder,OneHotEncoder
from sklearn.model_selection import trai... | PypiClean |
/EmbyPy-0.6.6.4.tar.gz/EmbyPy-0.6.6.4/embypy/emby.py | from simplejson.scanner import JSONDecodeError
import asyncio
from embypy import objects
from embypy.utils import Connector
from embypy.utils.asyncio import async_func
class Emby(objects.EmbyObject):
'''Emby connection class, an object of this type should be created
to communicate with emby
Parameters
... | PypiClean |
/Klampt-0.9.0-cp36-cp36m-win_amd64.whl/klampt/math/autodiff/so3_ad.py | import numpy as np
from .ad import ADFunctionInterface,function
from . import math_ad
from .. import vectorops,so3
import math
SIZE = 9
"""Constant giving the dimension of an so3_ad element"""
identity = lambda: np.array(so3.identity())
"""A 0 argument function that returns the SO(3) identity (just an alias to
so3.i... | PypiClean |
/CNN4IE-0.1.9-py3-none-any.whl/cnn4ie/dcnn/predict.py | import torch
import os
from configparser import ConfigParser
import pickle
from cnn4ie.dcnn.train import Train
from cnn4ie.util.crf_util import get_tags, format_result
DEVICE = torch.device('cuda' if torch.cuda.is_available() else 'cpu')
class Predict():
def __init__(self):
self.model = None
self... | PypiClean |
/Fragmenstein-0.12.11.tar.gz/Fragmenstein-0.12.11/fragmenstein/victor/_victor_place.py | from typing import *
from ._victor_common import _VictorCommon
from rdkit_to_params import Params
from ..monster import Monster
from ..igor import Igor
from rdkit import Chem
from functools import singledispatchmethod
class _VictorPlace(_VictorCommon):
@singledispatchmethod
def place(self,
smile... | PypiClean |
/OZI-0.0.43.tar.gz/OZI-0.0.43/.github/ISSUE_TEMPLATE/feature_request.md | ---
name: Feature request
about: Suggest an idea for this project
title: ''
labels: ''
assignees: ''
---
**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
**Describe the solution you'd like**
A clear and con... | PypiClean |
/FreeClimb-4.5.0-py3-none-any.whl/freeclimb/model/play.py | import re # noqa: F401
import sys # noqa: F401
from freeclimb.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,
vali... | PypiClean |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.