Removed unnecessary edge weights