Thanks to visit codestin.com
Credit goes to github.com

Skip to content

[BUG] Simple einsum program failed to compile #597

@lucifer1004

Description

@lucifer1004

The following code could not compile

#include "matx.h"

int main([[maybe_unused]] int argc, [[maybe_unused]] char **argv) {
  MATX_ENTER_HANDLER();

  auto a = matx::make_tensor<float>({10, 10});
  auto b = matx::make_tensor<float>({10, 10});
  auto c = matx::make_tensor<float>({10, 10});

  auto exec = matx::cudaExecutor();
  (c = matx::cutensor::einsum("ik,kl->il", a, b)).run(exec);
  matx::print(c);

  CUDA_CHECK_LAST_ERROR();
  MATX_EXIT_HANDLER();
}

The error message was:

MatX/include/matx/transforms/einsum.h(457): error: class "matx::detail::matxCache_t" may not have a template argument list
  static matxCache_t<EinsumParams_t<InT...>, EinsumParamsKeyHash<InT...>, EinsumParamsKeyEq<InT...>> einsum_cache;

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions