id stringlengths 1 265 | text stringlengths 6 5.19M | dataset_id stringclasses 7
values |
|---|---|---|
/Django%20CustomUser%20Model-1.1.0.tar.gz/Django CustomUser Model-1.1.0/user_app/models.py | import json
from slugify import slugify
from django.utils import timezone
from datetime import date, datetime
from django.db import models
from django.http import JsonResponse
from django.contrib.auth.models import AbstractBaseUser
from django.contrib.auth.models import PermissionsMixin
from django.contrib.auth.models ... | PypiClean |
/FlowTutor-0.9.0.tar.gz/FlowTutor-0.9.0/src/flowtutor/gui/section_structs.py | from __future__ import annotations
from typing import TYPE_CHECKING, Union
import dearpygui.dearpygui as dpg
from flowtutor.flowchart.flowchart import Flowchart
from flowtutor.flowchart.struct_definition import StructDefinition
from flowtutor.flowchart.struct_member import StructMember
from flowtutor.language import La... | PypiClean |
/ModbusGuiApp-1.1-py3-none-any.whl/modbus_gui_app/db_handler.py | import asyncio
import json
import logging
import sqlite3
from concurrent.futures.thread import ThreadPoolExecutor
class Backend:
"""
This class is used to instantiate a connection to the database and provides the methods needed to deal with
that connection.
"""
def __init__(self):
self._c... | PypiClean |
/Nuitka-1.8.tar.gz/Nuitka-1.8/nuitka/build/inline_copy/lib/scons-4.3.0/SCons/SConsign.py | import SCons.compat
import os
import pickle
import time
import SCons.dblite
import SCons.Warnings
from SCons.compat import PICKLE_PROTOCOL
from SCons.Util import print_time
def corrupt_dblite_warning(filename):
SCons.Warnings.warn(
SCons.Warnings.CorruptSConsignWarning,
"Ignoring corrupt .sconsi... | PypiClean |
/BootstrapPy-0.6.tar.gz/BootstrapPy-0.6/bootstrappy/templates/+package+/static/js/bootstrap.min.js | !function(e){"use strict";e(function(){e.support.transition=function(){var e=function(){var e=document.createElement("bootstrap"),t={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"},n;for(n in t)if(e.style[n]!==undefined)return ... | PypiClean |
/Bluebook-0.0.1.tar.gz/Bluebook-0.0.1/pylot/utils.py | from __future__ import division
import os
import re
import string
import random
import urlparse
import socket
import subprocess
import functools
import multiprocessing
import threading
from passlib.hash import bcrypt as crypt_engine
import slugify
import jinja2
def get_base_dir():
"""
Return the base director... | PypiClean |
/LupSeat-1.3.0-py3-none-any.whl/models/room.py | from models.seat import *
def chr_to_int(char):
'''Convert row char to row number
Args:
row (char): ('a', 'b')
Returns:
int: row number (1 to max_row)
'''
return ord(char.lower()) - ord('a') + 1
def int_to_chr(num):
'''Convert row number to row char
Args:
row (int... | PypiClean |
/DeepPhysX.Sofa-22.12.1.tar.gz/DeepPhysX.Sofa-22.12.1/examples/features/Environment/EnvironmentTraining.py | import os
import sys
from numpy import array
# Session related imports
sys.path.append(os.path.dirname(os.path.abspath(__file__)))
from EnvironmentDataset import EnvironmentDataset
# Create an Environment as a BaseEnvironment child class
class EnvironmentTraining(EnvironmentDataset):
def __init__(self,
... | PypiClean |
/MCdeck-0.6.3-py3-none-any.whl/mcdeck/util.py | import http
import ntpath
import platform
import posixpath
import urllib
import urllib.request
from PySide6 import QtWidgets, QtGui, QtCore
from lcgtools import LcgException
from lcgtools.graphics import LcgImage
def loadImageFromFileDialog(parent=None, title='Open image file',
ret_name=... | PypiClean |
/flask_sqlalchemy_whoosh-0.1.3.tar.gz/flask_sqlalchemy_whoosh-0.1.3/src/flask_sqlalchemy_whoosh/mixin.py | from whoosh.qparser import QueryParser
import sqlalchemy.sql
from flask_sqlalchemy import SQLAlchemy
from flask_sqlalchemy.query import Query
from .searcher import WhooshSearcher
class SearchableMixin():
@classmethod
def init_search(cls, searcher: WhooshSearcher, db: SQLAlchemy):
cls.searcher = searc... | PypiClean |
/LibRecommender-limited-0.6.6.6.tar.gz/LibRecommender-limited-0.6.6.6/libreco/algorithms/wave_net.py | from itertools import islice
import os
import numpy as np
import tensorflow.compat.v1 as tf
from tensorflow.keras.initializers import (
truncated_normal as tf_truncated_normal,
glorot_normal as tf_glorot_normal
)
from .base import Base, TfMixin
from ..evaluation.evaluate import EvalMixin
from ..utils.tf_ops imp... | PypiClean |
/CellProfiler-4.2.6.tar.gz/CellProfiler-4.2.6/cellprofiler/modules/findmaxima.py | from skimage.feature import peak_local_max
from skimage.morphology import disk, dilation
from cellprofiler_core.image import Image
from cellprofiler_core.module import ImageProcessing
from cellprofiler_core.setting import Color, Divider
from cellprofiler_core.setting.choice import Choice
from cellprofiler_core.setting... | PypiClean |
/Amplo-0.17.0.tar.gz/Amplo-0.17.0/amplo/api/databricks.py | from __future__ import annotations
import os
from typing import Any
from typing_extensions import Self
from amplo.api._base import BaseRequestAPI
__all__ = ["DatabricksJobsAPI"]
_DATABRICKS_HOST_OS = "DATABRICKS_HOST"
_DATABRICKS_TOKEN_OS = "DATABRICKS_TOKEN"
class DatabricksJobsAPI(BaseRequestAPI):
"""
... | PypiClean |
/MultiRunnable-0.17.0a2-py3-none-any.whl/multirunnable/persistence/database/operator.py | from typing import Tuple, Dict, TypeVar, Generic, Any
from abc import ABC, abstractmethod
from .strategy import BaseDatabaseConnection as _BaseDataBaseConnection, BaseConnectionPool
T = TypeVar("T")
class BaseDatabaseOperator:
def __init__(self, conn_strategy: _BaseDataBaseConnection, db_config: Dict = {}, ti... | PypiClean |
/Firefly_III_API_Client-2.0.5.0-py3-none-any.whl/firefly_iii_client/paths/v1_rules_id/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 |
/GiHaDocs-1.0.5.tar.gz/GiHaDocs-1.0.5/gihadocs/utils/__init__.py | import logging
import os
import pkg_resources
import shutil
import re
import yaml
import fnmatch
import posixpath
from datetime import datetime, timezone
from urllib.parse import urlparse
from gihadocs import exceptions
log = logging.getLogger(__name__)
markdown_extensions = [
'.markdown',
'.mdown',
'.mk... | PypiClean |
/ImpactEffect-0.0.3-py3-none-any.whl/impactEffects/utils/impact.py | from impactEffects.functions.function import *
def atmospheric_entry(impactor: Impactor, target: Target):
"""
Arguments
---------
Returns
-------
"""
i_factor, _av, _rStrength = iFactor(impactor, target)
if i_factor >= 1:
velocity_at_surface = burst_velocity_at_zero(impac... | PypiClean |
/webserver/cosmetics.py | import sanic
from MelloBot.webserver import Sanic
class Cosmetics:
def __init__(self, webserver: Sanic):
self.webserver = webserver
self.clients = webserver.client.clients
def get_client_by_id(self, account_id: str):
client = [c for c in list(self.clients.values()) if c.user.id == acc... | PypiClean |
/Mopidy-Mopify-1.7.3.tar.gz/Mopidy-Mopify-1.7.3/mopidy_mopify/static/debug/src/vendor/angular-prompt/dist/angular-prompt.js | angular.module('cgPrompt',['ui.bootstrap']);
angular.module('cgPrompt').factory('prompt',['$modal','$q',function($modal,$q){
var prompt = function(options){
var defaults = {
title: '',
message: '',
input: false,
label: '',
value: '',
... | PypiClean |
/CantrelleJouisseMamannTest4-0.0.1.tar.gz/CantrelleJouisseMamannTest4-0.0.1/philcantrel/module_carte.py |
# In[1]:
import cartopy.crs as ccrs
import cartopy.feature as cfeature
import matplotlib.pyplot as plt
import imageio
import moviepy
from moviepy.editor import ImageSequenceClip
#fonction pour voir les dechets en France selon les annees voulues
def plot_geo_time_value(x, y, df, lim_metropole = [-5, 10, 41, 52], ... | PypiClean |
/protocols/protocol.py | import datetime
import GcMessageProtocol
from GcMessageProtocol.errors import (
UnknownProtocolException,
UnknownProtocolFieldException,
MissingProtocolFieldsException
)
class Protocol():
split = "%|!%" # Used to separate fields
__field_types = {
"type":( (eval,), (lambda x: '.'.join([x.__m... | PypiClean |
/MyMessenger-0.3.3-py3-none-any.whl/my_messenger/client/core.py | import sys
import logging
import time
from socket import socket, AF_INET, SOCK_STREAM
from queue import Queue
from ..jim.core import *
from ..jim.utils import send_message, get_message
from ..utils import start_thread, get_hash
from ..logger.config import logger_config
from ..logger.decorators import Log
from .errors ... | PypiClean |
/MutPy-Pynguin-0.7.1.tar.gz/MutPy-Pynguin-0.7.1/mutpy/commandline.py | import argparse
import sys
from mutpy import __version__ as version
from mutpy import controller, views, operators, utils
def main(argv):
parser = build_parser()
run_mutpy(parser)
def build_parser():
DEF_TIMEOUT_FACTOR = 5
parser = argparse.ArgumentParser(description='Mutation testing tool for Pyth... | PypiClean |
/energon_prometheus_exporter_main-0.0.1.tar.gz/energon_prometheus_exporter_main-0.0.1/torchdistill-test/examples/hf_transformers/custom/dataset.py | from datasets import load_dataset
from transformers import PretrainedConfig, default_data_collator
from torchdistill.common.constant import def_logger
from torchdistill.datasets.registry import register_collate_func
logger = def_logger.getChild(__name__)
GLUE_TASK2KEYS = {
'ax': ('premise', 'hypothesis'),
'c... | PypiClean |
/Automated_cartography-0.0.2-py3-none-any.whl/Automated/Automated_cartography.py | def get_best_sell_index(PSINrank, sellsnum):
bestsellindex = float(1 / int(PSINrank)) * 1000
sellsnumber = sellsnum * 47
commemts = sellsnum
return bestsellindex, sellsnumber, commemts
def drow_chart(data, filename):
import xlsxwriter
workbook = xlsxwriter.Workbook(filename)
worksheet = ... | PypiClean |
/Flask-RESTy-4.0.2.tar.gz/Flask-RESTy-4.0.2/flask_resty/api.py | import functools
import posixpath
import flask
from werkzeug.exceptions import HTTPException
from .exceptions import ApiError
# -----------------------------------------------------------------------------
# Don't set default value in function so we can assert on None-ness.
DEFAULT_ID_RULE = "<id>"
# -------------... | PypiClean |
/Interlinears-0.2.tar.gz/Interlinears-0.2/README.rst | ============
Interlinears
============
This package pretty-prints plaintext `linguistic interlinears`__,
currently only to HTML.
__ http://en.wikipedia.org/wiki/Interlinear_gloss
It supports two formats:
- ``monospace``, where What You See Is What You Get, though where HTML
can be escaped or stripped away.... | PypiClean |
/Drum-0.4.0.tar.gz/Drum-0.4.0/drum/project_template/project_name/settings.py | from __future__ import absolute_import, unicode_literals
import os
from django import VERSION as DJANGO_VERSION
from django.utils.translation import ugettext_lazy as _
######################
# MEZZANINE SETTINGS #
######################
# The following settings are already defined with default values in
# the ``def... | PypiClean |
/Flask-Security-Too-5.3.0.tar.gz/Flask-Security-Too-5.3.0/docs/api.rst | API
===
The external (json/form) API is described `here`_
.. _here: _static/openapi_view.html
Core
----
.. autoclass:: flask_security.Security
:members:
.. data:: flask_security.current_user
A proxy for the current user.
.. function:: flask_security.Security.unauthorized_handler
If an endpoint fails ... | PypiClean |
/Djblets-3.3.tar.gz/Djblets-3.3/docs/releasenotes/0.5-rc-1.rst | ==============================
Djblets 0.5 RC 1 Release Notes
==============================
**Release date**: May 3, 2009
JavaScript
==========
* Clicking the edit icons for inlineEditors no longer causes the
page to scroll in some browsers. (:bug:`1057`)
djblets.datagrids
=================
* Sped up the data... | PypiClean |
/Flask-NoFLoC-1.0.0.tar.gz/Flask-NoFLoC-1.0.0/README.rst | ============
Flask-NoFLoC
============
Flask-NoFLoC_ is a `Flask extension`_ which disables FLoC_ by adding the header
.. code::
Permissions-Policy: interest-cohort=()
to each HTTP response of your app. Documentation_
.. _Flask-NoFLoC: https://Flask-NoFLoC.readthedocs.io/en/latest/
.. _Documentation: https://F... | PypiClean |
/CloudFerry-1.55.2.tar.gz/CloudFerry-1.55.2/cloudferry_devlab/utils/repackage_box.sh |
SCRIPT=$(basename $0)
error_exit() {
echo $* 1>&2
echo 1>&2
echo "Usage: $SCRIPT --box <box name> [-f, --force]" 1>&2
exit 1
}
while [[ $# -ge 1 ]]; do
case $1 in
-f | --force)
shift
forced=1
;;
--box)
shift
box=$1
... | PypiClean |
/MishMash-0.3.3.tar.gz/MishMash-0.3.3/HISTORY.rst | Release History
===============
.. :changelog:
v0.3.3 (2020-02-29) : Telltale
-------------------------------
Changes
~~~~~~~
- Replaced `countrycode` package `iso3166`
- Gunicorn upgrade.
v0.3.2 (2020-02-26) : Gareth Brown Says
----------------------------------------
- Pin gunicorn<20.0.0.
- Skip on sync errors.... | PypiClean |
/Flask-CKEditor-0.4.6.tar.gz/Flask-CKEditor-0.4.6/flask_ckeditor/static/full/plugins/a11yhelp/dialogs/lang/nl.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("a11yhelp","nl",{title:"Toegankelijkheidsinstructies",contents:"Help-inhoud. Druk op ESC om dit dialoog te sluiten.",legend:[{nam... | PypiClean |
/BIA_OBS-1.0.3.tar.gz/BIA_OBS-1.0.3/BIA/static/dist/node_modules/tailwindcss/src/util/formatVariantSelector.js | import selectorParser from 'postcss-selector-parser'
import unescape from 'postcss-selector-parser/dist/util/unesc'
import escapeClassName from '../util/escapeClassName'
import prefixSelector from '../util/prefixSelector'
let MERGE = ':merge'
let PARENT = '&'
export let selectorFunctions = new Set([MERGE])
export fu... | PypiClean |
/Netzob-2.0.0.tar.gz/Netzob-2.0.0/src/netzob/Model/Vocabulary/UnknownSymbol.py |
#+---------------------------------------------------------------------------+
#| 01001110 01100101 01110100 01111010 01101111 01100010 |
#| |
#| Netzob : Inferring communication protocols |
#+-... | PypiClean |
/MindustryCompiler-2.1-py3-none-any.whl/compiler/yacc/grammar/InstrASM/ulocate.py | from .._start import grammar, YaccProduction
from .. import asmError as err
from ...classes import AsmInst, KeyWord
from compiler.lex import keywords
# ulocate building reactor true @copper outx outy found buildingResult
@grammar
def ulocateResult(p: YaccProduction):
'''ligne : ulocate building buildingType instr... | PypiClean |
/NEMO_CE-1.6.12-py3-none-any.whl/NEMO/static/bootstrap/js/bootstrap.min.js | if("undefined"==typeof jQuery)throw new Error("Bootstrap's JavaScript requires jQuery");+function(a){"use strict";var b=a.fn.jquery.split(" ")[0].split(".");if(b[0]<2&&b[1]<9||1==b[0]&&9==b[1]&&b[2]<1)throw new Error("Bootstrap's JavaScript requires jQuery version 1.9.1 or higher")}(jQuery),+function(a){"use strict";fu... | PypiClean |
/Misago-0.36.1.tar.gz/Misago-0.36.1/misago/threads/viewmodels/category.py | from django.http import Http404
from ...acl.objectacl import add_acl_to_obj
from ...categories.models import Category
from ...categories.permissions import allow_browse_category, allow_see_category
from ...categories.serializers import CategorySerializer
from ...core.shortcuts import validate_slug
from ...core.viewmod... | PypiClean |
/Kamaelia-0.6.0.tar.gz/Kamaelia-0.6.0/Tools/Compose.py |
# Copyright (C) 2006 British Broadcasting Corporation and Kamaelia Contributors(1)
# All Rights Reserved.
#
# You may only modify and redistribute this under the terms of any of the
# following licenses(2): Mozilla Public License, V1.1, GNU General
# Public License, V2.0, GNU Lesser General Public License, V2.1
#
... | PypiClean |
/Editra-0.7.20.tar.gz/Editra-0.7.20/src/syntax/_glsl.py | __author__ = "Cody Precord <cprecord@editra.org>"
__svnid__ = "$Id$"
__revision__ = "$Revision$"
#-----------------------------------------------------------------------------#
# Imports
import wx.stc as stc
import re
# Local imports
import synglob
import syndata
import _cpp
#---------------------------------------... | PypiClean |
/KL_Audit_supportV3.2-1.0-py3-none-any.whl/AuditModule/util/LoggerUtil.py | from collections import OrderedDict
from logging import Formatter, FileHandler, StreamHandler, getLogger, INFO
from json import loads, dumps
def logger(name, handler, recordfields=None, level=INFO):
"""
returns logger object with logging level set and handlers added
:param name: logger name
:param han... | PypiClean |
/CAMELS_library-0.3.tar.gz/CAMELS_library-0.3/setup/SIMBA_DM/parameters_file_CV.py | from mpi4py import MPI
import numpy as np
import sys,os
import camb
###### MPI DEFINITIONS ######
comm = MPI.COMM_WORLD
nprocs = comm.Get_size()
myrank = comm.Get_rank()
#################################### INPUT #############################################
root_out = '/simon... | PypiClean |
/LongTermBiosignals-1.0.0.tar.gz/LongTermBiosignals-1.0.0/src/clinical/Patient.py |
# ===================================
# IT - LongTermBiosignals
# Package: clinical
# Module: Patient
# Description: Enumeration Sex and class Patient, to describe patients' clinical metadata.
# Contributors: João Saraiva
# Created: 22/04/2022
# Last update: 09/07/2022
# ===================================
from e... | PypiClean |
/DBigBang-0.2.tar.gz/DBigBang-0.2/dbigbang/graph.py | import datetime
import math
from collections import Counter
from pprint import pprint as pp
import networkx as nx
import numpy as np
import pandas
import pytz
import dbigbang.parse as parse
import dbigbang.process as process
def messages_to_reply_graph(messages):
"""Return a graph given messages."""
G = nx... | PypiClean |
/GALFITools-1.0.0.tar.gz/GALFITools-1.0.0/src/galfitools/sky/SkyDs9.py |
import numpy as np
import sys
import os.path
from astropy.io import fits
from matplotlib.path import Path
def SkyDs9(ImageFile, RegFile):
if not os.path.exists(ImageFile):
print ('image filename does not exist!' )
sys.exit()
if not os.path.exists(RegFile):
print ('%s: reg fi... | PypiClean |
/Gnosis-0.1.1.tar.gz/Gnosis-0.1.1/gnosis/util/convert/curses_txt2html.py | import curses, traceback, string, os
import dmTxt2Html
#-- Define the appearance of some interface elements
hotkey_attr = curses.A_BOLD | curses.A_UNDERLINE
menu_attr = curses.A_NORMAL
#-- Define additional constants
EXIT = 0
CONTINUE = 1
#-- Define default conversion dictionary
cfg_dict = {'target': 'DEFAULT.HTML',... | PypiClean |
/BigQuery-DatasetManager-0.1.6.tar.gz/BigQuery-DatasetManager-0.1.6/bqdm/action/dataset.py | from __future__ import absolute_import
import codecs
import logging
import os
import sys
from future.utils import iteritems
from google.cloud import bigquery
from google.cloud.exceptions import NotFound
from google.oauth2 import service_account
from bqdm.model.dataset import BigQueryDataset
from bqdm.util import (du... | PypiClean |
/IntervalArithmetic-0.2.0.tar.gz/IntervalArithmetic-0.2.0/doc/sphinx/source/development.rst | .. _development-page:
=========================
Development & Community
=========================
IntervalArithmetic is an open-source project, and relies on its community of users to keep getting better.
IntervalArithmetic source code and issues are managed on `Github <https://github.com/FabriceSalvaire/IntervalAr... | PypiClean |
/MetaCalls-0.0.5-cp310-cp310-manylinux2014_x86_64.whl/metacalls/node_modules/are-we-there-yet/LICENSE.md | ISC License
Copyright npm, Inc.
Permission to use, copy, modify, and/or distribute this
software for any purpose with or without fee is hereby
granted, provided that the above copyright notice and this
permission notice appear in all copies.
THE SOFTWARE IS PROVIDED "AS IS" AND NPM DISCLAIMS ALL
WARRANTIES WITH REGA... | PypiClean |
/AJWorkFlow-1.0.1-py3-none-any.whl/AJWorkFlow_pkg/Display/Graphs2D.py | try:
import matplotlib.pyplot as plt
import numpy as np
except ImportError as error:
print(f"Error, Module {error.__class__.__name__} is required")
def Graph2D(x_list,y_list,_description_list):
plt.style.use("default")
plt.figure(figsize=(6,6))
plt.plot(x_list,y_list)
plt.title(_description_... | PypiClean |
/Flask_BootstrapForms-0.1.6-py3-none-any.whl/flask_bootstrapforms/app.py | from markupsafe import Markup
from typing import TypeVar
from dataclasses import dataclass
import inspect
class BootstrapForms:
def __init__(self, form_tags: bool = False, name: str = None, method: str = None, action: str = None, autocomplete: bool = True):
self.form_tags = form_tags
self.name = ... | PypiClean |
/Kotti-2.0.9.tar.gz/Kotti-2.0.9/docs/developing/advanced/static-resource-management.rst | .. _static-resource-management:
Static resource management
==========================
In the default settings Kotti uses `Fanstatic`_ to manage its static resources (i.e. CSS, JS, etc.).
This is accomplished by a ``WSGI pipeline``:
.. code-block:: ini
[app:kotti]
use = egg:kotti
[filter:fanstatic]
... | PypiClean |
/DI_engine-0.4.9-py3-none-any.whl/dizoo/atari/config/serial/spaceinvaders/spaceinvaders_r2d2_residual_config.py | from easydict import EasyDict
collector_env_num = 8
evaluator_env_num = 5
spaceinvaders_r2d2_residual_config = dict(
exp_name='spaceinvaders_r2d2_residual_link_seed0',
env=dict(
collector_env_num=collector_env_num,
evaluator_env_num=evaluator_env_num,
n_evaluator_episode=8,
stop... | PypiClean |
/EnergyCapSdk-8.2304.4743.tar.gz/EnergyCapSdk-8.2304.4743/energycap/sdk/models/meter_bill_response.py |
from msrest.serialization import Model
class MeterBillResponse(Model):
"""MeterBillResponse.
:param bill_id: The bill identifier
:type bill_id: int
:param batch:
:type batch: ~energycap.sdk.models.BatchChild
:param account:
:type account: ~energycap.sdk.models.AccountChild
:param beg... | PypiClean |
/Booktype-1.5.tar.gz/Booktype-1.5/lib/booki/site_static/js/tiny_mce/plugins/legacyoutput/editor_plugin.js | (function(a){a.onAddEditor.addToTop(function(c,b){b.settings.inline_styles=false});a.create("tinymce.plugins.LegacyOutput",{init:function(b){b.onInit.add(function(){var c="p,h1,h2,h3,h4,h5,h6,td,th,div,ul,ol,li,table,img",e=a.explode(b.settings.font_size_style_values),d=b.schema;b.formatter.register({alignleft:{selecto... | PypiClean |
/MultipartPostHandler-0.1.0.tar.gz/MultipartPostHandler-0.1.0/MultipartPostHandler.py |
####
# 02/2006 Will Holcomb <wholcomb@gmail.com>
#
# This library 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; either
# version 2.1 of the License, or (at your option) any later version.
#
# This ... | PypiClean |
/Flask-CKEditor-0.4.6.tar.gz/Flask-CKEditor-0.4.6/flask_ckeditor/static/standard/plugins/specialchar/dialogs/lang/pt.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","pt",{euro:"Símbolo de Euro",lsquo:"Aspa esquerda simples",rsquo:"Aspa direita simples",ldquo:"Aspa esquerda dupla"... | PypiClean |
/Leytonium-10.tar.gz/Leytonium-10/diffuse/viewer/util.py |
# This file is part of Leytonium.
#
# Leytonium 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.
#
# Leytonium is distributed in the ho... | PypiClean |
/ImageD11-1.9.9.tar.gz/ImageD11-1.9.9/scripts/ImageD11_gui.py | from __future__ import print_function
# ImageD11_v1.0 Software for beamline ID11
# Copyright (C) 2005-2007 Jon Wright
#
# 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 2 of the... | PypiClean |
/Django-4.2.4.tar.gz/Django-4.2.4/django/utils/_os.py | import os
import tempfile
from os.path import abspath, dirname, join, normcase, sep
from pathlib import Path
from django.core.exceptions import SuspiciousFileOperation
def safe_join(base, *paths):
"""
Join one or more path components to the base path component intelligently.
Return a normalized, absolute... | PypiClean |
/Cubane-1.0.11.tar.gz/Cubane-1.0.11/cubane/lib/geocode.py | from __future__ import unicode_literals
from django.conf import settings
from cubane.lib.http import wget
from cubane.lib.libjson import decode_json
def geocode(address, apikey=settings.CUBANE_GOOGLE_MAP_API_KEY, url='https://maps.googleapis.com/maps/api/geocode/json'):
"""
Make an API call to google's geocod... | PypiClean |
/GQCMS-0.0.4-py3-none-any.whl/build/lib/gqcms/matrices/NumberOperator.py | from typing import List
import numpy as np
from . import Determinant
def NumberOperator(sites: list, basis: List[Determinant], balpha: bool =True, bbeta: bool =True, number_of_sites: int = None, N: np.ndarray = None) -> np.ndarray:
"""
Creates the matrix representation of the number operator in ONV or site b... | PypiClean |
/Adafruit_Blinka-8.20.1-py3-none-any.whl/adafruit_blinka/microcontroller/rp2040_u2if/rp2040_u2if.py | """Helper class for use with RP2040 running u2if firmware"""
# https://github.com/execuc/u2if
import os
import time
import hid
# Use to set delay between reset and device reopen. if negative, don't reset at all
RP2040_U2IF_RESET_DELAY = float(os.environ.get("RP2040_U2IF_RESET_DELAY", 1))
# pylint: disable=import-out... | PypiClean |
/Impression-CMS-0.2.0.tar.gz/Impression-CMS-0.2.0/impression/controls.py | import re
from functools import wraps
from impression.models import Setting, ApiKey, Content
from flask import request, redirect, url_for, g, jsonify
from flask_themes2 import get_theme, render_theme_template
from itsdangerous import TimestampSigner, SignatureExpired
'''
Misc functions that do things like get the c... | PypiClean |
/Curp-1.3.1.tar.gz/Curp-1.3.1/curp/tool/sele/console.py |
from __future__ import print_function
# Standard module
import argparse
import curp.tool.sele as sele
from curp.console import exec_command
manual = {
'sele': ('Output an irEC file with removed or kept only selected '
'residues from input irEC file.'),
'helix': '',
'... | PypiClean |
/Bis-Miner-3.11.1.tar.gz/Bis-Miner-3.11.0/Orange/widgets/visualize/owboxplot.py | import sys
import math
from itertools import chain
import numpy as np
from AnyQt.QtWidgets import (
QGraphicsView, QGraphicsScene, QGraphicsItem, QGraphicsSimpleTextItem,
QGraphicsTextItem, QGraphicsItemGroup, QGraphicsLineItem,
QGraphicsPathItem, QGraphicsRectItem, QSizePolicy
)
from AnyQt.QtGui import QP... | PypiClean |
/NlpToolkit-WordSenseDisambiguation-1.0.3.tar.gz/NlpToolkit-WordSenseDisambiguation-1.0.3/WordSenseDisambiguation/ParseTree/TreeAutoSemantic.py | from abc import abstractmethod
from AnnotatedTree.ParseTreeDrawable import ParseTreeDrawable
from MorphologicalAnalysis.FsmMorphologicalAnalyzer import FsmMorphologicalAnalyzer
from WordNet.WordNet import WordNet
class TreeAutoSemantic:
@abstractmethod
def autoLabelSingleSemantics(self, parseTree: ParseTree... | PypiClean |
/BenchExec-3.17.tar.gz/BenchExec-3.17/benchexec/tools/metaval.py |
import argparse
import benchexec.tools.template
import os
import re
import threading
from benchexec.tools.template import BaseTool2
from benchexec.tools.template import UnsupportedFeatureException
class Tool(benchexec.tools.template.BaseTool2):
"""
This is the tool info module for MetaVal.
The official... | PypiClean |
/CertGenerator-2.2.1.tar.gz/CertGenerator-2.2.1/README.rst | .. _pip: https://pip.pypa.io/en/stable/quickstart/
.. _changes: https://github.com/johndoe-dev/CertGenerator/blob/master/CHANGES.txt
*************
CertGenerator
*************
Python module to generate key, certificate request, self signed
certificate and p12 certificate
Information
-----------
This can be used onl... | PypiClean |
/NIA_image_2latex-1.0-py3-none-any.whl/resources/resources.py |
# Resource object code
#
# Created by: The Resource Compiler for PyQt5 (Qt v5.9.6)
#
# WARNING! All changes made in this file will be lost!
from PyQt5 import QtCore
qt_resource_data = b"\
\x00\x03\x67\x30\
\x00\
\x0f\xbc\xd5\x78\x9c\xec\xbd\xfb\x57\x1b\x49\x92\x30\xfa\xf3\xec\
\x39\xdf\xff\x50\xae\x19\x0f\x92\x11\x0... | PypiClean |
/OctoPrint-1.9.2.tar.gz/OctoPrint-1.9.2/src/octoprint/plugins/softwareupdate/version_checks/__init__.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"
from ..exceptions import ApiCheckError, RateLimitCheckError
from . import ( # noqa... | PypiClean |
/CallFlow-1.3.0.tar.gz/CallFlow-1.3.0/server/provider_base.py |
import os
import shutil
import multiprocessing
from functools import partial
from callflow import SuperGraph, EnsembleGraph
from callflow import get_logger
from callflow.operations import Filter, Group, Unify
from callflow.layout import NodeLinkLayout, SankeyLayout, HierarchyLayout
from callflow.utils.sanitizer imp... | PypiClean |
/FreePyBX-1.0-RC1.tar.gz/FreePyBX-1.0-RC1/freepybx/public/js/dojox/gauges/GlossyCircularGauge.js.uncompressed.js | define("dojox/gauges/GlossyCircularGauge", ["dojo/_base/declare","dojo/_base/Color","./GlossyCircularGaugeBase"],
function(declare, Color, GlossyCircularGaugeBase) {
/*=====
GlossyCircularGaugeBase = dojox.gauges.GlossyCircularGaugeBase;
=====*/
return declare("dojox.gauges.GlossyCircularGauge", [GlossyCircularGau... | PypiClean |
/AnubhavJain-1.0.0.tar.gz/AnubhavJain-1.0.0/TOPSIS-Anubhav-101803610/__init__.py | import pandas as pd
import numpy as np
import sys
def normalized_matrix(filename):
dataset = pd.read_csv(filename)
attributes = dataset.iloc[:,1:].values
alternatives = dataset.iloc[:,0].values
sum_cols=[0]*len(attributes[0])
for i in range(len(attributes)):
for j in range(... | PypiClean |
/MergePythonSDK.ticketing-2.2.2-py3-none-any.whl/MergePythonSDK/ats/model/ignore_common_model.py | import re # noqa: F401
import sys # noqa: F401
from typing import (
Optional,
Union,
List,
Dict,
)
from MergePythonSDK.shared.model_utils import ( # noqa: F401
ApiTypeError,
ModelComposed,
ModelNormal,
ModelSimple,
cached_property,
OpenApiModel,
change_keys_js_to_python,... | PypiClean |
/NodeGraphQt_QuiltiX_fork-0.6.0.tar.gz/NodeGraphQt_QuiltiX_fork-0.6.0/examples/nodes/custom_ports_node.py | from Qt import QtCore, QtGui
from NodeGraphQt import BaseNode
def draw_triangle_port(painter, rect, info):
"""
Custom paint function for drawing a Triangle shaped port.
Args:
painter (QtGui.QPainter): painter object.
rect (QtCore.QRectF): port rect used to describe parameters
... | PypiClean |
/EnergyCapSdk-8.2304.4743.tar.gz/EnergyCapSdk-8.2304.4743/energycap/sdk/models/user_create_request_py3.py |
from msrest.serialization import Model
class UserCreateRequest(Model):
"""UserCreateRequest.
All required parameters must be populated in order to send to Azure.
:param user_code: Required. <span
class='property-internal'>Required</span> <span
class='property-internal'>Must be between 0 and ... | PypiClean |
/LabExT_pkg-2.2.0.tar.gz/LabExT_pkg-2.2.0/docs/settings_configuration.md | # Configuration of LabExT
To make full use of LabExT, some configuration is required. Here, we describe the most important options.
* Instrument VISA address and driver configuration. (**highly recommended** for basic functionality)
* Specify and load addon repositories. (optional, recommended if you code your own me... | PypiClean |
/DuHast-1.0.7-py3-none-any.whl/duHast/APISamples/RevitRailings.py | '''
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
This module contains a number of helper functions relating to Revit railings.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
'''
#
#Lic... | PypiClean |
/Hikka_Pyro_New-2.0.103-py3-none-any.whl/hikkapyro/types/object.py |
import typing
from datetime import datetime
from enum import Enum
from json import dumps
import hikkapyro
class Object:
def __init__(self, client: "hikkapyro.Client" = None):
self._client = client
def bind(self, client: "hikkapyro.Client"):
"""Bind a Client instance to this and to all neste... | PypiClean |
/BioSAK-1.72.0.tar.gz/BioSAK-1.72.0/doc/rename_seq_cn.md |
+ Rename "NODE_941_length_17600_cov_52.7123" to "NODE_941"
BioSAK rename_seq -in Contigs.fa -sep_in "_" -n 2
+ Rename "Seawater|NODE|941|length|17600|cov|52.7123" to "Seawater_NODE_941"
BioSAK rename_seq -in Contigs.fa -sep_in "|" -sep_out "_" -n 3
+ Add prefix to all sequences in a fasta file
B... | PypiClean |
/APtools-0.2.4-py3-none-any.whl/aptools/data_handling/conversion.py | from aptools.data_handling.reading import read_beam
from aptools.data_handling.saving import save_beam
def convert_beam(orig_code, final_code, orig_path, final_path, final_file_name,
reposition=False, avg_pos=[None, None, None],
avg_mom=[None, None, None], n_part=None, read_kwargs={}... | PypiClean |
/DeWave-0.12.tar.gz/DeWave-0.12/README.md | # Single-channel blind source separation
This package decomposes two overlapping speech signals, which are recoded in one channel.
The method is described in deep clustering paper: https://arxiv.org/abs/1508.04306.
The code is based on [zhr1201/deep-clustering](https://github.com/zhr1201/deep-clustering) from the Gith... | PypiClean |
/Django_patch-2.2.19-py3-none-any.whl/django/contrib/gis/db/models/aggregates.py | from django.contrib.gis.db.models.fields import (
ExtentField, GeometryCollectionField, GeometryField, LineStringField,
)
from django.db.models import Value
from django.db.models.aggregates import Aggregate
from django.utils.functional import cached_property
__all__ = ['Collect', 'Extent', 'Extent3D', 'MakeLine', ... | PypiClean |
/Density_Sampling-1.3.tar.gz/Density_Sampling-1.3/README | Density\_Sampling
=================
Overview
--------
For a data-set comprising a mixture of rare and common populations,
density sampling gives equal weights to selected representatives of
those distinct populations.
Density sampling is a balancing act between signal and noise. Indeed,
while it increases the preval... | PypiClean |
/FamcyDev-0.3.71-py3-none-any.whl/Famcy/bower_components/bootstrap-fileinput/js/locales/ar.js | (function ($) {
"use strict";
$.fn.fileinputLocales['ar'] = {
fileSingle: 'ملف',
filePlural: 'ملفات',
browseLabel: 'تصفح …',
removeLabel: 'إزالة',
removeTitle: 'إزالة الملفات المختارة',
cancelLabel: 'إلغاء',
cancelTitle: 'إنهاء الرفع الحالي',
... | PypiClean |
/AaronTools-1.0b14.tar.gz/AaronTools-1.0b14/symmetry.py | import numpy as np
from scipy.spatial import distance_matrix
from AaronTools import addlogger
from AaronTools.utils.prime_numbers import Primes
from AaronTools.utils.utils import (
rotation_matrix, mirror_matrix, proj, angle_between_vectors, perp_vector
)
class SymmetryElement:
def __init__(self, order, cen... | PypiClean |
/LSD-Bubble-2.0.tar.gz/LSD-Bubble-2.0/LSD/detecter/brankovic.py | from LSD.RMQ import RangeQuery
from LSD.detecter.outvalues import out_child2, out_parent2
def super_bubble_brankovice(c, toposort, reporter):
"""Find all superbubbles in a DAG after Brankovice at all."""
ord_id = toposort.index
def report(s, t):
reporter.rep(toposort[ord_id(s): ord_id(t) + 1]... | PypiClean |
/Nodes-1.2.tar.gz/Nodes-1.2/rfNEAT/iznn/iznn_pure.py |
class Neuron(object):
'''
A spiking neuron model based on:
Izhikevich, E. M.
Simple Model of Spiking Neurons
IEEE TRANSACTIONS ON NEURAL NETWORKS, VOL. 14, NO. 6, NOVEMBER 2003
'''
def __init__(self, bias = 0, a = 0.02, b = 0.2, c = -65.0, d = 8.0):
'''
a, b, c, d are the ... | PypiClean |
/Mathics-1.0.tar.gz/Mathics-1.0/mathics/web/media/js/mathjax/jax/output/HTML-CSS/autoload/menclose.js | MathJax.Hub.Register.StartupHook("HTML-CSS Jax Ready",function(){var d="2.0";var a=MathJax.ElementJax.mml,b=MathJax.OutputJax["HTML-CSS"];var c="http://www.w3.org/2000/svg";var f="urn:schemas-microsoft-com:vml";var e="mjxvml";a.menclose.Augment({toHTML:function(ab){var j=this.getValues("notation","thickness","padding",... | PypiClean |
/KoiLang-1.2.0a0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl/kola/klvm/mask.py | from abc import ABC, abstractmethod
from enum import Enum
from typing import Any, Type, Union
from .commandset import CommandSet
class Mask(ABC):
__slots__ = ["type", "not_"]
class MType(Enum):
default = "" # test all reachable env
exact = "+" # test top env
all = "*" # ... | PypiClean |
/NEMO_billing-2.6.7-py3-none-any.whl/NEMO_billing/invoices/exceptions.py | from NEMO.models import Area, Consumable, Project, Tool
from NEMO_billing.exceptions import BillingException
from NEMO_billing.invoices.models import Invoice, InvoiceDetailItem
from NEMO_billing.rates.models import RateCategory, RateType
class NoRateSetException(BillingException):
def __init__(
self,
... | PypiClean |
/Axilent-Dox-0.1.4.tar.gz/Axilent-Dox-0.1.4/dox/uploader.py | import markdown
from dox.config import get_cfg, get_keymap, get_keyfields
from dox.client import get_content_library_resource
def upload_document(path,key=None):
"""
Uploads the specified document, returns the key of the uploaded document.
"""
# 1. Prepare data for upload
cfg = get_cfg()
body_f... | PypiClean |
/GNS-1.0-py3-none-any.whl/gns/geom_sampler.py | import numpy as np
#import custom modules
from . import geom
def splitGeomParams(paramGeomList):
"""
Get indexes of parameters from paramList
based on whether parameter should be sampled in
physical (non-geometric) or geometric space,
and add these to two lists which can be used
to index parameter array
"""
... | PypiClean |
/AyiinXd-0.0.8-cp311-cp311-macosx_10_9_universal2.whl/fipper/node_modules/readable-stream/lib/internal/streams/async_iterator.js | 'use strict';
var _Object$setPrototypeO;
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
function _toPropertyKey(arg) { var key = ... | PypiClean |
/Electrum-VTC-2.9.3.3.tar.gz/Electrum-VTC-2.9.3.3/gui/vtc/address_dialog.py |
from electrum_vtc.i18n import _
import PyQt4
from PyQt4.QtGui import *
from PyQt4.QtCore import *
from util import *
from history_list import HistoryList
from qrtextedit import ShowQRTextEdit
class AddressDialog(WindowModalDialog):
def __init__(self, parent, address):
WindowModalDialog.__init__(self, p... | PypiClean |
/Krakatau-noff-v0.20181212.tar.gz/Krakatau-noff-v0.20181212/Krakatau/assembler/instructions.py | OP_NONE = frozenset(['nop', 'aconst_null', 'iconst_m1', 'iconst_0', 'iconst_1', 'iconst_2', 'iconst_3', 'iconst_4', 'iconst_5', 'lconst_0', 'lconst_1', 'fconst_0', 'fconst_1', 'fconst_2', 'dconst_0', 'dconst_1', 'iload_0', 'iload_1', 'iload_2', 'iload_3', 'lload_0', 'lload_1', 'lload_2', 'lload_3', 'fload_0', 'fload_1'... | PypiClean |
/AppDispatch-0.3.4.tar.gz/AppDispatch-0.3.4/ez_setup.py | import sys
DEFAULT_VERSION = "0.6c11"
DEFAULT_URL = "http://pypi.python.org/packages/%s/s/setuptools/" % sys.version[:3]
md5_data = {
'setuptools-0.6b1-py2.3.egg': '8822caf901250d848b996b7f25c6e6ca',
'setuptools-0.6b1-py2.4.egg': 'b79a8a403e4502fbb85ee3f1941735cb',
'setuptools-0.6b2-py2.3.egg': '565775... | PypiClean |
/6D657461666C6F77-0.0.17.tar.gz/6D657461666C6F77-0.0.17/metaflow/tutorials/01-playlist/playlist.py | from metaflow import FlowSpec, step, IncludeFile, Parameter
def script_path(filename):
"""
A convenience function to get the absolute path to a file in this
tutorial's directory. This allows the tutorial to be launched from any
directory.
"""
import os
filepath = os.path.join(os.path.dir... | PypiClean |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.