Skip to content

Commit eb853a8

Browse files
committed
Enhance docstrings for dst_1_to_1 and dst_2_to_1 functions to clarify data handling and initialization
1 parent b4bc742 commit eb853a8

1 file changed

Lines changed: 13 additions & 1 deletion

File tree

cdl/computation/base.py

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,13 @@ def dst_1_to_1(
177177
src: SignalObj | ImageObj, name: str, suffix: str | None = None
178178
) -> SignalObj | ImageObj:
179179
"""Create a result object, as returned by the callback function of the
180-
:func:`cdl.core.gui.processor.base.BaseProcessor.compute_1_to_1` method
180+
:func:`cdl.core.gui.processor.base.BaseProcessor.compute_1_to_1` method.
181+
182+
.. note::
183+
184+
Data of the result object is copied from the source object (`src`).
185+
This initial data is usually replaced by the processing function, but it may
186+
also be used to initialize the result object as part of the processing function.
181187
182188
Args:
183189
src: source signal or image object
@@ -266,6 +272,12 @@ def dst_2_to_1(
266272
"""Create a result object, as returned by the callback function of the
267273
:func:`cdl.core.gui.processor.base.BaseProcessor.compute_2_to_1` method
268274
275+
.. note::
276+
277+
Data of the result object is copied from the first source object (`src1`).
278+
This initial data is usually replaced by the processing function, but it may
279+
also be used to initialize the result object as part of the processing function.
280+
269281
Args:
270282
src1: input signal or image object
271283
src2: input signal or image object

0 commit comments

Comments
 (0)