Skip to content
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

Importance nested sampling and multimodal should be **False** by default #220

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

AdamOrmondroyd
Copy link
Contributor

I was finding that changing multimodal was making no difference to the output. MultiNest cannot have both importance nested sampling and multimodal both turned on, so if both are True, then multimodal is changed to False. The default, multimodal=True and importance_nested_sampling=True, is therefore incompatible with MultiNest. To match MultiNest they should both default to False.

https://github.com/farhanferoz/MultiNest/blob/cc616c17ed440fbff8d35937997c86256ed4d744/MultiNest_v3.12/nested.F90#L168-L170

@AdamOrmondroyd
Copy link
Contributor Author

I just remembered this PR. I understand that this is a breaking change, but it does not work as is. Perhaps it would be better to raise a warning if both INS and mmodal are turned on?

@JohannesBuchner
Copy link
Owner

if IS=1, I expect MultiNest still does multiple ellipsoids, or not? I guess multimodal refers to splitting the run into several independent ones when modes are encountered?

To match MultiNest they should both default to False.

I don't understand this part. IIRC MultiNest does not have defaults.

How did this PR decide which to set to False, and why should multimodal be False if IS=False?

@AdamOrmondroyd
Copy link
Contributor Author

if IS=1, I expect MultiNest still does multiple ellipsoids, or not? I guess multimodal refers to splitting the run into several independent ones when modes are encountered?

Some notes I have from a conversation with Mike Hobson last October say "multimodal=False -> live points CANNOT move between clusters". I'll have to reimmerse myself to remember the issues I was seeing.

How did this PR decide which to set to False, and why should multimodal be False if IS=False?

I can't remember why I set both to False. However, if you follow the link, on line 170 of nested.f90, multimodal is set to false if IS is true. I think PyMultiNest should reflect this.

@JohannesBuchner
Copy link
Owner

maybe importance_nested_sampling=False is enough here.

@AdamOrmondroyd
Copy link
Contributor Author

What do you think about adding a warning if both are set to True?

@JohannesBuchner
Copy link
Owner

Explaining what multinest does internally goes beyond the scope of pymultinest.

IS and non-IS MultiNest are two quite different beasts. The stdout of multinest says which one is being performed.

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