mirror of
https://github.com/ml-explore/mlx-examples.git
synced 2025-07-23 20:51:16 +08:00
![]() * LoRA:Refactor TrainingCallback to enhance flexibility and extensibility This commit refactors the TrainingCallback class to accept a dictionary parameter for both on_train_loss_report and on_val_loss_report methods. By switching from multiple parameters to a single dict parameter, this change significantly improves the class's flexibility and makes it easier to extend with new training or validation metrics in the future without altering the method signatures. This approach simplifies the addition of new information to be logged or processed and aligns with best practices for scalable and maintainable code design. * LoRA: Add printing and callbacks for learning rate during training |
||
---|---|---|
.. | ||
__init__.py | ||
lora.py | ||
trainer.py | ||
utils.py |