44 m_fIntensity = fIntensity;
87 printf(
"Reading intensity graph from: %s\n", sFilename.c_str());
90 infile.open(sFilename.c_str());
119 for (
auto& pNode : *pNodes)
136 infile >> nNumberNodes;
139 for (
int n = 0 ; n < nNumberNodes ; n++)
146 infile >> nNumberEdges;
148 for (
int e = 0 ; e < nNumberEdges ; e++)
154 catch (std::istream::failure&)
156 printf(
"ERROR: failed to write FeatureGraph to file\n");
174 infile >> fIntensity;
183 printf(
"Error input file inconsistent: %d %d\n", nTest, nIndex);
192 int nIndex1, nIndex2, nLeftFace, nRightFace;
198 infile >> nRightFace;
200 addEdge(nIndex1, nIndex2, nLeftFace, nRightFace);
209 int nNumberNodes = int(
m_Nodes.size());
211 outfile << nNumberNodes << std::endl;
214 for (
int n = 0 ; n < nNumberNodes ; n++)
220 int nNumberEdges = int(
m_Edges.size());
221 outfile << nNumberEdges << std::endl;
223 for (
int e = 0 ; e < nNumberEdges ; e++)
229 catch (std::ostream::failure&)
231 printf(
"ERROR: failed to write FeatureGraph to file\n");
242 outfile << pCurrentNode->
getIndex() << std::endl;
247 outfile << std::endl;
254 outfile << pCurrentEdge->
nIndex1 <<
" ";
255 outfile << pCurrentEdge->
nIndex2 <<
" ";
257 outfile << pCurrentEdge->
nLeftFace <<
" ";
260 outfile << std::endl;
268 for (
auto& i : *nodes)