py-torch: set INTEL_MKL_DIR (#29613)
Add the INTEL_MKL_DIR variable so py-torch can find mkl if provided by intel-oneapi-mkl.
This commit is contained in:
parent
d349677dcb
commit
c6b69a8244
1 changed files with 5 additions and 0 deletions
|
@ -360,6 +360,11 @@ def enable_or_disable(variant, keyword='USE', var=None, newer=False):
|
|||
'intel-mkl', 'intel-parallel-studio', 'intel-oneapi-mkl']:
|
||||
env.set('BLAS', 'MKL')
|
||||
env.set('WITH_BLAS', 'mkl')
|
||||
# help find MKL
|
||||
if self.spec['mkl'].name == 'intel-oneapi-mkl':
|
||||
env.set('INTEL_MKL_DIR', self.spec['mkl'].prefix.mkl.latest)
|
||||
else:
|
||||
env.set('INTEL_MKL_DIR', self.spec['mkl'].prefix.mkl)
|
||||
elif self.spec['blas'].name == 'openblas':
|
||||
env.set('BLAS', 'OpenBLAS')
|
||||
env.set('WITH_BLAS', 'open')
|
||||
|
|
Loading…
Reference in a new issue