Two-dimensional density estimation using smooth invertible transformations