-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove some placeholders
- Loading branch information
Showing
18 changed files
with
295 additions
and
392 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
version: 2 | ||
jobs: | ||
build-and-test: | ||
working_directory: /ITKTotalVariation-build | ||
docker: | ||
- image: insighttoolkit/module-ci:latest | ||
steps: | ||
- checkout: | ||
path: /ITKTotalVariation | ||
- run: | ||
name: Fetch CTest driver script | ||
command: | | ||
curl -L https://raw.githubusercontent.com/InsightSoftwareConsortium/ITK/dashboard/itk_common.cmake -O | ||
- run: | ||
name: Configure CTest script | ||
command: | | ||
SHASNIP=$(echo $CIRCLE_SHA1 | cut -c1-7) | ||
cat > dashboard.cmake << EOF | ||
set(CTEST_SITE "CircleCI") | ||
set(CTEST_BUILD_NAME "External-ITKTotalVariation-${CIRCLE_BRANCH}-${CIRCLE_BUILD_NUM}-${SHASNIP}") | ||
set(CTEST_BUILD_CONFIGURATION "MinSizeRel") | ||
set(CTEST_CMAKE_GENERATOR "Unix Makefiles") | ||
set(CTEST_BUILD_FLAGS: "-j5") | ||
set(CTEST_SOURCE_DIRECTORY /ITKTotalVariation) | ||
set(CTEST_BINARY_DIRECTORY /ITKTotalVariation-build) | ||
set(dashboard_model Experimental) | ||
set(dashboard_no_clean 1) | ||
set(dashboard_cache " | ||
ITK_DIR:PATH=/ITK-build | ||
BUILD_TESTING:BOOL=ON | ||
") | ||
include(\${CTEST_SCRIPT_DIRECTORY}/itk_common.cmake) | ||
EOF | ||
- run: | ||
name: Build and Test | ||
no_output_timeout: 1.0h | ||
command: | | ||
ctest -j 2 -VV -S dashboard.cmake | ||
package: | ||
working_directory: ~/ITKTotalVariation | ||
machine: true | ||
steps: | ||
- checkout | ||
- run: | ||
name: Fetch build script | ||
command: | | ||
curl -L https://raw.githubusercontent.com/InsightSoftwareConsortium/ITKPythonPackage/master/scripts/dockcross-manylinux-download-cache-and-build-module-wheels.sh -O | ||
chmod u+x dockcross-manylinux-download-cache-and-build-module-wheels.sh | ||
- run: | ||
name: Build Python packages | ||
no_output_timeout: 1.0h | ||
command: | | ||
./dockcross-manylinux-download-cache-and-build-module-wheels.sh | ||
- store_artifacts: | ||
path: dist | ||
destination: dist | ||
|
||
workflows: | ||
version: 2 | ||
build-test-package: | ||
jobs: | ||
- build-and-test | ||
- package |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
sudo: true | ||
language: cpp | ||
os: | ||
- osx | ||
compiler: | ||
- gcc | ||
cache: | ||
directories: | ||
- "$HOME/Library/Caches/Homebrew" | ||
script: | ||
- curl -L https://raw.githubusercontent.com/InsightSoftwareConsortium/ITKPythonPackage/master/scripts/macpython-download-cache-and-build-module-wheels.sh -O | ||
- chmod u+x macpython-download-cache-and-build-module-wheels.sh | ||
- ./macpython-download-cache-and-build-module-wheels.sh | ||
- tar -zcvf dist.tar.gz dist/ | ||
- curl --upload-file dist.tar.gz https://transfer.sh/dist.tar.gz |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,86 @@ | ||
/*========================================================================= | ||
* | ||
* Copyright Insight Software Consortium | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0.txt | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
* | ||
*=========================================================================*/ | ||
#ifndef itkMyFilter_h | ||
#define itkMyFilter_h | ||
|
||
#include "itkImageToImageFilter.h" | ||
|
||
namespace itk | ||
{ | ||
|
||
/** \class MyFilter | ||
* | ||
* \brief Filters a image by iterating over its pixels. | ||
* | ||
* Filters a image by iterating over its pixels in a multi-threaded way | ||
* and {to be completed by the developer}. | ||
* | ||
* \ingroup TotalVariation | ||
* | ||
*/ | ||
template< typename TInputImage, typename TOutputImage > | ||
class MyFilter: public ImageToImageFilter< TInputImage, TOutputImage > | ||
{ | ||
public: | ||
ITK_DISALLOW_COPY_AND_ASSIGN(MyFilter); | ||
|
||
static constexpr unsigned int InputImageDimension = TInputImage::ImageDimension; | ||
static constexpr unsigned int OutputImageDimension = TOutputImage::ImageDimension; | ||
|
||
using InputImageType = TInputImage; | ||
using OutputImageType = TInputImage; | ||
using InputPixelType = typename InputImageType::PixelType; | ||
using OutputPixelType = typename OutputImageType::PixelType; | ||
|
||
/** Standard class typedefs. */ | ||
using Self = MyFilter< InputImageType, OutputImageType >; | ||
using Superclass = ImageToImageFilter< InputImageType, OutputImageType >; | ||
using Pointer = SmartPointer< Self >; | ||
using ConstPointer = SmartPointer< const Self >; | ||
|
||
/** Run-time type information. */ | ||
itkTypeMacro( MyFilter, ImageToImageFilter ); | ||
|
||
/** Standard New macro. */ | ||
itkNewMacro( Self ); | ||
|
||
protected: | ||
MyFilter(); | ||
virtual ~MyFilter() override {} | ||
|
||
void PrintSelf( std::ostream& os, Indent indent ) const override; | ||
|
||
typedef typename OutputImageType::RegionType OutputRegionType; | ||
|
||
virtual void DynamicThreadedGenerateData( const OutputRegionType & outputRegion) override; | ||
|
||
private: | ||
|
||
|
||
#ifdef ITK_USE_CONCEPT_CHECKING | ||
// Add concept checking such as | ||
// itkConceptMacro( FloatingPointPixel, ( itk::Concept::IsFloatingPoint< typename InputImageType::PixelType > ) ); | ||
#endif | ||
}; | ||
} | ||
|
||
#ifndef ITK_MANUAL_INSTANTIATION | ||
#include "itkMyFilter.hxx" | ||
#endif | ||
|
||
#endif // itkMyFilter |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
/*========================================================================= | ||
* | ||
* Copyright Insight Software Consortium | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0.txt | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
* | ||
*=========================================================================*/ | ||
#ifndef itkMyFilter_hxx | ||
#define itkMyFilter_hxx | ||
|
||
#include "itkMyFilter.h" | ||
|
||
#include "itkImageRegionIterator.h" | ||
#include "itkImageRegionConstIterator.h" | ||
|
||
namespace itk | ||
{ | ||
|
||
template< typename TInputImage, typename TOutputImage > | ||
MyFilter< TInputImage, TOutputImage > | ||
::MyFilter() | ||
{ | ||
} | ||
|
||
|
||
template< typename TInputImage, typename TOutputImage > | ||
void | ||
MyFilter< TInputImage, TOutputImage > | ||
::PrintSelf( std::ostream& os, Indent indent ) const | ||
{ | ||
Superclass::PrintSelf( os, indent ); | ||
} | ||
|
||
|
||
template< typename TInputImage, typename TOutputImage > | ||
void | ||
MyFilter< TInputImage, TOutputImage > | ||
::DynamicThreadedGenerateData( const OutputRegionType & outputRegion) | ||
{ | ||
OutputImageType * output = this->GetOutput(); | ||
const InputImageType * input = this->GetInput(); | ||
using InputRegionType = typename InputImageType::RegionType; | ||
InputRegionType inputRegion = InputRegionType(outputRegion.GetSize()); | ||
|
||
itk::ImageRegionConstIterator<InputImageType> in(input, inputRegion); | ||
itk::ImageRegionIterator<OutputImageType> out(output, outputRegion); | ||
|
||
for (in.GoToBegin(), out.GoToBegin(); !in.IsAtEnd() && !out.IsAtEnd(); ++in, ++out) | ||
{ | ||
out.Set( in.Get() ); | ||
} | ||
} | ||
|
||
} // end namespace itk | ||
|
||
#endif // itkMyFilter_hxx |
Oops, something went wrong.