code: def get_canvas_square_dpi(pageinfo, options):
      
      return float(
          max(
              (pageinfo.xres) or VECTOR_PAGE_DPI,
              (pageinfo.yres) or VECTOR_PAGE_DPI,
              VECTOR_PAGE_DPI if pageinfo.has_vector else 0,
              options.oversample or 0,
          )
      )
docs: Get the DPI when we require xres == yres, in Postscript units