fixes for head detection