updated to use seed for multiple instances