<?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: I found many problems with 3D arcpy.Polylines in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/i-found-many-problems-with-3d-arcpy-polylines/m-p/658305#M51237</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;See &lt;A class="link-titled" href="https://support.esri.com/en/contact-tech-support" title="https://support.esri.com/en/contact-tech-support"&gt;Esri Support Contact Support&lt;/A&gt; .&amp;nbsp; If you are in the United States, an organization/user contacts Esri Support directly.&amp;nbsp; Outside of the US, an organization/user usually contacts the Esri distributor for that country/area.&amp;nbsp; Another option is to use the "Tell us what you think" link at the very bottom of each documentation page.&amp;nbsp; Although you won't necessarily hear back directly from Esri, nor have the ability to track progress on any resolution, the Product Leads do get the feedback.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 04 Sep 2018 14:59:36 GMT</pubDate>
    <dc:creator>JoshuaBixby</dc:creator>
    <dc:date>2018-09-04T14:59:36Z</dc:date>
    <item>
      <title>I found many problems with 3D arcpy.Polylines</title>
      <link>https://community.esri.com/t5/python-questions/i-found-many-problems-with-3d-arcpy-polylines/m-p/658301#M51233</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This is just to inform about things that are most likely bugs.&lt;/P&gt;&lt;P&gt;I already posted a question and answer myself here: &lt;A class="link-titled" href="https://gis.stackexchange.com/questions/294875/arcpy-creating-a-3d-arcpy-polyline" title="https://gis.stackexchange.com/questions/294875/arcpy-creating-a-3d-arcpy-polyline" rel="nofollow noopener noreferrer" target="_blank"&gt;arcgis desktop - arcpy - creating a 3d arcpy.Polyline - Geographic Information Systems Stack Exchange&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;The thing is: I need to create a 3d polyline with arcpy having a series of XYZ coordinates.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If I do:&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;&lt;SPAN class=""&gt;array &lt;/SPAN&gt;&lt;SPAN class=""&gt;=&lt;/SPAN&gt;&lt;SPAN class=""&gt; arcpy&lt;/SPAN&gt;&lt;SPAN class=""&gt;.&lt;/SPAN&gt;&lt;SPAN class=""&gt;Array&lt;/SPAN&gt;&lt;SPAN class=""&gt;([&lt;/SPAN&gt;&lt;SPAN class=""&gt;arcpy&lt;/SPAN&gt;&lt;SPAN class=""&gt;.&lt;/SPAN&gt;&lt;SPAN class=""&gt;Point&lt;/SPAN&gt;&lt;SPAN class=""&gt;(&lt;/SPAN&gt;&lt;SPAN class=""&gt;0&lt;/SPAN&gt;&lt;SPAN class=""&gt;,&lt;/SPAN&gt;&lt;SPAN class=""&gt; &lt;/SPAN&gt;&lt;SPAN class=""&gt;0&lt;/SPAN&gt;&lt;SPAN class=""&gt;,&lt;/SPAN&gt;&lt;SPAN class=""&gt; &lt;/SPAN&gt;&lt;SPAN class=""&gt;0&lt;/SPAN&gt;&lt;SPAN class=""&gt;),&lt;/SPAN&gt;&lt;SPAN class=""&gt;arcpy&lt;/SPAN&gt;&lt;SPAN class=""&gt;.&lt;/SPAN&gt;&lt;SPAN class=""&gt;Point&lt;/SPAN&gt;&lt;SPAN class=""&gt;(&lt;/SPAN&gt;&lt;SPAN class=""&gt;0&lt;/SPAN&gt;&lt;SPAN class=""&gt;,&lt;/SPAN&gt;&lt;SPAN class=""&gt; &lt;/SPAN&gt;&lt;SPAN class=""&gt;100&lt;/SPAN&gt;&lt;SPAN class=""&gt;,&lt;/SPAN&gt;&lt;SPAN class=""&gt; &lt;/SPAN&gt;&lt;SPAN class=""&gt;-&lt;/SPAN&gt;&lt;SPAN class=""&gt;1000&lt;/SPAN&gt;&lt;SPAN class=""&gt;)])
