Saravanan666/pypi-org huggingface dataset:
Package: pyfakers
# py-fake-rsA fake data generator (a faker) for Python, extended with Rust.This module contains bindings to [fake-rs](https//github.com/cksac/fake-rs),a fake-data generator written in [Rust](https//www.rust-lang.org/).The reason for this library is performance. When you're generating large amountsof fake data, this library will serve you well.## Example API```pythonfrom pyfakers import Nameprint(Name.first_name())print(Name.last_name())```## InstallationInstall with pip, wheel files are provided for Linux and macOSTHIS WONT WORK YET (BUT WILL SHORTLY)    pip install pyfakers## Building from sourceInstall libffi, python3 headers, setuptools and wheel. The following command will install these on Ubuntuapt-get install libffi-dev python3-dev python3-setuptools python3-wheelCheck out the repositorygit clone git@github.comdowwie/pyfakers.gitcd pyfakersIn order to compile the Rust code, you'll need to have Rust nightly toolchain installed and enabled.Use rustup to set this up, find installation instructions for rustup at https//www.rustup.rs/To use Rust nightly, run the following commands (from the project root)rustup update nightlyrustup override add nightlyInstall the ``pipenv`` utility from pypipip install pipenvInstall dependencies (from the project root)pipenv installLaunch a virtual environment (from the project root)pipenv shellNow you can build the packagepython3 setup.py bdist_wheelInstall the wheelpip install dist/<wheel file name>## Full API```pythonfrom pyfakers import Name, Internet, Company, Address, PhoneNumberprint(Name.first_name())print(Name.last_name())print(Name.full_name())print(Name.title_descriptor())print(Name.title_level())print(Name.title_job())print(Name.title())print(Internet.free_email_provider())print(Internet.domain_suffix())print(Internet.user_name())print(Internet.free_email())print(Internet.safe_email())print(Company.suffix())print(Company.name())print(Company.buzzword())print(Company.catch_phrase())print(Company.bs())print(Company.profession())print(Company.industry())print(Address.time_zone())print(Address.city_prefix())print(Address.city_suffix())print(Address.street_suffix())print(Address.state())print(Address.state_abbr())print(Address.city())print(Address.street_name())print(Address.building_number())print(Address.street_address())print(Address.secondary_address())print(Address.postal_code())print(Address.latitude())print(Address.longitude())print(PhoneNumber.phone_number())```
Package: pyfallback
pyfallbackInstallpip install fallbackUsagefrompyfallbackimportFallbackjson={'attr-1':'value-1',}json=Fallback(json,fallback="default")# fallbackjson["attr-1"].get()# "value1"json["attr-2"].get()# "default"# chainingjson["attr-1"].split('-')[0].get()# "value"# see tests/test_fallback.py for more exampleContributingJust submit a pull request :DNote: this project uses poetry and pyenv
Package: pyfancylogger
FancyLoggerWith this library, Log in style!This library is still under development, so we appreciate if you help us improve it on the GitHub!Having an issue?You can always find someone on our discord server here:https://discord.agmstudio.xyz/WikiThe official wiki of this library is now available at GitHubhttps://git.agmstudio.xyz/FancyLogger/wikiHow to installTo install just use following commandpipinstallPyFancyLoggerThis library will have dev/beta builds on the GitHub, to install them you can usepipinstall--upgradegit+https://github.com/AGM-Studio/FancyLogger.gitExampleThis is based on file below:https://github.com/AGM-Studio/FancyLogger/blob/master/test.pyfromFancyLoggerimportFancyLogger,FancyFormatter,Formatslogger=FancyLogger('Test',FancyFormatter(Formats.detailed))logger.setLevel(0)if__name__=='__main__':logger.debug('This is a debug')logger.info('This is an info')logger.warning('This is a warning')try:int('Not an int')exceptExceptionase:logger.error(f'This is an error for{e}')try:int('Not an int either')exceptExceptionase:logger.exception(f'This is an error for{e}')logger.critical('IMPORTANT: THIS IS A CRITICAL MESSAGE')print('\n----- Testing Sub loggers -----\n')logger.sub('Sub 1').info('A sub to the parent')logger.sub('Sub 2').info('Another sub logger!')logger.sub('Sub 1').info('Previous one is still available!')logger.sub('Sub 1').sub('Sub in Sub').critical('EVEN SUBS CAN HAVE SUBS!')Extras & Features...
Package: pyfancyplots
## PyFancyPlotsDoes your advisor enjoy fancy plots?  Is his name Luke?  Then this plotting script is for you!## OverviewPython plotting tool with default options to make plots easy to read.  Thisscript uses matplotlib and Seaborn.## Testimonials"That plot looks great." -- Luke## Plotting ExamplesImport `plot.py' for default plotting parameters to be set.  A few importantmethods:- The method add_anchored_legend will add a multicolumn legend above yourplot.  Examples of this are in the plots below.- The method save_plot will save your figure with settings preferred by Luke- The methods stacked_barblot and partially_stacked_barplot create Seabornbarplots by stacking your data (or some of it for you).## Example Line PlotDefault and Luke-recommended settings are displayed in a simple line and scatterplot below.  Make sure to call add_luke_options() and save_plot(...) to addthese settings to your figures.![](figures/line_plot.png)## Standard and Stacked BarPlotsThe standard and stacked bar plots (available in methods barplot(...) andstacked_barplot(...)) take a typical list of x_data and either asingle list or list of lists for y_data.  If y_data is a list of lists, a listof corresponding labels is also required.  Each list of y_data will be plottedat all x_data positions, as shown below.![](figures/barplot.png)![](figures/stacked_barplot.png)## Partially Stacked BarPlotThe previous standard and stacked barplots can also be combined with methodpartially_stacked_barplot(...).  This method takes x_data as usual, and then alist of y_data.  The list for y_data contains both y_data lists and lists oflists.  E.g. y_data = [y0, y1, [y2, y3], y4, [y5, y6]] will plot y0, y1, and y4as normal barplots, while y3 will be stacked on top of y2, and y6 will also bestacked on y5.  Correpsonding labels should be in the same format as y_data.![](figures/partially_stacked_barplot.png)
Package: pyfanfou
## 饭否数据备份工具备份指定用户的全部饭否消息和相册照片，可选备份好友资料列表，备份数据格式为SQLite/Html/Markdown/Txt四种，推荐保存Html格式### 安装和使用#### Windows从[百度云](http://pan.baidu.com/s/1o6GcH9S#path=%252FPublic2)或[Github](https://github.com/mcxiaoke/pyfanfou/releases/latest)下载，解压运行 **pyfanfou.exe** 即可。### 所有系统```// pip安装pip install pyfanfou// 使用命令行fanfoubackup// 打开GUI界面fanfoubackupui```### 命令行使用```fanfoubackup [-h] [-u USERNAME] [-p PASSWORD] [-t TARGET] [-s] [-i][-o OUTPUT]-h, --help   显示帮助信息-u USERNAME, --username USERNAME 你的饭否帐号-p PASSWORD, --password PASSWORD 你的饭否密码-t TARGET, --target TARGET 要备份的用户ID，默认是登录帐号-s , --include-user 是否备份好友资料列表，默认否-i , --include-photo 是否备份全部相册照片，默认是-o OUTPUT, --output OUTPUT 备份数据存放目录，默认是当前目录下的output目录```## 截图#### Windows截图一![ui1](images/win1.png)#### Windows截图二![ui1](images/win2.png)#### Mac OS X截图一![ui1](images/backupui1.png)#### Mac OS X截图二![ui2](images/backupui2.png)
Package: pyfanotify
pyfanotifyPython wrapper for Linux fanotify.Seefanotify manpagefor more details.To detail see thedocumentationIMPORTANT!fanotifyrequires execution fromROOT!RequirementsPython 3.6+InstallingUsing PIP$pipinstallpyfanotifyFrom sources$gitclonehttps://github.com/baskiton/pyfanotify.git
$cdpyfanotify
$pythonsetup.pyinstallUsageSeeexamples
Package: pyfanuc
pyfanucpyfanuc is a free and open-source library allowing to connect to a Fanuc controller and to read user defined macro variables and axis related data, like positions, speeds and loads.For detailed information about the inputs for "FocasController.read_axis()", visit:https://www.inventcom.net/fanuc-focas-library/position/cnc_rdaxisdata. For detailed information about the inputs for for "FocasController.read_macro()", visit: "https://www.inventcom.net/fanuc-focas-library/ncdata/cnc_rdmacror2".Installationpip3 install pyfanucIn case of an error message: if "fwlipy" is included, then download it manually:pip3 install -e git+https://github.com/tonejca/pyfwlib.git@pyfanucable#egg=fwlipyUsagefrom pyfanuc import FocasController

