Skip to content

Commit

Permalink
Patch image short test
Browse files Browse the repository at this point in the history
  • Loading branch information
nyoungbq committed Dec 13, 2024
1 parent ae81266 commit eb345e3
Show file tree
Hide file tree
Showing 3 changed files with 39 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ using ArrayOptionsType = ITK::ScalarPixelIdTypeList;
template <class PixelT>
using FilterOutputTypeUI8 = uint8;

template <class PixelT>
using FilterOutputTypeI16 = int16;

template <class PixelT>
using FilterOutputTypeUI16 = uint16;

Expand Down Expand Up @@ -150,6 +153,11 @@ IFilter::PreflightResult ITKMaximumProjectionImageFilter::preflightImpl(const Da
ITK::DataCheck<cxITKMaximumProjectionImageFilter::ArrayOptionsType, cxITKMaximumProjectionImageFilter::FilterOutputTypeUI8>(dataStructure, selectedInputArray, imageGeomPath, outputArrayPath);
break;
}
case DataType::int16: {
helperOutputActions =
ITK::DataCheck<cxITKMaximumProjectionImageFilter::ArrayOptionsType, cxITKMaximumProjectionImageFilter::FilterOutputTypeI16>(dataStructure, selectedInputArray, imageGeomPath, outputArrayPath);
break;
}
case DataType::uint16: {
helperOutputActions =
ITK::DataCheck<cxITKMaximumProjectionImageFilter::ArrayOptionsType, cxITKMaximumProjectionImageFilter::FilterOutputTypeUI16>(dataStructure, selectedInputArray, imageGeomPath, outputArrayPath);
Expand All @@ -162,8 +170,6 @@ IFilter::PreflightResult ITKMaximumProjectionImageFilter::preflightImpl(const Da
}
case DataType::int8:
[[fallthrough]];
case DataType::int16:
[[fallthrough]];
case DataType::int32:
[[fallthrough]];
case DataType::uint32:
Expand Down Expand Up @@ -223,6 +229,11 @@ Result<> ITKMaximumProjectionImageFilter::executeImpl(DataStructure& dataStructu
outputArrayPath, itkFunctor, shouldCancel);
break;
}
case DataType::int16: {
result = ITK::Execute<cxITKMaximumProjectionImageFilter::ArrayOptionsType, cxITKMaximumProjectionImageFilter::FilterOutputTypeI16>(dataStructure, selectedInputArray, imageGeomPath,
outputArrayPath, itkFunctor, shouldCancel);
break;
}
case DataType::uint16: {
result = ITK::Execute<cxITKMaximumProjectionImageFilter::ArrayOptionsType, cxITKMaximumProjectionImageFilter::FilterOutputTypeUI16>(dataStructure, selectedInputArray, imageGeomPath,
outputArrayPath, itkFunctor, shouldCancel);
Expand All @@ -235,8 +246,6 @@ Result<> ITKMaximumProjectionImageFilter::executeImpl(DataStructure& dataStructu
}
case DataType::int8:
[[fallthrough]];
case DataType::int16:
[[fallthrough]];
case DataType::int32:
[[fallthrough]];
case DataType::uint32:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@ using ArrayOptionsType = ITK::ScalarPixelIdTypeList;
template <class PixelT>
using FilterOutputTypeUI8 = uint8;

template <class PixelT>
using FilterOutputTypeI16 = int16;

template <class PixelT>
using FilterOutputTypeUI16 = uint16;

Expand Down Expand Up @@ -153,6 +156,11 @@ IFilter::PreflightResult ITKMedianProjectionImageFilter::preflightImpl(const Dat
ITK::DataCheck<cxITKMedianProjectionImageFilter::ArrayOptionsType, cxITKMedianProjectionImageFilter::FilterOutputTypeUI8>(dataStructure, selectedInputArray, imageGeomPath, outputArrayPath);
break;
}
case DataType::int16: {
helperOutputActions =
ITK::DataCheck<cxITKMedianProjectionImageFilter::ArrayOptionsType, cxITKMedianProjectionImageFilter::FilterOutputTypeI16>(dataStructure, selectedInputArray, imageGeomPath, outputArrayPath);
break;
}
case DataType::uint16: {
helperOutputActions =
ITK::DataCheck<cxITKMedianProjectionImageFilter::ArrayOptionsType, cxITKMedianProjectionImageFilter::FilterOutputTypeUI16>(dataStructure, selectedInputArray, imageGeomPath, outputArrayPath);
Expand All @@ -165,8 +173,6 @@ IFilter::PreflightResult ITKMedianProjectionImageFilter::preflightImpl(const Dat
}
case DataType::int8:
[[fallthrough]];
case DataType::int16:
[[fallthrough]];
case DataType::int32:
[[fallthrough]];
case DataType::uint32:
Expand Down Expand Up @@ -227,6 +233,11 @@ Result<> ITKMedianProjectionImageFilter::executeImpl(DataStructure& dataStructur
itkFunctor, shouldCancel);
break;
}
case DataType::int16: {
result = ITK::Execute<cxITKMedianProjectionImageFilter::ArrayOptionsType, cxITKMedianProjectionImageFilter::FilterOutputTypeI16>(dataStructure, selectedInputArray, imageGeomPath, outputArrayPath,
itkFunctor, shouldCancel);
break;
}
case DataType::uint16: {
result = ITK::Execute<cxITKMedianProjectionImageFilter::ArrayOptionsType, cxITKMedianProjectionImageFilter::FilterOutputTypeUI16>(dataStructure, selectedInputArray, imageGeomPath, outputArrayPath,
itkFunctor, shouldCancel);
Expand All @@ -239,8 +250,6 @@ Result<> ITKMedianProjectionImageFilter::executeImpl(DataStructure& dataStructur
}
case DataType::int8:
[[fallthrough]];
case DataType::int16:
[[fallthrough]];
case DataType::int32:
[[fallthrough]];
case DataType::uint32:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ using ArrayOptionsType = ITK::ScalarPixelIdTypeList;
template <class PixelT>
using FilterOutputTypeUI8 = uint8;

template <class PixelT>
using FilterOutputTypeI16 = int16;

template <class PixelT>
using FilterOutputTypeUI16 = uint16;

Expand Down Expand Up @@ -150,6 +153,11 @@ IFilter::PreflightResult ITKMinimumProjectionImageFilter::preflightImpl(const Da
ITK::DataCheck<cxITKMinimumProjectionImageFilter::ArrayOptionsType, cxITKMinimumProjectionImageFilter::FilterOutputTypeUI8>(dataStructure, selectedInputArray, imageGeomPath, outputArrayPath);
break;
}
case DataType::int16: {
helperOutputActions =
ITK::DataCheck<cxITKMinimumProjectionImageFilter::ArrayOptionsType, cxITKMinimumProjectionImageFilter::FilterOutputTypeI16>(dataStructure, selectedInputArray, imageGeomPath, outputArrayPath);
break;
}
case DataType::uint16: {
helperOutputActions =
ITK::DataCheck<cxITKMinimumProjectionImageFilter::ArrayOptionsType, cxITKMinimumProjectionImageFilter::FilterOutputTypeUI16>(dataStructure, selectedInputArray, imageGeomPath, outputArrayPath);
Expand All @@ -162,8 +170,6 @@ IFilter::PreflightResult ITKMinimumProjectionImageFilter::preflightImpl(const Da
}
case DataType::int8:
[[fallthrough]];
case DataType::int16:
[[fallthrough]];
case DataType::int32:
[[fallthrough]];
case DataType::uint32:
Expand Down Expand Up @@ -223,6 +229,11 @@ Result<> ITKMinimumProjectionImageFilter::executeImpl(DataStructure& dataStructu
outputArrayPath, itkFunctor, shouldCancel);
break;
}
case DataType::int16: {
result = ITK::Execute<cxITKMinimumProjectionImageFilter::ArrayOptionsType, cxITKMinimumProjectionImageFilter::FilterOutputTypeI16>(dataStructure, selectedInputArray, imageGeomPath,
outputArrayPath, itkFunctor, shouldCancel);
break;
}
case DataType::uint16: {
result = ITK::Execute<cxITKMinimumProjectionImageFilter::ArrayOptionsType, cxITKMinimumProjectionImageFilter::FilterOutputTypeUI16>(dataStructure, selectedInputArray, imageGeomPath,
outputArrayPath, itkFunctor, shouldCancel);
Expand All @@ -235,8 +246,6 @@ Result<> ITKMinimumProjectionImageFilter::executeImpl(DataStructure& dataStructu
}
case DataType::int8:
[[fallthrough]];
case DataType::int16:
[[fallthrough]];
case DataType::int32:
[[fallthrough]];
case DataType::uint32:
Expand Down

0 comments on commit eb345e3

Please sign in to comment.