Headless command line mode?

Feel free to ask any question here
Post Reply
jgrn307
Posts: 4
Joined: Sat Mar 17, 2018 5:43 pm

Headless command line mode?

Post by jgrn307 »

Folks:

I'm trying to run the ICP algorithm in a fully command line mode, but I'm apparently not understanding how to do this. I am running CC command line as follows from the Docker version of CC:

CloudCompare -SILENT \
-O /data/gpfs/assoc/gears/lidarchange/scratch/wscharffenberger/ALS_TLS_UAV_registration/P406_E2/Unregistered/P406_E2_ALS.las \
-O /data/gpfs/assoc/gears/lidarchange/scratch/wscharffenberger/ALS_TLS_UAV_registration/P406_E2/Unregistered/P406_E2_TLS.las \
-ICP

But I'm getting an error:

QXcbConnection: Could not connect to display
Aborted (core dumped)

Thoughts? I'm not sure why it would be trying to connect to the display since I'm trying to run command line (there is no display on the HPC system I'm using).

Where does the output go? Does it modify the unaligned file directly?
daniel
Site Admin
Posts: 7709
Joined: Wed Oct 13, 2010 7:34 am
Location: Grenoble, France
Contact:

Re: Headless command line mode?

Post by daniel »

Hum, I fear it's because the command line of CloudCompare is just a hack of the graphical version, and the executable probably requires some graphic capabilities...
Daniel, CloudCompare admin
FreewindUly73
Posts: 1
Joined: Sun Oct 11, 2020 9:27 pm

Re: Headless command line mode?

Post by FreewindUly73 »

You can use cloudcompare headless by running it in xvfb, which implements the X server protocol, and to the cloudcompare executable, makes it look like there is an active X server.

xvfb can be installed with apt like so:

Code: Select all

sudo apt-get install xvfb
and you can run your command like like so:

Code: Select all

xvfb-run CloudCompare -SILENT \
-O /data/gpfs/assoc/gears/lidarchange/scratch/wscharffenberger/ALS_TLS_UAV_registration/P406_E2/Unregistered/P406_E2_ALS.las \
-O /data/gpfs/assoc/gears/lidarchange/scratch/wscharffenberger/ALS_TLS_UAV_registration/P406_E2/Unregistered/P406_E2_TLS.las \
-ICP
Post Reply