fixed jit default setting (#154)

This commit is contained in:
Frank Lee
2022-01-18 13:37:20 +08:00
committed by GitHub
parent a1da3900c8
commit f3802d6b06
2 changed files with 7 additions and 4 deletions

View File

@@ -3,8 +3,11 @@ import torch
JIT_OPTIONS_SET = False
def _set_jit_fusion_options():
"""Set PyTorch JIT layer fusion options."""
def set_jit_fusion_options():
"""Set PyTorch JIT layer fusion options.
"""
# LSG: the latest pytorch and CUDA versions may not support
# the following jit settings
global JIT_OPTIONS_SET
if JIT_OPTIONS_SET == False:
# flags required to enable jit fusion kernels