Added flattening of PDFs

Flattening enabled for PDFs