controller = FocasController("127.0.0.1")
with controller:
    axis_position = controller.read_axis(1, 0)
    macro_100 = controller.read_macro(100)
Package: pyfanyi
# PyfanyiTranslate every string. It is very good.# Requirements
- python 3.8
- requests==2.25.1
# Installation
## Using pip via pypi:`cmd pip install pyfanyi-ihttps://pypi.org/project/`## Update:`cmd pip install-Upyfanyi-ihttps://pypi.org/project/`# Usage`python from pyfanyi import Text, Language `# Test
## In CMD`cmd python-mpyfanyi "stripe" `## In Python`python from pyfanyi import Text, Language text =Text('stripe')language =Language('zh-CNS')text.set_source_language('en')result =text.fanyi(language)[0]print(result) `
Package: pyf.api
Python Package Filter APIThe Python Package Filter API (pyf.api)  helps you easily identify and
evaluate python packages using classifiers, stats etc.QuickstartFor detailed installation instructions, read thedocs.Install elasticsearchConfigure elasticsearch,
especially set the path to the data directory.Start elasticsearchAPILicenseThe code is open-source and licensed under the Apache License 2.0.Credits@jensens@veit@guziel@pypaChangelog1.0.0 (unreleased)Nothing changed yet.
Package: pyfar
The python package for acoustics research (pyfar) offers classes to store
audio data, filters, coordinates, and orientations. It also contains common
functions for digital audio signal processing.Getting StartedCheck out theexamples notebookfor a tour of the most important pyfar
functionality andread the docsfor the complete documentation. Packages
related to pyfar are listed atpyfar.org.InstallationUse pip to install pyfar$pipinstallpyfar(Requires Python 3.8 or higher)Audio file reading/writing is supported throughSoundFile, which is based onlibsndfile. On Windows and OS X, it will be installed automatically. On Linux, you need to install libsndfile using your distribution’s package manager, for examplesudoapt-getinstall libsndfile1.ContributingRefer to thecontribution guidelinesfor more information.
Package: pyfarm.agent
Core module containing code to run PyFarm’s agent. This will allow a remote
host to:Inform the master about itselfRequest, receive and execute work via job typesTrack and control individual processesMeasure and limit system resource usagePython Version SupportThis library supports Python 2.6 and Python 2.7 only for the moment.  Coding
practices have been geared towards supporting Python 3 when the underlying
library, Twisted, is ported to Python 3.DocumentationThe documentation for this this library is hosted onRead The Docs.
It’s generated directly from this library using sphinx (setup may vary depending
on platform):virtualenv env
. env/bin/activate
pip install sphinx nose
pip install -e . --egg
make -C docs htmlTestingTests are run onTravisfor
every commit.  They can also be run locally too usingtrial.  Currently,
the agent tests require:Access tohttps://httpbin.pyfarm.netfor HTTP client testing.  This is
configurable however and could be pointed to an internal domain
using theagent_unittestconfiguration variable.Thepyfarm.mastermodule to run the API.  So all the setup steps
that apply to the master will apply here as well.  This includes the
requirement to run Redis, RabbitMQ or another backend that supportscelery.Linux or OS X since the master is designed to operate on these
platforms.  The below setup may work on Windows with a few configuration
tweaks too.Newer tests are being designed to be lighter weight so eventually most of the
above may no longer be required for testing.  For now however these are the
basic steps to run the tests and are based on the steps in.travis.yml:virtualenv env
. env/bin/activate
pip install pyfarm.master uwsgi mock
pyfarm-tables
uwsgi resources/uwsgi.ini
pip install -e . --egg
trial tests  # in a new shell with the same virtualenv
Package: pyfarm.core
This library contains core modules, classes, and data types which are
used by other parts of the PyFarm project.  This package is contains:A configuration module for loading and merging configuration
files from disk.Enumerations of basic system information such as interpreter information,
Python types, operating systems and other basic information that can
be shared across the project.Logger setup and handlingMiscellaneous utilitiesPython Version SupportThis library supports Python 2.6+ and 3.2+ in one code base.  Python 2.5
and lower is not supported due to significant syntax, library and other
differences.  This library must support the range of Python versions
thatpython.masterandpyfarm.agentsupports.DocumentationThe documentation for this this library is hosted onRead The Docs.
It’s generated directly from this library using sphinx (setup may vary depending
on platform):virtualenv env
. env/bin/activate
pip install sphinx nose
pip install -e . --egg
make -C docs htmlTestingTests are run onTravisfor
every commit.  They can also be run locally too (setup may vary depending
on platform):virtualenv env
. env/bin/activate
pip install nose
pip install -e . --egg
nosetests tests/
Package: pyfarmer
PyFarmerIntroductionA farmer for yourDestructive FarmYou can read the documentation atrikyiso01.github.io/pyfarmerCode Samplesfromhttpximportpostfrompyfarmerimportfarm,print_exceptiondefmain(ip:str):forflag_idin["a","b","c"]:try:r=post(f"http://{ip}:5000/api/products/{flag_id}/download?a=/api/register")flag=r.textyieldflagexcept:print_exception()if__name__=="__main__":farm(main)InstallationInstall locally with:pipinstallpyfarmer
Package: pyfarmhash
python-farmhashGoogle's FarmHash binding for PythonOverviewThis package provides bindings for theGoogle's FarmHash.Code specific to this project is covered byThe MIT LicenseInstallUpdate:Windows binary wheel uploaded to pypiCurrently, clone the repo and:pip(Linux & Windows):$sudopipinstallpyfarmhashFrom Source:$cdpython-farmhash$sudopythonsetup.pyInstallBuild on Windows:Install Microsoft Visual C++ CompilerInstall miniconda for Python$cdpython-farmhash
$sudopythonsetup.pyinstallUsageimport farmhash  
print farmhash.hash64('abc')  
2640714258260161385  

