• Docs >
  • Library API >
  • Template Function at::symint::_efficient_attention_forward(const at::Tensor&, const at::Tensor&, const at::Tensor&, const ::std::optional<at::Tensor>&, const ::std::optional<at::Tensor>&, const ::std::optional<at::Tensor>&, ::std::optional<int64_t>, ::std::optional<int64_t>, double, int64_t, bool, ::std::optional<double>, const ::std::optional<at::Tensor>&, ::std::optional<int64_t>)
  • Edit on GitHub
Shortcuts

Template Function at::symint::_efficient_attention_forward(const at::Tensor&, const at::Tensor&, const at::Tensor&, const ::std::optional<at::Tensor>&, const ::std::optional<at::Tensor>&, const ::std::optional<at::Tensor>&, ::std::optional<int64_t>, ::std::optional<int64_t>, double, int64_t, bool, ::std::optional<double>, const ::std::optional<at::Tensor>&, ::std::optional<int64_t>)

Function Documentation

template<typename T, typename = std::enable_if_t<std::is_same_v<T, int64_t>>>
::std::tuple<at::Tensor, at::Tensor, at::Tensor, at::Tensor, c10::SymInt, c10::SymInt> at::symint::_efficient_attention_forward(const at::Tensor &query, const at::Tensor &key, const at::Tensor &value, const ::std::optional<at::Tensor> &bias, const ::std::optional<at::Tensor> &cu_seqlens_q, const ::std::optional<at::Tensor> &cu_seqlens_k, ::std::optional<int64_t> max_seqlen_q, ::std::optional<int64_t> max_seqlen_k, double dropout_p, int64_t custom_mask_type, bool compute_log_sumexp = false, ::std::optional<double> scale = ::std::nullopt, const ::std::optional<at::Tensor> &seqlen_k = {}, ::std::optional<int64_t> window_size = ::std::nullopt)

Docs

Access comprehensive developer documentation for PyTorch

View Docs

Tutorials

Get in-depth tutorials for beginners and advanced developers

View Tutorials

Resources

Find development resources and get your questions answered

View Resources