attentionbydesign / tymera

Custom Scripts
GNU General Public License v3.0
0 stars 0 forks source link

'fm' (fitmap) accelerator doesn't work for two volumes? #13

Closed attentionbydesign closed 1 week ago

attentionbydesign commented 1 week ago

Works fine when fitting mol --> vol, but gave error instead of prompting input for vol --> vol.

attentionbydesign commented 1 week ago

Issue was the conditional statements to determine mol > vol vs vol > vol.

Fixed the former to len(sel) / 2 == nvol == 1 in which case you have one vol and two selected total, so the assumption is that the other object must be a mol if not a vol. Previously was len(sel) == nvol + nmol == 2 but this would also be true if they were either both vols or both mols, hence the error with both being vols.

Latter is len(sel) == nvol == 2, meaning there are two object and they're both volumes. Unchanged.