def open_download_stream_by_name(self, filename, revision=-1):
        validate_string("filename", filename)

        query = {"filename": filename}

        cursor = self._files.find(query)
        if revision < 0:
            skip = abs(revision) - 1
            cursor.limit(-1).skip(skip).sort("uploadDate", DESCENDING)
        else:
            cursor.limit(-1).skip(revision).sort("uploadDate", ASCENDING)
        try:
            grid_file = next(cursor)
            return GridOut(self._collection, file_document=grid_file)
        except StopIteration:
            raise NoFile(
                "no version %d for filename %r" % (revision, filename))
Opens a Stream from which the application can read the contents of
dataset/ETHPy150Open mongodb/mongo-python-driver/gridfs/__init__.py/GridFSBucket.open_download_stream_by_name