Saravanan666/pypi-org huggingface dataset:
Package: rnd-logger
Rnd LoggerA python logger implementation for the Made Tech R&D departmentThis implementation adds flexibility for in and out of office hours alerts and inherits from the root logger provided
by the python logging module. There are two log handlers available, the standard root logger and a json loggerTestingrunmake testCreating a releaseCommit your changes to main and then create a release on Github.This will trigger a Github action that will increment the version with the tag you have chosen and publish that
version to PyPiPlease use semantic versioning and version relative to the change you have madeUsageUse the rnd_logger:Root Logger:fromrnd_loggerimportrnd_loggerlogger=rnd_logger.get_logger()defyour_test_code():logger.debug("Debug message")logger.info("Info message")logger.warning("Warning message")logger.error_office_hours_alert("Office hours alert message")logger.error_out_of_hours_alert("Out of office hours alert message")Json Logger:fromrnd_loggerimportrnd_loggerlogger=rnd_logger.get_logger("json")defyour_test_code():logger.debug("Debug message",extra={"json_key":"json_value"})logger.info("Info message",extra={"json_key":"json_value"})logger.warning("Warning message",extra={"json_key":"json_value"})logger.error_office_hours_alert("Office hours alert message",extra={"json_key":"json_value"})logger.error_out_of_hours_alert("Out of office hours alert message",extra={"json_key":"json_value"})Testing the rnd_logger:
3. There is a caplog fixture provided by pytestimportloggingdeftest_use_case_logs_info(caplog,use_case_under_test):withcaplog.at_level(logging.INFO):your_test_code()records=iter(caplog.records)record=next(records)assertrecord.message=="your test log"
Package: rnd-pcw-poly
rnd-pcw-polyGenerates random piecewise polynomial functions (for example for testing CPD-algorithms).Exampleimportnumpyasnpimportmatplotlib.pyplotaspltfromrnd_pcw_polyimportrnd_pcw_poly# generate a piecewise polynomial function with 5 "jumps" / 6 segments;# no more than 200 degrees of freedom in total and locally no more than# 6 degrees of freedom.p=rnd_pcw_poly(5,200,6)# plot itxs=np.linspace(0,1,5000)ys=p(xs)plt.scatter(xs,ys)plt.show()The algorithm has seperately seedable and idependent core characteristics like jump locations, dof distribution, realization etc.
Package: rndua
python-rnduaA python module that generate random user agent based on rulesWhy?Most random user agent generator just randomly pick from a large list.
This one is based on rule and software version lists, generate user agent that seems legit but may not actually exist.
The goal is to generate user agent that seems as legit as possible but also keep code complexity low.Currently supported user agent types{Chrome, Firefox} on {Android, Windows, OS X}How it works?Besides the source code,data.mdmay give you some hints.Basic usagefromrndua.rnduaimportRandomUAGeneratorrg=RandomUAGenerator()rg.get_random_user_agent()Advanced usageSee the source code, it's short.
Package: rnginline
rnginline: Flatten multi-file RELAX NG schemasrnginline is a Python library and command-line tool for loading multi-file RELAX
NG schemas from arbitary URLs, and flattening them into a single RELAX NG
schema.FeaturesConvert multi-file RNG schemas into one filewithout breaking or
restructuring the schemasGreat care is taken to maintain the semantics of the separate schema files
in the single outputThe input documents are changed as little as possible, so the output is as
readable as the inputLoad schemas from:The filesystemFrom a Python package's data (without unpacking it to the filesystem)Any type of URL by writing your ownUrlHandlerCommand-line interface & Python APITest suite covering lots of edge cases, e.g. namespace handling100% line & branch code coverageQuickstartInstall with pip (orpipxif you only need the
command-line program):$pipxinstallrnginlineYou can use it from the command line like this:$rnginlinemy-nested-schema-root.rngflattened-output.rngYou can use it from Python like this:>>>importrnginline>>>rnginline.inline('my-nested-schema-root.rng')<lxml.etree.RelaxNGobjectat...>You can load a multi-file schema from a Python package's data like this:>>>importrnginline>>>fromrnginline.urlhandlersimportpydata>>>url=pydata.makeurl('rnginline.test',...'data/testcases/external-ref-1/schema.rng')>>>url'pydata://rnginline.test/data/testcases/external-ref-1/schema.rng'>>>rnginline.inline(url)<lxml.etree.RelaxNGobjectat...>DocumentationDocumentation is available athttp://rnginline.readthedocs.org/Motivationlxmlhas good support for using RELAX NG schemas, but lacks support for
loading multi-file schemas from anywhere other than the filesystem. This is a
problem if you wish to bundle a multi-file schema with your Python
package/module. You'd have to depend on setuptools being available to use itsresource extraction, or use one of the existing RELAX NG merging tools to
convert your schema into a single file.Existing RELAX NG flattening toolsThe following projects didn't quite fit my needs, leading me to write rnginline.
They may work for you though.rng2srng— Implements full
simplification, so the structure of the input schema will be lostrng-incelim— A similar project to this,
implemented in XSLT. Unfortunately doesn't handle namespace declarations on<include>elements correctly. XSLT 1.0 doesn't support creating namespace
nodes, so to fix this rng-incelim would have to resolve all QNames in the
schema to NCNames with ns attributes, which would be undesirable for me.DevelopingInstructions for developers working on this project are inDEVELOPING.md.
Package: rnglfg
lfgPython implementation of Lagged Fibonacci Generator (LFG)There are two methods:lfgToFile(size, param1, param2, filename):This method will create a file using random numbers generated with 
LFG algorithm.

