Automated characterization of SiP MZI-based switches