how were the transparent backgrounds created in PS?

if you use tools such as magic eraser, or magic wand, or use a layer blend, these do not always guarantee a 100% transparent background