Closed lpatiny closed 4 months ago
The calculations of threshold based on the histogram is too slow if the images are 16 bits.
https://github.com/image-js/image-js-typescript/blob/main/src/operations/threshold.ts#L84
We should at least have an options to specify the number of slots to use for the histogram calculation and for me the default value should be 2**8.
The result by itself should barely change.
This seems wrong to me intuitively. We should discuss it in-person.
@moonayyur You may add this option but by default it can stay the same value as today.
The calculations of threshold based on the histogram is too slow if the images are 16 bits.
https://github.com/image-js/image-js-typescript/blob/main/src/operations/threshold.ts#L84
We should at least have an options to specify the number of slots to use for the histogram calculation and for me the default value should be 2**8.
The result by itself should barely change.