Hexagon Geospatial
MENU

Spatial Modeler

Discuss topics with other Hexagon Geospatial Product pioneers and experts to get the most out of our products.
Showing results for 
Search instead for 
Do you mean 
Reply
Regular Contributor
Posts: 219
Registered: ‎11-16-2015
Accepted Solution

OpenCL and NNDIFFUSE - Is it being used?

Hi. Running an nndiffuse process on WV3 data. Is there any way to check whether the GPU is being utilised? My CPU is 100% with eml 32bit taking up all available CPU and GPU is sitting on zero in the performance monitor.

 

I've an i7, 16bit RAM with GeForce GTX 1050 and Intel HD 630. I've prioritised the GeForce in Configure OpenCL in IMAGINE. Both of these and the CPU have OpenCL with cl_khr_fp64 as an extension.

 

Ah, on opening session log to find out how long the process had been running, I see this:

 

smprocess(54788): INFO com.hexgeo.smsdk.libcompute.PotentialComputeOp - Not able to run on an OpenCL compute device. No compute resources are available

 

Any ideas?

 

Cheers,

 

Johnnie

Technical Evangelist
Posts: 757
Registered: ‎10-01-2015

Re: OpenCL and NNDIFFUSE - Is it being used?

Hi Johnnie,

 

Have you checked the Configure OpenCL dialog (File > Configuration > Configure OpenCL) to see if  any devices are  listed? If they aren't (and you are sure your device supports 64-bit floating point calculations) then you probably need to update your drivers. 

 

OpenCL.png

 

Cheers

 

Ian Anderson
Chief Product Owner, Desktop Remote Sensing
Hexagon Geospatial
Regular Contributor
Posts: 219
Registered: ‎11-16-2015

Re: OpenCL and NNDIFFUSE - Is it being used?

Yup, looks about right to me. I'm just updating the drivers anyway but seems like it should be OK.

 

How can I be sure my device does support 64-bit FP calcs?

 

Ta

 

Johnnie

Technical Evangelist
Posts: 757
Registered: ‎10-01-2015

Re: OpenCL and NNDIFFUSE - Is it being used?

[ Edited ]

Hi Johnnie,

 

It needs to have the extension highlighted in the screenshot above (fp64).

 

Try promoting one of the other drivers to the top of the list to see if it gets picked up instead. Although the software is supposed to try everything on the list before falling back to CPU, so I suspect it's the drivers. The last time this sort of thing happened to me was becuase Windows had updated itself and so I needed new OpenCL drivers that were compatible with the Windows update.

 

Cheers

 

 

Ian Anderson
Chief Product Owner, Desktop Remote Sensing
Hexagon Geospatial
Regular Contributor
Posts: 219
Registered: ‎11-16-2015

Re: OpenCL and NNDIFFUSE - Is it being used?

Woosh! Well, updating the drivers worked. 

 

Now, another issue. Trees are going blue. Seen this before?

 

Cheers, Johnnie

Technical Evangelist
Posts: 757
Registered: ‎10-01-2015

Re: OpenCL and NNDIFFUSE - Is it being used?

[ Edited ]

Yep. Did you process just a small area? NNDiffuse is highly dependent on the data distribution you give it and does not (always) work well with smaller subsets. It seems to work best on entire satellite images.

 

Also, is that screenshot of a Preview? it's possible that Preview, because it's only processing the displayed extent (and scale) suffers the same symptom. Try outputting the whole sharpened image to a file and see if it looks  better.   

 

Ian Anderson
Chief Product Owner, Desktop Remote Sensing
Hexagon Geospatial
Regular Contributor
Posts: 219
Registered: ‎11-16-2015

Re: OpenCL and NNDIFFUSE - Is it being used?

Hiya. Nope, that is a whole WV3 tile as supplied - 4105 by 7450 MS and 16420 by 29801 Pan.

 

Histograms of input/output don't look that outrageous. And it's only the trees that are looking really weird. However, the tile next door (same acquisition date) has gone a bit more crazy. That's 7080 by 7605 in MS.

 

Cheers, Johnnie

Highlighted
Technical Evangelist
Posts: 757
Registered: ‎10-01-2015

Re: OpenCL and NNDIFFUSE - Is it being used?

It does appear to be an unfortunate side effect of the NNDiffuse algorithm. The blue wavelengths seem to sometimes be "boosted". So I've seen it happen most often with 8-band WorldView-2 / -3 data. But it doesn't always happen. 

Ian Anderson
Chief Product Owner, Desktop Remote Sensing
Hexagon Geospatial
Regular Contributor
Posts: 219
Registered: ‎11-16-2015

Re: OpenCL and NNDIFFUSE - Is it being used?

Thanks Ian. Guess we'll stick with HPF for this then. Cheers, Johnnie

Technical Evangelist
Posts: 757
Registered: ‎10-01-2015

Re: OpenCL and NNDIFFUSE - Is it being used?

I forgot to mention - the NNDiffuse works perfectly if you have atmospherically corrected the data prior to performing the NNDiffuse. Something about having the correct relative balance between band wavelengths makes NNDiffuse work much more effectively. Leaving the data as raw DN values is what causes the "bluing".

 

So for something like WorldView-2 and -3 data (whcih suffers most from the effect because it has both CB and B wavelengths) you can easily add the Rapid Atmospheric operator to the front end of the model. 

 

Sorry for the confusion.

 

Cheers

Ian Anderson
Chief Product Owner, Desktop Remote Sensing
Hexagon Geospatial
Do you need immediate support?
If you encounter a critical issue and need immediate assistance please submit a Service Request through our Support Portal.