tt-perf-report 1.1.1__tar.gz → 1.1.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of tt-perf-report might be problematic. Click here for more details.

@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: tt-perf-report
3
- Version: 1.1.1
3
+ Version: 1.1.2
4
4
  Summary: This tool analyzes performance traces from TT-Metal operations, providing insights into throughput, bottlenecks, and optimization opportunities.
5
5
  License: Apache License
6
6
  Version 2.0, January 2004
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "tt-perf-report"
7
- version = "1.1.1"
7
+ version = "1.1.2"
8
8
  description = "This tool analyzes performance traces from TT-Metal operations, providing insights into throughput, bottlenecks, and optimization opportunities."
9
9
  license = {file = "LICENSE"}
10
10
  readme = "README.md"
@@ -168,11 +168,32 @@ def pad_string(string, length, align="left"):
168
168
  return padding + string if align == "right" else string + padding
169
169
 
170
170
 
171
- def evaluate_fidelity(input_0_datatype, input_1_datatype, output_datatype, math_fidelity):
172
- mantissa_bits = {"BFLOAT16": 8, "BFLOAT8_B": 7, "BFLOAT4_B": 3}
173
- in0_bits = mantissa_bits[input_0_datatype] # activations -> srcB (7 bits)
174
- in1_bits = mantissa_bits[input_1_datatype] # weights -> srcA (5 bits)
175
- out_bits = mantissa_bits[output_datatype]
171
+ def evaluate_fidelity(
172
+ input_0_datatype, input_1_datatype, output_datatype, math_fidelity
173
+ ):
174
+ integer_types = {"UINT8", "UINT16", "INT32", "UINT32"}
175
+
176
+ if (
177
+ input_0_datatype in integer_types
178
+ or input_1_datatype in integer_types
179
+ or output_datatype in integer_types
180
+ ):
181
+ return (
182
+ "not_applicable",
183
+ "Fidelity evaluation is not applicable for integer datatypes (UINT8, UINT16, INT32, UINT32).",
184
+ )
185
+
186
+ mantissa_bits = {"FLOAT32": 23, "BFLOAT16": 8, "BFLOAT8_B": 7, "BFLOAT4_B": 3}
187
+ try:
188
+ in0_bits = mantissa_bits[input_0_datatype] # activations -> srcB (7 bits)
189
+ in1_bits = mantissa_bits[input_1_datatype] # weights -> srcA (5 bits)
190
+ out_bits = mantissa_bits[output_datatype]
191
+ except KeyError as e:
192
+ return (
193
+ "unknown",
194
+ f"Datatype {e.args[0]} is not supported for fidelity evaluation.",
195
+ )
196
+
176
197
  if in0_bits == 8 and out_bits >= 7:
177
198
  if math_fidelity == "HiFi4":
178
199
  return (
@@ -435,7 +456,12 @@ def analyze_op(row, prev_row, csv_format="v2"):
435
456
  output_datatype_cell = Cell(output_datatype)
436
457
  input_0_datatype_cell = Cell(input_0_datatype)
437
458
  input_1_datatype_cell = Cell(input_1_datatype)
438
- short_name = lambda n: {"BFLOAT16": "BF16", "BFLOAT8_B": "BFP8", "BFLOAT4_B": "BFP4"}.get(n, n)
459
+ short_name = lambda n: {
460
+ "FLOAT32": "FP32",
461
+ "BFLOAT16": "BF16",
462
+ "BFLOAT8_B": "BFP8",
463
+ "BFLOAT4_B": "BFP4",
464
+ }.get(n, n)
439
465
 
440
466
  dram_speed = Cell(None, unit="GB/s", decimals=0)
441
467
  dram_percentage = Cell(None, unit="%", decimals=1)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: tt-perf-report
3
- Version: 1.1.1
3
+ Version: 1.1.2
4
4
  Summary: This tool analyzes performance traces from TT-Metal operations, providing insights into throughput, bottlenecks, and optimization opportunities.
5
5
  License: Apache License
6
6
  Version 2.0, January 2004
File without changes
File without changes
File without changes