This fixes Apex build issues with older PyTorch versions 1.8.1, 1.9 and 1.10, since they didn't have the ATen/cuda/CUDAGeneratorImpl.h file available.
15:05:31 [0m[91m In file included from /tmp/pip-req-build-sttueip5/apex/contrib/csrc/multihead_attn/additive_masked_softmax_dropout_hip.hip:15:
15:05:31 /tmp/pip-req-build-sttueip5/apex/contrib/csrc/multihead_attn/dropout_hip.h:8:10: fatal error: 'ATen/hip/HIPGeneratorImpl.h' file not found
15:05:31 #include <ATen/hip/HIPGeneratorImpl.h>
This fixes Apex build issues with older PyTorch versions 1.8.1, 1.9 and 1.10, since they didn't have the
ATen/cuda/CUDAGeneratorImpl.h
file available.