Open wux12 opened 2 years ago
try to change gpu_ids: 0 to -1
try to change gpu_ids: 0 to -1
from .yml
Hi there! I bump into the same issue while using Colab and GPU to run this. May I know if your issue got resolved?
Same issue. Running on ubuntu on ec2 with nvidia t4 gpu.
Changing value of gpu_ids from 0 to -1 in argument.yml does not work for me.
Works fine on colab with older cuda setup.
running on device 0 0%| | 0/1 [00:00<?, ?it/s]Current Source ==> moon Running depth extraction at 1646976096.6373248 BoostingMonocularDepth/inputs/.jpg device: cuda Namespace(Final=True, R0=False, R20=False, colorize_results=False, data_dir='inputs/', depthNet=0, max_res=inf, net_receptive_field_size=None, output_dir='outputs', output_resolution=1, pix2pixsize=1024, savepatchs=0, savewholeest=0) ----------------- Options --------------- Final: True [default: False] R0: False
run(dataset , option_)
File "run.py", line 126, in run
option.pix2pixsize, option.depthNet)
File "run.py", line 389, in doubleestimate
estimate1 = singleestimate(img, size1, net_type)
File "run.py", line 418, in singleestimate
return estimatemidas(img, msize)
File "run.py", line 475, in estimatemidas
prediction = midasmodel.forward(sample)
File "/home/w/3d-photo-inpainting/BoostingMonocularDepth/midas/models/midas_net.py", line 59, in forward
layer_1 = self.pretrained.layer1(x)
File "/home/w/anaconda3/envs/3DP/lib/python3.7/site-packages/torch/nn/modules/module.py", line 532, in call
result = self.forward(input, *kwargs)
File "/home/w/anaconda3/envs/3DP/lib/python3.7/site-packages/torch/nn/modules/container.py", line 100, in forward
input = module(input)
File "/home/w/anaconda3/envs/3DP/lib/python3.7/site-packages/torch/nn/modules/module.py", line 532, in call
result = self.forward(input, kwargs)
File "/home/w/anaconda3/envs/3DP/lib/python3.7/site-packages/torch/nn/modules/activation.py", line 94, in forward
return F.relu(input, inplace=self.inplace)
File "/home/w/anaconda3/envs/3DP/lib/python3.7/site-packages/torch/nn/functional.py", line 912, in relu
result = torch.relu_(input)
RuntimeError: CUDA error: no kernel image is available for execution on the device
0%| | 0/1 [10:02<?, ?it/s]
Traceback (most recent call last):
File "main.py", line 54, in
run_boostmonodepth(sample['ref_img_fi'], config['src_folder'], config['depth_folder'])
File "/home/w/3d-photo-inpainting/boostmonodepth_utils.py", line 41, in run_boostmonodepth
depth = imageio.imread(os.path.join(BOOST_BASE, BOOST_OUTPUTS, tgt_name))
File "/home/w/anaconda3/envs/3DP/lib/python3.7/site-packages/imageio/core/functions.py", line 265, in imread
reader = read(uri, format, "i", kwargs)
File "/home/w/anaconda3/envs/3DP/lib/python3.7/site-packages/imageio/core/functions.py", line 172, in get_reader
request = Request(uri, "r" + mode, **kwargs)
File "/home/w/anaconda3/envs/3DP/lib/python3.7/site-packages/imageio/core/request.py", line 124, in init
self._parse_uri(uri)
File "/home/w/anaconda3/envs/3DP/lib/python3.7/site-packages/imageio/core/request.py", line 260, in _parse_uri
raise FileNotFoundError("No such file: '%s'" % fn)
FileNotFoundError: No such file: '/home/w/3d-photo-inpainting/BoostingMonocularDepth/outputs/moon.png'
R20: False
aspect_ratio: 1.0
batch_size: 1
checkpoints_dir: ./pix2pix/checkpoints
colorize_results: False
crop_size: 672
data_dir: inputs/ [default: None] dataroot: None
dataset_mode: depthmerge
depthNet: 0 [default: None] direction: AtoB
display_winsize: 256
epoch: latest
eval: False
generatevideo: None
gpu_ids: 0
init_gain: 0.02
init_type: normal
input_nc: 2
isTrain: False [default: None] load_iter: 0 [default: 0] load_size: 672
max_dataset_size: 10000
max_res: inf
model: pix2pix4depth
n_layers_D: 3
name: void
ndf: 64
netD: basic
netG: unet_1024
net_receptive_field_size: None
ngf: 64
no_dropout: False
no_flip: False
norm: none
num_test: 50
num_threads: 4
output_dir: outputs [default: None] output_nc: 1
output_resolution: None
phase: test
pix2pixsize: None
preprocess: resize_and_crop
savecrops: None
savewholeest: None
serial_batches: False
suffix:
verbose: False
----------------- End ------------------- initialize network with normal loading the model from ./pix2pix/checkpoints/mergemodel/latest_net_G.pth Loading weights: midas/model.pt Using cache found in /home/w/.cache/torch/hub/facebookresearch_WSL-Imagesmain start processing processing image 0 : moon wholeImage being processed in : 2112 Traceback (most recent call last): File "run.py", line 580, in