TissueImageAnalytics / tiatoolbox

Computational Pathology Toolbox developed by TIA Centre, University of Warwick.
https://warwick.ac.uk/tia
Other
374 stars 77 forks source link

Empty slide visualizer on a remote machine #819

Closed coolmule0 closed 4 months ago

coolmule0 commented 4 months ago

Description

The visualizer tiatoolbox visualize does not show slide images when accessed via a remote machine. The page can be accessed, the various slides selected according to the --slides $slides_dir argument, the right hand pane is usable. However, nothing is ever visualized within the main left hand pane. I can use the point draw tool in the UI to draw red dots.

I can access the site on the host machine running the visualize command and it will show the slides & tiles as expected.

What I Did

on the host machine

tiatoolbox visualize --slides ./slide_dir --overlays ./overlays_dir --port 5001

and on the client machine

ssh host_addr -L 5006:localhost:5006 -L 5001:localhost:5001
measty commented 4 months ago

Hi, the --port flag sets the port that bokeh will use; it is 5006 by default and will be changed to whatever you specify with --port if needed. The tileserver which provides slide tiles to the interface uses port 5000, and this currently cannot be changed using the command line (if it turns out that there is a need, we could make it customizable too). So the reason the slides are not showing is because it is looking at port 5000 for the tiles, and port 5000 is not forwarded.

if on the host machine you are running: tiatoolbox visualize --slides ./slide_dir --overlays ./overlays_dir --port 5001 then the correct ssh command on the client would be: ssh host_addr -L 5001:localhost:5001 -L 5000:localhost:5000