pytorch/test/cpp
Prem 7557407653 Added directory check before saving in C++ API
Fixes #75177

Couldn't find any utility method to get directory name in pytorch repo, hence creating a function for that.
Let me know if a new function is not needed.

I also referred [this](https://github.com/pytorch/pytorch/blob/master/c10/test/util/tempfile_test.cpp#L15) for directory check.

Also I am using TORCH_CHECK to show the error. This is highly verbose with the entire stack visible. Is there any alternative for the same so that it is easier to read? This could happen a frequently, so small and concise error would be more helpful here.
Pull Request resolved: https://github.com/pytorch/pytorch/pull/75681
Approved by: https://github.com/albanD
2022-04-22 20:04:41 +00:00
..
api Extend jit::load to work on flatbuffer file; Take 2 (#75256) 2022-04-06 17:54:01 +00:00
c10d Add cuda-11.3+clang9 build workflow (take 2) 2022-04-11 17:13:01 +00:00
common
dist_autograd Fix distributed autograd gradients synchronization (#57792) 2021-05-09 17:32:59 -07:00
jit Added directory check before saving in C++ API 2022-04-22 20:04:41 +00:00
lazy Decouple Lazy Node Shape Cache (#75324) 2022-04-21 17:27:05 -07:00
lite_interpreter_runtime [PyTorch] Add codegen unboxing ability (#69881) 2022-03-01 23:28:13 +00:00
monitor torch/monitor: merge Interval and FixedCount stats (#72009) 2022-01-30 23:21:59 +00:00
profiler [RecordFunction] More effecient machinery to determine which callbacks to run. (#75807) 2022-04-19 20:46:16 +00:00
rpc Remove ProcessGroup from TensorPipeAgent initialization (#68128) 2021-11-11 12:28:55 -08:00
tensorexpr [NNC] Add utility functions to check channels-last contiguous (#75938) 2022-04-22 06:42:39 -07:00
__init__.py