Quoting @tonysyu : "The output will still extend outside 256---instead it limits the number of unique values to 256 because of the histogram implementation, right?"
Absolutely right.

Quoting @tonysyu : "This comment doesn't quite seem to match the behavior that we observed, right?"
This comment does not bear on the output/behaviour.  It simply mentions that the block of code below is meant to handle float images and values outside range(256), which is the case (i.e., it is the intention).  In fact, it's not handled properly in the *general case* (more than 256 unique values), as you say and I wrote in the description of this PR ("if there are more than 256 different intensity values (in the input image), the filtering cannot be handled properly").

I'd like to add (at least) a warning about that.  What do you think?