Saravanan666/pypi-org huggingface dataset:
Package: ampcountpy
Some python functions to count the expected amplifications for genomic regions given a set of primer binding locations for amultiple displacement amplificationreaction. SeeampCountRfor more details.InstallationEasy installThe easy way to install is to just do:pip install ampcountpyGithubTo install the development version from github, clone the repository to a local directory using something like:git clone https://github.com/sherrillmix/ampcountpy.gitand runsetup.pyfrom the resulting directory (the–userinstalls it locally and doesn’t require root access):cd ampcountpy
python setup.py install --user
python setup.py testRun directlyThe module can be called directly using something like:python -m ampcountpy -f forward.txt -r reverse.txtor:ampcountpy -f forward.txt -r reverse.txtwhereforward.txtis a text file containing position of primer landing sites on the forward strand andreverse.txtis primer landing sites on the reverse strand. By default, amplification predictions are output to out.csv. The full details on options and arguments is available with:ampcountpy --helpUsing function in pythonThe main function ispredictAmplificationswhich can be used like:fromampcountpyimportpredictAmplificationsforwards=[1,2,3]reverses=[5,6,7]predictions=predictAmplifications(forwards,reverses)whereforwardsare the 5’-most base of primer landing sites on the forward strand andreversesare the 3’-most base of primers landing on the reverse strand.Changelog0.2.0 (2015-12-08)Count non-overlapping primers correctly0.1.3 (2015-11-02)Fix header0.1.2 (2015-11-02)Fix changelog formatting0.1.1 (2015-11-02)Pip install instructions0.1.0 (2015-11-02)Initial public release
Package: ampd
ampd - Asynchronous MPD client libraryCommunicate with a Music Player Daemon server using asyncio.Connection is established by a client object.
Requests (MPD commands) are generated by executor objects, and are awaited for in asyncio coroutines.
Each client has a root executor, and sub-executors can be constructed for grouping related requests.TasksAn AMPD task is an asyncio coroutine decorated by@ampd.task.
The decorator ensures that the task is immediately scheduled for execution, and
that cancellation (e.g., on close()ing the executor) is considered normal termination:@ampd.task
async def task_example():
    ...
    reply = await executor.request1(a, b)
    ...
    reply = await executor.request2()
    ...The request can be:a. AnMPD command(other thanidleornoidle).
Returns when the server's reply arrives:await executor.play(5)
    reply = await executor.status()b. Idle request:reply = await executor.idle(event_mask, timeout=None)This emulates MPD'sidlecommand, with some improvements.
The timeout is given in seconds.
Possible event flags are:Event.<SUBSYSTEM>(in uppercase) orANYto match any subsystem.Event.CONNECT- client is connected to server.Event.IDLE- client is idle.Returns the mask of events which actually occurred, orEvent.TIMEOUTif timeout occurred.c. Command list:executor.command_list(iterable).
Package: ampdata
AmpData API librayThis library is meant as a simple toolkit for working with data fromhttps://ampiato.com/(or equivalent services).  Note that access
is based on some sort of login credentials, this library is not all
that useful unless you have a valid Ampiato account.InstallationYou can simply install/update the latest version of AmpData API python
library with pip.
Start a terminal (a shell) and use the following commandpipinstall-UampdataCopyright (MIT License)Copyright (c) 2024 Ampiato s.r.o.Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.AcknowledgementThis library started as a fork of wapi-python.
Package: ampdLib
README.md rev. 10 Feb 2023 by Luca Cerina.
Copyright (c) 2023 Luca Cerina.
Distributed under the Apache 2.0 License in the accompanying file LICENSE.Automatic Multiscale-based Peak Detection (AMPD)ampdLib implements automatic multiscale-based peak detection (AMPD) algorithm
as in An Efficient Algorithm for Automatic Peak Detection in Noisy Periodic and
Quasi-Periodic Signals, by Felix Scholkmann, Jens Boss and Martin Wolf,
Algorithms 2012, 5, 588-603.Python required dependenciesPython >= 3.6NumpyScipy for testsInstallationThe library can be easily installed with setuptools support usingpip install .or via PyPI withpip install ampdlibUsageA simple example is:peaks = ampdlib.ampd(input)AMPD may require a lot of memory (N*(lsm_limit*N/2) bytes for a given length N and default lsm_limit). A solution is to divide the signal in windows withampd_fastorampd_fast_subor determine a better lsm_limit for the minimum distance between peaks required by the use case withget_optimal_size.TestsThe tests folder contains an ECG signal with annotated peaks in matlab format.ContributionIf you feel generous and want to show some extra appreciation:
Package: ampdup
ampdupA type-hinted async python mpd client library.Summaryampdupis an async/await based MPD library.It is fully type-hinted and MPD responses are typed as well, so it is able to
play nicely withmypyand autocompletion such as what is provided byjedi.ExamplesFirst a basic usage example.make()returns a connected client as a context
manager that handles disconnection automatically.asyncdefmain():asyncwithMPDClient.make('localhost',6600)asm:awaitm.play()The IdleClient class provides theidle()function. Sinceampdupisasync/await-based this loop can easily run concurrently with other
operations.async def observe_state():
    async with IdleClient.make('localhost', 6600) as i:
        while True:
            changed = await i.idle()
            handle_changes(changed)TodoSupport command lists.Support connecting through Unix socket.Support the more obscure MPD features such as partitions.
