Home || Visual Search || Applications || Architecture || Important Messages || OGL || Src

void Impala::Application::Util::DoDumpParameter (  ) 

Definition at line 1133 of file mainUtil.cpp.

References Impala::CmdOptions::GetArg(), Impala::Util::PropertySet::GetDouble(), Impala::CmdOptions::GetInstance(), Impala::CmdOptions::GetNrArg(), ILOG_ERROR, ILOG_VAR, and Impala::Core::Database::MakeRawDataSet().

Referenced by mainUtil().

01134 {
01135     typedef Core::Database::RawDataSet RawDataSet;
01136     typedef Core::Feature::FeatureDefinition FeatureDef;
01137 
01138     ILOG_VAR(Impala.Application.Util.DoDumpParameter);
01139     CmdOptions& options = CmdOptions::GetInstance();
01140     if (options.GetNrArg() < 5)
01141     {
01142         ILOG_ERROR("Need more parameters");
01143         return;
01144     }
01145     String dataSetName = options.GetArg(1);
01146     String conceptSet = options.GetArg(2);
01147     String model = options.GetArg(3);
01148     String feature = options.GetArg(4);
01149 
01150     RawDataSet* dataSet = Core::Database::MakeRawDataSet(dataSetName);
01151     KeywordListLocator keyLoc(dataSet->GetLocator(), conceptSet);
01152     Core::Table::KeywordList concepts = *(KeywordListRepository().Get(keyLoc));
01153 
01154     ModelLocator modelLoc(dataSet->GetLocator(), conceptSet, model, feature, "");
01155     Real64 map = 0;
01156     int nrMap = 0;
01157     std::cout << "parameter best for " << conceptSet << "  " << model << "  "
01158               << feature << std::endl;
01159     for (int c=0 ; c<concepts.size() ; c++)
01160     {
01161         String con = concepts[c];
01162         modelLoc.SetConcept(con);
01163         Impala::Util::PropertySet* props = BestFileRepository().Get(modelLoc);
01164         Real64 ap = props->GetDouble("value", 0.0);
01165         std::cout << con << " " << ap << std::endl;
01166         map += ap;
01167         nrMap++;
01168     }
01169     std::cout << "map = " << map / nrMap << std::endl << std::endl;
01170 }

Here is the call graph for this function:


Generated on Thu Jan 13 09:16:28 2011 for ImpalaSrc by  doxygen 1.5.1