def is_valid(self):
        """Check the file extension against valid file extensions.

        The list of valid file extensions come from self.extensions.

        :returns: bool
        """
        source = self.source
        return os.path.splitext(source)[1][1:].lower() in self.extensions
dataset/ETHPy150Open jmathai/elodie/elodie/media/base.py/Base.is_valid/original