ITP procedure works for ground and excited states, other bug fixes