wip: dataTools close resource leak
wip: converting to N-D