<commit_before>#include <iostream>
#include <iomanip>
#include <string>
#include <sstream>
#include <Windows.h>
#include <cuda_profiler_api.h>
#include "hf_siddon_recon.hpp"


int main()
{
	cudaProfilerStart();

	double totalTime;
	StopWatchInterface *timer;
	sdkCreateTimer(&timer);
	sdkResetTimer(&timer);
	sdkStartTimer(&timer);
	
	//----------------reconstruction part--------------------------------
	siddon_recon recon;
	recon.a1_forward_projection("H:\\Visual Studio 2010\\CT_Recon\\CT_Recon", "MasterParameterFile.cfg");
	//recon.a0_recon_mlem("H:\\Visual Studio 2010\\CT_Recon\\CT_Recon\\ball", "fp_ball64.cfg");
	//recon.a1_backward_projection("H:\\Visual Studio 2010\\CT_Recon\\CT_Recon\\ball", "fp_ball64.cfg", true);
	//-------------------------------------------------------------------


	//------- just backprojection--------------------------------------
	//dim3 threads_image, blocks_image, threads_object, blocks_object, threads_atomic, blocks_atomic;

	//siddon_recon recon;
	//recon.a1_recon_initiate("CTParameters_042414.h");
	//recon.a_pull_kernel_threads(blocks_image, threads_image, blocks_object, threads_object, blocks_atomic, threads_atomic);
	//int N_image_pixels = recon.siddon_var.N_image_pixels;
	//int N_object_voxels = recon.siddon_var.N_object_voxels;


	//float *image = new float [N_image_pixels];
	//float *object = new float [N_object_voxels];
	//
	//float *d_image, *d_object;
	//LoadRawData<float> readfloat;
	//SaveRawData<float> savefloat;
	//
	//CUDA_SAFE_CALL( cudaMalloc((void**)&d_image, N_image_pixels*sizeof(float)) );
	//CUDA_SAFE_CALL( cudaMalloc((void**)&d_object, N_object_voxels*sizeof(float)) );
	//CUDA_SAFE_CALL( cudaMemset(d_object, 0, N_object_voxels*sizeof(float) ) );

	//for (int n = 0; n < 180; n++)
	//{
	//	float angle_degree = (float)n*2;
	//	recon.siddon_var.a_calc_initial_limits(angle_degree, blocks_image, threads_image);

	//	//readfloat(image, N_image_pixels*sizeof(float), "");
	//	//CUDA_SAFE_CALL( cudaMemcpy(d_image, image, N_image_pixels*sizeof(float), cudaMemcpyHostToDevice) );

	//	set_ones<<<blocks_image, threads_image>>>(d_image);
	//	recon.a2_bp_per_angle(d_image, recon.siddon_var, blocks_image, threads_image, blocks_object, threads_object, blocks_atomic, threads_atomic);
	//	siddon_add_bp<<<blocks_object, threads_object>>>(d_object, recon.a_bpdevicepointer());

	//	CUDA_SAFE_CALL( cudaMemcpy(object, recon.a_bpdevicepointer(), N_object_voxels*sizeof(float), cudaMemcpyDeviceToHost) );
	//	savefloat(object, N_object_voxels*sizeof(float), 
	//		create_filename("H:/Visual Studio 2010/CTSolution/Siddon/bp_ones/", "bp_ones32", n, ".bin") );
	//	std::cout << "angle = " << angle_degree << std::endl;
	//}
	//
	//
	//CUDA_SAFE_CALL( cudaMemcpy(object, d_object, N_object_voxels*sizeof(float), cudaMemcpyDeviceToHost) );
	//savefloat(object, N_object_voxels*sizeof(float), 
	//	create_filename("H:/Visual Studio 2010/CTSolution/Siddon/bp_ones/", "total_bp_ones32.bin") );
	//CUDA_SAFE_CALL( cudaFree(d_image) );
	//CUDA_SAFE_CALL( cudaFree(d_object) );
	//delete [] image, object;	
	//-----------------------------------------------------------------------------------------------------------------------------------------------------


	sdkStopTimer(&timer);
	totalTime = sdkGetTimerValue(&timer)*1e-3;
	printf("calculation time = %f seconds \n", totalTime);

	cudaProfilerStop();
<commit_msg>Added comment on mlem.cu file<commit_after>#include <iostream>
#include <iomanip>
#include <string>
#include <sstream>
#include <Windows.h>
#include <cuda_profiler_api.h>
#include "hf_siddon_recon.hpp"


int main()
{
	cudaProfilerStart();

	double totalTime;
	StopWatchInterface *timer;
	sdkCreateTimer(&timer);
	sdkResetTimer(&timer);
	sdkStartTimer(&timer);
	
	//---------------- how to use siddon_recon class --------------------------------
	//siddon_recon recon;
	//recon.a1_forward_projection("H:\\Visual Studio 2010\\CT_Recon\\CT_Recon", "MasterParameterFile.cfg");
	//recon.a0_recon_mlem("H:\\Visual Studio 2010\\CT_Recon\\CT_Recon\\ball", "fp_ball64.cfg");
	//recon.a1_backward_projection("H:\\Visual Studio 2010\\CT_Recon\\CT_Recon\\ball", "fp_ball64.cfg", true);
	//-------------------------------------------------------------------
	

	sdkStopTimer(&timer);
	totalTime = sdkGetTimerValue(&timer)*1e-3;
	printf("calculation time = %f seconds \n", totalTime);

	cudaProfilerStop();

{'fraction_non_alphanumeric': 0.24107959743824336, 'fraction_numerical': 0.01578225068618481, 'mean_word_length': 3.3469184890656063, 'pattern_counts': {'":': 0, '<': 30, '<?xml version=': 0, '>': 23, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '715217', 'n_tokens_mistral': 1626, 'n_tokens_neox': 1555, 'n_words': 228}