Added comments. Also moved template code behind a function so that main method is not cluttered. Fixed a possible bug in choosing Shared_Byte in which we just did sizeof(S_DATA)*TileSize instead of (sizeof(int) + 2*sizeof(float) * TileSize