An Optimization-Based Approach for Continuous Map Generalization