Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
61 commits
Select commit Hold shift + click to select a range
b45ff00
allow Gaussian smoothing with scale 0 (=identity filter)
ukoethe Feb 4, 2016
cfd23e2
vigranumpy: relaxed the axistags rules in ufuncs
ukoethe Feb 4, 2016
4757aa9
vigranumpy: improved documentation of slicSuperpixels() (and minor cl…
ukoethe Feb 4, 2016
52744bb
Promoted version to 1.11.0
ukoethe Feb 4, 2016
ed3a62b
vigranumpy: fixed gaussianDerivative() (fix by S. Peter)
ukoethe Feb 8, 2016
779fd5f
Added vigranumpy tests for multidef functions.
dagophil Feb 9, 2016
0c45392
Added more vigranumpy tests for multidef functions.
dagophil Feb 9, 2016
c060eef
Removed duplicate definition of vigra.filters.distanceTransform.
dagophil Feb 10, 2016
cde5ed1
Fixed vigranumpy tests for multidef distance transform.
dagophil Feb 10, 2016
167be93
Merge remote-tracking branch 'philip/multideftests' into version-1-11-rc
ukoethe Feb 11, 2016
488300d
pythonaccumulator.hxx: Fixed signature of PythonRegionFeatureAccumula…
stuarteberg Feb 19, 2016
bf32637
python: Added applyMapping() function (transforms an array based on a…
stuarteberg Feb 22, 2016
87718d2
travis: Download Boost.Python bottle from casacore's bintray.
jakirkham Feb 23, 2016
a2e3c7d
Merge pull request #333 from jakirkham/use_boost_python_bottle
ukoethe Feb 23, 2016
3aec9ba
Merge remote-tracking branch 'stuart/add-python-applymapping' into ve…
ukoethe Feb 23, 2016
d3e4b29
Merge remote-tracking branch 'stuart/fix-acc-remapping-merge' into ve…
ukoethe Feb 23, 2016
65747a5
travis: Clean build intermediates before testing.
jakirkham Feb 23, 2016
3a2b405
travis: Install packages simply.
jakirkham Feb 24, 2016
f5f7ecf
travis: Uninstall only unneeded packages from brew.
jakirkham Feb 24, 2016
4cc483f
travis: Include the python version in homebrew deps string.
jakirkham Feb 24, 2016
e2f7ab8
travis: Update pip and setuptools on all supported platforms.
jakirkham Feb 24, 2016
840c994
travis: Skip updating brew.
jakirkham Feb 24, 2016
d3d8f8b
Merge pull request #335 from jakirkham/travis_brew_no_update
ukoethe Feb 24, 2016
636d46d
vigranumpy: make sure that singleton axes have non-zero stride (fixes…
ukoethe Feb 24, 2016
9f65e73
vigranumpy: added converters for numpy's number types
ukoethe Feb 24, 2016
3713648
test_segmentation: Eliminated unecessary scalar conversions.
stuarteberg Feb 24, 2016
e53e1a2
Merge pull request #337 from stuarteberg/scalar-converters
ukoethe Feb 24, 2016
4decdf2
Merge pull request #336 from ukoethe/scalar-converters
ukoethe Feb 24, 2016
d2734b6
cmake: improved FindOpenEXR
ukoethe Feb 24, 2016
c223cb6
fixed impex PositionTest
ukoethe Feb 24, 2016
de6e5b5
enhanced vigra.taggedView()
ukoethe Feb 24, 2016
b22d61f
extended acknowledgments
ukoethe Feb 24, 2016
5f00ef8
vigranumpy: added precondition for zero strides
ukoethe Feb 25, 2016
3c92620
fixed ArrayVector operator<<()
ukoethe Feb 26, 2016
f2353da
restricted BSpline to order < 18 and hardwired prefilter coefficients
ukoethe Feb 26, 2016
56a1044
Added new feature accumulation for the RAG to export_graph_rag_visito…
constantinpape Feb 22, 2016
66b65c8
Merge remote-tracking branch 'consti/master' into version-1-11-rc
ukoethe Feb 26, 2016
b4d2a37
fixed isinf() and isfinite() fallbacks on Windows
ukoethe Feb 26, 2016
f5b1056
python: Added unique()
stuarteberg Feb 26, 2016
d8fbeef
python: Added relabelConsecutive()
stuarteberg Feb 26, 2016
3b5a76b
python: relabelConsecutive(): Don't cache labelmap.end() outside the …
stuarteberg Feb 27, 2016
121422a
python: relabelConsecutive() returns a tuple (newlabels, maxlabel, ma…
stuarteberg Feb 27, 2016
4921270
python: segmentation: Replace boost::unordered with std::unordered
stuarteberg Feb 27, 2016
9f9f9cd
Merge pull request #339 from stuarteberg/add-relabel-consecutive
ukoethe Feb 28, 2016
e4c9458
Merge branch 'version-1-11-rc' of github.com:ukoethe/vigra into versi…
ukoethe Feb 28, 2016
c152a0e
Tentative bugfix for an out-of-bounds read in watershed3d.
bluescarni Mar 1, 2016
ffdad2c
multiarray: fix a problem in the test where an end() iterator would b…
bluescarni Mar 1, 2016
5efc679
fixed StridedScanOrderIterator stream output
ukoethe Mar 2, 2016
721ddfe
Any: rename the release() function to destroy() and make it delete th…
bluescarni Mar 2, 2016
a378732
Merge pull request #340 from bluescarni/bounds_fix
ukoethe Mar 2, 2016
922f33a
recursive approximation of convolution w/ Gaussians
Feb 11, 2016
91de78a
test impulse responses
Feb 29, 2016
36f9312
halfway there
Mar 1, 2016
53f9d1a
convert some c99-style code to c++ style code to fix compile errors o…
Mar 2, 2016
2ac1ed4
(still) broken vyv border treatment
Mar 2, 2016
f6e02b1
c++ is strange
Mar 2, 2016
1371303
fixes for gcc 4.6 and msvc
Mar 2, 2016
e714e97
more fixes for old compilers
Mar 2, 2016
1e07410
minor cleanup
Mar 2, 2016
67e5bba
disable VYV filters for now, deriche should pass tests
Mar 2, 2016
f0d5a1b
more outdated c++ for window builds *sigh*
Mar 3, 2016
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 8 additions & 15 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,11 @@ matrix:
- os: osx
osx_image: xcode7.3
language: generic
env: TRAVIS_PYTHON_VERSION="2"
env: TRAVIS_PYTHON_VERSION="2" BREW_DEPS="cmake\nhdf5\nboost\nlibjpeg\nlibtiff\nlibpng\nfftw\nreadline\npython"
- os: osx
osx_image: xcode7.3
language: generic
env: TRAVIS_PYTHON_VERSION="3"
env: TRAVIS_PYTHON_VERSION="3" BREW_DEPS="cmake\nhdf5\nboost\nlibjpeg\nlibtiff\nlibpng\nfftw\nreadline\npython3"


addons:
Expand All @@ -43,29 +43,22 @@ addons:

before_script:
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then export PATH="/usr/local/bin:${PATH}" ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew remove --force $(brew list); brew cleanup --force ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then travis_retry brew update ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew tap homebrew/science ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install cmake ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install hdf5 ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install boost ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install libjpeg ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install libtiff ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install libpng ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install fftw ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install readline ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]] && [[ ${TRAVIS_PYTHON_VERSION:0:1} -eq 2 ]]; then brew install python ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]] && [[ ${TRAVIS_PYTHON_VERSION:0:1} -eq 3 ]]; then brew install python3 ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew remove --force $(grep -v -F -x -f <(cat <(brew deps --skip-optional --union $(echo -e $BREW_DEPS)) <(echo -e $BREW_DEPS)) <(cat <(brew leaves) <(brew deps --skip-optional --union $(brew leaves)))); brew cleanup --force ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install $(echo -e $BREW_DEPS) || true ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]] && [[ ${TRAVIS_PYTHON_VERSION:0:1} -eq 3 ]]; then sudo ln -s /usr/local/bin/pip3 /usr/local/bin/pip ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]] && [[ ${TRAVIS_PYTHON_VERSION:0:1} -eq 3 ]]; then sudo ln -s /usr/local/bin/python3 /usr/local/bin/python ; fi
- if [[ "$TRAVIS_PYTHON_VERSION" == "3.2" ]]; then pip install --upgrade 'pip<8' 'setuptools<19' ; fi
- if [[ "$TRAVIS_PYTHON_VERSION" != "3.2" ]]; then pip install --upgrade pip setuptools ; fi
- pip install nose
- pip install numpy
- if [[ "$TRAVIS_OS_NAME" == "osx" ]] && [[ ${TRAVIS_PYTHON_VERSION:0:1} -eq 2 ]]; then brew install boost-python --with-python ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]] && [[ ${TRAVIS_PYTHON_VERSION:0:1} -eq 3 ]]; then brew install boost-python --without-python --with-python3 ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]] && [[ ${TRAVIS_PYTHON_VERSION:0:1} -eq 3 ]]; then curl -L -O https://bintray.com/artifact/download/casacore/homebrew-bottles/boost-python-1.60.0.el_capitan.bottle.1.tar.gz && brew install ./boost-python-1.60.0.el_capitan.bottle.1.tar.gz ; rm -f ./boost-python-1.60.0.el_capitan.bottle.1.tar.gz ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew cleanup --force -s; sudo rm -rf $(brew --cache) ; fi

