From: Søren H. <so...@ha...> - 2012-09-06 08:45:23
|
On Sep 5, 2012, at 11:51 PM, Jordi Gutiérrez Hermoso wrote: > regionprops does a bunch of things, most of which make sense for > N-dimensional images. I attach a proposed diff to address this. Can > anyone give me some review before I commit it? Your changes seem good. A few comments (though not a complete review): 1) You check if you should use 'bwlabel' or 'bwlabeln'. Shouldn't this check rather be part of 'bwlabeln', i.e. for 2D inputs, 'bwlabeln' can just call 'bwlabel' ? 2) Not all properties are meaningful for ND input. The previous code checked that the input was 2D and gave an error otherwise. You have removed this check, which makes sense given that we now support ND input. But shouldn't there be some input checking for properties that only work for 2D input? 3) I guess the documentation needs to be updated as well? Other then that, I think your patch looks great! Søren |