From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by dpdk.org (Postfix) with ESMTP id 93EB25A57 for ; Thu, 31 Dec 2015 09:36:33 +0100 (CET) Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by orsmga102.jf.intel.com with ESMTP; 31 Dec 2015 00:36:32 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.20,503,1444719600"; d="scan'208";a="21642703" Received: from fmsmsx106.amr.corp.intel.com ([10.18.124.204]) by fmsmga004.fm.intel.com with ESMTP; 31 Dec 2015 00:36:33 -0800 Received: from shsmsx151.ccr.corp.intel.com (10.239.6.50) by FMSMSX106.amr.corp.intel.com (10.18.124.204) with Microsoft SMTP Server (TLS) id 14.3.248.2; Thu, 31 Dec 2015 00:36:32 -0800 Received: from shsmsx102.ccr.corp.intel.com ([169.254.2.133]) by SHSMSX151.ccr.corp.intel.com ([169.254.3.220]) with mapi id 14.03.0248.002; Thu, 31 Dec 2015 16:36:30 +0800 From: "Xu, Qian Q" To: "Ding, HengX" , "dts@dpdk.org" Thread-Topic: [dts] [PATCH 2/2] l3fwd: delete plot funtions Thread-Index: AQHRQ6TvYbOvlQzcAkSk7UyYGzj+dp7kxS0g Date: Thu, 31 Dec 2015 08:36:29 +0000 Message-ID: <82F45D86ADE5454A95A89742C8D1410E031A4E4A@shsmsx102.ccr.corp.intel.com> References: <1451550354-26047-1-git-send-email-hengx.ding@intel.com> <1451550354-26047-2-git-send-email-hengx.ding@intel.com> In-Reply-To: <1451550354-26047-2-git-send-email-hengx.ding@intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiODE0MTUxNDUtMWMzMC00ZTM2LTgxMzUtNjg4OWY3NTAxM2JkIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX0lDIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE1LjQuMTAuMTkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiSjB4QzE3ZmIrT0U5YnlsR3dDN3ZKTHN5TmhUXC9NQkp2RW9US2dTZlwvZFVBPSJ9 x-ctpclassification: CTP_IC x-originating-ip: [10.239.127.40] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Cc: "Ding, HengX" Subject: Re: [dts] [PATCH 2/2] l3fwd: delete plot funtions X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: test suite reviews and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 31 Dec 2015 08:36:34 -0000 Thanks Qian -----Original Message----- From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of Ding Heng Sent: Thursday, December 31, 2015 4:26 PM To: dts@dpdk.org Cc: Ding, HengX Subject: [dts] [PATCH 2/2] l3fwd: delete plot funtions Signed-off-by: Ding Heng diff --git a/tests/TestSuite_l3fwd.py b/tests/TestSuite_l3fwd.py index e785= b8b..63d6acd 100644 --- a/tests/TestSuite_l3fwd.py +++ b/tests/TestSuite_l3fwd.py @@ -95,7 +95,7 @@ class TestL3fwd(TestCase,IxiaPacketGenerator): "{IPv4(13,101,0,0), 24, P3}", ] =20 - frame_sizes =3D [64, 128, 256, 512, 2048] # 65, 128 + frame_sizes =3D [64]#, 128, 256, 512, 2048] # 65, 128 Qian: Pls check the line, 64]#??? methods =3D ['lpm', 'exact'] =20 # @@ -121,160 +121,6 @@ class TestL3fwd(TestCase,IxiaPacketGenerator): # Test cases. # =20 - def plot_4_ports(self): - - data =3D self.l3fwd_test_results['data'] - - # Create a plot for each number of queues for frame size and mode = comparison - cores =3D '1S/1C/1T' - for queues in TestL3fwd.queues_4_ports: - ydata =3D [] - lpm_ydata =3D [] - exact_ydata =3D [] - for frame_size in TestL3fwd.frame_sizes: - for row in data: - if row[1] * 4 =3D=3D queues and row[2] =3D=3D cores an= d \ - row[0] =3D=3D frame_size: - if len(TestL3fwd.methods) =3D=3D 2: - lpm_ydata.append(row[4]) - exact_ydata.append(row[6]) - else: - if 'lpm' in TestL3fwd.methods: - lpm_ydata.append(row[4]) - if 'exact' in TestL3fwd.methods: - exact_ydata.append(row[4]) - - if 'lpm' in TestL3fwd.methods: - ydata.append(lpm_ydata) - if 'exact' in TestL3fwd.methods: - ydata.append(exact_ydata) - - if len(ydata[0]) =3D=3D 0: - self.logger.warning('No data for plotting 1S/1C/1T') - break - else: - try: - image_path =3D self.plotting.create_bars_plot( - 'test_perf_l3fwd_4ports_1S_1C_1T_%dRxQ' % queues, - 'LPM & Exact modes, 1S/1C/1T, %d Rx Queues, 4 port= s' % queues, - TestL3fwd.frame_sizes, - ydata, - ylabel=3D'% linerate', - legend=3DTestL3fwd.methods) - - dts.results_plot_print(image_path, 50) - except VerifyFailure as e: - self.logger.error(str(e)) - - # Create a plot for each number of queues for core config and mode= comparison - frame_size =3D TestL3fwd.frame_sizes[0] # Frame size fixed to th= e first selected - for queues in TestL3fwd.queues_4_ports: - - cores =3D [] - for row in data: - if row[2] not in cores and \ - row[1] * 4 =3D=3D queues: - cores.append(row[2]) - - ydata =3D [] - lpm_ydata =3D [] - exact_ydata =3D [] - - for core in cores: - for row in data: - if row[1] * 4 =3D=3D queues and \ - row[2] =3D=3D core and \ - row[0] =3D=3D frame_size: - if len(TestL3fwd.methods) =3D=3D 2: - lpm_ydata.append(row[4]) - exact_ydata.append(row[6]) - else: - if 'lpm' in TestL3fwd.methods: - lpm_ydata.append(row[4]) - if 'exact' in TestL3fwd.methods: - exact_ydata.append(row[4]) - - if 'lpm' in TestL3fwd.methods: - ydata.append(lpm_ydata) - if 'exact' in TestL3fwd.methods: - ydata.append(exact_ydata) - - try: - image_path =3D self.plotting.create_bars_plot( - 'test_perf_l3fwd_4ports_%d_%dRxQ' % (frame_size, queue= s), - 'LPM & Exact modes, %dB, %d Rx Queues, 4 ports' % (fra= me_size, queues), - TestL3fwd.frame_sizes, - ydata, - ylabel=3D'% linerate', - legend=3DTestL3fwd.methods) - - dts.results_plot_print(image_path) - except VerifyFailure as e: - self.logger.error(str(e)) - - def plot_2_ports(self): - - data =3D self.l3fwd_test_results['data'] - - cores =3D [] - for row in data: - if row[2] not in cores: - cores.append(row[2]) - - # Create a plot for each mode for frame size and cores comparison - for mode in TestL3fwd.methods: - mode_ydata =3D [] - - for core in cores: - core_ydata =3D [] - for row in data: - if row[1] =3D=3D mode and row[2] =3D=3D core: - core_ydata.append(float(row[4])) - - mode_ydata.append(core_ydata) - - image_path =3D self.plotting.create_bars_plot( - 'test_perf_l3fwd_2ports_%s' % mode, - 'L3fwd %s mode, 2 ports' % mode, - TestL3fwd.frame_sizes, - mode_ydata, - ylabel=3D'% linerate', - legend=3Dcores) - - dts.results_plot_print(image_path, 50) - - # If testing only one mode, do nothing else. - if len(TestL3fwd.methods) =3D=3D 1: - return - - # Create a plot for 1st core config for mode and frame size compar= ison - core =3D '1S/1C/1T' - - ydata =3D [] - for mode in TestL3fwd.methods: - mode_ydata =3D [] - for frame_size in TestL3fwd.frame_sizes: - for row in data: - if row[2] =3D=3D core and row[0] =3D=3D frame_size and= \ - row[1] =3D=3D mode: - mode_ydata.append(float(row[4])) - - ydata.append(mode_ydata) - - str_frame_sizes =3D [] - for frame_size in TestL3fwd.frame_sizes: - str_frame_sizes.append(str(frame_size)) - - image_path =3D self.plotting.create_bars_plot( - 'test_perf_l3fwd_2ports_1S_1C_1T', - 'L3fwd 1S/1C/1T cores, 2 ports', - TestL3fwd.frame_sizes, - ydata, - ylabel=3D'% linerate', - legend=3DTestL3fwd.methods) - - dts.results_plot_print(image_path) - def set_up_all(self): """ Run at the start of each test suite. @@ -513,7 +359,6 @@ class TestL3fwd(TestCase,IxiaPacketGenerator): if number_sockets >=3D int(test_case[1].split('/')[0][0]): self.get_throughput(frame_size, *test_case) =20 - self.plot_4_ports() dts.results_table_print() =20 def test_perf_l3fwd_2ports(self): @@ -615,7 +460,6 @@ class TestL3fwd(TestCase,IxiaPacketGenerator): dts.results_table_add_row(data_row) self.l3fwd_test_results['data'].append(data_row) =20 - self.plot_2_ports() dts.results_table_print() =20 def test_perf_rfc2544(self): -- 1.9.3