Skip to content

Commit

Permalink
Merge pull request #284 from thewtex/MutualInformationAffine-output-b…
Browse files Browse the repository at this point in the history
…aseline

MutualInformationAffine output baseline
  • Loading branch information
thewtex authored May 20, 2021
2 parents cc062d9 + 7eae01a commit 66b6352
Show file tree
Hide file tree
Showing 9 changed files with 13 additions and 10 deletions.
1 change: 1 addition & 0 deletions .github/workflows/build-test-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -278,6 +278,7 @@ jobs:
sudo apt-get install gnuplot dvipng
sudo apt-get install texlive-full
sudo apt-get install pandoc
sudo apt-get install imagemagick
python -m pip install --upgrade pip
python -m pip install ninja
Expand Down
4 changes: 3 additions & 1 deletion CMake/FindSphinx.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ option( SPHINX_EPUB_OUTPUT "Build HTML pages with additional information for bui
option( SPHINX_LATEX_OUTPUT "Build LaTeX sources that can be compiled to a PDF document using pdflatex." OFF )
option( SPHINX_MAN_OUTPUT "Build manual pages in groff format for UNIX systems." OFF )
option( SPHINX_TEXT_OUTPUT "Build plain text files." OFF )
option( SPHINX_LINKCHECK "Create a target that will check HTTP links." OFF )


mark_as_advanced(
Expand All @@ -77,6 +78,7 @@ mark_as_advanced(
SPHINX_LATEX_OUTPUT
SPHINX_MAN_OUTPUT
SPHINX_TEXT_OUTPUT
SPHINX_LINKCHECK
)

function( Sphinx_add_target target_name builder conf source destination )
Expand Down Expand Up @@ -152,7 +154,7 @@ function( Sphinx_add_targets target_base_name conf source base_destination )
add_dependencies( ${target_base_name}_text ${_dependencies} )
endif()

if( ${BUILD_TESTING} )
if( ${SPHINX_LINKCHECK} )
sphinx_add_target( ${target_base_name}_linkcheck linkcheck ${conf} ${source} ${base_destination}/linkcheck )

add_dependencies( ${target_base_name}_linkcheck ${_dependencies} )
Expand Down
2 changes: 1 addition & 1 deletion Formatting/conf.py.in
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ primary_domain = 'cpp'
# Add any Sphinx extension module names here, as strings. They can be extensions
# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
extensions = ['sphinx.ext.todo', 'sphinx.ext.imgmath', 'sphinx.ext.ifconfig',
'sphinx.ext.viewcode', 'breathe', 'doxylink', 'breathelink', 'nbsphinx']
'sphinx.ext.viewcode', 'sphinx.ext.imgconverter', 'breathe', 'doxylink', 'breathelink', 'nbsphinx']

# Add any paths that contain templates here, relative to this directory.
templates_path = ['templates']
Expand Down
2 changes: 2 additions & 0 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ If building the documentation:
- nbsphinx_
- gnuplot_
- dvipng_ ( for rendered equations )
- imagemagick_

PDF generation requires a TeX distribution like `TeX Live`_ or MiKTeX_.

Expand All @@ -96,3 +97,4 @@ Run the bash script ``SetupForDevelopment.sh``::
.. _dvipng: https://sourceforge.net/projects/dvipng/
.. _Pandoc: https://pandoc.org/
.. _nbsphinx: https://nbsphinx.readthedocs.io/
.. _imagemagick: https://www.imagemagick.org/
1 change: 1 addition & 0 deletions Superbuild/Superbuild.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ if(BUILD_DOCUMENTATION)
"-DSPHINX_MAN_OUTPUT:BOOL=${SPHINX_MAN_OUTPUT}"
"-DSPHINX_QTHELP_OUTPUT:BOOL=${SPHINX_QTHELP_OUTPUT}"
"-DSPHINX_TEXT_OUTPUT:BOOL=${SPHINX_TEXT_OUTPUT}"
"-DSPHINX_LINKCHECK:BOOL=${SPHINX_LINKCHECK}"
)
endif()

Expand Down
2 changes: 0 additions & 2 deletions src/Core/Transform/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,6 @@ compare_to_baseline(EXAMPLE_NAME GlobalRegistrationTwoImagesAffine
add_example(MutualInformationAffine)
compare_to_baseline(EXAMPLE_NAME MutualInformationAffine
BASELINE_PREFIX
fixed
moving
OutputBaseline
)

Expand Down
3 changes: 1 addition & 2 deletions src/Core/Transform/MutualInformationAffine/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,4 @@ add_test(NAME MutualInformationAffineTest
COMMAND ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/MutualInformationAffine
fixed.png
moving.png
output.png)

Output.png)
6 changes: 3 additions & 3 deletions src/Core/Transform/MutualInformationAffine/Documentation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -25,17 +25,17 @@ Results
.. figure:: fixed.png
:alt: fixed.png

fixed.png
Fixed

.. figure:: moving.png
:alt: moving.png

moving.png
Moving

.. figure:: OutputBaseline.png
:alt: OutputBaseline.png

OutputBaseline.png
Output

Output::

Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
46a0c840567a4eee4a3150674d78fecf7d0395c61c7de697218c0b408919587e4a39f7c307b7bbe144613e0c72bf8eb45f3f59a6b140f1b443bffa0a611aae1e
84bfbdda46574ed22a06b44f12d3bfa36ca86f384d39a7ca724eb7da0824f27e5d66e995200596ce62a6354994e24629b69776454a33c4199604eedbcacff7d2

2 comments on commit 66b6352

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.