Raster Function - Calculator Failing

116
4
04-22-2020 08:21 AM
Labels (1)
Highlighted
New Contributor II

I am running into a problem with the calculator raster function (not the raster calculator in sa). When I try to add two rasters (raster1 + raster2) I get an immediate failure without a detailed message just 'failed to apply calculator' in the history with a message in the details that only says execution fails. No useful information.

My image type is .bil with a float32 pixel depth. I do not have an sa license at this time but the calculator raster function is enabled. Do I need sa?

Reply
0 Kudos
4 Replies
Highlighted
Regular Contributor

Calculate does not need SA.

Did you define the variables?

eg

I only get similar error if variables are not defined.

If you do 

Then you will get a failure.

Suggest you check also with some other rasters and visually check overlap etc.

Reply
0 Kudos
Highlighted
New Contributor II

Hmm I did set the variables when I ran the tool. Also tried with a

geotiff created from the original data. I thought I might have used illegal

keywords to set my variable names (I used min and max), so I changed to

minimum and maximum. That time it said that it couldn't find the sa

license. I forgot to mention before I'm using pro 2.5.

Reply
0 Kudos
Highlighted
MVP Regular Contributor

I'm pretty sure it needs a Spatial Analyst licence.

Raster Calculator—Help | Documentation 

Reply
0 Kudos
Highlighted
Esri Contributor

David (and Patrick),

this is what Patrick mentions in the first sentence: He is not asking about RASTER CALCULATOR tool (your link above) but about the CALCULATOR raster function (Calculator function—ArcGIS Pro | Documentation ) - and here the Doc says two things:

So to clarify, I made a test: 
Without Spatial Analyst or Image Analyst Licenses i got:

 


With Spatial Analyst activated the raster function I tested worked.
With Image Analyst activated the raster function I tested worked.


So the short term answer is: It does require one of both Extensions and thus the documentation on the Calculator function page should also state:

But thank you for notifying us, Patrick. We'll have it adjusted

As a workaround for you, Patrick, if you really only want to to an arithmetic PLUS of two rasters: The Arithmetic function will not require Spatial Analyst or Image Analyst.

Guenter

Reply
0 Kudos