Before converting, your DWG geometry must be perfect. The converter (script or tool) can only read lines.