diff --git a/ppcls/static/train.py b/ppcls/static/train.py index 14eb661ed..ad1d92915 100755 --- a/ppcls/static/train.py +++ b/ppcls/static/train.py @@ -94,7 +94,7 @@ def main(args): use_mlu = global_config.get("use_mlu", False) use_ascend = global_config.get("use_ascend", False) assert ( - use_gpu and use_xpu and use_npu and use_mlu and use_ascend + use_gpu + use_xpu + use_npu + use_mlu + use_ascend <= 1 ) is not True, "gpu, xpu, npu, mlu and ascend can not be true in the same time in static mode!" if use_gpu: