Saravanan666/pypi-org huggingface dataset:
Package: completions
completionsShell completions for your program made easy.Installationpipinstallcompletions# install lastest version using poetrygitclonehttps://github.com/pwwang/completionscdcompletions
poetryinstallUsageDefining your completionsYou may define your completions, basically commands and options, by following schema (showed inyaml, but can be any format supported bypython-simpleconf:example.yamlprogram:# your program, or path to your programname:completions-exampledesc:Shell completions for your program made easy.# whether global options should be inherited by commandsinherit:true# options or global options if you have commandsoptions:-s:The shell, one of bash, fish, zsh and auto.--shell:The shell, one of bash, fish, zsh and auto.-a:Automatically write completions to destination file.--auto:Automatically write completions to destination file.commands:# No other options for command, give the descriptionself:Generate completions for myself.generate:desc:Generate completions from configuration files.options:-c:The configuration file to load.--config:The configuration file to load.How it looks like infish:Generating completion scriptsBash>completionsgenerate--shellbash\--configexample.yaml>~/bash_completion.d/completions.bash-completionYou may need tosourceit in your.bashrcand restart your shell for the changes to take effect.Fish>completionsgenerate--shellfish\--configexample.yaml>~/.config/fish/completions/completions.fishYou may need to restart your shell for the changes to take effect.Zsh>completionsgenerate--shellzsh\--configexample.yaml>~/.zsh-completions/_completionsMake surefpath+=~/.zsh-completionsis put beforecompinitin you.zshrcSaving completions scripts automaticallyBash>completionsgenerate--shellbash--configexample.yaml--autoFish>completionsgenerate--shellfish--configexample.yaml--autoZsh>completionsgenerate--shellzsh--configexample.yaml--autoPython APIfromcompletionsimportCompletionscompletions=Completions(# if not given, will be read from sys.argv[0]name='completions',# Add global options to commandsinherit=True,desc='Shell completions for your program made easy.')completions.addOption(['-s','--shell'],'The shell, one of bash, fish, zsh and auto.')completions.addOption(['-a','--auto'],'Automatically write completions to destination file.')completions.addCommand('self','Generate completions for myself.')completions.addCommand('generate','Generate completions from configuration files.')completions.command('generate').addOption(['-c','--config'],'The configuration file to load.')completions.generate(shell='fish',auto=False)
Package: completions-resurrection
This is not being maintained.Please check:https://github.com/pwwang/pyparamfor shell completions.completionsShell completions for your program made easy.Installationpipinstallcompletions# install lastest version using poetrygitclonehttps://github.com/pwwang/completionscdcompletions
poetryinstallUsageDefining your completionsYou may define your completions, basically commands and options, by following schema (showed inyaml, but can be any format supported bypython-simpleconf:example.yamlprogram:# your program, or path to your programname:completions-exampledesc:Shell completions for your program made easy.# whether global options should be inherited by commandsinherit:true# options or global options if you have commandsoptions:-s:The shell, one of bash, fish, zsh and auto.--shell:The shell, one of bash, fish, zsh and auto.-a:Automatically write completions to destination file.--auto:Automatically write completions to destination file.commands:# No other options for command, give the descriptionself:Generate completions for myself.generate:desc:Generate completions from configuration files.options:-c:The configuration file to load.--config:The configuration file to load.How it looks like infish:Generating completion scriptsBash>completionsgenerate--shellbash\--configexample.yaml>~/bash_completion.d/completions.bash-completionYou may need tosourceit in your.bashrcand restart your shell for the changes to take effect.Fish>completionsgenerate--shellfish\--configexample.yaml>~/.config/fish/completions/completions.fishYou may need to restart your shell for the changes to take effect.Zsh>completionsgenerate--shellzsh\--configexample.yaml>~/.zsh-completions/_completionsMake surefpath+=~/.zsh-completionsis put beforecompinitin you.zshrcSaving completions scripts automaticallyBash>completionsgenerate--shellbash--configexample.yaml--autoFish>completionsgenerate--shellfish--configexample.yaml--autoZsh>completionsgenerate--shellzsh--configexample.yaml--autoPython APIfromcompletionsimportCompletionscompletions=Completions(# if not given, will be read from sys.argv[0]name='completions',# Add global options to commandsinherit=True,desc='Shell completions for your program made easy.')completions.addOption(['-s','--shell'],'The shell, one of bash, fish, zsh and auto.')completions.addOption(['-a','--auto'],'Automatically write completions to destination file.')completions.addCommand('self','Generate completions for myself.')completions.addCommand('generate','Generate completions from configuration files.')completions.command('generate').addOption(['-c','--config'],'The configuration file to load.')completions.generate(shell='fish',auto=False)
Package: completion-utils
completion_utilsA lightweight set of functions intended to make writing shell completion functions in python easier. Install withpip install completion-utilsand import what you need fromcompletion_utils. Generally you only need to importbash_completion_decorator, and decorate a function with it.UsageSupposing you have some simple completion like this already...#!/usr/bin/env python3
import sys

def foobar():
    return ["a", "bunch", "of", "potential", "matches"]


def completion_hook(cmd, curr_word, prev_word):
    potential_matches = foobar()
    matches = [k for k in potential_matches if k.startswith(curr_word)]
    return matches


def main():
    results = completion_hook(*sys.argv[1:])
    if len(results):
          print("\n".join(results))


if __name__ == "__main__":
    main()You can then decoratecompletion_hookwithbash_completion_decoratorto have shell completion automatically supply the necessary arguments and use bash_complete to test out the results of potential completions.#!/usr/bin/env python3
import sys
import unittest
from completion_utils import bash_completion_decorator, bash_complete

class CompletionTestCase_up(unittest.TestCase):
    def test_all_options_show(self):
        expected = "\n".join(sorted(foobar()))
        actual = bash_complete("heylook ", __file__)

    def test_one_option(self):
        expected = "m"
        actual = bash_complete("heylook m", __file__)

def foobar():
    return ["a", "bunch", "of", "potential", "matches"]


@bash_completion_decorator
def completion_hook(cmd, curr_word, prev_word):
    potential_matches = foobar()
    matches = [k for k in potential_matches if k.startswith(curr_word)]
    return matches

if __name__ == "__main__":
    completion_hook()
Package: complex
ComplexCompute complex numbers operations such as addition, substraction, multiplication , division, modulus, conjugate and angle.InstallationOS X , Windows & Linux:pipinstallcomplexUsage exampleUse for complex number mathematicsfromcompleximportComplexx=Complex(2,3)y=Complex(4,5)print(x+y,x-y,x*y,x/y,x.mod(),y.mod(),x.angle(),y.angle(),x.conjugate(),y.conjugate(),x.log(),y.log())Development setupFor local development setupgitclonehttps://github.com/deepak7376/complexcdcomplex
pipinstall-rrequirements.txtMetaDeepak Yadav –@imdeepak_dky–dky.united@gmail.comDistributed under the MIT license. SeeLICENSEfor more information.https://github.com/deepak7376/complex/blob/master/LICENSEContributingFork it (https://github.com/deepak7376/complex/fork)Create your feature branch (git checkout -b feature/fooBar)Commit your changes (git commit -am 'Add some fooBar')Push to the branch (git push origin feature/fooBar)Create a new Pull RequestReferencesNone
Package: complex-attn
Complex TransformerThe open source implementation of the attention and transformer from "Building Blocks for a Complex-Valued Transformer Architecture" where they propose an an attention mechanism for complex valued signals or images such as MRI and remote sensing.They present:complex valued scaled dot product attentioncomplex valued layer normalizationresults show improved robustness to overfitting while maintaing performance wbhen compared to real valued transformerInstallpip install ctLicenseMIT
Package: complexaudio
Complexaudio wrapperSome extensions to simpleaudio has been done such as music pause and resuming. Even though the pypi name is complexaudio,
you may use the import package names as “simpleaudio”.Simpleaudio PackageThe simplaudio package provides cross-platform, dependency-free audio playback
capability for Python 3 on OSX, Windows, and Linux.MIT Licensed.Documentation at RTFDInstallationInstallation (make sure thepipcommand is the right one for
your platform and Python version):pip install complexaudioSee documentation for additional installation information.Quick Function Checkimportsimpleaudio.functionchecksasfcfc.LeftRightCheck.run()See documentation for more on function checks.Simple Exampleimportsimpleaudioassawave_obj=sa.WaveObject.from_wave_file("path/to/file.wav")play_obj=wave_obj.play()play_obj.wait_done()SupportFor usage and how-to questions, first checkout the tutorial in the
documentation. If you’re still stuck, post a question onStackOverflowandtag it ‘pysimpleaudio’.For bug reports, please create anissue on Github.Big Thanks To …Jonas KalderstamChristophe GohlkeTom ChristieMany others for their contributions, documentation, examples, and more.
Package: complexity-science
Complexity Science PackageThis package is created mainly for convenience in doing complex systems research.The design implementation and structure of the package is motivated for scalability and ease of use.
Optimization maybe limited by the design, or the language itself.Downloadpip install complexity-scienceCellular AutomataBasic usage:import complexity_science.ca as cs1-D CAca = cs.wolfram(N, 20) #creates a 1-Dimensional CA of N cells with wolfram rule number 20ca.initialize([50]) #initializes the 50th cell of the CAca.run(100) #returns the resulting state of the CA for 100 iterations following the rule and plots the result with a default colormap2-D CAmodel = cs.brians_brain([128,128], toroidal=False)Initializes a CA based on brians brain with toroidal boundary conditionsAvailable modelscs.game([dim], toroidal=True)cs.applause([dim],  alpha=1)cs.mpa([dim], percent_mpa=0)Thedimparameter is the only required parameter for all models, others are optional. Parameters are set to default value if not specified.alphaandpercent_mpaare examples of model specific parameters.See model documentation for more information.Modifying ParametersModels can be initialized randomly, binary, by index, using different functions
e.g.model.initialize_random()model.initialize_random_bin(0.5)model.initialize_random_int(0,2)Models with specific parameters can be modified by this function.model.modify_rule(parameter = new_value)See model documentation for more information on available parametersAdding rules and modelsPlease contact the author for more information.Animationmodel.animate(iteration=100)Ifiterationis not set, animation will continue infinitely.Animation in jupyter notebookimport complexity_science.ca as cs
import matplotlib.pyplot as plt

from matplotlib import animation, rc
from IPython.display import HTMLAn exampleGame Of Lifeanimation will be as followsgame = cs.game([50,50])
game.initialize_random_bin(0.5)
anim = game.jyp_anim()

HTML(anim.to_html5_video())Network FragmentationCOMING SOON!Contributing:git clone https://github.com/KristerJazz/complexity-science.git
Package: complex-linear-network-analyzer
Complex Linear Network Analyzer (COLNA)The complex linear network analyzer (COLNA) python package analytically computes the propagation of complex valued signals in networks with linear nodes and directed, complex valued and delayed edges.COLNA can be used to model linear, photonic circuits (e.g. Si photonic integrated circuits). It provides an analytic expression of the systems transfer matrix, which is often useful to better understand the effect of system parameters on the output signal.COLNA offers an easy and well documented interface, which allows to quickly build network models and understand their behaviour.COLNA computes all paths leading from input to output nodes down to a certain amplitude accuracy threshold. It also supports the evaluation of recurrent paths (loops).COLNA supports the mixed use of numeric and symbolic numbers (variable) for all edge properties.COLNA can inject complex valued signals to the network and the compute the resulting signals at the output nodes using a testbench.COLNA was developed to compute coherent wave propagation in linear photonic circuits but it can be used in other areas, where signal propagation through linear complex valued networks is of relevance.COLNA is well suited for educational purposes, where analytic expression help to better understand the functionality of simple photonic networks, like for example a Mach-Zehnder interferometer.DocumentationDocumentation including a full reference, tutorials and examples is availablehere.InstallationPip install the COLNA package. All required packages are installed automatically.pip install complex-linear-network-analyzerIf you intend to use the visualization feature, Graphviz must be installed and added to the path and the COLNA package must be
installed as follows:pip install complex-linear-network-analyzer[Visualization]Details for the installation are given in theuser manual.RequirementsNumpy, Scipy, Matplotlib, tqdmFor visualization: Graphviz + Graphviz Python Package (see installation instructions for details)
Package: complexnetwork
Self-Organizing Criticality:This repository has methods to investigate criticality in Complex networks. The API is under active development, breaking changes may occur.Installationpipinstallcomplexnetworkto install from source,pipinstallgit+https://github.com/Saran-nns/complexnetworkWorkflowAvalanche size, interval, durationPower laws (Zipf's law) for avalanche size, interval, durationExponent Estimate and UncertaintyIsing Model - One and Two point function correlation and covariancePlottersScaling functionExponent Relationships - Avalanche Lifetime Exponent, Size distribution exponent, Height rescaling ExponentBranching Process - Branching RatioDifferent Phase TransitionsInformation transfer - Mutual Information, Transfer Entropy , Partial Information Decomposition, Active information storage, Memory capacityPyPi packageAutoDocReferences
Package: complex-network-tools
complex-network-toolscomplex-network-tools is a Python package for generating, learning, and analysis of complex networks.ExamplesSynthetic network generatingfromcnt.generatorimporterdos_renyi_graph# generate a Erdos Renyi(ER) random graphG=erdos_renyi_graph(num_nodes=100,num_edges=400,is_directed=False,is_weighted=False)# generate a Barabasi Albert(BA) scale-free graphG=barabasi_albert_graph(num_nodes=100,num_edges=400,is_directed=False,is_weighted=False)Network attackfromcnt.robustness.network_attackimportnetwork_attack# get attack sequence of nodesG=erdos_renyi_graph(num_nodes=100,num_edges=400,is_directed=False,is_weighted=False)# node-removal based network attacks, use the targeted-degree based node-removal strategyattack_sequence=network_attack(graph=G,attack='node',strategy='degree')Spectral measurefromcnt.spectral_measure.robustness_spectral_measureimportspectral_gap# calculate spectral gap for a graphG=erdos_renyi_graph(num_nodes=100,num_edges=400,is_directed=False,is_weighted=False)spectral_gap(G)Installpipinstallcomplex-network-tools
Package: complex-number
ComplexNumberComplexNumber class to perform complex operations.
You can take a look at the source codehere.Installationpip install complex-numberUsage examplefromcomplex_numberimportComplexNumberimportmathz1=Complex(1,2)# real, imagz2=Complex.from_polar(2,math.pi)# modulus, argumentprint(z1)z2.print(4)# set precision (defaults to 2)z2.print_polar(4)# set precision (defaults to 2)print(z1.real)z1.real=5print(z1.imag)z1.imag=-3print(z1.modulus)z1.modulus=4print(z1.argument)z1.argument=math.pi/2Math operationsprint(z1+z2)z1+=z2print(z1-z2)z1-=z2print(z1*z2)z1*=z2print(z1/z2)z1/=z2print(z1**3)z1**=3print(z1.root())# defaults to 2print(z1.root(3))# returns a tuple of ComplexNumbers with all solutionsprint(+z1)print(-z1)Additional Operationsprint(z1.conjugate())print(z1.polar())# returns dictionary with the keys: modulus and argument.print(ComplexNumber.to_cartesian(modulus=2,argument=math.pi))# returns tuple with real and imag part.Check for Equalityprint(z1==z2)# true if real and imag parts are both equal to each other
Package: complexNumbers
complexNumbersUse complex numbers in python.1 Initial Complexz = Complex(value)value can be 5 different datatypes:intfloatcomplexstrComplex1.1int, floatThey are used when a real number should be become a complex number. (no imaginary part)1.2complexStandard complex numbers also can be initialed. (e.g.:1+1j)1.3strWith a string there can be entered complex numbers in the cartesian and polar form.1.3.1 cartesian formshould be entered like this:"x+yj"1.3.2 polar formModulus and argument are separated bye^. (e.g.:1e^1)1.4ComplexValue can also be the same type as the own class.2 VariablesThe class has following__self__variables.real: real part of the cartesian formimaginary: imaginary part of the cartesian formmodulus: modulus of the polar formargument: argument of the polar form in the range [0; 2Pi[3 MethodsThe class can be used with the following methods:__add__ , __radd__ , __iadd__equals+ , +=__sub__ , __rsub__ , __isub__equals- , -=__mul__ , __rmul__ , __imul__equals* , *=__truediv__ , __rtruediv__ , __itruediv__equals/ , /=__pow__equals**ATTENTION:only real numbers can be used aspowerand when used to get a root only one
solution returns.__eq__equals==__ne__equals!=__abs__equalsabs()returns the modulus__str__equalsstr()returns the number in cartesian form (e.g.:"1+1j")root(n)returns a list with all possible roots of the complex number.nis the power of the root (e.g.: n = 2 ...
square root)4 Example>>> a = Complex("1+1j")
>>> b = Complex("1e^1")
>>> print(a.modulus)
1.4142135623730951
>>> print(a.argument)
0.7853981633974483
>>> print(b.real)
0.5403023058681398
>>> print(b.imaginary)
0.8414709848078965
>>> print(a+b)
1.5403023058681398+1.8414709848078965j
>>> print(a-b)
0.45969769413186023+0.1585290151921035j
>>> print(a*b)
-0.30116867893975674+1.3817732906760363j
>>> print(a/b)
1.3817732906760363-0.30116867893975674j
>>> print(a**2)
1.2246467991473535e-16+2.0000000000000004j
>>> print(b**0.5)
0.8775825618903728+0.479425538604203j
>>> print(b.root())
[0.8775825618903728+0.479425538604203j, -0.8775825618903728-0.4794255386042029j]
>>> print(abs(b)
1.0
>>> print(a == a)
True
>>> print(a != b)
True
Package: complexoperations-iperoyg
devops-experimentsEste é um projeto de teste para fazer experimentações de DevOps no GitHubAuthor:Arthur IperoygBasic instructionsUtilize o arquivo deambiente condapara replicar o ambienteconda env create -n devops-experiments-env -f env.ymlPrefiramodificar os arquivos deambiente condaou derequerimentos do pippara modificar/adicionar/remover bibliotecas aoinvés de operar diretamente nos ambientes.conda env update -n devops-experiments-env -f env.ymlPara executar os testes, usepytestpytestPara executar a verificação de lint, use oflakeflake8 . --count --statisticsflake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statisticsPara atualizar a documentação gerada automaticamente (dentro da pasta dedocumentação) utilize o pdocpdoc src\complexoperations -o docsPara contribuirUse sua imaginação
Package: complex-random
random-complexA package for the most basic complex random sampling.fromrandom_compleximportcrandomnimportmatplotlib.pyplotaspltx=crandomn(size=1000000)plt.figure(figsize=(6,6),dpi=300)plt.hexbin(x.real,x.imag,gridsize=(173,100),lw=0.2,extent=(-2.5,+2.5,-2.5,+2.5))plt.xlim((-2.5,+2.5))plt.ylim((-2.5,+2.5))plt.xlabel('Re(x)')plt.ylabel('Im(x)')plt.show()Installationpip install random-complexUsageThis package provides three functions, that mimic their correspondingnumpy.randomanalogon.crandomucrandomu(size=None, dtype=np.complex128, out=None)Random uniform sampling from the complex unit circle:fromrandom_compleximportcrandomux=crandomu(size=1000000)plt.figure(figsize=(6,6),dpi=300)plt.hexbin(x.real,x.imag,gridsize=(173,100),lw=0.2,extent=(-1.1,+1.1,-1.1,+1.1))plt.xlim((-1.1,+1.1))plt.ylim((-1.1,+1.1))plt.xlabel('Re(x)')plt.ylabel('Im(x)')plt.show()crandomcrandom(size=None, dtype=np.complex128, out=None)Random uniform sampling from within complex unit circle:fromrandom_compleximportcrandomx=crandom(size=1000000)plt.figure(figsize=(6,6),dpi=300)plt.hexbin(x.real,x.imag,gridsize=(173,100),lw=0.2,extent=(-1.1,+1.1,-1.1,+1.1))plt.xlim((-1.1,+1.1))plt.ylim((-1.1,+1.1))plt.xlabel('Re(x)')plt.ylabel('Im(x)')plt.show()crandomncrandomn(loc=0j, scale=((1, 0), (0, 1)), size=None, dtype=np.complex128, out=None)Normal distributed sampling on the complex plane. See first image, or here with unequal variance.fromrandom_compleximportcrandomnx=crandomn(scale=((1,0.5),(0.5,0.5)),size=1000000)plt.figure(figsize=(6,6),dpi=300)plt.hexbin(x.real,x.imag,gridsize=(173,100),lw=0.2,extent=(-2.5,+2.5,-2.5,+2.5))plt.xlim((-2.5,+2.5))plt.ylim((-2.5,+2.5))plt.xlabel('Re(x)')plt.ylabel('Im(x)')plt.show()
Package: complextorch
Complex PyTorch(Available onPyPI)Author: Josiah W. Smith, Ph.D.A lightweight complex-valued neural network package built on PyTorch.This is a package built onPyTorchwith the intention of implementing light-weight interfaces for common complex-valued neural network operations and architectures.
Notably, we include efficient implementations for linear, convolution, and attention modules in addition to activation functions and normalization layers such as batchnorm and layernorm.Although there is an emphasis on 1-D data tensors, due to a focus on signal processing, communications, and radar data, many of the routines are implemented for 2-D and 3-D data as well.DocumentationPlease seeRead the DocsDependenciesThis library requires numpy and PyTorch.PyTorchshould be installed to your environment using the compute platform (CPU/GPU) settings for your machine. PyTorch will not be automatically installed with the installation of complextorch and MUST be installed manually by the user.Instalation:IMPORTANT:
Prior to installation,install PyTorchto your environment using your preferred method using the compute platform (CPU/GPU) settings for your machine.Usingpippip install complextorchBasic Usageimportcomplextorchascvtorchx=cvtorch.randn(64,5,7)