fixes in samples.py