Create a new composite transform that is the result of applying `Affine2DBase` *a* then `Affine2DBase` *b*. You will generally not call this constructor directly but write ``a + b`` instead, which will automatically choose the best kind of composite transfor
(self, a, b, **kwargs)
| 2510 | and *b* are 2D affines. |
| 2511 | """ |
| 2512 | def __init__(self, a, b, **kwargs): |
| 2513 | """ |
| 2514 | Create a new composite transform that is the result of |
| 2515 | applying `Affine2DBase` *a* then `Affine2DBase` *b*. |
| 2516 | |
| 2517 | You will generally not call this constructor directly but write ``a + |
| 2518 | b`` instead, which will automatically choose the best kind of composite |
| 2519 | transform instance to create. |
| 2520 | """ |
| 2521 | if not a.is_affine or not b.is_affine: |
| 2522 | raise ValueError("'a' and 'b' must be affine transforms") |
| 2523 | if a.output_dims != b.input_dims: |
| 2524 | raise ValueError("The output dimension of 'a' must be equal to " |
| 2525 | "the input dimensions of 'b'") |
| 2526 | self.input_dims = a.input_dims |
| 2527 | self.output_dims = b.output_dims |
| 2528 | |
| 2529 | super().__init__(**kwargs) |
| 2530 | self._a = a |
| 2531 | self._b = b |
| 2532 | self.set_children(a, b) |
| 2533 | self._mtx = None |
| 2534 | |
| 2535 | @property |
| 2536 | def depth(self): |
nothing calls this directly
no test coverage detected