use thread safe num_nodes