🛠️ Welcome to Stouputils Documentation#

Versions: latest, v1.9.3, v1.9.2, v1.9.1, v1.9.0, v1.8.0, v1.7.3, v1.6.6, v1.5.4, v1.4.8, v1.3.23, v1.2.40, v1.0.22

🛠️ Project Badges#

GitHub PyPI - Downloads Documentation


📚 Project Overview#

Stouputils is a collection of utility modules designed to simplify and enhance the development process.
It includes a range of tools for tasks such as execution of doctests, display utilities, decorators, as well as context managers.

🔧 Installation#

pip install stouputils

Enable Tab Completion on Linux (Optional)#

For a better CLI experience, enable bash tab completion:

# Option 1: Using argcomplete's global activation
activate-global-python-argcomplete --user

# Option 2: Manual setup for bash
register-python-argcomplete stouputils >> ~/.bashrc
source ~/.bashrc

After enabling completion, you can use <TAB> to autocomplete commands:

stouputils <TAB>        # Shows: --version, -v, all_doctests, backup
stouputils all_<TAB>    # Completes to: all_doctests

Note: Tab completion works best in bash, zsh, Git Bash, or WSL on Windows.

🚀 Project File Tree#

stouputils/
├── applications/
│   ├── automatic_docs.py    # 📚 Documentation generation utilities (used to create this documentation)
│   ├── upscaler/            # 🔎 Image & Video upscaler (configurable)
│   └── ...
│
├── continuous_delivery/
│   ├── cd_utils.py          # 🔧 Utilities for continuous delivery
│   ├── github.py            # 📦 Utilities for continuous delivery on GitHub (upload_to_github)
│   ├── pypi.py              # 📦 Utilities for PyPI (pypi_full_routine)
│   ├── pyproject.py         # 📝 Utilities for reading, writing and managing pyproject.toml files
│   ├── stubs.py             # 📝 Utilities for generating stub files using stubgen
│   └── ...
│
├── data_science/
│   ├── config/              # ⚙️ Configuration utilities for data science
│   ├── dataset/             # 📊 Dataset handling (dataset, dataset_loader, grouping_strategy)
│   ├── data_processing/     # 🔄 Data processing utilities (image augmentation, preprocessing)
│   │   ├── image/           # 🖼️ Image processing techniques
│   │   └── ...
│   ├── models/              # 🧠 ML/DL model interfaces and implementations
│   │   ├── keras/           # 🤖 Keras model implementations
│   │   ├── keras_utils/     # 🛠️ Keras utilities (callbacks, losses, visualizations)
│   │   └── ...
│   ├── scripts/             # 📜 Data science scripts (augment, preprocess, routine)
│   ├── metric_utils.py      # 📏 Static methods for calculating various ML metrics
│   ├── mlflow_utils.py      # 📊 Utility functions for working with MLflow
│   └── ...
│
├── installer/
│   ├── common.py            # 🔧 Common functions used by the Linux and Windows installers modules
│   ├── downloader.py        # ⬇️ Functions for downloading and installing programs from URLs
│   ├── linux.py             # 🐧 Linux/macOS specific implementations for installation
│   ├── main.py              # 🚀 Core installation functions for installing programs from zip files or URLs
│   ├── windows.py           # 💻 Windows specific implementations for installation
│   └── ...
│
├── all_doctests.py          #  Run all doctests for all modules in a given directory
├── archive.py               # 📦 Functions for creating and managing archives
├── backup.py                # 💾 Utilities for backup management (delta backup, consolidate)
├── collections.py           # 🧰 Utilities for collection manipulation (unique_list, sort_dict_keys, upsert_in_dataframe, array_to_disk)
├── ctx.py                   # 🔇 Context managers (Muffle, LogToFile, MeasureTime, DoNothing)
├── decorators.py            # 🎯 Decorators (measure_time, handle_error, timeout, retry, simple_cache, abstract, deprecated, silent)
├── image.py                 # 🖼️ Little utilities for image processing (image_resize, auto_crop, numpy_to_gif, numpy_to_obj)
├── io.py                    # 💾 Utilities for file management (super_json, super_csv, super_copy, super_open, clean_path)
├── parallel.py              # 🔀 Utility functions for parallel processing (multiprocessing, multithreading)
├── print.py                 # 🖨️ Utility functions for printing messages with different levels of importance
└── ...

Star History#

Star History Chart

📖 Module Documentation#