Saravanan666/pypi-org huggingface dataset:
Package: escape-windows-filepath
Escaping file paths (Windows) without crying and losing one's mindpip install escape-windows-filepathTested against Windows 10 / Python 3.10 / Anaconda# How it is usually done:importosvideopathraw=r"C:\baba ''bubu\bab xx\2020-11-23 13-05-26.mp4"vlcpathraw=r"C:\Program Files\VideoLAN\VLC\vlc.exe"# Quite frequently something like this surprisingly works, but in this example it doesn't:videofilenotwellescaped='"'+r"C:\baba ''bubu\bab xx\2020-11-23 13-05-26.mp4"+'"'vlcpathnotwellescaped='"'+r"C:\Program Files\VideoLAN\VLC\vlc.exe"+'"'escapedcmdnotgood=rf"{vlcpathnotwellescaped}{videofilenotwellescaped}"print(f"{escapedcmdnotgood=}")os.system(escapedcmdnotgood)# Output:# escapedcmdnotgood='"C:\\Program Files\\VideoLAN\\VLC\\vlc.exe" "C:\\baba \'\'bubu\\bab xx\\2020-11-23 13-05-26.mp4"'# 'C:\Program' is not recognized as an internal or external command,# operable program or batch file.fromescape_windows_filepathimportescape_windows_path# The safest method is escaping evey single part (folder,file) of the pathvideofileescaped=escape_windows_path(videopathraw)vlcpath=escape_windows_path(vlcpathraw)escapedcmd=rf"{vlcpath}{videofileescaped}"print(f"{escapedcmd=}")os.system(escapedcmd)# Output# escapedcmd='C:\\"Program Files"\\"VideoLAN"\\"VLC"\\"vlc.exe" C:\\"baba \'\'bubu"\\"bab xx"\\"2020-11-23 13-05-26.mp4"'# And the video player opens
Package: escapyde
escapydeYet another ANSI escape sequence library for Python - now modernised!InstallationThe package is readily available on PyPI. There are no dependencies, but Python 3.9 or newer is required.On Windows:py-mpipinstallescapydeOn other platforms:pip3installescapydeChangelogYou can find the project changeloghere.UsageFor basic usage, pre-made colours are available for your convenience.
Use them with the pipe operator on strings you want to colour. They
end the colour changes automatically, too!importescapydefromescapyde.examples.textimportSKULLsome_text="Hello, world!"print(f"I want to print this red:{escapyde.FRED|some_text}, and this yellow:{escapyde.FYELLOW|'Hi!'}.")print(f"Here's a cyan skull:\n{escapyde.FCYAN|SKULL}")You can also colour backgrounds,importescapydesome_more_text="This should have a blue background."print(f"{escapyde.BBLUE|some_more_text}")combine formatting options,importescapydeeven_more_text="Lorem Ipsum dolor sit amet."print(f"{escapyde.FRED|escapyde.BWHITE|even_more_text}")and even mix formatting options on the fly (although at present you need to
separate strings with parentheses):importescapydeprint(f"{(escapyde.FRED|'Hello')|(escapyde.FBLUE|'World')}")It is possible to use custom foreground and background colours via theescapyde.AnsiEscapeclass; these can be either valid ANSI literals or
RGB values:fromescapyde.ansiimportAnsiEscapefromescapyde.coloursimportsequence_tablefg_white=sequence_table['fg_white']# You can alternatively use raw integers, eg. 37 for whitegold=AnsiEscape(foreground_colour=(0xDB,0xAC,0x34))white_gold=AnsiEscape(foreground_colour=fg_white,background_colour=(219,172,34))print(gold|"This is gold!")print(white_gold|"This is white text on gold background!")The class defaults to the default colours of the terminal,
so you don't need to set both values.Finally, if you have a string with multiple substrings you wish to recolour, there's a function for that:fromescapyde.ansiimportAnsiEscape,escape_formatmapping={'match':AnsiEscape(foreground_colour=(255,0,0)),'case':AnsiEscape(foreground_colour=(255,255,0)),'print':AnsiEscape(foreground_colour=(0,255,0)),}text="""stuff = [3, 1, 4]match stuff:case [3, *rest]:print("It's pi-like")case _:print("Not like pi")"""print(escape_format(string=text,escape_map=mapping,case_sensitive=True))Screenshots
Package: escarpolette
EscarpoletteThis project provides a server and clients to manage your music playlist when you are hosting a party.It supports many sites thanks to the awesome projectyoutube-dl.FeaturesServer:add items (and play them!)get playlist's itemsruns on Android! (seeinstructions)Web client:there is currently no web client :(DependenciesPython 3.7the playermpvThey should be available for most of the plateforms.InstallationpipinstallescarpoletteAndroidYou will needTermux.
Then inside Termux you can install it with:# dependenciespkginstallpythonpython-devclangmpv# escarpolettepipinstallescarpoletteNote that while the project can run without wake-lock, acquiring it improve the performance (with a battery trade off).Usageescarpolette[--configconfig.cfg][--hosthost][--portport][--help]The default configuration should be good for all the usages.DevYou will needPoetryto manage the dependencies.Clone the repo and then typepoetry install.
You can run the app withpoetry run python -m escarpolette.Todoservervotesbonjour / mDNSprevent adding youtube / soundcloud playlistsrestrictions by usersconfiguration of those restrictions by an adminweb clientshow playing statusvotesconfigure restrictions:max video added per usermax video lengthadmin access:configure restrictionsno restrictions for himforce video orderMaybe one day?android clientiOS client
Package: escat
# Elasticsearch cat CLIBasic Elasticsearch cat API command line wrapper with multi-cluster support[![Build Status](https://travis-ci.org/anishmcloud/escat.svg?branch=master)](https://travis-ci.org/anishmcloud/escat)[![PyPI](https://img.shields.io/pypi/v/escat.svg)](https://pypi.org/project/escat/)#### Features:- Complete coverage of all Elasticsearch `cat` modules- Exposed `cat` API call options as command line arguments- Get output in form of json, or text- Manage multiple clusters using profiles- Support for SSL and Password authentication### Installation:**Requirements**:- python3- pip**Installation instructions**- Install using pip```pip install escat```- A config file will be automatically created in the home directory of the current user called `~/escat.yml`. This file will have the default configuration:```yamlclusters:default:hosts: ["http://localhost:9200"]```### ConfigurationExample configuration```yamlclusters:default:hosts: ['http://localhost:9200']#    auth:#      username: 'elastic'#      password:#        ask: yes#        value: 'elastic'#    ssl:#      enabled: no#      cert: ''#      ca: []#      private_key: ''#      verify_certs: yes```The contents of the file are pretty self explanatory. The keys: `auth` and `ssl` are disabled but visible for reference on how to configure authentication for the requests sent to Elasticsearch. Below mentioned is a multi cluster configuration. For the rest of the documentation, we are going to use this configuration file to run commands:```yamlclusters:default:hosts: ['http://localhost:9200']dev:hosts: ['https://dev-es-1:9200', 'https://dev-es-2:9200']prod:hosts: ['https://prod-es-1:9200', 'https://prod-es-2:9200']ssl:enabled: yescert: '~/.openssl/certs/prod-es-cert.cert'ca: ['~/.openssl/cas/prod-ca-1.cert', '~/.openssl/cas/prod-ca-2.cert']private_key: '~/.openssl/certs/prod-es-cert.key'verify_certs: yes```If you set a config like this:```yamlclusters:default:hosts: ['http://localhost:9200']auth:username: 'elastic'password:ask: yes```You will be asked for the password on a command line.### RunningTo understand some options, please refer the config example directly above.Get help for commands```escat -h```Get cluster health for default cluster```lescat health```Get count for selective indices in the dev cluster```escat --cluster dev count --indices "dev-test"```Get recovery information on prod cluster in json format```escat --cluster prod --format json recovery```Use a different config file```escat --config ~/.es.yml --cluster dev health```### ContributingPlease raise github issues related to questions, feature requests or troubleshooting. Also, to make debug person's life easier, one should always include the following information:- Command ran- Operating system- Python version- Elasticsearch versionCurrently, the escat is only tested on Python 3.6.5 on Ubuntu 16.04, Windows 10, and Mac OSX.PRs are welcome. Do mention the description in brief what the PR would fix. If the PR is in a form of checklist, it would be amazing.### Resources[Elasticsearch cat API](https://www.elastic.co/guide/en/elasticsearch/reference/current/cat.html)
Package: esc-calc
What is esc?esc(pronounced /esk/) is an Extensible Stack-based Calculator
designed for efficiency and customizability.
What does this mean?esc isstack-based,
operating using aReverse Polish Notation-like syntax.
Rather than typing2 + 2and pressing an equals key,
you enter the two numbers2and2onto the stack,
then choose+to add them.
This can be slightly awkward at first,
but it means no parentheses are necessary,
and for most people it becomes faster and more elegant
than the standard algebraic method
with a small amount of practice.
In addition, it is considerably easier to customize and program.esc isextensible.
If you frequently need to
multiply two numbers together, add five, and then divide the result by pi,
you can add an operation to the calculator to do this specific operation
using a couple of lines of Python code.
The extension features are simple enough to be accessible
even to people who do not know Python
or have little to no programming experience.esc operations are arbitrary Python code, so if you want to get fancy,
they can get arbitrarily complicated.
You can even call APIs to perform calculations or get data!esc isfast,simple, andterminal-based.
All you need is a working terminal (at least 80×24)
and your keyboard.Installationesc requires Python 3.6 or greater.
It is lightweight and has no dependencies outside the standard library
(except on Windows, wherencursesisn't available by default
and thewindows-cursespackage is transparently installed to fix that).
The recommended installation method is through pip:$ pip install --user esc-calcThis will install anesccommand to your system path which will launch esc.After installing esc, you may wish to install plugins
(see the "Plugins" section in theuser guide).
Official plugins can be downloaded
from theesc-pluginsfolder of this repository.DevelopmentFor development, clone this repository,
build a virtualenv with the necessary development tools,
and install esc into it:$ git clone https://github.com/sobjornstad/esc
$ cd esc
$ virtualenv --python=python3.7 venv  # or 3.6 if you don't have 3.7
$ . venv/bin/activate
$ pip install -r requirements.txt
$ pip install -e esc
$ escDocumentationThe user manual and API documentation on writing plugins for esc
are maintained onRead The Docs.ContributingBug reports, suggestions, and code contributions are welcome.In particular,
if you write a plugin that might be useful to someone else,
please consider submitting it for inclusion
in the officialesc-pluginsdirectory.
Package: escea
MIT LicenseCopyright (c) 2016 Mal CurtisPermission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the “Software”), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.Description: Escea Fireplace API Client
Platform: UNKNOWN
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: Natural Language :: English
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 2.6
Classifier: Programming Language :: Python :: 2.7
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.3
Package: escherauth
EscherPython - HTTP request signing libEscher helps you creating secure HTTP requests (for APIs) by signing HTTP(s) requests. It's both a server side and client side implementation. The status is work in progress.The algorithm is based onAmazon'sAWS Signature Version 4, but we have generalized and extended it.More details are available atescherauth.io.Signing a requestEscher works by calculating a cryptographic signature of your request, and adding it (and other authentication information) to said request.Usually you will want to add the authentication information to the request by appending extra headers to it.fromescherauthimportEscherrequest={'method':'POST','url':'/','headers':[['Host','example.com'],],'body':'{"this_is": "a_request_body"}',}escher=Escher('YOUR_ACCESS_KEY_ID','YOUR SECRET','example/credential/scope')signed_request=escher.sign_request(request)frompprintimportpprintpprint(signed_request)Signing aRequestsrequest:importrequestsfromescherauthimportEscherRequestsAuthauth=EscherRequestsAuth('YOUR_ACCESS_KEY_ID','YOUR SECRET','example/credential/scope')response=requests.post('https://httpbin.org/post',json={'this_is':'a_request_body'},auth=auth)frompprintimportpprintpprint(response.json())Presigning a URLIn some cases you may want to send authenticated requests from a context where you cannot modify the request headers, e.g. when embedding an API generated iframe.You can however generate a presigned URL, where the authentication information is added to the query string.fromescherauthimportEscherescher=Escher('YOUR_ACCESS_KEY_ID','YOUR SECRET','example/credential/scope')presigned_url=escher.presign_url('http://example.com/',expires=300)print(presigned_url)Validating a requestYou can validate a request signed by the methods described above. For that you will need a database of the access keys and secrets of your clients.fromescherauthimportEscher,EscherExceptionescher=Escher('','','example/credential/scope')signed_request={'body':'{"this_is": "a_request_body"}','headers':[['Host','example.com'],['X-Escher-Date','20240227T121443Z'],['X-Escher-Auth','ESR-HMAC-SHA256 Credential=YOUR_ACCESS_KEY_ID/20240227/example/credential/scope, SignedHeaders=host;x-escher-date, Signature=5febb099193b8e6c4027ff810e0faa5bc8a275efb46f2d5c1af8810f4332c4cb'],],'method':'POST','url':'/',}key_db={'ACCESS_KEY_OF_CLIENT_1':'SECRET OF CLIENT 1','ACCESS_KEY_OF_CLIENT_42':'SECRET OF CLIENT 42',}try:escher.authenticate(signed_request,key_db)print('OK')exceptEscherExceptionase:print(f'The validation failed:{e}')
Package: escience
escience科研在线网盘CTL客户端http://ddl.escience.cn安装环境Python 3pip install escience在~/escience.cfg中配置自己的账号和密码及下载路径#使用escience --help===>显示帮助escience -s somefile===>以关键字somefile搜索相关文件escience -d 0===>下载序号为0的文件
Package: es-client
https://es-client.readthedocs.io/You may wonder why this even exists, as at first glance it doesn’t seem to make
anything any easier than just using the elasticsearch8 Python module to
build a client connection.  I needed to be able to reuse the more complex
schema validation bits I was employing, namely:master_onlydetectionElasticsearch version checking and validation, and the option to skip this.Configuration value validation, including file paths for SSL certificates,
meaning:No unknown keys or unacceptable parameter values are acceptedAcceptable values and ranges are established (where known)–and easy to
amend, if necessary.So, if you don’t need these, then this library probably isn’t what you’re
looking for.  If you want these features, then you’ve come to the right place.Example Usagefrom es_client import Builder

