id stringlengths 1 265 | text stringlengths 6 5.19M | dataset_id stringclasses 7
values |
|---|---|---|
/CubeLang-0.1.4-py3-none-any.whl/libcube/orientation.py | import enum
from typing import Any, Iterable, Optional, Callable, Tuple, TypeVar
from itertools import groupby
from functools import wraps
T = TypeVar("T")
def count_occurrences(seq: Iterable[T]) -> Iterable[Tuple[T, int]]:
return ((val, sum(1 for _ in group)) for val, group in groupby(seq))
def pipe(g):
d... | PypiClean |
/Infomericaclass-1.0.0.tar.gz/Infomericaclass-1.0.0/inf/pred_nc_reg_name.py |
import sys
import argparse
import pandas as pd
import numpy as np
from tensorflow.keras.models import load_model
from tensorflow.keras.preprocessing import sequence
from pkg_resources import resource_filename
from .utils import column_exists, find_ngrams, fixup_columns
MODELFN = "models/nc_voter_reg/lstm/nc_voter_n... | PypiClean |
/Flask-QR-0.1.3.zip/Flask-QR-0.1.3/flask_qr.py | from flask import current_app, url_for, Markup
import os.path
import urllib
import qrcode
# Find the stack on which we want to store the database connection.
# Starting with Flask 0.9, the _app_ctx_stack is the correct one,
# before that we need to use the _request_ctx_stack.
try:
from flask import _app_ctx_stac... | PypiClean |
/Driver_zch-3.2.0.tar.gz/Driver_zch-3.2.0/zhouch23/player.py | import sys
import argparse
from datetime import datetime
import can
from can import Bus, LogReader, MessageSync
def main():
parser = argparse.ArgumentParser(
"python -m can.player", description="Replay CAN traffic."
)
parser.add_argument(
"-f",
"--file_name",
dest="log_fi... | PypiClean |
/Bluebook-0.0.1.tar.gz/Bluebook-0.0.1/pylot/component/static/pylot/vendor/mdeditor/bower_components/codemirror/addon/search/match-highlighter.js |
(function() {
var DEFAULT_MIN_CHARS = 2;
var DEFAULT_TOKEN_STYLE = "matchhighlight";
function State(options) {
if (typeof options == "object") {
this.minChars = options.minChars;
this.style = options.style;
this.showToken = options.showToken;
}
if (this.style == null) this.style = ... | PypiClean |
/Moose-0.9.9b3.tar.gz/Moose-0.9.9b3/docs/topics/connection.rst | .. _topics-connection:
=======================
连接(Connection)
=======================
*Moose* 不是一个孤立的系统,文件和数据通过各种现有的服务提供——关系/非关系型数据库、文件系统、
云存储服务等等,我们要进行处理就必须提供“港口和桥梁”,将数据接入进来。 *connection*
模块就是被用来处理这样的任务。
对于关系型数据库,无论底层的引擎是mysql还是sqlserver, :doc:`sqlhandler` 模块为所有的操作
提供了一个统一的接口; 除此之外, :doc:`operations` 则基于这层抽象提供了便捷的s... | PypiClean |
/DendroPy-4.6.1.tar.gz/DendroPy-4.6.1/src/dendropy/dataio/__init__.py |
##############################################################################
## DendroPy Phylogenetic Computing Library.
##
## Copyright 2010-2015 Jeet Sukumaran and Mark T. Holder.
## All rights reserved.
##
## See "LICENSE.rst" for terms and conditions of usage.
##
## If you use this work or any portion there... | PypiClean |
/MusicOnPolytopes-0.1.0-py3-none-any.whl/polytopes/compute_scores.py | from IPython.display import display, Markdown
# Self-code imports
import polytopes.segmentation_algorithms as algos
import polytopes.data_manipulation as dm
#Generic imports
import numpy as np
import matplotlib.pyplot as plt
import pandas as pd
import math
database_path = "C:/Users/amarmore/Desktop/Projects/RWC_ann... | PypiClean |
/DLTA-AI-1.1.tar.gz/DLTA-AI-1.1/DLTA_AI_app/mmdetection/configs/strong_baselines/mask_rcnn_r50_caffe_fpn_syncbn-all_rpn-2conv_lsj_100e_coco.py | _base_ = [
'../_base_/models/mask_rcnn_r50_fpn.py',
'../common/lsj_100e_coco_instance.py'
]
norm_cfg = dict(type='SyncBN', requires_grad=True)
# Use MMSyncBN that handles empty tensor in head. It can be changed to
# SyncBN after https://github.com/pytorch/pytorch/issues/36530 is fixed
# Requires MMCV-full afte... | PypiClean |
/NL4Py-0.9.0-py3-none-any.whl/nl4py/__init__.py | import shutil
import os
import traceback
from typing import Callable, List, Any
from py4j.java_gateway import JavaGateway
import pandas as pd
from .NetLogoHeadlessWorkspace import NetLogoHeadlessWorkspace
from .NetLogoControllerServerStarter import NetLogoControllerServerStarter
from .NetLogoWorkspaceFactory import N... | PypiClean |
/Flask-KQMaps-0.4.2.tar.gz/Flask-KQMaps-0.4.2/flask_kqmaps/static/kqwebclient/leaflet/3rd_libs/Leaflet-semicircle/Semicircle.js | (function (factory) {
if (typeof define === 'function' && define.amd) {
// AMD
define(['leaflet'], factory);
} else if (typeof module !== 'undefined' && typeof require !== 'undefined') {
// Node/CommonJS
module.exports = factory(require('leaflet'));
} else {
// Browse... | PypiClean |
/LightNER-0.3.0.tar.gz/LightNER-0.3.0/lightner/crf_model/crf.py | import torch
import torch.nn as nn
import torch.optim as optim
import torch.sparse as sparse
import lightner.utils as utils
class CRF(nn.Module):
"""
Conditional Random Field Module
Parameters
----------
hidden_dim : ``int``, required.
the dimension of the input features.
tagset_size :... | PypiClean |
/NeodroidAgent-0.4.8-py36-none-any.whl/neodroidagent/agents/numpy_agents/model_free/baseline/linear_feature_gae_estimator.py |
__author__ = "Christian Heider Nielsen"
__doc__ = r"""
Created on 19/01/2020
"""
from typing import Any, Tuple
import numpy
from draugr.writers import MockWriter, Writer
from neodroid.utilities import (
ActionSpace,
EnvironmentSnapshot,
ObservationSpace,
SignalSpace,
)
from neodroida... | PypiClean |
/OZI-0.0.43.tar.gz/OZI-0.0.43/ templates/CHANGELOG.orig.md | <!-- Copyright 2023 Ross J. Duff MSc
The copyright holder licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless r... | PypiClean |
/APS_BlueSky_tools-2019.103.0.tar.gz/APS_BlueSky_tools-2019.103.0/APS_BlueSky_tools/devices.py |
from collections import OrderedDict
from datetime import datetime
import epics
import itertools
import numpy as np
import threading
import time
from .synApps_ophyd import *
from . import plans as APS_plans
import ophyd
from ophyd import Component, Device, DeviceStatus, FormattedComponent
from ophyd import Signal, E... | PypiClean |
/Auto-Research-1.0.tar.gz/Auto-Research-1.0/README.md | # Auto-Research
##### A no-code utility to generate a detailed well-cited survey with topic clustered sections (draft paper format) and other interesting artifacts from a single research query.
Requires:
- python 3.7 or above
- poppler-utils
- list of requirements in requirements.txt
- 8GB disk space
- 13GB CUDA... | PypiClean |
/MaterialDjango-0.2.5.tar.gz/MaterialDjango-0.2.5/materialdjango/static/materialdjango/components/bower_components/prism/plugins/keep-markup/prism-keep-markup.js | (function () {
if (typeof self === 'undefined' || !self.Prism || !self.document || !document.createRange) {
return;
}
Prism.plugins.KeepMarkup = true;
Prism.hooks.add('before-highlight', function (env) {
if (!env.element.children.length) {
return;
}
var pos = 0;
var data = [];
var f = function (e... | PypiClean |
/CT3-3.3.2-cp310-cp310-macosx_10_9_x86_64.whl/Cheetah/Filters.py | from .compat import unicode
# Additional entities WebSafe knows how to transform. No need to include
# '<', '>' or '&' since those will have been done already.
webSafeEntities = {' ': ' ', '"': '"'}
class Filter(object):
"""A baseclass for the Cheetah Filters."""
def __init__(self, template=None)... | PypiClean |
/Django-ConfPages-0.1.1.tar.gz/Django-ConfPages-0.1.1/confpages/loaders.py | from __future__ import absolute_import
class Page(object):
"""The page object."""
def __init__(self, name, title='', content='', is_static=True,
api_url=None, base_template=None):
# The page name
self.name = name
# The page title
self.title = title
# T... | PypiClean |
/CloudFerry-1.55.2.tar.gz/CloudFerry-1.55.2/cloudferry/actions/compute/transport_instance.py |
import copy
import logging
import pprint
import random
from oslo_config import cfg
from cloudferry.actions.helper import task_transfer
from cloudferry.lib.base import exception
from cloudferry.lib.base.action import action
from cloudferry.lib.copy_engines import base
from cloudferry.lib.migration import notifiers
fr... | PypiClean |
/Deep-Motility-1.0.6rc1.tar.gz/Deep-Motility-1.0.6rc1/deep_motility/predict_seg.py | from __future__ import absolute_import
# ML
import torchvision.transforms as transforms
import torch
# Show Images
from PIL import Image
from skimage import color
import io
import numpy as np
# Biomedical Images
from skimage import exposure, img_as_ubyte
# List dir
import os
from pathlib import Path
# Suppress all... | PypiClean |
/CardioWave-0.2.3.tar.gz/CardioWave-0.2.3/README.md | # CardioWave: A tool for waveform analysis



:
"""Perform multiple SNMP queries virtually simultaneously
"""
def __init__ (self):
# Set defaults to public attributes
self.retries = 3
self.time... | PypiClean |
/Nano-CAT-0.7.2.tar.gz/Nano-CAT-0.7.2/nanoCAT/recipes/cdft_utils.py | import inspect
import textwrap
from os import PathLike
from os.path import join
from typing import Mapping, Any, Union, Optional, TypeVar, FrozenSet
from scm.plams import Molecule, config
from qmflows import adf, Settings
from qmflows.utils import InitRestart
from qmflows.packages import registry, Package, Result
from... | PypiClean |
/BlueWhale3-3.31.3.tar.gz/BlueWhale3-3.31.3/Orange/widgets/unsupervised/owdistancemap.py | import itertools
from functools import reduce
from operator import iadd
import numpy
from AnyQt.QtWidgets import (
QGraphicsRectItem, QGraphicsGridLayout, QApplication, QSizePolicy
)
from AnyQt.QtGui import QFontMetrics, QPen, QTransform, QFont
from AnyQt.QtCore import Qt, QRect, QRectF, QPointF
from AnyQt.QtCore... | PypiClean |
/Diofant-0.14.0a2.tar.gz/Diofant-0.14.0a2/diofant/logic/utils.py | import re
from ..core import Symbol
from . import And, Or
def parse_dimacs(s):
r"""
Loads a boolean expression from a string in the DIMACS CNF format.
The file in the DIMACS CNF format is an ASCII file consisting of
a two major sections: the preamble and the clauses.
The preamble contains infor... | PypiClean |
/Hikka_Pyro_New-2.0.103-py3-none-any.whl/hikkapyro/utils.py |
import asyncio
import base64
import functools
import hashlib
import os
import struct
from concurrent.futures.thread import ThreadPoolExecutor
from datetime import datetime, timezone
from getpass import getpass
from typing import Union, List, Dict, Optional
import hikkapyro
from hikkapyro import raw, enums
from hikkap... | PypiClean |
/FreePyBX-1.0-RC1.tar.gz/FreePyBX-1.0-RC1/freepybx/public/js/dojox/wire/ml/Action.js.uncompressed.js | define("dojox/wire/ml/Action", ["dijit","dojo","dojox","dojo/require!dijit/_Widget,dijit/_Container,dojox/wire/Wire,dojox/wire/ml/util"], function(dijit,dojo,dojox){
dojo.provide("dojox.wire.ml.Action");
dojo.require("dijit._Widget");
dojo.require("dijit._Container");
dojo.require("dojox.wire.Wire");
dojo.require("doj... | PypiClean |
/Cowpox-6-py3-none-any.whl/cowpox/recipe.py |
# This file is part of Cowpox.
#
# Cowpox is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# Cowpox is distributed in the hope that i... | PypiClean |
/FreeGS-0.8.0-py3-none-any.whl/freegs/optimise.py | from . import optimiser
from . import picard
import matplotlib.pyplot as plt
from freegs.plotting import plotEquilibrium
from math import sqrt
# Measures which operate on Equilibrium objects
def max_abs_coil_current(eq):
"""
Given an equilibrium, return the maximum absolute coil current
"""
current... | PypiClean |
/FicusFramework-3.1.0.post2.tar.gz/FicusFramework-3.1.0.post2/src/py_eureka_client/eureka_client.py |
import atexit
import json
import os
import re
import socket
import time
import random
import inspect
import xml.etree.ElementTree as ElementTree
from threading import Timer
from threading import RLock
from threading import Thread
try:
from urllib.parse import urlparse
except ImportError:
from urlparse import u... | PypiClean |
/FreePyBX-1.0-RC1.tar.gz/FreePyBX-1.0-RC1/freepybx/public/js/dojox/gfx3d/scheduler.js | define("dojox/gfx3d/scheduler",["dojo/_base/lang","dojo/_base/array","dojo/_base/declare","./_base","./vector"],function(_1,_2,_3,_4,_5){
_4.scheduler={zOrder:function(_6,_7){
_7=_7?_7:_4.scheduler.order;
_6.sort(function(a,b){
return _7(b)-_7(a);
});
return _6;
},bsp:function(_8,_9){
_9=_9?_9:_4.scheduler.outline;
var... | PypiClean |
/FFC-2017.1.0.tar.gz/FFC-2017.1.0/doc/sphinx/source/releases/v2017.1.0.rst | ===========================
Changes in version 2017.1.0
===========================
FFC 22017.1.0 was released on 2017-05-09.
Summary of changes
==================
- Add experimental ``tsfc`` representation; for installation see
`the reference manual
<https://fenics.readthedocs.io/projects/ffc/en/latest/installa... | PypiClean |
/FreePyBX-1.0-RC1.tar.gz/FreePyBX-1.0-RC1/freepybx/public/js/dojox/mobile/common.js.uncompressed.js | define("dojox/mobile/common", [
"dojo/_base/kernel", // to test dojo.hash
"dojo/_base/array",
"dojo/_base/config",
"dojo/_base/connect",
"dojo/_base/lang",
"dojo/_base/window",
"dojo/dom-class",
"dojo/dom-construct",
"dojo/dom-style",
// "dojo/hash", // optionally prereq'ed
"dojo/ready",
"dijit/registry", //... | PypiClean |
/BigJob2-0.54.post73.tar.gz/BigJob2-0.54.post73/docs/source/intro/index.rst | ############
Introduction
############
BigJob is a Pilot-Job framework built on top of `The Simple API for Grid Applications (SAGA) <http://saga-project.github.com>`_, a high-level, easy-to-use API for accessing distributed resources. BigJob supports a wide range of application types and is usable over a broad range o... | PypiClean |
/MezzanineFor1.7-3.1.10.tar.gz/MezzanineFor1.7-3.1.10/docs/frequently-asked-questions.rst | ==========================
Frequently Asked Questions
==========================
These are some of the most frequently asked questions on the
`Mezzanine mailing list <http://groups.google.com/group/mezzanine-users>`_.
* :ref:`prerequisites`
* :ref:`static-files`
* :ref:`wysiwyg-filtering`
* :ref:`homepage`
... | PypiClean |
/GraphQL_core_next-1.1.1-py3-none-any.whl/graphql/utilities/separate_operations.py | from collections import defaultdict
from typing import Dict, List, Set
from ..language import (
DocumentNode,
ExecutableDefinitionNode,
FragmentDefinitionNode,
OperationDefinitionNode,
Visitor,
visit,
)
__all__ = ["separate_operations"]
DepGraph = Dict[str, Set[str]]
def separate_operation... | PypiClean |
/FreeClimber-0.3.1.1.tar.gz/FreeClimber-0.3.1.1/README.md | <h1>FreeClimber</h1>
<h3>Overview</h3>
`FreeClimber` is a Python 3-based, background-subtracting particle detection algorithm that performs a local linear regression to quantify the vertical velocity of points moving in a common direction.
<img src="https://github.com/adamspierer/FreeClimber/blob/master/z/0-Tutoria... | PypiClean |
/NeodroidVision-0.3.0-py36-none-any.whl/neodroidvision/detection/single_stage/ssd/architecture/nms_box_heads/ssd_box_head.py |
__author__ = "Christian Heider Nielsen"
__doc__ = r"""
Created on 10/11/2019
"""
from collections import namedtuple
from typing import Any, Tuple
import torch
from draugr.torch_utilities import to_tensor
from torch import nn
from torch.nn import Parameter, functional
from neodroidvision.detec... | PypiClean |
/MinecraftWS-1.1.1.tar.gz/MinecraftWS-1.1.1/README.md | # MinecraftWS

Minecraft Bedrock Websocket
## Install
```shell
pip install MinecraftWS
```
## Example
```python
from MinecraftWS import MinecraftWebSocket, Event
class MWS(MinecraftWebSocket):
async def on_connect(self):
print('connect')
await se... | PypiClean |
/Amara-2.0.0a6.tar.bz2/Amara-2.0.0a6/sandbox/filters.py | def process_filters(event_type, event_data, depth=0):
for filter in filters:
if filter.active:
filter.depth += depth
if filter.handlers[event_type]:
status = filter.handlers[event_type](*event_data)
else:
status = filter.default
... | PypiClean |
/Loglan-DB-0.1.21.tar.gz/Loglan-DB-0.1.21/loglan_db/model_db/addons/addon_word_sourcer.py | from typing import Optional, List, Union
from flask_sqlalchemy import BaseQuery
from loglan_db.model_db.base_type import BaseType
from loglan_db.model_db.base_word import BaseWord
from loglan_db import db
from loglan_db.model_db.base_word_source import BaseWordSource
class AddonWordSourcer:
"""AddonWordSourcer M... | PypiClean |
/DI_engine-0.4.9-py3-none-any.whl/ding/interaction/base/app.py | import json
from enum import IntEnum, unique
from functools import wraps
from typing import Mapping, Any, Type, Optional, Tuple, Union, Iterable, Callable
import flask
import requests
from flask import jsonify
@unique
class CommonErrorCode(IntEnum):
SUCCESS = 0
COMMON_FAILURE = 1
def flask_response(
su... | PypiClean |
/FreePyBX-1.0-RC1.tar.gz/FreePyBX-1.0-RC1/freepybx/public/js/dojox/dtl.js | This is an optimized version of Dojo, built for deployment and not for
development. To get sources and documentation, please visit:
http://dojotoolkit.org
*/
//>>built
require({cache:{"dojox/dtl/_base":function(){define(["dojo/_base/kernel","dojo/_base/lang","dojox/string/tokenize","dojo/_base/json","dojo/dom","d... | PypiClean |
/FamcyDev-0.3.71-py3-none-any.whl/Famcy/bower_components/bootstrap-table/src/locale/bootstrap-table-th-TH.js | $.fn.bootstrapTable.locales['th-TH'] = $.fn.bootstrapTable.locales['th'] = {
formatCopyRows () {
return 'Copy Rows'
},
formatPrint () {
return 'Print'
},
formatLoadingMessage () {
return 'กำลังโหลดข้อมูล, กรุณารอสักครู่'
},
formatRecordsPerPage (pageNumber) {
return `${pageNumber} รายการต่... | PypiClean |
/Newcalls-0.0.1-cp37-cp37m-win_amd64.whl/newcalls/types/__init__.py | from .browsers import Browsers
from .cache import Cache
from .groups import AlreadyJoined
from .groups import ErrorDuringJoin
from .groups import GroupCall
from .groups import GroupCallParticipant
from .groups import JoinedGroupCallParticipant
from .groups import JoinedVoiceChat
from .groups import LeftGroupCallPartici... | PypiClean |
/Codado-0.8.0.tar.gz/Codado-0.8.0/README.md | # Codado [](https://travis-ci.org/corydodt/Codado)
A library of utilities for systems application development
## Tools included:
- codado.enum: a simple key-(optional value) enumerator builder
- codado.eachMethod: a class decorator that applies a... | PypiClean |
/FamcyDev-0.3.71-py3-none-any.whl/Famcy/bower_components/bootstrap/site/content/docs/5.0/layout/grid.md | ---
layout: docs
title: Grid system
description: Use our powerful mobile-first flexbox grid to build layouts of all shapes and sizes thanks to a twelve column system, six default responsive tiers, Sass variables and mixins, and dozens of predefined classes.
group: layout
toc: true
---
## Example
Bootstrap's grid syst... | PypiClean |
/HOPP-0.0.5-py3-none-any.whl/tools/optimization/candidate_converter/object_converter.py | import functools
from enum import IntEnum
from typing import (
Callable,
Generator,
Iterable,
Iterator,
List,
Optional,
Tuple,
TypeVar,
Union,
)
from ..data_logging.data_recorder import DataRecorder
from .candidate_converter import CandidateConverter
class Type(IntEnum):
V... | PypiClean |
/AyiinXd-0.0.8-cp311-cp311-macosx_10_9_universal2.whl/fipper/node_modules/minizlib/node_modules/minipass/index.js | 'use strict'
const proc = typeof process === 'object' && process ? process : {
stdout: null,
stderr: null,
}
const EE = require('events')
const Stream = require('stream')
const SD = require('string_decoder').StringDecoder
const EOF = Symbol('EOF')
const MAYBE_EMIT_END = Symbol('maybeEmitEnd')
const EMITTED_END = S... | PypiClean |
/EC_MS-0.7.5.tar.gz/EC_MS-0.7.5/src/EC_MS/Chem/Thermochem.py | import re
import numpy as np
from math import gcd
from .PhysCon import R, Far
from .MolarMasses import get_elements
dfH0 = { # standard enthalpies of formation / [kJ/mol]
"H2O(g)": -241.82,
"H2O(l)": -285.8,
"CH3CH2OH(g)": -234.8, # Langes Handbook
"CH3CH2OH(l)": -277,
"CH3CH2CH2OH(g)": -256, ... | PypiClean |
/Blue-DiscordBot-3.2.0.tar.gz/Blue-DiscordBot-3.2.0/README.md | <h1 align="center">
<br>
<a href="https://github.com/aditya-nugraha-bot/AN-DiscordBot"><img src="https://imgur.com/pY1WUFX.png" alt="AN - Discord Bot"></a>
<br>
AN Discord Bot
<br>
</h1>
<h4 align="center">Music, Moderation, Trivia, Stream Alerts and Fully Modular.</h4>
<p align="center">
<a href="https:/... | PypiClean |
/MPInterfaces_Latest_Test-1.0.2.tar.gz/MPInterfaces_Latest_Test-1.0.2/examples/bands_dos.py |
from __future__ import division, print_function, unicode_literals, \
absolute_import
"""
reads in KPOINTS(with labels) and vasprun.xml files and
plots band diagram and density of states
from http://gvallver.perso.univ-pau.fr/?p=587
"""
from six.moves import range
from six.moves import zip
import numpy as np
t... | PypiClean |
/FEW-0.0.51.tar.gz/FEW-0.0.51/few/population.py | import numpy as np
import copy
import pdb
import uuid
from mdr import MDR
from collections import defaultdict
import itertools as it
eqn_dict = {
'+': lambda n,stack_eqn,names: '(' + stack_eqn.pop() + '+' + stack_eqn.pop() + ')',
'-': lambda n,stack_eqn,names: '(' + stack_eqn.pop() + '-' + stack_eqn.pop()+ ')'... | PypiClean |
/0lever_utils-0.1.6-py3-none-any.whl/_lever_utils/foo/helpers/db/mysql_helper.py | import sqlalchemy
import sqlalchemy.orm as sqlalchemy_orm
import pandas as pd
from sshtunnel import SSHTunnelForwarder
class Mysql(object):
_engine = None
_session = None
_ssh_server = None
def __init__(self, *args, **kwargs):
user = kwargs["user"]
password = kwargs["password"]
... | PypiClean |
/COMPAS-1.17.5.tar.gz/COMPAS-1.17.5/src/compas_rhino/geometry/booleans/__init__.py | from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import Rhino
from compas.plugins import plugin
__all__ = [
"boolean_union_mesh_mesh",
"boolean_difference_mesh_mesh",
"boolean_intersection_mesh_mesh",
]
@plugin(category="booleans", requires=[... | PypiClean |
/FiPy-3.4.4.tar.gz/FiPy-3.4.4/fipy/tools/inline.py | from __future__ import unicode_literals
from builtins import range
__all__ = ["doInline"]
from future.utils import text_to_native_str
__all__ = [text_to_native_str(n) for n in __all__]
import inspect
import os
import sys
if '--inline' in [s.lower() for s in sys.argv[1:]]:
doInline = True
else:
doInline = 'FIP... | PypiClean |
/Electrum-CHI-3.3.8.tar.gz/Electrum-CHI-3.3.8/packages/pip/_internal/req/req_install.py | from __future__ import absolute_import
import logging
import os
import shutil
import sys
import sysconfig
import zipfile
from distutils.util import change_root
from pip._vendor import pkg_resources, six
from pip._vendor.packaging.requirements import Requirement
from pip._vendor.packaging.utils import canonicalize_nam... | PypiClean |
/Js2Py-0.74.tar.gz/Js2Py-0.74/js2py/translators/translator.py | import pyjsparser
import pyjsparser.parser
from . import translating_nodes
import hashlib
import re
# Enable Js2Py exceptions and pyimport in parser
pyjsparser.parser.ENABLE_PYIMPORT = True
# the re below is how we'll recognise numeric constants.
# it finds any 'simple numeric that is not preceded with an alphanumer... | PypiClean |
/Misago-0.36.1.tar.gz/Misago-0.36.1/misago/graphql/admin/analytics.py | from datetime import timedelta
from ariadne import QueryType
from django.contrib.auth import get_user_model
from django.core.cache import cache
from django.utils import timezone
from ...threads.models import Attachment, Post, Thread
from ...users.models import DataDownload, DeletedUser
CACHE_KEY = "misago_admin_anal... | PypiClean |
/MPInterfaces_Latest-2.0.3.tar.gz/MPInterfaces_Latest-2.0.3/mpinterfaces/lammps.py |
from __future__ import division, print_function, unicode_literals, \
absolute_import
"""
Calibrate LAMMPS jobs
"""
from six.moves import map
from six.moves import zip
import os
import logging
from collections import OrderedDict
from pymatgen.core.structure import Structure
from pymatgen.io.ase import AseAtomsA... | PypiClean |
/Deliverance-0.6.1.tar.gz/Deliverance-0.6.1/deliverance/selector.py | import re
from lxml.etree import XPath
from lxml.cssselect import CSSSelector
from deliverance.exceptions import DeliveranceSyntaxError
type_re = re.compile(r'^(elements?|children|tag|attributes?):')
type_map = dict(element='elements', attribute='attributes')
attributes_re = re.compile(r'^attributes[(]([a-zA-Z0-9_, -:... | PypiClean |
/JitsiProvS-0.10b1.tar.gz/JitsiProvS-0.10b1/README.txt |
JitsiProvS is a provisioning server for Jitsi(http://jitsi.org/).
Detailed information about Jitsi provisioning can be found here(http://jitsi.org/provisioning/).
The following concepts/ideas apply:
* JitsiProvS is multitenant through the use of domain parameter. Domain parameter is taken from url or decoded from... | PypiClean |
/CProxy-0.1a1.tar.gz/CProxy-0.1a1/README.md | # Caching Proxy
CProxy (CP) is a HTTP caching proxy server written in Python 3. With the aim of being able to surf the Internet completely offline, it will intercept Browser's HTTPs requests and decrypt the the traffic on-the-fly to store each successful HTTP response.
This work is inspired by [coursera-dl](https:/... | PypiClean |
/ExpressPigeon-0.0.8.tar.gz/ExpressPigeon-0.0.8/expresspigeon/contacts.py | class Contacts(object):
"""Contacts endpoint
"""
endpoint = "contacts"
def __init__(self, ep):
self.ep = ep
def upsert(self, list_id, contacts):
""" JSON document represents a list of contacts to be created or updated.
The email field is required.
When updating a co... | PypiClean |
/COMPAS-1.17.5.tar.gz/COMPAS-1.17.5/src/compas_rhino/conversions/_surfaces.py | from __future__ import print_function
from __future__ import absolute_import
from __future__ import division
from compas.geometry import Point
from Rhino.Geometry import NurbsSurface as RhinoNurbsSurface
from ._primitives import point_to_rhino
from ._primitives import point_to_compas
def surface_to_compas_data(sur... | PypiClean |
/CoolAMQP-1.2.15.tar.gz/CoolAMQP-1.2.15/coolamqp/attaches/agroup.py | from __future__ import print_function, absolute_import, division
import logging
logger = logging.getLogger(__name__)
from coolamqp.attaches.channeler import Attache, ST_OFFLINE, ST_ONLINE
from coolamqp.attaches.consumer import Consumer
from coolamqp.attaches.publisher import Publisher
class AttacheGroup(Attache):
... | PypiClean |
/Lokai-0.3.tar.gz/Lokai-0.3/lokai/lk_ui/fcgi_server_up.py |
#-----------------------------------------------------------------------
""" This server provides a pre-forked fcgi server that can be used as
a back end for any httpd server.
Using a pre-forked server means we don't have to rely on the
application being thread-safe.
If you are running with whatever... | PypiClean |
/fastapi_jsonapi-2.0.0.tar.gz/fastapi_jsonapi-2.0.0/fastapi_jsonapi/views/detail_view.py | import logging
from typing import TypeVar, Union
from fastapi_jsonapi import BadRequest
from fastapi_jsonapi.schema import (
BaseJSONAPIItemInSchema,
JSONAPIResultDetailSchema,
)
from fastapi_jsonapi.views.view_base import ViewBase
from fastapi_jsonapi.views.view_handlers import handle_endpoint_dependencies
l... | PypiClean |
/Flask-WeChat-0.1.0.zip/Flask-WeChat-0.1.0/flask_wechat/filters.py |
from functools import reduce
import re
from .messages import WeChatRequest
__all__ = ["all", "and_", "event", "message", "or_"]
_typeof = lambda t: lambda m: m.msgtype==t
def _match(message, contains, accuracy=True, ignorecase=False):
"""帮助匹配文本的函数"""
if ignorecase:
message = message.lower()
... | PypiClean |
/HolmesIV-2021.9.8a1.tar.gz/HolmesIV-2021.9.8a1/mycroft/skills/mycroft_skill/event_container.py | from inspect import signature
from mycroft.messagebus import Message
from mycroft.metrics import Stopwatch, report_timing
from mycroft.util.log import LOG
from mycroft.skills.skill_data import to_alnum
def unmunge_message(message, skill_id):
"""Restore message keywords by removing the Letterified skill ID.
... | PypiClean |
/LiBai-0.1.1.tar.gz/LiBai-0.1.1/libai/engine/trainer.py |
import logging
import time
import weakref
from typing import Callable, List, Mapping
import numpy as np
import oneflow as flow
from libai.utils import distributed as dist
from libai.utils.events import EventStorage, get_event_storage
class HookBase:
"""
Base class for hooks that can be registered with :cla... | PypiClean |
/CryptoRL-0.2.0.tar.gz/CryptoRL-0.2.0/docs/source/example.rst | Examples for the functions
=============================
*tickers()*
------------
The function gets valid tickers with given keyword information. See the following example:
.. code-block:: python
tickers("USD")
It returns a list containing all the valid tickers with keyword "USD".
*fetch_single()*
------------... | PypiClean |
/Kamaelia-0.6.0.tar.gz/Kamaelia-0.6.0/Axon/Linkage.py | import time
from AxonExceptions import AxonException, ArgumentsClash
from Axon import AxonObject
from util import removeAll
from idGen import strId, numId,Debug
from debug import debug
class linkage(AxonObject):
"""\
linkage(source, sink[, passthrough]) -> new linkage object
An object describing a l... | PypiClean |
/GTW-1.2.6.tar.gz/GTW-1.2.6/_RST/_MOM/Entity.py |
from __future__ import absolute_import, division, print_function, unicode_literals
from _GTW import GTW
from _TFL import TFL
import _GTW._RST.Resource
import _GTW._RST.HTTP_Method
import _GTW._RST._MOM.Mixin
from _MOM.import_MOM import MOM, Q
from _TFL._M... | PypiClean |
/EModelRunner-1.1.16.tar.gz/EModelRunner-1.1.16/emodelrunner/synplas_analysis.py |
# Copyright 2020-2022 Blue Brain Project / EPFL
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
# http://www.apache.org/licenses/LICENSE-2.0
# Unless required by applicable law or agree... | PypiClean |
/Nuitka_fixed-1.1.2-cp310-cp310-win_amd64.whl/nuitka/build/inline_copy/lib/scons-2.3.2/SCons/Tool/linkloc.py |
__revision__ = "src/engine/SCons/Tool/linkloc.py 2014/07/05 09:42:21 garyo"
import os.path
import re
import SCons.Action
import SCons.Defaults
import SCons.Errors
import SCons.Tool
import SCons.Util
from SCons.Tool.MSCommon import msvs_exists, merge_default_version
from SCons.Tool.PharLapCommon import addPharLapPa... | PypiClean |
/BIT_framework-0.0.2-py3-none-any.whl/BIT_DL/pytorch/modules/decoders/gpt2_decoder.py | import sys
from typing import Dict, Optional, Tuple, Union
import torch
from BIT_DL.pytorch.modules.decoders.decoder_helpers import Helper
from BIT_DL.pytorch.modules.decoders.transformer_decoders import \
TransformerDecoder, TransformerDecoderOutput
from BIT_DL.pytorch.modules.embedders import PositionEmbedder, ... | PypiClean |
/Notable-0.4.2.tar.gz/Notable-0.4.2/notable/static/lib/ace/src-min/mode-sh.js | define("ace/mode/sh",["require","exports","module","ace/lib/oop","ace/mode/text","ace/tokenizer","ace/mode/sh_highlight_rules","ace/range"],function(e,t,n){var r=e("../lib/oop"),i=e("./text").Mode,s=e("../tokenizer").Tokenizer,o=e("./sh_highlight_rules").ShHighlightRules,u=e("../range").Range,a=function(){var e=new o;t... | PypiClean |
/DeepSR-0.0.80.tar.gz/DeepSR-0.0.80/README.md | ## <p align='center'> A Python Tool for Obtaining and Automating Super Resolution with Deep Learning Algorithms </p>
[](https://doi.org/10.5281/zenodo.4310169)
<p align='justify'>
DeepSR is an open source progam that eases the entire processes of the Supe... | PypiClean |
/Flask_AdminLTE3-1.0.9-py3-none-any.whl/flask_adminlte3/static/plugins/moment/locale/tzm.js |
;(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined'
&& typeof require === 'function' ? factory(require('../moment')) :
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
factory(global.moment)
}(this, (function (moment) { 'use strict';
... | PypiClean |
/GradeBot-0.1.8.tar.gz/GradeBot-0.1.8/README.txt | GradeBot by AlexKang
This is my first project in Python. It is a grade report generator and a GPA calculator.
You can store the name of courses you are taking, the grades of those courses, and the units those courses are worth. They are stored in a dictionary which is saved into a .txt file using the json module.
Wi... | PypiClean |
/FlaskCms-0.0.4.tar.gz/FlaskCms-0.0.4/flask_cms/static/js/ckeditor/plugins/codemirror/js/mode/fortran/fortran.js |
(function(mod) {
if (typeof exports == "object" && typeof module == "object") // CommonJS
mod(require("../../lib/codemirror"));
else if (typeof define == "function" && define.amd) // AMD
define(["../../lib/codemirror"], mod);
else // Plain browser env
mod(CodeMirror);
})(function(CodeMirror) {
"use s... | PypiClean |
/AmFast-0.5.3-r541.tar.gz/AmFast-0.5.3-r541/amfast/remoting/cherrypy_channel.py | import threading
import cherrypy
import cherrypy.process.plugins as cp_plugins
import amfast
import amfast.remoting.flex_messages as messaging
from amfast.remoting.channel import ChannelSet, HttpChannel, ChannelError
def amfhook():
"""Checks for POST, and stops cherrypy from processing the body."""
cherrypy... | PypiClean |
/CLAchievements-0.1.0.tar.gz/CLAchievements-0.1.0/doc/index.rst | .. Command Line Achievements documentation master file, created by
sphinx-quickstart on Tue Jul 26 20:04:50 2016.
You can adapt this file completely to your liking, but it should at least
contain the root `toctree` directive.
Welcome to Command Line Achievements's documentation!
==============================... | PypiClean |
/NiMARE-0.2.0rc2.tar.gz/NiMARE-0.2.0rc2/nimare/workflows/base.py | import copy
import itertools
import logging
import os.path as op
from abc import abstractmethod
from nimare.base import NiMAREBase
from nimare.correct import Corrector, FDRCorrector, FWECorrector
from nimare.diagnostics import Diagnostics, FocusCounter, Jackknife
from nimare.meta import ALE, KDA, SCALE, ALESubtraction... | PypiClean |
/CAMELS_library-0.3.tar.gz/CAMELS_library-0.3/scripts/neural_nets/params_2_SFRH/NN_predictions_SIMBA.py | import numpy as np
import torch
import sys,os
sys.path.append('../')
import data as data
import architecture
#################################### INPUT ##########################################
root_in = '/mnt/ceph/users/camels'
root_out = '/mnt/ceph/users/camels/Results/neural_nets/params_2_SFRH/SIMBA'
sim ... | PypiClean |
/ENPC-Aligner-1.0.5.tar.gz/ENPC-Aligner-1.0.5/examples/example.py |
from string import ascii_uppercase, ascii_lowercase, digits
import re
from math import ceil, floor
from operator import itemgetter
from matplotlib.pyplot import plot, show, title, xlim, ylim, xlabel, ylabel, xticks, legend, matshow
from numpy import zeros, ones, infty
from enpc_aligner.dtw import *
def try_example(in... | PypiClean |
/FTIRE_jweng-0.1.4-py3-none-any.whl/FTIRE/genxy.py | import numpy as np
import scipy.linalg as la
__all__ = ['generateX', 'generateY']
def generateX(n, p, covstr):
"""
Generate X for simulation
Args:
n (int): sample size
p (int): number of dimension of X
covstr (0-3): covariance structure
Returns:
X: n times p array
... | PypiClean |
/Data-CAT-0.7.2.tar.gz/Data-CAT-0.7.2/dataCAT/hdf5_log.py | from __future__ import annotations
from typing import Sequence, Tuple, Optional, Any, TYPE_CHECKING
from datetime import datetime
import h5py
import numpy as np
import pandas as pd
from . import CAT_VERSION, NANOCAT_VERSION, DATACAT_VERSION
from .dtype import DT_DTYPE, VERSION_DTYPE, MSG_DTYPE, INDEX_DTYPE
if TYPE_... | PypiClean |
/Hablame-0.4.tar.gz/Hablame-0.4/README.md | # HABLAME CONNECT
Librería de integración de servicio de mensajeria
[Hablame](https://hablame.co) con django.
#### Instalación:
> $ pip install Hablame
ó
> $ pipenv install Hablame
Añadir la linea
> 'Hablame'
settings.py en las installed_apps proyecto de django
#### USO
##### Constructor(
client strin... | PypiClean |
/DendroPy_calver-2023.330.2-py3-none-any.whl/dendropy/dataio/nexusyielder.py |
##############################################################################
## DendroPy Phylogenetic Computing Library.
##
## Copyright 2010-2015 Jeet Sukumaran and Mark T. Holder.
## All rights reserved.
##
## See "LICENSE.rst" for terms and conditions of usage.
##
## If you use this work or any portion there... | PypiClean |
/NESTML-5.3.0-py3-none-any.whl/pynestml/meta_model/ast_simple_expression.py |
from typing import Optional, Union
from pynestml.meta_model.ast_expression_node import ASTExpressionNode
from pynestml.meta_model.ast_function_call import ASTFunctionCall
from pynestml.meta_model.ast_variable import ASTVariable
from pynestml.utils.cloning_helpers import clone_numeric_literal
class ASTSimpleExpressi... | PypiClean |
/FreePyBX-1.0-RC1.tar.gz/FreePyBX-1.0-RC1/freepybx/public/js/dojo/nls/ca/colors.js | define(
"dojo/nls/ca/colors", //begin v1.x content
({
// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information
// is required for each color, such as a palette widget, and not for specifying color programatically.
//Note: due to the SVG 1.0 spec additions, s... | PypiClean |
/Cubane-1.0.11.tar.gz/Cubane-1.0.11/cubane/backend/static/cubane/backend/tinymce/js/tinymce/plugins/fullscreen/plugin.min.js | !function(){"use strict";var e=function(t){var n=t,i=function(){return n};return{get:i,set:function(e){n=e},clone:function(){return e(i())}}},t=tinymce.util.Tools.resolve("tinymce.PluginManager"),n=function(e){return{isFullscreen:function(){return null!==e.get()}}},i=function(e,t){e.fire("FullscreenStateChanged",{state... | PypiClean |
/aleksis_app_alsijil-3.0.1.tar.gz/aleksis_app_alsijil-3.0.1/aleksis/apps/alsijil/migrations/0002_excuse_type.py |
import django.contrib.sites.managers
import django.db.models.deletion
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
("sites", "0002_alter_domain_unique"),
("alsijil", "0001_initial"),
]
operations = [
migrations.CreateModel(
... | PypiClean |
/Flask-Administration-0.1.42.tar.gz/Flask-Administration-0.1.42/flask_administration/static/jsmin/library/g.raphael.js | Raphael.el.popup=function(a,b,c,d){var e=this.paper||this[0].paper,f,g,h,i,j;if(!e)return;switch(this.type){case"text":case"circle":case"ellipse":h=!0;break;default:h=!1}a=a==null?"up":a,b=b||5,f=this.getBBox(),c=typeof c=="number"?c:h?f.x+f.width/2:f.x,d=typeof d=="number"?d:h?f.y+f.height/2:f.y,i=Math.max(f.width/2-b... | PypiClean |
/Activate_App-0.0.10-py3-none-any.whl/activate/activity.py | import shutil
from dataclasses import dataclass
from datetime import datetime
from typing import Optional
from uuid import UUID, uuid4
from activate import serialise
from activate import track as track_
from activate.units import DimensionValue
def from_track(name, sport, track, filename):
return Activity(name, ... | PypiClean |
/Elephantoplasty-0.1.zip/Elephantoplasty-0.1/src/eplasty/field/base.py | from eplasty.object.const import DELETED, UNCHANGED, UPDATED, MODIFIED, NEW
from eplasty.object.exc import LifecycleError
from eplasty import conditions
class Field(object):
"""
Fields are high-level representation of data stored in Objects.
a field can represent a column, a set of columns or some remote r... | PypiClean |
/DividenderX-0.0.5-py3-none-any.whl/Dividender/Dividender.py | import numpy as np
import pandas as pd
import matplotlib.pyplot as plt
def getDividendQuarter(Price, DivdendPerShare, Quarters, Ticker="UnderlyingAsset"):
equityHistory = []
#newerReturn = []
normalDiviReturn = DivdendPerShare/ Price
equity = Price
for i in range(Quarters):
temp = equity * ... | PypiClean |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.