Home / Function/ header_fmt_str() — pytorch Function Reference

header_fmt_str() — pytorch Function Reference

Architecture documentation for the header_fmt_str() function in compare-fastrnn-results.py from the pytorch codebase.

Entity Profile

Dependency Diagram

graph TD
  17f8ae9c_b31e_e506_f023_e7c5fe4be3dd["header_fmt_str()"]
  dae18006_ed25_a6a6_45ae_39aac9e00a5d["print()"]
  17f8ae9c_b31e_e506_f023_e7c5fe4be3dd -->|calls| dae18006_ed25_a6a6_45ae_39aac9e00a5d
  style 17f8ae9c_b31e_e506_f023_e7c5fe4be3dd fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

benchmarks/compare-fastrnn-results.py lines 55–68

    header_fmt_str = header_fmt[args.format]
    data_fmt_str = data_fmt[args.format]
    print(header_fmt_str.format("name", "base time (s)", "diff time (s)", "% change"))
    if args.format == "md":
        print(header_fmt_str.format(":---", "---:", "---:", "---:"))
    for r in results:
        print(
            data_fmt_str.format(
                r.name,
                r.base_time,
                r.diff_time,
                (r.diff_time / r.base_time - 1.0) * 100.0,
            )
        )

Domain

Subdomains

Calls

Frequently Asked Questions

What does header_fmt_str() do?
header_fmt_str() is a function in the pytorch codebase.
What does header_fmt_str() call?
header_fmt_str() calls 1 function(s): print.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free