class_docstr: Exporter for image or video datasets whose location data and labels are
  stored in GeoJSON format.
  
  See :ref:`this page <GeoJSONDataset-export>` for format details.
  
  Args:
      export_dir (None): the directory to write the export. This has no
          effect if ``data_path`` and ``labels_path`` are absolute paths
      data_path (None): an optional parameter that enables explicit control
          over the location of the exported media. Can be any of the
          following:
  
          -   a folder name like ``"data"`` or ``"data/"`` specifying a
              subfolder of ``export_dir`` in which to export the media
          -   an absolute directory path in which to export the media. In
              this case, the ``export_dir`` has no effect on the location of
              the data
          -   a JSON filename like ``"data.json"`` specifying the filename of
              the manifest file in ``export_dir`` generated when
              ``export_media`` is ``"manifest"``
          -   an absolute filepath specifying the location to write the JSON
              manifest file when ``export_media`` is ``"manifest"``. In this
              case, ``export_dir`` has no effect on the location of the data
  
          If None, the default value of this parameter will be chosen based
          on the value of the ``export_media`` parameter
      labels_path (None): an optional parameter that enables explicit control
          over the location of the exported labels. Can be any of the
          following:
  
          -   a filename like ``"labels.json"`` specifying the location in
              ``export_dir`` in which to export the labels
          -   an absolute filepath to which to export the labels. In this
              case, the ``export_dir`` has no effect on the location of the
              labels
  
          If None, the labels will be exported into ``export_dir`` using the
          default filename
      export_media (None): controls how to export the raw media. The
          supported values are:
  
          -   ``True``: copy all media files into the output directory
          -   ``False``: don't export media
          -   ``"move"``: move all media files into the output directory
          -   ``"symlink"``: create symlinks to the media files in the output
              directory
          -   ``"manifest"``: create a ``data.json`` in the output directory
              that maps UUIDs used in the labels files to the filepaths of
              the source media, rather than exporting the actual media
  
          If None, the default value of this parameter will be chosen based
          on the value of the ``data_path`` parameter
      rel_dir (None): an optional relative directory to strip from each input
          filepath to generate a unique identifier for each media. When
          exporting media, this identifier is joined with ``data_path`` to
          generate an output path for each exported media. This argument
          allows for populating nested subdirectories that match the shape of
          the input paths. The path is converted to an absolute path (if
          necessary) via :func:`fiftyone.core.storage.normalize_path`
      abs_paths (False): whether to store absolute paths to the images in the
          exported labels
      image_format (None): the image format to use when writing in-memory
          images to disk. By default, ``fiftyone.config.default_image_ext``
          is used
      location_field (None): the name of the field containing the location
          data for each sample. Can be any of the following:
  
          -   The name of a :class:`fiftyone.core.fields.GeoLocation` field
          -   The name of a :class:`fiftyone.core.fields.GeoLocations` field
          -   ``None``, in which case there must be a single
              :class:`fiftyone.core.fields.GeoLocation` field on the samples,
              which is used by default
  
      property_makers (None): an optional dict mapping sample field names to
          functions that convert the field values to property values to be
          stored in the ``properties`` field of the GeoJSON ``Feature`` for
          the sample. By default, no properties are written
      omit_none_fields (True): whether to omit ``None``-valued Sample fields
          from the output properties
      pretty_print (False): whether to render the JSON in human readable
          format with newlines and indentations
