pickling of models
FIX: functions for GPU did not work