Skip to content

Commit

Permalink
Added diagrams for ET and diff workflows
Browse files Browse the repository at this point in the history
Refs #10855
  • Loading branch information
DanNixon committed May 18, 2015
1 parent f2bbec8 commit 10e9539
Show file tree
Hide file tree
Showing 5 changed files with 304 additions and 1 deletion.
Expand Up @@ -9,7 +9,20 @@
Description
-----------

The generic routine used to reduce diffraction runs from indirect inelastic geometry instruments at ISIS.
The generic routine used to reduce diffraction runs from indirect geometry
inelastic instruments at ISIS.

Workflow
--------

The workflow of this algoirhm is shown in the following flowchart.

.. diagram:: ISISIndirectDiffractionReduction-v1_wkflw.dot

This workflow uses routines from the IndirectReductionCommon Python file which
are described in the following flowchart.

.. diagram:: IndirectReductionCommon_wkflw.dot

Usage
-----
Expand Down
Expand Up @@ -12,6 +12,18 @@ Description
Performs a reduction from raw time of flight to energy transfer for an inelastic
indirect geometry instrument at ISIS.

Workflow
--------

The workflow of this algoirhm is shown in the following flowchart.

.. diagram:: ISISIndirectEnergyTransfer-v1_wkflw.dot

This workflow uses routines from the IndirectReductionCommon Python file which
are described in the following flowchart.

.. diagram:: IndirectReductionCommon_wkflw.dot

Usage
-----

