Skip to content
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

Ability to stop TSNE, possibly other time-heavy computations #740

Closed
Nightenom opened this issue May 22, 2023 · 1 comment
Closed

Ability to stop TSNE, possibly other time-heavy computations #740

Nightenom opened this issue May 22, 2023 · 1 comment

Comments

@Nightenom
Copy link

Nightenom commented May 22, 2023

Is your feature request related to a problem? Please describe.
Hi (currently doing some uni semestral work), running t-SNE with high amount of iterations (eg. 5k) may take a very long time, especially with medium to big data (mine is 10k 10-dims points) on not high-end PCs. My app provides way to stop such computation, which must be unfortunately handled by Thread#stop(), because the current code provides no progress listener nor checks for Thread#isInterrupted().

Describe the solution you'd like
Ideally provide listener with iterations granularity - sth like each X iterations call supplied Consumer<Integer>. This approach provides fine control to executor, which may also check for thread interruptions.
Might also use Predicate<Integer> and throw InterruptedException

Describe alternatives you've considered
Or at least check for Thread#isInterrupted() periodically.

Additional context
None, except having a nice day :)
Actually, there is also no way to control stream parallelism

@haifengl
Copy link
Owner

The update() method takes iterations parameter. Instead of stopping the computation, you may set a small value for iterations. If the results are not good enough, you can call update() again until the visualization looks good.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants