zero.analysis.base module

Base analysis

class zero.analysis.base.BaseAnalysis(circuit, print_progress=False, stream=None)[source]

Bases: object

Base class for circuit analysis.

Parameters
  • circuit (Circuit) – The circuit to analyse.

  • print_progress (bool, optional) – Whether to print analysis output.

  • stream (io.IOBase, optional) – Stream to print analysis output to.

progress(sequence, total, update=100000)[source]

Print progress of generator with known length.

Parameters
  • sequence (array_like) – Sequence to report iteration progress for.

  • total (int) – The number of items the sequence will contain.

  • update (float or int) – The number of items to yield before next updating display.

Returns

array_like – The input sequence.