For more details, use ipython:
In [1]: import farmhash 

In [2]: farmhash.hash64withseed?  
Type:       builtin_function_or_method  
String Form:<built-in function hash64withseed>  
Docstring:  
Hash function for a string.  For convenience, a 64-bit seed is also hashed into the result.  
example: print farmhash.hash64withseed('abc', 12345)  
13914286602242141520L
Package: pyfarm.master
Sub-library which contains the code necessary to run an instance of the master
server.  The primary purposes of the master including serving a REST API,
running the scheduler and serving the web interface.Python Version SupportThis library supports Python 2.7 and Python 3.3+ in one code base.  Python 2.6
and lower is not supported due to syntax differences and support for 2.6 in
external libraries.DocumentationThe documentation for this this library is hosted onRead The Docs.
It’s generated directly from this library using sphinx (setup may vary depending
on platform):virtualenv env
. env/bin/activate
pip install sphinx sphinxcontrib-httpdomain
pip install -e . --egg
make -C docs htmlTestingNoteA broker is required for most of the tests due to pyfarm.master’s dependency
on celery.  Redis is recommended because it’s the default, least
persistent and easiest to setup.General TestingTests are run onTravisfor
every commit.  They can also be run locally too (setup may vary depending
on platform):virtualenv env
. env/bin/activate
pip install nose
pip install -e . --egg
nosetests tests/Testing Specific DatabasesBy default tests are run against sqlite.  While this is sufficient in many
cases it’s generally best to test against the database type you wish to use.
Setup wise the only difference will be in the call tonosetests:PYFARM_DATABASE_URI="dialect+driver://username:password@host:port/database" nosetests tests/For more information on database URIs seesqlalchemy’s documentationor theTravis configuration.
Package: pyfarmsay
PyfarmsayExpanding on the existing package,pycowsay, pyfarmsay does not only feature a talking cow, but an entire talking farm! Our beautiful farm features a talking cow, pig, chicken, dog, penguin, and sheep.InstallTo install our package on your local machine, run the following command:pip install pyfarmsayTo install into a virtual environment, make sure you install pipenv by running the following:pip install pipenvand then use the following command to install our package into an isolated virtual environment.pipenv install pyfarmsayThis will create a virtual environment, which you can access by runningpipenv shellRunOnce pyfarmsay is installed on your machine (or virtual environment), you can use it from the command line or from within a python file.From the Command LineTo run the package from the command line, all you have to do is invoke the package name, followed by the animal of your choice and your desired message:pyfarmsay [ANIMAL] [MESSAGE]For example,pyfarmsay cow i say moowill output-----------
< i say moo >
 -----------
    \
     \
      ^__^
      (oo)\_______
      (__)\       )\/\
          ||----w |
          ||     ||Import into a python moduleUse the following import statement at the very top of your.pyfile to use the functions from within your module.from pyfarmsay import pyfarmsayorfrom pyfarmsay.pyfarmsay import [function name]Build and Test the packageTo build and test our package for yourself, make sure to havepipenvinstalled.Install our package into a virtual environment following the instructions above.Run:pipenv shellInstallbuildinto the virtual
