Saravanan666/pypi-org huggingface dataset:
Package: pyTerminalUI
pyTerminalUIA set of helpers to implement a text user interface (TUI) in a terminal.FeaturesColored command line outputs based on coloramaMessage classification in fatal, error, warning, normal, quiet, ...Get information like terminal dimensions from underlying terminal windowSimple Terminal ApplicationThis is a minimal terminal application example which inherits fromLineTerminal.frompyTerminalUIimportLineTerminalclassApplication(LineTerminal):def__init__(self):super().__init__(verbose=True,debug=True,quiet=False)defrun(self):self.WriteNormal("This is a simple application.")self.WriteWarning("This is a warning message.")self.WriteError("This is an error message.")# entry pointif__name__=="__main__":Application.versionCheck((3,6,0))app=Application()app.run()app.exit()Complex Terminal ApplicationThis example hands over the terminal instance to a submodule, which implementsILineTerminal, so the submodule can also use the terminal's writing methods.frompathlibimportPathfrompyTerminalUIimportLineTerminal,ILineTerminalclassSubModule(ILineTerminal):def__init__(self,configFile,terminal):super().__init__(terminal)ifnotconfigFile.exists():self.WriteError("Config file '{0!s}' not found.".format(configFile))classApplication(LineTerminal):def__init__(self):super().__init__(verbose=True,debug=True,quiet=False)mod=SubModule(Path("config.yml"),self)defrun(self):pass# entry pointif__name__=="__main__":app=Application()app.run()ContributorsPatrick Lehmann(Maintainer)and more...LicenseThis Python package (source code) licensed underApache License 2.0.The accompanying documentation is licensed underCreative Commons - Attribution 4.0 (CC-BY 4.0).SPDX-License-Identifier: Apache-2.0
Package: pyterm-progress-bar
pyterm_progress_barPrints a progress bar to the terminal from python.ProgressBarimportpyterm_progress_barprogress_bar=pyterm_progress_bar.ProgressBar(name='Progress',# Defaultchar='#'# Default)progress_bar.start()foriinrange(0,5):# Do stuffprogress_bar.update((i+1)/5)# between 0 and 1 inclusive.Looppyterm_progress_bar can automatically perform a loop for you to save you having to do the difficult math.importpyterm_progress_bardefmy_func(counter,data):# data param is optional here# Do stuff# 'counter' is the loop counter# 'data' is whatever you pass as 'param' in the next steploop=pyterm_progress_bar.Loop(my_func,number_of_iterations=300,param=['foo','bar','🐙'],# Optionalprogress_bar_name='Running my_func',# Defaultprogress_bar_char='#'# Default)loop.execute()
Package: pytermrec
termrecRecord your terminal and play itinstallFrom PyPIpip3 install pytermrecFrom GitHubpip3 install git+https://github.com/donno2048/termrecUsageJust type the command in the terminal:Record to a filetermrec-p<filepath># record without default commandtermrec-p<filepath>-c<commandtorecord># record with custom commandTo stop recording use theexitcommand or justctrl+DPlay a filetermplay-p<filepath># or with a prompttermplay-P
Package: pyTermTk
pyTermTk(pythonTerminalToolkit) is a Text-based user interface library (TUI)
Evolved from the discontinued projectpyCuTand inspired by a mix ofQt5,GTK, andtkinterapi definition with a touch of personal interpretationpyTermTk.Showcase.002.webmFeaturesSelf Contained(no external lib required), Python 3.9 or above required.Cross compatible:Linux🐧,MacOS🍎,MS Windows🪟,HTML5🌍(Try)Basic widgetsforTUIdevelopment (Button, Label, checkbox, ...)Specialized widgetsto improve the usability (Windows, Frames, Tables, ...)QT Like Layout system to help arrange the widgets in the terminalTrue color supportFul/Half/Zero sized Unicode characters 😎I am pretty sure there issomething else...Try theSandboxstraight from your browserPowered byPyodideandxterm.jsandCodeMirror5andw2uithe Tutorialsandthe ExamplesBe inspired bythe Tutorialsandthe ExamplesApi DefinitionsDon't get bored by theApi DefinitionsttkDesignerSmell deliciousness with the officialpyTermTktool for designing and building Text-based user interfaces (TUIs)Install/UpgradepyTermTkis available onPyPIpip3install--upgradepyTermTkQuick Test/Try - no install requiredClonegitclonehttps://github.com/ceccopierangiolieugenio/pyTermTk.gitcdpyTermTkDemos# Press CTRL-C to exit (CTRL-Break on Windows)# Showcase Demopython3demo/demo.py-f# run the ttkDesignerpython3-mttkDesigner# Text edit with "Pygments" highlight integrated# it require pygments#   pip install pygmentspython3tests/test.ui.018.TextEdit.Pygments.pyREADME.mdProjects usingpyTermTkttkDesigner- the officialpyTermTktool for designing and building Text-based user interfaces (TUIs)tlogg- A fast, advanced log explorer.ttkode- TerminalToolKit (Studio) Code (editor)pytest-fold- A Pytest plugin to make console output more manageable when there are multiple failed testspytest-tui- A Text User Interface (TUI) for Pytest, automatically launched after your test run is finishedbreakoutRL- Breakout the RoguelikeRelated ProjectsHonourable mentionbpytop- Linux/OSX/FreeBSD resource monitorThis was the base inspiration for my core libraryPythonurwid- Console user interface library for PythonpyTermGUI- A simple yet powerful TUI framework for your Python (3.7+) applicationsTextual- TUI (Text User Interface) framework for Python inspired by modern web developmentRich- Python library for rich text and beautiful formatting in the terminalPyCuT- terminal graphic library loosely based on QT api (my previous failed attempt)pyTooling.TerminalUI- A set of helpers to implement a text user interface (TUI) in a terminal.Non PythonTurbo Visionncursestui.el- An experimental text-based UI framework for Emacs modeled after React
Package: pyTermUI
TermUITermUI is a rapid development user interface library for python command-line applications.If you would like a reference for the library, D-Word is built on it. You can find it here:https://github.com/iiVeil/D-Word-Password-ManagerComplete documentation available athttps://pytermui.readthedocs.io/en/latest/Version 1.2All changelogs can be found in changelog.md on github
Package: pytermx
PyTermXPyTermX is a Python package for creating colorful text-based animations and effects in your terminal. It provides a variety of features to make your command-line applications more visually appealing.FeaturesText animation with color and style optionsCenter text in your terminalGradient text effectsHide and show the cursorEasy-to-use and customizableInstallationYou can install PyTermX viapip:pipinstallpytermxUsageHere is a simple example of how to use PyTermX in your Python code:frompytermximportAnim,Color,Center# Create an animated bannerbanner="Hello, PyTermX!"Anim.show_n_hide(banner,10)# Create centered textcentered_text=Center.center("This text is centered.")print(centered_text)# Apply a gradient effectgradient_text=Fade.in_blue("This text has a blue gradient.",255,0)print(gradient_text)CreditsMade with <3 by SekaFor questions or support, you can reach me on Discord: @sekateurAnd remember, cats are world! 🐱
Package: pyterrain
pyterrainA python package to fetch terrain.InstallationYou can install by pip$ pip install pyterrainUsageRegister API KeyPyterrain doesn't offer terrain data by itself, it fetches data from another website. Before downloading data, you should sign up an API key fromnextzen.org. The key's pattern is likeDto0r88DQuaQizoxcQSxxxFetch DEM by bound boxWhen API key is reday, you can download DEM data like this:bbox=108.444319,20.161757,111.318897,18.05883# Hainan province of Chinaterrain=Terrain("Dto0r88DQuaQizoxcQSxxx")# Pass API keyxs,ys,elevation=terrain.fetch(bbox=bbox,quiet=False,coord="lonlat",zoom=10)If download is not completed because of connection, retry it.
Package: pyterri
pyterriA simple python package for gettingterritorial.ioplayer and clan dataStill in early developmentInstallingpip install pyterriUsageCurrently only one function (getClans()) is provided (although more are on the way).
The below example gets data for every listed clan.frompyterriimportclanprint(clan.getClans())You can also pass a limit like so:frompyterriimportclanprint(clan.getClans(limit=10))This will list the top 10 clans.
Package: pyterrier-sentence-transformers
pyterrier_sentence_transformersA codebase derived onterrierteam/pyterrier_ancethat allows encoding using anysentence_transformersmodel.InstallationIf running faiss on CPU:pipinstallgit+https://github.com/soldni/pyterrier_sentence_transformers.git
condainstall-cpytorchfaiss-cpuelse, for gpu support:pipinstallgit+https://github.com/soldni/pyterrier_sentence_transformers.git
condainstall-cpytorchfaiss-gpucudatoolkit=11.3If you need to install faiss from scratch, seeinstructions here.RunningSee example inscripts/contriever_scifact.py.namemaprecip_rankP.10ndcg_cut.100BM250.6377990.6479410.0916670.6839041facebook/contriever-msmarco0.6413460.6538740.0916670.682851Note that the nDCG@10 we get for BM25 is much better than in thepaper: instead of66.5on row 0, we get '68.4'. The contriever result is also a bit better, with68.3instead of67.7. Not sure what kind of magic pyterrier is doing here 🤷.Note that, by default, this codebase uses exhaustive search when querying the dense index. This is not ideal for performance, but it is the setting contriever was evaluated on. If you want to switch to approximate search, you can do so by setting thefaiss_factory_configattribute ofSentenceTransformersRetriever/SentenceTransformersIndexerto any valid index factory string (or passfaiss_factory_config=to thecontriever_scifact.pyscript). I recommend checking outthe faiss docsfor more info on the various approximate search options; a good starting point is probablyHNSW:pythonscripts/contriever_scifact.py\faiss_factory_config='HNSW32'\per_call_size=1024This gets you close performance to the exact search:namemaprecip_rankP.10ndcg_cut.100BM250.6377990.6479410.0916670.6839041facebook/contriever-msmarco0.6295940.6421710.0900000.670841Note Note that sometimes you might have to increment the number of passages batch batch (per_call_size); this is because the approximate search gets trained using the first batch of passages, and the more passages you have, the better the search will be.In the example above, switching tofaiss_factory_config='HNSW64'gets you another point of accuracy in nDCG@10, but it will increase query time.
Package: py-tes
py-tespy-tesis a library for interacting with servers implementing theGA4GH Task Execution Schema.InstallAvailable onPyPI.pip install py-tesExampleimport tes

task = tes.Task(
    executors=[
        tes.Executor(
            image="alpine",
            command=["echo", "hello"]
        )
    ]
)

cli = tes.HTTPClient("http://funnel.example.com", timeout=5)
task_id = cli.create_task(task)
res = cli.get_task(task_id)
cli.cancel_task(task_id)
Package: pytescomobileirl
pytescomobileirlA Python API for accessing yourTesco Mobile Irelandaccount balance & usage stats. This is an unoffical API and the author/contributors are in no way connected to Tesco or Tesco Mobile. The API provides methods to:Get your current balances (€ credit and voice/text/data packages)Get your usage records as far back as is available.For an example of this in use, see myTesco Mobile BitBar pluginInstallationpip install pytescomobileirlUsageIt's very easy to use. Try the following to get your balance data:frompytescomobileirlimport*frompprintimportpprintsession=pytescomobileirl.TescoSession()session.login("<PhoneNumber>","<Password>")balances=session.get_balances()my_credit=balances.credit_remainingmy_data=balances.remaining_total("data")print(my_credit)print(my_data.summary())pprint(vars(my_data))returns:14.28939MB{'balance_expires':datetime.datetime(2017,10,15,0,0),'balance_type':u'data','is_active':True,'remaining_qty':939.181640625,'serviceCode':u'AB3','unit':'MByte'}Or to get your usage history enter:usage=session.get_usage()pprint(vars(usage.records[0]))returns:{'called_number':u'tescomobile.liffeytelecom.com','charge':u'0.0','country_code':None,'event_date':datetime.datetime(2017,9,23,13,33),'roaming':False,'service_code':u'GPBAS','service_name':u'GPRS Basic Service','unit':u'Bytes','use_type':u'DATA','volume':119896.0}Testspython ./tests/tests.pyContributingFork this repo, make some changes and create a new pull request!
Package: pytesdaq
pytesdaqpytesdaqcontains python data acquisition and data handling code for TES detector related R&D and dark matter searches.To install the most recent release ofpytesdaq, type the following line into your command linepip install pytesdaq --upgradeTo install the most recent development version ofpytesdaq, clone this repo, then from the top-level directory of the repo, type the following line into your command linepip install .If using a shared Python installation, you may want to add the--userflag to the above line.
Package: pyteseo
Package under development!pyTESEOis a python package developed byIHCantabriato simplify and facilitate the setup and processing ofTESEOsimulations(TESEO is a lagrangian numerical model also developed by IHCantabria.)💻 InstallationInstall pyTESEO library:Pip package manageris needed to install the library and
it is recommended to be installed from [IHCantabria/pyteseo](https://github.com/IHCantabria/pyteseo) repository:pipinstallgit+https://github.com/IHCantabria/pyteseoAlternatively, you can install it from pypi but you will need also install some direct dependencies     that are not publish in pipy repositories:pipinstallpyteseo# direct dependencies:pipinstall"datahub @ https://github.com/IHCantabria/datahub.client/archive/refs/tags/v0.9.4.zip"Install TESEO model binary (Not available yet!):Get access to the binary @ (https://github.com/IHCantabria/TESEO/blob/main/bin)Set up environment variable "TESEO_PATH" with the path to the model executable. You can use the   command following CLI command after activate the python environement (python-dotenv library)dotenvsetTESEO_PATH/path/to/teseo_executableOnline data providers require to stablish opendap connections, and in some cases aditional configurations:CMEMS productsrequires authentication. You should set up the environment variablesCMEMS_usernameandCMEMS_password.dotenvsetCMEMS_usernameyour_username_at_CMEMSdotenvsetCMEMS_passwordyour_password_at_CMEMSIHCantabria productsrequires connection to IHCantabria datahub API. You should set up the environment variableDATAHUB_API_URL.DATAHUB_API_URL="https://datahub.ihcantabria.com"✔️ TestsTests are located inpyteseo/tests/and data required for tests are located inpyteseo/tests/data/.
Tests have been developed usingpytest.Run tests to verify your package installation:pyteseo-test# Run tests and prompt pytest-report♻️ Continuous integration (CI)Build and deploy documentation on Github Pages in.github/workflows/docs.ymlInstall and test package in diferent environments in.github/workflows/tests.ymlPrecommit hooks for formats and linting in.pre-commit-config.yamlFor Linux, Windows, MacOS and compatible python versions defined in installation section📚 DocumentationDocumentation is available athttps://ihcantabria.github.io/pyteseo©️ CreditsDeveloped and maintained by 👨‍💻German Aragon@ 🏢IHCantabria.
Package: pytesimal
PytesimalPytesimal models the conductive cooling of planetesimals with temperature-dependent material properties.Pytesimal is a finite difference code to perform numerical models of a conductively cooling planetesimal, both with constant and temperature-dependent properties. It returns a thermal history of the planetesimal, and contains modules to estimate the timing and depth of pallasite meteorite genesis.FeaturesConstant or variable material propertiesChoose to return compressed.npzNumPy arrays of temperature and cooling rates through time and radiusPlot temperature or cooling rate heatmapsReturn timing of core solidification, and depth and timing of meteorite formationReturn a parameter.jsonfile with details of input parameters and resultsInstallationThis software relies on python (version 3.6 and up) and various other python packages. Examples are distributed as Jupyter notebooks, which need Jupyter and Matplotlib to run. Installation and management of all these dependencies is most easily done in a conda environment.conda create -n=pytesimal python=3.8 jupyter
conda activate pytesimal    
pip install pytesimalInstallation for developmentThe package can be downloaded and installed directly from Github for the most recent version. The software and its dependencies are best installed in a virtual environment of your choice. Download of the software and creation of an isolated conda environment can be done by running:git clone https://github.com/murphyqm/pytesimal.git
cd pytesimal
conda create -n=pytesimal python=3.8 jupyter
conda activate pytesimal
pip install -e .The-eflag installs the package in editable mode so that any changes
to modules can be carried through.Getting startedOpen up some examples onBinderor download some examples from our galleryhere.ContributeIssue Tracker:github.com/murphyqm/pytesimal/issueSource Code:github.com/murphyqm/pytesimalSupportIf you are having issues, please let us know.
You can email us ateememq@leeds.ac.ukLicenseThe project is licensed under the MIT license.
Package: pyteslable
PyTeslaBLEPython library for communicating with Tesla vehicles directly using the BLE API:bangbang:WARNING: This library is not supported by Tesla, and it could break at any moment. It should be noted that this library stores private keys and other sensitive data unencrypted on your machine. I am not responsible for any (extremely unlikely) damage done to your car.Usagepip install pyteslablefrompyteslableimportBLEtesla_ble=BLE("private_key.pem")print("Scanning for vehicles...")list=tesla_ble.scan()print(list)# Connect to a specific vehicle by BLE addressvehicle=list.getAddress("05:eb:6d:b7:f7:92")vehicle.connect()ifnotvehicle.isAdded():print("Tap your keycard on the center console")vehicle.whitelist()# Now we are ready to send commands!vehicle.unlock()Cryptography Library ModificationIf you have the latestcryptographylibrary, you will likely get an error about not supporting 4-bit nonces.
For now, the best solution I have is to simply modify the if statement that produces the error.CreditsHuge props to Lex Nastin for putting together some documentation for the Tesla BLE API. Check out the documentationhere.Also many thanks to Kevin Dewald from Neuralink for theBLE library!
Package: pytesmo
pytesmo, the Python Toolbox for the Evaluation of Soil Moisture Observations, is
a package/python toolbox which aims to provide a library that can be used for
the comparison and validation of geospatial time series datasets with a
(initial) focus on soil moisture.Documentation & Software CitationTo see the latestfull documentationclick on the docs badge at the top.If you use the software in a publication then please cite it using the Zenodo
DOI.  Be aware that this badge links to the latest package version.Please select your specific version athttps://doi.org/10.5281/zenodo.596422to
get the DOI of that version.  You should normally always use the DOI for the
specific version of your record in citations.  This is to ensure that other
researchers can access the exact research artefact you used for
reproducibility.You can find additional information regarding DOI versioning athttp://help.zenodo.org/#versioningIf you want to contribute, take a look at thedevelopers guide.InstallationThis package should be installable throughpipwhich downloads the package
from thepython package repository Pypi.
However, pytesmo also needs some packages that depend on C or Fortran libraries (likenetCDF4).
They should be installed first with conda or mamba. We recommend installingMambaforge.
Then the following command should install all dependencies:mambainstall-cconda-forgenumpyscipypandasnetCDF4cythonpyresampleAfterwardspytesmocan be installed via pip.pipinstallpytesmoAs an alternative (e.g. if you want to contribute to the package), you can
clone the Github repository and install from source:git clone https://github.com/TUW-GEO/pytesmo.git --recursive
cd pytesmo
mamba create -n pytesmo python=3.10 # or any supported python version
conda activate pytesmo
mamba env update -f environment.yml -n pytesmo
pip install -e .Supported ProductsSoil moisture is observed using different methods and instruments, in this
version several satellite datasets as well as in situ and reanalysis data are supported
through independent and optional (reader) packages:ERS & H-SAF ASCAT productsSMAPGLDAS NoahERA5 and ERA5-LandSMOSC3S SMESA CCI SMMERRAData from the International Soil Moisture Network (ISMN)In case of the ISMN, two different formats are provided:
An example of how to use the dataset in the pytesmo validation framework can be
found in the “Examples” chapter.
* Variables stored in separate files (CEOP formatted)Related PackagesSome former pytesmo modules are now provided as separate packages.pygeogrids: Creation and handling of Discrete Global Grids or Point collectionscadati: Calender, Date and Time functionsrepurpose: Time series - image conversion and resampling routinescolorella: Color maps and color map handlingContributeWe are happy if you want to contribute. Please raise an issue explaining what
is missing or if you find a bug. We will also gladly accept pull requests
against our master branch for new features or bug fixes.Please follow thedevelopers guide.
Package: pytessel
PyTesselPurposePython package for building isosurfaces from 3D scalar fieldsInstallationAnacondaconda install -c ifilot pyqintPyPipip install pytesselGetting startedIn the script below, the isosurface of a threedimensional Gaussian function is
constructed. The isosurface is written totest.plyand can, for example,
be opened usingctmviewer(Linux) or3D viewer(Windows).frompytesselimportPyTesselimportnumpyasnpdefmain():pytessel=PyTessel()# generate some datax=np.linspace(0,10,50)# the grid is organized with z the slowest moving index and x the fastest moving indexgrid=np.flipud(np.vstack(np.meshgrid(x,x,x,indexing='ij')).reshape(3,-1)).TR=[5,5,5]scalarfield=np.reshape(np.array([gaussian(r,R)forringrid]),(len(x),len(x),len(x)))unitcell=np.diag(np.ones(3)*10.0)vertices,normals,indices=pytessel.marching_cubes(scalarfield.flatten(),scalarfield.shape,unitcell.flatten(),0.1)pytessel.write_ply('test.ply',vertices,normals,indices)defgaussian(r,R):returnnp.exp(-(r-R).dot((r-R)))if__name__=='__main__':main()Isosurface qualityIn the script below, 6 different images are created of an icosahedral "metaball" using a grid
of10x10x10,20x20x20,25x25x25,50x50x50,100x100x100, and200x200x200points. The
resulting.plyfiles are rendered usingBlender.frompytesselimportPyTesselimportnumpyasnpdefmain():"""Build 6 .ply files of increasing quality"""pytessel=PyTessel()fornrpointsin[10,20,25,50,100,200]:sz=3x=np.linspace(-sz,sz,nrpoints)y=np.linspace(-sz,sz,nrpoints)z=np.linspace(-sz,sz,nrpoints)xx,yy,zz,field=icosahedron_field(x,y,z)unitcell=np.diag(np.ones(3)*sz*2)pytessel=PyTessel()isovalue=3.75vertices,normals,indices=pytessel.marching_cubes(field.flatten(),field.shape,unitcell.flatten(),isovalue)pytessel.write_ply('icosahedron_%03i.ply'%nrpoints,vertices,normals,indices)deficosahedron_field(x,y,z):"""Produce a scalar field for the icosahedral metaballs"""phi=(1+np.sqrt(5))/2vertices=[[0,1,phi],[0,-1,-phi],[0,1,-phi],[0,-1,phi],[1,phi,0],[-1,-phi,0],[1,-phi,0],[-1,phi,0],[phi,0,1],[-phi,0,-1],[phi,0,-1],[-phi,0,1]]xx,yy,zz=np.meshgrid(x,y,z)field=np.zeros_like(xx)forvinvertices:field+=f(xx,yy,zz,v[0],v[1],v[2])returnxx,yy,zz,fielddeff(x,y,z,X0,Y0,Z0):"""Single metaball function"""return1/((x-X0)**2+(y-Y0)**2+(z-Z0)**2)if__name__=='__main__':main()Local compilation (Linux)python3setup.pybuild_ext--inplacebdist
Package: pytesseract-api
pytesseract-apiTesseract C-API in python, a faster alternative to pytesseractInstallationYou can install the package via pip:pipinstallpytesseract-apiUsageimportcv2frompytesseract_apiimportimage_to_stringimg=cv2.imread("sample.png")text=image_to_string(img)print(text)LimitationsOnly supports opencv images as input as of nowLicenseThis project is licensed under the terms of the MIT license.ContactIf you want to contact me you can reach me atpradishbijukchhe@gmail.com.