shenjianbing / Real-time-Superpixel-Segmentation-by-DBSCAN-Clustering-Algorithm-

Real-time Superpixel Segmentation by DBSCAN Clustering Algorithm
31 stars 23 forks source link

How to modify the hard-core param for 4k resolution image segmentation? #5

Open philleer opened 4 years ago

philleer commented 4 years ago

Hi, @shenjianbing @ahban @pmixer thanks for your great contribution to the open-sourced repo, very nice work.

Say I am using it to get super-pixel segmentation result for large image, e.g. 4k(3840x2160), which parameter shall I to modify for correct processing, I have already encountered some errors

// In function DBscan
int *neighb = new int[5000];
for(int i=0; i<5000; ++i) neighb[i]=0;

when the size of 'neighb` is 5000, I got the following error info

malloc: Incorrect checksum for freed object 0x7fb43011c200: probably modified after being freed

and when I change it to 500000 it works well, but the final segment result still not very good. Solution refered to stackoverflow Malloc Error: incorrect checksum for freed object

So I am wondering which param I can change for clustering or merging stage to get as good result as expected?

Any suggestion would be appreciated! Much thanks!