qupath / qupath-extension-djl

A QuPath extension for working with Deep Java Library (https://djl.ai)
Apache License 2.0
5 stars 4 forks source link

Switch to domain named prop and fix tensorflow toString issue #19

Closed alanocallaghan closed 4 months ago

alanocallaghan commented 4 months ago

Related to the PR linked in #18, this uses the domain named property, which is a bit less ambiguous.

Also fixes an error when trying to call toString on a TensorFlow engine, it'd end up going into LibUtils.getLibName() which leads eventually into downloadTensorFlow, which fails given the default offline setting

See https://github.com/deepjavalibrary/djl/blob/1d3613aaab1fcc5cbb3398a60152f6ce49a76342/engines/tensorflow/tensorflow-engine/src/main/java/ai/djl/tensorflow/engine/TfEngine.java#L177C62-L177C72

petebankhead commented 4 months ago

As far as I can see, ai.djl.offline was introduced in DJL 0.27.0 and so I presume this is only targeting QuPath v0.6.0?

I'll update the version accordingly in another PR (and I don't see a reason to stick with Java 17 compatibility, so will also move that to 21).