add attr, compute to petMidpoint.py