Codes to generate the numerical examples in the dissertation "Inverse Scattering Problems and Shape Optimization with Respect to Electromagnetic Chirality for Long Tubular Objects". These codes are written in the Python programming language and are based on the Bempp boundary element library (https://bempp.com).