|
Rosetta 3.5
|
ArchiveManager is responsible for communication with JobDistributor and organization of Batches and returning decoys he owns an Archive (AbstractArchiveBase) that will be handed the decoys and is asked to generate_batch() if the QUEUE_EMPTY . More...
#include <ArchiveManager.hh>

Public Types | |
| typedef utility::vector1< Batch > | BatchList |
Public Member Functions | |
| ArchiveManager (core::Size archive_rank, core::Size jd_master_rank, core::Size file_buf_rank) | |
| ctor is protected; singleton pattern More... | |
| virtual | ~ArchiveManager () |
| void | go (ArchiveBaseOP) |
| Batch & | start_new_batch (core::io::silent::SilentStructOPs const &start_decoys) |
| Batch & | start_new_batch () |
| void | finalize_batch (Batch &, bool reread=false) |
| core::Size | last_batch_id () const |
| BatchList const & | batches () const |
| core::Size | unfinished_batches () const |
| void | cancel_batch (Batch &batch, bool allow_reading_of_decoys=true) |
| void | cancel_batches_previous_to (core::Size batch_id, bool allow_reading_of_decoys=true) |
| void | save_archive () |
Static Public Member Functions | |
| static void | register_options () |
Protected Member Functions | |
| virtual void | batch_underflow () |
| triggered in slave if new batch_ID comes in. More... | |
| void | idle () |
| void | jobs_completed () |
| void | queue_batch (Batch const &batch) |
| void | cancel_batch (Batch const &batch) |
| void | read_existing_batches () |
| void | register_batch (Batch new_batch) |
| void | send_stop_to_jobdistributor () |
| bool | restore_archive () |
Private Types | |
| typedef MPIArchiveJobDistributor::CompletionMessage | CompletionMessage |
| typedef std::map< core::Size, CompletionMessage > | CompletionMessages |
Private Attributes | |
| utility::vector1< Batch > | batches_ |
| core::Size const | archive_rank_ |
| core::Size const | jd_master_rank_ |
| core::Size const | file_buf_rank_ |
| AbstractArchiveBaseOP | theArchive_ |
| CompletionMessages | jobs_completed_ |
| core::Size | save_archive_time_interval_ |
| specify seconds between automatic saves to filesystem More... | |
Static Private Attributes | |
| static bool | options_registered_ |
Friends | |
| class | JobDistributorFactory |
ArchiveManager is responsible for communication with JobDistributor and organization of Batches and returning decoys he owns an Archive (AbstractArchiveBase) that will be handed the decoys and is asked to generate_batch() if the QUEUE_EMPTY .
Definition at line 191 of file ArchiveManager.hh.
Definition at line 195 of file ArchiveManager.hh.
|
private |
Definition at line 256 of file ArchiveManager.hh.
|
private |
Definition at line 257 of file ArchiveManager.hh.
| protocols::jd2::archive::ArchiveManager::ArchiveManager | ( | core::Size | archive_rank, |
| core::Size | jd_master_rank, | ||
| core::Size | file_buf_rank | ||
| ) |
ctor is protected; singleton pattern
constructor. Notice it calls the parent class! It also builds some internal variables for determining which processor it is in MPI land.
Definition at line 259 of file ArchiveManager.cc.
References options_registered_.
|
inlinevirtual |
Definition at line 195 of file ArchiveManager.hh.
|
inlineprotectedvirtual |
triggered in slave if new batch_ID comes in.
Definition at line 230 of file ArchiveManager.hh.
|
inline |
Definition at line 218 of file ArchiveManager.hh.
References batches_.
Referenced by protocols::abinitio::IterativeBase::collect_hedgeing_decoys_from_batches(), and unfinished_batches().
| void protocols::jd2::archive::ArchiveManager::cancel_batch | ( | Batch & | batch, |
| bool | allow_reading_of_decoys = true |
||
| ) |
Definition at line 625 of file ArchiveManager.cc.
References protocols::jd2::JobDistributor::add_batch(), protocols::jd2::BatchJobInputter::BOGUS_BATCH_ID, protocols::jd2::archive::CANCEL_BATCH, protocols::jd2::archive::Batch::flag_file(), protocols::jd2::JobDistributor::get_instance(), protocols::jd2::archive::Batch::id(), jd_master_rank_, protocols::jd2::archive::Batch::mark_as_cancelled(), protocols::jd2::MPI_JOB_DIST_TAG(), protocols::jd2::archive::Batch::nstruct(), core::io::serialization::size(), protocols::jd2::tr(), and protocols::jd2::archive::Batch::write_info_file().
Referenced by cancel_batches_previous_to().
|
protected |
| void protocols::jd2::archive::ArchiveManager::cancel_batches_previous_to | ( | core::Size | batch_id, |
| bool | allow_reading_of_decoys = true |
||
| ) |
Definition at line 617 of file ArchiveManager.cc.
References batches_, and cancel_batch().
Referenced by protocols::abinitio::IterativeBase::increment_stage(), and protocols::abinitio::IterativeBase::rescore_nonlocal_archive().
| void protocols::jd2::archive::ArchiveManager::finalize_batch | ( | Batch & | new_batch, |
| bool | reread = false |
||
| ) |
Definition at line 758 of file ArchiveManager.cc.
References protocols::jd2::archive::Batch::all_broker_files(), protocols::jd2::archive::Batch::batch(), batches_, protocols::jd2::archive::Batch::broker_file(), protocols::swa::rna::file_exists(), protocols::jd2::archive::Batch::flag_file(), protocols::jd2::archive::Batch::has_finished(), protocols::jd2::archive::Batch::has_silent_in(), protocols::jd2::archive::Batch::intermediate_structs(), protocols::jd2::archive::Batch::is_cancelled(), protocols::jd2::archive::Batch::mark_as_finished(), protocols::jd2::archive::Batch::nstruct(), queue_batch(), protocols::jd2::archive::Batch::read_info_file(), protocols::jd2::archive::report_batch_inconsistency(), protocols::jd2::archive::Batch::score_file(), protocols::jd2::archive::Batch::set_decoys_returned(), protocols::jd2::archive::Batch::set_intermediate_structs(), protocols::jd2::archive::Batch::silent_in(), protocols::jd2::archive::Batch::silent_out(), theArchive_, protocols::jd2::tr(), protocols::jd2::archive::Batch::user_options(), and protocols::jd2::archive::Batch::write_info_file().
Referenced by protocols::abinitio::IterativeFullatom::generate_batch(), protocols::abinitio::IterativeBase::generate_batch(), protocols::jd2::archive::DebugArchive::generate_batch(), and read_existing_batches().
| void protocols::jd2::archive::ArchiveManager::go | ( | ArchiveBaseOP | archive) |
Definition at line 277 of file ArchiveManager.cc.
References archive_rank_, batches_, file_buf_rank_, idle(), jd_master_rank_, protocols::jd2::archive::JOB_COMPLETION, jobs_completed(), jobs_completed_, protocols::jd2::archive::MPI_ARCHIVE_TAG, protocols::jd2::archive::QUEUE_EMPTY, read_existing_batches(), core::io::silent::SilentFileData::read_file(), restore_archive(), save_archive(), send_stop_to_jobdistributor(), protocols::swa::rna::sleep(), protocols::loops::stop, theArchive_, protocols::jd2::tr(), and unfinished_batches().
Referenced by protocols::jd2::archive::MPIArchiveJobDistributor::go().
|
protected |
Definition at line 436 of file ArchiveManager.cc.
References jobs_completed(), jobs_completed_, save_archive(), save_archive_time_interval_, protocols::swa::rna::sleep(), theArchive_, and protocols::jd2::tr().
Referenced by go().
|
protected |
Definition at line 469 of file ArchiveManager.cc.
References protocols::jd2::archive::Batch::allow_reading_cancelled_decoys(), protocols::jd2::archive::Batch::batch(), batches_, protocols::jd2::archive::Batch::decoys_returned(), file_buf_rank_, protocols::jd2::archive::Batch::id(), protocols::jd2::archive::Batch::is_cancelled(), jobs_completed_, protocols::jd2::archive::Batch::mark_as_finished(), core::io::silent::SilentFileData::read_tags_fast(), save_archive(), protocols::jd2::archive::Batch::set_decoys_returned(), protocols::jd2::archive::Batch::silent_out(), protocols::swa::rna::sleep(), theArchive_, protocols::jd2::tr(), and protocols::jd2::archive::Batch::write_info_file().
|
inline |
Definition at line 214 of file ArchiveManager.hh.
References batches_.
Referenced by protocols::abinitio::IterativeBase::increment_stage().
|
protected |
Definition at line 592 of file ArchiveManager.cc.
References protocols::jd2::archive::ADD_BATCH, protocols::jd2::JobDistributor::add_batch(), protocols::jd2::archive::Batch::flag_file(), protocols::jd2::JobDistributor::get_instance(), protocols::jd2::archive::Batch::id(), jd_master_rank_, protocols::jd2::MPI_JOB_DIST_TAG(), protocols::jd2::archive::Batch::nstruct(), core::io::serialization::size(), and protocols::jd2::tr().
Referenced by finalize_batch(), and send_stop_to_jobdistributor().
|
protected |
Definition at line 674 of file ArchiveManager.cc.
References protocols::jd2::archive::Batch::batch(), batches_, protocols::swa::rna::file_exists(), finalize_batch(), protocols::jd2::archive::Batch::flag_file(), protocols::jd2::archive::Batch::id(), jobs_completed_, start_new_batch(), and protocols::jd2::tr().
Referenced by go().
|
protected |
|
static |
Definition at line 91 of file ArchiveManager.cc.
References protocols::evaluation::options_registered_.
|
protected |
| void protocols::jd2::archive::ArchiveManager::save_archive | ( | ) |
Definition at line 865 of file ArchiveManager.cc.
References theArchive_.
Referenced by go(), idle(), jobs_completed(), protocols::abinitio::IterativeBase::reassign_noesy_data(), and send_stop_to_jobdistributor().
|
protected |
Definition at line 655 of file ArchiveManager.cc.
References queue_batch(), save_archive(), and protocols::jd2::tr().
Referenced by go().
| Batch & protocols::jd2::archive::ArchiveManager::start_new_batch | ( | core::io::silent::SilentStructOPs const & | start_decoys) |
Definition at line 719 of file ArchiveManager.cc.
References core::io::silent::SilentFileData::add_structure(), batches_, protocols::swa::rna::file_exists(), protocols::jd2::archive::Batch::set_id(), protocols::jd2::tr(), and core::io::silent::SilentFileData::write_all().
| Batch & protocols::jd2::archive::ArchiveManager::start_new_batch | ( | ) |
Definition at line 713 of file ArchiveManager.cc.
Referenced by read_existing_batches().
| core::Size protocols::jd2::archive::ArchiveManager::unfinished_batches | ( | ) | const |
|
friend |
Definition at line 246 of file ArchiveManager.hh.
|
private |
Definition at line 251 of file ArchiveManager.hh.
Referenced by go().
|
private |
Definition at line 249 of file ArchiveManager.hh.
Referenced by batches(), cancel_batches_previous_to(), finalize_batch(), go(), jobs_completed(), last_batch_id(), read_existing_batches(), and start_new_batch().
|
private |
Definition at line 253 of file ArchiveManager.hh.
Referenced by go(), and jobs_completed().
|
private |
Definition at line 252 of file ArchiveManager.hh.
Referenced by cancel_batch(), go(), and queue_batch().
|
private |
Definition at line 258 of file ArchiveManager.hh.
Referenced by go(), idle(), jobs_completed(), and read_existing_batches().
|
staticprivate |
Definition at line 262 of file ArchiveManager.hh.
Referenced by ArchiveManager().
|
private |
specify seconds between automatic saves to filesystem
Definition at line 260 of file ArchiveManager.hh.
Referenced by idle().
|
private |
Definition at line 255 of file ArchiveManager.hh.
Referenced by finalize_batch(), go(), idle(), jobs_completed(), restore_archive(), and save_archive().
1.8.4