environment using:pip install buildBuild the project using:python3 -m buildTo test, install pytest from the virtual environment shell using:pip install pytestRun unit tests using:python3 -m pytest tests/testPackage functionsPyfarmsay comes with the following 7 main functions, each accepting a message argument:
Use the following command to run the program:python3 ex_2.py [ANIMAL] [MESSAGE]cowsay(usecowfor the animal argument if you are invoking the function from the command line)pigsay(usepigfor the animal argument if you are invoking the function from the command line)chickensay(usechickenfor the animal argument if you are invoking the function from the command line)sheepsay(usesheepfor the animal argument if you are invoking the function from the command line)penguinsay(usepenguinfor the animal argument if you are invoking the function from the command line)dogsay(usedogfor the animal argument if you are invoking the function from the command line)farmsay(usefarmfor the animal argument if you are invoking the function from the command line)Our animals can only repeat what you tell them to say, so if no message is given, each animal will call out their native animal sound.AuthorsSarah Al-TowaityHarrison DouglassBrandon ChaoEduarda MartiniMichelle Lu
Package: pyfas
PyfasPyfas is a python toolbox for flow assurance engineers.WrappersAt this moment in time the toolbox contains wrappers for:OLGAUnisim DesignGAPPipesim (via OpenLink, for all the versions <= 2012.4)Olgais the standard de facto for the dynamic simulations of multiphase
systems (single pipelines or complex network) in the oil and gas indistry. The
simulator has text input and output files; with pyfas you can expose Olga
results to python (both trends and profiles) or dump all the results to excel/csv
for your post-precessing.UnisimDesignis mainly a process simulator but can be used also to simulate
pipelines or networks in particular providing some external components.
Differently from Olga Unisim (unfortunately) does not use text input or
output files, the only way to communicate with the software is via a COM interface
using pywin32.  Pyfas does not pretend to exposes all the possible
functionalities of Unisim, only a very limited subset is available at the
moment.PipeSimis a steady state simulator for both single branches or networksUtilitiesTab files processingSurge volume calculationPIRead functionalityTab filesare look-up tables with specific thermodynamic properties at
given pressure and temperature intervals used for flash calculations by dynamic
simulators. These files are generated by thermodynamic simulators (like
PTVTsim) and it is good practice to have a look on this informationbeforea dynamic simulation. With pyfas it is possible to generate 3d plots of all the
properties and examine more in detail critical ones.Thesurge volume calculationutility returns the surge volume given a drain
rate and a liquid flowrate time series. Not more than a simple discrete
integration.WithPIReadit is possible to retrieve PI values from a PI server.A live demo should be available here below (no installation required)Installationpip install pyfasExamples and documentation
Package: pyFASST
FASST (Flexible Audio Source Separation Toolbox) classsubclass it to obtain your own flavoured source separation model!You can find more about the technique and how to use this module in the
provided documentation indoc/(using the python package)Adapted from the Matlab toolbox available at:http://bass-db.gforge.inria.fr/fasst/Jean-Louis Durrieu, EPFL-STI-IEL-LTS5jean DASH louis AT durrieu DOT ch2012-2013http://www.durrieu.ch
Package: py-fastapi-logging
py-fastapi-loggingENV-переменные для управления логамиУровень логов. debug - для площадок отладки, info - для PROMLOG_LEVEL=infoФормат логов: SIMPLE (обычный) или JSON (JSON-STDOUT - лог в формате json в поток stdout)LOG_FORMAT=SIMPLEПапка, в которой будут лежать логиLOG_DIR=/var/log/Название файла логаLOG_FILENAME=production.logДобавление переменных в лог (JSON-формат) из переменных окруженияLOG_ENV_EXTRA="field1:ENV_VAR_NAME_1,field2:ENV_VAR_NAME_2"Интеграция в FastAPI приложениеfromfastapiimportFastAPIfrompy_fastapi_logging.middlewares.loggingimportLoggingMiddlewareapp=FastAPI()app.add_middleware(LoggingMiddleware,app_name='my_app_name')Использование логгера в приложениях не на FastAPIimportloggingfrompy_fastapi_logging.config.configimportinit_loggerinit_logger(app_name='my_app_name')logger=logging.getLogger()
Package: pyfastblur
pyfastblurSmall Python library with a single purpose to apply fast blur to PNG images (libpng backend)InstallWindows:python -m pip install pyfastblurLinux:git clone https://github.com/sertraline/pyfastblur && cd pyfastblur
python3 setup.py build bdist_wheel
cd dist && python3 -m pip install ./pyfastblur*.whlUsage# example 1importpyfastblurresult=pyfastblur.blur("path/to/file.png",radius=24)# example 2result=pyfastblur.blur("path/to/file.png",radius=24,enable_gaussian=True)# enable_gaussian processes the image with gaussian blur instead of box blur (slower)# example 3fromioimportBytesIO# read image into memory objectobj=BytesIO()withopen("test.png",'rb')asf:obj.write(f.read())# rewindobj.seek(0)result=pyfastblur.blur(obj,radius=24)# write result to filewithopen("output.png",'wb')asf:f.write(result.read())SpeedSample image:link(3.55MB)Code:importpyfastblurimporttimefromioimportBytesIOruns=6average=0.0foriinrange(runs):start=time.time()# read image into memory objectobj=BytesIO()withopen("test.png",'rb')asf:obj.write(f.read())# rewindobj.seek(0)# output: BytesIO objectout=pyfastblur.blur(obj,radius=64)# write to filewithopen("output.png",'wb')asf:f.write(out.read())average+=(time.time()-start)average=average/runsprint("Average runtime:%sseconds"%str(average))Result (Windows):Average runtime: 0.5009152094523112 seconds