IMP  2.0.1
The Integrative Modeling Platform
fitting_solutions_reader_writer.h
Go to the documentation of this file.
1 /**
2  * \file IMP/multifit/fitting_solutions_reader_writer.h
3  * \brief handles reading and writing MultiFit fitting solutions file
4  *
5  * Copyright 2007-2013 IMP Inventors. All rights reserved.
6  *
7  */
8 
9 #ifndef IMPMULTIFIT_FITTING_SOLUTIONS_READER_WRITER_H
10 #define IMPMULTIFIT_FITTING_SOLUTIONS_READER_WRITER_H
11 
13 #include <IMP/Model.h>
14 #include <IMP/core/Hierarchy.h>
15 #include <IMP/Object.h>
16 #include <IMP/file.h>
17 #include <IMP/em/rigid_fitting.h>
18 #include <IMP/multifit/multifit_config.h>
19 #include "FittingSolutionRecord.h"
20 IMPMULTIFIT_BEGIN_NAMESPACE
21 
22 //! Fitting solutions reader
23 /**
24 \todo consider using TextInput
25  */
27  const char *fitting_fn);
28 //! Write fitting solutions to a file
29 /**
30 \param[in] fitting_fn the fitting filename
31 \param[in] fit_sols the fitting solutions to write to file
32 \param[in] num_sols optional, only write the first num_sols fits.
33  */
34 IMPMULTIFITEXPORT void write_fitting_solutions(
35  const char *fitting_fn,
36  const FittingSolutionRecords &fit_sols,
37  int num_sols=-1);
38 
39 IMPMULTIFITEXPORT FittingSolutionRecords convert_em_to_multifit_format(
40  const em::FittingSolutions &em_fits);
41 IMPMULTIFITEXPORT em::FittingSolutions convert_multifit_to_em_format(
42  const FittingSolutionRecords &multifit_fits);
43 
44 IMPMULTIFITEXPORT FittingSolutionRecords
45  convert_transformations_to_multifit_format(
46  const algebra::Transformation3Ds &trans);
47 
48 IMPMULTIFITEXPORT algebra::Transformation3Ds
49  convert_multifit_format_to_transformations(
50  const FittingSolutionRecords &recs);
51 
52 IMPMULTIFIT_END_NAMESPACE
53 #endif /* IMPMULTIFIT_FITTING_SOLUTIONS_READER_WRITER_H */