5

I don't think you can. If you dig into the arcpy source you'll find that arcpy.Describe essentially returns a wrapper around a non-python binary object (see line 369 in <install dir>\ArcGIS\Pro\Resources\ArcPy\arcpy\geoprocessing\_base.py) which doesn't have a class you can inherit from. However, you could fake a subclass, by creating a stand-alone ...


4

I would approach this by reconstructing the line manually. Use a cursor to extract the start and end points from the line, sort the list of point coordinates by proximity to the start of the line, and reconstruct the new line geometry. # assumes one line in in_line in_line = r'\scratch.gdb\sample_line' in_points = r'\scratch.gdb\sample_points' # get line ...


3

aprxMap.listLayers() will return a list even if there is only one layer that matches the wildcard you passed. You need to index the 0 position in the list before assigning it to install_layer. install_layer = aprxMap.listLayers(installname)[0]


2

No you can't do this. ArcGIS Pro already includes the conda package management system. It's separate to the Anaconda conda that you installed. ArcGIS Pro comes with a base read-only conda environment arcgispro-py3. To use the ArcGIS Pro conda command, use the Python Command Prompt shortcut in your Start Menu -> ArcGIS Pro entry. You can also run c:\...


2

After changing the layer symbology you need to save the project. aprx.save ()


2

Append end points of your lines to snap points and run near tool on appended set of points. Add field type "Double" to their table: Rename original lines in table of content to "original" and use field calculator: g = arcpy.Geometry() geometryList=arcpy.CopyFeatures_management("original",g) def getChainage(lineFID,point): line=geometryList[lineFID] ...


2

You need to pass the Hierarchy field to the function, not the Crime field. crime = Reclass(!Hierarchy!) def Reclass(Hierarchy): if (Hierarchy == 1): return "Murder-Manslaughter" elif (Hierarchy == 2): return "Forcible Rape" elif (Hierarchy == 3): return "Robbery" elif (Hierarchy == 4): return "Aggravated ...


2

You are calling Describe function again using arcpy.env.Describe which does not seem to be correct. Although you already used arcpy.Describe() which is the correct one. you did not use it. Here is a working code, you can adjust your code based on it: import arcpy from arcpy import env env.workspace = r"F:\Ahmad\Test\Landsat_Test" raster = "TestClassClip....


2

Making this change will not propagate down to views. The view could have its own symbology set and the parent layer can be changed independent of it. You will have to make the change at the view level.


2

You can save a .lyrx file and open in your fave text editor to see the JSON. { "type" : "CIMLayerDocument", "version" : "2.3.0", "build" : 15850, "layers" : [ "CIMPATH=map/new_group_layer2.xml" ], "layerDefinitions" : [ { "type" : "CIMRasterLayer", "name" : "Shaded Relief_dem.tif", "uRI" : "CIMPATH=map/shaded_relief....


1

It's the same in Pro 2.4.2. A work around is right-click the folder you want to have around and select "Add to New Projects". It will then show up under all new Projects' "Folder" section. A plus is that you can get to it from both the Catalog Pane AND Catalog View. The "Favorites" tab is only available in Catalog Pane. For that reason alone I usually ...


1

In ArcGIS Pro, try checking the "Only show features visible in the map extent" box, which can be found under Feature Display Options menu. This will make it so that only things that appear in the current map extent are displayed in your legend. https://pro.arcgis.com/en/pro-app/help/layouts/work-with-legend-items.htm


1

The Esri tool formerly known as the Grouping Analysis tool has evolved into two enhanced cluster analysis analysis tools that might apply to your problem: Multivariate clustering will examine clusters solely based on attributes. (I think this is what you're looking for.) Spatially constrained Multivariate Clustering examines for spatially contiguous ...


1

This worked for me: aprx = arcpy.mpArcGISProject("CURRENT") m = aprx.listMaps("Map")[0] itemid = '2ec9f27bea254a428e4eb70e7650672d' m.addDataFromPath("https://mycounty.maps.arcgis.com/home/item.html?id=" + itemid) The layer gets added to the Pro map.


1

You left z-factor = 1. The ArcGIS Pro Help for Hillshade specifically states: If the input raster is in a spherical coordinate system, such as decimal degrees, the resulting hillshade may look peculiar. This is due to the difference in measure between the horizontal ground units and the elevation z units. Since the length of a degree of longitude ...


1

You'll want to use the translation, rotation, and scale tools to transform the data manually. For translation use the "shift" tool, for rotation use "Rotate" and for scaling use "rescale".


1

I have done something similar to open PDF files in Adobe Acrobat Reader in the past so I just looked up this answer to Opening PDF generated by Python AddIn using Report (*.rlf) file automatcally? and tested: import os myfile = r"C:\Temp\Projects\TestProject\TestProject.aprx" os.system("start " + myfile) and it worked.


1

You can use: aprx = arcpy.mp.ArcGISProject(r"C:\path\to\project.aprx") For further things you can do with aprx refer to the documentation.


1

Try the Set LAS Class Codes Using Features tool. Filter the LiDAR points for non-ground or even first return. The tool will intersect your LiDAR points with your 2D power line feature class. Barring that you could also use the Classification tab->Reassign Classification tool to interactively change the class codes. https://pro.arcgis.com/en/pro-app/help/...


Only top voted, non community-wiki answers of a minimum length are eligible