Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to implement learning rate anealing? #1587

Open
AJAXJR24 opened this issue Dec 11, 2023 · 2 comments
Open

How to implement learning rate anealing? #1587

AJAXJR24 opened this issue Dec 11, 2023 · 2 comments

Comments

@AJAXJR24
Copy link

AJAXJR24 commented Dec 11, 2023

Dear @lululxvi
Hi and thanks for your help.

  1. I want to know How can i implement the underlying LRA algorithm in deepxde.
  2. How to define the equation number 15?

lulu

@haison19952013
Copy link

haison19952013 commented Dec 12, 2023

  • While your question is about loss weights, not learning rate, dynamically updating them in TensorFlow is achievable.

  • The key is to create custom callbacks that adjust the weights during training. This requires a deep understanding of TensorFlow's internal workings, particularly the autograph functionality.

  • If diving into code complexity isn't your preference, consider alternative PINN libraries like sciann or modulus that offer built-in dynamic loss weight functionalities.

  • Or you can refer to (this blog) to learn about constructing a PINN and the adaptive loss weights from the scratch

@praksharma
Copy link
Contributor

No this is not implemented in DeepXDE and to be honest, LRA (learning rate annealing) isn't very effectively on many problems. Anyways it is implemented in NVIDIA Modulus. Personally, I would say that just stick to constant coefficients and use deeper networks.
Here is one of my paper where solved PDEs with discontinuous solutions without any adaptive cofficients: paper

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants