updated debug statements and template_normal value