Skip to main content

A package I developed for my daily work.

Project description

wppkg logo

PyPI version PyPI total downloads GitHub release

wppkg is a package I developed for my daily work.

🔥About Me

Installation

Environment Setup

Step 1: Set up a python environment

We recommend creating a virtual Python environment with Anaconda:

  • Required version: python >= 3.10
conda create -n wppkg python=3.10
conda activate wppkg

Step 2: Install pytorch

Install PyTorch based on your system configuration. Refer to PyTorch installation instructions

For the exact command, for example:

  • You may choose any version to install, but make sure the PyTorch version is not too old.
  • We recommend torch ≥ 2.6.
# Installation Example: torch v2.8.0
# CUDA 12.6
pip install torch==2.8.0 torchvision==0.23.0 torchaudio==2.8.0 --index-url https://download.pytorch.org/whl/cu126
# CUDA 12.8
pip install torch==2.8.0 torchvision==0.23.0 torchaudio==2.8.0 --index-url https://download.pytorch.org/whl/cu128
# CUDA 12.9
pip install torch==2.8.0 torchvision==0.23.0 torchaudio==2.8.0 --index-url https://download.pytorch.org/whl/cu129

Step 3: Install deepspeed (optional)

Install DeepSpeed based on your system configuration. Refer to DeepSpeed installation instructions

For the exact command, for example:

pip install deepspeed

Step 4: Install wppkg and dependencies

To install wppkg, run:

pip install wppkg

Or install from github:

git clone https://github.com/Peg-Wu/wppkg
cd wppkg
pip install [-e] .

# w/o dependencies
pip install [-e] . --no-deps

Update wppkg

If you want to update all dependencies of wppkg except torch, you can run the following command:

pip install -U $(pip show wppkg | sed -n 's/^Requires: //p' | tr ',' ' ' | xargs -n1 | grep -vi '^torch$')

Trainer Tips

  • Early stopping does not currently support resuming training. If training is forcibly resumed, the early stopping callback will be reinitialized.
  • If you enable early stopping, ensure that eval_every_n_epochs and checkpointing_steps are aligned, as the Trainer does not automatically save the best model.
  • The final model is always saved at the end of training, even if early stopping is triggered.

Star History

Star History Chart

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

wppkg-0.1.3.tar.gz (4.0 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

wppkg-0.1.3-py3-none-any.whl (33.9 kB view details)

Uploaded Python 3

File details

Details for the file wppkg-0.1.3.tar.gz.

File metadata

  • Download URL: wppkg-0.1.3.tar.gz
  • Upload date:
  • Size: 4.0 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.8

File hashes

Hashes for wppkg-0.1.3.tar.gz
Algorithm Hash digest
SHA256 72b615a3996c5050919b16d5518e7681c104bc0c47215c61b19d160838ed0209
MD5 a68dcbf78030d9777cbfc2b5ad7061f5
BLAKE2b-256 b2b54bb1de9738415a9f85b6f9441c78b0ff024be005c1b25a8728abb97a89eb

See more details on using hashes here.

File details

Details for the file wppkg-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: wppkg-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 33.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.8

File hashes

Hashes for wppkg-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 c75243ace564ba2d833e2499f0053b7e77b79116ab41e0970b814854e7f88d74
MD5 398866359817c9b17a907ad45bc5f6d4
BLAKE2b-256 aa5e5cd2fbf4e474e43892e243b1f05f43d3cc5f91934d76d1e7ea190a52eb76

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page