def _read_exif(self, file):
    result = {}
    try:
        file.open('rb')
        tags = exifread.process_file(file)
        self.focal_length = self._get_and_format(tags, 'EXIF FocalLength', '%gmm', (lambda s: Fraction(s)))
        self.iso = self._get_and_format(tags, 'EXIF ISOSpeedRatings', 'ISO %d', (lambda s: int(s)))
        self.fraction = self._get_and_format(tags, 'EXIF FNumber', 'f/%g', (lambda s: float(Fraction(s))))
        exposure_time = self._get_and_format(tags, 'EXIF ExposureTime', None, (lambda s: Fraction(s)))
        exposure_time_str = ''
        if exposure_time:
            if (exposure_time >= 1):
                exposure_time_str = ('%gs' % exposure_time)
            else:
                exposure_time_str = ('%ss' % str(exposure_time))
        self.exposure_time = exposure_time_str
    except IOError as e:
        pass
def _read_exif(self, file):
    result = {}
    try:
        file.open('rb')
        tags = exifread.process_file(file)
        self.focal_length = self._get_and_format(tags, 'EXIF FocalLength', '%gmm', (lambda s: Fraction(s)))
        self.iso = self._get_and_format(tags, 'EXIF ISOSpeedRatings', 'ISO %d', (lambda s: int(s)))
        self.fraction = self._get_and_format(tags, 'EXIF FNumber', 'f/%g', (lambda s: float(Fraction(s))))
        exposure_time = self._get_and_format(tags, 'EXIF ExposureTime', None, (lambda s: Fraction(s)))
        exposure_time_str = 
        if exposure_time:
            if (exposure_time >= 1):
                exposure_time_str = ('%gs' % exposure_time)
            else:
                exposure_time_str = ('%ss' % str(exposure_time))
        self.exposure_time = exposure_time_str
    except IOError as e:
        pass