Saravanan666/pypi-org huggingface dataset:
Package: gpgLabs
[overview](#overview) | [launching the notebooks](#launching-the-notebooks) | [running the notebooks](#running-the-notebooks) | [issues](#issues) | [contributing](#for-contributors)# gpgLabs[![binder](http://mybinder.org/badge.svg)](https://mybinder.org/v2/gh/geoscixyz/gpgLabs/master?filepath=Notebooks%2Findex.ipynb)
[![travis](https://travis-ci.org/geoscixyz/gpgLabs.svg?branch=master)](https://travis-ci.org/geoscixyz/gpgLabs)
[![SimPEG](https://img.shields.io/badge/powered%20by-SimPEG-blue.svg)](http://simpeg.xyz)## OverviewThis is a repo of interactive examples forhttp://gpg.geosci.xyz.The notebooks are available on
- [Binder](https://mybinder.org/v2/gh/geoscixyz/gpgLabs/master?filepath=Notebooks%2Findex.ipynb)<!– <img src=”https://em.geosci.xyz/_images/DC_LayeredEarth_notebook.png” width=60% align=”center”>–>## Launching the notebooksThe notebooks can be run online through [Binder](#Binder), or [downloaded and run locally](#Locally).### Binder[![Binder](https://mybinder.org/badge.svg)](https://mybinder.org/v2/gh/geoscixyz/gpgLabs/master?filepath=Notebooks%2Findex.ipyn)Launch the binder by clicking on the badge above or going to:https://mybinder.org/v2/gh/geoscixyz/gpgLabs/master?filepath=Notebooks%2Findex.ipynb.
This can sometimes take a couple minutes, so be patient…Select the notebook of interest from the contents[Run the Jupyter notebook](#Running-the-notebooks)![Binder-steps](https://em.geosci.xyz/_images/binder-steps.png)### LocallyTo run them locally, you will need to have python installed, preferably through [anaconda](https://www.anaconda.com/download/).You can then clone this reposiroty. From a command line, run` git clonehttps://github.com/geoscixyz/gpgLabs.git`ThencdintogpgLabs` cd gpgLabs `To setup your software environment, we recommend you use the provided conda environment` conda env create-fenvironment.yml source activateem-apps-environment`alternatively, you can install dependencies through pypi` pip install-rrequirements.txt `You can then launch Jupyter` jupyter notebook `Jupyter will then launch in your web-browser.## Running the notebooksEach cell of code can be run withshift + enteror you can run the entire notebook by selectingcell,Run Allin the toolbar.![cell-run-all](https://em.geosci.xyz/_images/run_all_cells.png)For more information on running Jupyter notebooks, see the [Jupyter Documentation](https://jupyter.readthedocs.io/en/latest/)## IssuesIf you run into problems or bugs, please let us know by [creating an issue](https://github.com/geoscixyz/em-apps/issues/new) in this repository.## For Contributors### Notebook StructureEach notebook has the following structurePurpose: Motivation and key concepts addressed by the notebookSetup: Overview of the relevant parameters in the problemQuestions: Guiding questions related to the purposeApp: interactive visualizationsExplore: further questions that can be explored with the app### Setting up your environmentto develop code for these notebooks, please seehttps://github.com/geoscixyz/gpgLabsadd the notebook name and path to the [index](index.ipynb)
Package: gpglib2
GPGLib2This is a Python3 compatible fork of the gpglib library with support for AES
secret keys and the mdc packet types.HistoryBack in 2012 we couldn’t find a library for decrypting gpg that didn’t shell out
to gpg.And shelling out to gpg is slow when you do it for many small files.So, with the help ofhttp://pypi.python.org/pypi/OpenPGPand PyCrypto we created
this, which is more performant than shelling out.Then in 2017 a friend needed this library for a task, but the library wasn’t
compatible with python3. Unfortunately we couldn’t get write access back to the
original gpglib, so we have created a fork.ChangeLog0.5.1 - 8 January 2024Update pycryptodome0.5.0 - 2 December 2023Update to hatchlingNow supports python 3.8 to 3.12Changed to MIT license0.4.0 - 6 December 2020gpglib2 now only supports python3.6 and aboveFormatting and linting with black and pylamaUpgraded dependencies0.3.1 - 1 September 2018Update pycryptodome for CVE-2018-15560Remove use of a private method in pycryptodome when decrypting session keys0.3 - 4 August 2018Migrated from pycrypto to pycryptodome0.2.1 - 7 February 2018performance enhancement0.2 - 28 Jan 2018Fork and python3 compatibilityInstallingTo install, pip:$ python -m pip install gpglib2Or download from pypi:http://pypi.python.org/pypi/gpglib2.Or clone the git repo:https://github.com/delfick/gpglib2.Making test dataThis is what I did to get the data in tests/data.From within tests/data:$ gpg --full-gen-key --homedir ./gpg
# Once with RSA encrypt and sign, username Stephen and password "password25"
# And again with DSA/Elgamal, username Bobby and password "password25"Then find the keyid:$ gpg --homedir ./gpg --list-keys
  ------------------------------------------------------------------------
  pub   rsa2048 2018-08-03 [SC]
        F93E6E1B45D1C037B42650DE52320610E94B004B
  uid           [ultimate] Stephen <stephen@stephen.com>
  sub   rsa2048 2018-08-03 [E]

  pub   dsa2048 2018-08-03 [SC]
        A02F07AF335D3212FEB29C44FF5D18CBDBE4C62B
  uid           [ultimate] Bobby <bobby@bobby.com>
  sub   elg2048 2018-08-03 [E]

# Here, the key we want is "F93E6E1B45D1C037B42650DE52320610E94B004B"Then with that keyid export the secret and public keys for both the rsa and dsa keys:$ export KEY=F93E6E1B45D1C037B42650DE52320610E94B004B
$ gpg --export $KEY > keys/key.public.rsa.gpg
$ gpg --export-secret-key $KEY > keys/key.secret.rsa.gpgI then created dump.small and dump.big as random json structures (the big on is fromhttp://json.org/example.html).Then run./tests/data/generate_test_data.shto generate messages in thetests/encryptedfolder.Note that this is only necessary if you are editinggenerate_test_data.shto
accommodate different options. If you are doing this then you will also need
to do the same totests/test_decryption.pyto take the different data into
account.TestsRun:> ./test.shCurrently not much is tested.You may also use tox:> source run.sh activate
> toxDocsRun:> ./run.sh docs viewGenerated documentation is also available at:http://gpglib2.readthedocs.org/en/latest/
Package: gpglock
IntroductionA GPG based file lock.UsageInstallpip install gpglockSetupgpginit target_dirAdd files which need to be locked into the.gpglockintarget_dirLock/Unlockgpglock target_dirgpgunlock target_dirIftarget_diris not provided, the current working directory will be used.GPG ConfigurationMake sure the key is imported correctly.Make sure the key is trusted, otherwise you might seeInvalid Recipienterror.Rungpg --list-secret-keysto check the keys.
Package: gpgmailencrypt
# gpgmailencrypt
gpgmailencrypt can encrypt e-mails and check for spam and viruses.It supports
* PGP/Inline
* PGP/Mime
* S/Mime
* PDFFor spam checking it supports
* spamassassin
* bogofilterFor virus checking it supports
* avast
* bitdefender
* clamav
* drweb
* f-prot
* sophosIt can be used normally as a script doing everything on command line, in daemon mode, where gpgmailencrypt acts as an encrypting smtp server or as a module for programmers.It takes e-mails and  returns the e-mail encrypted to another e-mail server if a encryption key exists for the receiver. Otherwise it returns the e-mail unencrypted.
The encryption method can be selected per user.See gpgmailencrypt documentation.pdf for more info.(https://github.com/gpgmailencrypt/gpgmailencrypt/blob/master/documentation/gpgmailencrypt%20documentation.pdf)
Package: gpgmime
`python-gpgmime` is a library for manipulating PGP mime messages.It provides support for encrypting, decrypting, signing, and verifyingPGP mime email messages (RFC 3156). It's based partly on thecorresponding functionality in [alot][1], but the interface is built ontop of [python-gnupg][2]; It provides a subclass of that library's`GPG`, with some additional mime-related methods.This is in a very early stage of development; not everything works yet,and what does may still be rough around the edges.# LICENSEGPL, version 3 or later.# HACKINGGet set up:virtualenv .venvsource .venv/bin/activatepython setup.py developpip install -r test-requirements.txtRunning the test suite:py.testNotes on tests:* The folder `testing/gpghome` contains a keyring used by the testsuite, and there's a fixture defined in `testing/utils.py` thatsets up the library to use this keyring. Obviously, don't rely onthese keys for security; the private keys are published in a publicgit repository! The passphrases for the secret keys are as follows:* Alice: `secret`* Bob has no passphrase on his key (tsk tsk).* Mallory: `god`* Tests themselves go in `testing/tests`. Support code for tests goesin other modules under `testing/`.* `python-gnupg` is missing support for a couple of the new statusmessages introduced in gnupg2; these can cause erroneous testfailures. Some of these appear to be fixed in master, but still cropup in 0.3.7 on my machine.[1]: https://github.com/pazz/alot[2]: https://pythonhosted.org/python-gnupg/
Package: gpgodzilla
gpgodzilla - Large File Encryption with Line Modificationgpgodzillaenables developers and data scientists to encrypt and decrypt large and structured files while modifying them using whatever custom functions/methods they want, in memory. It is specifically designed for de-tokenization + encryption of sensitive data such as account numbers and social insurance numbers, where raw data is not allowed to live on the local storage of the system.Use CaseThe files that can be worked with should be structured on a line-by-line basis. For example, each line has some portions that need to be modified in the same way before encryption or after decryption.One primary example is for transferring and processing PANs. Provided is a file of customers' PANs that are tokenized. The requirement is to send the encrypted and de-tokenized PANs to the receiver.However, because PANs are highly sensitive, the de-tokenized/raw PANs cannot touch the local storage of the system. Hence, de-tokenization and encryption need to happen in system memory.RequirementsIt is essential to haveGnuPG 2installed on the system.Quick StartInstall via pip:pip install gpgodzillaBasic ExampleWith the file to manipulate on the local storage, define the path to the file and the path to the processed/manipulated file.The file to process must exist.Define the recipient of the encrypted file and the manipulation method for each line (ex. de-tokenization method that returns the de-tokenized line).fromgpgodzillaimportencrypt_large_file,decrypt_large_filedeftokenize_foo(line):# The example tokenization# replacing each "foo" with "bar" before encryptionline=line.replace('foo','bar')returnlinedefdetokenize_bar(line):# The example detokenization method# replacing each "some_token" with "cipher" before encryptionline=line.replace('bar','foo')returnline# The following code demonstrates a simple use casefile_to_encrypt='test.txt'# File to manipulate and encryptrecipient='john.doe@test.com'# Email of the recipient (GnuPG), which must exist on the system on which the code is runningoutput_file_encrypt='test.pgp'# path of the encrypted & manipulated fileoutput_file_decrypt='original_test.txt'# path of the decrypted fileencrypt_large_file(recipient,file_to_encrypt,output_file_encrypt,tokenize_foo)# then, to decrypt the file and detokenize each 'bar' back to 'foo':decrypt_large_file(output_file_encrypt,output_file_decrypt,detokenize_bar,PASSPHRASE)
Package: gpgraph
GPGraphGenotype-phenotype maps in NetworkXPort aGenotypePhenotypeMapto aNetworkX Digraph.Basic ExampleGPGraph follows NetworkX syntax. Initialize a graph, add the
genotype-phenotype map object, and draw the graph. This library even
comes with a draw method,draw_gpgraph, suited for genotype-phenotype graphs.fromgpmap.simulateimportMountFujiSimulationfromgpgraphimportGenotypePhenotypeGraphfromgpgraph.pyplotimportdraw_gpgraph,draw_edges# Simulate a genotype-phenotype mapsim=MountFujiSimulation.from_length(4,roughness_width=1)# Turn the genotype-phenotype map into a networkx objectG=GenotypePhenotypeGraph(sim)# Draw the graphfigure=draw_gpgraph(G,edge_colors='gray',node_size=400)InstallClone this repo and install withpip:pip install -e .To developClone this repo and runsetup.pyas followspython setup.py develop --userThis way, if only python scripts are being changed nothing has
to be reinstalled.
Package: gp-hashing
gp-hashingFirst Stable ReleaseDeveloped by Sayak Mukhopadhyay && Shouvik Bajpayee from Team GangPayee (c) 2021Example of How To Use (First Stable Version)Import the packagefromgp_hashing.generateHashimportgenerateHashGenerating Hashed Stringfromgp_hashing.generateHashimportgenerateHashnormal_string="a simple string"hashed_string=generateHash(normal_string)print(hashed_string)Outputg36kn49xi36kr64mt76ys63l36ke54cl45tp54cm37li36ks63l36ka16q
Package: gphoto2-cffi
Python bindings forlibgphoto2with an interface that strives to be
idiomatic. In contrast to other bindings for Python, gphoto2-cffi hides most
of the lower-level abstractions and reduces the API surface while still
offering access to most of the library’s features.importgphoto2cffiasgp# List all attached cameras that are supportedcams=gp.list_cameras()# Get a camera instance by specifying a USB bus and device numbermy_cam=gp.Camera(bus=4,device=1)# Get an instance for the first supported cameramy_cam=gp.Camera()# ormy_cam=next(gp.list_cameras())# Capture an image to the camera's RAM and get its dataimgdata=my_cam.capture()# Grab a preview from the camerapreviewdata=my_cam.get_preview()# Get a list of files on the camerafiles=tuple(my_cam.list_all_files())# Iterate over a file's contentwithopen("image.jpg","wb")asfp:forchunkinmy_cam.files[0].iter_data():fp.write(chunk)# Get a configuration valueimage_quality=my_cam.config['capturesettings']['imagequality'].value# Set a configuration valuemy_cam.config['capturesettings']['imagequality'].set("JPEG Fine")Python 2.7 and 3.4 or newer (CPython and PyPy) are supported.Requirementslibgphoto2 with development headersA working C compilercffiInstallationFrom Source:$ pip install git+https://github.com/jbaiter/gphoto2-cffi.gitSimilar projectspiggyphoto: Uses ctypespython-gphoto2: Uses SWIG
Package: gphotos-sync
Google Photos Sync (gphotos-sync)Google Photos Sync is a backup tool for your Google Photos cloud storage.PyPIpip installgphotos-syncSource codehttps://github.com/gilesknap/gphotos-syncDocumentationhttps://gilesknap.github.io/gphotos-syncReleaseshttps://github.com/gilesknap/gphotos-sync/releasesIntroGoogle Photos Sync downloads all photos and videos the user has uploaded to
Google Photos. It also organizes the media in the local file system using
album information. Additional Google Photos ‘Creations’ such as
animations, panoramas, movies, effects and collages are also backed up.This software is read only and never modifies your cloud library in any way,
so there is no risk of damaging your data.Warning: Google API IssuesThere are a number of long standing issues with the Google Photos API that mean it is not possible
to make a true backup of your media. In particular:Videos are transcoded to lower qualityRaw or Original photos are converted to ‘High Quality’GPS info is removed from photos metadataFor details of the Bugs reported to Google seehttps://github.com/gilesknap/gphotos-sync/issues/119.To join in a discussion on this issue seehttps://github.com/gilesknap/gphotos-sync/discussions/347.Quick StartTo get started seeTutorialSeehttps://gilesknap.github.io/gphotos-syncfor more detailed documentation.AlternativesFor a commercial product that backs up your library to the cloud see:
Seehttps://photovaultone.com/
Package: gpi
# GIMP Plugin Installer![Build Status](https://travis-ci.org/tschuy/gpi.svg)Install GIMP plugins from the command line with a simple, easy to use packagemanager.Usage-----Install from gpi-web:```$ gpi install imguruploader```Uninstall an installed package:```$ gpi uninstall imguruploader```Install from a locally downloaded file:```$ gpi install -f ~/imgur-uploader.tar.gz```Anatomy of a gpi package (aka how to package your plugin)---------------------------------------------------------The root level of a gpi package requires two things: a ``gpi.json`` manifestfile, and a ``contents/`` directory. The ``contents/`` directory will beextracted directly to the user's GIMP plugin directory, so make sure you onlyinclude files necessary for your plugin. You can put other content, like aLICENSE or CHANGELOG, in the root of the package. Files outside of ``contents/``will be ignored.Your ``gpi.json`` file should look like this:```{"version": "0.1.0","name": "Imgur Uploader","identifier": "imguruploader","author": "tschuy","license": "MIT","url": "https://github.com/tschuy/gimp-export-to-imgur","description": "Upload your images to Imgur directly from the Save menu"}```To test your plugin, pass your ``.tar.gz`` to gpi with the ``-f`` flag. OpenGIMP, and verify your plugin works as expected.Testing gpi-----------Currently, ``gpi`` has no tests. This is a major issue and will be rectified assoon as possible.Issues------1. Remove empty folders on uninstall2. Catch duplicate files and disallow uninstallation (or fix GIMP to allow recursive plugin finding)3. Install plugins from git4. Documentation5. Code cleanup6. Allow the use of a virtualenv to install packages from pip7. Add verbose mode
Package: gpib-ctypes
gpib-ctypesCross-platform Python bindings for the NI GPIB and linux-gpib C interfaces.Free software: GNU General Public License v2Documentation:https://gpib-ctypes.readthedocs.io.Featurescross-platform: tested on Microsoft Windows and LinuxAPI-compatible with the linux-gpib Python bindingsno Python dependencies except the standard libraryTestingCurrently tested with:
* NI GPIB-USB-HI, Microsoft Windows 7 32-bit, NI GPIB driver version 3.1.0.49154,
* NI GPIB-USB-HI, Arch Linux 64-bit current, linux-gpib 4.1.0More testers welcome with different hardware and OS configurations!CreditsThis package was created withCookiecutterand theaudreyr/cookiecutter-pypackageproject template.History0.3.0 (2018-12-13)Provide bindings to iblines through gpib.lines and Gpib.lines0.2.1 (2018-11-28)Fix gpib.ibfind string marshalling0.2.0 (2018-11-27)Safe cleanup using Gpib.close()0.1.1 (2018-11-27)Bugfix release0.1.0 (2018-01-01)First release on PyPI.
Package: gpib-devices
GPIB device driver library for python. A Generic IEEE 488 and
IEEE 4882 class for any GPIB device is subclassed in various
devices for different laboratory equipment devices.This library uses ctypes to directly access the GPIB library
from either linux-gpib (http://linux-gpib.sourceforge.net/) or
National Instruments. It also includes a pure Python driver for the NI Enet Ethernet-to-GPIB adapters.It does not yet mirror all functions from libgpib but tries to
exploit many of Python’s features that make GPIB programming
more fun.
Package: gpicalc
GPI CalculatorWelcome to GPI CalculatorA Package for Calculating Global Performance Indicator (GPI)Use the GPI Calculator to compute a comprehensive performance metric for your models.IntroductionThe GPI was introduced by Despotovic, et al. (2015) in their publication "Review and statistical analysis of different global solar radiation sunshine models". The motivation of creating the GPI was to combine multiple performance evaluation metrics into a single numerical representation for multi-dimensional and comprehensive comparison of different artificial intelligence/empirical models. The GPI metric has been cited and used in various articles such as:Chia, M.Y., Huang, Y.F. and Koo, C.H., 2021. Improving reference evapotranspiration estimation using novel inter-model ensemble approaches. Computers and Electronics in Agriculture, 187, p.106227.Chia, M.Y., Huang, Y.F. and Koo, C.H., 2022. Resolving data-hungry nature of machine learning reference evapotranspiration estimating models using inter-model ensembles with various data management schemes. Agricultural Water Management, 261, p.107343.InstallationpipinstallgpicalcExampleWe can import the test.xlsx supplied in the repository using the following lines:importpandasaspddata=pd.read_excel('test.xlsx',index_col=0)This will give you a DataFrame named "data" that has 3 columns (MAE, RMSE and R2) and 30 rows (30 different models).Next, import the "GPICalculator" class from thegpi packageto create a GPICalculator object.fromgpicalcimportGPICalculatorcalculator=GPICalculator()To obtain the GPI score, use the GPICalculator.score() method by including "data" and a list of coefficient as the parameters.coefficient=[1,1,-1]# Use positive coefficient for metrics to be minimised (MAE, RMSE), and negative coefficient for metrics to be maximized (R2)gpi_score=calculator.score(data,coefficient)# GPI is positive-oriented, the higher the betterSupportFor any suggestions or feedbacks, I will be available at this repository orchiamy94@gmail.com.
Package: gpilab
GPI stands forGraphicalProgrammingInterface which is a development environment for scientific algorithms that provides a visual workspace for assembling algorithms. Algorithm elements (i.e. nodes) can be linked together to form a flow diagram. Each node is executed according to the hierarchy of the diagram.WebsiteDocumentationIssuesInstallingPIPGPI is available on PyPI:$pipinstallgpilabGPI officially supports Python 3.7 to 3.9.Source$gitclonehttps://github.com/gpilab/framework.gitgpi
$cdgpi
$pipinstall-rrequirements.txtRunningIf you have installed GPI usingpipyou can run it as follows:$gpiIf you have install GPI from source you can run it as follows:$./bin/gpiCompiling PyFI filesYou will need to havefftwandeigento compile PyFI, you can get them by running the following command:$condainstallfftweigenFirst navigate to the directory with your PyFI files.If you have installed GPI usingpipyou can make PyFI as follows:$gpi_make--allIf you have install GPI from source you can run PyFI as follows:$./bin/gpi_make--all
Package: gpilot
A sample Python projectA sample project that exists as an aid to thePython Packaging User
Guide'sTutorial on Packaging and Distributing
Projects.This project does not aim to cover best practices for Python project
development as a whole. For example, it does not provide guidance or tool
recommendations for version control, documentation, or testing.The source for this project is available here.The metadata for a Python project is defined in thepyproject.tomlfile,
an example of which is included in this project. You should edit this file
accordingly to adapt this sample project to your needs.This is the README file for the project.The file should use UTF-8 encoding and can be written usingreStructuredTextormarkdownwith the appropriatekey set. It will be used to generate the project webpage on PyPI and will be
displayed as the project homepage on common code-hosting services, and should be
written for that purpose.Typical contents for this file would include an overview of the project, basic
usage examples, etc. Generally, including the project changelog in here is not a
good idea, although a simple “What's New” section for the most recent version
may be appropriate.
Package: gpio
Linuxsysfsgpio accessThis library provides gpio access via the standard linuxsysfs interfaceIt is intended to mimickRPIOas much as possible
for all features, while also supporting additional (and better named) functionality
to the same methods.Supported Featuresget pin values withread(pin)orinput(pin)set pin values withwrite(pin, value),set(pin, value)oroutput(pin, value)get the pin mode withmode(pin)set the pin mode withsetup(pin, mode)modecan currently equalgpio.INorgpio.OUTcreate aGPIOPinclass directly towriteandreada pinExamplesRPi.GPIO Drop-inGood for up to 130KHz pin toggle on a Pi 400.importtimeimportgpioasGPIOGPIO.setup(14,GPIO.OUT)whileTrue:GPIO.output(14,GPIO.HIGH)time.sleep(1.0)GPIO.output(14,GPIO.LOW)time.sleep(1.0)Use GPIOPin directlyGood for up to 160KHz pin toggle on a Pi 400.This gives you a class instance you can manipulate directly, eliminating the lookup:importgpiopin=gpio.GPIOPin(14,gpio.OUT)whileTrue:pin.write(14,GPIO.HIGH)time.sleep(1.0)pin.write(14,GPIO.LOW)time.sleep(1.0)