Skip to content
Discussion options

You must be logged in to vote

I have been experimenting with multiple backends but for some reason, I cannot get the mean_l2_relative_error loss to work with the paddle backend -

import deepxde as dde
import numpy as np
import paddle


# all the lines below error out
dde.losses.mean_l2_relative_error(np.array([[1, 1]]), np.array([[2, 2]]))
dde.losses.mean_l2_relative_error(1, 2)
dde.losses.mean_l2_relative_error(paddle.to_tensor(1.0), paddle.to_tensor(2.0)))

Error -

ValueError                                Traceback (most recent call last)
Cell In[6], line 1
----> 1 dde.losses.mean_l2_relative_error(np.array([[1, 1]]), np.array([[2, 2]]))

File ~/Code/SciML/deepxde/deepxde/losses.py:27, in mean_l2_relative_error(y_true

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
2 replies
@lululxvi
Comment options

@Saransh-cpp
Comment options

Answer selected by Saransh-cpp
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants