Skip to content

Commit

Permalink
Merge pull request #461 from e0404/rc/v2.10.1
Browse files Browse the repository at this point in the history
1st Patch Release for Blaise - v2.10.1
  • Loading branch information
wahln authored Nov 20, 2020
2 parents e3126c5 + 1d2bc93 commit d930c3e
Show file tree
Hide file tree
Showing 183 changed files with 2,407 additions and 1,481 deletions.
18 changes: 18 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE/feature_pull_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
### Bug description
Describe the new feature you want to contribute and reference respective issues if this specific enhancement was asked for.

### Approach
Describe how you implemented the feature:
- How does my feature change matRad code?
- Are there any new parameters associated with the feature that need to be documented? (maybe think about providing defaults in MatRad_Config)
- Are there external dependencies (toolboxes, mex files, etc.)?

### Open Questions and/or Concerns
Use a github checklists to adress any concerns like. e.g.
- [ ] I wasn't sure about this or that variable and if I did the correct thing with it
- [ ] I am not sure if this is compatible with the latest Matlab version
- [ ] etc.
This self-defined checklist then has to be checked before merge by reviewers and yourself.

### References
Any helpful external information (e.g. links to stackoverflow question, blogposts, external software websites, etc.)
17 changes: 17 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE/release_checklist_pull_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
### Release Version
Version of new Release and Type (new major release, minor release, patch release)

### Release Checklist

- [ ] Version number changed in matRad_getVersion
- [ ] Adapted Changelog.txt
- [ ] All required mex files compiled
- [ ] Third Party libraries / scripts up to date
- [ ] Standalone(s) generated and tested
- [ ] Wiki adapted
- [ ] Optional changes to README.md
- [ ] Check license information

### References
Any references regarding new functionality etc.

107 changes: 72 additions & 35 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,65 +1,102 @@
language: cpp
group: travis_latest

matrix:
jobs:
include:
# works on Precise and Trusty
- os: linux
- name: "Ubuntu Octave"
os: linux
language: cpp
dist: focal # 20.04 -> Octave 5.2
services:
- xvfb
addons:
apt:
sources:
- ubuntu-toolchain-r-test
update: true
packages:
- g++-7
env:
- MATRIX_EVAL="CC=gcc-7 && CXX=g++-7"
- os: osx
- os: windows
- gdb
- gfortran
- fonts-freefont-otf
- gnuplot-x11
- libgdcm-dev
- octave
- liboctave-dev
- name: "Ubuntu Matlab"
os: linux
language: matlab
dist: focal
- name: "OSX Octave"
os: osx
language: cpp
addons:
homebrew:
update: true
packages:
- llvm
- libomp
- gdcm
- octave
cache:
directories:
- $HOME/Library/Caches/Homebrew
- name: "Windows Octave"
os: windows
language: cpp
cache:
directories:
- $HOME/AppData/Local/Temp/chocolatey
- /C/ProgramData/chocolatey/
allow_failures:
- os: windows
- os: osx

before_install:
# Linux setup
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then echo "Testing matRad on linux..." ; fi
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then eval "${MATRIX_EVAL}" ; fi
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo chmod +x before_install_linux.sh ; fi
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo ./before_install_linux.sh; fi
- if [[ "$TRAVIS_JOB_NAME" == "Ubuntu Octave" ]]; then echo "Testing matRad on linux with Octave..." ; fi
- if [[ "$TRAVIS_JOB_NAME" == "Ubuntu Octave" ]]; then sudo chmod +x .travis/before_install_linux.sh ; fi
- if [[ "$TRAVIS_JOB_NAME" == "Ubuntu Octave" ]]; then sudo .travis/before_install_linux.sh; fi

# Linux Matlab Setup
- if [[ "$TRAVIS_JOB_NAME" == "Ubuntu Matlab" ]]; then echo "Testing matRad on linux with Matlab..." ; fi
- if [[ "$TRAVIS_JOB_NAME" == "Ubuntu Matlab" ]]; then sudo chmod +x .travis/runtests.sh ; fi
- if [[ "$TRAVIS_JOB_NAME" == "Ubuntu Matlab" ]]; then sudo chmod +x MCsquare/bin/MCsquare_linux ; fi

