TorchLean API

NN.Tactic.Einops.Report.Analysis.Common

Shared report decoding #

This module provides the reflection, formatting, and axis-analysis utilities used by the operation-specific einops? reports.

instantiateOuterLets is not defined here. It is Tensor.Internal.instantiateOuterLets from NN/Tactic/Einops/Proof.lean, which this module already imports, and which had the identical four-line body. Report.Impl sits inside Tensor.Internal, so the uses below find it by walking outward.

Normalize reflected report data after instantiating pending metavariables.

Instances For

    Expose the fields of an expected reflected constructor after removing generated outer lets and metadata.

    Instances For

      Decode a reflected string only when kernel normalization exposes a literal.

      Instances For

        Decode a reflected natural number only when it reduces to a literal.

        Instances For
          partial def TorchLean.Tensor.Internal.Report.Impl.decodeExprList {α : Type} (expression : Lean.Expr) (decodeItem : Lean.ExprLean.MetaM (Option α)) :

          Decode a reflected list with an element decoder, failing atomically.

          Decode a fully concrete reflected shape or list of natural numbers.

          Instances For

            Decode a transformation axis together with its user-facing description.

            Instances For

              Decode an einsum axis together with its user-facing description.

              Instances For

                Decode a reflected einsum axis to its concrete checker value.

                Instances For

                  Render one concrete shape in tensor notation.

                  Instances For

                    Render a heterogeneous family of concrete shapes.

                    Instances For

                      Compute the number of scalar entries described by a concrete shape.

                      Instances For

                        Pretty-print an elaborated type using the current local context.

                        Instances For

                          Infer and pretty-print the type of an elaborated expression.

                          Instances For

                            Test whether a reflected term contains an application of a named constant.

                            Instances For

                              Pretty-print one concrete tensor type without evaluating a tensor value.

                              Instances For

                                Format one uniformly indented report section.

                                Instances For

                                  Format checked input and output types.

                                  Instances For

                                    Explain how static estimates relate to actual runtime measurements.

                                    Instances For

                                      Render a flat logical-axis list.

                                      Instances For

                                        Render one elementary-axis group using einops parentheses.

                                        Instances For

                                          Render a physical shape's complete sequence of logical-axis groups.

                                          Instances For

                                            Preserve the first occurrence of each reflected axis expression.

                                            Instances For

                                              Select axes absent from another reflected axis list.

                                              Instances For

                                                Select the axes repeated within one operand.

                                                Instances For

                                                  Look up the concrete length associated with a reflected axis expression.

                                                  Instances For

                                                    Resolve an ordered axis list to a concrete shape when every length is known.

                                                    Instances For

                                                      Describe singleton dimensions that expand to non-singleton logical axes.

                                                      Instances For

                                                        Number human-readable lowering stages from the supplied starting index.

                                                        Instances For