'Transform the appropriate sample fields.'

def _convert(self, s, growth=1):

    volume = (self._scale(s) * growth)
    return sample.Sample(name=self._map(s, 'name'), unit=self._map(s, 'unit'), type=self.target.get('type', s.type), volume=(min(volume, self.max) if self.max else volume), user_id=s.user_id, project_id=s.project_id, resource_id=s.resource_id, timestamp=s.timestamp, resource_metadata=s.resource_metadata)
