Closed zzzkk2009 closed 6 years ago
求教,你是怎么编译flownet2-pytorch的
@ding-hai
follow this issue https://github.com/NVIDIA/flownet2-pytorch/issues/75
pytorch use 0.2.0 version
@zzzkk2009 only pytorch >= 0.4 is supported now. You can try removing the 'track_running_stats' option, but my guess is there will be other problems too.
@tcwang0509
thanks your advise.
i use pytorch 0.2.0 compile flownet2-pytorch, and then upgrade pytorch to 0.4, not removing the 'track_running_stats' option, i run ./scripts/test_2048.sh, got another error like below:
Doing 28 frames
ERROR: Unexpected bus error encountered in worker. This might be caused by insufficient shared memory (shm).
Traceback (most recent call last):
File "test.py", line 43, in
RuntimeError: DataLoader worker (pid 77) is killed by signal: Bus error. Details are lost due to multiprocessing. Rerunning with num_workers=0 may give better error trace.
for this error, i add --shm-size 8G options when i run docker, and solved my problem.
but then i got another problem like below:
Doing 28 frames ./scripts/test_2048.sh: line 1: 56 Segmentation fault (core dumped) python test.py --name label2city_2048 --dataroot datasets/Cityscapes/test_A --loadSize 2048 --n_scales_spatial 3 --use_instance --fg --use_single_G
@zzzkk2009 I recommit the same error as you.now my error is same as yours.
who can save me ?
@ding-hai TypeError: init() got an unexpected keyword argument 'track_running_stats' this error can solved by upgrade pytorch to >=0.4
I have compiled flownet2 with cuda 9 + Python 3.5 + pytorch 0.3 by running
python scripts/download_flownet2.py
Then I updated to pytorch 0.4.1 and run
python test.py --name label2city_1024_g1 --loadSize 1024 --n_scales_spatial 3 --use_instance --fg --n_downsample_G 2 --use_single_G
I then get the following output:
Doing 560 frames
Segmentation fault (core dumped)
Does anybody know what causes this?
what is the version of python when you compile flownet2-pytorch, Python2 + pytorch0.2 or python3 + pytorch0.4.1 I checkout to python36 branch and compile with python3 + pytorch0.4.1 .And I run ''python3 test.py --name label2city_2048 --loadSize 2048 --n_scales_spatial 3 --use_instance --fg --use_single_G I still got the error 'TypeError: init() got an unexpected keyword argument 'track_running_stats'' Can you leave a wechat or qq number for me? thx
@zzzkk2009 now the error is
Doing 560 frames
Segmentation fault (core dumped)
@ding-hai I updated my comment.
@ding-hai @maxjaritz i have same error with yours.
@zzzkk2009 @maxjaritz maybe we should make a new issue for 'Segmentation fault (core dumped)'.
@ding-hai
OK
i have installed this repo in nvidia docker env with: cuda8.0, cudnn6.0, miniconda with python3.6 virtualenv, pytorch0.2.0
when i run ./scripts/test_2048.sh this shell, i got beblow error:
------------ Options ------------- aspect_ratio: 1.0 batchSize: 1 checkpoints_dir: ./checkpoints dataroot: datasets/Cityscapes/ dataset_mode: temporal debug: False display_id: 0 display_winsize: 512 feat_num: 3 fg: True fg_labels: [26] fineSize: 512 gpu_ids: [0] how_many: 300 input_nc: 3 isTrain: False label_feat: False label_nc: 35 loadSize: 2048 load_features: False load_pretrain: max_dataset_size: inf model: vid2vid nThreads: 2 n_blocks: 9 n_blocks_local: 3 n_downsample_E: 3 n_downsample_G: 3 n_frames_G: 3 n_gpus_gen: 1 n_local_enhancers: 1 n_scales_spatial: 3 name: label2city_2048 ndf: 64 nef: 32 netE: simple netG: composite ngf: 128 no_first_img: False no_flip: False norm: batch ntest: inf output_nc: 3 phase: test resize_or_crop: scaleWidth results_dir: ./results/ serial_batches: False tf_log: False use_instance: True use_real_img: False use_single_G: True which_epoch: latest -------------- End ---------------- CustomDatasetDataLoader dataset [TestDataset] was created vid2vid ---------- Networks initialized -------------
Traceback (most recent call last): File "test.py", line 24, in
model = create_model(opt)
File "/vid2vid/models/models.py", line 19, in create_model
modelG.initialize(opt)
File "/vid2vid/models/vid2vid_model_G.py", line 51, in initialize
self.netG_i = self.load_single_G() if self.use_single_G else None
File "/vid2vid/models/vid2vid_model_G.py", line 270, in load_single_G
netG = networks.define_G(input_nc, opt.output_nc, 0, 32, 'local', 4, 'instance', 0, self.gpu_ids, opt)
File "/vid2vid/models/networks.py", line 39, in define_G
netG = LocalEnhancer(input_nc, output_nc, ngf, n_downsampling, opt.n_blocks, opt.n_local_enhancers, opt.n_blocks_local, norm_layer)
File "/vid2vid/models/networks.py", line 320, in init
model_global = GlobalGenerator(input_nc, output_nc, ngf_global, n_downsample_global, n_blocks_global, norm_layer).model
File "/vid2vid/models/networks.py", line 286, in init
model = [nn.ReflectionPad2d(3), nn.Conv2d(input_nc, ngf, kernel_size=7, padding=0), norm_layer(ngf), activation]
TypeError: init() got an unexpected keyword argument 'track_running_stats'
(py3) root@0d93b7e85c1e:/vid2vid#
can anyone tell me how to solve it.
thks!