added layer loading