Optimizing the topological properties of semiconductor-ferromagnet-superconductor heterostructures