Saravanan666/pypi-org huggingface dataset:
Package: universions
universionsPython library to get the version of other toolsRead the documentationInstallwith pippipinstalluniversionswith condacondainstall-cconda-forgeuniversionsExamplesIn python code :>>>fromuniversions.javaimportget_java_version>>>get_java_version()Version(major=10,minor=0,patch=2,prerelease=None,build=None)>>>get_java_version()>(1,8)TrueIn the command line :>>>universionsjava11.0
>>>universionsnode-v12.6.0Languages and other tools supportedGitJavaNodeNpmPipPythonOpen an issue if you want more !
If you want to contribute read thecontributing guide.
Package: universities
Python package to search for basic university information. This packages
obtains information fromHipo/university-domains-list’s
database. It is fully compatible with Python 2.6 and up.InstallationYour preference should be to use PyPi:pip install universitiesSource and wheel distributions are available in the releases tab as
well.Usageimportuniversitiesuni=universities.API()# can specify encoding for use in Python 2canadian=uni.search(country="Canada")only_mit=uni.search(domain="mit.edu")all_data=uni.get_all()waterloo=uni.lucky(name="Waterloo")# As in "I'm feeling lucky"Available Functionsuniversities.searchsearches the entire database for universities
matching the specified critera. You may filter byname,domainorcountryas arguments tosearch. This returns a
list ofuniversities.models.Universityobjects.universities.luckyis an alias forsearchwhich only returns
the first result of the search. All the same parameters are
available, and a singleuniversities.models.Universityis
returned.universities.get_allreturns all of the entries in the database,
in the same format assearch. In fact, this is simply an alias
forsearchthat uses no arguments.Any query which reurns multiple objects will return a Generator.Modelsuniversities.models.Universityis the basic model returned in all
requests. It contains six fields:name: The name of the university.domains: A list of domain names the university uses (for
emails, etc).web_pages: A list of web pages associated with the university.country_code: The two-letter ISO-3166 country code where the
university is located.stateprov: The state or province the university is located.
This is usually not populated.country: The full country name where the university is
located.RequirementsThe only requirement isrequests.DevelopmentClone/fork the git repository.cdto the directory and install the requirements if necessary:pip install-rrequirements.txtEdit to your heart’s content!If you wish to contribute, push your changes to GitHub on your own
fork and make a pull request.Note: Any contributions should be made following the PEP8 standard.
Package: universityhack2018
Data Rhapsody UniversityHack2018Package for Data Rhapsody’s UniversityHack 2018 Challenge solution.Free software: MIT licenseDocumentation:https://universityhack2018.readthedocs.io.UsageInstall:pip install universityhack2018Example (easy peasy):from universityhack2018.prediction import Model
import pandas as pd

clients_df = pd.read_csv('/path/to/Dataset_Salesforce_Predictive_Modelling_TEST.txt')
clients = client_df_train.iloc[0:5, :]

model = Model(clients)
predictions = model.predict(as_df=True)

print(predictions.head())

