Add comments
Fix a few bugs due to EMR compatibility issues