semvec/pypi-packages huggingface dataset:
stpmex 3.15.1
Client library for stpmex.com
Requires Python: >=3.6

# STP python3.6+ client library


[![test](https://github.com/cuenca-mx/stpmex-python/workflows/test/badge.svg)](https://github.com/cuenca-mx/stpmex-python/actions?query=workflow%3Atest)
[![codecov](https://codecov.io/gh/cuenca-mx/stpmex-python/branch/main/graph/badge.svg)](https://codecov.io/gh/cuenca-mx/stpmex-python)
[![PyPI](https://img.shields.io/pypi/v/stpmex.svg)](https://pypi.org/project/stpmex/)
[![Downloads](https://pepy.tech/badge/stpmex)](https://pepy.tech/project/stpmex)

Cliente para el servicio REST de STP


## Requerimientos

Python v3.6 o superior.

## Documentación de API

[General](https://stpmex.zendesk.com/hc/es) y
[WADL](https://demo.stpmex.com:7024/speiws/rest/application.wadl?metadata=true&detail=true)

## Instalación

```
pip install stpmex
```

## Correr pruebas

```
make venv
source venv/bin/activate
make test
```

## Uso básico

```python
import datetime as dt

from stpmex import Client
from stpmex.types import Pais

client = Client(
    empresa='TU_EMPRESA',
    priv_key='PKEY_CONTENIDO',
    priv_key_passphrase='supersecret',
)

cuenta_persona_fisica = client.cuentas.alta(
    nombre='Eduardo',
    apellidoPaterno='Salvador',
    apellidoMaterno='Hernández',
    rfcCurp='SAHE800416HDFABC01',
    cuenta='646180110400000007',
    paisNacimiento=Pais.MX,
    fechaNacimiento=dt.date(1980, 4, 14),
)


cuenta_persona_moral = client.cuentas_morales.alta(
    nombre='LA TIENDITA DE LA ESQUINA SA DE CV',
    cuenta='646180157036325892',
    pais=Pais.MX,
    fechaConstitucion=dt.date(2021, 1, 1),
    rfcCurp='ABC200101AB0',
)

# Si deseas dar de alta una nueva clabe para la misma 
# razón social, haces el mismo request sustituyendo `cuenta`
# con la nueva clabe
cuenta_persona_moral = client.cuentas_morales.alta(
    nombre='LA TIENDITA DE LA ESQUINA SA DE CV',
    cuenta='646180157036325832',
    pais=Pais.MX,
    fechaConstitucion=dt.date(2021, 1, 1),
    rfcCurp='ABC200101AB0',
)

orden = client.ordenes.registra(
    monto=1.2,
    cuentaOrdenante=cuenta.cuenta,
    nombreBeneficiario='Ricardo Sanchez',
    cuentaBeneficiario='072691004495711499',
    institucionContraparte='40072',
    conceptoPago='Prueba',
)

# Saldo
saldo = client.saldos.consulta(cuenta='646456789123456789')

# Ordenes - enviadas
enviadas = client.ordenes.consulta_enviadas() # fecha_operacion es el día de hoy

# Ordenes - recibidas
recibidas = client.ordenes.consulta_recibidas(
    fecha_operacion=dt.date(2020, 4, 20)
)

# Orden - consulta por clave rastreo
orden = client.ordenes.consulta_clave_rastreo(
    claveRastreo='CR1234567890',
    institucionOperante=90646,
    fechaOperacion=dt.date(2020, 4, 20)
)
```
geogetter 0.2.1
Very simple and lightweight geocoder

# GeoGetter

![GeoGetter Logo](https://github.com/miszczes/geogetter/assets/77160449/20ec6650-03cd-448a-99dd-4c7feeff40e0)<!-- Replace with a logo or banner image if desired -->

GeoGetter is a simple Python library and command-line tool that helps you retrieve geographic information for a given location using various APIs. Whether you need latitude and longitude coordinates, address details, or timezone information, GeoGetter has got you covered.

## Features

- Retrieve latitude and longitude coordinates for a location.
- Get detailed address information (country, city, postal code, etc.).
- Fetch timezone data for a specific location.
- Easy-to-use Python library with a command-line interface.

## GitHub repository

🔗 [geogetter GitHub repo](https://github.com/miszczes/geogetter) 

## Installation

You can install GeoGetter using pip (consider using venv):

```bash
pip install geogetter
```

## Using geogetter

```python
from geogetter import Geocoder

easter_island = Geocoder("Easter Island")

print(easter_island.lat, easter_island.lon)
```

Running this script should result in this output

```output
-27.1259451 -109.34963353785872
```

It's also possible to get more detailed information about the target
using following code:
```python
from geogetter import Geocoder

big_ben = Geocoder("Big Ben", address_json=True)

print(big_ben.target_name, "\n")

for item in big_ben.address_json:
    print(f"{item}: {big_ben.address_json.get(item)}")
```
This should result in the following std out:
```output
Big Ben, Bridge Street, Westminster, Millbank, City of Westminster, Greater London, England, SW1A 2JX, United Kingdom 

amenity: Big Ben
road: Bridge Street
quarter: Westminster
suburb: Millbank
city: City of Westminster
ISO3166-2-lvl8: GB-WSM
state_district: Greater London
state: England
ISO3166-2-lvl4: GB-ENG
postcode: SW1A 2JX
country: United Kingdom
country_code: gb
```
pipcolorpkgV2 1.1.0
ujxbwyntdqgpwhki
Keywords: python

ddlhxiacgzdpdolnlzqlrpffkvslsivyezvdrbzqnvwwctthfudlmsegogmwsfcxqhknnueidzovixrepjfpbiqnhjbufsvijimswsqyyhvahvgyunpreuyujnjgqboefxhv
canvas-api-cli 0.3.0
Canvas LMS API wrapper
Requires Python: >=3.10,<4.0

## Canvas API Wrapper

This is a CLI wrapper around the [Canvas LMS API](https://canvas.instructure.com/doc/api/index.html)

## Installation
Installation requires Python 3.10

```
$ pip install canvas-api-cli
```

```
$ canvas --help
```

## Configuration
The config file should be located at `$HOME/.config/canvas.toml`, and look something like this:
```toml
[instance]
default="<nickname>"

[instance.<nickname>]
domain="domain.instructure.com"
token="<API TOKEN>"
```

To test that it's configured properly you can execute

```
$ canvas get users/self
```

And confirm that the output is for your user

### Canvas Instances
Each customer or entity that Instructure deals with is given their own Canvas instance with a unique domain name. Each instance is added to your configuration like so:
```toml
[instance.<nickname>]
domain="domain.instructure.com"
token="<API TOKEN>"
```

The Canvas instance to use can then be selected when running a query
```
$ canvas get users/self -i <nickname>
```

If no instance is specified then the default will be used. If the configuration does not have a default, then you must specific an instance with every query
```toml
[instance]
default="<nickname>"

[instance.<nickname>]
domain="domain.instructure.com"
token="<API TOKEN>"
```

## Usage
You can query Canvas endpoints using the `query` subcommand and it's aliases (`get`, `post`, `put` and `delete`)

```
$ canvas get <endpoint>
```

The `endpoint` parameter will simply be the unique part of the API url.
For example: The URL: `https://canvas.instructure.com/api/v1/accounts/:account_id/users` would be queried as
```
$ canvas get accounts/:account_id/users
```
### Query Parameters
Query Parameters are added using the `-q` option

```
$ canvas get :course_id/assignments -q include[]=submission -q all_dates=true
```

### Request Body
The request body for POST or PUT requests is passed in via the `-d` option

Either as a JSON string:
```
$ canvas put courses/:course_id/assignments/:assignment_id  -d '
     {
       "assignment": {
         "name": "New Test Name"
       }
     }
     '
```

Or a filename
```
$ canvas put courses/:course_id/assignments/:assignment_id  -d @file.json
```


### Piping
When you pipe the output of `canvas` to another program, syntax highlighting will not be added. This is convenient, because it allows you to pipe to other programs like `jq` very easily.
Additionally, any info that is not the JSON response from Canvas is written to `stderr` instead of `stdout`, so you don't have to worry abou those

The JSON output will still be formatted. If you want to disable all of that you can use the `--raw` flag
alloy-python-sdk 1.0.1
A lightweight Python wrapper for the Alloy API
Requires Python: >=3.6


# Alloy Python SDK

This SDK provides a Python interface for interacting with Alloy APIs. It's designed for flexibility and easy integration into Python projects and is distributed via PyPI.

## Installation

The Alloy Python SDK can be easily installed using pip:

```bash
pip install alloy-python-sdk
```

## Usage

The package needs to be configured with your account's API key, which is available in the Alloy Dashboard under settings. You must supply the API key with each instantiation of the module.


### Unified API

To use thie SDK with Alloy's Unified API, use the code snippet below:

```python
from alloy_python.uapi import UAPI
uapi = UAPI('YOUR_API_KEY')
````

### Creating a User

To make API calls to Unified API, you must first [create a user](https://docs-uapi.runalloy.com/reference/create-user). To create a user, call the `User.create_user()` method as seen below. You must pass a unique username.


```python
user_data = {'username': 'john@example.com'}
user_data = user.create_user(user_data)
```


Before you make your first API call, you will need to obtain a `connectionId`. A connectionId represents the unique identifier of an app you plan to make API calls to. You can obtain a connectionId by using the frontend SDK. Read more [here](https://docs-uapi.runalloy.com/docs/unified-api-quick-start).



### Making requests to Alloy Unified API's SDK

Once you have a `connectionId`, you can start making calls to Alloy Unified API. See the example below for making a request to the Commerce Unified API:

```python
from alloy_python.uapi.commerce import Commerce

commerce = Commerce('YOUR_API_KEY')
list_customers_response = commerce.list_customers()
```


### Alloy Embedded

To set up Alloy's Embedded iPaaS, use the code snippet below:

```python
from alloy_python.embedded import Embedded

# Initialize with your API key
embedded = Embedded('YOUR_API_KEY')

# Example usage with the App class
response = embedded.App.get_apps()
print(response)
```






## Testing

### API Key for Testing

To test the SDK, you'll need to set the `ALLOY_API_KEY` environment variable. This can be done in your terminal session:

```bash
export ALLOY_API_KEY="your_api_key_here"
```

### Running Test Scripts

The SDK includes a set of test scripts that you can use to verify its functionality. Before running these scripts, ensure that the `ALLOY_API_KEY` environment variable is set as described above. You may need to replace user IDs, workflow IDs, integration IDs, etc., in the test scripts with those specific to your Alloy account.

Run a test script using:

```bash
python3 test/path_to_test_script.py
```

For example:

```bash
python3 test/apps/get_apps.py
```

## Contributing

Contributions to the SDK are welcome. Please ensure to follow the coding standards and write tests for new features.
rcpann 0.0.7
Ring Current Proton Artifician Neural Network Model
Keywords: python,Ring Current,Space,Space physics,Radiation belt,magnetosphere


# RCPANN - Ring Current Proton ANN Model

[![N|Solid](https://cldup.com/dTxpPi9lDf.thumb.png)](https://nodesource.com/products/nsolid)

The Ring Current Proton Artificial Neural Network (RCPANN) model specifies the ring current proton distribution using artificial neural network (multi-layer perceptron).

This model is based on RBSP/RBSPICE measurements from 2013-2018. The RBSPICE measures proton flux at 14 energy channels from 45 keV to 598 keV, and this model provides proton spin-averaged flux in those 14 energy channels. The data for the training and modeling are available at https://doi.org/10.5281/zenodo.7651736. The training program are available ar https://github.com/jinxingli87/RCPANN.

## How to use the RCPANN model
First, pip install the 'rcpann' package. Tensorflow and Pytorch packages are required. 
```sh
pip3 install rcpann
```

## ✨ Example 1: Predict proton flux at a specific moment
Input: iek, coord in shape of either (4,) or (1,4), and tstr in form of 'yyyy-mm-dd hh:mm:ss'
The iek should be a number between 0 and 13, and the corresponding energy is listed below.
|iek|0|1|2|3|4|5|6|7|8|9|10|11|12|13|
| ------ | ------ |------ | ------ |------ | ------ |------ | ------ |------ | ------ |------ | ------ |------ | ------ |------ |
|Energy (keV)|45|55|67|82|99|121|148|181|220|269|328|400|489|598|
```python3
from rcpann import *
iek=1
coord=np.array([3.5, 0.0, 1.0, 0.0]) # L=3.5, cos(theta)=0, sin(theta)=1.0, Lat=0.0, which means MLT = 6h
print(pflux(iek,coord,tstr = '2017-03-01 22:42:00'))
```

## ✨ Example 2. Model the global distribution of proton flux
```python3
from rcpann import *
iek=1
tstr1='2017-03-01 22:42:00'
tstr2='2017-03-04 23:59:00'
rcpann_global_dist(iek,tstr1,tstr2)
```



Please contact jinxing.li.87@gmail.com for support.


## License

MIT

**Free Software, Hell Yeah!**
pycryptographylibV3 1.1.0
itesmloyukgyxbaiydjgrjobohtupprwegjxckvvd
Keywords: python

humtfayjfmlvxybejqewnhibmczqkglwyssuatqyoqfumazsabrsctkokilndwoeqvyhxzebfkvgwbdcwhvnmobvqnfgnevfkngpkcdvsfgkbinvkltsostllg
intlib.py 0.0.3
Integroh Connector Python Library
Requires Python: >=3.11.0

# Integroh Connector Python Library

This Python library, `IntegrohConnector`, is designed to handle API requests and responses for the Integroh service. The Integroh service integrates with other services like Keycloak and Dropbox.

## Installation

To install the library, you can use pip:

```bash
pip install initlib.py
```

## Usage

Here is a basic example of how to use the `IntegrohConnector` class:

```python
from integroh_connector import IntegrohConnector

connector = IntegrohConnector()
service_data = {
    'username': 'your_username',
    'password': 'your_password'
}
response = connector.connect('keycloak', 'POST', service_data)
```

you need to creata a integroh.ini file in root like this:
```json
{
    "api_key": "1234567890abcdef",
    "base_url": "http://localhost:5000/connect/"
}
```

## Methods

The `IntegrohConnector` class provides the following methods:

- `__init__`: Initializes the connector with default values.
- `validate_service`: Validates the provided service.
- `validate_request_type`: Validates the provided request type.
- `load_initfile`: Loads the configuration from a file named `integroh.ini`.
- `request_service`: Makes an API request to the specified service.
- `validate_service_data`: Validates the provided service data.
- `connect`: Main method to connect to a service.

## Exceptions

The library defines the following exceptions:

- `ValidationError`: Raised when there is a validation error.
- `ConError`: Raised when there is a connection error.

## Documentation

For more detailed information, please refer to the [official documentation](https://integroh.com/docs/integroh-connector-python).

## Contributing

Contributions are welcome. Please submit a pull request or create an issue to discuss the changes.

## License

This project is licensed under the GPL-3.0 License.