You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Yes, WordSegmenter uses a bad algorithm that works ok in most cases but fails miserably in some cases. It should have been using a dynamic programming approach but sadly it is not. Unfortunately I do not have much spare time to fix this, I would advise using a different algorithm for this.
One idea that may alleviate this issue is to split input from spaces before processing with this. Also please provide an example that may cause this bad recursion.
The dfs recursive method in the WordSegmenter class causes high CPU usage in some scenarios.
See below screenshot of JVM profiler and CPU profiler.
The text was updated successfully, but these errors were encountered: