def get_obs_leaves(self):
obs_leaves = []<EOL>for n in self:<EOL><INDENT>if n.is_leaf:<EOL><INDENT>if isinstance(n, ModelNode):<EOL><INDENT>l = n.parent<EOL><DEDENT>else:<EOL><INDENT>l = n<EOL><DEDENT><DEDENT>if l not in obs_leaves:<EOL><INDENT>obs_leaves.append(l)<EOL><DEDENT><DEDENT>return obs_leaves<EOL>
Returns the last obs nodes that are leaves