hpinn icon indicating copy to clipboard operation
hpinn copied to clipboard

Code outdated

Open ArtemioA opened this issue 2 years ago • 5 comments

Sorry, there is currently a problem with your code. The version of the deepxde library that runs the "holography_main.py" file it is 0.9.1. Could you update the file so that it can run on the current version? or how could I fix this problem?

image

Thank you

ArtemioA avatar Apr 01 '22 19:04 ArtemioA

It might be due to the following code

https://github.com/lululxvi/hpinn/blob/1a59c28dc52af26d719b6a6b2adf1f12f552fae4/holography/holography/pde.py#L71

The new version of DeepXDE doesn't allow the numpy X as the 3rd argument. It support PDE with 3 arguments via auxiliary_var_function, see https://github.com/lululxvi/deepxde/blob/master/examples/pinn_inverse/Lorenz_inverse_forced.py

lululxvi avatar Apr 05 '22 00:04 lululxvi

I wonder what "X" means and how to modify this code in latest deepXDE1.1.3? Thanks ! @lululxvi

XinweiCai avatar Apr 15 '22 14:04 XinweiCai

X means the numpy version of the network input, which is a tensor.

To modify the code, you need to use auxiliary_var_function, see https://github.com/lululxvi/deepxde/blob/master/examples/pinn_inverse/Lorenz_inverse_forced.py

lululxvi avatar Apr 19 '22 00:04 lululxvi

Sorry Dr. Lu, I am still confused which function is the tensor X calculated from ? i.e. auxiliary_var_function = ? Can you give me detailed advise or exact codes? Thanks a lot!

XinweiCai avatar Apr 19 '22 05:04 XinweiCai

X is the network input, a numpy array, not from any function.

You cannot "translate" the code line by line. You need to modify the logic a little bit.

lululxvi avatar Apr 22 '22 01:04 lululxvi