def get_alt_path(self, output_path, alt_dir=None):
        """Returns the alternate path for the given output path generated by
        :meth:`get_output_path`.

        Args:
            output_path: an output path
            alt_dir (None): a directory in which to return the alternate path.
                If not provided, :attr:`alt_dir` is used

        Returns:
            the corresponding alternate path
        """
        root_dir = alt_dir or self.alt_dir or self.output_dir
        rel_path = os.path.relpath(output_path, self.output_dir)
        return os.path.join(root_dir, rel_path)
Returns the alternate path for the given output path generated by
        :meth:`get_output_path`.

        Args:
            output_path: an output path
            alt_dir (None): a directory in which to return the alternate path.
                If not provided, :attr:`alt_dir` is used

        Returns:
            the corresponding alternate path
        
fiftyone/core/utils.py