New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Directly constructing a Tensor #15
Comments
Sure, you can run the following code. open Torch;;
let x = Tensor.of_float1 [| 5.5; 3. |];;
Tensor.print x;; Fwiw for playing with the library I often use utop by just running |
I definitely don't have a fluid workflow though. Here are issues I run into:
what would really helpMost of the time, I'd really like to be able to filter functions by type signature. So in this particular case, if I could say "list me all functions that take a |
Cool, you seem to already have a nice setup. I do get the types with merlin in vim and that's very helpful. |
Interesting. Are you (1) getting this during auto completion, where it shows the type signature of each potential completion or (2) getting this outside of auto completion, when cursor is over some identifier / expr ? I can achieve (2) via :MerlinTypeOf, but I can't figure out how to do (1). |
It turns out "Tensor." C-x C-o => names, but no types So now (1) also "works" for me. Thanks! |
In PyTorch, we can do:
Is there a corresponding function in OCaml-Torch? I don't see the corresponding function in Torch. or Torch.Tensor .
Thanks!
The text was updated successfully, but these errors were encountered: