fix a small bug in computer_13 action space
This commit is contained in:
@@ -144,7 +144,7 @@ class PythonController:
|
||||
return
|
||||
|
||||
action_type = action["action_type"]
|
||||
parameters = action["parameters"] if "parameters" in action else {}
|
||||
parameters = action["parameters"] if "parameters" in action else {param: action[param] for param in action if param != 'action_type'}
|
||||
move_mode = random.choice(
|
||||
["pyautogui.easeInQuad", "pyautogui.easeOutQuad", "pyautogui.easeInOutQuad", "pyautogui.easeInBounce",
|
||||
"pyautogui.easeInElastic"])
|
||||
|
||||
@@ -236,7 +236,7 @@ class DesktopEnv(gym.Env):
|
||||
info = {}
|
||||
|
||||
# handle the special actions
|
||||
if action in ['WAIT', 'FAIL', 'DONE']:
|
||||
if action in ['WAIT', 'FAIL', 'DONE'] or (type(action) == dict and action['action_type'] in ['WAIT', 'FAIL', 'DONE']):
|
||||
if action == 'WAIT':
|
||||
time.sleep(pause)
|
||||
elif action == 'FAIL':
|
||||
|
||||
Reference in New Issue
Block a user