Skip to content

Releases: esa/torchquad

torchquad v0.5.0

03 Aug 19:04

Choose a tag to compare

torchquad 0.5.0 Release Notes

We are excited to announce the release of torchquad 0.5.0! This release includes significant structural improvements, enhanced GPU support, better documentation, and improved testing infrastructure.

Major Changes

🏗️ Project Structure Modernization

  • Migrated to pyproject.toml: Transitioned from setup.py to modern Python packaging standards with pyproject.toml configuration (#223)
  • Test Suite Restructuring: Moved all tests from torchquad/tests/ to root-level tests/ directory, following Python best practices (#218)
  • Code Formatting: Standardized code formatting with Black using 100-character line length across the entire codebase

🖥️ Enhanced GPU Support & Backend Management

  • Improved GPU Selection: Enhanced GPU device selection and management with better error handling and user guidance (#222)
  • Backend Precision Control: Significant improvements to the set_precision utility with better backend compatibility and GPU memory management
  • CUDA Integration: Fixed and improved PyTorch CUDA integration for more reliable GPU acceleration

📚 Documentation Enhancements

  • Parametric Integration Guide: Added comprehensive documentation for parametrizing integration domains with practical examples (#219)
  • GPU Usage Tutorial: Extensive documentation covering GPU setup, device selection, and optimization tips
  • CI/CD Documentation: Added detailed documentation about the continuous integration and deployment processes

🔧 Improved Logging & Debugging

  • Release-Friendly Logging: Implemented conditional logging that can be disabled for production releases while maintaining verbose output for development (#221)
  • Better Warning Management: Enhanced warning filtering and management throughout the codebase
  • Loguru Integration: Improved integration with the loguru logging framework for better debugging experience

Minor Changes

🧪 Testing Infrastructure

  • Expanded Test Suite: Added comprehensive tests for deployment scripts and RNG functionality (#224)
  • Additional Test Functions: Introduced new challenging test functions for better convergence testing
  • CI Warning Filtering: Implemented systematic filtering of known warnings in CI to reduce noise
  • Better Test Organization: Cleaned up test imports and reduced code duplication across test files

📊 Benchmarking Improvements

  • Enhanced Benchmarks: Reworked benchmarking system with better scaling analysis and framework comparisons (#220)
  • Analytical Ground Truths: Added analytical reference values for more accurate convergence testing
  • Updated Performance Visualizations: Refreshed benchmark plots and scaling analysis charts

🔍 Code Quality

  • Code Formatting: Applied consistent formatting using Black with flake8 compliance
  • Better Error Messages: Enhanced error handling with more informative exception messages

Bugfixes

🐛 Integration & Numerical Fixes

  • Gaussian Integration: Fixed edge cases in Gaussian quadrature with improved error margins
  • VEGAS Algorithm: Resolved issues with VEGAS map updates and stratification
  • Grid Integration: Fixed coordinate transformation bugs in grid-based methods
  • Memory Management: Improved GPU memory cleanup and garbage collection

🔧 Backend Compatibility

  • Multi-Backend Support: Fixed compatibility issues across PyTorch, JAX, TensorFlow, and NumPy backends
  • Precision Handling: Resolved dtype conversion issues when switching between different numerical precisions
  • Device Management: Fixed GPU device selection and fallback behavior for systems without CUDA

📦 Packaging & Deployment

  • Setup Script: Fixed setup.py configuration issues for proper package installation
  • Dependencies: Updated and validated all package dependencies for compatibility
  • CI/CD Pipeline: Resolved deployment issues to PyPI and TestPyPI

Migration Guide

For Users Upgrading from 0.4.x

  1. No Breaking API Changes: All public APIs remain backward compatible
  2. Improved GPU Setup: The GPU selection process is now more robust - you may see improved performance if you were experiencing GPU-related issues
  3. Better Logging: If you were relying on specific log messages, note that some logging behavior has been refined
  4. Enhanced Documentation: Check out the new parametric integration guide for advanced use cases

For Contributors

  1. Test Location: Tests have moved from torchquad/tests/ to tests/ - update any scripts or IDE configurations accordingly
  2. Packaging: The project now uses pyproject.toml instead of setup.py - use modern Python packaging tools
  3. Code Style: Code now uses 100-character line length - configure your formatter accordingly

Acknowledgments

Special thanks to all contributors who made this release possible. This release represents a significant step forward in making torchquad more robust, better documented, and easier to use across different computational backends and hardware configurations.

For detailed technical information about the changes, please refer to the individual pull requests linked above.

What's Changed

New Contributors

Full Changelog: v0.4.1...v0.5.0

torchqad 0.4.1

25 Nov 17:22

Choose a tag to compare

Changelog

Major

N/A

Minor

  • Fix compatibility with newer jax version (now requiring jax>=0.4.17)
  • Use tensorflows global precision setting and related bugfixes
  • Various CI fixes
  • Small doc fixes and formatting

Detailed changes

New Contributors

Full Changelog: v0.4.0...v0.4.1

torchquad v0.4.0

15 Jun 08:24

Choose a tag to compare

Changelog

Major

  • Support for vectorized multiple integrand compute with one call
  • Better support for custom integrators
  • Added Gauss Legendre integration

Minor

  • Various changes to tests
  • Additional examples in docs and various docstring changes
  • Workflow improvements for repo
  • Added automatic test coverage investigation
  • Small bugfixes

Detailed changes

New Contributors

Full Changelog: v0.3.0...v0.4.0

torchquad v0.3.0

05 May 17:02

Choose a tag to compare

Major

  • Added support for NumPy, JAX, Tensorflow via autoray for most integrators. Refer to docs for more details.
  • Support for (JIT) compilation of the integration, except VEGAS. Refer to docs for more details.
  • Huge performance improvements to VEGAS

Minor

  • More tests
  • New environment variable called TORCHQUAD_LOG_LEVEL to conveniently control loglevel, default changed to "warning"
  • More strict code linting with flake8 and a corresponding small code cleanup
  • Docs improvements
  • Custom RNG class
  • Refactoring of Newton-Cotes integrators

torchquad v0.2.4 - JOSS release

31 Aug 11:21
e5c4992

Choose a tag to compare

Release for Zenodo archiving for the JOSS publication

torchquad v0.2.3

20 Aug 13:23
e5c4992

Choose a tag to compare

Major

  • Added support and test for complex integrands (except in VEGAS, WIP)
  • Further vectorized VEGAS leading to significant performance improvements (still work to do though, currently VEGAS is faster on CPU)
  • Transitioned to PyTorch 1.9.0
  • Submitted paper to JOSS (currently in press)
  • Expanded docs (example for computing gradients, minimal working example)
  • Improved README

Minor

  • Added automated tests for computed gradients
  • Fixed gradient flow through all integrators (e.g. w.r.t domain)
  • Fixed setting loglevel
  • Switched to loguru as logger
  • Removed benchmark notebook (more extensive benchmarking will follow in the future)
  • Updated contribution guidelines
  • Several small fixes in the docs
  • Improved automated tests
  • Added some performance and convergence plots to README

JOSS Paper Version

13 Aug 08:21
9ab7175

Choose a tag to compare

Tagged version for the JOSS proof. Based on torchquad 0.2.2 with some updates to documentations.

torchquad v0.2.1

04 Jun 14:59

Choose a tag to compare

torchquad v0.2.1 Pre-release
Pre-release

Changelog

Major

Huge improvements to documentation
Added VEGAS Enhanced

Minor

Added Boole's rule
Migrated examples to docs
Updated requirements
Added option to set precision (float or double)
Improved comments
Added 10D unit test

torchquad v0.1.1-rc1

05 Feb 09:53

Choose a tag to compare

torchquad v0.1.1-rc1 Pre-release
Pre-release
  • Fixes to workflows
  • Improved README
  • Fixes in requirements.txt
  • Fixes in setup.py
  • More verbose errors when calling integrators with incompatible inputs
  • Simpson's & Boole's Rule now automatically pick compatible numbers of points and will warn
  • Small improvements to unit tests

torchquad v0.1.0-rc1

21 Jan 11:01

Choose a tag to compare

torchquad v0.1.0-rc1 Pre-release
Pre-release

First version of torchquad.

The first version of torchquad enables n-dimensional integrations using torch / CUDA utilizing several Newton-Cotes formulas or a simple Monte Carlo Integration. This should already enable huge speedups compared to CPU-only libraries. Also it should be differentiable using torch. Please feel free to test it and get back to us to help us improve it!