classDiagram

class Operator {
  +fwd()
  +adj()
}

class ContextManager {
  - __enter__()
  - __exit__()
}

class Tomo {
  +int ntheta
  +int n
  +int nz
  +fwd(self, obj, **kwargs)
  +adj(self, tomo, **kwargs)
}

class Lamino {
  +int theta
  +int n
  +int tilt
  +fwd(self, obj, **kwargs)
  +adj(self, tomo, **kwargs)
}

class Ptycho {
  +int nscan
  +int probe_shape
  +int detector_shape
  +int nz
  +int n
  +int ntheta
  +Propagation propagation
  +Convolution convolution
  +fwd(self, probe, scan, psi, **kwargs)
  +adj(self, farplane, probe, scan, **kwargs)
  +adj_probe(self, farplane, scan, psi, **kwargs)
}



class Convolution {
  +int nscan
  +int probe_shape
  +int nz
  +int n
  +int ntheta
  +fwd()
  +adj()
}

class Propagation {
  +int detector_shape
  +fwd()
  +adj()
}

ContextManager <|-- Operator

Operator <|-- Tomo
Operator <|-- Lamino
Operator <|-- Ptycho
Operator <|-- Convolution
Operator <|-- Propagation

Ptycho --o Convolution
Ptycho --o Propagation

Operator <|-- Alignment
class Alignment {
+Flow flow
+Rotate rotate
+Pad pad
+Shift shift
+fwd()
+adj()
}

Operator <|-- Rotate
class Rotate {
+fwd()
+adj()
}

Operator <|-- Pad
class Pad {
+fwd()
+adj()
}

Operator <|-- Flow
class Flow {
+fwd()
+adj()
}

Operator <|-- Shift
class Shift {
+fwd()
+adj()
}

Alignment --o Rotate
Alignment --o Pad
Alignment --o Shift
Alignment --o Flow