Method will not return anything.

size    : File size
param1  : Lag parameter
param2  : Size of the seed
filename: Name of the output file, overwritten if exists.lfgToList(size, param1, param2):This method will return a list of random numbers generated with 
LFG algorithm.

size    : File size
param1  : Lag parameter
param2  : Size of the seedTo install:sudo python3 setup.py install
Package: rng-rava-diag
RAVA Python DiagnosticsThe RAVA Diagnostics app introduces a test suite designed to evaluate the
statistical properties of randomness produced by the RAVA circuit. It comprises
three distinct sub-applications:Quick Tests: Conducted on relatively small samples generated in real-time
to detect significant errors within the RAVA circuit.Acquisition: Generation of large files comprising pulse counts, bytes, or
numbers extracted from an RAVA device. (This sub-app is imported from theRAVA Python Driverpackage).Detailed Tests: Analyzes the statistical distribution of bias and correlation
metrics associated with the random bytes obtained through the Acquisition
module. Moreover, it explores the normality of pulse count distributions
across different sampling intervals. Additionally, it implements a
visualization of the reports generated by theNIST Tests,
offering an insightful representation of its results.
Lastly, a reporting feature generates a PDF file summarizing the information
from the Detailed Tests. This document is designed to facilitate the quality
assessment of a specific instance of the RAVA circuit.The Diagnostics suite is an open-source implementation of the tests outlined in
the article presenting the RAVA circuit. For more details, refer toIEEE Access, DOI: 10.1109/ACCESS.2023.3327325.Installation and usageThe diagnostics code is available as therng_rava_diagPyPI package. To install it, run:pip install rng_rava_diagRequirements:rng_rava,numpy,matplotlib,scipy,lmfitTo run the diagnostics app, execute:python3 -m rng_rava_diagDocumentationRAVA Python Diagnostics - Statistical TestsDriver CompatibilityRegarding theRAVA Python Driver:Driver v1.1.0 to latest is compatible with Diagnostics from v1.0.0 to latestAssociated projectsRAVA DeviceRAVA FirmwareRAVA Python DriverContactgabrielguerrer [at] gmail [dot] com
Package: rngslib
rngslib: R interface for NGS data analysisPrerequisites:R 3.2+ (down to 3.0 probably OK). When compiling R from source, do not forget to specify –enable-R-shlib at the ./configure step.Python 3.4, with intended compatibility with 2.7 and 3.3.readlinerpy2Install rpy2:From source.> tar -xzf <rpy_package>.tar.gz
> cd <rpy_package>
> python setup.py build install
or
> python setup.py build –r-home /opt/packages/R/lib install # give explicitly the location for the R HOMEBinaries.Get details fromhttp://rpy2.readthedocs.org/en/version_2.7.x/overview.html#background.Install rngslib:> easy_install –prefix=$HOME/local rngslib
Package: rng-to-html-form
Requirementspython 3.4lxml 3.4.4Installpipinstallrng-to-html-formUsageTakes an rng file and makes an html form :fromrng_to_form.rngimportRNGfromrng_to_form.form_makerimportmake_form,make_tree,set_in_nested_dict,order_dicts"""
List of rng tools
"""# Creates an RNG object to use rng toolsrng=RNG(file="/path/to/my/rng/file.rng",target="ArchiveTransfer")# 1 - Tools to make the form# Builds an html form in a stringgenerated_form=make_form(rng)# Returns elements orderorder=rng.find_definitions()# From the specified element, returns all nested ordersform_root=rng.get_form_root(root_name="ArchiveTransfer")# 2 - Tools to get data from the form# Generates a dict of dicts from dot separated keys. Result will be : {'a': {'c': {}, 'b': {}}, 'b': {'d': {}, 'e': {'b': {}, 'a': {}}}}data={'a.b':1,'a.c':2,'b.d':1,'b.e.a':1,'b.e.b':2}tree=make_tree(data)# Makes a nested python object from the form data. It modifies "tree"set_in_nested_dict(tree,data)# Builds the final python object with all ordered elementsorder=rng.find_definitions()all_data={rng.get_form_root(root_name="ArchiveTransfer"):tree}final=order_dicts(all_data,ordered=order)# 3 - Tools to get data from the form# Flattens nested dicts into a single level dict. Result will be : {'a.b': 1, 'a.c': 2, 'b.d' : 1, 'b.e.a': 1, 'b.e.b': 2}dp=dict_path({'a':{'b':1,'c':2},'b':{'d':1,'e':{'a':1,'b':2}}})AuthorsGeoffroy :https://github.com/orgs/unistra/people/geoffroybeckMorgan :https://github.com/orgs/unistra/people/dotmobo
Package: rnlp
Relational NLP Preprocessing (rnlp): A Python package and tool for converting text into a set of relational facts.Documentation:https://rnlp.readthedocs.io/en/latest/Questions?: ContactAlexander L. Hayes (hayesall)InstallationStable builds on PyPipipinstallrnlpQuick-Startrnlpcan be used either as a command line interface (CLI) tool or as an imported Python Package.CLIImported$python-mrnlp-fexample_files/doi.txtReadingcorpusfromfile(s)...Creatingbackgroundfile...100%|████████|18/18[00:00<00:00,38it/s]fromrnlp.corpusimportdeclarationimportrnlpdoi=declaration()rnlp.converter(doi)The relations created byrnlpinclude the following:Sentence’s Relative Position in Block:earlySentenceInBlock: Sentence occurs within the first third of a block.midWaySentenceInBlock: Sentence occurs between the first third and the last third of a block’s length.lateSentenceInBlock: Sentence occurs within the last third of a block’s length.Word’s Relative Position in Sentence:earlyWordInSentence: Word occurs within the first third of a sentence.midWayWordInSentence: Word occurs between a third and two-thirds of a sentence.lateWordInSentence: Word occurs within the last third of a sentence.Relative Position Between Items:nextWordInSentence: Pointer from a word to its neighbor.nextSentenceInBlock: Pointer from a sentence to its neighbor.Existential Semantics:sentenceInBlock: Sentence occurs in a particular block.wordInSentence: Word occurs in a particular sentence.Low-Level Information about words:wordString: A string representation of a word.partOfSpeechTag: The word’s part of speech (as determined by the nltk part-of-speech tagger).—Files contain a toy corpus (example files/) and an image of a BoostSRL tree for predicting if a word in a sentence is the word “you”.The tree says that if the word string contained in word ‘b’ is “you” then ‘b’ is the word “you” with a high probability. (This is of course true).
A more interesting inference is the False branch that says that if word ‘b’ is an early word in sentence ‘a’ and word ‘anon12035’ is also an early word in sentence ‘a’ and if the word string contained in word ‘anon12035’ is “Thank”, then the word ‘b’ has decent chance of being the word “you”. (The model was able to learn that the word “you” often occurs with the word “Thank” in the same sentence when “Thank” appears early in that sentence).
Package: rnnlm-python
RNNLM Toolkit wrapper for python==========================rnnlm-python is a python wrapper module for RNNLM Toolkit.RNNLM Toolkit is developed by Tomas MikolovDetailed information of RNNLM Toolkit can be found athttp://rnnlm.org/Install rnnlm-python--------------------% pip install rnnlm-pythonInstall rnnlm-python (without pip)--------------------% makeIf you want to install, run% sudo make installHow to use--------------------See 'scripts/main.py' as a sample program.License--------------------MIT License
Package: rnnoise-cli
rnnoise-cliA CLI wrapper for the LADSPA plugin athttps://github.com/werman/noise-suppression-for-voice.
To be used with systems running PulseAudio (basically any Linux distro).
This was written out of frustration that Discord+Krisp is unavailable on Linux.
If you'd like a GUI alternative, check outCadmus(as of May 2021, it has some issues and the developer seems to be MIA).InstallationInstall fromPyPI:pip install rnnoise-cliOr install from source, seedevelopment.Enabling shell completionThe click library offers tab completion for bash, zsh and fish, but it's not installed automatically.If you downloaded the source, theMakefilecan generate the relevant scripts after installing (runmake help).
Otherwise, generate a script as follows:_RNNOISE_COMPLETE=bash_sourcernnoise>rnnoise_completion.shYou can replacebash_sourcewithzsh_sourceorfish_sourcefor other shells.
The generated script should be sourced from.bashrc/.zshrc/~/.config/fish/completions/rnnoise.sh.Seethe click documentationfor more info.UsagernnoiseactivateIt will show a list of eligible input devices and prompt you to select one.You can use--controlto set the control level.
Control level 0 means only try to filter noise and never cut to silence,
100 means silence unless RNNoise is 100% sure you're talking.
The default of 50 means that if RNNoise determines the probability that you're talking to be below 50%,
the output will be silent.
Your strategy should be to start at the default of 50 and go up if it blocks too little or down if your voice is
cutting out while talking.A new input option named "RNNoise Denoised Microphone" should now be available to your system.Check outrnnoise --helpfor more commands.Configuring defaultsDefaults are optionally loaded from~/.config/rnnoise_cli/rnnoise_cli.conf.
These settings are overridden by the corresponding options when provided (e.g.--device, seernnoise --help).Example config with currently supported options:[activate]# device to use, omitted by default# `rnnoise activate` will prompt for it if omitted (and provide a list of options)device=some.device.name# control level (0-100), 50 by defaultcontrol=50DevelopmentThe project should work with any Python ≥ 3.7.Create a virtual environment:python3-mvenvvenv# activate or alternatively configure IDE (e.g. PyCharm) to use the env's interpretersourcevenv/bin/activateInstall dev requirements:# this runs pip install -r requirements.txtmakeinitCreditsInitially based on the work athttps://github.com/josh-richardson/cadmusUses the plugin fromhttps://github.com/werman/noise-suppression-for-voice(the fileres/librnnoise_ladspa.sois obtained from
thenoise-suppression-for-voice releases.
)The plugin above is in turn based on a recurrent neural network:https://github.com/xiph/rnnoise
Package: rnnr
rnnrrnnr: neural network runnerrnnrhelps you to run your neural network models, for either training or evaluation.
It is heavily inspired byIgniteandtorchnet, but hopefully simpler and more applicable
to libraries other thanPyTorch.Documentationhttps://rnnr.readthedocs.ioContributingPull requests are welcome! To start contributing, first installflit.pip install flitNext, install this library and its dependencies in development mode.flit install --symlinkLastly, setup the pre-commit hook.ln -s ../../pre-commit.sh .git/hooks/pre-commitTests, the linter, and the type checker can be run withpytest,flake8, andmypyrespectively.LicenseApache License, Version 2.0
Package: rnnsim
OverviewRandom Neural Network Simulator implemented in Python.SetupRequirementsPython 3.6+NumPySklearnInstallationInstall this library directly into an activated virtual environment:$pipinstallrnnsimor add it to yourPoetryproject:$poetryaddrnnsimUsageAfter installation, the package can either be used as:fromrnnsim.modelimportSequentialRNNsequential_model=SequentialRNN([2,2,1])sequential_model.compile()sequential_model.fit(train_data=(X_train,y_train),epochs=50,metrics="acc")print(sequential_model.score((X_test,y_test)))orfromrnnsim.RNNimportRNN# define model connectionsconn_plus={1:[3,4],2:[3,4],3:[5],4:[5],5:[]}conn_minus={1:[3,4],2:[3,4],3:[5],4:[5],5:[]}model=RNN(n_total=5,input_neurons=2,output_neurons=1,conn_plus=conn_plus,conn_minus=conn_minus)model.fit(epochs=N_Iterations,train_data=(X,Y))ReferencesE. Gelenbe, Random neural networks with negative and positive signals and product
form solution," Neural Computation, vol. 1, no. 4, pp. 502-511, 1989.E. Gelenbe, Stability of the random neural network model," Neural Computation, vol.
2, no. 2, pp. 239-247, 1990.
Package: rnotes
rnotesRelease notes manager.This is kindof like reno, except it's faster because it makes some assumptions about git logs,
and uses current tag state, not branch history.The idea is you create a folder with note files, and on your merge CI, you run a linter to ensure that your
devs are posting release notes.The notes relevant to a tag are those committed between that tag's creation and the previous tag (if any).Note history is then easy to extract from git tags and logs.USAGE: rnotes-h, --help            show this help message and exit
  --version VERSION     Version to report on (default: current branch)
  --previous PREVIOUS   Previous version, (default: ordinal previous tag)
  --version-regex VERSION_REGEX
                        Regex to use when parsing (default: from rnotes.yaml)
  --notes-dir REL_NOTES_DIR
                        Release notes folder
  --debug               Debug mode
  --yaml                Dump yaml
  --lint                Lint notes for valid markdown
  --create              Create a new note
  --check               Check if current branch has a release note
  --target TARGET       Target branch for merge (default: from ci env or upstream)
  --blame               Show more commit info in the reportEXAMPLE config: rnotes.yamlencoding: utf8
