added methods and features for visualization and debug