From 26a433cebcf5a921ac2974631190c47fb63f4a21 Mon Sep 17 00:00:00 2001 From: delmon Date: Wed, 26 Jan 2011 12:58:23 +0000 Subject: [PATCH] Remove bug introduced in previeous patch about initial coeficients --- .../clitkMultipleBSplineDeformableTransformInitializer.txx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/registration/clitkMultipleBSplineDeformableTransformInitializer.txx b/registration/clitkMultipleBSplineDeformableTransformInitializer.txx index 1ee4be9..b6e8056 100644 --- a/registration/clitkMultipleBSplineDeformableTransformInitializer.txx +++ b/registration/clitkMultipleBSplineDeformableTransformInitializer.txx @@ -197,6 +197,7 @@ namespace clitk typename CoefficientReaderType::Pointer coeffReader = CoefficientReaderType::New(); std::vector coefficientImages; unsigned nLabels = m_Transform->GetnLabels(); + coefficientImages.resize(nLabels); int dotpos = s.length() - 1; while (dotpos >= 0 && s[dotpos] != '.') @@ -208,7 +209,7 @@ namespace clitk osfname << s.substr(0, dotpos) << '_' << i << s.substr(dotpos); coeffReader->SetFileName(osfname.str()); if (m_Verbose) - std::cout << "Reading initial coefficients from file: " << osfname << "..." << std::endl; + std::cout << "Reading initial coefficients from file: " << osfname.str() << "..." << std::endl; coeffReader->Update(); coefficientImages[i] = coeffReader->GetOutput(); } -- 2.47.1