Simplified depth value and other minor changes
reindented some python files