-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
help with histogram split #1
Comments
Is this how we're supposed to run the function?
Does this mean that GHT() is suggesting to place a threshold at 3.45? |
It looks like you're running GHT on a list of points. Try running it on a
histogram (or on a sorted list of points provided as input as "x", where
"n" is a vector of 1s).
…On Sun, Jul 26, 2020 at 2:22 PM Kamil Slowikowski ***@***.***> wrote:
Is this how we're supposed to run the function?
In [90]: d = np.sort(d)
In [91]: res = GHT(d)
In [96]: d[int(res[0])]
Out[96]: 3.45438746714696
Does this mean that GHT() is suggesting to place a threshold at 3.45?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#1 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAGZFNQMSGNEPUVX6XDDQBDR5SNBDANCNFSM4PIFH3IA>
.
|
Here you go:
https://drive.google.com/file/d/1IevRDSI3bYGVhcZuDU9IZ81insF3w0XO/view?usp=sharing.
I tuned the knobs a bit to give me 2.6.
…On Sun, Jul 26, 2020 at 2:42 PM Jon Barron ***@***.***> wrote:
It looks like you're running GHT on a list of points. Try running it on a
histogram (or on a sorted list of points provided as input as "x", where
"n" is a vector of 1s).
On Sun, Jul 26, 2020 at 2:22 PM Kamil Slowikowski <
***@***.***> wrote:
> Is this how we're supposed to run the function?
>
> In [90]: d = np.sort(d)
>
> In [91]: res = GHT(d)
>
> In [96]: d[int(res[0])]
> Out[96]: 3.45438746714696
>
> Does this mean that GHT() is suggesting to place a threshold at 3.45?
>
> —
> You are receiving this because you are subscribed to this thread.
> Reply to this email directly, view it on GitHub
> <#1 (comment)>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/AAGZFNQMSGNEPUVX6XDDQBDR5SNBDANCNFSM4PIFH3IA>
> .
>
|
Thanks! For anyone visiting this issue, here is the code. The
Could I ask if there's any intuitive way to describe the parameters |
They're the hyperparameters of a scaled inverse chi-squared distribution,
if you find that intuitive. The paper goes into much more detail on this
but they kinda serve to let you interpolate between MET and Otsu's method,
and also kinda control how much the histogram is pre-filtered with a
Gaussian blur.
…On Sun, Jul 26, 2020 at 4:20 PM Kamil Slowikowski ***@***.***> wrote:
Thanks!
For anyone visiting this issue, here is the code. The d array holds a
bunch of data points from n.txt
<https://github.com/jonbarron/hist_thresh/files/4978528/n.txt>
In [17]: print(GHT(np.ones_like(d), np.sort(d), 100000, .1, 0)[0])
Out[17]: 2.62013605497376
Could I ask if there's any intuitive way to describe the parameters nu
and tau?
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#1 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAGZFNTHE27KREQZRCY6KWDR5S23DANCNFSM4PIFH3IA>
.
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi Jon,
Thanks for the great code and youtube video! I decided to try it out on my own data, and I am a bit confused with the result.
I would expect that GHT() should return 2.6 or so, but I don't understand the output. Could I please ask if you might be able to help me understand how to use this function and how to interpret the output? Is there a way to call GHT() to get the threshold of 2.6?
Here is my data: n.txt
The text was updated successfully, but these errors were encountered: