#include <FilteredVMatrix.h>
Inheritance diagram for PLearn::FilteredVMatrix:
Public Member Functions | |
FilteredVMatrix () | |
Default constructor. | |
FilteredVMatrix (VMat the_source, const string &program_string, const string &the_metadatadir="") | |
Convenience constructor. | |
virtual void | setMetaDataDir (const string &the_metadatadir) |
Also sets the source's meta-data dir if it's not already set. | |
virtual void | build () |
Should call simply inherited::build(), then this class's build_(). | |
virtual void | makeDeepCopyFromShallowCopy (map< const void *, void * > &copies) |
Transforms a shallow copy into a deep copy. | |
PLEARN_DECLARE_OBJECT (FilteredVMatrix) | |
Declares name and deepCopy methods. | |
Public Attributes | |
string | prg |
Protected Member Functions | |
void | openIndex () |
Generates the index file if it does not already exist. | |
virtual void | getNewRow (int i, const Vec &v) const |
This is the only method requiring implementation. | |
Static Protected Member Functions | |
void | declareOptions (OptionList &ol) |
Declares this class' options. | |
Protected Attributes | |
VMatLanguage | program |
IntVecFile | indexes |
Private Types | |
typedef SourceVMatrix | inherited |
Private Member Functions | |
void | build_ () |
This does the actual building. | |
Private Attributes | |
bool | build_complete |
A custom hack to make sure openIndex() is not called before the build is complete. |
|
Reimplemented from PLearn::SourceVMatrix. Definition at line 55 of file FilteredVMatrix.h. Referenced by FilteredVMatrix(). |
|
Default constructor.
Definition at line 50 of file FilteredVMatrix.cc. References inherited. |
|
Convenience constructor.
Definition at line 56 of file FilteredVMatrix.cc. References build_(). |
|
Should call simply inherited::build(), then this class's build_(). This method should be callable again at later times, after modifying some option fields to change the "architecture" of the object. Reimplemented from PLearn::SourceVMatrix. Definition at line 139 of file FilteredVMatrix.cc. References build_(), and build_complete. |
|
This does the actual building.
Reimplemented from PLearn::SourceVMatrix. Definition at line 125 of file FilteredVMatrix.cc. References build_complete, PLearn::VMatLanguage::compileString(), openIndex(), prg, program, PLearn::SourceVMatrix::setMetaInfoFromSource(), and PLearn::VMatLanguage::setSource(). Referenced by build(), and FilteredVMatrix(). |
|
Declares this class' options.
Reimplemented from PLearn::SourceVMatrix. Definition at line 115 of file FilteredVMatrix.cc. References PLearn::declareOption(), and PLearn::OptionList. |
|
This is the only method requiring implementation.
Reimplemented from PLearn::SourceVMatrix. Definition at line 108 of file FilteredVMatrix.cc. References indexes, PLearn::IntVecFile::length(), and PLERROR. |
|
Transforms a shallow copy into a deep copy.
Reimplemented from PLearn::SourceVMatrix. Definition at line 146 of file FilteredVMatrix.cc. |
|
Generates the index file if it does not already exist. If it exists and is up to date, simply opens it. Definition at line 71 of file FilteredVMatrix.cc. References PLearn::IntVecFile::append(), PLearn::IntVecFile::close(), PLearn::file_exists(), PLearn::VMatrix::getMetaDataDir(), PLearn::VMatrix::getMtime(), indexes, PLearn::IntVecFile::length(), PLearn::VMat::length(), PLearn::mtime(), PLearn::IntVecFile::open(), program, PLearn::rm(), PLearn::VMatLanguage::run(), PLearn::ProgressBar::update(), and PLearn::Vec. Referenced by build_(), and setMetaDataDir(). |
|
Declares name and deepCopy methods.
|
|
Also sets the source's meta-data dir if it's not already set. If there are fields that have no corresponding .smap .notes or .binning info files but the source has those files for a field with the same name, then those of the source will be set also for this vmatrix. Reimplemented from PLearn::SourceVMatrix. Definition at line 98 of file FilteredVMatrix.cc. References build_complete, and openIndex(). |
|
A custom hack to make sure openIndex() is not called before the build is complete.
Definition at line 61 of file FilteredVMatrix.h. Referenced by build(), build_(), and setMetaDataDir(). |
|
Definition at line 66 of file FilteredVMatrix.h. Referenced by getNewRow(), and openIndex(). |
|
Definition at line 78 of file FilteredVMatrix.h. Referenced by build_(). |
|
Definition at line 65 of file FilteredVMatrix.h. Referenced by build_(), and openIndex(). |