semvec/pypi-packages huggingface dataset:
toopazo-ulg 0.0.24
Python package to process and plot Px4 .ulg files
Requires Python: >=3.6

# toopazo_ulg
This is the repository for the pip module ```https://pypi.org/project/toopazo-ulg/```

This is a simple python package that makes use of pyulog commands
(see https://github.com/PX4/pyulog ) to: parse, process and plot
Px4 .ulg log files ( see https://github.com/PX4/Firmware )


## How it works
It needs three folders: logs, tmp and plots (names are hardcoded).
It works by taking all .ulg files from the logs folder and then using
ulog2csv to writing the resulting .csv files in the tmp folder.
It finally writes all results in the plots folder.

## Dependencies
Install dependencies running pip as a module
```
 python3 -m pip install -U matplotlib
 python3 -m pip install -U numpy
 python3 -m pip install -U scipy
 python3 -m pip install -U toopazo_tools
```

## Usage
```
user@host: ls
logs tmp plots
user@host: python -m toopazo_ulg.plot_main --bdir tests/
```

## How to update a new version to https://pypi.org/  

This is note to myself about the necessary steps to upload a new version 
of the code to the repo in https://pypi.org/.

I wrote a bash file to automate the update and uploading process to pypi. 
It is can be executed in the terminal using

```
. ./update_library.sh
```

The steps involved are taken from https://widdowquinn.github.io/coding/update-pypi-package/

1. Update local packages for distribution
    ```
    python3 -m pip install --user --upgrade setuptools wheel
    python3 -m pip install --user --upgrade twine 
    ```
2. Open setup.py and change the version, e.g., version='1.0.3'. 
   This can be done automatically by running 
   ```
   python increment_setup_version.py
   ```
3. It is sometimes neccessary to delete the build/ and dist/ folder
    ```
    rm -r build/*
    rm -r dist/*
    ```
4. Create distribution packages on your local machine, and check
the dist/ directory for the new version files
    ```
    python3 setup.py sdist bdist_wheel
    ```
5. Upload the distribution files to https://pypi.org/ server
    ```
    python3 -m twine upload dist/*
    ```
6. Install the package from https://pypi.org/ server
    ```
    python3 -m pip install -U toopazo-tools
    ```