bugGNU Octave - Bugs: bug #61786, [octave forge] (image) many image...


bug #61786: [octave forge] (image) many image package test failures under Octave 7

Submitter:  Hartmut <hardy>
Submitted:  Mon 10 Jan 2022 12:11:12 PM UTC
Category:  Octave Forge Package Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Regression
Status:  Fixed Assigned to:  None
Originator Name:  Open/Closed:  * Closed
Release:  * 7.0.90 Operating System:  * Any
* Mandatory Fields

Add a New Comment (Rich Markup)

Comment Type & Canned Response:


( Jump to the original submission )

Fri 25 Mar 2022 05:37:51 PM UTC, comment #12: 

Closing as fixed, according to comment #11

Avinoam Kalma <avinoam>
Project Member
Fri 18 Mar 2022 08:39:33 PM UTC, comment #11: 

I have re-tested the image package with the latest Octave 7.0.92 release candidate (under linux only, so far). And now there are ZERO failing BIST tests, when running "pkg test image" any more. I think this is because bug #61788 has been fixed in core Octave, now.

If you don't hear anything from me in the next weeks, this issue can be CLOSED as fixed.

Hartmut <hardy>
Thu 13 Jan 2022 04:49:01 PM UTC, comment #10: 

With the current state of the latest Octave (stable) repository and the current state of the image-package repository, nearly all BIST tests of the image package now pass.

The only failing BIST that is left in the image-package is one single test in im2bw.m. This waits for a fix in core Octave, see bug #61788, regarding arrays of int types.

Hartmut <hardy>
Wed 12 Jan 2022 03:48:27 PM UTC, comment #9: 

Re comment #6: The interpreter can't check if a function is called with too few input arguments. That's the responsibility of the function itself.
It can (and does since Octave 7) check whether a function is called with more arguments than its prototype allows.

Markus M├╝tzel <mmuetzel>
Project Member
Mon 10 Jan 2022 10:33:39 PM UTC, comment #8: 

Oh, I see bug #61783 now. Sorry I missed it.

Arun Giridhar <arungiridhar>
Project Member
Mon 10 Jan 2022 10:00:25 PM UTC, comment #7: 

@Arun: Yes, the image package cannot even be installed, currently. This a known issue and is been worked on (in other bug reports). If you want to tests things out here, you can either use the Windows exe-installer, that comes with an pre-installed image package (this works because of some extra patches to mxe-octave). Or you just copy the relevant image package functions individually to a folder and then use Octave 7.0.90 to run them.

Hartmut <hardy>
Mon 10 Jan 2022 09:57:03 PM UTC, comment #6: 

Some failing BIST tests (at least the one in colorangle.m) are due to the new compiler behavior, that automatically throws error messages in user-defined functions with too few or too many input arguments. And this automatic error for too many input arguments does not have an error-id any  more.

I have filed a bug report for core Octave to ask if this could be changed or improved, to make life easier for packages: bug #61789.

Hartmut <hardy>
Mon 10 Jan 2022 09:54:09 PM UTC, comment #5: 

The image package cannot even be installed for me. I get the following errors and warnings on "pkg install -forge image":

Namespace collision error with Octave core, which prevents the package from building:

In file included from strel.cc:27:
In file included from /usr/local/include/octave-8.0.0/octave/../octave/parse.h:41:
In file included from /usr/local/include/octave-8.0.0/octave/pt-misc.h:32:
In file included from /usr/local/include/octave-8.0.0/octave/pt-decl.h:36:
In file included from /usr/local/include/octave-8.0.0/octave/pt-cmd.h:35:
In file included from /usr/local/include/octave-8.0.0/octave/pt-bp.h:35:
In file included from /usr/local/include/octave-8.0.0/octave/interpreter.h:47:
/usr/local/include/octave-8.0.0/octave/graphics.h:8214:21: error: redefinition of 'image' as different kind of
class OCTINTERP_API image : public base_graphics_object
./strel.h:50:13: note: previous definition is here
  namespace image

Multiple deprecated warnings from the Octave API about Range and fortran_vec:

hough_line.cc:50:59: warning: 'Range' is deprecated [-Wdeprecated-declarations]
  const ColumnVector thetas = (DEF_THETA) ? ColumnVector (Range (-M_PI/2.0, M_PI/2.0, M_PI/180.0).matrix_value ())