Expand Down
@@ -0,0 +1,84 @@
digraph ISISIndirectDiffractionReduction {
label="ISISIndirectDiffractionReduction Flowchart"
$global_style

subgraph decisions {
$decision_style
need_to_unwrap [label="Need To Unwrap Monitor?"]
is_multi_frame [label="Is Multiple Frames?"]
}

subgraph params {
$param_style
InputFiles
SumFiles
Instrument
Mode
SpectraRange
RebinParam
GroupingPolicy
OutputWorkspace
}

subgraph algorithms {
$algorithm_style
ConvertUnits
ConvertUnits_dSpacing [label="ConvertUnits"]
GroupWorkspaces
}

subgraph processes {
$process_style
load_files
get_multi_frame_rebin
identify_bad_detectors
unwrap_monitor
process_monitor_efficiency
scale_monitor
scale_detectors
rebin_reduction
group_spectra
fold_chopped
rename_reduction
}

subgraph values {
$value_style
multi_frame_rebin_string [label="Multiple Frame Rebin String"]
multi_frame_num_bins [label="Maximum Number of Bins"]
masked_detectors [label="Masked Detectors"]
}

InputFiles -> load_files
SpectraRange -> load_files
Instrument -> load_files
Mode -> load_files
SumFiles -> load_files
load_files -> get_multi_frame_rebin
RebinParam -> get_multi_frame_rebin
get_multi_frame_rebin -> multi_frame_rebin_string
get_multi_frame_rebin -> multi_frame_num_bins
load_files -> identify_bad_detectors
identify_bad_detectors -> masked_detectors
load_files -> need_to_unwrap
need_to_unwrap -> unwrap_monitor [label="Yes"]
unwrap_monitor -> ConvertUnits
ConvertUnits -> process_monitor_efficiency
need_to_unwrap -> process_monitor_efficiency [label="No"]
process_monitor_efficiency -> scale_monitor
scale_monitor -> scale_detectors
scale_detectors -> ConvertUnits_dSpacing
ConvertUnits_dSpacing -> rebin_reduction
RebinParam -> rebin_reduction
multi_frame_rebin_string -> rebin_reduction
multi_frame_num_bins -> rebin_reduction
rebin_reduction -> group_spectra
GroupingPolicy -> group_spectra
masked_detectors -> group_spectra
group_spectra -> is_multi_frame
is_multi_frame -> fold_chopped [label="Yes"]
fold_chopped -> rename_reduction
is_multi_frame -> rename_reduction [label="No"]
rename_reduction -> GroupWorkspaces
GroupWorkspaces -> OutputWorkspace
}
@@ -0,0 +1,143 @@
digraph ISISIndirectEnergyTransfer {
label="ISISIndirectEnergyTransfer Flowchart"
$global_style

subgraph decisions {
$decision_style
is_multi_frame [label="Is Data Multiple Frames?"]
is_x_unit_mev [label="Is UnitX in meV?"]
should_fold [label="FoldMultipleFrames?"]
have_scale_factor [label="ScaleFactor is not 1?"]
have_background_range [label="Have BackgroundRange?"]
have_calibration_workspace [label="Have CalibrationWorksapce"]
have_detailed_balance [label="Have DetailedBalance?"]
have_save_formats [label="Have SaveFormats?"]
need_to_unwrap [label="Need to Unwrap Monitor?"]
}

subgraph params {
$param_style
InputFiles
SumFiles
CalibrationWorksapce
Instrument
Analyser
Reflection
SpectraRange
BackgroundRange
RebinString
DetailedBalance
ScaleFactor
GroupingMethod
GroupingWorkspace
MapFile
UnitX
SaveFormats
OutputWorkspace
}

subgraph algorithms {
$algorithm_style
ConvertUnits
ConvertUnits_DeltaE [label="ConvertUnits"]
ConvertUnits_Output [label="ConvertUnits"]
ConvertToDistribution
ConvertFromDistribution
ExponentialCorrection
GroupWorkspaces
CalculateFlatBackground
Divide
Scale
CorrectKiKf
}

subgraph processes {
$process_style
load_files
get_multi_frame_rebin
identify_bad_detectors
unwrap_monitor
scale_monitor
process_monitor_efficiency
scale_monitor
scale_detectors
rebin_reduction
group_spectra
fold_chopped
rename_reduction
save_reduction
}

subgraph values {
$value_style
multi_frame_rebin_string [label="Multiple Frame Rebin String"]
multi_frame_num_bins [label="Maximum Number of Bins"]
masked_detectors [label="Masked Detectors"]
detailed_balance_corr_factor [label="11.606 / (2 * DetailedBalance)"]
}

InputFiles -> load_files
Instrument -> load_files
Analyser -> load_files
Reflection -> load_files
SumFiles -> load_files
SpectraRange -> load_files
load_files -> get_multi_frame_rebin
RebinString -> get_multi_frame_rebin
get_multi_frame_rebin -> multi_frame_rebin_string
get_multi_frame_rebin -> multi_frame_num_bins
load_files -> identify_bad_detectors
identify_bad_detectors -> masked_detectors
load_files -> need_to_unwrap
need_to_unwrap -> unwrap_monitor [label="Yes"]
unwrap_monitor -> ConvertUnits
ConvertUnits -> process_monitor_efficiency
need_to_unwrap -> process_monitor_efficiency [label="No"]
process_monitor_efficiency -> scale_monitor
scale_monitor -> have_background_range
have_background_range -> ConvertToDistribution [label="Yes"]
ConvertToDistribution -> CalculateFlatBackground
BackgroundRange -> CalculateFlatBackground
CalculateFlatBackground -> ConvertFromDistribution
ConvertFromDistribution -> have_calibration_workspace
have_background_range -> have_calibration_workspace [label="No"]
have_calibration_workspace -> Divide [label="Yes"]
CalibrationWorksapce -> Divide
Divide -> scale_detectors
have_calibration_workspace -> scale_detectors [label="No"]
scale_detectors -> ConvertUnits_DeltaE
ConvertUnits_DeltaE -> CorrectKiKf
CorrectKiKf -> rebin_reduction
RebinString -> rebin_reduction
multi_frame_rebin_string -> rebin_reduction
multi_frame_num_bins -> rebin_reduction
rebin_reduction -> have_detailed_balance
have_detailed_balance -> ExponentialCorrection [label="Yes"]
DetailedBalance -> detailed_balance_corr_factor
detailed_balance_corr_factor -> ExponentialCorrection [label="C1"]
ExponentialCorrection -> have_scale_factor
have_detailed_balance -> have_scale_factor [label="No"]
have_scale_factor -> Scale [label="Yes"]
ScaleFactor -> Scale
Scale -> group_spectra
have_scale_factor -> group_spectra [label="No"]
masked_detectors -> group_spectra
GroupingMethod -> group_spectra
MapFile -> group_spectra
GroupingWorkspace -> group_spectra
group_spectra -> is_multi_frame
is_multi_frame -> should_fold [label="Yes"]
should_fold -> fold_chopped [label="Yes"]
should_fold -> is_x_unit_mev [label="No"]
fold_chopped -> is_x_unit_mev
is_multi_frame -> is_x_unit_mev [label="No"]
is_x_unit_mev -> ConvertUnits_Output [label="No"]
UnitX -> ConvertUnits_Output
ConvertUnits_Output -> rename_reduction
is_x_unit_mev -> rename_reduction [label="Yes"]
rename_reduction -> GroupWorkspaces
rename_reduction -> have_save_formats
have_save_formats -> save_reduction [label="Yes"]
SaveFormats -> save_reduction
GroupWorkspaces -> OutputWorkspace
}
51 changes: 51 additions & 0 deletions Code/Mantid/docs/source/diagrams/IndirectReductionCommon_wkflw.dot
@@ -0,0 +1,51 @@
digraph ISISIndirectReductionCommon {
label="ISISIndirectReductionCommon Flowchart"
$global_style

subgraph decisions {
$decision_style
load_files_ShouldChopData [label="Should Chop Data?"]
load_files_IsChopped [label="Data Is Chopped?"]
load_files_SumFiles [label="Sum Files?"]
}

subgraph params {
$param_style
}

subgraph algorithms {
$algorithm_style
load_files_Load [label="Load"]
load_files_LoadParameterFile [label="LoadParameterFile"]
load_files_ChopData [label="ChopData"]
load_files_ExtractSingleSpectrum [label="ExtractSingleSpectrum"]
load_files_CropWorkspace [label="CropWorkspace"]
}

subgraph processes {
$process_style
load_files_SumRegular [label="sum_regular"]
load_files_SumChopped [label="sum_chopped"]
}

load_files_Start [label="load_files"]
load_files_End [label="End"]

subgraph load_files {
load_files_Start -> load_files_Load
load_files_Load -> load_files_LoadParameterFile
load_files_LoadParameterFile -> load_files_ShouldChopData
load_files_ShouldChopData -> load_files_ChopData [label="Yes"]
load_files_ChopData -> load_files_ExtractSingleSpectrum
load_files_ShouldChopData -> load_files_ExtractSingleSpectrum [label="No"]
load_files_ExtractSingleSpectrum -> load_files_CropWorkspace
load_files_CropWorkspace -> load_files_SumFiles
load_files_SumFiles -> load_files_IsChopped [label="Yes"]
load_files_IsChopped -> load_files_SumRegular [label="No"]
load_files_IsChopped -> load_files_SumChopped [label="Yes"]
load_files_SumFiles -> load_files_End [label="No"]
load_files_SumRegular -> load_files_End
load_files_SumChopped -> load_files_End
}

}

0 comments on commit 10e9539

Please sign in to comment.