<?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 Rescaling an image with a factor from 0 to 1 does not work (arcpy.Rescale_management) in Data Management Questions</title>
    <link>https://community.esri.com/t5/data-management-questions/rescaling-an-image-with-a-factor-from-0-to-1-does/m-p/409905#M23455</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hey,&lt;BR /&gt;I am using ArcGIS Pro 2.5.1 and try to scale the CellSize of an image from 1 to a value of ~0.48 using arcpy.Rescale_management.&lt;/P&gt;&lt;P&gt;The Rescale - Data Management Tool in ArcGIS Pro works correctly for this use case&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="495886" class="image-1 j-img-centered jive-image" height="173" src="https://community.esri.com/legacyfs/online/495886_pastedImage_4.png" style="display: block; margin-left: auto; margin-right: auto;" width="334" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When trying to use the rescaling function in Python I get the following exception&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="495887" class="image-2 j-img-centered jive-image" height="257" src="https://community.esri.com/legacyfs/online/495887_pastedImage_6.png" style="display: block; margin-left: auto; margin-right: auto;" width="416" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If I export the function called in ArcGIS Pro as a Python script, the exact same function is called with identical parameters. Is there a bug in ArcGIS/ArcPy?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edit:&lt;/P&gt;&lt;P&gt;It seems that only integer values are accepted or the decimal places are cut off.&lt;BR /&gt;1.488.. -&amp;gt; = scaling by factor 1, no Exception&lt;BR /&gt;0.488.. -&amp;gt; = 0?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 08 Jun 2020 11:19:21 GMT</pubDate>
    <dc:creator>MoritzWollen</dc:creator>
    <dc:date>2020-06-08T11:19:21Z</dc:date>
    <item>
      <title>Rescaling an image with a factor from 0 to 1 does not work (arcpy.Rescale_management)</title>
      <link>https://community.esri.com/t5/data-management-questions/rescaling-an-image-with-a-factor-from-0-to-1-does/m-p/409905#M23455</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hey,&lt;BR /&gt;I am using ArcGIS Pro 2.5.1 and try to scale the CellSize of an image from 1 to a value of ~0.48 using arcpy.Rescale_management.&lt;/P&gt;&lt;P&gt;The Rescale - Data Management Tool in ArcGIS Pro works correctly for this use case&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="495886" class="image-1 j-img-centered jive-image" height="173" src="https://community.esri.com/legacyfs/online/495886_pastedImage_4.png" style="display: block; margin-left: auto; margin-right: auto;" width="334" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When trying to use the rescaling function in Python I get the following exception&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="495887" class="image-2 j-img-centered jive-image" height="257" src="https://community.esri.com/legacyfs/online/495887_pastedImage_6.png" style="display: block; margin-left: auto; margin-right: auto;" width="416" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If I export the function called in ArcGIS Pro as a Python script, the exact same function is called with identical parameters. Is there a bug in ArcGIS/ArcPy?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edit:&lt;/P&gt;&lt;P&gt;It seems that only integer values are accepted or the decimal places are cut off.&lt;BR /&gt;1.488.. -&amp;gt; = scaling by factor 1, no Exception&lt;BR /&gt;0.488.. -&amp;gt; = 0?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 08 Jun 2020 11:19:21 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/rescaling-an-image-with-a-factor-from-0-to-1-does/m-p/409905#M23455</guid>
      <dc:creator>MoritzWollen</dc:creator>
      <dc:date>2020-06-08T11:19:21Z</dc:date>
    </item>
    <item>
      <title>Re: Rescaling an image with a factor from 0 to 1 does not work (arcpy.Rescale_management)</title>
      <link>https://community.esri.com/t5/data-management-questions/rescaling-an-image-with-a-factor-from-0-to-1-does/m-p/409906#M23456</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;From&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="https://pro.arcgis.com/en/pro-app/tool-reference/data-management/rescale.htm" title="https://pro.arcgis.com/en/pro-app/tool-reference/data-management/rescale.htm"&gt;Rescale—Data Management toolbox | Documentation&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;you will notice in the examples that they pass the numeric value as a string rather than a number&lt;/P&gt;&lt;P&gt;ie "&amp;nbsp;&lt;SPAN style="background-color: #ffffff;"&gt;0.488 "&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff;"&gt;in your case.&amp;nbsp; This is indeed strange&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 08 Jun 2020 20:56:05 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/rescaling-an-image-with-a-factor-from-0-to-1-does/m-p/409906#M23456</guid>
      <dc:creator>DanPatterson</dc:creator>
      <dc:date>2020-06-08T20:56:05Z</dc:date>
    </item>
    <item>
      <title>Re: Rescaling an image with a factor from 0 to 1 does not work (arcpy.Rescale_management)</title>
      <link>https://community.esri.com/t5/data-management-questions/rescaling-an-image-with-a-factor-from-0-to-1-does/m-p/409907#M23457</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you, actually works.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Alternative solution:&lt;BR /&gt;I had to make a format adjustment in Windows. After I changed the decimal separator from "." to "," everything works like in the code snippet above, with double values instead of strings.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Jun 2020 10:22:30 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/rescaling-an-image-with-a-factor-from-0-to-1-does/m-p/409907#M23457</guid>
      <dc:creator>MoritzWollen</dc:creator>
      <dc:date>2020-06-09T10:22:30Z</dc:date>
    </item>
  </channel>
</rss>

