Saravanan666/pypi-org huggingface dataset:
Package: pypostelium
Hardware Telium Payment TerminalThis module adds support for credit card reader and checks printers
using theCaisse Concertprotocol. This module is designed to
be installed:either on thePOSbox(i.e. the proxy on which the USB devices are connected) and not on the main Odoo server.either aspywebdriverdependencyOn the main Odoo server, you should install the modulepos_payment_terminal.The configuration of the hardware is done in the configuration file of
the Odoo server of the POSbox. You should add the following entries in
the configuration file:payment_terminal_device_name (default = /dev/ttyACM0)payment_terminal_device_rate (default = 9600)The Caisse Concert protocol is used by many payment terminals in France
from different manufacturers (Ingenico, Sagem, Verifone). From our
experience, this protocol is only used in France.In France, Ingenico has the biggest market-share on payment terminals.
In France, Ingenico terminals are loaded with the Telium Manager
software stack which implements the Caisse Concert protocol natively.
This module implements the protocol E+ (and not the protocol E), so it
requires a Telium Managerversion 37783600or superior.To get the version of the Telium Manager on an Ingenico
terminal:press F > 0-TELIUM MANAGER > 2-Consultation > 4-Configuration
> 2-Software > 1-TERMINAL > On Display > Telium Managerand then read the fieldM20S.You will need to configure your payment terminal to accept commands
from the point of sale. On an Ingenico terminal:press F > 0-TELIUM MANAGER >
5-Initialization > 1-Parameters > Cash Connection and then select *On*
and then **USB** or **USB Base** according to used cable.After that, you should reboot the terminal (normally by clicking simultaneously on keysyellowand#).
This module has been successfully tested with:Ingenico EFTSmart4SIngenico EFTSmart2 2640 with Telim Manager version 37784503Ingenico iCT220Ingenico iCT250Ingenico i2200 cheque reader and writerThis module has been developped during a POS code sprint at Akretion
France from July 7th to July 10th 2014. This module is part of the POS
project of the Odoo Community Associationhttp://odoo-community.org/.
You are invited to become a member and/or get involved in the
Association !Installationsudo pip install git+https://github.com/akretion/pypostelium.git --upgradeChangelogVersion 0.0.5 dated 2021-10-17add get_status()add auto device detectionVersion 0.0.4 dated 2020-10-19transaction_start() now returns True (success) or False (failure)Version 0.0.3 dated 2020-05-18Python3 supportContributorsAlexis de Lattre <alexis.delattre@akretion.com>Sébastien BEAU <sebastien.beau@akretion.com>Sylvain Calador <sylvain.calador@akretion.com>
Package: py-postgresql
WarningIn v1.3,postgresql.driver.dbapi20.connectwill now raiseClientCannotConnectErrordirectly.
Exception traps around connect should still function, but the__context__attribute
on the error instance will beNonein the usual failure case as it is no longer
incorrectly chained. TrappingClientCannotConnectErrorahead ofErrorshould
allow both cases to co-exist in the event that data is being extracted from
theClientCannotConnectError.py-postgresql is a set of Python modules providing interfaces to various parts
of PostgreSQL. Primarily, it provides a pure-Python driver with some C optimizations for
querying a PostgreSQL database.http://github.com/python-postgres/feFeatures:Prepared Statement driven interfaces.Cluster tools for creating and controlling a cluster.Support for most PostgreSQL types: composites, arrays, numeric, lots more.COPY support.Sample PG-API Code:>>> import postgresql
>>> db = postgresql.open('pq://user:password@host:port/database')
>>> db.execute("CREATE TABLE emp (emp_first_name text, emp_last_name text, emp_salary numeric)")
>>> make_emp = db.prepare("INSERT INTO emp VALUES ($1, $2, $3)")
>>> make_emp("John", "Doe", "75,322")
>>> with db.xact():
...  make_emp("Jane", "Doe", "75,322")
...  make_emp("Edward", "Johnson", "82,744")
...There is a DB-API 2.0 module as well:postgresql.driver.dbapi20However, PG-API is recommended as it provides greater utility.Once installed, try out thepg_pythonconsole script:$ python3 -m postgresql.bin.pg_python -h localhost -p port -U theuser -d database_nameIf a successful connection is made to the remote host, it will provide a Python
console with the database connection bound to thedbname.
Package: py-postgresql-wrapper
PyPostgreSQLWrapperPyPostgreSQLWrapper is a simple adapter for PostgreSQL with connection poolingConfigurationThe configuration can be done throughJSONfile or byDictfollowing the pattern described below:{"database":"postgres","host":"localhost","max_connection":10,"password":"postgres","port":5432,"print_sql":true,"username":"postgres"}UsagePyPostgreSQLWrapper usage description:DeleteDelete with wherefrompy_postgresql_wrapper.databaseimportDatabasewithDatabase()asdatabase:database.delete('test').where('id',1).execute()Delete with like conditionfrompy_postgresql_wrapper.databaseimportDatabasewithDatabase()asdatabase:database.delete('test').where('description','Test%',operator='like').execute()Insertfrompy_postgresql_wrapper.databaseimportDatabasewithDatabase()asdatabase:database.insert('test').set('id',1).set('description','Test').execute()PagingPaging with wherefrompy_postgresql_wrapper.databaseimportDatabasewithDatabase()asdatabase:database.select('test').fields('id','description').where('id',3,operator='<').order_by('id').paging(0,2)Paging without wherefrompy_postgresql_wrapper.databaseimportDatabasewithDatabase()asdatabase:database.select('test').paging(0,2)SelectFetch allfrompy_postgresql_wrapper.databaseimportDatabasewithDatabase()asdatabase:database.select('test').execute().fetch_all()Fetch manyfrompy_postgresql_wrapper.databaseimportDatabasewithDatabase()asdatabase:database.select('test').execute().fetch_many(1)Fetch onefrompy_postgresql_wrapper.databaseimportDatabasewithDatabase()asdatabase:database.select('test').execute().fetch_one()Select by filefrompy_postgresql_wrapper.databaseimportDatabasewithDatabase()asdatabase:database.execute('find_test_by_id',{'id':1}).fetch_one()Select by queryfrompy_postgresql_wrapper.databaseimportDatabasewithDatabase()asdatabase:database.execute('select id, description from test where id =%(id)s',{'id':1}).fetch_one()SQLfrompy_postgresql_wrapper.databaseimportDatabasewithDatabase()asdatabase:database.execute('''create table test (id int primary key,description varchar(255))''')UpdateUpdate with wherefrompy_postgresql_wrapper.databaseimportDatabasewithDatabase()asdatabase:database.update('test').set('description','New Test 1').where('id',1).execute()Update with where allfrompy_postgresql_wrapper.databaseimportDatabasewithDatabase()asdatabase:database.update('test').set('description','New Test 1').where_all({'id':1,'description':'Test 1'}).execute()
Package: pypostgrestool
pgpoolInstallpip3 install pypostgrestool==0.1Usagefrom pg_client import PostgresDB
db = PostgresDB(host="127.0.0.1", port=5432, user='postgres',
                     password='123456', db_name=my-db', min_conn=10,
                     max_conn=100)
# search 
sql = "select * from my-tab"
print(db1.query_all(sql=sql))Singletondb1 = PostgresDB(host="127.0.0.1", port=5432, user='postgres',
                     password='123456', db_name=my-db', min_conn=10,
                     max_conn=100)
db2 = PostgresDB(host="127.0.0.1", port=5432, user='postgres',
                     password='123456', db_name=my-db', min_conn=10,
                     max_conn=100)
print(db1)
print(db2)
print(db1.pool)
print(db2.pool)
Package: pypostmodern
pypostmodernPrepare your Python code to the postmodernism era!This code:ifFalse:print('It'sthepostmodernismtime!')with pypostmodern the output will be:It's the postmodernism time!Postmodernist philosophers in general argue that truth is always contingent on historical and social context rather than being absolute and universal and that truth is always partial and "at issue" rather than being complete and certain.Postmodernism on WikipediaSo let's turn your Python to a Postmodern Python, where there is no truth...
Package: pypostscript
pypostscriptCreate A4 Portrait PostScript output with Python ObjectsVersion 0.1:Portrait A4 only
4 Font choices
TextLines
Code39Barcodes
Code93Barcodes
Circles
RectanglesUsageExample of usage:from pypostscript.barcode import Code39Barcode, Code93Barcode
from pypostscript.shapes import Circle, Rectangle
from pypostscript.text import HelveticaBoldFont, TextLine, TimesPlainFont
from pypostscript.page import Page


def sample_page():
    page = Page()
    page.extend(TextLine(x_pts=40,
                         y_pts=740,
                         font=HelveticaBoldFont(size_pts=22),
                         text='A Test Portrait Page'))
    page.extend(TextLine(x_pts=40,
                         y_pts=650,
                         font=TimesPlainFont(size_pts=12),
                         text='PostScript library, test portrait page.'))
    page.extend(Code39Barcode(x_pts=40,
                              y_pts=500,
                              chars='ABC123'))
    page.extend(Code93Barcode(x_pts=40,
                              y_pts=400,
                              chars='ABC987'))
    page.extend(Rectangle(x_pts=30,
                          y_pts=390,
                          width_pts=170,
                          height_pts=185,
                          line_width_pts=2))
    page.extend(Circle(centre_x_pts=80,
                       centre_y_pts=150,
                       radius_pts=72,
                       line_width_pts=1))
    return page

if __name__ == '__main__':
    page = sample_page()
    print page.render()
Package: pypotd-cli
PyPOTD CLIDescriptionUsing thepypotdlibrary, pypotd-cli is a command-line tool to generate single or multiple ARRIS/CommScope-compatible password-of-the-day strings using a default or custom seed. Output defaults to JSON. Output can be written to a file, and will not output to console unless also provided with the verbose flag.Installationpip install pypotd-cliUsageusage: python -m pypotd-cli [-d DATE] [-D] [-f {json,text}] [-h] [-o OUT_FILE] [-r START END] [-s SEED] [-v]

Password-of-the-Day Generator for ARRIS/CommScope Devices

options:
  -d DATE, --date DATE                  generate a password for the given date
  -D, --des                             output des representation of seed
  -f {json,text}, --format {json,text}  password output format, either text or json
  -h, --help                            show this help message and exit
  -o OUT_FILE, --out-file OUT_FILE      password or list will be written to given filename
  -r START END, --range START END       generate a list of passwords given start and end dates
  -s SEED, --seed SEED                  string of 4-8 characters, used in password generation to mutate output
  -v, --verbose                         print output to console even when writing to file

If your seed uses special characters, you must surround it with quotesExamplesPrint password for current day using custom seed$ python -m pypotd-cli -s test
{
  "09/27/23": "FP8992KBS5"
}Print DES for a custom seed$ python -m pypotd-cli -s test -D
{
  "DES": "CD.7D.DE.86.D7.04.4A.85"
}Write a list of passwords to a file and print to console$ python -m pypotd-cli -s test -r 2023-09-27 2023-09-30 -o range.json -v
{
  "09/27/23": "FP8992KBS5",
  "09/28/23": "JUSHXQ2S9O",
  "09/29/23": "9OTOUA0UI3",
  "09/30/23": "EDU83VUHE5"
}

$ cat ./range.json
{
  "09/27/23": "FP8992KBS5",
  "09/28/23": "JUSHXQ2S9O",
  "09/29/23": "9OTOUA0UI3",
  "09/30/23": "EDU83VUHE5"
}Previous example, but with formatted text output$ python -m pypotd-cli -s test -r 2023-09-27 2023-09-30 -o range.txt -v -f text
09/27/23: FP8992KBS5
09/28/23: JUSHXQ2S9O
09/29/23: 9OTOUA0UI3
09/30/23: EDU83VUHE5

$ cat ./range.txt
09/27/23: FP8992KBS5
09/28/23: JUSHXQ2S9O
09/29/23: 9OTOUA0UI3
09/30/23: EDU83VUHE5
Package: pypotlib
pypotlibPython bindings and ASE adapters forpotlib.DetailsThe library consists of thin wrappers topotlibundercpotand aPyPotLibCalcclass which is anasecalculator underase_adapters.InstallationThis ison PyPI, with wheels, so usage is simply:pipinstallpypotlibUsers are advised to not try to build from source, since the underlyingpotlibcode includesfortranandcppdependencies which can be slightly tricky to
work with.Local DevelopmentThe easiest way is to use the environment file, compatible withconda,mamba,micromambaetc.mambaenvcreate-fenvironment.yml
mambaactivatergpotpy
pdminstallProductionAs such, due to the compiled extensions and what not,cibuildwheelis used to
generatemacosandlinuxwheels. Locally this may be emulated (onlinux)
by:cibuildwheel--output-dirwheelhouse--platformlinuxUsage examplesThe simplest usage is just:importpypotlibaspplimportnumpyasnpljpot=ppl.cpot.LJPot()pos=np.array([1,2,3,1.2,2.3,3.6]).reshape(-1,3)atm_types=[0,0]cell_dim=np.eye(3)*50print(ljpot(pos,atm_types,cell_dim))For using the ASE calculator we need an instantiated class.fromaseimportAtomsfrompypotlibimportcpotfrompypotlib.ase_adaptersimportPyPotLibCalcatoms=Atoms(symbols=['Cu','H'],positions=[[0,0,0],[0.5,0.5,0.5]])calc=PyPotLibCalc(cpot.CuH2Pot())atoms.set_calculator(calc)print(atoms.get_potential_energy())print(atoms.get_forces())To run an NEB with this, consider the following toy example:fromaseimportAtomsfromase.nebimportNEBfromase.optimizeimportBFGSfrompypotlibimportcpotfrompypotlib.ase_adaptersimportPyPotLibCalcatoms_initial=Atoms(symbols=['H','H'],positions=[(0,0,0),(0,0,1)])atoms_final=Atoms(symbols=['H','H'],positions=[(0,0,2),(0,0,3)])images=[atoms_initial]images+=[atoms_initial.copy()foridxinrange(3)]images+=[atoms_final]forimageinimages:image.calc=PyPotLibCalc(cpot.LJPot())neb=NEB(images)neb.interpolate(method='idpp')optimizer=BFGS(neb)optimizer.run(fmax=0.04)ContributionsAll contributions are welcome, this includes code and documentation
contributions but also questions or other clarifications. Note that we expect
all contributors to follow ourCode of
Conduct.LicenseMIT.
Package: pypotree
PyPotree (potree for jupyter notebooks and colab)Allows to insert potree cells into jupyter and colab notebooksGabriele Facciolo, Gabriele Facciolo, CMLA 2019Try it on colab hereInstallation and dependenciesThe main source code repository for this project ishttps://github.com/cmla/pypotreeIt is written in Python and contains Potree and PotreeConverter. It was tested with Python 3.5 and 3.6.pypotreerequires C and C++ developement tools.pypotreecan be installed withpip:pip install pypotreeUsageIn a Python interpreter:>>> import pypotree 
>>> import numpy as np
>>> xyz = np.random.random((100000,3))
>>> cloudpath = pypotree.generate_cloud_for_display(xyz)
>>> pypotree.display_cloud_colab(cloudpath)
Package: pypowerprojects
PyPower ProjectsA Python Library for 5 GUI Projects : Gmail, Image & Audio Captcha, TicTacToe Game, Instagram Image Filters & Currency ConversionHow To Use :1. Install the library pypowerprojects : pip install pypowerprojects2. Go to python bash(command prompt) and execute the following commands :from pypowerprojects import gmailfrom pypowerprojects import captchafrom pypowerprojects import tictactoefrom pypowerprojects import currencyfrom pypowerprojects import instagram
Package: pypowerup
pypoweruppypowerupis the Python implementation for the research article "PowerUp!: A Tool for Calculating Minimum Detectable
Effect Sizes and Minimum Required Sample Sizes for Experimental and Quasi-experimental Design Studies (Dong & Maynard, 2013)". It is a
power analysis tool for experimental and quasi-experimental designs.ReferencesDong, N. & Maynard, R. A. (2013). PowerUp!: A tool for calculating minimum detectable
effect sizes and minimum required sample sizes for experimental and quasi- experimental design studies, Journal of Research on Educational Effectiveness, 6(1), 24-67. doi: 10.1080/19345747.2012.673143.https://www.causalevaluation.org/uploads/7/3/3/6/73366257/powerup.xlsmBulus, M., Dong, N., Kelcey, B., & Spybrook, J. (2019). PowerUpR: Power Analysis Tools for Multilevel Randomized Experiments. R package version 1.0.4.https://CRAN.R-project.org/package=PowerUpRHistory0.1.0 (2020-9-19)First release on PyPI.
Package: pypowerview
StatuspypowerviewPython3 interface implementation for Powerview HubNotesThis is for use withHome-AssistantUsagefrompypowerviewimportPowerView# Connect via IPpv=PowerView('192.168.1.50')# Return an array of shade objectsshades=pv.get_shades()# Return first shade in arrayshade=shades[0]# Return attributes of shadeprint(shade.id)print(shade.name)print(shade.position)# Position represented 0 (close) to 100 (open)# Update shade positionpv.get_status(shade)# Close shadepv.close_shade(shade)# Open Shadepv.open_shade(shade)# Stop shade in motionpv.stop_shade(shade)# Set shade to specific position (0 - 100)pv.set_shade_position(shade,55)
Package: pypowerworld
pypowerworld==== OVERVIEW ====pypowerworld provides a class as a user-friendly wrapper for the PowerWorld COM object. It initializes a class object with a loadflow case. If the case fails to open, the program does not error out but prints an error and proceeds without a case. The ‘open_case’ method may be used to attempt to open the PowerWorld case again.==== REQUIREMENTS ====pypowerworld requires COM which means it must be run on a Windows operating system. It also requires the user to have PowerWorld and SimAuto licenses. Any PowerWorld tools which require additional license are also necessary.==== INPUT ====The inputs are labeled similarly to the PowerWorld Auxiliary File documentation. The inputs can either be method parameters or attributes used to set data or get data from the PowerWorld program.==== OUPUT ====Data output is sent in dataframe format and set to the ‘output’ attribute. This is true only when the get data method is run. For all other operations, this attribute will be set to None.==== ERROR HANDLING ====If an error occurs, the ‘error’ attribute is set to True and the ‘error_message’ attribute is set to an error string value explaining the error. If an error is not encountered, the ‘error’ attribute is set to False and the ‘error_message’ is set to an empty string.==== TYPICAL IMPLEMENTATION ====from pypowerworld import PowerWorldcase_path = r'somepathsomecase.pwb'pw = PowerWorld(case_path)script_cmd = 'SolvePowerFlow(RECTNEWT);'if pw.run_script(script_cmd):print("The case was solved using the Newton-Raphson method.")else:print("Error encountered solving power flow: %s" % pw.error_message)
Package: pypownetr
# PowNet Refactored![license MIT](https://img.shields.io/github/license/kamal0013/PowNet)# PyPowNet: A Python Library for PowNet Model Optimization[PowNet](https://github.com/kamal0013/PowNet/) is a least-cost optimization model for simulating the Unit Commitment and Economic Dispatch of large-scale power systems.It has been applied to model Cambodian, Laotian, and Thai power systems.PyPowNetR improves the original implementation of PowNet and simplifies the model specification process.It aims to help researchers to import their own power system data on the PowNet model and and serve as a benchmark for optimization solvers.Ultimately, we hope that our effort will encourage more regions to adopt renewable energy sources in the power system.# RequirementsPyPowNetR is written in Python 3.6. It requires the following Python packages: (i) Pyomo, (ii) NumPy, and (iii) Pandas. It also requires an optimization solver (e.g. CPLEX).PyPowNetR has been tested in Anaconda on Windows 10.# How to runIf you have installed [glpk], this will execute the model using the data on Cambodian power system.The script also generates .csv files containing the values of each decision variable.# CitationIf you use PyPowNetR for your research, please cite the following papers (mainly from the original authors), which can be found in [this document](README_LONG.md)# LicensePyPowNetR is released under the MIT license.
Package: pypowsybl
PyPowSyBlThe PyPowSyBl project gives access PowSyBl Java framework to Python developers. This Python integration relies on
GraalVM to compile Java code to a native library.DocumentationLatest version of the documentation with API reference and many code samples ishere.NotebooksNotebooks demonstrating PyPowSyBl features can be found in thisrepository.InstallationPyPowSyBl is released onPyPifor Python 3.8 to 3.12, on Linux, Windows and MacOS.First, make sure you have an up-to-date version of pip and setuptools:pipinstall--upgradesetuptoolspipThen you can install PyPowSyBl using pip:pipinstallpypowsyblGetting startedFirst, we have to import pypowsybl:importpypowsyblasppWe can create an IEEE 14 buses network and run a load flow computation:n=pp.network.create_ieee14()results=pp.loadflow.run_ac(n)print(results)[ComponentResult(connected_component_num=0,synchronous_component_num=0,status=CONVERGED,status_text=CONVERGED,iteration_count=3,reference_bus_id='VL1_0',slack_bus_results=[SlackBusResult(id='VL1_0',active_power_mismatch=-0.006730108618313579)],distributed_active_power=0.0)]We can now get buses data (like any other network elements) as aPandasdataframe:buses=n.get_buses()print(buses)v_magv_angle
VL1_01.0600.00
VL2_01.045-4.98
VL3_01.010-12.72
VL4_01.019-10.33
VL5_01.020-8.78
VL6_01.070-14.22
VL7_01.062-13.37
VL8_01.090-13.36
VL9_01.056-14.94
VL10_01.051-15.10
VL11_01.057-14.79
VL12_01.055-15.07
VL13_01.050-15.16
VL14_01.036-16.04This is just a quick appetizer of PyPowSyBl features. PyPowsybl provides a lot more features:
security analysis, sensitivity analysis, handling of multiple file formats (including CGMES),
substation and network diagrams generation, ...
For more details and examples, go to the documentation and Jupyter notebooks.Build from sourcesThat section is intended for developers who wish to build pypowsybl from the sources in this repository.Requirements:Maven >= 3.1Cmake >= 3.14C++11 compilerPython >= 3.8 for Linux, Windows and MacOS (amd64 and arm64)Oracle GraalVM Java 17To build from sources and install PyPowSyBl package:gitclone--recursivehttps://github.com/powsybl/pypowsybl.gitexportJAVA_HOME=<pathtoGraalVM>
pipinstall--upgradesetuptoolspip
pipinstall-rrequirements.txt
pipinstall.While developing, you may find it convenient to use the developer (or editable)
mode of installation:pipinstall-e.# or, to build the C extension with debug symbols:pythonsetup.pybuild--debugdevelop--userPlease refer to pip and setuptools documentations for more information.To run unit tests:pytesttestsTo run static type checking withmypy:mypy-ppypowsyblTo run linting inspection withpylint:pylintpypowsyblContribute to documentationTo run the tests included in the documentation:cddocs/
makedoctestAnd then, to build the documentation:makehtmlWeb pages are generated in repository _build/html/ for preview before opening a pull request.
You can for example open it with firefox browser:firefox_build/html/index.html
Package: pypox
PypoxDescriptionPypox version 2 will replace its current version 1.5.+. although stable, it lacks the flexibility that current python application needed to scale big. we remove FastAPI system from the pypox version 2 for the reason that most of the features that FastAPI brings cant be properly implemented on pypox. that's why we now use pure starlette as a toolkit for implementing routing, middleware, etc.the main feature that Pypox version 2 will have is its modular system. from convention based lookup, file based routing, (new middleware based routing) for local and global scope. new processor to convert your data into usable parameters when dealing with request and response.FeaturesFile based routingProcessor based system.many moreInstallationThis is under development and will be published soon. stay tuned!UsageWe will provide example soon!!!