Skip to content
Commits on Source (4)
......@@ -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)
......
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
......
......@@ -1008,6 +1008,9 @@ 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++) {
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);
}
......
iqtree (1.6.9+dfsg-1) unstable; urgency=medium
* New upstream version
-- Andreas Tille <tille@debian.org> Wed, 02 Jan 2019 14:13:38 +0100
iqtree (1.6.8+dfsg-1) unstable; urgency=medium
* New upstream version
......
......@@ -13,7 +13,7 @@ Build-Depends: debhelper (>= 11~),
help2man,
time,
chrpath
Standards-Version: 4.2.1
Standards-Version: 4.3.0
Vcs-Browser: https://salsa.debian.org/med-team/iqtree
Vcs-Git: https://salsa.debian.org/med-team/iqtree.git
Homepage: http://www.cibiv.at/software/iqtree/
......
......@@ -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);
......
......@@ -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
*/
......
......@@ -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]);
......
......@@ -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());
}
......
......@@ -1707,7 +1707,7 @@ void parseArg(int argc, char *argv[], Params &params) {
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 &params) {
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;
}
......