Commit 3c696932 authored by wooway777's avatar wooway777
Browse files

issue/216 - Fixed Enum Camparison in util.py

parent 125afeb5
...@@ -477,7 +477,7 @@ def get_test_devices(args): ...@@ -477,7 +477,7 @@ def get_test_devices(args):
def get_sync_func(device): def get_sync_func(device):
import torch import torch
if device == "cpu": if device == InfiniDeviceEnum.CPU:
sync = None sync = None
else: else:
sync = getattr(torch, infiniDeviceEnum_str_map[device]).synchronize sync = getattr(torch, infiniDeviceEnum_str_map[device]).synchronize
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment