pavlin-policar / openTSNE

Extensible, parallel implementations of t-SNE
https://opentsne.rtfd.io
BSD 3-Clause "New" or "Revised" License
1.47k stars 162 forks source link

Pass verbose=1 to pynndescent? #145

Closed dkobak closed 4 years ago

dkobak commented 4 years ago

When run with verbose=1, pynndescent provides some helpful verbose output:

Mon Oct 19 12:44:31 2020 Building RP forest with 55 trees
Mon Oct 19 12:50:16 2020 metric NN descent for 20 iterations
     1  /  20
     2  /  20
     3  /  20
     4  /  20
     5  /  20
    Stopping threshold met -- exiting after 5 iterations
Mon Oct 19 12:54:43 2020 Finished Nearest Neighbor Search

openTSNE currently does not pass the verbose setting into pynndescent, so the output with verbose=1 looks like this:

===> Finding 15 nearest neighbors using NN descent approximate search using cosine distance...
   --> Time elapsed: 980.70 seconds

Would it make sense to pass the verbose flag? The logging format used by pynndescent looks a bit different, but I think it does not matter that much, and verbose output could be useful.

pavlin-policar commented 4 years ago

Maybe we could do this with verbosity levels. E.g. with verbose=True i.e. verbose=1 I would keep the output as is because I don't think I'd want to look at that output every time. But then we could do verbose=2 to show that as well. What do you think?

dkobak commented 4 years ago

Makes sense!