Error: Unable to build a whole slide server for (directory of the file)

Hi all. I am trying to open an .ndpi image on QPath (0.2.0-m4) and i get the error message in the title. Does anyone have an idea of what’s going on? I can normally open the original .ndpi file with QPath but after adding/saving annotations and doing some analyses with Positive Pixel Count I am not able to open these files anymore.


How exactly did you try to open it?

Had you created a project yet?

I’ve tried both opening from the taskbar File - > Open or just dragging the file into QuPath window.

My guess is that it’s related to the annotation I have added previously on these files. I could open the original ndpi file but after adding annotations I have this problem.

Under View → Show log there may be more information.

Also, if you create a project first you and drag the image in you have the opportunity to select the library that will read the image. Both OpenSlide and Bio-Formats should usually work for (most) .ndpi - so using this you can try selecting each in turn from the drop-down menu to see if it makes any difference.

QuPath does not add any annotations or perform any manipulation of the ndpi file. What exactly are you opening? If it is part of a project (which it should be if you are doing any analysis as linked above), the file should already be in the project tab list on the left, so are you should not need to re-add it once measurements have been made.

Thank you both!

I have managed to open the file creating a Project first and then dragging the image using Bio-Formats like you suggested. However I can’t see the annotations that I made previously. In the former version of QPath ( v0.1.2), I used to make annotations, save the file and re-open it and annotations were included. They were saved in .qpdata format by default. In the new version (0.2.0-m4) they are saved in .ndpi format so I guess this is the reason they are gone? Not sure how to select the format as I can’t see this option in “Save as”.

Attached is the log file. Thanks a lot for your help!

log.txt (9.0 KB)

QuPath still uses .qpdata files - but it appears that if you save these directly, QuPath allows you to use the same extension as the original image, and if that happens then it doesn’t add the .qpdata extension that it should. This is a bug that should be fixed in the next release:

In the meantime, you can replace the extension of the files containing annotations from .ndpi to .qpdata and it should work.

Or you can work with images in projects, in which case QuPath takes care of the naming for you. It is strongly recommended to work in projects generally, and avoid using lots of separate .qpdata files. Projects are a lot more flexible, and required for some features.

1 Like

In this case I guess I will have to start from the beginning, correct? What does the project do exactly with annotations?

In addition to the above link (first post), the wiki explains it as well:
There would be no need to start over, but you would have to place the files in the correct places with the right names, which varies from version to version. And in some cases annotations from previous versions might be misaligned (OpenSlide mostly, I think).

The link from @Research_Associate relates to v0.1.2; projects are becoming a bit more sophisticated now as new features are added, although the concepts are basically the same. Where precisely the data is stored is different, but it is still in .qpdata files in the end.

The changed alignment of annotations probably won’t be an issue; it affects only certain formats under certain circumstances (.scn or .mrxs files read into QuPath using OpenSlide) and depends on QuPath version, not whether projects are used or not.

The easy answer is ‘yes’ but there might be other options… however I can’t really be more specific as I don’t know what you’re using QuPath for, what you’ve already done or what the end goal is.