Nathaniel R. Stickley

Software Engineer - Astrophysicist - Data Scientist

Euclid Software Development Notes

This page contains my personal notes on Euclid software development. I am putting concise summaries of the Wiki content and links to longer documents here, since the Euclid Redmine website is currently a bit of a rat's nest.

Primary Links:

Particularly useful links within Redmine:

The EuclidRun Tool

The utility, 'EuclidRun' (equivalently, 'E-Run' and 'ERun') sets up environment variables and then runs a specified command. The basic sytax is:

For example, to set up the environment for EuclidImgUtils version 0.5, and then launch Ipython:

Assuming that EuclidImgUtils, version 0.5 is installed, you can then import EuclidImageBinding (the python bindings for EuclidImageUtils). Note: running the following command enables autocompletion when the program is called as 'ERun':

so that ERun [TAB] lists the available projects.

Creating and expanding a new project with Elements

Main reference.

Assuming that we are using Elements 4.0, to create a new project named testproject with a version number of 0.1, we do this:

To create a module, cd into a project directory and use the AddElementsModule sub-command / helper script, like this:

To create a C++ class, cd into a module and then use the AddCppClass sub-command / helper script:

This will create several template files in the src/, test/, and Module_Name/ subdirectories of the main module directory.

To create a C++ program, make sure that you are in the desired module directory and then use the AddCppProgram sub-command:

This creates a template of the program's main function in the src/program/ subdirectory.

To create a Python module, use the AddPythonModule sub-command:

This creates a new python/ subdirectory, a tests/python/ directory, and template files.

To create a Python program, use the AddPythonProgram sub-command:

This creates a template file in python/Module_Name/.

For more information about the required command line parameters for Python programs: go here.

To build and install your project:

Then you can run the Python program like this:

The default parameters will already be filled in, using the contents of the corresponding .conf file at /home/user/Work/Projects/tstproject/0.1/Module_Name/conf/

To run a quality check on the code:

Navigate into the project's directory (/home/user/Work/Projects/testmodule/0.1/) and run 'checkQuality -e' to make sure that the environment is set up right, then do 'checkQuality -L c++' or'checkQuality -L python':

Once the code anlysis is complete, a summary is printed and a hyperlink to the SonarQube output is provided.


Nathaniel R. Stickley