Saravanan666/pypi-org huggingface dataset:
Package: fast-unit
Fast Unit - Rust Unit Management for PythonOriginally created as a faster version ofUnumfor use in Python-based FRC robot code.Building and Installing for Local Machinematurinbuild--release# This will generate wheels and put a native library in ./fast_unit/pipinstall.# Installs to your python interpreterCross Compilation for RoboRIO (WIP)Getting Required FilesIn order to compile for RoboRIO, you need to copy the contents of/usr/local/liband
update theRIO_ROOTto reflect where you copied them. This is assuming you have already
installed python on your RIO usingRobotPy.This is the command I used to accomplish this:scplvuser@roboRIO-XXXX-FRC.local:/usr/local/lib./RIO_ROOT/usr/local/libInstalling ARM LinkerRust needs an arm linker to compile arm binaries, which can be installed fairly easily.
On debian, run the following:sudoaptinstallgcc-arm-linux-gnueabiBuildingOnce you have the required tools, running the script below should compile and build
the wheels.# Add RIO's target triplerustuptargetaddarm-unknown-linux-gnueabi# Set cross-compilation environment variablesexportPYO3_CROSS_PYTHON_VERSION=3.10exportPYO3_CROSS_LIB_DIR="RIO_ROOT/usr/local/lib"# Build wheels for RIOmaturinbuild--target=arm-unknown-linux-gnueabi--rustc-extra-args="-C linker=arm-linux-gnueabi-gcc"
Package: fast-unzip
Fast unzipperFast unzipper is a Python CLI tool you could use to effectively and fast unzip ZIP archives.When will it be helpful?It proved to be useful working with huge amount of relatively small files for it distributes load among processes and threads to provide higher speeds than standard unzip.However, should you need to unzip archive with only few files, that tool isn't probably for you because it won't be possible to distribute 1 or 2 files in archive among threads.Moreover, changing threads(e.g. 8) when there are 8 files will lead to decrease in performance rather than profit in time.Use it when it's possible to adequately split your files.InstallationUse the package managerpipto install fast_unzip.pipinstallfast_unzipUsageIt's compulsory you specify the archive PATH like this.MacOS/Linuxpython3-mfast_unziptest.zipWindowspython-mfast_unziptest.zipBeing started this way it will use standard mode which means it will decide automatically which mode to use depending on compression level of your archive.Standard directory for unpacking is ./ZIP_unpack.
You can specify it with -d flag.python-mfast_unziptest.zip-d./../testNevertheless, you can specify number of processes and threads you want to start using -p and -t flags.python3-mfast_unziptest.zip-p4-t10Also, you can specify mode you want this tool to work. Maybe you know beforehand that compression level is low. You do it with -m flag.python-mfast_unziptest.zip-m"mt"RecommendationsThough, it's possible to choose mode, number of threads and number of processes manually, it's highly unrecommended, because if will affect the performance.Number of threads is chosen asmin(32, os.cpu_count()).Number of processes is chosen asos.cpu_count().For some reasonsos.cpu_count()can fail to determine your system characteristics. This way you'll be given an error and you need to specify this arguments explicitly. I highly recommend you use formula from above.If you try to enter more processes thanos.cpu_count()found you'll be given an error. You can either choose an appropriate number of processes or leave it to program to decide.!!! If it's impossible foros.cpu_count()to work and you enter inappropriate number of processes it will lead to undefined behaviour.If you know that archive you want to unpack is compressed less than 50% you can use-m "cmbd", else-m "mt". It will disable part of program doing analysis and increase performance.Thank you for using our tool!LicenseMIT
Package: fast-upfirdn
Fast UpfirdnThe core low-level function implemented here is an equivalent ofscipy.signal.upfirdnbut with support for both CPU (via NumPy) and GPU
(via CuPy).The version ofupfirdnhere supports several signal extension modes. These
have been contributed upstream to SciPy and are available there for SciPy 1.4+.Licensefast_upfirdnis licensed under the terms of the BSD 3-clause license. See
the file “LICENSE.txt” for information on the history of this software, terms &
conditions for usage, and a DISCLAIMER OF ALL WARRANTIES.All trademarks referenced herein are property of their respective holders.Copyright (c) 2019-2020,
Gregory R. Lee, Cincinnati Children’s Hospital Medical Center.
Package: fast-utils
fast-utils is a collection of small Python function that can make you scripts more fast.
This collection is organized package of receipts and experiments founded in the Internet.Notice“Premature optimization is the root of all evil” –Donald Knuth.InstallationTo use fast-utils  usepiporeasy_install:pip install fast-utilsoreasy_install fast-utilsCONTRIBUTEIf you know how make some things more fast.Check for open issues or open a fresh issue to start a discussion around a feature idea or a bug.
There is a Contributor Friendly tag for issues that should be ideal for people who are not very familiar with the codebase yet.Forkthe repositoryon Github to start making your changes to thedevelopbranch (or branch off of it).Write a test which shows that the bug was fixed or that the feature works as expected.Send a pull request and bug the maintainer until it gets merged and published.
Package: fastvalidate
RequirementsPython 3.6+Installation & Upgradepipinstallfastvalidate--upgradeDictionary ValidationfromfastvalidateimportValidatorvalidator=Validator({'first_name':'Mo','last_name':None,'age':'5','email':'mojtabaa.hn@gmail','website':'yup','languages':['en','fa'],},{'first_name':'required|min:3','last_name':'required|min:3','age':'required|numeric|gt:10|lt:120','email':'required|email','website':'required|url','languages':'required|list|min:3'})validator.validate().errors()# {#     'first_name': 'Field length must be at least 3 characters',#     'last_name': 'Field is required',#     'age': 'Field must be greater than 10',#     'email': 'Field must be email',#     'website': 'Field must be url',#     'languages': 'Field must have at least 3 items'# }Pydantic ValidationfromfastvalidateimportBaseModelclassUser(BaseModel):email:strwebsite:strclassConfig:rules=dict(email='required|email|min:3',website='required|url|min:3')user=User(email='whatever',website='whoever')# ValidationError# [#     dict(loc=('email',), msg='Field must be email', type='value_error'),#     dict(loc=('website',), msg='Field must be url', type='value_error')# ]Available RulesTypeApplicable              OnsignatureBooleanstring, booleanbool,booleanNumericstring, integernumeric,int,integerListstring(json), listlist,arrayDictionarystring(json), dictdictEmailstringemailPasswordstringpasswordRegExstringregex:<pattern>URLstringurlLengthstring, integer, float, list, dictlen:<length>,length:<length>Minstring, integer, float, list, dictmin:<threshold>Maxstring, integer, float, list, dictmax:<threshold>Choicestringchoice:<x>,<y>,<z>in:<x>,<y>,<z>Greater Thanintgt:<threshold>Greater Than Equalintgte:<threshold>Less Thanintlt:<threshold>Less Than Equalintlte:<threshold>AlphastringalphaAlpha Numericstringalpha_num,alpha_numericAlpha Num Dashstringalpha_dashDatestringdateUUIDstringuuidIPV4stringipv4IPV6stringipv6IPstringipMac Addressstringmac,mac_addressTesting# install pytestpipinstallpytest# run testspython-mpytest
Package: fast-version
FastAPI versioning libraryThis package adds versioning by Accept-header into FastAPIQuickstart:Defining app and routesimportfastapifromfast_versionimportVersionedAPIRouter,init_fastapi_versioningVERSION_HEADER:str="application/vnd.some.name+json"ROUTER_OBJ=VersionedAPIRouter()@ROUTER_OBJ.get("/test/")asyncdeftest_get()->dict:return{"version":(1,0)}@ROUTER_OBJ.get("/test/")@ROUTER_OBJ.set_api_version((2,0))asyncdeftest_get_v2()->dict:return{"version":(2,0)}app=fastapi.FastAPI()app.include_router(ROUTER_OBJ)init_fastapi_versioning(app=app,vendor_media_type=VERSION_HEADER)Query Examples# call 1.0 versioncurl-X'GET''https://test.ru/test/'-H'accept: application/vnd.some.name+json; version=1.0'curl-X'GET''https://test.ru/test/'-H'accept: application/vnd.some.name+json'curl-X'GET''https://test.ru/test/'# call 2.0 versioncurl-X'GET''https://test.ru/test/'-H'accept: application/vnd.some.name+json; version=2.0'
Package: fastwapi
DescriptionFastWAPI is a simple lightweight Websocket framework based on Starlette, which provide easy-to-use Python decorator to parse JSON incoming message.It's in the same spirit asFastAPI, where each decorator map to an HTTP path. But here, each decorator map to a Pydantic object, and each object map to a function.Installationpip install fastwapiDisclaimerThe module is available, but far from finished & polished, please do not use it in production.RoadmapAdd authent middlewareAdd background job to asynchrounosly send JSON to the clientUsageSee example/main.py for complete code.Getting started in three steps :Instanciates the framework and declare the Websocket HTTP endpoint.importuvicornfromfastwapiimportFastWAPI,WebSocketfrompydanticimportBaseModelapp=FastWAPI(endpoint="/ws")Define Pyndantic model, for incoming and outgoing messages.classCM(BaseModel):counter:intclassSD(BaseModel):name:strMap each Pydantic model to your function.@app.parse(CM)asyncdefparse_CM(websocket:WebSocket,data:CM):print("RECEIVED CM : ",data)awaitwebsocket.send_json(data.dict())@app.parse(SD)asyncdefparse_SD(websocket:WebSocket,data:CM):print("RECEIVED SD : ",data)awaitwebsocket.send_json(data.dict())Launch your appEither through command line "uvicorn main:app" or directly inside the python file :if__name__=="__main__":uvicorn.run("main:app",port=5000,log_level="info")
Package: fastweb
English |简体中文Introductionfastwebis a web-server integration solution. It based ontornado,celery,thrift.DocumentationExamplesIt is a charming web-server framework based on the effective technique and organized into component. The components could be used with only several config and code. It is always so easy to make a new component.It also provides many scenes to construct your apis, pages, rpc functions, tasks and so on efficiently.Features- Configuration
        - ini

    - Web
        - api
        - page render

    - Task
        - distributed task
        - periodic task
        - touting task

    - Rpc
        - thrift

    - Component
        - mysql
        - redis
        - mongo
        - http
        - soap

    - Manager
        - poolGetting StartedpipinstallfastwebExamplesMany useful examples arehere.ChangelogDetail changes for each releases are documented in therelease notes.LicenseApache LicenseCopyright on (c) 2018-present bslience