# OSX setup
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then echo "Testing matRad on Mac OSX..." ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install octave > /dev/null ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install llvm > /dev/null ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install libomp > /dev/null ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then sudo chmod +x before_install_osx.sh ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then sudo ./before_install_osx.sh; fi
- if [[ "$TRAVIS_JOB_NAME" == "OSX Octave" ]]; then echo "Testing matRad on Mac OSX..." ; fi
- if [[ "$TRAVIS_JOB_NAME" == "OSX Octave" ]]; then sudo chmod +x .travis/before_install_osx.sh ; fi
- if [[ "$TRAVIS_JOB_NAME" == "OSX Octave" ]]; then sudo .travis/before_install_osx.sh; fi

# Windows Setup
- if [[ "$TRAVIS_OS_NAME" == "windows" ]]; then echo "Testing matRad on Windows..." ; fi
- if [[ "$TRAVIS_OS_NAME" == "windows" ]]; then choco install octave.portable ; fi
- if [[ "$TRAVIS_OS_NAME" == "windows" ]]; then choco install cmake --installargs 'ADD_CMAKE_TO_PATH=System' ; fi
- if [[ "$TRAVIS_OS_NAME" == "windows" ]]; then bash ./before_install_win_gitbash.sh ; fi
- if [[ "$TRAVIS_JOB_NAME" == "Windows Octave" ]]; then echo "Testing matRad on Windows..." ; fi
- if [[ "$TRAVIS_JOB_NAME" == "Windows Octave" ]]; then choco install octave.portable ; fi
- if [[ "$TRAVIS_JOB_NAME" == "Windows Octave" ]]; then bash .travis/before_install_win_gitbash.sh ; fi


before_script:
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then ulimit -c unlimited -S ; fi
- if [[ "$TRAVIS_JOB_NAME" == "Ubuntu Octave" ]]; then ulimit -c unlimited -S ; fi


after_failure:
## Linux stack trace
# find core file
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then COREFILE=$(find . -maxdepth 1 -name "core*" | head -n 1) ; fi
- if [[ "$TRAVIS_JOB_NAME" == "Ubuntu Octave" ]]; then COREFILE=$(find . -maxdepth 1 -name "core*" | head -n 1) ; fi
# print stack trace
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then gdb -c "$COREFILE" -ex "thread apply all bt" -ex "set pagination 0" -batch /usr/bin/octave-cli ; fi
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then tail runtests.log ; fi
- if [[ "$TRAVIS_JOB_NAME" == "Ubuntu Octave" ]]; then gdb -c "$COREFILE" -ex "thread apply all bt" -ex "set pagination 0" -batch /usr/bin/octave-cli ; fi
- if [[ "$TRAVIS_JOB_NAME" == "Ubuntu Octave" ]]; then tail runtests.log ; fi

script:
# Linux script
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then travis_wait 45 ./runtests.sh octave-cli ; fi
# Linux Octave script
- if [[ "$TRAVIS_JOB_NAME" == "Ubuntu Octave" ]]; then travis_wait 45 .travis/runtests.sh octave-cli ; fi
# Linux Matlab script
- if [[ "$TRAVIS_JOB_NAME" == "Ubuntu Matlab" ]]; then travis_wait 45 .travis/runtests.sh matlab; fi
# OSX script
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then travis_wait 45 ./runtests.sh octave-cli ; fi
- if [[ "$TRAVIS_JOB_NAME" == "OSX Octave" ]]; then travis_wait 45 .travis/runtests.sh octave-cli ; fi
# Windows script
- if [[ "$TRAVIS_OS_NAME" == "windows" ]]; then travis_wait 45 ./runtests.sh octave-cli ; fi
- if [[ "$TRAVIS_JOB_NAME" == "Windows Octave" ]]; then travis_wait 45 "cmd.exe //C RefreshEnv.cmd & .travis/runtests.sh octave-cli" ; fi

before_cache:
- if [[ "$TRAVIS_JOB_NAME" == "OSX Octave" ]]; then brew cleanup; fi

notifications:
slack: e0404:u5tBXbO6D1mEwzJuFZV0MmqJ
slack:
if: repo = e0404/matRad
rooms:
- e0404:u5tBXbO6D1mEwzJuFZV0MmqJ

9 changes: 9 additions & 0 deletions .travis/before_install_linux.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#!/usr/bin/env bash

