Created
September 29, 2018 22:41
-
-
Save goldsborough/265a13be401578611d56a9cd4cdf12f6 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- Old-style factory functions that accept a type as first argument and size as second argument have been removed. New-style factory functions accepting the size as first argument and [`TensorOptions`](https://github.com/pytorch/pytorch/blob/master/aten/src/ATen/core/TensorOptions.h#L14) as last argument should be used instead. For example, replace your call e.g. to `at::ones(torch::CPU(at::kFloat)), {2, 3})` with `torch::ones({2, 3}, at::kCPU)`. This applies to the following functions: | |
- `arange` | |
- `empty` | |
- `eye` | |
- `full` | |
- `linspace` | |
- `logspace` | |
- `ones` | |
- `rand` | |
- `randint` | |
- `randn` | |
- `randperm` | |
- `range` | |
- `zeros` | |
We have [improved online documentation](https://pytorch.org/cppdocs) of our C++ APIs. Authors of C++ extensions may want to consult this documentation when writing new extensions. | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment