hanna-xu / ddcgan Goto Github PK
View Code? Open in Web Editor NEWCode of DDcGAN for infrared and visible image fusion and medical image fusion
Code of DDcGAN for infrared and visible image fusion and medical image fusion
Hello, can you tell me how your data set was obtained from TNO, I want to use this data set to train my network, thank you very much!!!
How do I test a fusion image?
ir_batch[b, :, :] = scipy.ndimage.zoom(ir_or_batch[b, :, :], 0.25)
ir_batch[b, :, :] = scipy.ndimage.zoom(ir_or_batch[b, :, :], 0.25)
ValueError: could not broadcast input array from shape (0,21) into shape (21,21)
I want to retrain your model but I cant't find your dataset and I don't what is it.
Would you like to tell me, please?
ir_batch[b, :, :] = scipy.ndimage.zoom(ir_or_batch[b, :, :], 0.25)
ValueError: could not broadcast input array from shape (0,21) into shape (21,21)
执行的过程中报了这个错误。请问应该如何处理
hi, thank you for sharing the code!
I've noticed that in the muti-resolution fusion part, the resolution of the IR and VIS picture have to be fixed, which is 1:4 in your testing codes, to work out. I'm trying to change the resolution relationship by changing the multiple '4' in the following codes:
Generator.py line16
IR = deconv_ir(ir, strides = [1, 4, 4, 1], scope_name = 'deconv_ir')
Deconv.py line18-21
out = tf.nn.conv2d_transpose(out, filter = kernel, output_shape = [int(input_shape[0]), int(input_shape[1]) * 4,
int(input_shape[2]) * 4,
int(input_shape[3])],
strides = strides, padding = 'SAME')
It works out for 2, 4, 8 but fails on 3, 6, 9, mainly because of the resolution difference.
I wonder if there is a way to fuse arbitrary resolution IR and VIS pictures. Is there anything else which needs to be modified?
Hi!
First of all, thank you very much for sharing your code, it's a great job, congratulations!
I would like to train it with my own dataset. I've the image volumes in .nii format. Would be it possible?
Thank you very much in advance!
Dear hanna-xu,
I sincerely thank you for your code. Since I didn't find the metrics in your code ,I have looked for variable codes about PSNR. But I got the PSNR always approximately 29. I didn't kown why I got the results. Can you help me?
Your sincerely.
Jessis
My MRI/PET images are all 256x256 pixels. Are there any relevant documents to help me? thank you~
Hi, thank your for sharing your code. I met some problems when I run your model under the folder same-resolution vis-ir image fusion. I used your model to inference the images, there is the error:
NotFoundError (see above for traceback): Restoring from checkpoint failed. This is most likely due to a Variable name or other graph key that is missing from the checkpoint. Please ensure that you have not altered the graph expected based on the checkpoint. Original error:
Key Generator_1/decoder/conv2_5/bias not found in checkpoint
[[node save/RestoreV2 (defined at generate.py:38) ]]
I am confused . Could you help me? Thanks~
Hi!
It'd be great if tyou could add a dependency versions list.
Cannot reproduce results without creating the same environment.
First of all, thank you for sharing your code.In the code of the same-resolution vis-ir image fusion, I used your training datasets, test datasets and related parameters, but only a few pairs of the final test results could achieve the effect in your paper.A similar situation occurred after I directly used your model. How can I improve it?
自己训练为什么会出现G_loss: nan, D1_loss: nan, D2_loss: nan
这个代码只能使用一个GPU,运行速度很慢,怎么使用多个GPU来跑这个代码
I want to know how to solve this plblem.
raise ValueError("Can only save/restore ResourceVariables when
ValueEmror: Can only save/restore ResourceVariables when executing eagerly, got type: <class tensorflow.python,framework.ops .Tensor '>
作者您好,我想知道您的训练数据是否都是单通道的灰度图像?
对于我目前的工作,我想使用RGB的图像来进行训练是否可行?
感激不尽
What to do if you want to change a data set
What to do if you want to change a data set
如果要更改数据集该怎么办 用自己的数据集
Traceback (most recent call last):
File "/home/root3203/wanniny/code/DDcGAN-master/PET-MRI image fusion/main.py", line 57, in
main()
File "/home/root3203/wanniny/code/DDcGAN-master/PET-MRI image fusion/main.py", line 32, in main
train(sources, MODEL_SAVE_PATH, EPOCHES, BATCH_SIZE, logging_period=LOGGING)
File "/home/root3203/wanniny/code/DDcGAN-master/PET-MRI image fusion/train.py", line 200, in train
saver.save(sess, save_path + str(epoch) + '/' + str(epoch) + '.ckpt')
File "/home/root3203/anaconda3/envs/tf/lib/python3.6/site-packages/tensorflow/python/training/saver.py", line 1703, in save
{self.saver_def.filename_tensor_name: checkpoint_file})
File "/home/root3203/anaconda3/envs/tf/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 900, in run
run_metadata_ptr)
File "/home/root3203/anaconda3/envs/tf/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1058, in _run
raise RuntimeError('Attempted to use a closed Session.')
RuntimeError: Attempted to use a closed Session.
您好在跑完您的training后总是遇到这个错误请问怎么解决
I Can't sign up for Baidu.
vis-ir dataset (password:nh2r).
PET-MRI dataset (password: 5d9y).
Hello, author, thank you for sharing the source program. I have some questions for you. How do you make dataset Medical_dataset.h5? How are PET data and MRI data combined? I'm very confused about this. Can you help me? Thank you very much.
Dear Professor Xu,
At first place, I generally thanks for your code. When I run the code of MRI/PET , I could not get your results. And I always get the significantly lower results than your results. Could you tell me about how can I get your results?
Your sincerely.
Scarlett
I see the code in Generator is concat the two image which are both one channel only. Does it can be used for the fusion of RGB image and infrared image?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.