Combining tree-based and dynamical systems for the inference of gene regulatory networks