finesse.detectors.general.Detector

Overview

class finesse.detectors.general.Detector(name, node=None, dtype=<class 'numpy.complex128'>, shape=(), unit='arb.', label=None, needs_fields=True, needs_trace=False)[source]

Bases: ABC, ModelElement

Abstract representation of a component that produces a numerical output.

User detector classes should subclass this class. The simulation will then generate a dictionary of output values.

Parameters
namestr

Name of newly created detector.

nodeNode or Port

Node to read output from. If a port is given, it must have one node, so that is is unambiguous which node to use.

dtypetype, optional

The numpy datatype for which this output result will be stored in.

unitstr, optional

A human readable unit for the output. E.g. W, m, m/rtHz.

Properties

Detector.dtype

Detector.dtype_shape

Detector.dtype_size

Size of the output in terms of number of elements.

Detector.label

Detector.needs_fields

Flag indicating whether the detector requires light fields (i.e.

Detector.needs_trace

Flag indicating whether the detector requires beam traces.

Detector.node

The nodes this detector observes.

Detector.output_information

Detector.unit