code: def from_dict(self, document):
          
          # Get object properties from Json document
          identifier = str(document['_id'])
          active = document['active']
          timestamp = datetime.datetime.strptime(document['timestamp'], '%Y-%m-%dT%H:%M:%S.%f')
          properties = document['properties']
          # The directory is not materilaized in database to allow moving the
          # base directory without having to update the database.
          directory = self.get_directory(identifier)
          # Cretae image handle
          return ImageHandle(identifier, properties, directory, timestamp=timestamp, is_active=active)
docs: Create image object from JSON document retrieved from database.
  
          Parameters
          ----------
          document : JSON
              Json document in database
  
          Returns
          -------
          ImageHandle
              Handle for image object