ExportGeometry v1

../_images/ExportGeometry-v1_dlg.png

ExportGeometry dialog.

Summary

Extract geometry into a variety of file formats

Properties

Name Direction Type Default Description
InputWorkspace Input Workspace Mandatory Workspace containing the instrument to be exported
EulerConvention Input string YZY Euler angles convention used when writing angles. Allowed values: [‘ZXZ’, ‘XYX’, ‘YZY’, ‘ZYZ’, ‘XZX’, ‘YXY’, ‘XYZ’, ‘YZX’, ‘ZXY’, ‘XZY’, ‘ZYX’, ‘YXZ’]
Components Input str list   Comma separated list of instrument components to export
Filename Input string Mandatory Save file. Allowed extensions: [‘.xml’]

Description

This algorithm is intended to write out portions of an instrument’s geometry. The resulting file is mean to be copied by-hand into a geometry file. The main use of this is if the instrument geometry is calibrated in mantid, this algorithm can be used ot help get the information back into the initial instrument definition file.

Usage

LoadEmptyInstrument(Filename="NOMAD_Definition.xml",
                    OutputWorkspace="NOM_geom")
import mantid
filename=mantid.config.getString("defaultsave.directory")+"NOMgeometry.xml"
ExportGeometry(InputWorkspace="NOM_geom",
               Components="bank46,bank47",
               Filename=filename)
import os
if os.path.isfile(filename):
    print "File created: True"

Output:

File created: True

Categories: Algorithms | Utility\Instrument