guan404ming commented on code in PR #1116:
URL: https://github.com/apache/mahout/pull/1116#discussion_r2884648037
##########
qdp/qdp-python/src/engine.rs:
##########
@@ -506,10 +506,35 @@ impl QdpEngine {
consumed: false,
})
}
- 2 => Err(PyRuntimeError::new_err(
- "CUDA float32 batch amplitude encoding is not yet
supported. \
- Use float64 (tensor.to(torch.float64)) or encode samples
individually.",
- )),
+ 2 => {
+ let num_samples: usize = data.call_method1("size",
(0,))?.extract()?;
Review Comment:
Nit: consider using `tensor_info.shape` for consistency with the f64 path,
though the current approach is functionally correct since contiguity is already
validated.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]