script:
- mkdir build && cd build
- cmake -DCMAKE_BUILD_TYPE=Release -DTEST_VIGRANUMPY=1 -DDEPENDENCY_SEARCH_PREFIX=$VIRTUAL_ENV -DAUTOBUILD_TESTS=1 -DAUTOEXEC_TESTS=0 -DWITH_BOOST_THREAD=$WITH_BOOST_THREAD -DBoost_DEBUG=1 -DPYTHON_VERSION=${TRAVIS_PYTHON_VERSION:0:3} ..
- make
- find . -name "*.o" | xargs rm -v
- ctest --output-on-failure
37 changes: 30 additions & 7 deletions config/FindOpenEXR.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -25,20 +25,43 @@

FIND_PATH(OPENEXR_INCLUDE_DIR ImfRgbaFile.h PATH_SUFFIXES OpenEXR)

FIND_LIBRARY(OPENEXR_ILMIMF_LIBRARY NAMES IlmImf)
FIND_LIBRARY(OPENEXR_IMATH_LIBRARY NAMES Imath)
FOREACH(V "" -2_2 -2_1 -2_0 -1_7)
if(NOT OPENEXR_ILMIMF_LIBRARY)
FIND_LIBRARY(OPENEXR_ILMIMF_LIBRARY NAMES IlmImf${V})
if(OPENEXR_ILMIMF_LIBRARY)
set(OPENEXR_VERSION ${V})
endif()
endif()
ENDFOREACH(V)

