-
Notifications
You must be signed in to change notification settings - Fork 8
Added test for gradient flow and verifying that the deviation from th… #92
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
Conversation
…e original fdtd is not significant
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
minimal changes
nidn/tests/fdtd_test.py
Outdated
grid.run(cfg.FDTD_niter) | ||
t_signal_material, r_ = _get_detector_values(t_detector_material, _) | ||
# Original fdtd | ||
import fdtd |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
wouldn't it be easier to just hard-coded save the output values from the original FDTD? If the FDTD module changes in the future otherwise we may get an error here 🤔
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(still do keep the code to reproduce the code to create the ground truth in a comment in here ideally so we can easily update values if ever necessary)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Where should I put the code for the generation? The code is the same as in the generate ground-truth data notebook
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
minimal change
nidn/tests/fdtd_test.py
Outdated
# Add only the z component of the E field from the center point of the detector, as there is only z polarized waves | ||
raw_signal.append(t_detector_material.detector_values()["E"][i][1][2]) | ||
t.append(i) | ||
original_fdtd = [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
…e original fdtd is not significant
Description
As title
Resolved Issues
How Has This Been Tested?
pytest