Update visitor.py

correction of some errors