update parse method, add calculating packet loss method