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

Mafft Changes #1337

Merged
merged 44 commits into from
Mar 20, 2024
Merged

Mafft Changes #1337

merged 44 commits into from
Mar 20, 2024

Conversation

elischberg
Copy link
Contributor

@elischberg elischberg commented Oct 19, 2023

Fixes:

  • Fix datatype selection matrix choice
  • Autodetection matrix definition
  • Update version number

Fixes need to be done:

  • according alignment strategies with help section
  • insert arguments
  • tests correction

@@ -1,7 +1,7 @@
<?xml version="1.0"?>
<macros>
<token name="@VERSION@">0</token>
<token name="@TOOL_VERSION@">7.508</token>
<token name="@TOOL_VERSION@">7.52</token>
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh wow, is 7.52 really bigger/newer than 7.508?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The latest version is actually 7.520. @elischberg I don't think you can just drop that trailing zero.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh my bad. I thought, the dot is a comma.

@bgruening
Copy link
Owner

You need to rebase this PR, please.

@elischberg
Copy link
Contributor Author

Tried for the groupsize param to get a max limit through a validator with the sequence metadata, but I think it then ignored every inserted integer of the groupsize param. Solved it right now with a condition in the command part of mafft.xml.

@bgruening
Copy link
Owner

@elischberg
Copy link
Contributor Author

In venn.xml it is a fix maximum. Unfortunately not appliable in the groupsize case with a variable maximum. We solved it with a warning for users, when they use a too large number.
But thanks!

@elischberg
Copy link
Contributor Author

There are difficulties with the groupsize parameter. I don't know, how to change the empty value of $cond_flavour.guidetree.partetree_selection.groupsize into the calculated $sequence_count. Do you have an idea?

echo $cond_flavour.guidetree.parttree_selection.groupsize &&
#if $cond_flavour.guidetree.parttree_selection.groupsize == "None"
int($cond_flavour.guidetree.parttree_selection.groupsize) = $sequence_count
#elif $cond_flavour.guidetree.parttree_selection.groupsize > $sequence_count
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Although the error:

'>' not supported between instances of 'NoneType' and 'int'

looks like it's coming from here, you can completely remove the whole section and when you don't enter anything for the optional integer param still get it in exactly the same form.

I think this comes from an internal attempt to compare the None to the "min" and "max" values of the param =>
There's just no way to combine min, max and optional="true" for an int param.

As discussed try to use -1 instead and explain it in the param help.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

-1 isn't working. Then MAFFT gives an error like: Specify groupsize!
I think it is an internal function of MAFFT, if one adding a larger number than input sequences, then it shows -1 but it takes one more than the number of input sequences.

I'm just wondering, because there was a moment, when it worked with the comparison.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can remove the section but then we dont have a warning in die stoud. I can simply mention it somewhere else?

@elischberg
Copy link
Contributor Author

elischberg commented Nov 27, 2023

git status: clean worktree and git diff:nothing.
Its only Test 4 which is online a failure with the error of a different output.

@bgruening
Copy link
Owner

grafik

So the results for test 4 are still different.
If you run this already in Containers, then the only explanation I have is that this test is not deterministic and generates a different output based on some other wired stuff.

But the changes look vastly different :(

@bgruening
Copy link
Owner

GreeeennnnnnnnnnnN!

@elischberg
Copy link
Contributor Author

Very good. (:

@bgruening
Copy link
Owner

ping @wm75

tools/mafft/mafft-add.xml Outdated Show resolved Hide resolved
</conditional>
</when>
</conditional>
<section name="progressive_alignment_calculation" title="Progressive alignment calculation" expanded="true">
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Exposing these settings unconditionally makes no sense since they are part of the "flavour" definitions.
If a user selects a pre-defined flavour above and you're overwriting some of that flavour's settings here, it's not that flavour anymore.

@elischberg I've opened another PR against your branch that fixes this and a few other things.
Once that's merged you will have to regenerate all test data except for the first test (for which the settings here happen to be that of the flavour).
I guess it would be a good idea to generate all test data with mafft flavour commands on the command line to make sure the wrapper produces matching outputs.

@wm75
Copy link
Collaborator

wm75 commented Mar 19, 2024

@elischberg cool!
What about test 4, which you previously changed to check only for a few lines of output.
Is it by chance possible to make this one stricter again now that --threadit is set to 0?

@elischberg
Copy link
Contributor Author

@elischberg cool! What about test 4, which you previously changed to check only for a few lines of output. Is it by chance possible to make this one stricter again now that --threadit is set to 0?

Going to try (:

@wm75
Copy link
Collaborator

wm75 commented Mar 19, 2024

The mafft_auto_result.aln test file was also used by the mafft_add test, which is now failing.

@bgruening
Copy link
Owner

failing ...

Copy link
Collaborator

@wm75 wm75 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the hard work on this complex wrapper @elischberg !

@bgruening bgruening merged commit 2f6456c into bgruening:master Mar 20, 2024
12 checks passed
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.

3 participants