octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #63560] imresize gives inaccurate result


From: Raghavan
Subject: [Octave-bug-tracker] [bug #63560] imresize gives inaccurate result
Date: Thu, 22 Dec 2022 06:16:29 -0500 (EST)

URL:
  <https://savannah.gnu.org/bugs/?63560>

                 Summary: imresize gives inaccurate result
                 Project: GNU Octave
               Submitter: ragsubra
               Submitted: Thu 22 Dec 2022 11:16:26 AM UTC
                Category: Octave Forge Package
                Severity: 3 - Normal
                Priority: 5 - Normal
              Item Group: Inaccurate Result
                  Status: None
             Assigned to: None
         Originator Name: 
        Originator Email: 
             Open/Closed: Open
                 Release: 7.3.0
         Discussion Lock: Any
        Operating System: Microsoft Windows
           Fixed Release: None
         Planned Release: None


    _______________________________________________________

Follow-up Comments:


-------------------------------------------------------
Date: Thu 22 Dec 2022 11:16:26 AM UTC By: Raghavan <ragsubra>
When an image is resized using imresize, for some images some
artifacts/distortions are introduced.  This issue is observed from version 7.2
onwards (version 6.4 does not have the issue).
To reproduce the problem, download the attached image (image.jpg) and run the
following lines of code:

pkg load image
im = imread("image.jpg");
im1 = imresize(im, [100,100], 'Linear');
figure(1); subplot(2,1,1) ; imshow(im, [])
subplot(2,1,2) ; imshow(im1, [])
imwrite(im1, "image_resized.jpg", 'Quality',95)

Note the grey stripes created in the flat regions of the resized image.
If imresize method is changed to "Cubic", the artifacts do reduce for this
image, but I have seen other images where it gets worse.  I tried smoothing
the image to prevent aliasing, but didn't work.  Also note that this problem
is not seen in older versions of Octave (6.4.0), nor with opencv







    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?63560>

_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]