@classmethod
def from_dict(cls, content):
    """ Can contain two keys:
        
        ops_by_dut_id: A dut_id indexed list of operations
        ops: A list of operation
        
        (in yaml format)
        ops:
          - dut_match: 'my_unit'
            dut_after: 
                id: 'my_unit' # optional
                version: 'my_version'
            op_datetime: '2018-02-11 11:02:57'
          - (other ops...)
          
        OR
        
        ops_by_dut_id:
            my_unit:
                - dut_after:
                    version: 'my_version'
                  op_datetime: '2018-02-11 11:02:57'
        """
    ops = content.get('ops', None)
    ops_by_dut_id = content.get('ops_by_dut_id', None)
    if ops:
        return cls._parse_ops_array(ops)
    elif ops_by_dut_id:
        return cls._parse_ops_by_dut_id_dict(ops_by_dut_id)
    else:
        raise ValueError(
            'Dict content must have either a ops or ops_by_dut_id top-level key. Received keys: {}'
            .format(list(content.keys())))
