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 PackageSeverity: 3 - Normal
Priority: 5 - NormalItem Group: Incorrect Result
Status: ConfirmedAssigned to: None
Originator Name: Open/Closed: Open
Release: otherOperating 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 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 File(s):

No files currently attached


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -unavailable- added by jwe (Updated the item)
  • -unavailable- added by fgnievinski (Posted a comment)
  • -unavailable- added by hardy (Posted a comment)
  • -unavailable- added by mtmiller (Updated the item)
  • -unavailable- added by andy1978 (Posted a comment)
  • -unavailable- added by maxg (Submitted the item)

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

    Only project members can vote.


    Please enter the title of George Orwell's famous dystopian book (it's a date):



    Follow 6 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sun 13 Aug 2017 01:23:28 PM UTCjweSummaryimage package: imrotate chrashes when using 'spline' as interpolation method=>[octave forge] (image) imrotate chrashes when using 'spline' as interpolation method
    Tue 05 May 2015 03:36:00 AM UTCmtmillerItem GroupSegfault, Bus Error, etc.=>Incorrect Result
      Operating SystemGNU/Linux=>Any
    Fri 10 Apr 2015 02:18:28 PM UTCcarandraugRelease3.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.1-cleanup1