semvec/pypi-packages huggingface dataset:
mysqldave-package 2.1.0
A wrapper for simplified Postgres usage using mysql.connector.
Requires Python: >=3.7

# mysqldave

A wrapper for simplified MySQL access

### install with pip
pip install mysqldave_package

### command line test
py -m mysqldave_package.mysqldave

### Quick Start Guide
https://github.com/daveskura/mysqldave/blob/main/QuickStart.md

### Methods
https://github.com/daveskura/mysqldave/blob/main/methods.md
tplot 0.3.6
Create text-based graphs
Requires Python: >=3.8,<4

# tplot

[![Documentation status](https://readthedocs.org/projects/tplot/badge/)](https://tplot.readthedocs.io/en/latest/)
[![Tests status](https://github.com/JeroenDelcour/tplot/actions/workflows/tests.yml/badge.svg)](https://github.com/JeroenDelcour/tplot/actions/workflows/tests.yml)
[![codecov](https://codecov.io/gh/JeroenDelcour/tplot/branch/master/graph/badge.svg?token=WXH7I3BGEO)](https://codecov.io/gh/JeroenDelcour/tplot)

[![Supported Python versions](https://img.shields.io/pypi/pyversions/tplot)](https://pypi.org/project/tplot/)
[![PyPI version](https://img.shields.io/pypi/v/tplot)](https://pypi.org/project/tplot/)
[![License](https://img.shields.io/github/license/jeroendelcour/tplot)](https://github.com/JeroenDelcour/tplot/blob/master/LICENSE)

`tplot` is a Python package for creating text-based graphs. Useful for visualizing data to the terminal or log files.

## Features

- Scatter plots, line plots, horizontal/vertical bar plots, and image plots
- Supports numerical and categorical data
- Legend
- Unicode characters (with automatic ascii fallback)
- Colors
- Few dependencies
- Fast and lightweight
- Doesn't take over your terminal (only prints strings)

## Installation

`tplot` is available on [PyPi](https://pypi.org/project/tplot/):

```bash
pip install tplot
```

## Documentation

Documentation is available on [readthedocs](https://tplot.readthedocs.io/en/latest/).

## Examples

### Basic usage

```python
import tplot

fig = tplot.Figure()
fig.scatter([0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10])
fig.show()
```

![Basic example](docs/images/basic.png)

### A more advanced example

```python
import tplot
import numpy as np

x = np.linspace(start=0, stop=np.pi*3, num=80)

fig = tplot.Figure(
    xlabel="Phase",
    ylabel="Amplitude",
    title="Trigonometric functions",
    legendloc="bottomleft",
    width=60,
    height=15,
)
fig.line(x, y=np.sin(x), color="red", label="sin(x)")
fig.line(x, y=np.cos(x), color="blue", label="cos(x)")
fig.show()
```

![Advanced example](docs/images/advanced.png)

See more examples in the [documentation](https://tplot.readthedocs.io/en/latest/).

## Contributing

Contributions are welcome. Bug fixes, feature suggestions, documentation improvements etc. can be contributed via [issues](https://github.com/JeroenDelcour/tplot/issues) and/or [pull requests](https://github.com/JeroenDelcour/tplot/pulls).
mappings-utility 0.2.5
mapping utility tool for sdmx based partial mappings
Requires Python: >=3.9,<4.0

An SDMX mapping utility to generate partial key maps for referential metadata.
Although not designed to do that, data mappings are also possible.
The package is structured in such a way that it can be used as a package without the FASTAPI overhead.

Three methods are available:
- *map_withFile* GET method (receiving the mapping source and mapping rules both as file references)
- *map_withURN* GET method (receiving the mapping source  as file and the mapping rules as SDMX registry endpoint + mapping ID)
- *map_json_withURN* POST method (receiving the mapping source as the body of the request in json - pandas dataframe dictionary style - and mapping rules as SDMX registry endpoint + mapping ID) (added in version 0.1.1)

A typical usage example in package mode:

```python
    from mappings_utility.sdmx_mapping_utility import SDMXMappingUtility 
    
    mf = Path('to-mapping-artefacts.xml')
    sf = Path('to-file-to-be-mapped.csv')
    mu = SDMXMappingUtility.initialise_with_file(mf, sf, sid_based=False)
    df = mu.generate_mappings_partial_keys(
        includeSourceColumns=False,
        includeAttributesMeasures=False,
        nulledFixedTargets=True,
        writeTargetStructInfo=False,
        dropInvalid=False,
        sid_based=False
        )
    df.to_csv(Path('mapped-file.csv'), index=False)
```
The parameters fine-tune the output file:
- includeSourceColumns: True/False; when set to True the resulting file would include the fields of the source csv file  
- includeAttributesMeasures: True/False; when True it will include the attribute columns and obs_value, otherwise it will suppress those from the output (this is needed for referential metadata partial key mappings)
- nulledFixedTargets: True/False, when True fixed values in the target mapping will be set to Null, also a partial-key mapping motivated feature
- writeTargetStructInfo: True/False, when True it adds or maps columns necessary for the output to be SDMX-CSV compliant
- dropInvalid: True/False, when set to True the output only contains valid mappings (although validity checks are lazy), invalid rows are ommitted; with False the returned dataframe will contain cells with a special string highlighting the positions where the target value could not be determined
- sid_based: True/False, when set to True the resulting file will contain a Series ID (SID) field with the dimensions of the target data model dot-concatenated

# Changelog:
- Version 0.2.3
Introduced validation for implicit maps (target codes are checked whether they are in the referenced codelist - constraints are not yet taken into account)
- Version 0.2.4
Bug-fix for regex substitution (previously substitutions with more than one substitution failed)
- Version 0.2.5
    - Attributes scaffolding for future features (validates coded attributes)
    - Bug-fix for optional attributes missing when all values are null
sqpy 0.0.3
A Python package for interactive slurm squeue
Requires Python: >=3.8

# Description
This project is a Python-based terminal application designed for managing and interacting with SLURM jobs. It provides a user-friendly interface to view, navigate, and manage SLURM job queues using a curses based graphical interface. Features include viewing job details, cancelling jobs, and refreshing job lists, all through a convenient text-based interface.

The program leverages Python's curses library for the terminal UI, subprocess for interacting with SLURM commands, and follows object-oriented programming principles for modular and maintainable code.

# Features
View SLURM job queues in a structured, table-like format.
Navigate through the job list with keyboard controls.
Cancel jobs with a confirmation dialog.
Refresh job list dynamically.
Popup windows for displaying messages and confirmations.

## Installation
To install this application, you can use the following command:

```bash
pip install sqpy
```

## Usage
After installation, the application can be launched by running its command in the terminal:


## Keyboard Controls:
UP ARROW: Move up in the job list.
DOWN ARROW: Move down in the job list.
Ctrl + K: Open the cancel job dialog for the selected job.
Ctrl + R: Refresh the job list.
Q: Quit the application.

## Dependencies
Python 3.6 or higher

## Contributing
Contributions to this project are welcome! To contribute, please follow these steps:

## Fork the repository.
Create a new branch for your feature.
Add your changes and commit them.
Push to your branch and submit a pull request.

## License
This project is licensed under the GPL3 - see the LICENSE file for details.
dbuilder-hfss 0.0.1
Ansys interface for Data Generation
Requires Python: >=3.7

# Ansys HFSS Interface
## _Simulate, data generation, optimization_

This development is intended to provide an interface to access HFSS, in order to automate simulation, Data generation and optimization processes.

## Features

- Automate the re-creation of models in aedt files.
- Create intermediate files to run simulations.
- Run simulations and gather specific metrics from the simulator.

## Usage
```
from dbuilder import Manager as MG
```


```
Builder=MG.Builder(ansysPath=ansysPath,modelName=_,projectName=_, designName=_,modelPath=_, exportPath=_)
```

```
Builder.create()
```

```
Builder.sim_file('', batch, iteration, simfile_path, **kwargs)
```


```    
Builder.simulate(simfile_path+simfileName)
```

```
dbManager=MG.DBManager(ansysPath=ansysPath,
                       modelName=modelName,
                       projectName=project_name,
                       designName=designName,
                       modelPath=modelPath, 
                       dbPath=dBPath,
                      dbName=dbName)
```

```
dbManager.load_df(columns=columnNames)


"""This object can be treated as a pandas dataframe"""
dbManager.df 

```

```
dbManager.insert_row(data_to_store)
```

```
image_rgb=tools.cropImage( file,image_path=path,
                              image_name=fileName_absolute,
                              output_path=imagesPath, 
                             resize_dim=(512,512))
```
aws-secrets 0.1.10
Python library for resolving secrets from AWS Secrets Manager
Requires Python: >=3.7

AWS Secrets
-----------

This library allows you to use credentials stored in AWS Secrets Manager within
your code. It will lazily resolve secret values when they are evaluated, or resolve
all secrets when AWSCredential.resolve_secrets() is called.

Usage
=====

.. code-block:: python

    from aws_secrets import AWSCredential
    db = AWSCredential('path/to/key')

    # credential is resolved here
    print(db['username'])

    secret_one = AWSCredential('path/to/key_one')
    secret_two = AWSCredential('path/to/key_one')

    # both credentials are resolved here
    AWSCredential.resolve_secrets()
    print(secret_one)
    print(secret_two)
fts-rtmidi 0.0.6
A simple class for sending MIDI messages
Requires Python: >=3.12

# fts-rtmidi
My name is Ferdinand Tonby-Strandborg, and I am creating this library as I want an easy, quick class for sending midi messages.

## Installation
Available on [PyPi](https://pypi.org/project/fts-rtmidi/)
```bash
pip install fts-rtmidi
```


## Usage
To check what MIDI ports are available, use the ***rtmidi*** library. To send messages, use the ***ftsmidi*** library.
```python
from rtmidi  import MidiOut
from ftsmidi import MidiSender
from time    import sleep

## Print available MIDI channels using rtmidi class
print(MidiOut().get_ports())


## Connect to MIDI channel "Microsoft GS Wavetable Synth 0"
midi = MidiSender("Microsoft GS Wavetable Synth 0")


## Trigger note middle-C with velocity 120 for 1 second
midi.note_on(60, 120)
sleep(1)
midi.note_off(60)

```

## MIDI protocol
For an in-depth explanation of the MIDI format, please see: https://www.cs.cmu.edu/~music/cmsip/readings/davids-midi-spec.htm

## Note on implementation
A lot of the functions are implemented in a way that is unnecessarily hard to read. This is simply as I wanted to test features of Python I haven't used before.

# rtmidi
This uses the **python-rtmidi** library, which is currently available through pypi. All classes here simply wrap the rtmidi classes, and handle formatting the messages.
<br>To learn more about RtMidi, visit their [PyPi](https://pypi.org/project/python-rtmidi/) page or their [GitHub repository](https://github.com/SpotlightKid/python-rtmidi).
calendar-cleanup 0.3.1
CLI utility to unclutter old calendar entries from WebDAV calendars.
Requires Python: >=3.11,<4.0

# Calendar Cleanup

CLI utility to unclutter WebDAV calendars by deleting old entries.

## Installation

```bash
pip install calendar-cleanup
```

## Usage example

```bash
$ calendar-cleanup

Please enter the credentials for your WebDAV calendar.

username: john.doe
password:
Calendar URL:

Verifying authentication...
Authentication successful.

Reading WebDAV files content...
Loaded content from 25 WebDAV files.

Parsing ICS content...
Successfully parsed 22 of 25 ICS files.

Found 2 events for deletion.

Events that can be deleted:
- 2023-11-14: Lorem ipsum
- 2023-11-16: Lorem ipsum follow-up

Delete listed events? [y/N]
Deletion not confirmed. Exiting.
```

## CLI documentation

```
Usage: calendar-cleanup [OPTIONS]

CLI utility to unclutter WebDAV calendars by deleting old entries.

The CLI tools proposes which old entries to remove. If the user approves,
the events get deleted.

Options:
-d, --days INTEGER  Number of days into past from which on to delete events.
                    [default: 30]
-v, --verbose       Enable detailed output.
--help              Show this message and exit.
```