Select to view content in your preferred language

Error 003266 When Creating Building Scene Layer Package on ArcGIS Server 11.2

905
9
12-17-2024 07:25 AM
DominicReed
Occasional Contributor

Hi everyone,

 

I am trying to automate the creation of a Building Scene Layer from a Revit file by building a geoprocessing service on ArcGIS Server (advanced license, Enterprise version 11.2). The process works perfectly in ArcGIS Pro, where I use the arcpy.CreateBuildingSceneLayerContent() tool to generate the .slpk file. I then publish the tool using the ArcGIS API for Python.

 

However, when I publish the tool on ArcGIS Server and try to run it as a GP service, the tool fails during the .slpk preparation step and throws the following error:

 

"003266: Absolute Z values used"

 

Steps I've Tried:

 

1. Converted the Revit file into a geodatabase format and reprojected it.

 


2. Reprojected the dataset to various coordinate systems.

 


3. Ensured all inputs have valid spatial references and elevation values.

 

 

Despite these efforts, the error persists only when running the tool as a GP service on the server.

 

Has anyone encountered this issue before? Any insights into the cause of Error 003266 in this context or suggestions to resolve it would be greatly appreciated.

 

Thank you in advance for your help!

0 Kudos
9 Replies
Andrew--Johnson
Esri Regular Contributor

Hi,

This message should only be returned as a warning not an error message. We'll investigate further and get back to you.

thanks,

Andrew

0 Kudos
DominicReed
Occasional Contributor

Hi Andrew, 

Thanks for your reply.  Please let me know if you find any solution!

0 Kudos
Andrew--Johnson
Esri Regular Contributor

Hi,

Thanks for your patience as I was out of the office for the holidays. After looking into it further I can confirm that this bug was fixed in 11.3. This error message was being reported as an error instead of a warning. Now, the question is why is it even being reported? The Create Building Scene Layer Content tool creates the scene layer based on the Z values. If you add a layer to a scene and set the elevation mode to anything other than Absolute Z this warning alerts you that the output may look different then how you had it setup initially. Now when the layer gets created in this case (without a 3D scene) it looks like for some of the category layers the elevation is not being written which then triggers our tool to return this message. The tool is checking for the presence of "featureElevationExpression": "Shape.Z". I need to check with the BIM team to find out why this is not being written to the layer in all cases and also see if there's a workaround in 11.2 for you. I'll follow up once I have some more information.

thanks,

Andrew

DominicReed
Occasional Contributor

Hi @Andrew--Johnson,  

Thanks for your reply and many many thanks for looking into the matter. To give you a heads up, I tried to publish the tool in the 11.3 as well as 11.4 enterprise, but when running through REST API, the process stucks in the create building scene layer part and waits untill server kills the job. I extended maximum idle time by many hours but the process never completes. However, I tried to run the process using server python on the server machine in 11.3 as well as 11.4. Can you take a look into that also? 

 

Thanks again!

0 Kudos
Andrew--Johnson
Esri Regular Contributor

Hi,

How long does it take to create the slpk using the Create Building Scene Layer Content tool in ArcGIS Pro? I would expect similar run time between Pro and Server.  Also, can you reproduce this hang with any dataset? We haven't seen this hang running the tool in our server environment so hoping to narrow the cause down some more as to a dataset issue, environment issue or something else.

thanks,

Andrew

DominicReed
Occasional Contributor

Hi @Andrew--Johnson , 

The tool takes 4 minutes apprx to run on pro. I am getting this error in the server rest endpoint (11.4, standard license): "

  • esriJobMessageTypeInformative: java.lang.RuntimeException: java.util.concurrent.ExecutionException: java.lang.RuntimeException: com.esri.arcgis.discovery.admin.rediscovery.util.ArcGISServiceException: Could not service request.

 

DominicReed_1-1737882508414.png

Here is what I got in the server log:

DominicReed_2-1737882734464.png

 

However, no error report is generated. 

 

Also this is the code I used (nothing fancy):

        # Create building layer in memory
        building_layer_dir = os.path.dirname(revit_file)

        # Create the output path
        output_slpk = os.path.join(building_layer_dir, slpk_name)
        arcpy.AddMessage(f"Creating Scene Layer Named: {output_slpk}")

        # Create the building layer
        building_layer = "BuildingLayer"
        arcpy.management.MakeBuildingLayer(revit_file, building_layer)
           
        # Create the scene layer package
        result = arcpy.management.CreateBuildingSceneLayerPackage(building_layer, output_slpk)
        arcpy.AddMessage(f"Scene layer package created: {output_slpk}")
 
 
 
Thanks!

 

 

 

0 Kudos
Andrew--Johnson
Esri Regular Contributor

Hi Dominic,

I ran the script on my 11.4 server and it succeeded. You are running it from this location, correct?  C:\Program Files\ArcGIS\Server\framework\runtime\ArcGIS\bin\Python\Scripts\proenv.bat 

You also tested with other datasets, correct? If it's not any of those issues then there's something else going to which I would direct you to one of our Enterprise Support Analysts so i'd recommend creating a case at support.esri.com to get more specialized assistance.

thanks,

Andrew

 

0 Kudos
sakildev1
Emerging Contributor

Hello Everyone,
I am also facing issues after publishing the script into ArcGIS Server 11.2. It is failing to publish slpk file.

 

        building_layer = "BuildingLayer"
        arcpy.management.MakeBuildingLayer(revit_file, building_layer)
        arcpy.AddMessage(f"Temporary Building Layer Created: {building_layer}")
        name = f"{building_name}_prj{timestamp}"
        inGCS = os.path.join(building_layer_dir, f"{building_name}.prj")
        outGCS = 'PROJCS["WGS_1984_Web_Mercator_Auxiliary_Sphere",GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137.0,298.257223563]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Mercator_Auxiliary_Sphere"],PARAMETER["False_Easting",0.0],PARAMETER["False_Northing",0.0],PARAMETER["Central_Meridian",0.0],PARAMETER["Standard_Parallel_1",0.0],PARAMETER["Auxiliary_Sphere_Type",0.0],UNIT["Meter",1.0]],VERTCS["EGM96_Geoid",VDATUM["EGM96_Geoid"],PARAMETER["Vertical_Shift",0.0],PARAMETER["Direction",1.0],UNIT["Meter",1.0]];-20037700 -30241100 10000;-100000 10000;-100000 10000;0.001;0.001;0.001;IsHighPrecision'
        customGeoTransfm = "GEOGTRAN[METHOD['Geocentric_Translation'],PARAMETER['X_Axis_Translation',''],PARAMETER['Y_Axis_Translation',''],PARAMETER['Z_Axis_Translation','']]"
        transformation = arcpy.management.CreateCustomGeoTransformation(name, inGCS, outGCS, customGeoTransfm)
        arcpy.AddMessage(f"custom transformation created as {transformation}")
 
        # Create the scene layer package
        result = arcpy.management.CreateBuildingSceneLayerPackage(building_layer,output_slpk,outGCS,transformation,'DESKTOP',None)
        arcpy.AddMessage(f"Scene layer package created: {output_slpk}")
 
Failed to publish building scene layer Failed to execute. Parameters are not valid. ERROR 003266: Absolute Z values used. Failed to execute (CreateBuildingSceneLayerPackage). Traceback details: Traceback (most recent call last): File

 

Andrew--Johnson
Esri Regular Contributor

Hi,

See my comment above for some background info. Will report back on workarounds.

thanks,

Andrew

0 Kudos