Package: fastwebhook
fastwebhookA simple GitHub webhook server.At this stage, this is only able to send tweets on software releases. It's very early stage still. You'll need to set up a webhook on GitHub.InstallFirst install the package:pip install fastwebhookThen create an file calledtwitter.inicontaining:gh_secret: 
consumer_key: 
consumer_secret: 
access_token: 
access_token_secret:gh_secretis the webhook secret you set in GitHub. The remaining are your twitter API keys.How to useRunfastwebhookto run the web server. Pass--helpfor info about optional arguments. Either run this from the same directory that contains yourtwitter.ini, or else pass--inifilealong with the full path to your ini file.Systemd serviceThe following commands should all be run as root (i.e. prependsudoto the commands).To install it as a systemd service (which is probably what you want), runfastwebhook_install. Pass--helpfor info about optional arguments, which will be passed tofastwebhookby the service.After the service is installed, runsystemctl start fastwebhookto start it,systemctl status fastwebhookto check it, andsystemctl stop fastwebhookto stop it. Runsystemctl enable fastwebhookto have it start automatically on boot. Runjournalctl -eu fastwebhook
Package: fastwer
FastWERA PyPI package for fast word/character error rate (WER/CER) calculationfast (cpp implementation)sentence-level and corpus-level WER/CER scoresInstallationpipinstallfastwerExampleimportfastwerhypo=['This is an example .','This is another example .']ref=['This is the example :)','That is the example .']# Corpus-Level WER: 40.0fastwer.score(hypo,ref)# Corpus-Level CER: 25.5814fastwer.score(hypo,ref,char_level=True)# Sentence-Level WER: 40.0fastwer.score_sent(hypo[0],ref[0])# Sentence-Level CER: 22.7273fastwer.score_sent(hypo[0],ref[0],char_level=True)ContactChanghan Wang (wangchanghan@gmail.com)
Package: fastwlk
Quick LinksDocumentationInstallationUsageContributingWhat doesfastwlkdo?fastwlkis a Python package that implements a fast version of the
Weisfeiler-Lehman kernel. It manages to outperform current state-of-the-art
implementations on sparse graphs by implementing a number of improvements
compared to vanilla implementations:It parallelizes the execution of Weisfeiler-Lehman hash computations since
each graph’s hash can be computed independently prior to computing the
kernel.It parallelizes the computation of similarity of graphs in RKHS by computing
batches of the inner products independently.When comparing graphs, lots of computations are spent processing
positions/hashes that do not actually overlap between Weisfeiler-Lehman
histograms. As such, we manually loop over the overlapping keys,
outperforming numpy dot product-based implementations on collections of
sparse graphs.This implementation works best when graphs have relatively few connections
compared to the number of possible connections and are reasonably dissimilar
from one another. If you are not sure the graphs you are using are either sparse
or dissimilar enough, try to benchmark this package with others out there usingthis script.How fast isfastwlk?Running the benchmark script inexamples/benchmark.pyshows that for the
graphs indata/graphs.pkl, we get an approximately 80% speed improvement
over other implementations likegrakel. The example dataset contains 2-nn
graphs extracted from 100 random proteins from the human proteome from theAlphaFold EBI database.To see how much faster this implementation is for your use case:$gitclonegit://github.com/pjhartout/fastwlk$poetryinstall$poetryrunpythonexamples/benchmark.pyYou will need to swap out the providedgraphs.pklwith a pickled iterable of
graphs from the database you are interested in.
Package: fastwork
fastwork致力于让你繁琐的工作自动化，让你有更多的精力和时间去提升自己的认知和影响力。
欢迎关注我的微信公众号：人文互联网。安装pip install china-district依赖库requests=2.22.0基础使用示例基础使用，默认使用作者自己的高德地图开发者key，每天上限调用30万次。超过这个限制将无法使用。>>> In [1]: from china_district import District
# 初始化District,默认只返回下一级行政区，不返回行政区边界坐标点
>>> In [2]: d=District()