Package: ampeg
AmpegAmpeg is a simple and lightweight package for parallel computation. It provides
simple functions for scheduling and execution of a set of dependent or
independent computational tasks over multiple processes using themultiprocessingpackage.RequirementsPython 2.7 or laterPython 3.4 or laterInstallationpip install ampegUsageAmpeg exposes a scheduling functionearliest_finish_time, an execution
functionexecute_task_listsand aDependencyclass. The former takes a
directed acyclic graph (DAG) and a number of processes and produces a set of
task lists for each process and a corresponding set of task IDs for translating
the execution result. These two form the input toexecute_task_lists, which
returns a dict with the result of each task in the original graph.The DAG is represented by a python dict of vertices where each key is the ID of
a task and each value is a triple of (function, args or kwargs, computation
cost). Edges are implicitly defined by instances of theDependencyclass in
the args or kwargs.A simple usage example computing (3^2 + 4^2) - (3^2 * 10/2):>>> import ampeg as ag
>>> n_processes = 3
>>> my_graph = {0: (lambda x: x**2, 3, 10.8),
                1: (lambda x: x**2, 4, 10.8),
                2: (lambda x: x/2, 10, 11),
                3: (lambda x, y: x + y, (ag.Dependency(0, None, 1),
                                         ag.Dependency(1, None, 1), 10.7),
                4: (lambda x, y: x*y, (ag.Dependency(0, None, 1),
                                       ag.Dependency(2, None, 1)), 10.8),
                5: (lambda x, y: x - y, (ag.Dependency(3, None, 1),
                                         ag.Dependency(4, None, 1)), 10.9)}
>>> task_lists, task_ids = ag.earliest_finish_time(my_graph, n_processes)
>>> ag.execute_task_lists(task_lists, task_ids)
{0: 9, 1: 16, 2: 5, 3: 25, 4: 45, 5: -20}The Dependency classA dependency is a triple of (task ID or index, key (if any) and communication
cost). The key may be a single key, index or slice, or it may be an iterable of
such values to be applied in sequence. For example, the key('values', 2)extracts the value 5 from the dict{'values': [1, 3, 5]}. Dependency
instances are created byampeg.Dependency(task, key, cost)where cost is
optional and defaults to 0.ExceptionsAmpeg catches exceptions raised by individual tasks, returning them as results
encapsulated in theErrclass. When anErrinstance is found among the
dependencies for a task, the result for this task will be anErrinstance
encapsulating aDependencyError.WindowsNote that under Windows, the functions and their arguments must all be
picklable.
Package: ampel-alerts
Alert support for AMPELEnables the processing ofalertsby AMPEL.The central class of this repository,ampel.alert.AlertConsumer,
is capable of loading, filtering and "ingesting" these alerts.The loading part involves instrument specific classes.The optional filtering part allows the selection of events based on pre-defined rules.
High-throughput systems, such as ZTF or LSST in astronomy, rely on such filters.Duringingestion, the content of alerts is saved into the AMPEL database, possibly together with other different documents which can be created according to pre-defined directives.TheAlertConsumeroperates on the first three tiers of AMPEL: T0, T1 and T2.Loading AlertPerformed by subclasses ofampel.abstract.AbsAlertSupplier.Concrete implementation examples:ampel.ztf.alert.ZiAlertSupplierActions break-down:Load bytes (tar, network, ...)Deserialize (avro, bson, json, ...)First shape (instrument specific): morph intoAmpelAlertorPhotoAlertPurpose: having a common format that theAlertConsumerand alert filters understand. APhotoAlerttypically contains two distinct flat sequences, one for photopoints and one for upperlimits. The associated object ID, such as the ZTF name, is converted into nummerical ampel IDs. This is necessary for all alerts (rejected one as well) since "autocomplete" is based on true Ampel IDs.Filtering AlertAlerts filtering is performed per channel, by subclasses ofampel.abstract.AbsAlertFilter.
AnAlertConsumerinstance can handle multiple filters.
Alert filters methods provided by user units are called by the classFilterBlock,
that handles associated operations (what happens to rejected alerts ? what about auto-complete, etc...)FilterBlockinstances are themselves embedded inFilterBlocksHandlerFilters can return:FalseorNoneto reject an alert.Trueto accept the alert and create all t1/t2 documents defined in the alert processor directiveAnintnumber to accept the alert and create only the t1/t2 documents associated with this group id (as defined in the alert processor directive)Ingesting AlertIf any channel accepts a given alert, DB updates need to occur.
v0.7 brought many updates regarding how ingestion happens.
Class:ampel.alert.ChainedIngestionHandler,ampel.abstract.AbsDocIngesterMore details laterDirectivesNesting is chainingSecond shape: morph intoDataPointAlerts that pass any T0 filter are further shaped in order to fullfill
some requirements for DB storage and easy later retrieval.
Among other things, individual datapoints can be tagged during this step.
For ZTF, upper limits do not feature a unique ID, so we have to build our own.
Each datapoint is shaped into aampel.content.DataPointstructure.Implementation example:ampel.ztf.ingest.ZiDataPointShaperCompilersOptimize the number of created documentsIngestersCreate and upserts documents into the DB
Package: ampel-hu-astro
AMPEL-HU-astroContributed Ampel units from HU/DESY groupDemo install instructions:Create environment with python 3.10+ / poetry. Then run:git clone https://github.com/AmpelProject/Ampel-HU-astro.gitcd Ampel-HU-astro/poetry install -E "ztf sncosmo extcats notebook"cd notebookspoetry run jupyter notebookThis will allow a number of Demo / access / development notebooks to be run. Note that most of them
requires an access token if data is to be retrieved.Contains as of Nov 2022:T0SimpleDecentFilterLensedTransientFilterNoFilterRandFilterSEDmTargetFilterSimpleDecentFilterToOFilterTransientInClusterFilterTransientInEllipticalFilterXShooterFilterRcfFilterRedshiftCatalogFilterT2T2PanStarrThumbPrintT2PhaseLimitT2PS1ThumbExtCatT2PS1ThumbNedSNCosmoT2PS1ThumbNedTapT2LCQualityT2BrightSNProbT2TNSEvalT2InfantCatalogEvalT2RunSncosmoT2CatalogMatchLocalT2DigestRedshiftsT2RunPossisT2RunTDET2RunParsnipT2RunSnoopyT2MatchBTST2NedTapT2NedSNCosmoT2PropagateStockInfoT2GetLensSNParametersT2LSPhotoZTapT2ElasticcRedshiftSamplerT2TabulatorRiseDeclineT2XgbClassifierT2ElasticcReportT2FastDeclinerT3TransientInfoPrinterTransientViewDumperChannelSummaryPublisherSlackSummaryPublisherRapidBaseRapidSedmRapidLcoTNSTalkerTNSMirrorUpdaterTransientTablePublisherHealpixCorrPlotterPlotLightcurveSampleElasticcClassPublisherVOEventPublisher
Package: ampel-nuclear
Ampel-nuclearCentral repository to host AMPEL code to search for and analyze nuclear transients. At the moment, this is exclusively code from the ZTFbh science working group.InstallationPrerequisitesYou need to export environment variables for theAMPEL ZTF archive(tokens are availablehere), forFritz, and for the dropbox API (ask Sjoert).Furthermore, you need a running instance ofMongoDB. On macOS, make sure you have the command line tools installed (in doubt, runxcode-select –install).SetupCreate a fresh Python 3.10 conda envconda create -n tde_filter_upgrade python=3.10
conda activate tde_filter_upgradeInstall is done via poetry:pip install poetry 
git clone https://github.com/AmpelProject/ampel-nuclear
cd Ampel-nuclear
poetry installNow we have to build the ampel config and install it in the conda env. Issueampel config installNote: this will throw some import errors, but you can ignore these because those packages are not needed locally.Now you need to export the following tokensexport AMPEL_ARCHIVE_TOKEN='' 
export DROPBOX_TOKEN=''
export FRITZ_TOKEN=''TestTo run the test, start your local MongoDB. And then issue./run_tde_scan.py -iIf you cannot execute the file, issuechmod +x run_tde_scan.py.Note: To push the result of a run to the dropbox, add-p.The-iinitiates (and saves) a new archive API stream token. To request one day, use-d YYYY-MM-DDfor a certain day. The script will request alerts for the 24 hours after this date.Your can also use--daysago nto scan the lastndays.Note: When requesting a full day with-dor the lastndays with--daysago nfrom the archive, the first run will probably fail, as the archive database has not fully ramped up yet (URL is locked). In this case, just rerun./run_tde_scan.py, without any parameters except for-pif you want to enable dropbox-push to prevent requesting a new stream token and overwriting the current one until the archive starts serving alerts (you will see them getting ingested).To check the output, go to thetempdirectory that gets created when script is run without-p(push to dropbox), or check the dropbox.To see all available commands of the test script, run./run_tde_scan.py -h.Examples./run_tde_scan.py -i --daysago 4 -pThis will perform a search for the last 4 days and push the results to the dropbox../run_tde_scan.py -i -d 2022-10-06This will perform a search for October 6, 2022 and save the result in a local directory.
Package: ampere
Ampere - Advanced Model Package for ElectRochemical ExperimentsAmpereis a Python module for working with battery models.Using ascikit-learn-like API, we hope to make visualizing, fitting, and analyzing impedance spectra more intuitive and reproducible.Ampere is currently in the alpha phase and new features are rapidly being added.If you have a feature request or find a bug, please feel free tofile an issueor, better yet, make the code improvements andsubmit a pull request! The goal is to build an open-source tool that the entire electrochemical community can use and improveAmpere currently provides:A simple API for fitting, predicting, and plotting discharge curvesA simple API for generating data, or fitting with arbitrary charge / discharge patterns.InstallationDependenciesAmpere requires:Python (>=3.5)SciPy (>=1.0)NumPy (>=1.14)Matplotlib (>=2.0)Cython (>=0.29)Several example notebooks are provided in the examples/ directory. Opening these will require Jupyter notebook or Jupyter lab.User InstallationThe easiest way to install Ampere is using pip:pip install ampereHowever, it depends on Cython and Microsoft c++ libraries in order to install (on windows). Those should be added as follows:pip install --upgrade cython setuptoolsfollowthese instructionsto install the proper c++ libraries using Microsoft tools.That may or may not work, depending upon your system. An alternative method of installation that works is:git clone https://github.com/nealde/ampereI've recently added the Cython-generated c files back to the repo, so it may be as simple as:cd amperepython setup.py installHowever, if that doesn't work, the following will rebuild the files:cd ampere/models/P2Dpython setup.py build_ext --inplacecd ../SPMpython setup.py build_ext --inplaceThis will build the local C code that is needed by the main compiler.  Then, you can cd back up to the main folder andpython setup.py installThat will typically work.  I'm still working on getting pip installation working, and it will likely require some package modifications,
following SKLearn as a guide.Examples and DocumentationExamples and documentation will be provided after my Defense, which is set for the end of May.On the HorizonCurrently, all models are solved with Finite Difference discretization.  I would love to use some higher order spatial discretizations.Currently, the results have not been verified with external models. That is still on the to-do list, and to incorporate those values into the test suite would be excellent.Some of my published work regarding surrogate models for solving and fitting will be implemented once they are fully fleshed out.Add ability to serialize / deserialize models from disk, to save the result of an optimizationadd ability to have custom Up / Un functions for different battery chemistriesadd documentation / fix docstrings to be accurateadd Latex equations and node spacings
Package: ampersand
The really,reallyminimalistic static site generator. Manage
translations statically, without any pesky JavaScript for rendering
dynamic chunks of localized text.FeaturesSeparate key phrases (or everything, for that matter) into “modals”
and localized content files.Create includes such as site-wide headers and footers to reduce
repetition.Avoid copy and pasting the same content several times with global
translations.Keep things simple with Mustache templates.Extend Ampersand with plugins written in Python.The problemTraditionally, managing translations of a website statically would look
something like this:__ root
|
|__ scripts
|  |__ scripts.js
|
|__ styles
|  |__ styles.css
|
|__ lang
    |__ en
    |  |__ index.html
    |  |__ about.html
    |  |__ ...
    |
    |__ fr
        |__ index.html
        |__ about.html
        |__ ...Here, we have a website with two or more English pages that we also
translated into French. This works, but what happens when I want to make
some changes toindex.html? Now, I need to copy those changes over
to thefrfolder and adapt. When these phrases are wrapped with new
UI components, It gets worse the more languages you add.The solutionA problem like this would take a static site generator to solve, but not
just any static site generator would do the trick. This generator must
have a focus on translation, allowing you to build several copies of the
same page based on different localization files.Now, you can leave the translation to the globalization team and focus
on your code.PhilosophySo as you can tell, Ampersand is a pretty straightforward static site
generator. Some may even argue that it doesn’t do much. This is because
Ampersand is aminimalisticstatic site generator. But of course, all
static site generators mention minimalism in their mission statement so
saying it here doesn’t mean much. Never the less, Ampersand aims to do
what it’s supposed to do without jumping through too many hoops that
don’t help it achieve its goal.InstallationSetting up Ampersand is fairly simple if you havepip. For those of
you who don’t,python.orghas it documented.$ pip install ampersandFor a bleeding edge and developer version, you can clone the repository:$ git clone https://github.com/natejms/ampersand.git
$ cd ampersand
$ pip install .To learn more about the usage of Ampersand, check outthe
documentationContributingInterested in making a contribution? Here’s a few places where you might
be able to help out:Contribute patches and help develop new featuresDevelop a plugin for AmpersandWork to improve the documentationHelp spread the wordMore information can be found in the CONTRIBUTING.md file of this
repository.
Package: ampform
AmpFormAmpForm is a Python library of spin formalisms and dynamics with which you can
automatically formulate symbolic amplitude models for Partial Wave Analysis. The
resulting amplitude models are formulated withSymPy(a Computer Algebra System). This not only
makes it easy to inspect and visualize the resulting amplitude models, but also means
the amplitude models can be used as templates for faster computational back-ends (seeTensorWaves)!Visitampform.rtfd.iofor several usage examples. For
an overview ofupcoming releases and planned functionality, seehere.Available featuresAutomatic amplitude model buildingConvert state transition graphs fromQRulesto an amplitude model that ismathematically expressedwithSymPyand can beconverted
to any backend(seeTensorWaves).Spin formalismsHelicity formalismCanonical formalismSpin alignmentfor generic, multi-body decays that feature different decay topologiesDynamicsRelativistic Breit-Wigner,
optionally with form factors and/orenergy-dependent widthSymbolicK-matrixfor an arbitrary number of poles and channelsSymbolicP-vectorfor an arbitrary number of poles and channelsContributeSeeCONTRIBUTING.md
Package: ampgo
ampgoGlobal optimization via adaptive memory programming with a scipy.optimize like API.InstallationpipinstallampgoExample: Minimizing the six-hump camelback function in ampgoimportampgodefobj(x):"""Six-hump camelback function"""x1=x[0]x2=x[1]f=(4-2.1*(x1*x1)+(x1*x1*x1*x1)/3.0)*(x1*x1)+x1*x2+(-4+4*(x2*x2))*(x2*x2)returnfbounds=[(-5,5),(-5,5)]res=ampgo.ampgo(obj,bounds)print(res.x)print(res.fun)DocumentationFor the full API reference check out theonline documentation.HistoryCoded by Andrea Gavana,andrea.gavana@gmail.com. Original hosted athttps://code.google.com/p/ampgo/.  Made available under the MIT licence. Usage and installation modified by Daniel Schmitz.Differences compared to original version:Support all of SciPy's local minimizersReturn a OptimizeResult class like SciPy's global optimizersRequire bounds instead of starting pointJacobian and Hessian supportSupport all of NLopt's local minimizers (requiressimplenlopt)Drop support for OpenOpt solvers as OpenOpt has been stale for several years