<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Generalize a Slope Surface in ArcGIS Spatial Analyst Questions</title>
    <link>https://community.esri.com/t5/arcgis-spatial-analyst-questions/generalize-a-slope-surface/m-p/274864#M3914</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Joe,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can also write a complex Con statement as follows:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;mySlope = Raster(“mySlope.tif”)&lt;/P&gt;&lt;P&gt;mySlopeClasses = Con(mySlope &amp;lt;= 25, 1, Con(((mySlope &amp;gt; 25) &amp;amp; (mySlope &amp;lt;=35)), 2, 3))&lt;/P&gt;&lt;P&gt;mySlopeClasses.save(“mySlopeClasses.tif”)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is a blog on the Con tool you might find useful - &lt;A href="https://www.esri.com/arcgis-blog/products/analytics/analytics/performing-analysis-with-the-con-tool/"&gt;Performing analysis with the Con tool&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Noman&lt;/P&gt;&lt;P&gt;Esri, Redlands, CA.&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 08 Apr 2020 21:35:51 GMT</pubDate>
    <dc:creator>NawajishNoman</dc:creator>
    <dc:date>2020-04-08T21:35:51Z</dc:date>
    <item>
      <title>Generalize a Slope Surface</title>
      <link>https://community.esri.com/t5/arcgis-spatial-analyst-questions/generalize-a-slope-surface/m-p/274858#M3908</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;My adventure into creating and visualizing slope surfaces has moved into a third and possibly final chapter.&amp;nbsp; See&amp;nbsp;&lt;A href="https://community.esri.com/thread/250091" target="_blank"&gt;Using arcpy to create slope surfaces&lt;/A&gt;&amp;nbsp; and&amp;nbsp;&lt;A href="https://community.esri.com/thread/249842" target="_blank"&gt;Display A Slope Raster&lt;/A&gt;&amp;nbsp;for chapters 1 and 2.&amp;nbsp; I have a complete slope surface for the Oquirrh Range ( pronounced &lt;STRONG&gt;oh-&lt;/STRONG&gt;ker) which bounds the Salt Lake Valley to the west.&amp;nbsp; As you can imagine it took a bunch of data and a bunch of processing.&amp;nbsp; My&amp;nbsp;goal in this whole exercise is to display where someone can build or can't build according to our slope ordinance which basically says, anything less than 25% is fair game; 25.1% to 35% you need to survey the property and show exactly where the building will take place, and finally anything steeper than 35% is off limits.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The complete slope model is now stored as a mosaic dataset, and the values range from 0% to 2535% .&amp;nbsp; I'd like to eventually end up with a polygon feature class that is&amp;nbsp;depicts&amp;nbsp;the three classifications described above.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1 = 'Go for it';&lt;/P&gt;&lt;P&gt;2 = 'Show us the survey' ;&lt;/P&gt;&lt;P&gt;3 = 'I can help the next person in line...'&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My first question is generalizing the slope model to such a degree a reasonable approach? My second question is how do I make the calculations&amp;nbsp;against the original slope? I'm not well versed in map algebra but what I do understand seems like a series of conditional statements such as:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;if slope value &amp;lt;=25:
    new value = 1
else if slope value between 25 and 35:
    new value = 2