>>> In [3]: d.get("武侯区")
{'status': '1',
 'info': 'OK',
 'infocode': '10000',
 'count': '1',
 'suggestion': {'keywords': [], 'cities': []},
 'districts': [{'citycode': '028',
   'adcode': '510107',
   'name': '武侯区',
   'center': '104.05167,30.630862',
   'level': 'district',
   'districts': [{'citycode': '028',
     'adcode': '510107',
     'name': '金花桥街道',
     'center': '103.973,30.6029',
     'level': 'street',
     'districts': []},
……}
# 将当前搜索结果(json对象)写入到当前目录，默认文件名"搜索关键词.json"
>>> d.to_json("武侯区")
	写入本地完成...高级使用示例>>> In [1]: from china_district import District
# 初始化District,key为高德地图开发者key,subdistrict设置显示下级行政区级数，extensions设置行政区信息中是否返回行政区边界坐标点，”base"不返回，“all"返回

>>> In [5]:d = District(key="182ad5d7061ed1e421091c22089c3677",subdistrict=3,extensions="all")

Out[6]: 
{'status': '1',
 'info': 'OK',
 'infocode': '10000',
 'count': '1',
 'suggestion': {'keywords': [], 'cities': []},
 'districts': [{'citycode': '028',
   'adcode': '510107',
   'name': '武侯区',
   'polyline': '103.949841,30.658586;103.949928,30.658864;103.950137,30.659044;103.950415,30.659121;103.950667,30.6591;103.952425,30.658587;103.952869,30.658525;103.95333,30.658589;103.953
687,30.658726;103.953966,30.658948;103.954261,30.659335;103.954984,30.660906;103.955149,30.661113;103.955472,30.661348;103.95575,30.661423;103.956107,30.661436;103.957439,30.661364;103.957……```}请求参数说明了解更多高德地图行政区域查询接口：https://lbs.amap.com/api/webservice/guide/api/districtLicenseLicensed under the MIT License.
Package: fastwsgi
FastWSGI:construction: FastWSGI is still under development.FastWSGI is an ultra fast WSGI server for Python 3.Its written in C and useslibuvandllhttpunder the hood for blazing fast performance.Supported PlatformsPlatformLinuxMacOsWindowsSupport:white_check_mark::white_check_mark::white_check_mark:PerformanceFastWSGI is one of the fastest general use WSGI servers out there!For a comparison against other popular WSGI servers, seePERFORMANCE.mdInstallationInstall using thepippackage manager.pipinstallfastwsgiQuick startCreate a new fileexample.pywith the following:importfastwsgidefapp(environ,start_response):headers=[('Content-Type','text/plain')]start_response('200 OK',headers)return[b'Hello, World!']if__name__=='__main__':fastwsgi.run(wsgi_app=app,host='0.0.0.0',port=5000)Run the server using:python3example.pyOr, by using thefastwsgicommand:fastwsgiexample:appExample usage with FlaskSeeexample.pyfor more details.importfastwsgifromflaskimportFlaskapp=Flask(__name__)@app.get('/')defhello_world():return'Hello, World!',200if__name__=='__main__':fastwsgi.run(wsgi_app=app,host='127.0.0.1',port=5000)TestingTo run the test suite usingpytest, run the following command:python3-mpytestContributingPull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.Please make sure to update tests where appropriate.TODOComprehensive error handlingComplete HTTP/1.1 complianceUnit tests running in CI workflow
Package: fastx
fastxJust a fasta/q parser based onkseq.hfor CPython and PyPy.Install with:pip install fastxExample use:import fastx
for name, seq, qual for Fastx(filename):
    print(">{}\n{}".format(name, seq))This library was inspired by the benchmarking page below and that the
existing fastest entry for python works only on CPython. It is not
intended for general use.https://github.com/lh3/biofastBenchmarkingLine profiling the previous code we find program spent as much time adding python
objects together as it does in the pyfastx package:Line #      Hits         Time  Per Hit   % Time  Line Contents
==============================================================
    28                                           @profile
    29                                           def main():
    30         1         21.0     21.0      0.0      n, slen, qlen = 0, 0, 0
    31   5682011    7366975.0      1.3     47.9      for name, seq, qual in pyfastx.Fastq(sys.argv[1], build_index=False):
    32   5682010    2324629.0      0.4     15.1          n += 1
    33   5682010    2783887.0      0.5     18.1          slen += len(seq)
    34   5682010    2909447.0      0.5     18.9          qlen += qual and len(qual) or 0
    35         1        158.0    158.0      0.0      print('{}\t{}\t{}'.format(n, slen, qlen))This modules works both under CPython and PyPy, unlike pyfastx which is
strictly a CPython extension. When using PyPy, the difference between
the Python and C implementation is narrowed dramatically.Running cpython
5682010	568201000	568201000

real	0m11.444s
user	0m10.944s
sys	0m0.284s


Running pypy
5682010	568201000	568201000

real	0m1.973s
user	0m1.555s
sys	0m0.258s


Running C
5682010	568201000	568201000

real	0m1.764s
user	0m1.508s
sys	0m0.217s
Package: fastx-barber
fastx-barberPyPi|docsA Python3.8+ package to trim and extract flags from FASTA  and FASTQ files.Features (in short)Works on both FASTA and FASTQ files.Selects reads based on a pattern (regex).Trims reads by pattern (regex), length, or single-base quality.Extracts parts (flags) of reads based on a pattern and stores them in the read headers.Generates BED file with the locations of a substringin FASTX records.Regular expression supportfuzzymatching(fuzzy matchingmight affect the barber's speed).Parallelizes processing by splitting the fastx file in chunks.For more available features, check out ourdocs!Requirementsfastx-barberhas been tested with Python 3.8 and 3.9. We recommend installing it usingpipx(seebelow) to avoid dependency conflicts with other packages. The packages it depends on are listed in ourdependency graph. We usepoetryto handle our dependencies.InstallWe recommend installingfastx-barberusingpipx. Check how to installpipxhereif you don't have it yet!Once you havepipxready on your system, install the latest stable release offastx-barberby running:pipx install fastx-barber. If you see the stars (✨ 🌟 ✨), then the installation went well!UsageRun:fbarberto access the barber's services.fbarber find_seqto extract the locations of a sequence (e.g., restriction site) in FASTX records.fbarber flagto extract or manipulate read flags.fbarber matchto select reads based on a pattern (regular expression).fbarber trimto trim your reads.Add-hto see the full help page of a command!ContributingWe welcome any contributions tofastx-barber. In short, we useblackto standardize code format. Any code change also needs to passmypychecks. For more details, please refer to ourcontribution guidelinesif this is your first time contributing! Also, check out ourcode of conduct.LicenseMIT License - Copyright (c) 2020-21 Gabriele Girelli
Package: fastxm
fastxmFor cross-matching astronomical catalogs. Likenp.intersect1dbut faster.InstallationFromPyPI:pipinstallfastxmFrom source (requiresmaturin):gitclonehttps://github.com/al-jshen/fastxmcdfastxm
maturinbuild--release
pipinstalltarget/release/<pathtowheel>Example usagefromfastxmimportintersect_1dcatalog_1=...catalog_2=...match_ix_1,match_ix_2=intersect_1d(catalog_1['common_id'],catalog_2['common_id'],parallel=True)Tests/BenchmarksThis requirespytestandpytest-benchmark.gitclonehttps://github.com/al-jshen/fastxmcdfastxm
maturindevelop
pytest
Package: fastxor
Afraid of red status ? Please click on the link, sometimes this is not my fault ;-)A C++ fast XOR implementation strongly inspired byeryksun’s stackoverflow post.Here are the results on my workplace desktop computer (Intel(R) Core(TM) i7-3770 CPU @ 3.40GHz):Method NameTimeSpeep-upxor_inplace_loop0.4441.000xor_list_comprehension0.2371.877numpy.bitwise_xor0.00175252.986fastxor.fast_xor_inplace0.00125356.339What the release number stands for ?I do my best to follow this interesting recommendation :Semantic Versioning 2.0.0How to install it (Python 2.7) ?Install some packages that are not handled by pip:sudo apt-get install gfortran python-dev python-pipMake sure that pip is up-to-date (PIPception):sudo pip-2.7 install --upgrade pipThen, you only need to runsetup.py:python2 setup.py test
sudo python2 setup.py installHow to install it (Python 3.3) ?Install some packages that are not handled by pip:sudo apt-get install gfortran python3-dev python3-pipMake sure that pip is up-to-date (PIPception):sudo pip-3.3 install --upgrade pipThen, you only need to runsetup.py:python3 setup.py test
sudo python3 setup.py installSometimes numpy setup fails, just runsudopip-3.3install numpyto solve this.How to check coverage ?python setup.py test
xdg-open tests/cover/index.htmlHow to use it ?This extension module gives you access to fast_xor_inplace and fast_xor (… TODO).2013 - David Fischer