Added embedTree implementation.