Tamil
மொழிகள்
English
Bengali
French
Hindi
Italian
Japanese
Korean
Malayalam
Russian
Spanish
Tamil
Turkish
Vietnamese
Shortcuts



CircuitQNN.set_interpret

CircuitQNN.set_interpret(interpret, output_shape=None)[source]

Change 'interpret' and corresponding 'output_shape'. If self.sampling==True, the output _shape does not have to be set and is inferred from the interpret function. Otherwise, the output_shape needs to be given.

Parameters
  • interpret (Optional[Callable[[int], Union[int, Tuple[int, ...]]]]) -- A callable that maps the measured integer to another unsigned integer or tuple of unsigned integers. See constructor for more details.

  • output_shape (Union[int, Tuple[int, ...], None]) -- The output shape of the custom interpretation, only used in the case where an interpret function is provided and sampling==False. See constructor for more details.

Return type

None