class_docstr_tok: ["Exporter","for","image","or","video","datasets","whose","location","data","and","labels","are","stored","in","GeoJSON","format",".","See",":","ref",":","`","this","page","<","GeoJSONDataset-export",">","`","for","format","details",".","Args",":","export_dir","(","None",")",":","the","directory","to","write","the","export",".","This","has","no","effect","if","``","data_path","``","and","``","labels_path","``","are","absolute","paths","data_path","(","None",")",":","an","optional","parameter","that","enables","explicit","control","over","the","location","of","the","exported","media",".","Can","be","any","of","the","following",":","-","a","folder","name","like","``","``","data","''","``","or","``","``","data\/","''","``","specifying","a","subfolder","of","``","export_dir","``","in","which","to","export","the","media","-","an","absolute","directory","path","in","which","to","export","the","media",".","In","this","case",",","the","``","export_dir","``","has","no","effect","on","the","location","of","the","data","-","a","JSON","filename","like","``","``","data.json","''","``","specifying","the","filename","of","the","manifest","file","in","``","export_dir","``","generated","when","``","export_media","``","is","``","``","manifest","''","``","-","an","absolute","filepath","specifying","the","location","to","write","the","JSON","manifest","file","when","``","export_media","``","is","``","``","manifest","''","``",".","In","this","case",",","``","export_dir","``","has","no","effect","on","the","location","of","the","data","If","None",",","the","default","value","of","this","parameter","will","be","chosen","based","on","the","value","of","the","``","export_media","``","parameter","labels_path","(","None",")",":","an","optional","parameter","that","enables","explicit","control","over","the","location","of","the","exported","labels",".","Can","be","any","of","the","following",":","-","a","filename","like","``","``","labels.json","''","``","specifying","the","location","in","``","export_dir","``","in","which","to","export","the","labels","-","an","absolute","filepath","to","which","to","export","the","labels",".","In","this","case",",","the","``","export_dir","``","has","no","effect","on","the","location","of","the","labels","If","None",",","the","labels","will","be","exported","into","``","export_dir","``","using","the","default","filename","export_media","(","None",")",":","controls","how","to","export","the","raw","media",".","The","supported","values","are",":","-","``","True","``",":","copy","all","media","files","into","the","output","directory","-","``","False","``",":","do","n't","export","media","-","``","``","move","''","``",":","move","all","media","files","into","the","output","directory","-","``","``","symlink","''","``",":","create","symlinks","to","the","media","files","in","the","output","directory","-","``","``","manifest","''","``",":","create","a","``","data.json","``","in","the","output","directory","that","maps","UUIDs","used","in","the","labels","files","to","the","filepaths","of","the","source","media",",","rather","than","exporting","the","actual","media","If","None",",","the","default","value","of","this","parameter","will","be","chosen","based","on","the","value","of","the","``","data_path","``","parameter","rel_dir","(","None",")",":","an","optional","relative","directory","to","strip","from","each","input","filepath","to","generate","a","unique","identifier","for","each","media",".","When","exporting","media",",","this","identifier","is","joined","with","``","data_path","``","to","generate","an","output","path","for","each","exported","media",".","This","argument","allows","for","populating","nested","subdirectories","that","match","the","shape","of","the","input","paths",".","The","path","is","converted","to","an","absolute","path","(","if","necessary",")","via",":","func",":","`","fiftyone.core.storage.normalize_path","`","abs_paths","(","False",")",":","whether","to","store","absolute","paths","to","the","images","in","the","exported","labels","image_format","(","None",")",":","the","image","format","to","use","when","writing","in-memory","images","to","disk",".","By","default",",","``","fiftyone.config.default_image_ext","``","is","used","location_field","(","None",")",":","the","name","of","the","field","containing","the","location","data","for","each","sample",".","Can","be","any","of","the","following",":","-","The","name","of","a",":","class",":","`","fiftyone.core.fields.GeoLocation","`","field","-","The","name","of","a",":","class",":","`","fiftyone.core.fields.GeoLocations","`","field","-","``","None","``",",","in","which","case","there","must","be","a","single",":","class",":","`","fiftyone.core.fields.GeoLocation","`","field","on","the","samples",",","which","is","used","by","default","property_makers","(","None",")",":","an","optional","dict","mapping","sample","field","names","to","functions","that","convert","the","field","values","to","property","values","to","be","stored","in","the","``","properties","``","field","of","the","GeoJSON","``","Feature","``","for","the","sample",".","By","default",",","no","properties","are","written","omit_none_fields","(","True",")",":","whether","to","omit","``","None","``","-valued","Sample","fields","from","the","output","properties","pretty_print","(","False",")",":","whether","to","render","the","JSON","in","human","readable","format","with","newlines","and","indentations"]
code: def export_sample(self, sample):
      properties = {}
  
      if self.property_makers:
          for key, fn in self.property_makers.items():
              value = sample[key]
              if value is not None or not self.omit_none_fields:
                  properties[key] = fn(value)
  
      out_media_path, uuid = self._media_exporter.export(
          sample.filepath
      )
  
      if self.abs_paths:
          properties["filename"] = out_media_path
      else:
          properties["filename"] = uuid
  
      location = sample[self.location_field]
      if location is not None:
          geometry = location.to_geo_json()
      else:
          geometry = None
  
      self._features.append(
          {
              "type": "Feature",
              "geometry": geometry,
              "properties": properties,
          }
      )
  
imports: import logging
  import os
  import eta.core.serial
  import eta.core.utils
  import fiftyone.core.fields
  import fiftyone.core.labels
  from fiftyone.core.sample import Sample
  import fiftyone.core.storage
  import fiftyone.core.utils
  import fiftyone.core.validation
  import fiftyone.utils.data
label_desc: Use image node_id 4 for calling the GeoJSONDatasetExporter obj's underlying member method code with example usage: obj.export_sample(sample) without return types