config = {
    'elasticsearch': {
        'client': {
            'hosts': 'https://10.0.0.123:9200',
            'ca_certs': '/etc/elasticsearch/certs/ca.crt',
            'request_timeout': 60,
        },
        'other_settings': {
            'master_only': false,
            'username': 'joe_user',
            'password': 'password',
        }
    },
    'logging': {
        'loglevel': 'INFO',
        'logfile': '/path/to/file.log',
        'logformat': 'default',
    }
}

builder = Builder(configdict=config)

try:
    builder.connect()
except:
    # Do exception handling here...

client = builder.clientAdditionally, you can read from a YAML configuration file:---
elasticsearch:
  client:
    hosts: https://10.0.0.123:9200
    ca_certs: /etc/elasticsearch/certs/ca.crt
    request_timeout: 60
  other_settings:
    master_only: false
    username: joe_user
    password: password
logging:
  loglevel: INFO
  logfile: /path/to/file.log
  logformat: defaultfrom es_client import Builder

builder = Builder(configfile='/path/to/es_client.yml')

try:
    builder.connect()
except:
    # Do exception handling here...

client = builder.clientThe same schema validations apply here as well.
Package: esc-ls
This is a plugin for the Palantir’s Python Language Server (https://github.com/palantir/python-language-server)It, requires Python 3.6 or newer.InstallationInstall into the same virtualenv as pyls itself.pip installesc-lsConfigurationDepending on your editor, the configuration (found in a file called esc-ls.cfg in your workspace or a parent directory) should be roughly like this:{
    "enabled": True
}
Package: escode
Fast Serializing and Deserializing for Python.escodeis a very fast binary serialize/deserialize module for Python. It is written as a Python C-Extension and operates on most portable types. It is designed to be fast, generate small encoding sizes, and have a version that is indexable/sortable. This last part is the primary motivation forescodesince most data retrieval happens via indexed range queries.PerformanceBelow is the space and time performance ofescodeas compared to other major encodings. It was generally faster, and produced sizes comparable to dense formats likecborormsgpack. The code used can be found in thebenchmarkdirectory.MethodEncode (μs)xFasterDecode (μs)xFasterSizexSmallerescode9811.0024111.001851.00pickle17231.7626971.122331.26json51855.2876853.193381.82cbor15341.5624561.021800.97ujson20172.0636871.533301.78msgpack13291.3630861.281790.97Installation# Requires gcc and python-dev# Requires Python2.7+ or Python3+pipinstallescodeUsageimportescodedata={"id":<id>,"name":"James Maddison",...}blob=escode.encode(data)db.put(<id>,blob)...dbdata=escode.decode(db.get(<id>))assertdbdata==dataMost data retrieval for data happens via range queries which operates on data attributes.escode.encode_indexproduces an encoding that matches the sort order of the input. i.e.cmp(tup1, tup2) == cmp(encoded_tup1, encoded_tup2)Index encoding isnot decodableas it skips some of info (like lengths for strings/collections)- it is only meant to be used to store and compare against an index of the same type.City=namedtuple('City',('id','name','country','pop'))citylist=[City('city:1','Delhi','India',19000000),City('city:2','Mumbai','India',18000000),City('city:3','San Francisco','USA',3000000),City('city:4','Paris','France',5000000),...]INDEX_NAME='index:city:country_pop'indextuples=[]forcityincitylist:# store datadb.put(city.id,city)# store indexindextuple=(INDEX_NAME,city.country,city.pop)indextuples.add(indextuple)index=escode.encode_index(indextuple)db.put(index,city.id)#retrieval: Indian cities with pop between 1M and 5Mrangestart=escode.encode_index((INDEX_NAME,'India',1000000))rangeend=escode.encode_index((INDEX_NAME,'India',5000000))cityids=db.getrange(rangestart,rangeend)indiancities=db.multiget(cityids)# also useful for sortingtuple_encodings=[(indextup,escode.encode_index(indextup))forindextup,cityidinindextuples]# sorting by tuples is the same as sorting by the encodingsassert(sorted(indextuples,key=lambdatup_enc:tup_enc[0])==sorted(indextuples,key=lambdatup_enc:tup_enc[1]))FormatEncodings use a 1 byteheadbytewhich stores the data type and some info, followed by a variable length (upto 8 bytes) number. This number is used to either store integer types or lengths for collections.Index encodings are tricky to implement since one cannot simply concat the index tuples in order to maintain sort ordering i.e.('a','z') < ('aa', 'z')but'az' > 'aaz'This is accomplished in escode by using'\x00\x00'as the boundary between tuple elements, and escaping\x00sin the tuple elements themselves. Since elements like 8 byte zeros are fairly common, consecutive\x00sinside elements are compressed as an optimization.
Package: escodegen
Escodegen(escodegen) is anECMAScript(also popularly known asJavaScript)
code generator fromMozilla's Parser APIAST. See theonline generatorfor a demo. This repository contains the Python translation of Escodegen.Installpip install escodegenUsageExample:importescodegenescodegen.generate({'type':'BinaryExpression','operator':'+','left':{'type':'Literal','value':20},'right':{'type':'Literal','value':2}})produces the string:'20 + 2'Example:importescodegenimportesprimaescodegen.generate(esprima.parse('let a=10;let b=20'))produces the string:'let a = 10;\nlet b = 20;'See theAPI pagefor
options.
Package: escodesearcher
escodesearcherA source code searcherCurrently searching in a limited set of sites:Geeks for GeeksC plus plusTutorials PointProgramizInstallationpip install escodesearcherDependenciesrequests -pip install requestsbeautifulsoup4 -pip install beautifulsoup4google -pip install googlehtml2text -pip install html2textUsageUseSearchCodeescodesearchercan be used to fetch source code urls from the sites mentioned above or to fetch the source codes in these sitesTo fetch and save the source codesfromescodesearcherimportSearchCodecode_searcher=SearchCode()keyword="Merge sort C++"source_codes=code_searcher.search(keyword)forindex,source_codeinenumerate(source_codes):withopen('fetched_files/'+str(index)+'.txt','w',encoding='utf8')asf:f.write(source_code)To fetch urls onlyfromescodesearcherimportUrlsFetchersearcher=UrlsFetcher()keyword="Binary Search C++"urls=searcher.fetch_urls(keyword)print(urls)Result is a list of urls from specific sitesTo fetch source codes from specific url from the supported sitesfromescodesearcherimportFetchCodecode_grapper=FetchCode()url="https://www.tutorialspoint.com/binary-search-in-cplusplus"print(code_grapper.fetch_code(url))
Package: es-core-news-sm
### Details:https://spacy.io/models/es#es_core_news_smSpanish pipeline optimized for CPU. Components: tok2vec, morphologizer, parser, senter, ner, attribute_ruler, lemmatizer.Feature | Description |— | — |Name|es_core_news_sm|Version|3.1.0|spaCy|>=3.1.0,<3.2.0|Default Pipeline|tok2vec,morphologizer,parser,attribute_ruler,lemmatizer,ner|Components|tok2vec,morphologizer,parser,senter,attribute_ruler,lemmatizer,ner|Vectors| 0 keys, 0 unique vectors (0 dimensions) |Sources| [UD Spanish AnCora v2.5](https://github.com/UniversalDependencies/UD_Spanish-AnCora) (Martínez Alonso, Héctor; Zeman, Daniel)<br />[WikiNER](https://figshare.com/articles/Learning_multilingual_named_entity_recognition_from_Wikipedia/5462500) (Joel Nothman, Nicky Ringland, Will Radford, Tara Murphy, James R Curran)<br />[spaCy lookups data](https://github.com/explosion/spacy-lookups-data) (Explosion) |License|GNU GPL 3.0|Author| [Explosion](https://explosion.ai) |### Label Scheme<details><summary>View label scheme (414 labels for 4 components)</summary></details>### AccuracyType | Score |— | — |TOKEN_ACC| 100.00 |TAG_ACC| 97.29 |POS_ACC| 98.20 |MORPH_ACC| 97.74 |LEMMA_ACC| 98.32 |DEP_UAS| 90.42 |DEP_LAS| 86.94 |SENTS_P| 97.87 |SENTS_R| 98.97 |SENTS_F| 98.42 |ENTS_P| 88.90 |ENTS_R| 88.98 |ENTS_F| 88.94 |