-
Notifications
You must be signed in to change notification settings - Fork 0
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
Update installation and general code clean-up #13
Conversation
Merge main into develop
|
||
The _analytical_case.py_ script allows for comparaison between simulated and analytical results for a spherical and cylindrical phantom. | ||
The _analytical_cases_ command allows for comparaison between simulated and analytical results for a spherical and cylindrical phantom. |
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.
The _analytical_cases_ command allows for comparaison between simulated and analytical results for a spherical and cylindrical phantom. | |
The `analytical_cases` command allows for comparaison between simulated and analytical results for a spherical and cylindrical phantom. |
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.
it's not very clear to me what the function actually does. Can you give an example of figure output? Also, what should be my input here? it seems that -t and -b are not image inputs, so I'm puzzled as to what I'm supposed to input...?
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.
right, i'll add an example of figures output. the inputs -t and -b are defined in the inputs as the geometry type and the buffer value respectively.
README.md
Outdated
``` | ||
|
||
|
||
### fft_simulation | ||
### compute_fieldmap |
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.
I would definitely place this one before. The logical order is to first compute the fieldmap, and then run analytical_cases, no?
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.
indeed. will switch the two
@CharlesPageot in the future I suggest you pick a branch name that is less generic, see our conventions |
fft_simulation/analytical_cases.py
Outdated
|
||
Bz_in = np.where(mask, Bz_in, 0) | ||
Bz_out = np.where(~mask, Bz_out, 0) | ||
Bz_in = np.zeros(self.matrix) | ||
|
||
Bz_analytical = Bz_out + Bz_in |
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.
What is the point of Bz_in? It's only a matrix of zeros.
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.
will remove
fft_simulation/analytical_cases.py
Outdated
@@ -114,17 +209,21 @@ def main(geometry_type, buffer): | |||
|
|||
# plot sections of the chi distribution | |||
fig, axes = plt.subplots(2, 3, figsize=(10, 5), dpi=120) |
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.
A plot () function should be integrated for each class instead of having an if statement with two very similar functions. You could even create a PArent class to both where you define the plot function.
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.
I created a parent class for plotting
Co-authored-by: Julien Cohen-Adad <[email protected]>
Co-authored-by: Julien Cohen-Adad <[email protected]>
Co-authored-by: Julien Cohen-Adad <[email protected]>
Summary