/usr/local/include/octave-8.0.0/octave/Range.h:427:3: note: 'Range' has been explicitly marked deprecated here
  OCTAVE_DEPRECATED (7, "use the 'octave::range<double>' class instead")
/usr/local/include/octave-8.0.0/octave/oct-conf-post-public.h:50:57: note: expanded from macro 'OCTAVE_DEPRECATED'
#    define OCTAVE_DEPRECATED(ver, msg) __attribute__ ((__deprecated__))

80 C++ warnings like these which can be fixed with "std::abs":

__custom_gaussian_smoothing__.cc:58:43: warning: using integer absolute value function 'abs' when argument is of
      floating point type [-Wabsolute-value]
              const octave_idx_type rur = abs (k*(ct*sqrtv2 - st*sqrtv1)); // 'rur' means 'row-upper-right'
__custom_gaussian_smoothing__.cc:58:43: note: use function 'std::abs' instead
              const octave_idx_type rur = abs (k*(ct*sqrtv2 - st*sqrtv1)); // 'rur' means 'row-upper-right'

Arun Giridhar <arungiridhar>
Project Member
Mon 10 Jan 2022 09:20:52 PM UTC, comment #4: 

The BIST failure in label2rgb.m was due to a missing input parameter in the shared BIST function. This is necessary for the automatic check of input parameter number in Octave 7. I added it with this commit:

Hartmut <hardy>
Mon 10 Jan 2022 09:05:07 PM UTC, comment #3: 

The above BIST failure in im2bw.m might also be a regression in core Octave 7.0.90. See bug #61788.

Hartmut <hardy>
Mon 10 Jan 2022 08:17:00 PM UTC, comment #2: 

The failing BIST in imlincomb.m due to the not yet hugging "--" operator should be fixed with this commit:

Hartmut <hardy>
Mon 10 Jan 2022 07:16:43 PM UTC, comment #1: 

The above BIST failures with connection to "hist" seem to be a regression in core Octave 7.0.90, see bug #61787.

Hartmut <hardy>
Mon 10 Jan 2022 12:11:12 PM UTC, original submission:  

Currently the release candidate 7.0.90 under Windows comes bundled with the latest released image package version (2.12.0.). Via some patches in mxe-octave to the image package, the image package installs fine (i.e. without errors during "pkg install") on Octave 7.

But: Running "pkg test image" under Octave 7.0.90 produces many failing tests, for several reasons. Several of the image package funtions probably not work at all under Octave 7. A first glance gave me the impression that some changes to core Octave result in those test failurs.

This issue is ment to collect and eventually solve these test failures. Here is a short overview of failing unit tests, including a short first comment to what the problem seems to be:

  • @imref2d/contains.m
    • something with the error-id
  • @imref2d\intrinsicToWorld.m
    • something with the error-id
  • @imref2d\worldToIntrinsic.m
  • @imref2d\worldToSubscript.m
  • @imref3d\contains.m
  • @imref3d\intrinsicToWorld.m
  • @imref3d\worldToIntrinsic.m
  • @imref3d\worldToSubscript.m
  • blockproc.m
    • those should be fixed already in the next image relase
  • colorangle.m
    • something with the error-id
  • graythresh.m
    • usage of hist changed?
  • im2bw.m
    • the "+=" operator seems to be obsolete now
  • imfindcircles.m
    • usage of hist changed?
  • imlincomb.m
    • the "--" operator seems to be obsolete now
  • integralImage3.m
    • changed error message
  • label2rgb.m
    • something with a function name as parameter
  • otsuthresh.m
    • something with the error-id

Probably some of those issues are also present in image package functions, that do not have any unit tests...

Hartmut <hardy>


(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:

No files currently attached


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -email is unavailable- added by avinoam (Posted a comment)
  • -email is unavailable- added by mmuetzel (Posted a comment)
  • -email is unavailable- added by arungiridhar (Posted a comment)
  • -email is unavailable- added by hardy (Submitted the item)
  • -email is unavailable- added by hardy
  • -email is unavailable- added by hardy

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only project members can vote.





    Follow 5 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2022-03-25 avinoam StatusNone Fixed
        Open/ClosedOpen Closed
        Operating SystemMicrosoft Windows Any
    2022-01-10 hardy Carbon-Copy- Added carandraug
        Carbon-Copy- Added avinoam

    Back to the top

    Powered by Savane 3.9