Added initialization methods and optimizations