A Deterministic Partition Function Approximation for Exponential Random Graph Models