FIND_LIBRARY(OPENEXR_IMATH_LIBRARY NAMES Imath${OPENEXR_VERSION})
FIND_LIBRARY(OPENEXR_IEX_LIBRARY NAMES Iex${OPENEXR_VERSION})
FIND_LIBRARY(OPENEXR_ILMTHREAD_LIBRARY NAMES IlmThread${OPENEXR_VERSION})
FIND_LIBRARY(OPENEXR_HALF_LIBRARY NAMES Half)
FIND_LIBRARY(OPENEXR_IEX_LIBRARY NAMES Iex)
FIND_LIBRARY(OPENEXR_ILMTHREAD_LIBRARY NAMES IlmThread)

INCLUDE(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(OPENEXR DEFAULT_MSG
FIND_PACKAGE_HANDLE_STANDARD_ARGS(OpenEXR DEFAULT_MSG
OPENEXR_HALF_LIBRARY OPENEXR_IEX_LIBRARY OPENEXR_IMATH_LIBRARY
OPENEXR_ILMIMF_LIBRARY OPENEXR_INCLUDE_DIR
)

IF(OPENEXR_FOUND)
IF(OpenEXR_FOUND)
SET(OPENEXR_LIBRARIES ${OPENEXR_ILMIMF_LIBRARY}
${OPENEXR_IMATH_LIBRARY} ${OPENEXR_HALF_LIBRARY}
${OPENEXR_IEX_LIBRARY} ${OPENEXR_ILMTHREAD_LIBRARY} )
ENDIF(OPENEXR_FOUND)

if(MSVC)
execute_process(
COMMAND lib /list "${OPENEXR_HALF_LIBRARY}"
OUTPUT_VARIABLE OPENEXR_HALF_CONTENTS)
if(OPENEXR_HALF_CONTENTS MATCHES "Half.dll")
SET(OPENEXR_CPPFLAGS -DOPENEXR_DLL)
endif()
endif()
ELSE()
SET(OPENEXR_ILMIMF_LIBRARY OPENEXR_ILMIMF_LIBRARY-NOTFOUND)
SET(OPENEXR_IMATH_LIBRARY OPENEXR_IMATH_LIBRARY-NOTFOUND)
SET(OPENEXR_IEX_LIBRARY OPENEXR_IEX_LIBRARY-NOTFOUND)
SET(OPENEXR_ILMTHREAD_LIBRARY OPENEXR_ILMTHREAD_LIBRARY-NOTFOUND)
SET(OPENEXR_HALF_LIBRARY OPENEXR_HALF_LIBRARY-NOTFOUND)
ENDIF()
2 changes: 2 additions & 0 deletions docsrc/credits_changelog.dxx
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@

<li> Benjamin Seppke contributed various \ref Registration "image registration" algorithms.

<li> John Kirkham figured out how to configure Travis to run tests for Python3 and on OS X.

<li> Numerous people reported and fixed bugs and made suggestions.
</ul>

Expand Down
6 changes: 3 additions & 3 deletions include/vigra/any.hxx
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ VIGRA_ANY_OF_CONVERTIBLE(long double)
assert(a.cast<double>() == 20.0);

// delete the stored value
a.release();
a.destroy();
assert(a.empty());
assert(a == false);

Expand Down Expand Up @@ -275,9 +275,9 @@ class Any

/** Delete the contained object (make this 'Any' object empty).
*/
void release()
void destroy()
{
handle_.release();
handle_.reset((detail::AnyHandle*)0);
}

/** Exchange the value of this object with other's.
Expand Down
2 changes: 1 addition & 1 deletion include/vigra/array_vector.hxx
Original file line number Diff line number Diff line change
Expand Up @@ -956,7 +956,7 @@ namespace std {
template <class T>
ostream & operator<<(ostream & s, vigra::ArrayVectorView<T> const & a)
{
for(std::size_t k=0; k<a.size()-1; ++k)
for(std::ptrdiff_t k=0; k<(std::ptrdiff_t)a.size()-1; ++k)
s << a[k] << ", ";
if(a.size())
s << a.back();
Expand Down
4 changes: 2 additions & 2 deletions include/vigra/config_version.hxx
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,8 @@
#define VIGRA_CONFIG_VERSION_HXX

#define VIGRA_VERSION_MAJOR 1
#define VIGRA_VERSION_MINOR 10
#define VIGRA_VERSION_MINOR 11
#define VIGRA_VERSION_PATCH 0
#define VIGRA_VERSION "1.10.0"
#define VIGRA_VERSION "1.11.0"

#endif /* VIGRA_CONFIG_VERSION_HXX */
102 changes: 102 additions & 0 deletions include/vigra/kerneltraits.hxx
Original file line number Diff line number Diff line change
@@ -0,0 +1,102 @@
//-- -*- c++ -*-
/************************************************************************/
/* */
/* Copyright 2016 by Sven Peter and Ullrich Koethe */
/* */
/* This file is part of the VIGRA computer vision library. */
/* The VIGRA Website is */
/* http://hci.iwr.uni-heidelberg.de/vigra/ */
/* Please direct questions, bug reports, and contributions to */
/* ullrich.koethe@iwr.uni-heidelberg.de or */
/* vigra@informatik.uni-hamburg.de */
/* */
/* Permission is hereby granted, free of charge, to any person */
/* obtaining a copy of this software and associated documentation */
/* files (the "Software"), to deal in the Software without */
/* restriction, including without limitation the rights to use, */
/* copy, modify, merge, publish, distribute, sublicense, and/or */
/* sell copies of the Software, and to permit persons to whom the */
/* Software is furnished to do so, subject to the following */
/* conditions: */
/* */
/* The above copyright notice and this permission notice shall be */
/* included in all copies or substantial portions of the */
/* Software. */
/* */
/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND */
/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES */
/* OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND */
/* NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT */
/* HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, */
/* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING */
/* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR */
/* OTHER DEALINGS IN THE SOFTWARE. */
/* */
/************************************************************************/

#ifndef VIGRA_KERNEL_H
#define VIGRA_KERNEL_H

#include <type_traits>

namespace vigra {
namespace detail {

struct fir_kernel_tag {};
struct iir_kernel_tag {};
struct gaussian_kernel_tag {};

template<typename X>
struct is_kernel
{
template <typename Y>
static char test(int, typename Y::vigra_kernel_category*);

template <typename Y>
static int test(int, ...);

static const bool value = (sizeof(char) == sizeof(test<X>(0,0)));
};

template<typename X, bool = is_kernel<X>::value >
struct is_fir_kernel
{
static const bool value = std::is_same<typename X::vigra_kernel_category, fir_kernel_tag>::value;
};

template<typename X, bool = is_kernel<X>::value >
struct is_iir_kernel
{
static const bool value = std::is_same<typename X::vigra_kernel_category, iir_kernel_tag>::value;
};

template<typename X, bool = is_kernel<X>::value >
struct is_gaussian_kernel
{
static const bool value = std::is_same<typename X::vigra_kernel_category, gaussian_kernel_tag>::value;
};

template<typename X>
struct is_fir_kernel<X, false>
{
static const bool value = false;
};

template<typename X>
struct is_iir_kernel<X, false>
{
static const bool value = false;
};

template<typename X>
struct is_gaussian_kernel<X, false>
{
static const bool value = false;
};


} // namespace detail

} // namespace vigra

#endif
17 changes: 16 additions & 1 deletion include/vigra/mathutil.hxx
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,10 @@
#ifndef M_EULER_GAMMA
# define M_EULER_GAMMA 0.5772156649015329
#endif

#ifndef M_SQRT2PI
# define M_SQRT2PI 2.50662827463100050241576528481104525
#endif
\endcode
*/
#ifndef M_PI
Expand Down Expand Up @@ -114,6 +118,10 @@
# define M_EULER_GAMMA 0.5772156649015329
#endif

#ifndef M_SQRT2PI
# define M_SQRT2PI 2.50662827463100050241576528481104525
#endif

namespace vigra {

/** \addtogroup MathFunctions Mathematical Functions
Expand Down Expand Up @@ -163,13 +171,14 @@ VIGRA_DEFINE_MISSING_ABS(signed long long)

using std::isinf;
using std::isnan;
using std::isfinite;

#else

template <class REAL>
inline bool isinf(REAL v)
{
return _finite(v) == 0;
return _finite(v) == 0 && _isnan(v) == 0;
}

template <class REAL>
Expand All @@ -178,6 +187,12 @@ inline bool isnan(REAL v)
return _isnan(v) != 0;
}

template <class REAL>
inline bool isfinite(REAL v)
{
return _finite(v) != 0;
}

#endif

// scalar dot is needed for generic functions that should work with
Expand Down
Loading