EDM and ECM , Non traditional processes which are used to cut or machine difficult shapes (die,complex shapes,hard metals ...etc). , different procedure used in each process one is thermal and other chemical.
With ECM, tool wear is very less, so it can be used if tool used is expensive/retention of tool shape is required. The problem with ECM is the corrosivity which can destroy any metallic pipes, tanks etc. used during the process. This is not the case with EDM.