<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def from_data(cls, data):
 """Create a list of Messages from deserialized epubcheck json output. :param dict data: Decoded epubcheck json data :return list[Message]: List of messages """

        messages = []
        filename = data['checker']['filename']
        for m in data['messages']:
            for l in m['locations']:
                location = l['path']
                if not location.startswith(filename):
                    location = filename + '/' + location
                if l['line'] != -1:
                    location += ':{}'.format(l['line'])
                if l['column'] != -1:
                    location += ':{}'.format(l['column'])
                messages.append(
                    cls(m['ID'], m['severity'], location, m['message'], m['suggestion'])
                )
        return messages