Using range minimal query for lowest common ancestor (LCA) -- part 2
advice on ... code style


Including docstrings would be good, e.g. to spell out that RMQ denotes Range Minimal Query.
But as a more pressing matter, your identifiers are much too ambiguous.
The names rmq_index or node_index_map are just not helpful as you never describe an index, and result and raw_array are even worse. At least stick to one or the other, don't use both of them to describe the same thing.
Not once did you refer to the literature (e.g. Schieber and Vishkin), nor comment on an invariant you were maintaining.

It would be helpful to include sample in/out values in the SO posting or, better, in the comments or docstrings. You regrettably ignored the advice to use flake8.

    self.value = value


This appears to be more of a unique id than some continuous value.

    for i,v in enumerate(raw_array):


This may have been clearer as for i, depth_id.

It's not clear how a step is different from a depth.

In ... self.rmq_index[(i+2**(step-1), step-1)][0] &lt; self.rmq_index[(i, step-1)][0]: it would have been helpful to break out depth_left &amp; depth_right and compare them.

These look like they are useful tests:

print rmq.rmq_query(node_index_map[4], node_index_map[5])
print rmq.rmq_query(node_index_map[4], node_index_map[7])


but they would be far more informative in the form of assertEqual statements in a unittest.TestCase.