Skip to content

Try to uniformize the function of generating the noise #303

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

Draft
wants to merge 81 commits into
base: main
Choose a base branch
from

Conversation

lionelkusch
Copy link
Collaborator

@lionelkusch lionelkusch commented Jun 23, 2025

By merging the 2 functions of the noise, I get a strange result for plot_2D.
@bthirion Do you have an explanation for it?

I made a snippet of code here: https://github.com/lionelkusch/hidimstat/blob/PR_spatial_noise/spatial_noise/plot_2D_simulation_example.py

@lionelkusch lionelkusch requested a review from bthirion June 23, 2025 14:15
@lionelkusch
Copy link
Collaborator Author

For the parameters, I use:

  • n_samples = 100
  • shape = (40, 40)
  • n_features = shape[1] * shape[0]
  • roi_size = 4 # size of the edge of the four predictive regions
  • sigma = 2.0 # noise standard deviation
  • rho = 0.5 # level of "spatial correlation"
  • snr = 50.0

I get this result:
image

I don't know if it's interesting or not.
This previous result will replace the following result:
image

@bthirion
Copy link
Collaborator

My impression is that the smoothing is applied only horizontally, which leads to this very anisotropic clusters.

@lionelkusch lionelkusch changed the title Try to uniformize the function fo generating the noise Try to uniformize the function of generating the noise Jun 24, 2025
@lionelkusch
Copy link
Collaborator Author

My impression is that the smoothing is applied only horizontally, which leads to this very anisotropic clusters.
Yes, I think it's the case.

Do you think that it can be interesting to improve the function multivariate_simulation by proposing different types of correlation/smoothing? Or Do we stay with 2 different functions and I improve multivariate_simulation_spatial for having a similar signature that multivariate_simulation?

@bthirion
Copy link
Collaborator

My impression is that the smoothing is applied only horizontally, which leads to this very anisotropic clusters.
Yes, I think it's the case.

Do you think that it can be interesting to improve the function multivariate_simulation by proposing different types of correlation/smoothing? Or Do we stay with 2 different functions and I improve multivariate_simulation_spatial for having a similar signature that multivariate_simulation?

No there's no need for that. We should only keep isotropic smoothing

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

Successfully merging this pull request may close these issues.

2 participants