earliest_version: 0.0.1
release_tag_re: ^((?:[\d.ab]|rc)+)$
editor.win32: notepad.exe
sections:
  - [features, New Features]
  - [issues, Known Issues]
  - [upgrade, Upgrade Notes]
  - [security, Security Issues]
  - [fixes, Bug Fixes]
  - [internal, Internal Changes]
prelude_section_name: release_summary
template: |
  # These notes are public facing!!! Write your notes accordingly.
  release_summary: >
      Replace this text with content to appear at the
      top of the section for this release.
  features:
    - List new features here, or remove this section.
  issues:
    - List known issues here, or remove this section.
  upgrade:
    - List upgrade notes here, or remove this section.
  security:
    - Add security notes here, or remove this section.
  fixes:
    - Add normal bug fixes here, or remove this section.
  internal:
    - List internal non-user-facing notes here, or remove this section(view source)
Package: rnpfind
rnpfindCommand line tool for collecting and generating RNA-RBP interaction data in
various formats.Installationpip install rnpfindRequirements:Python >=3.8Usagernpfindcan be used as a command line tool as follows:rnpfind <transcript>wheretranscriptis a gene name such as "PTEN", or an hg38 coordinate range
(such as 11:65497688-65506516)Note: If a transcript is specified through genomic coordinates, the
transcript is assumed to be on the forward strand (the "+" strand). On the
other hand, a transcript specified by name will have its strand positioning
correctly identified.The tool takes a transcript as input, and computes the binding sites of various
RBPs on the transcript. The information is collected from data sources
including RBPDB, ATTRACT, and POSTAR.The tool produces as output the binding data in a folder (use--out-dirto
specify). A few output formats are supported (use--out-formatto specify):bedformat: a widely usedformatfor displaying intervals. A bed file created in this way could be visualized
on a genome browser, for example. Note the--trackhuboption avaiable to
generate a trackhub structure (useful for hosting a large number of indexed
bed files (bigBed files) and allowing users to view on genome browsers like
the UCSC Genome Browser.csvformat: anNxNtable (whereN=number of RBPs) showing binding
correlations of RBPs on the particular transcript analyzed. This could be
useful for inferring molecular mechanisms on certain regions of the
transcriptome.For more options, runrnpfind --helpWithin PythonYou can importrnpfindto your Python code as follows:from rnpfind import rnpfind

# Collect data on Malat1
rnpfind("malat1")The data is written to disk like in the command line call.
Checkhelp(rnpfind)for keyword arg options.Perhaps not so usefully, you can find the genome versionrnpfindis working
with programatically:from rnpfind import GENOME_VERSION
print(GENOME_VERSION)How does it work?In principle, RNA-RBP interactions can be backed by two forms of evidence:
experimental and computational.The experimental binding sites are collected on large databases such as POSTAR.
The computational binding sites are generated by scanning RNA-binding-motifs of
various RBPs (collected from RBPDB and ATTRACT) across a transcript to look for
hits.As a result, the tool requires around 6.4GB to function.The data is
downloaded automatically on the first run of the tool, or can be downloaded
manually usingrnpfind-download.If the above memory footprint is too much for you to handle, consider using the
web tool avaiable athttps://rnpfind.comContributingAny suggestions / PR requests are welcome!
Package: rnumpy
rnumpyAn experiment in trying to define a core and cleaned-up NumPy API: RNumPyDon't use this just yet! It will be ready for production use soon, but the API
may still change in the near future.The main goals of this project:Provide a package with NumPy functions that contain the essence of NumPy for end users.
I.e. what would the NumPy API look like if we could remove functions and objects
from it and move things around without worrying about backwards compatibility.Answer the question: "what's theminimalset of functions needed to form a core of numpy?"(1) allows end users to usernumpyinstead ofnumpy, and thereby work with a much
easier to navigate package where they can be confident that the functions they use are
well-maintained and "best practice". In many cases, NumPy contains multiple ways of doing
things. Superceded functions are kept for backwards compatibility. Often users won't realize
that, and use a function that has a more modern alternative. Usingrnumpy, they won't
have to worry about that.Besides end users, (1) is also aimed at authors of NumPy-like libraries. It suggests
a subset of the full NumPy API that makes sense to support.(2) can form the basis of reimplementing other functions in terms of "core" functions.
An example may clarify this. To create an array filled with all the same values,
NumPy offersones,zeros,empty,full,ones_like,zeros_like,empty_like,full_likeandndarray.fill.  The fundamental building blocks areemptyandndarray.fill.
So one could reimplement, e.g.,onesas:def ones(...):
    return np.empty(...).fill(1)Such implementations in terms of core functions is useful forndarraysubclass authors,
people porting NumPy to other platforms (e.g. WebAssembly), and probably other groups of
developers too.See the docstring ofrnumpy/__init__.pyfor more details.