i have opened image in imagej , output histogram representation of loaded image. imagej, able access list of pixel values corresponding occurrences in image.
however, when tried load image sample prototype written using opencv in order compute histogram list of pixel values frequency, different result; yet, plotting of both histogram output similar shape of distribution.
histogram of opencv calculated by:
cv::calchist( &image, 1, channels, cv::mat(), hist, 1, histsize, ranges );
and accessed by
histo.at<float>(i)
the results can seen in snapshot below:
the upper image opencv example while second image computed using imagej
this because trying extract similar values computed imagej using opencv in c++. thanks.
note:both have same pixel counts
Comments
Post a Comment