Mass edits toward python friendly code