added initmodel