A base image based on Void Linux that can be used to build DICOMautomaton.
1.4K
DICOMautomaton is a multipurpose tool for analyzing medical physics data
with a focus on automation. It has first-class support for:
\mathbb{R}^1$).There are four ways of operating DICOMautomaton:
DICOMautomaton provides a diverse array of functionality, including
implementations of the following well-known algorithms and analytical
techniques:
Notably absent but (eventually) planned features:
Interchange is important. DICOMautomaton supports the following standard file
formats:
Customized file formats are provided for snapshotting internal state.
The basic workflow is:
Files are loaded (from a DB or files).
A list of operations are sequentially performed, mutating the data state.
Files of various kinds can be written or a viewer can be invoked. Both are implemented as operations that can be chained together sequentially.
Some operations are interactive. Others will run on their own (possibly for days or even weeks). See integration_tests/tests/ for specific examples.
Each operation provides a description of the parameters that can be configured. To see the exact, up-to-date documentation, invoke:
$> dicomautomaton_dispatcher -u
and for general information invoke:
$> dicomautomaton_dispatcher -h
Alternatively, see documentation/ for documentation snapshots.
DICOMautomaton should NOT be used for clinical purposes. It is suitable
only for research purposes or in a non-critical supporting role where outputs
can be easily validated.
While efforts have been made to verify integrity and validity of the code, no independent audit or review has been performed. The breadth of functionality would make it difficult to test all operations combinations. We therefore rely on static analysis, code quality metrics, and a limited amount of integration testing for specific workflows.
All materials herein which may be copywrited, where applicable, are. Copyright 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021 Hal Clark and other contributing authors.
See LICENSE.txt for details about the license. Informally,
DICOMautomaton is available under a GPLv3+ license. The Imebra library is
bundled for convenience and was not written by the author; consult the Imebra
license file which is informally a simplified
BSD-like license.
All liability is herefore disclaimed. The person(s) who use this source and/or software do so strictly under their own volition. They assume all associated liability for use and misuse, including but not limited to damages, harm, injury, and death which may result, including but not limited to that arising from unforeseen or unanticipated implementation defects.
Dependencies are listed in PKGBUILD using Arch Linux package naming conventions, and in CMakeLists.txt using Debian package naming conventions.
Notably, DICOMautomaton depends on the author's Ygor, Explicator, and
YgorClustering projects which are hosted at:
Ygor: https://gitlab.com/hdeanclark/Ygor and
https://github.com/hdclark/Ygor.
Explicator: https://gitlab.com/hdeanclark/Explicator and
https://github.com/hdclark/Explicator.
YgorClustering (needed only for compilation):
https://gitlab.com/hdeanclark/YgorClustering and
https://github.com/hdclark/YgorClustering.
Download the latest AppImage artifact from the continuous integration server here or via:
$> curl http://halclark.ca/ci/DICOMautomaton-latest-x86_64.AppImage > dicomautomaton_dispatcher
$> chmod 777 dicomautomaton_dispatcher
$> ./dicomautomaton_dispatcher -h
This artifact corresponds to the latest successful build on
http://halclark.ca/ci/. Please confirm the
checksum.
Installation is not necessary, but the file can be renamed and installed in a
standard location for convenience (e.g., /usr/bin/).
This is not an official release. It may be lacking functionality, and is almost certainly not optimized.
The CI build environment is currently based on Debian stable. Attempting to
run on systems with older glibcs will likely fail.
AppImages require FUSE support, so running in Docker will not work.
However, AppImages can be extracted and run without FUSE via:
$> ./DICOMautomaton-x86_64.AppImage --appimage-extract
$> ./squashfs-root/usr/bin/dicomautomaton_dispatcher -h
The CI AppImage currently expects graphical components to be available on
the host system. It will fail if libGL, freetype, or libstdc++ libraries
are either incompatible or missing.
See https://gitlab.com/hdeanclark/DICOMautomaton or https://github.com/hdclark/DICOMautomaton for sources and build scripts.
Compile from source to get all functionality and ensure compatibility with your system.
This project uses CMake. Use the usual commands to compile on Linux:
$> git clone https://gitlab.com/hdeanclark/DICOMautomaton/ && cd DICOMautomaton/ # or
$> git clone https://github.com/hdclark/DICOMautomaton/ && cd DICOMautomaton/
$> cd /path/to/source/directory
$> mkdir build && cd build/
Then, if building for Debian:
$> cmake ../ -DCMAKE_INSTALL_PREFIX=/usr
$> make && make package
$> sudo apt install -f ./*.deb
Or, if building for Arch Linux:
$> rsync -aC --exclude build ../ ./
$> makepkg --syncdeps --noconfirm # Optionally also [--install].
Otherwise, if installing directly (i.e., by-passing your package manager):
$> cmake ../ -DCMAKE_INSTALL_PREFIX=/usr
$> make && sudo make install
Direct installation on non-Linux systems is not officially supported. However,
Docker images can be built that are portable across non-Linux systems (see
below).
DICOMautomaton can be built as a Docker image. This method automatically
handles installation of all dependencies. The resulting image can be run
interactively or accessed through a web server.
In order to build the Docker image, you will need git, Docker, and a
bash shell. On Windows systems the git shell should be used. To build the
image:
$> git clone https://gitlab.com/hdeanclark/DICOMautomaton/ && cd DICOMautomaton/ # or
$> git clone https://github.com/hdclark/DICOMautomaton/ && cd DICOMautomaton/ # or
$> cd /path/to/source/directory
$> ./docker/build_bases/arch/build.sh
$> ./docker/builder/arch/build.sh
After building, the default web server can be launched using the convenience script:
$> ./docker/scripts/arch/Run_Container.sh
and a container can be run interactively with the convenience script:
$> ./docker/scripts/arch/Run_Container_Interactively.sh
Docker ImagesDocker containers are available in three variants: using Arch Linux, Debian,
or Void Linux base images. Arch Linux and Void Linux provide the latest
upstream packages, whereas Debian provides greater portability since an older
glibc is used. Arch Linux builds use glibc whereas Void Linux builds use
musl.
Build base images contain all dependencies and requirements necessary to compile
DICOMautomaton, but may not themselves contain DICOMautomaton. The latest
successfully-built base images are available from Docker Hub:
Continuous integration is used to build Docker images, AppImages,
cross-compile and perform tests for all commits. Docker build
artifacts may be available here.
Additional build environments and AppImage portability are tested with
GitHub and GitLab CI pipelines; build artifacts are available
here.
Direct links for the latest build artifacts:
Note that all CI artifacts are not optimized and core functionality may be missing.
The well-known LD_PRELOAD trick can be used to provide somewhat portable
DICOMautomaton binaries for Linux systems. Binaries from the
system-installed or locally-built DICOMautomaton will be automatically
gathered by building and then invoking:
$> ./scripts/dump_portable_dcma_bundle.sh /tmp/portable_dcma/
If successful, the portable outputs will be dumped to /tmp/portable_dcma/. A
convenience script that performs the preload trick and forwards all user
arguments is portable_dcma.
Note that this trick works only on Linux systems, and a similar Linux
system must be used to generate the binaries. The interactive Debian Docker
container will likely suffice. Additionally this technique only provides the
dicomautomaton_dispatcher binary. All shared libraries needed to run it are
bundled, including glibc and some other intrinsic libraries in case the host
and target glibc differ. If the patchelf program is available, the binary
can be patched to use the bundled ld-linux.so interpreter and glibc using
the included adjusting_dcma script, otherwise the system interpreter will be
used. If patchelf is not available it is best to remove ld-linux, libm,
and libc from the bundle and rely fully on the target glibc. Mixing and
matching bits of different glibc installations will almost certainly result in
segmentation faults or silent failures so it is not recommended in any
circumstances. Also note that compilation arguments and architecture-specific
tunings will likely ruin portability.
Alternatively, a third wrapper script (emulate_dcma) uses qemu-x86_64 to
emulate a 64 bit x86 system and preload bundled libraries. This script may work
when the native LD_PRELOAD trick fails, but emulation may be slow. The cpu can
be emulated, so it may be possible to support architecture-specific tunings this
way.
Portability, validity of the program, and full functionality are NOT
guaranteed using either script! They should all be considered experimental. The
preload trick is best run in a controlled environment, and targetting the same
controlled environment and architecture. This method of distributing
DICOMautomaton is not officially supported, but can simplify distributing
custom builds in some situations.
A portable AppImage can be generated using an existing Docker image. This
method supports graphical operations, but suffers from the same general glibc
incompatibility issues described above. However, it works well if your system
glibc is newer than (or equivalent to) that provided by Debian stable.
External, runtime support programs (e.g., Zenity, Gnuplot) may be
incompatible or missing altogether. At the moment no canonical AppImages are
provided, though continuous integration artifacts are available (see above).
Refer to docker/scripts/debian_stable/ for instructions showing how to
generate your own AppImage.
A dedicated Linux system can be bootstrapped using an up-to-date Arch Linux
system that will package the system-installed DICOMautomaton in a truly
portable virtual machine that can be emulated using qemu, including a
graphical display. External, runtime support programs can be bundled this way,
so this method provides the most reliable means of archiving a specific version.
See linux/. Note that this method is experimental.
DICOMautomaton can also be built using the Nix package manager. See nix/.
Note that this method is experimental.
DICOMautomaton can be installed on Android inside a Termux environment
(refer to guide in documentation/).
If you use DICOMautomaton in an academic work, we ask that you please cite the
most relevant publication for that work or the most relevant release DOI, if possible.
DICOMautomaton can be cited as a whole using
doi:10.5281/zenodo.4088796.
Individual releases are assigned a DOI too; the latest release DOI can be found via
or by clicking here.
Finally, several publications describe core functionality of DICOMautomaton
and may be more appropriate to cite.
The SFML_Viewer operation hangs on some systems after viewing a plot with
Gnuplot. This stems from a known issue in Ygor.
Building with musl may cause character conversion to fail for some DICOM
files in some circumstances.
Some operations make use of threading and create filesystem mutexes to avoid race conditions. If execution is unexpectedly terminated a mutex may remain and stall/hang future operations. This can be resolved by manually removing the mutex.
If you are limited by an OpenGL version earlier than 3.0, for example in a
VirtualBox virtual machine, the SDL viewer may fail to load. This can be
worked around by switching to Mesa-based software rendering by configuring
the entire system or defining the LIBGL_ALWAYS_SOFTWARE=1 environment
variable.
The DICOMautomaton homepage can be found at http://www.halclark.ca/. Source
code is available at https://gitlab.com/hdeanclark/DICOMautomaton/ and
https://github.com/hdclark/DICOMautomaton/.
Content type
Image
Digest
Size
1 GB
Last updated
about 5 years ago
docker pull hdclark/dcma_build_base_void