The HORRORS Of The Dachau Liberation Executions

When Dachau was liberated in April 1945, the American soldiers found many SS guards who had worked there. But many of them would be executed and were shot by a combination of the liberating Americans and also the prisoners. But why did this happen, and specifically how many were executed?