         }
 
         // // Handle snapshoting
-        // if (opt.return_style == tsnecuda::RETURN_STYLE::SNAPSHOT && step % snap_interval == 0 && opt.return_data != nullptr) {
-        //   thrust::copy(points_device.begin(),
-        //                points_device.end(),
-        //                snap_num*opt.num_points*2 + opt.return_data);
-        //   snap_num += 1;
-        // }
+        if (opt.return_style == tsnecuda::RETURN_STYLE::SNAPSHOT && step % snap_interval == 0 && opt.return_data != nullptr) {
+          thrust::copy(points_device.begin(),
+                       points_device.end(),
+                       snap_num*opt.num_points*2 + opt.return_data);
+          snap_num += 1;
+        }
 
     }
 

            std::cout << "This version is not built with ZMQ for interative viz. Rebuild with WITH_ZMQ=TRUE for viz." << std::endl;
    #endif



    END_IL_TIMER(_time_init_fft);


    // Support for infinite iteration
    for (size_t step = 0; step != opt.iterations; step++) {


    float attr_exaggeration = opt.early_exaggeration;
    float normalization;

    // Allocate host memory
    float *knn_squared_distances = new float[num_points * num_neighbors];
    memset(knn_squared_distances, 0, num_points * num_neighbors * sizeof(float));
    long *knn_indices = new long[num_points * num_neighbors];

    // Set cache configs
    cudaFuncSetCacheConfig(tsnecuda::IntegrationKernel, cudaFuncCachePreferL1);
    cudaFuncSetCacheConfig(tsnecuda::ComputePijxQijKernel, cudaFuncCachePreferShared);
    GpuErrorCheck(cudaDeviceSynchronize());


    END_IL_TIMER(_time_initialization);
    START_IL_TIMER();
