tidy3d.FluxData#
- class FluxData[source]#
Bases:
MonitorDataData associated with a
FluxMonitor: flux data in the frequency-domain.- Parameters:
monitor (FluxMonitor) β Frequency-domain flux monitor associated with the data.
flux (FluxDataArray) β Flux values in the frequency-domain.
Notes
The data is stored as a DataArray object using the xarray package.
We can access the data for each monitor by indexing into the
SimulationDatawith the monitor.name. For the flux monitor data, we can access the raw flux data as a function of frequency with.flux. As most data are multidimensional, itβs often very helpful to print out the data and directly inspect its structure.Example
>>> from tidy3d import FluxDataArray >>> f = [2e14, 3e14] >>> coords = dict(f=f) >>> flux_data = FluxDataArray(np.random.random(2), coords=coords) >>> monitor = FluxMonitor(size=(2,0,6), freqs=[2e14, 3e14], name='flux') >>> data = FluxData(monitor=monitor, flux=flux_data)
See also
Attributes
Methods
normalize(source_spectrum_fn)Return copy of self after normalization is applied using source spectrum function.
Inherited Common Usage
- monitor#
- flux#
- normalize(source_spectrum_fn)[source]#
Return copy of self after normalization is applied using source spectrum function.
- __hash__()#
Hash method.