moved sample pattern outside of load()