• Dmytro Dzhulgakov's avatar
    Lightweight at-most-once logging for API usage (#20745) · c25e3378
    Dmytro Dzhulgakov 提交于
    Summary:
    Resubmit #20698 which got messed up.
    
    Idea is that when PyTorch is used in a custom build environment (e.g. Facebook), it's useful to track usage of various APIs centrally. This PR introduces a simple very lightweight mechanism to do so - only first invocation of a trigger point would be logged. This is significantly more lightweight than #18235 and thus we can allow to put logging in e.g. TensorImpl.
    
    Also adds an initial list of trigger points. Trigger points are added in such a way that no static initialization triggers them, i.e. just linking with libtorch.so will not cause any logging. Further suggestions of what to log are welcomed.
    Pull Request resolved: https://github.com/pytorch/pytorch/pull/20745
    
    Differential Revision: D15429196
    
    Pulled By: dzhulgakov
    
    fbshipit-source-id: a5e41a709a65b7ebccc6b95f93854e583cf20aca
    c25e3378
名称
最后提交
最后更新
..
bench_gen Loading commit data...
CMakeLists.txt Loading commit data...
benchmark_args.h Loading commit data...
benchmark_helper.cc Loading commit data...
benchmark_helper.h Loading commit data...
caffe2_benchmark.cc Loading commit data...
convert_and_benchmark.cc Loading commit data...
convert_caffe_image_db.cc Loading commit data...
convert_db.cc Loading commit data...
convert_encoded_to_raw_leveldb.cc Loading commit data...
convert_image_to_tensor.cc Loading commit data...
core_overhead_benchmark.cc Loading commit data...
core_overhead_benchmark_gpu.cc Loading commit data...
db_throughput.cc Loading commit data...
inspect_gpu.cc Loading commit data...
make_cifar_db.cc Loading commit data...
make_image_db.cc Loading commit data...
make_mnist_db.cc Loading commit data...
parallel_info.cc Loading commit data...
predictor_verifier.cc Loading commit data...
print_core_object_sizes_gpu.cc Loading commit data...
print_registered_core_operators.cc Loading commit data...
run_plan.cc Loading commit data...
run_plan_mpi.cc Loading commit data...
speed_benchmark.cc Loading commit data...
split_db.cc Loading commit data...
tsv_2_proto.cc Loading commit data...
tutorial_blob.cc Loading commit data...
zmq_feeder.cc Loading commit data...