&lt;/SPAN&gt;&lt;SPAN class=""&gt;polyline &lt;/SPAN&gt;&lt;SPAN class=""&gt;=&lt;/SPAN&gt;&lt;SPAN class=""&gt; arcpy&lt;/SPAN&gt;&lt;SPAN class=""&gt;.&lt;/SPAN&gt;&lt;SPAN class=""&gt;Polyline&lt;/SPAN&gt;&lt;SPAN class=""&gt;(&lt;/SPAN&gt;&lt;SPAN class=""&gt;array&lt;/SPAN&gt;&lt;SPAN class=""&gt;,&lt;/SPAN&gt;&lt;SPAN class=""&gt; has_z&lt;/SPAN&gt;&lt;SPAN class=""&gt;=&lt;/SPAN&gt;&lt;SPAN class=""&gt;True&lt;/SPAN&gt;&lt;SPAN class=""&gt;)&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;I get an error, saying that has_z property is Read-only. From the &lt;A href="https://pro.arcgis.com/en/pro-app/arcpy/classes/polyline.htm" rel="nofollow noopener noreferrer" target="_blank"&gt;arcpy.Polyline&lt;/A&gt; official docs, this is an optional input parameter, and lke so, the user should be able to set it (to True or False).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, if I set has_z parameter via python positional parameters rather than named parameter, it works:&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;&lt;CODE&gt;&lt;SPAN class=""&gt;polyline &lt;/SPAN&gt;&lt;SPAN class=""&gt;=&lt;/SPAN&gt;&lt;SPAN class=""&gt; arcpy&lt;/SPAN&gt;&lt;SPAN class=""&gt;.&lt;/SPAN&gt;&lt;SPAN class=""&gt;Polyline&lt;/SPAN&gt;&lt;SPAN class=""&gt;(&lt;/SPAN&gt;&lt;SPAN class=""&gt;array&lt;/SPAN&gt;&lt;SPAN class=""&gt;,&lt;/SPAN&gt;&lt;SPAN class=""&gt; None, &lt;/SPAN&gt;&lt;SPAN class=""&gt;&lt;/SPAN&gt;&lt;SPAN class=""&gt;True&lt;/SPAN&gt;&lt;SPAN class=""&gt;)
&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/CODE&gt;&lt;CODE&gt;&lt;SPAN class=""&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;CODE&gt;&lt;SPAN class=""&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Another problem with 3d Polylines in general, is that their Shape_Length is always 0 for vertical lines (i.e. with equal first and lastPoint).&lt;BR /&gt;Also, length is probably calculated regardless the Z coordinate, resulting in strange lengths values.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 03:51:31 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/i-found-many-problems-with-3d-arcpy-polylines/m-p/658301#M51233</guid>
      <dc:creator>AlessandroValra</dc:creator>
      <dc:date>2021-12-12T03:51:31Z</dc:date>
    </item>
    <item>
      <title>Re: I found many problems with 3D arcpy.Polylines</title>
      <link>https://community.esri.com/t5/python-questions/i-found-many-problems-with-3d-arcpy-polylines/m-p/658302#M51234</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have always created geometries with the positional arguments and with a spatial reference.&lt;/P&gt;&lt;P&gt;Like&amp;nbsp;&lt;/P&gt;&lt;PRE class="language-python line-numbers"&gt;&lt;CODE&gt;arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;Polyline&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;array&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; sr&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="token boolean"&gt;True&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Not sure that the has_z formulation will work, well it doesn't for you.&lt;/P&gt;&lt;P&gt;As regards the length, yes, vertical lines are zero length in plan view. If you want the 3d length you can calculate it or add it.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Sep 2018 11:35:35 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/i-found-many-problems-with-3d-arcpy-polylines/m-p/658302#M51234</guid>
      <dc:creator>NeilAyres</dc:creator>
      <dc:date>2018-09-04T11:35:35Z</dc:date>
    </item>
    <item>
      <title>Re: I found many problems with 3D arcpy.Polylines</title>
      <link>https://community.esri.com/t5/python-questions/i-found-many-problems-with-3d-arcpy-polylines/m-p/658303#M51235</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;In terms of creating your Polyline, definitely a bug.&amp;nbsp; Esri's geoprocessing tools have always had gremlins when it comes to working with Python named arguments.&amp;nbsp; The gremlins get less as users keep reporting them to Esri, so I encourage you to open a case with Esri Support.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The behavior you are seeing with Z values and length is expected.&amp;nbsp; On the surface (no pun intended), most people assume Z equates to elevation/height/depth.&amp;nbsp; Although Z can store elevation, it was designed to store a value that could be something else as well.&amp;nbsp; From &lt;A class="link-titled" href="http://desktop.arcgis.com/en/arcmap/latest/manage-data/geodatabases/feature-class-basics.htm" title="http://desktop.arcgis.com/en/arcmap/latest/manage-data/geodatabases/feature-class-basics.htm"&gt;Feature class basics—ArcGIS Help | ArcGIS Desktop&lt;/A&gt; :&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;H3 style="margin: 1.26316em 0px 0.63158em; font-family: 'Avenir LT W01 35 Light', Arial, Helvetica, sans-serif; font-style: normal; font-weight: 500; letter-spacing: 0.02em; font-size: 1.5rem; line-height: 1.6em; -webkit-font-smoothing: antialiased; color: #4d4d4d; font-variant-ligatures: normal; font-variant-caps: normal; orphans: 2; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial;"&gt;Vertical measurements using z-values&lt;/H3&gt;&lt;P style="font-size: 0.875rem; line-height: 1.71429em; margin-top: 0em; margin-bottom: 1.71429em; -webkit-font-smoothing: antialiased; color: #4d4d4d; font-family: 'Lucida Grande', 'Segoe UI', Arial, sans-serif; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial;"&gt;Feature coordinates can include x,y and x,y,z vertices. Z-values are most commonly used to represent elevations, but they can represent other measurements such as annual rainfall or air quality.&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;The X,Y values are required to be coordinates, but the software doesn't know whether the Z value is storing elevation, annual rainfall, or air quality information.&amp;nbsp; The tools in &lt;A class="link-titled" href="http://desktop.arcgis.com/en/arcmap/latest/extensions/3d-analyst/what-is-the-3d-analyst-extension-.htm" title="http://desktop.arcgis.com/en/arcmap/latest/extensions/3d-analyst/what-is-the-3d-analyst-extension-.htm"&gt;What is the ArcGIS 3D Analyst extension?—Help | ArcGIS Desktop&lt;/A&gt; are designed to work with Z values under the assumption those values represent elevation in some form.&amp;nbsp; For feature classes, run &lt;A class="link-titled" href="http://desktop.arcgis.com/en/arcmap/latest/tools/3d-analyst-toolbox/add-z-information.htm" title="http://desktop.arcgis.com/en/arcmap/latest/tools/3d-analyst-toolbox/add-z-information.htm"&gt;Add Z Information—Help | ArcGIS Desktop&lt;/A&gt;&amp;nbsp; to add a "LENGTH_3D" field.&amp;nbsp; For ArcPy &lt;A class="link-titled" href="http://desktop.arcgis.com/en/arcmap/latest/analyze/arcpy-classes/polyline.htm" title="http://desktop.arcgis.com/en/arcmap/latest/analyze/arcpy-classes/polyline.htm"&gt;Polyline—Help | ArcGIS Desktop&lt;/A&gt;, use &lt;SPAN style="font-family: courier new, courier, monospace;"&gt;Polyline.length3D&lt;/SPAN&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The idea that Z values can represent something other than elevation and that spatial operations ignore Z and M values by default isn't just an Esri thing.&amp;nbsp; The OpenGIS Simple Feature Access standard reflects the same view:&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;The z coordinate of a point is typically, but not necessarily, represents altitude or elevation.&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;and&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;... it is possible to store and obtain z (and m) coordinate values but they are ignored in all other operations which are based on map geometries.&amp;nbsp; Implementations are free to include true 3D geometric operations, but should be consistent with ISO 19107.&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;Any spatial product that is OGC Simple Feature Access compliant will behave the same way.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Sep 2018 14:39:51 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/i-found-many-problems-with-3d-arcpy-polylines/m-p/658303#M51235</guid>
      <dc:creator>JoshuaBixby</dc:creator>
      <dc:date>2018-09-04T14:39:51Z</dc:date>
    </item>
    <item>
      <title>Re: I found many problems with 3D arcpy.Polylines</title>
      <link>https://community.esri.com/t5/python-questions/i-found-many-problems-with-3d-arcpy-polylines/m-p/658304#M51236</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;That makes perfect sense, thank you for clarifying this!&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;The gremlins get less as users keep reporting them to Esri, so I encourage you to open a case with Esri Support.&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;I'd really like to, but how/where am I suppose to report a bug?&lt;/P&gt;&lt;P&gt;I was struggling in the past to find such a place, but never could find one...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Sep 2018 14:52:55 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/i-found-many-problems-with-3d-arcpy-polylines/m-p/658304#M51236</guid>
      <dc:creator>AlessandroValra</dc:creator>
      <dc:date>2018-09-04T14:52:55Z</dc:date>
    </item>
    <item>
      <title>Re: I found many problems with 3D arcpy.Polylines</title>
      <link>https://community.esri.com/t5/python-questions/i-found-many-problems-with-3d-arcpy-polylines/m-p/658305#M51237</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;See &lt;A class="link-titled" href="https://support.esri.com/en/contact-tech-support" title="https://support.esri.com/en/contact-tech-support"&gt;Esri Support Contact Support&lt;/A&gt; .&amp;nbsp; If you are in the United States, an organization/user contacts Esri Support directly.&amp;nbsp; Outside of the US, an organization/user usually contacts the Esri distributor for that country/area.&amp;nbsp; Another option is to use the "Tell us what you think" link at the very bottom of each documentation page.&amp;nbsp; Although you won't necessarily hear back directly from Esri, nor have the ability to track progress on any resolution, the Product Leads do get the feedback.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Sep 2018 14:59:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/i-found-many-problems-with-3d-arcpy-polylines/m-p/658305#M51237</guid>
      <dc:creator>JoshuaBixby</dc:creator>
      <dc:date>2018-09-04T14:59:36Z</dc:date>
    </item>
    <item>
      <title>Re: I found many problems with 3D arcpy.Polylines</title>
      <link>https://community.esri.com/t5/python-questions/i-found-many-problems-with-3d-arcpy-polylines/m-p/658306#M51238</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Whether bug or mere oversight on my end, this was extremely helpful.&amp;nbsp;Among all the examples of creating features from points,&amp;nbsp;there are no good examples for 3D, not to mention one that shows this syntax. Saved the day!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 15 Oct 2019 22:04:28 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/i-found-many-problems-with-3d-arcpy-polylines/m-p/658306#M51238</guid>
      <dc:creator>Arne_Gelfert</dc:creator>
      <dc:date>2019-10-15T22:04:28Z</dc:date>
    </item>
  </channel>
</rss>