sudo chmod +x .travis/runtests.sh
sudo chmod +x MCsquare/bin/MCsquare_linux

mv optimization/optimizer/ipopt.m optimization/optimizer/ipopt.m.bak

octave --no-gui --eval "pkg install -forge dicom"
octave --no-gui --eval "pkg install -forge nan"
File renamed without changes.
9 changes: 9 additions & 0 deletions .travis/before_install_osx.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#!/usr/bin/env bash

sudo chmod +x .travis/runtests.sh
sudo chmod +x MCsquare/bin/MCsquare_mac

mv optimization/optimizer/ipopt.m optimization/optimizer/ipopt.m.bak

octave --no-gui --eval "pkg install -forge dicom"
octave --no-gui --eval "pkg install -forge nan"
File renamed without changes.
11 changes: 11 additions & 0 deletions .travis/before_install_win_gitbash.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/usr/bin/env bash

sudo chmod +x .travis/runtests.sh
#sudo chmod +x MCsquare/MCsquare_windows.exe

#mv optimization/optimizer/ipopt.m optimization/optimizer/ipopt.m.bak

#octave --no-gui --eval "pkg install -forge dicom"
#octave --no-gui --eval "pkg install -forge nan"

cmd.exe //C RefreshEnv.cmd
File renamed without changes.
2 changes: 1 addition & 1 deletion runtests.sh → .travis/runtests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ fi
if [ -z "$Switches" ] ; then
case "$Runner" in
*matlab* )
Switches="-nodesktop -r"
Switches="-batch"
;;

