sdp.py: track total (complex) nodes

Signed-off-by: Jacob Emmert-Aronson <jre2718@berkeley.edu>