Skip to content

newcleo-dev-team/glow

Repository files navigation

GLOW

newcleo logo

Authors:Davide Manzione, Daniele Tomatis
Contributors:Gianluca Cirillo, Camilla De Santis
Date:01/08/2025

Introduction

GLOW (Geometry Layout Oriented Workflow) is a Python package providing 2D unstructured geometries to the DRAGON5 lattice transport computer code.

DRAGON5 can natively handle the generation of simple geometry layouts that are structured according to repeated patterns of Cartesian or hexagonal cells by the GEO module.

Even though DRAGON5 can track any 2D geometries without concavities, it can natively only handle the generation of simple geometry layouts that are structured according to repeated patterns. This is done with the GEO module where the G2S module converts the geometry layout to a .dat description file used by the SALT tracking module. More complex layout cases made by boolean operations among geometrical shapes are not handled.

GLOW was developed with the purpose of offering a tool that includes all the functionalities needed to assemble complex geometry layouts. It relies on the APIs of the GEOM module of the SALOME platform, an open-source environment offering 2D/3D CAD modelling capabilities. GLOW supports euclidean geometric transformation, such as translation and rotation, and boolean operations.

GLOW can operate cuts to extract parts out of an existing layout, thus focusing on the minimum portion of the geometry required to describe the entire pattern. Calculations on smaller geometries are expected to be computationally cheaper. Special symmetries according to the main lattice types are implemented:

  • Cartesian lattice - half, quarter and eighth symmetries.
  • Hexagonal lattice - third, sixth and twelfth symmetries.

The geometries built with GLOW can be visualized in the 3D viewer of SALOME through the graphical user interface (GUI module).

GLOW can export geometry layouts to .dat files in the format of the TDT solver of APOLLO2.

GLOW is developed by the Codes & Methods Department of newcleo and it is released under the LGPL-2.1 License.

DISCLAIMER

The DRAGON5 lattice code is not distributed with GLOW. Please, refer to http://merlin.polymtl.ca/version5.htm for downloading the latest version and for the installation instructions.

Project Structure

The project is organized according to the following folder structure:

<glow parent folder>
  ├── docs/
  ├── glow/
  ├── resources/
  ├── tests/
  ├── tutorials/
  ├── LICENSE
  └── README.rst
  • docs: contains the files for generating the project documentation with Sphinx;
  • glow: contains all the modules that provide the functionalities implemented by GLOW;
  • resources: contains files that support the configuration and operation of GLOW;
  • tests: contains both unit tests and functional tests, the former to ensure the correctness of individual code units, the latter to ensure the overall functionalities behave as expected;
  • tutorials: contains Python scripts that provide use cases showing how to use the GLOW functionalities for building different geometry layouts.

Dependencies

To run the code, the following dependencies must be satisfied:

  • Python >= 3.11+
  • SALOME >= 9.12
  • typing-extensions >= 4.12.2
  • PyQt5 >= 5.15.11
  • psutil >= 7.0.0

To build the documentation in both html and LaTeX formats, the following dependencies must be satisfied:

  • sphinx >= 8.2.3
  • sphinx-rtd-theme >= 3.0.2
  • myst-parser >= 4.0.1
  • sphinxcontrib-bibtex >= 2.6.3

How to Install

To install the GLOW application, clone the repository at https://github.com/newcleo-dev-team/glow using the following command:

git clone https://github.com/newcleo-dev-team/glow

Now, from the root folder of GLOW the following command can be run to automatically install all the needed dependencies:

pip install .

To upgrade the GLOW package, please type the install command along with the --upgrade or -U flag:

pip install --upgrade .

Since GLOW exploits the GEOM module of SALOME, a correct installation of SALOME is required. Please, refer to the Building and installing section of the SALOME FAQ page for the installation instructions according to the user's specific OS.

Please, note that the GLOW usage is limited to the OSs supported by SALOME itself.

How to Use

GLOW can be used directly by writing down a Python script where the single needed modules can be imported; alternatively, users can import all the modules at once to have them available by setting the following import instruction:

from glow import *

Given that, classes and methods are directly accessible and users can exploit them to:

  • assemble the geometry;
  • assign properties to regions;
  • visualize the result in the SALOME 3D viewer (see image below);
  • perform the geometry analysis and generate the output TDT file.
Cartesian lattice after applying a eighth symmetry

The above image shows an example of a geometry layout obtained by applying a symmetry that extracts a eighth of an entire Cartesian lattice.

To run any script using the GLOW functionalities, users can:

  • provide it as argument when running SALOME;

    salome my_script.py
  • load it directly from within the SALOME application.

In addition, since SALOME comes with an embedded Python console, users can import the GLOW modules and exploit its functionalities directly.

For a detailed description of the functionalities provided by GLOW, please refer to the Getting Started chapter of the documentation. Python scripts are also provided in the tutorials folder. They are intended to show some case studies and how they are managed in GLOW.

Documentation

The Sphinx documentation can be built both in html and LaTeX formats by executing the following command in the folder docs:

make html
make latexpdf

To see the available templates for generating the documentation in PDF format and to choose among them, please look at the docs/conf.py file.

How to Contribute

For anyone wishing to contribute to the development of the GLOW project, report issues or problems with the software, or request support, please refer to this web page.

Acknowledgements

newcleo is thankful to Professor Alain Hébert and the entire DRAGON5 development team at the Polytechnique of Montreal, Canada, for their constant support.

About

Geometry Layout Oriented Workflow (GLOW)

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 3

  •  
  •  
  •  

Languages