[med-svn] [Git][med-team/iqtree][upstream] New upstream version 1.6.9+dfsg
Andreas Tille
gitlab at salsa.debian.org
Wed Jan 2 13:51:32 GMT 2019
Andreas Tille pushed to branch upstream at Debian Med / iqtree
Commits:
48b7c97f by Andreas Tille at 2019-01-02T13:13:29Z
New upstream version 1.6.9+dfsg
- - - - -
8 changed files:
- CMakeLists.txt
- README.md
- alignment/superalignment.cpp
- nclextra/msetsblock.cpp
- nclextra/msetsblock.h
- tree/iqtree.cpp
- utils/checkpoint.cpp
- utils/tools.cpp
Changes:
=====================================
CMakeLists.txt
=====================================
@@ -51,7 +51,7 @@ add_definitions(-DIQ_TREE)
# The version number.
set (iqtree_VERSION_MAJOR 1)
set (iqtree_VERSION_MINOR 6)
-set (iqtree_VERSION_PATCH "8")
+set (iqtree_VERSION_PATCH "9")
set(BUILD_SHARED_LIBS OFF)
=====================================
README.md
=====================================
@@ -1,6 +1,9 @@
IQ-TREE
=======
+[![Build Status](https://travis-ci.org/bqminh/IQ-TREE.svg?branch=master)](https://travis-ci.org/bqminh/IQ-TREE)
+[![License: GPL v2](https://img.shields.io/badge/License-GPL%20v2-blue.svg)](https://www.gnu.org/licenses/old-licenses/gpl-2.0.en.html)
+
Efficient and versatile phylogenomic software by maximum likelihood <http://www.iqtree.org>
Introduction
=====================================
alignment/superalignment.cpp
=====================================
@@ -1008,7 +1008,10 @@ void SuperAlignment::createBootstrapAlignment(int *pattern_freq, const char *spe
// resampling sites within genes
int offset = 0;
for (vector<Alignment*>::iterator it = partitions.begin(); it != partitions.end(); it++) {
- (*it)->createBootstrapAlignment(pattern_freq + offset, NULL, rstream);
+ if (spec && strncmp(spec, "SCALE=", 6) == 0)
+ (*it)->createBootstrapAlignment(pattern_freq + offset, spec, rstream);
+ else
+ (*it)->createBootstrapAlignment(pattern_freq + offset, NULL, rstream);
offset += (*it)->getNPattern();
}
}
@@ -1259,11 +1262,12 @@ Alignment *SuperAlignment::concatenateAlignments(set<int> &ids) {
Alignment *SuperAlignment::concatenateAlignments() {
vector<SeqType> seq_types;
+ vector<char*> genetic_codes;
vector<set<int> > ids;
for (int i = 0; i < partitions.size(); i++) {
bool found = false;
for (int j = 0; j < seq_types.size(); j++)
- if (partitions[i]->seq_type == seq_types[j]) {
+ if (partitions[i]->seq_type == seq_types[j] && partitions[i]->genetic_code == genetic_codes[j]) {
ids[j].insert(i);
found = true;
break;
@@ -1272,6 +1276,7 @@ Alignment *SuperAlignment::concatenateAlignments() {
continue;
// create a new partition
seq_types.push_back(partitions[i]->seq_type);
+ genetic_codes.push_back(partitions[i]->genetic_code);
ids.push_back(set<int>());
ids.back().insert(i);
}
=====================================
nclextra/msetsblock.cpp
=====================================
@@ -267,6 +267,9 @@ void MSetsBlock::Read(NxsToken &token)
else
{
+ errormsg = "Unknown command ";
+ errormsg += token.GetToken();
+ throw NxsException(errormsg, token.GetFilePosition(), token.GetFileLine(), token.GetFileColumn());
SkippingCommand(token.GetToken());
do
{
@@ -284,6 +287,11 @@ void MSetsBlock::Read(NxsToken &token)
}
+void MSetsBlock::SkippingCommand(NxsString commandName) {
+ cout << "WARNING: Skipping unknown command " << commandName << endl;
+}
+
+
CharSet *MSetsBlock::findCharSet(string name) {
for (vector<CharSet*>::iterator it = charsets.begin(); it != charsets.end(); it++)
if ((*it)->name == name) return (*it);
=====================================
nclextra/msetsblock.h
=====================================
@@ -95,6 +95,12 @@ public:
*/
virtual void Reset();
+ /**
+ called when some commands are skipped
+ @param commandName command name
+ */
+ virtual void SkippingCommand(NxsString commandName);
+
/**
@return the number of sets
*/
=====================================
tree/iqtree.cpp
=====================================
@@ -2885,6 +2885,15 @@ void IQTree::refineBootTrees() {
finish_random();
randstream = saved_randstream;
+ SplitGraph *sg = new SplitGraph;
+ summarizeBootstrap(*sg);
+ sg->removeTrivialSplits();
+ sg->setCheckpoint(checkpoint);
+ boot_splits.push_back(sg);
+
+ saveCheckpoint();
+ checkpoint->dump();
+
// restore
params->gbo_replicates = boot_trees.size();
params->nni_type = saved_nni_type;
@@ -4051,6 +4060,8 @@ void IQTree::printResultTree(ostream &out) {
void IQTree::printBestCandidateTree() {
if (MPIHelper::getInstance().isWorker())
return;
+ if (params->suppress_output_flags & OUT_TREEFILE)
+ return;
string tree_file_name = params->out_prefix;
tree_file_name += ".treefile";
readTreeString(candidateTrees.getBestTreeStrings(1)[0]);
=====================================
utils/checkpoint.cpp
=====================================
@@ -9,6 +9,7 @@
#include "tools.h"
#include "timeutil.h"
#include "gzstream.h"
+#include <cstdio>
const char* CKP_HEADER = "--- # IQ-TREE Checkpoint ver >= 1.6";
const char* CKP_HEADER_OLD = "--- # IQ-TREE Checkpoint";
@@ -149,12 +150,18 @@ void Checkpoint::dump(bool force) {
return;
}
prev_dump_time = getRealTime();
+ string filename_tmp = filename + ".tmp";
+ if (fileExists(filename_tmp)) {
+ outWarning("IQ-TREE was killed while writing temporary checkpoint file " + filename_tmp);
+ outWarning("You should increase checkpoint interval from the default 60 seconds");
+ outWarning("via -cptime option to avoid too frequent checkpoint for large datasets");
+ }
try {
ostream *out;
if (compression)
- out = new ogzstream(filename.c_str());
+ out = new ogzstream(filename_tmp.c_str());
else
- out = new ofstream(filename.c_str());
+ out = new ofstream(filename_tmp.c_str());
out->exceptions(ios::failbit | ios::badbit);
*out << header << endl;
// call dump stream
@@ -165,6 +172,12 @@ void Checkpoint::dump(bool force) {
((ofstream*)out)->close();
delete out;
// cout << "Checkpoint dumped" << endl;
+ if (fileExists(filename)) {
+ if (std::remove(filename.c_str()) != 0)
+ outError("Cannot remove file ", filename);
+ }
+ if (std::rename(filename_tmp.c_str(), filename.c_str()) != 0)
+ outError("Cannot rename file ", filename_tmp);
} catch (ios::failure &) {
outError(ERR_WRITE_OUTPUT, filename.c_str());
}
=====================================
utils/tools.cpp
=====================================
@@ -1707,7 +1707,7 @@ void parseArg(int argc, char *argv[], Params ¶ms) {
if (strcmp(argv[cnt], "-rclusterf") == 0) {
cnt++;
if (cnt >= argc)
- throw "Use -rcluster <percent>";
+ throw "Use -rclusterf <percent>";
params.partfinder_rcluster = convert_double(argv[cnt]);
if (params.partfinder_rcluster < 0 || params.partfinder_rcluster > 100)
throw "rcluster percentage must be between 0 and 100";
@@ -1722,6 +1722,8 @@ void parseArg(int argc, char *argv[], Params ¶ms) {
params.partfinder_rcluster_max = convert_int(argv[cnt]);
if (params.partfinder_rcluster_max <= 0)
throw "rcluster-max must be between > 0";
+ if (params.partfinder_rcluster == 100)
+ params.partfinder_rcluster = 99.9999;
continue;
}
View it on GitLab: https://salsa.debian.org/med-team/iqtree/commit/48b7c97f2de5b926ed28e09c26a5076e769cc662
--
View it on GitLab: https://salsa.debian.org/med-team/iqtree/commit/48b7c97f2de5b926ed28e09c26a5076e769cc662
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/debian-med-commit/attachments/20190102/d9858acb/attachment-0001.html>
More information about the debian-med-commit
mailing list