Transfer Learning for Bayesian Optimization on Heterogeneous Search Spaces