Treatment and casting of insulating resins for electrical machines (transformers, insulating enclosures, components etc.)