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


bug #44799: [octave forge] (image) imrotate chrashes when using 'spline' as interpolation method

Submitted by:  Max Görner <maxg>
Submitted on:  Fri 10 Apr 2015 01:41:44 PM UTC  
Category:  Octave Forge Package Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Incorrect Result
Status:  Confirmed Assigned to:  None
Originator Name:  Open/Closed:  Open
Release:  other Operating System:  Any

Add a New Comment(Rich Markup)

You are not logged in

Please log in, so followups can be emailed to you.


( Jump to the original submission)

Tue 09 May 2017 01:39:15 AM UTC, comment #7:

I would like to avoid saying that the spline method does not work on the documentation, because once it does work in core, it automatically works in the image package. I made mention of the core version then:


As a fix, I tried to replace interp2 with interpn whose implementation of spline seems to work fine for out of order grids. However, seems like interpn behaves slightly different and different methods had different issues. They were not wrong, theyr were rotate around a corner instead a center, or rotated in the other direction, or things like that. Not sure if an issues with interpn or the preparation of data to interpn.

Carnë Draug <carandraug>
Project Member
Mon 03 Apr 2017 05:40:38 PM UTC, comment #6:

As long as this (Octave core) issue is not fixed, should we maybe change the documentation in the image package accordingly?

Currently the help string of imrotate.m reads:

And the help string of interp2.m (in Octave core) then claims:

This leads users of imrotate to the wrong conclusion, that "spline" is a valid option for the method parameter of imrotate. But imrotate then only throws an (interp2) error, since a rotated pixel grid is nearly never evenly spaced, as currently needed by interp2 (more precise: needed by _splinen_.m).

So if (core) interp2.m isn't fixed in the near future, I would suggest to add the text "(except for 'spline')" to the help string of (image package) imrotate. This help text would then read like this:

Hartmut <hardy>
Tue 14 Mar 2017 07:14:07 AM UTC, comment #5:

it is a bit weird that interp2(..., 'spline') requires the interpolation points to be on a regular grid, as they're normally scattered (contrary to the original grid itself).

Felipe G. Nievinski <fgnievinski>
Fri 23 Dec 2016 10:46:49 PM UTC, comment #4:

This issue is still present in Octave 4.2.0 with image-2.6.1.

Since the underlying issue is with interp2.m, this bug report should be re-labeled to be an Octave CORE issue, not only an image package issue.

Hartmut <hardy>
Fri 10 Apr 2015 03:04:14 PM UTC, comment #3:

interp2 with "spline" can't handle arbitrary grids yet (There is a "FIXME: Allow arbitrary grids..." in _splinen_.m)

Andreas Weber <andy1978>
Project Member
Fri 10 Apr 2015 02:34:09 PM UTC, comment #2:

I'm sorry, I just stumbled across this error.
Currently I do not have the time to analyse the source code and to create a patch then.

Max Görner <maxg>
Fri 10 Apr 2015 02:18:28 PM UTC, comment #1:

Confirmed in image package version 2.4.0

Could you please submit a changeset/patch?

Carnë Draug <carandraug>
Project Member
Fri 10 Apr 2015 01:41:44 PM UTC, original submission:

It is quite simple:

Max Görner <maxg>


(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 jwe (Updated the item)
  • -email is unavailable- added by fgnievinski (Posted a comment)
  • -email is unavailable- added by hardy (Posted a comment)
  • -email is unavailable- added by mtmiller (Updated the item)
  • -email is unavailable- added by andy1978 (Posted a comment)
  • -email is unavailable- added by maxg (Submitted the item)

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.




    Follow 6 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2017-08-13 jwe Summaryimage package: imrotate chrashes when using 'spline' as interpolation method => [octave forge] (image) imrotate chrashes when using 'spline' as interpolation method
    2015-05-05 mtmiller Item GroupSegfault, Bus Error, etc. => Incorrect Result
        StatusNone => Confirmed
        Operating SystemGNU/Linux => Any
    2015-04-10 carandraug Release3.8.2 => other
        Summaryimrotate chrashes when using \'spline\' as interpolation method => image package: imrotate chrashes when using 'spline' as interpolation method

    Back to the top

    Powered by Savane 3.4