Skip to content
Snippets Groups Projects
Commit dc6df644 authored by xArthur's avatar xArthur
Browse files

fix path error when executing from cmd.

parent 81e6e103
No related branches found
No related tags found
No related merge requests found
......@@ -20,7 +20,7 @@ double_dqn = True # If using double dqn algorithm
input_channels = 5 # Number of Input channels
device = torch.device("cuda:0" if torch.cuda.is_available() else "cpu")
device = torch.device("cpu")
#device = torch.device("cpu")
print(device)
......
......@@ -4,6 +4,11 @@ import random
import sys
from collections import deque
# make sure the root path is in system path
from pathlib import Path
base_dir = Path(__file__).resolve().parent.parent
sys.path.append(str(base_dir))
import matplotlib.pyplot as plt
import numpy as np
import torch
......
......@@ -3,6 +3,11 @@ import random
import sys
from collections import deque
# make sure the root path is in system path
from pathlib import Path
base_dir = Path(__file__).resolve().parent.parent
sys.path.append(str(base_dir))
import matplotlib.pyplot as plt
import numpy as np
import torch
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment