Re: VDP 2 in C++

318 views
Skip to first unread message

Rafal

unread,
Oct 24, 2012, 5:51:24 AM10/24/12
to hdr...@googlegroups.com
On Wednesday, October 24, 2012 12:21:26 AM UTC+1, Maryam Azimi wrote:
Hi,

I was wondering if VDP 2 source code is available in C++ as well. 

 
Unfortunately there is no C++ implementation.

The code could potentially run in GNU Octave, but have not tried. It may require some changes, especially the steerable pyramid decomposition.

Rafal

Harald Sanftmann

unread,
Oct 1, 2022, 6:27:20 AM10/1/22
to HDR VDP
Hi,

Has someone managed to get this to work with Octave?

First I run into the issue that clamp is not defined, so I defined it like this:

function c = clamp(v,l,h)
   c = min(max(v,l),h);
end

Now I run into another issue:

.../hdrvdp-3.0.6/examples$ octave impairment_detection_sdr.m > impairment_detection_sdr-output.txt
warning: function /mnt/h/work/hdrvdp-3.0.6/examples/../matlabPyrTools_1.4_fixed/factorial.m shadows a core library function
warning: called from
    hdrvdp3 at line 309 column 5
    impairment_detection_sdr at line 50 column 15
warning: function /mnt/h/work/hdrvdp-3.0.6/examples/../matlabPyrTools_1.4_fixed/shift.m shadows a core library function
warning: called from
    hdrvdp3 at line 309 column 5
    impairment_detection_sdr at line 50 column 15
warning: dlmread: '/mnt/h/work/hdrvdp-3.0.6/examples/../data/emission_spectra_led-lcd-srgb.csv' found by searching load path
warning: called from
    load_spectral_resp at line 10 column 3
    hdrvdp3 at line 419 column 18
    impairment_detection_sdr at line 50 column 15
parse error near line 5 of file /mnt/h/work/hdrvdp-3.0.6/examples/../utils/hdrvdp_multscale.m

  external methods are only allowed in @-folders

>>>         ms = decompose( ms, I );
                                  ^

error: called from
    hdrvdp3 at line 473 column 31
    impairment_detection_sdr at line 50 column 15
.../hdrvdp-3.0.6/examples$

Since I have no clue of Matlab or Octave I am kind of stuck.

Thanks & Regards,
Harald

Rafal

unread,
Oct 1, 2022, 6:32:57 AM10/1/22
to HDR VDP
Herald,

We have never tested HDR-VDP with Octave. It is quite likely that you will encounter some compatibility issues. It probably can be made to run with Octave, but it may require some work.

You can find "clamp" and other functions in the "utils" folder. 

If you cannot get Matlab (e.g. trial version), you can try using instead:


It comes with Python code, which should be easy to install.  This is a different metric, less suitable for images, but may still do the job.

Best,

Rafal

Harald Sanftmann

unread,
Oct 8, 2022, 7:07:32 AM10/8/22
to HDR VDP
Hi Rafal,

Got it working with Octave. Had to do some changes, like placing  hdrvdp_multscale.m in a @hdrvdp_multscale folder, replacing some incompatible function calls, and recompiling "mkoctfile --mex gaussian_columns.c".

Is FovVideoVDP the successor of HDRVDP? Does it deliver the same or superior results on still images?

Thanks
Harald

Rafal

unread,
Oct 8, 2022, 7:09:32 AM10/8/22
to HDR VDP
Herald,

Great to hear that you got it working in Octave. If you would like to contribute your changes (ideally as a patch), I can integrate those into the next release. 

FovVideoVDP is not a full replacement for HDR-VDP - it is missing many features and may be less accurate on images. 

Best,

Rafal
Reply all
Reply to author
Forward
0 new messages