*octave* )
Expand Down
1 change: 1 addition & 0 deletions AUTHORS.txt
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ List of all matRad developers that contributed code (alphabetical)
* Henning Mescher
* Lucas-Raphael M�ller
* Ahmad Neishabouri
* Martina Palkowitsch
* Giuseppe Pezzano
* Daniel Ramirez
* Carsten Scholz
Expand Down
19 changes: 18 additions & 1 deletion ChangeLog.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,21 @@
Version 2.10.0 "Blaise"
Version 2.10.1 - Patch release for "Blaise"
Release with small updates, clean-ups and bugfixes
- Bugfix in 3D view due to inconsistent angles in pln & stf
- Bugfix for using incorrect dicom UID's and wrong writing order in the dicom export
- Bugfix for weird colormap issue in plotting
- New handling of environment checking with matRad_cfg (old function is still working)
- Code documentation update
- Remove hardcoded penumbra width in photon dose calculation -> can now be stored in machine file (machine.data.penumbraFWHMatIso)
- Update to ompMC to use virtual Gaussian source (uses measured penumbra value) incld precompiled mex files
- remove useless global statements before matRad_cfg
- add blue/white/red difference map to colormaps (in the correct way)
- Updated TravisCI testing (Sped up by using pre-compiled mex interfaces and including testing with Matlab (on Ubuntu), Azure DevOps as fallback
- Github gimmicks added: Stalebot, Issue & PR Templates
- code optimization for jacobian evaluation (x10-100 speedup)
- New option pln.propDoseCalc.useGivenEqDensityCube (default false) to directly use the literal values from ct.cube and omit HU to WEQ conversion from ct.cubeHU
- New option pln.propDoseCalc.ignoreOutsideDensities (default true) to disable/enable inclusion of WEPL outside the patient contour in ray-tracing

Version 2.10.0 - "Blaise"
Second Release of matRad. Note that despite major incompatibilities with "Alan" we still chose major version number "2" to have a consistent versioning in the future.
we want to thank all new contributing authors (see AUTHORS.txt)
The new release contains:
Expand Down
3 changes: 2 additions & 1 deletion IO/matRad_importPatient.m
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,15 @@
%
% call
% [ct,cst] = matRad_importPatient(cubeFile,maskFiles)
% [ct,cst] = matRad_importPatient(cubeFile,maskFiles, hlutFilename)
%
% input
% ctFile: path to CT file. If HLUT is not set, values are interpreted
% as HU and interpolated to ED.
% maskFiles: cell array with filenames to the masks
% if maskFiels contains a folder, all contained and
% recognized data files are treated as masks
% HLUT: optional HLUT, (n,2) array. if set to 'default', we will
% hlutFilname:(optional) HLUT, (n,2) array. if set to 'default', we will
% use a default HLUT
% output
% ct ct struct for use with matlab
Expand Down
52 changes: 26 additions & 26 deletions IO/matRad_readHLUT.m
Original file line number Diff line number Diff line change
@@ -1,30 +1,30 @@
function hlut = matRad_readHLUT(filename)
% matRad function to read HLUT from filename
%
% call
% hlut = matRad_readHLUT(filename)
%
% input
% filename: hlut filename
%
% output
% hlut: lookup table
%
% References
% -
%
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% Copyright 2018 the matRad development team.
%
% This file is part of the matRad project. It is subject to the license
% terms in the LICENSE file found in the top-level directory of this
% distribution and at https://github.com/e0404/matRad/LICENSES.txt. No part
% of the matRad project, including this file, may be copied, modified,
% propagated, or distributed except according to the terms contained in the
% LICENSE file.
%
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% matRad function to read HLUT from filename
%
% call
% hlut = matRad_readHLUT(filename)
%
% input
% filename: hlut filename
%
% output
% hlut: lookup table
%
% References
% -
%
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% Copyright 2018 the matRad development team.
%
% This file is part of the matRad project. It is subject to the license
% terms in the LICENSE file found in the top-level directory of this
% distribution and at https://github.com/e0404/matRad/LICENSES.txt. No part
% of the matRad project, including this file, may be copied, modified,
% propagated, or distributed except according to the terms contained in the
% LICENSE file.
%
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

% Check the extension
[~,~,ext] = fileparts(filename);
Expand Down
2 changes: 1 addition & 1 deletion IO/matRad_readNRRD.m
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
% matRad NRRD reader
%
% call
% matRad_readNRRD(filename)
% [cube, metadata] = matRad_readNRRD(filename)
%
% input
% filename: full path to nrrd file
Expand Down
4 changes: 2 additions & 2 deletions IO/matRad_writeCube.m
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@
% matRad wrapper for Cube export
%
% call
% matRad_writeCube(filepath,cube,meta)
% [saved_metadata] = matRad_writeCube(filepath,cube,meta)
%
% input
% filepath: full output path. needs the right extension
% to choose the appropriate writer
% cube: cube that is to be written
% datatype: MATLAB numeric datatype
% meta: meta-information in struct.
% metadata: meta-information in struct.
% Necessary fieldnames are:
% - resolution: [x y z]
% Optional:
Expand Down
2 changes: 1 addition & 1 deletion IO/matRad_writeMHA.m
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ function matRad_writeMHA(filepath,cube,metadata)
% matRad function to write mha files
%
% call
% matRad_writeMHA(cube,metadata,filename)
% matRad_writeMHA(filepath,cube,metadata)
%
% input
% filepath: full filename (with extension)
Expand Down
2 changes: 1 addition & 1 deletion IO/matRad_writeVTK.m
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ function matRad_writeVTK(filepath,cube,metadata)
% matRad function to write vtk cubes
%
% call
% matRad_writeVTK(cube,metadata,filename)
% matRad_writeVTK(filepath,cube,metadata)
%
% input
% filepath: full filename (with extension)
Expand Down
10 changes: 5 additions & 5 deletions MCsquare/matRad_compileMCsquareSparseReader.m
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
function matRad_compileMCsquareSparseReader(dest,sourceFolder)
% Compiles the sparse mcsquare reader as mex interface for the current
% platform
% Compiles the sparse mcsquare reader as mex interface
% for the current platform
%
% call
% matRad_compileMCsquareSparseReader()
% matRad_compileMCsquareSparseReader(dest)
% matRad_compileMCsquareSparseReader(dest,sourceFolder)
%
% input:
% dest: destination for mex file. Default: location of this
% dest: (optional) destination for mex file. Default: location of this
% file
% sourceFolder: path to folder (optional). Default: location of this
% sourceFolder: (optional) path to folder. Default: location of this
% file
%
% References
Expand All @@ -31,7 +31,7 @@ function matRad_compileMCsquareSparseReader(dest,sourceFolder)
%
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

global matRad_cfg;

matRad_cfg = MatRad_Config.instance();

if nargin < 1
Expand Down
Loading

0 comments on commit d930c3e

Please sign in to comment.