code: def page_from_image(input_file):
      
      if input_file.local_filename is None:
          raise Exception("input_file must have 'local_filename' property")
      exif = exif_from_filename(input_file.local_filename)
      now = datetime.now()
      return PcGtsType(
          Metadata=MetadataType(
              Creator="OCR-D/core %s" % VERSION,
              Created=now,
              LastChange=now
          ),
          Page=PageType(
              imageWidth=exif.width,
              imageHeight=exif.height,
              # XXX brittle
              imageFilename=input_file.url if input_file.url is not None else 'file://' + input_file.local_filename
          )
      )
docs: Create `OcrdPage </../../ocrd_models/ocrd_models.ocrd_page.html>`_
      from an `OcrdFile </../../ocrd_models/ocrd_models.ocrd_file.html>`_
      representing an image (i.e. should have ``mimetype`` starting with ``image/``).
  
      Arguments:
          * input_file (OcrdFile):