Hi Mari,
Thanks so much for your reply.
I have first attempted to run the script on a single file, but it returns the following error:
IDL> untitled_2
% End of file encountered before end of program.
At: C:\Users\elton\AppData\Local\Temp\untitled_2.pro, Line 36
% 1 Compilation error(s) in module $MAIN$.
% Attempt to call undefined procedure: 'UNTITLED_2'.
% Execution halted at: $MAIN$ 1 C:\Users\elton\AppData\Local\Temp\untitled_2.pro
IDL>
This is the script that I attempted to run:
; Create a headless instance
e = ENVI(/HEADLESS)
; Open a las file
file = FILEPATH('5090_54490.las', ROOT_DIR=e.ROOT_DIR, $
SUBDIRECTORY = ['data','lidar'])
pointcloud = e.OpenPointCloud(file, PROJECT_URI='J:\Lidar\2013Lidar\Native_LAS_Files')
; Get the point cloud feature extraction task from the catalog of ENVI tasks
task = ENVITask('PointCloudFeatureExtraction')
; Define inputs
Task.INPUT_POINT_CLOUD = pointcloud
; Make sure that DEM, building and trees generation is enabled
Task.DEM_GENERATE = 1
Task.BUILDINGS_GENERATE = 1
Task.TREES_GENERATE = 1
; Run the task
Result = task.Validate(VALIDATION_EXCEPTION=msg)
print, 'Executing Point Cloud Feature Extraction Task'
Task.Execute
; Get the output product filenames
productsInfo = Task.OUTPUT_PRODUCTS_INFO
print, 'DEM Filename: ', productsInfo.DEM_URI
print, 'Buildings Filename: ', productsInfo.BUILDINGS_URI
print, 'Trees Filename: ', productsInfo.TREES_URI
; Close any open point cloud objects
pointcloud.Close
Are you able to advise on what the problem is?
Thanks,
Elton
|