added sparse writer