Superconductor loops with Josephson junctions such as SQUIDs and Bi-SQUID have unique properties that can be used as quantum accurate magnetometers, amplifiers, and many more applications. However, due to quantum interference between junctions and their nonlinear nature, their interaction with magnetic fields is hard to analyze. In this work, we introduce an open-source library titled PySQIF that determines the voltage response of the SQUIDs and Bi-SQUIDs in the presence of the external magnetic flux and can determine the design parameter margins by a statistical approach. This library was used to design and fabricate a Bi-SQUID magnetometer.