Update RivFinder2.py

Fix Bugs and Refactoring