def _convert_to_dict(data):
if isinstance(data, dict):<EOL><INDENT>return data<EOL><DEDENT>if isinstance(data, list) or isinstance(data, tuple):<EOL><INDENT>if _all_correct_list(data):<EOL><INDENT>return dict(data)<EOL><DEDENT>else:<EOL><INDENT>data = zip(data[::<NUM_LIT:2>], data[<NUM_LIT:1>::<NUM_LIT:2>])<EOL>return dict(data)<EOL><DEDENT><DEDENT>else:<EOL><INDENT>raise MetaParsingException(<EOL>"<STR_LIT>"<EOL>)<EOL><DEDENT>
Convert `data` to dictionary.

Tries to get sense in multidimensional arrays.

Args:
    data: List/dict/tuple of variable dimension.

Returns:
    dict: If the data can be converted to dictionary.

Raises:
    MetaParsingException: When the data are unconvertible to dict.