finished shmr.py: needs running and bugchecking