cleanup layer init