High-Dimensional Optimization in Adaptive Random Subspaces