else:
    new value = 3  ‍‍‍‍‍‍&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How is such conditional written in map algebra? Can that interim raster be held in memory and then output to a polygon feature class on disc? (I &lt;EM&gt;think&lt;/EM&gt; I have enough ram...)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Or is there a better way to achieve my goal?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 13:24:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-spatial-analyst-questions/generalize-a-slope-surface/m-p/274858#M3908</guid>
      <dc:creator>JoeBorgione</dc:creator>
      <dc:date>2021-12-11T13:24:27Z</dc:date>
    </item>
    <item>
      <title>Re: Generalize a Slope Surface</title>
      <link>https://community.esri.com/t5/arcgis-spatial-analyst-questions/generalize-a-slope-surface/m-p/274859#M3909</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Joe&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Another option is to rather use &lt;A href="https://pro.arcgis.com/en/pro-app/tool-reference/spatial-analyst/reclassify.htm"&gt;Reclassify&lt;/A&gt;. See the help for some examples,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #595959; background-color: #f8f8f8;"&gt;outReclassify = Reclassify(inRaster, reclassField, remap, &lt;/SPAN&gt;&lt;SPAN class="" style="color: #c41a16;"&gt;"NODATA"&lt;/SPAN&gt;&lt;SPAN style="color: #595959; background-color: #f8f8f8;"&gt;), &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #595959; background-color: #f8f8f8;"&gt;outReclassify is temporary and can be passed into RasterToPolygon. You therefore will not need to persist the output via the .save as in the example.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As far as in memory goes, some questions;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;ArcGIS Desktop or ArcGIS Pro (memory output is different between these 2)?&lt;/LI&gt;&lt;LI&gt;why in memory?&lt;/LI&gt;&lt;LI&gt;will this be done via scripting or from the tool UI?&lt;/LI&gt;&lt;LI&gt;what is the typical size of the output raster (number of columns and rows)?&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-Steve&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 31 Mar 2020 14:10:13 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-spatial-analyst-questions/generalize-a-slope-surface/m-p/274859#M3909</guid>
      <dc:creator>SteveLynch</dc:creator>
      <dc:date>2020-03-31T14:10:13Z</dc:date>
    </item>
    <item>
      <title>Re: Generalize a Slope Surface</title>
      <link>https://community.esri.com/t5/arcgis-spatial-analyst-questions/generalize-a-slope-surface/m-p/274860#M3910</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;As Steve says, Reclassify would be my go-to option. If you do need/want to cast it into memory:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sloperasterpath = r"c:\myraster.tif"&lt;/P&gt;&lt;P&gt;sloperasterobject = arcpy.Raster(rasterpath)&lt;/P&gt;&lt;P&gt;then do a Con(….) using map algebra syntax.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A useful part of the Reclassify tool is that if you change the symbology in the TOC to your desired classes, dragging that layer into the tool keeps those classified ranges.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 31 Mar 2020 14:17:53 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-spatial-analyst-questions/generalize-a-slope-surface/m-p/274860#M3910</guid>
      <dc:creator>DavidPike</dc:creator>
      <dc:date>2020-03-31T14:17:53Z</dc:date>
    </item>
    <item>
      <title>Re: Generalize a Slope Surface</title>
      <link>https://community.esri.com/t5/arcgis-spatial-analyst-questions/generalize-a-slope-surface/m-p/274861#M3911</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks guys. &lt;A href="https://community.esri.com/migrated-users/3428"&gt;Steve Lynch&lt;/A&gt;‌: I thought I'd do it via python script and my thought was to hold whatever the interim raster would be in memory just because I don't need it. As mentioned, the raster I'm trying to simplify is in the form of a mosaic dataset and is 21,589 X 48,940&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'll take a look at reclassify&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is a hack I've tried: I made an int() type of raster out of the mosiac dataset and added a new field to integer-raster's and then made three successive selections base on the value field and calculated the new field accordingly.&amp;nbsp; That worked, I guess.&amp;nbsp; Then I performed a raster to polygon on it.&amp;nbsp;&amp;nbsp;That's more or less what I want....&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 31 Mar 2020 16:20:30 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-spatial-analyst-questions/generalize-a-slope-surface/m-p/274861#M3911</guid>
      <dc:creator>JoeBorgione</dc:creator>
      <dc:date>2020-03-31T16:20:30Z</dc:date>
    </item>
    <item>
      <title>Re: Generalize a Slope Surface</title>
      <link>https://community.esri.com/t5/arcgis-spatial-analyst-questions/generalize-a-slope-surface/m-p/274862#M3912</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Joe, just a general note: my experience is if you can do&amp;nbsp;a process within an Esri tool like Reclassify or raster functions&amp;nbsp; you really want to go that path as their tools are written in C++ allowing for a lot of optimization you can't do from the raster calculator or python scripting side of things, including nifty memory management, tiling and multiprocessing for many tools.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Apr 2020 19:51:03 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-spatial-analyst-questions/generalize-a-slope-surface/m-p/274862#M3912</guid>
      <dc:creator>curtvprice</dc:creator>
      <dc:date>2020-04-08T19:51:03Z</dc:date>
    </item>
    <item>
      <title>Re: Generalize a Slope Surface</title>
      <link>https://community.esri.com/t5/arcgis-spatial-analyst-questions/generalize-a-slope-surface/m-p/274863#M3913</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Curtis, how is this implemented? Would be useful to expand my learning into C++ if this is the case.&lt;/P&gt;&lt;P&gt;Cheers&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Apr 2020 20:05:54 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-spatial-analyst-questions/generalize-a-slope-surface/m-p/274863#M3913</guid>
      <dc:creator>DavidPike</dc:creator>
      <dc:date>2020-04-08T20:05:54Z</dc:date>
    </item>
    <item>
      <title>Re: Generalize a Slope Surface</title>
      <link>https://community.esri.com/t5/arcgis-spatial-analyst-questions/generalize-a-slope-surface/m-p/274864#M3914</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Joe,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can also write a complex Con statement as follows:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;mySlope = Raster(“mySlope.tif”)&lt;/P&gt;&lt;P&gt;mySlopeClasses = Con(mySlope &amp;lt;= 25, 1, Con(((mySlope &amp;gt; 25) &amp;amp; (mySlope &amp;lt;=35)), 2, 3))&lt;/P&gt;&lt;P&gt;mySlopeClasses.save(“mySlopeClasses.tif”)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is a blog on the Con tool you might find useful - &lt;A href="https://www.esri.com/arcgis-blog/products/analytics/analytics/performing-analysis-with-the-con-tool/"&gt;Performing analysis with the Con tool&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Noman&lt;/P&gt;&lt;P&gt;Esri, Redlands, CA.&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Apr 2020 21:35:51 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-spatial-analyst-questions/generalize-a-slope-surface/m-p/274864#M3914</guid>
      <dc:creator>NawajishNoman</dc:creator>
      <dc:date>2020-04-08T21:35:51Z</dc:date>
    </item>
  </channel>
</rss>