# Output:
#   ID_Customer        PA_Est
# 0    TE000001  26926.541016
# 1    TE000002  15267.800781
# 2    TE000003  19499.935547
# 3    TE000004  12799.532227
# 4    TE000005  11262.253906FeaturesTODOCreditsThis package was created withCookiecutterand theaudreyr/cookiecutter-pypackageproject template.History0.1.0 (2018-03-11)First release on PyPI.
Package: university-scraper
A simple web scraping/crawler tool for university sites.pipinstalluniversity-scraperthen:fromuniversity_scraperimportavailable,init# Get list of available universitiesprint(available())# Give the abbreviation as a string, from the list of available universitiesscraper=init('USYD')scraper.programsscraper.units# Details can be retrieved for a certain program or unit using the respective kwargsscraper.program_detail(...)scraper.unit_detail(...)Scrapers available for:https://www.sydney.edu.au/ContributePart of the reason I want this open sourced is because if a university makes a design change, the scraper for it should be modified.If you spot a design change (or something else) that makes the scraper unable to work for a given site - please fire anissueASAP.If you are a programmer, PRs with fixes are warmly welcomed and acknowledged with a virtual :beer:If you want a scraper for a new university addedOpen anIssueproviding us the university name, as well as the direction on how to get the neccessary detailsUnit detailsProgram detailsYou are a developer and want to code the scraper on your own feel free to make a PR for us to review :)For Devs / ContributeAssuming you havepython3installed, navigate to the directory where you want this project to live in and drop these linesgitclonehttps://github.com/giulianocelani/university-scraper.git&&cduniversity-scraper&&pipinstallpipenv&&pipenvshell&&pipenvinstall&&python-munittest-vAcknowledgementProject was built with reference tohttps://github.com/hhursev/recipe-scrapers
Package: univoc
Towards Achieving Robust Universal Neural VocodingA PyTorch implementation ofTowards Achieving Robust Universal Neural Vocoding.
Audio samples can be foundhere.Fig 1:Architecture of the vocoder.Quick StartEnsure you have Python 3.6 and PyTorch 1.7 or greater installed. Then install the package with:pip install univocExample UsageimporttorchimportsoundfileassffromunivocimportVocoder# download pretrained weights (and optionally move to GPU)vocoder=Vocoder.from_pretrained("https://github.com/bshall/UniversalVocoding/releases/download/v0.2/univoc-ljspeech-7mtpaq.pt").cuda()# load log-Mel spectrogram from file or ttsmel=...# generate waveformwithtorch.no_grad():wav,sr=vocoder.generate(mel)# save outputsf.write("path/to/save.wav",wav,sr)Train from ScratchClone the repo:git clone https://github.com/bshall/UniversalVocoding
cd ./UniversalVocodingInstall requirements:pip install -r requirements.txtDownload and extract theLJ-Speech dataset:wget https://data.keithito.com/data/speech/LJSpeech-1.1.tar.bz2
tar -xvjf LJSpeech-1.1.tar.bz2Download the train splithereand extract it in the root directory of the repo.Extract Mel spectrograms and preprocess audio:python preprocess.py in_dir=path/to/LJSpeech-1.1 out_dir=datasets/LJSpeech-1.1Train the model:python train.py checkpoint_dir=ljspeech dataset_dir=datasets/LJSpeech-1.1Pretrained ModelsPretrained weights for the 10-bit LJ-Speech model are availablehere.Notable Differences from the PaperTrained on 16kHz audio from a single speaker. For an older version trained on 102 different speakers form theZeroSpeech 2019: TTS without TEnglish dataset clickhere.Uses an embedding layer instead of one-hot encoding.Acknowlegementshttps://github.com/fatchord/WaveRNN
Package: univoucher
Examplefromunivoucherimportmodels,localfromgetpassimportgetpassimportmathnetloc=input("Netloc: ")# <host>:<port>username=input("Username: ")password=getpass("Password: ")client:models.Client=local.Client(netloc,username,password)client.verify=False# Create one voucher# A guest can use it for 1000 minutes when redeemed# The voucher can be redeemed an unlimited amount of timesvouchers=client.fetch(amount=1,duration=1000,uses=math.inf)unlimited_uses_voucher:models.Voucher=next(vouchers)print(unlimited_uses_voucher.code)
Package: unix
This module aims to manage Unix-likes operating systems. It manage both local or
remote host in the same way. Commands can be executed interactively or not, and
the result is a list of three elements:the status of the command (boolean based on return code)the standard output (stdout)the error output (stderr)For executed commands on localhost, the module used issubprocessand for
remotes hosts, the module used isparamiko.Code is available on Github (http://github.com/fmenabe/python-unix)Releases notes1.0 (2015-07-02)Manage localhost (subprocess) and remote hosts (SSH; paramiko) uniformly.Use controls for managing some behaviour (decoding outputs, locale, …).Implements basic commands for manipulating files and directories (open,copy,mkdir, …).Organize commands in objects accessible via properties:path API (exists,isfile, …)remote API for copying file using from one host to anotherusers and groups APIManage Linux hosts:chrootautodetecting the distributionmanage arch, debian, ubuntu, redhat, centos, …0.1 (2015-03-05)Initial version.
Package: unixaccount
Python module to manipulate unix system accounts by calling standard unix
commands user{add,mod,del} which do the actual system files manipulation.Usessudoto run the commands if not root (EUID not 0).LocationsUnix Account packages are available from Cheese shop (PyPI)
athttps://pypi.python.org/pypi/unixaccountTheproject pageis hosted on Github.If you’ve never worked withgitor contributed to a project on Github,
there is aquick start guide.If you find something wrong or know of a missing feature, pleasecreate an issueon the project
page. If you find that inconvenient or have some security concerns, you could
also drop me a line at <devel@beli.sk>.Installpip install unixaccountContentsCLASSESexceptions.Exception(exceptions.BaseException)UnixAccountErrorAlreadyExistsBusyNotFoundFUNCTIONScreate_user(username, group=None, homedir=None, password=None, mkhome=False, shell=None)
    Create a new user account

delete_user(username)
    Delete user account.

modify_user(username, group=None, homedir=None, password=None, mkhome=False, shell=None)
    Modify existing user account.

get_gid(groupname)
    Return numeric group ID for given group name or raise NotFound exception.

get_uid(username)
    Return numeric user ID for given username or raise NotFound exception.

get_username(uid)
    Return user name for given numeric user ID or raise NotFound exceptionLicenseCopyright 2014 Michal Belica <devel@beli.sk>Unix Account 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.

Unix Account is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with Unix Account.  If not, see < http://www.gnu.org/licenses/ >.
Package: unix-ar
unix_arThis packages allows the reading and writing ofAR archive files.It is inspired by thetarfileandzipfilethat are part of Python's standard library (unfortunately the namearfilewas taken on PyPI).FeaturesThe package provides aArFilepartially implementing the interface oftarfile.TarFile>>>importunix_ar>>>importtarfile>>>ar_file=unix_ar.open('mypackage.deb')>>>tarball=ar_file.open('data.tar.gz/')# default interest location on .deb files>>>tar_file=tarfile.open(fileobj=tarball)# handles gz decompression internally>>>tar_file.extractfile('usr/local/mypackage/bin/mybinarycontent.sh')CreditsThis package was created by Remi Rampin, that does not want to maintain it anymore.
Package: unix-at
This tiny library allows you to talk to theat(1)system, available on most UNIX machines, to schedule jobs to be run later.Usingat(1)can be much more light-weight than running a full-fledged job-processing system such asCeleryif you are running very few jobs, however the performance will be much lower if you are running a considerable amount of tasks.Exampleimportunix_atjob=unix_at.submit_shell_job(['touch','/some/file'])unix_at.cancel_job(job)job=unix_at.submit_python_job(os.mkdir,'now + 1 hour','/some/dir')
Package: unix-cred
unix_credA Python library that simplifies reading peer credentials from Unix domain sockets.Installation$ pip install unix-credExamples>>>importos>>>importsocket>>>importunix_cred>>>server=socket.socket(socket.AF_UNIX,socket.SOCK_STREAM)>>>server.bind("/tmp/unix_cred-test")>>>server.listen(1)>>>cli=socket.socket(socket.AF_UNIX,socket.SOCK_STREAM)>>>cli.connect("/tmp/unix_cred-test")>>>server_cli=server.accept()[0]>>># Check the peer credentials on each end against the current process's>>>assertunix_cred.get_peer_uid_gid(cli)==(os.geteuid(),os.getegid())>>>assertunix_cred.get_peer_uid_gid(server_cli)==(os.geteuid(),os.getegid())>>># Not supported on all systems>>># On some systems this function is not defined; on certain versions of other systems>>># it may return None for the PID>>>assertunix_cred.get_peer_pid_uid_gid(cli)==(os.getpid(),os.geteuid(),os.getegid())>>>assertunix_cred.get_peer_pid_uid_gid(server_cli)==(os.getpid(),os.geteuid(),os.getegid())
Package: unix_daemon
unix_daemon is a python module emulating BSD daemon(3).This module provides a function named daemon.If this function is called, the process become a daemon and start to runbackground.RequirementsPython 2.6 or later, or Python 3.xUnix or Linux platform.TestPython 2.6.9Python 2.7.8Python 3.1.5Python 3.2.5Python 3.3.5Python 3.4.1SetupInstall using pip$ sudo pip install unix_daemonInstall from git.$ git clone https://github.com/wbcchsyn/unix_daemon.git
$ cd unix_daemon
$ sudo python setup.py installUsageunix_daemon.daemon(nochdir=False, noclose=False)Make process daemon and start to run in the background.ArgumentsIf argument 1 ‘nochdir’ is False, the process changes the callingprocess’s current working directory to the root directory (“/”);otherwise, the current working directory is left unchanged.The default value of the nochdir is False.If argument 2 ‘noclose’ is False, this function close file descriptors 0,1 and 2 and redirect them to /dev/null. Even if some of them have beenclosed, this function open these file descriptors and redirect to/dev/null if noclose is False.The defult value of noclose is False.Return Valuedaemon returns the pid of new process.NoteThis function calls os.fork() internally to detach tty safely.Be careful to call this function when two or more than two python threadsare running.Normary, file descriptors 0, 1 and 2 are correspond to stdin, stdout andstderr. However, even if any of these file discriptors refer to somethingelse, they will still be closed when argument ‘noclose’ is False.It is a good idea to call this function before creating any threads andbefore opening any files or sockets.ExampleCall unix_daemon.daemon(), then the process starts to run in the backgrond.import unix_daemon
import os

print('pid: %s\n' % os.getpid())

pid = unix_daemon.daemon()
with open('/tmp/foo', 'a') as f:
    print('pid: %s\n' % os.getpid())
    f.write('new pid: %s\n' % pid)You can see the process id changes and the 2nd print is not displayed.DevelopmentInstall requirements to developing copy pre-commit hook from repository.$ git clone https://github.com/wbcchsyn/unix_daemon.git
$ cd unix_daemon
$ pip install -r dev_utils/requirements.txt
$ ln -s ../../dev_utils/pre-commit .git/hooks/pre-commit
Package: unix-elf
elf PackageParse Executable-Linking Files (Unix ELF binary files). Seehttps://en.wikipedia.org/wiki/Executable_and_Linkable_Formatfor general reference.Script Usageelf.py <input ELF filename>Features32- and 64-bit ELF parsingELF class for convenient abstractionElfBytes class for byte-level operationsSummary inspectionDynamic linking dependency lookup
Package: unix-fs-exporter
This code has been transpiled fromipfs-unixfs-exporterand has minimal changes.UsageDAG-PB, Raw, DAG-CBOR, and Identity codecs are supported.>>> from unix_fs_exporter import UnixFSFile, UnixFSDirectory, RawNode, ObjectNode, IdentityNodeGiven a block store and a root cid, decode the underlying data.>>> from unix_fs_exporter import RawNode, export, BlockStore
>>> from multiformats import CID, multicodec, multihash
...
>>> class SomeBlockStore(BlockStore):
...     def __init__(self):
...         self.mapping = dict()
...
...     async def get_block(self, cid):
...         return self.mapping[cid.digest]
...
>>> data = b'some data'
>>> mh = multihash.get('sha2-256').digest(data)
>>> cid = CID('base32', 1, 'raw', mh)
>>> block_store = SomeBlockStore()
>>> block_store.mapping[cid.digest] = data
...
>>> async def test():
...     result = await export(cid, block_store)
...     assert isinstance(result, RawNode)
...
...     async for chunk in result.content:
...         print(chunk)
...
>>> asyncio.run(test())
b'some data'Recursively iterate through a directory.>>> from unix_fs_exporter import recursive_export, UnixFSFile
>>> # Creation of the blockstore is an exercise left to the reader
>>> async def test():
...     entries = recursive_export('bafybeifpaez32hlrz5tmr7scndxtjgw3auuloyuyxblynqmjw5saapewmu', block_store)
...     async for entry in entries:
...         assert isinstance(entry, UnixFSFile)
...         async for chunk in entry.content:
...             assert isinstance(chunk, bytes)
>>> asyncio.run(test())
Package: unixgpt
🗣️ unixgptunixgpt is a powerful bridge between natural language and UNIX commands.A valid OpenAI API Key is required to run unixgpt (you can get one here:https://openai.com/blog/openai-api)exportOPENAI_API_KEY="enter key here"The latest version ofunixgptcan be installed from PyPI:pipinstallunixgptTo upgrade to the latest version:pipinstall--upgradeunixgptBuilding LocallyDockerBuild the Docker imagedockerbuild-tunixgpt-cli.Create and run the Docker container (with a valid OpenAI API Key)dockerrun-eOPENAI_API_KEYunixgpt-cliNote:Input can be edited in DockerfilepipBuild via pip (from source code)pipinstall.Run via pipunixgpt-i"enter input here"FeaturesConversion:Seamlessly transform natural language queries into their corresponding UNIX commands.Command Options:After generating a command, enjoy the following flexibility:Execute:Execute the generated UNIX command directly.Save:Store frequently used commands locally for swift and convenient access.Copy:Copy the generated command to the clipboard, simplifying pasting and use in your terminal.Reusability:It's not just about storing commands; it's a versatile tool for saving and editing custom commands via natural language, ensuring your workflow remains flexible and efficient.ExamplesConversionInput: unixgpt -i "I want to see any uses of the 'git commit' command in my history"

Output: history | grep "git commit"Input: unixgpt -i "Use the Dockerfile in the cwd to create an image called project-image"

Output: docker build -t project-image .Input: unixgpt --input "Show me the current processes running on port 8000"

Output: lsof -i :8000SaveInput: unixgpt -s "git commit && git push"

Output: "Added to UnixGPT local library"Input: unixgpt --save 1599

Output: "Added to UnixGPT local library"FetchInput: unixgpt -f "command that commits and pushes via Git"

Output: git commit && git pushInput: unixgpt --fetch 23

Output: "Returns command in UnixGPT local library with ID:23"
Package: unixlog
A simple unix style logging in color format. Light weight library for Color formating.FeaturesInclude warning, error, info, debug, success, traceLight weight importunix style formatInstallationpip install unixlogExamples>>> from unixlog import error, warning, info, success, trace, debug>>> print(error("This error text"))[  ERROR  ] This error text>>> error("This error text")'\x1b[91m[  ERROR  ] This error text\x1b[0m'
Package: unixpackage
UnixPackage is a UNIX independent way of installing packages. Specify the
Ubuntu package name (e.g. libpq-dev), and it will install the equivalent
on your system (e.g. postgresql-libs on Arch).InstallEither:$ pip install unixpackageOr:$ sudo pip install unixpackageunixpackage is entirely self contained and has no dependencies. It is
safe to use sudo pip install with it.Simple UsageRun:$ unixpackage install libpq-devOn Arch this will run:$ sudo pacman -S postgresql-libsOn Debian and Ubuntu:$ sudo apt-get install libpq-devOn Mac OS X:$ brew install postgresqlOn Red Hat/CentOS/Fedora:$ sudo yum install postgresql-develOther usageYou can also just print the command to install rather than running it:$ unixpackage show libpq-dev libssl-dev
sudo pacman -S postgresql-libs opensslOr just check to see if it is installed:$ unixpackage check libpq-dev openssl
InstalledOr install using “polite mode”:$ unixpackage install libpq-dev --polite
The following command must be run to continue. I am attempting to run it now:


       sudo apt-get install -y libpq-dev


You can also run this command in another window and then hit Ctrl-C to continue.

[sudo] password for user:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Suggested packages:
  postgresql-doc-9.3
The following NEW packages will be installed:
  libpq-dev
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B/140 kB of archives.
After this operation, 741 kB of additional disk space will be used.
Selecting previously unselected package libpq-dev.
(Reading database ... 231796 files and directories currently installed.)
Preparing to unpack .../libpq-dev_9.3.9-0ubuntu0.14.04_amd64.deb ...
Unpacking libpq-dev (9.3.9-0ubuntu0.14.04) ...
Processing triggers for man-db (2.6.7.1-1ubuntu1) ...
Setting up libpq-dev (9.3.9-0ubuntu0.14.04) ...
Post-install package check for libpq-dev successful!Python APIThere is also a python API for the above commands:importunixpackageimportsys# Install package if not already installedunixpackage.install(["libpq-dev"])# Install package if not already installed (in polite mode)unixpackage.install(["libpq-dev"],polite=True)# Check if packages are installedifunixpackage.packages_installed(["libpq-dev"]):sys.stdout.write("libpq-dev installed")Package LibraryPackage names and their equivalents are downloaded fromhttps://github.com/unixpackage/unixpackage.github.iovia the generated website:Example :http://unixpackage.github.io/libpq-dev.jsonThese files are cached in the ~/.unixpackage directory.To add more packages you want to be installable in a UNIX-independent way,
fork and submit a pull request to this repository:http://github.com/unixpackage/unixpackage.github.ioWant to help?See CONTRIBUTING.rst
Package: unixpath
unixpathunix-style path processing functionsWhy?My goal was to provideposixpathpath processing functions in pure Python (e.g.normpath,join,split, etc)minusany functions that rely on any kind of "filesystem" concept (stat, etc).Basically, this is a "minimum viable unix path processing framework." Path processing functions are useful for e.g. ML libraries that want to use unix-style paths to refer to model variables.(Honestlyunixpathis kind of pointless. Its functions are copy-pasted fromposixpath, so why not justimport posixpathand not worry about the extra dependency onunixpath? Answer: because I was curious how Python implemented their unix path processing functions, so I made this library as a learning exercise.)Installpython3 -m pip install -U unixpathUsageimportunixpathunixpath.join('a','b')# 'a/b'unixpath.join('a','b','..','c')# 'a/b/../c'unixpath.normpath('a/b/../c')# 'a/c'LicenseMITContactA library byShawn Presser. If you found it useful, please considerjoining my patreon!My Twitter DMs are always open; you shouldsend me one! It's the best way to reach me, and I'm always happy to hear from you.Twitter:@theshawwnPatreon:https://www.patreon.com/shawwnHN:sillysaurusxWebsite:shawwn.com