1. A method comprising: receiving a two-dimensional image to be converted to a three-dimensional image; determining a category of the image; applying feature values for a plurality of pixels in the two-dimensional image to a feature-to-depth mapping function associated with the category to determine a depth value for each of the plurality of pixels; and generating, by a processing device, the three-dimensional image based on the depth values for the plurality of pixels of the two-dimensional image.