protected void SetUp()
		{
	        base_cycle_metric_header header = new base_cycle_metric_header();
            float[] focus1 = new float[]{2.24664021f, 2.1896739f, 0, 0};
            ushort[] p90_1  = new ushort[]{302, 273, 0, 0};
			expected_metrics.Add(new extraction_metric(7, 1114, 1, new csharp_date_time(9859129975844165472ul), (p90_1), (focus1), 4));
			float[] focus2 = new float[]{2.23177338f, 2.20616174f, 0, 0};
            ushort[] p90_2  = new ushort[]{312, 273, 0, 0};
			expected_metrics.Add(new extraction_metric(7, 1214, 1, new csharp_date_time(9859129975872781680ul), (p90_2), (focus2), 4));
			float[] focus3 = new float[]{2.10524225f, 2.14023066f, 0, 0};
            ushort[] p90_3  = new ushort[]{349, 302, 0, 0};
			expected_metrics.Add(new extraction_metric(7, 2114, 1, new csharp_date_time(9859129975901427921ul), (p90_3), (focus3), 4));

			int[] tmp = new int[]{
                2,38
                ,7,0,90,4,1,0,-12,-56,15,64,-98,35,12,64,0,0,0,0,0,0,0,0,46,1,17,1,0,0,0,0,96,-41,-104,36,122,-86,-46,-120
                ,7,0,-66,4,1,0,96,-43,14,64,-63,49,13,64,0,0,0,0,0,0,0,0,56,1,17,1,0,0,0,0,112,125,77,38,122,-86,-46,-120
                ,7,0,66,8,1,0,74,-68,6,64,-118,-7,8,64,0,0,0,0,0,0,0,0,93,1,46,1,0,0,0,0,-47,-104,2,40,122,-86,-46,-120
			};
			expected_binary_data = new byte[tmp.Length];
			for(int i=0;i<expected_binary_data.Length;i++) expected_binary_data[i] = (byte)tmp[i];
			expected_metric_set = new base_extraction_metrics(expected_metrics, Version, header);
			c_csharp_comm.read_interop_from_buffer(expected_binary_data, (uint)expected_binary_data.Length, actual_metric_set);
			actual_metrics = actual_metric_set.metrics();
		}
Exemple #2
0
		protected void SetUp()
		{
	        base_cycle_metric_header header = new base_cycle_metric_header();
		    if(metrics.Count == 0)
		    {
                System.Diagnostics.Stopwatch timer = new System.Diagnostics.Stopwatch();
                timer.Start();
                float[] focus1 = new float[]{2.24664021f, 2.1896739f, 0, 0};
                ushort[] p90_1  = new ushort[]{302, 273, 0, 0};
                for(uint lane = 1;lane <=8;lane++)
                {
                    for(uint tile = 1;tile <=TileCount;tile++)
                    {
                        for(uint cycle = 1;cycle <=318;cycle++)
                        {
                            metrics.Add(new extraction_metric(lane, tile, cycle, new csharp_date_time(9859129975844165472ul), (p90_1), (focus1), 4));
                        }
                    }
                }
                extraction_metric_set = new base_extraction_metrics(metrics, Version, header);
                timer.Stop();
                System.Console.WriteLine("Setup: " + timer.Elapsed.Hours +" : " + timer.Elapsed.Minutes +" : " + timer.Elapsed.Seconds);
                System.Console.WriteLine("Size: " + metrics.Count + " - " + extraction_metric_set.size());
		    }
		}
		/// <summary>
		/// Setup the expected and actual metric sets
		/// </summary>
		/// <param name="tmp">Hard coded binary data</param>
		/// <param name="version">Version of the format</param>
	    protected void SetupBuffers(int[] tmp, short version)
	    {
	        base_cycle_metric_header header = new base_cycle_metric_header();
	        expected_binary_data = new byte[tmp.Length];
	        for(int i=0;i<expected_binary_data.Length;i++) expected_binary_data[i] = (byte)tmp[i];
			expected_metric_set = new base_corrected_intensity_metrics(expected_metrics, version, header);
	        c_csharp_comm.read_interop_from_buffer(expected_binary_data, (uint)expected_binary_data.Length, actual_metric_set);
	        actual_metrics = actual_metric_set.metrics();
	        //actual_binary_data = write_metrics(actual_metric_set);
	    }
        /// <summary>
        /// Setup the expected and actual metric sets
        /// </summary>
        /// <param name="tmp">Hard coded binary data</param>
        /// <param name="version">Version of the format</param>
        protected void SetupBuffers(int[] tmp, short version)
        {
            base_cycle_metric_header header = new base_cycle_metric_header();

            expected_binary_data = new byte[tmp.Length];
            for (int i = 0; i < expected_binary_data.Length; i++)
            {
                expected_binary_data[i] = (byte)tmp[i];
            }
            expected_metric_set = new base_corrected_intensity_metrics(expected_metrics, version, header);
            c_csharp_comm.read_interop_from_buffer(expected_binary_data, (uint)expected_binary_data.Length, actual_metric_set);
            //actual_binary_data = write_metrics(actual_metric_set);
        }
Exemple #5
0
        protected void SetUp()
        {
            base_cycle_metric_header header = new base_cycle_metric_header();

            expected_metrics.Add(new error_metric(7, 1114, 1, 0.450100899f));
            expected_metrics.Add(new error_metric(7, 1114, 2, 0.900201797f));
            expected_metrics.Add(new error_metric(7, 1114, 3, 0.465621591f));

            int[] tmp = new int[] { 3, 30, 7, 0, 90, 4, 1, 0, -96, 115, -26, 62, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
                                    , 7, 0, 90, 4, 2, 0, -96, 115, 102, 63, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
                                    , 7, 0, 90, 4, 3, 0, -12, 101, -18, 62, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 };
            expected_binary_data = new byte[tmp.Length];
            for (int i = 0; i < expected_binary_data.Length; i++)
            {
                expected_binary_data[i] = (byte)tmp[i];
            }
            expected_metric_set = new base_error_metrics(expected_metrics, Version, header);
            c_csharp_comm.read_interop_from_buffer(expected_binary_data, (uint)expected_binary_data.Length, actual_metric_set);
        }
Exemple #6
0
		protected void SetUp()
		{
	        base_cycle_metric_header header = new base_cycle_metric_header();
			expected_metrics.Add(new error_metric(7, 1114, 1, 0.450100899f));
			expected_metrics.Add(new error_metric(7, 1114, 2, 0.900201797f));
			expected_metrics.Add(new error_metric(7, 1114, 3, 0.465621591f));

			int[] tmp = new int[]{3,30,7,0,90,4,1,0,-96,115,-26,62,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
				,7,0,90,4,2,0,-96,115,102,63,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
				,7,0,90,4,3,0,-12,101,-18,62,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
			};
			expected_binary_data = new byte[tmp.Length];
			for(int i=0;i<expected_binary_data.Length;i++)
			{
			    expected_binary_data[i] = (byte)tmp[i];
			}
			expected_metric_set = new base_error_metrics(expected_metrics, Version, header);
			c_csharp_comm.read_interop_from_buffer(expected_binary_data, (uint)expected_binary_data.Length, actual_metric_set);
			actual_metrics = actual_metric_set.metrics();
		}