Added
- **New Builder Module**
- Implemented fluent builder pattern for more intuitive solver configuration
- Added `builder.py` to support customizable solver construction
- Streamlined solver creation with chainable method calls
- **Observer Pattern for Progress Tracking**
- Added `observers.py` to implement the observer pattern
- Enabled real-time monitoring of solver progress and status
- Added `SolverObserver` interface and `SolverSubjectMixin` for notification support
- **Material Data Management**
- Added `material_proxy.py` for robust material data handling
- Implemented `MaterialDataProxy` for improved data caching and retrieval
- Added new method `from_nk_data()` to create materials from refractive index data
- **Algorithm Strategies**
- Enhanced `algorithm.py` with strategy pattern implementation
- Added support for algorithm selection and configuration
Changed
- **Solver Improvements**
- Modularized solver methods for single and batch frequency solving
- Enhanced `FourierBaseSolver` with improved type hints and validation
- Refactored solver initialization and configuration processes
- Moved utility functions from solver to dedicated modules
- **Material Class Enhancements**
- Enhanced `MaterialClass` with improved caching mechanisms
- Updated `from_data_file()` method with better error handling and validation
- Added `clear_cache()` method to improve memory management
- **Cell Module Enhancements**
- Added type hints and validation in `Cell3D` class
- Improved property management and access
- **Documentation**
- Added comprehensive docstrings across all modules
- Standardized documentation format with Args, Returns, and Examples sections
- Enhanced module-level documentation
Removed
- **Logger Module**
- Removed separate `logger.py` module
- Integrated logging functionality with new observer pattern
Fixed
- **GPU Compatibility**
- Fixed minor bugs when using GPU devices
- Improved tensor handling for better GPU compatibility
- **Material Handling**
- Fixed minor bugs in solving dispersive homogeneous layers
- Fixed warnings related to certain numpy versions in materials module
- **Tensor Support**
- Fixed issues when accepting thickness as tensors
- Improved validation of tensor inputs throughout the codebase
Internal
- **Architecture Refinements**
- Implemented multiple software design patterns for improved code structure
- Enhanced separation of concerns across modules
- Improved overall code organization and maintainability
- Removed `set_grad` parameter from `update_er_with_mask` method
This release represents a significant architectural improvement to the TorchRDIT package, focusing on enhanced material handling, solver configuration flexibility, and overall code organization.
**Full Changelog**: https://github.com/yi-huang-1/torchrdit/compare/0.1.11...0.1.12