-
Notifications
You must be signed in to change notification settings - Fork 17
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
[Augur] Add augur tree iqtree model type to output #674
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…tory for iqtree model extraction
sage-wright
reviewed
Nov 14, 2024
sage-wright
reviewed
Nov 14, 2024
…titution model and rename iqtree model variable for clarity
sage-wright
reviewed
Nov 14, 2024
sage-wright
approved these changes
Nov 14, 2024
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.
well done. ⭐
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR closes #665
🗑️ This dev branch should be deleted after merging to main.
🧠 Summary
Adds a condition to augur tree to extract the model type if method is iqtree and model type is "auto', else if model is provided for iqtree extract that user provided model, else return null. A new output
iqtree_model_used
has been added to augur.⚡ Impacted Workflows/Tasks
Tasks:
task_augur_tree.wdl
Workflows:
wf_augur.wdl
This PR may lead to different results in pre-existing outputs: No
This PR uses an element that could cause duplicate runs to have different results: No
🛠️ Changes
A conditional statement has been added for task augur tree if the method is
iqtree
to either scrape the log file to extract the best fit model ifsubstitution_model
isauto
, else for user provided or default GTR model assign that to the output, if iqtree is not used echo an empty string into the file. This output is captured byiqtree_model_used
which is consistent with how snippy variant names the output.Note: If method is
iqtree
and substitution model isauto
, I am having to do an awkward work around to get where the log file containing the best fit model lives. Me and @kapsakcj took a look at how augur tree treats the execution directory and it seemed to be localizing data in and out from the alignment task. More detailed review of this can be done upon request.⚙️ Algorithm
➡️ Inputs
⬅️ Outputs
Outputs added for the follwowing:
task_augur_tree.wdl:
String iqtree_model_used = read_string("FINAL_MODEL.txt")
wf_augur.wdl:
String iqtree_model_used = augur_tree.iqtree_model_used
🧪 Testing
The PR was tested against the vrdl_vpd_specimen_HAV_set using this Augur_PHB instance. The
augur_tree.substitution_model
was tested with model set to auto, with model manually set to TIM2, with model manually set to GTR, with model manually set to F81. The null object pattern was tested withaugur_tree.substitution_model
unset andaugur_tree.method
set tofasttree
.Suggested Scenarios for Reviewer to Test
Please test with this workflow configured here using the
mb-augur-automodel-output-dev
branch. Test withaugur_tree.substitution_model
set toauto
and a few models manually set to your choosing from this set. Check to see iqtree_model_used on the set has been updated appropriately. Also please test without usingiqtree
as theaugur_tree.method
(fasttree or raxml). Check to seeiqtree_model_used
is null.🔬 Final Developer Checklist
🎯 Reviewer Checklist