- 🧐 Interested in Artificial Intelligence.
- 🎓 Graduated from East China Normal University with degree of M. S. in computer science.
- 📚 Like Games. Wants to be an Indie Game Developer
Take a look at my repositories and let's get in touch!
A Simple U-net model for Retinal Blood Vessel Segmentation based on tensorflow2
Take a look at my repositories and let's get in touch!
Hi:
I want to try your model with my own image. But I don't have mask or result for my own image and the code didn't run well. How should I fix this?
Traceback (most recent call last):
File "main_test.py", line 40, in
main_test()
File "main_test.py", line 34, in main_test
drawCurve(gtlist,[problist],modelName,'DRIVE',config.checkpoint)
File "/home/mir/project/Retina-VesselNet/perception/metric/segmention_metric.py", line 209, in drawCurve
(FPR, TPR, AUC), (Precision, Recall, MAP),IoU = process.statistics()
File "/home/mir/project/Retina-VesselNet/perception/metric/segmention_metric.py", line 38, in statistics
assert(len(self.groundtruth)==len(self.probgraph))
AssertionError
could anyone tell me why would this happen and how to solve it? thx a lot!
I see “You can find model parameter in configs/segmention_config.json.“ in readme, but I can't find in your repo to reproduce experiment.
leftover_h = (img_h - config.patch_height) % config.stride_height # leftover on the h dim
leftover_w = (img_w - config.patch_width) % config.stride_width # leftover on the w dim
full_imgs=None
if (leftover_h != 0): #change dimension of img_h
tmp_imgs = np.zeros((imgs.shape[0],img_h+(config.stride_height-leftover_h),img_w,imgs.shape[3]))
tmp_imgs[0:imgs.shape[0],0:img_h,0:img_w,0:imgs.shape[3]] = imgs
full_imgs = tmp_imgs
if (leftover_w != 0): #change dimension of img_w
tmp_imgs = np.zeros((full_imgs.shape[0],full_imgs.shape[1],img_w+(config.stride_width - leftover_w),full_imgs.shape[3]))
tmp_imgs[0:imgs.shape[0],0:imgs.shape[1],0:img_w,0:full_imgs.shape[3]] =imgs
full_imgs = tmp_imgs
print("new full images shape: \n" +str(full_imgs.shape))
return full_imgs
我的数据集是256*256的,计算下来leftover_h和leftover_w都是0,所以full_imgs直接等于none了。我添加了一个if判断,问题解决了。
if(leftover_h==leftover_w==0):
full_imgs=imgs
Hello,
I was trying to test this model out on multiple images instead of just one and I wanted to know how that would be possible since when I currently have more than one image in the test/origin directory, the test results end up getting overwritten. Any help would be greatly appreciated.
Thanks,
Aditya
Hi, I noticed in your algorithm you didn't calculate the metrics within the FOV of the masks provided by the DRIVE dataset. Do you know what your results will be if you used them?
Could you please specify the dependencies of your model?
Thank you!
from bunch import Bunch
error is No module named bunch
I cannot find content about bunch ,wolud you tell me how you learn this bunch,thanks
hi
i use your environment but have some problems
Traceback (most recent call last):
File "main_train.py", line 54, in
main_train()
File "main_train.py", line 35, in main_train
dataloader.prepare_dataset()
File "/home/air/Desktop/BioHiLab/Retina-VesselNet/experiments/data_loaders/standard_loader.py", line 72, in prepare_dataset
imgs_train, groundTruth=self._access_dataset(self.train_img_path,self.train_groundtruth_path,self.train_type)
File "/home/air/Desktop/BioHiLab/Retina-VesselNet/experiments/data_loaders/standard_loader.py", line 63, in _access_dataset
assert (np.max(groundTruth) == 255)
File "/home/air/anaconda3/lib/python3.6/site-packages/numpy/core/fromnumeric.py", line 2320, in amax
out=out, **kwargs)
File "/home/air/anaconda3/lib/python3.6/site-packages/numpy/core/_methods.py", line 26, in _amax
return umr_maximum(a, axis, None, out, keepdims)
ValueError: zero-size array to reduction operation maximum which has no identity
Hi!
I tried to test this code on GPU but it gives value error.
The program runs perfectly fine on CPU but takes a lot of time(as it is expected).
I am adding the screenshot of the error
I am using tensorflow 1.12 and keras 2.2.4
Also please see this link for a potential guidence.
Also , i request you to mention which version of tensorflow and keras did you use.
Thank you.
I'm getting the following error when i'm running main_test.py
tempfile.tif: Cannot read TIFF header.
Traceback (most recent call last):
File "main_test.py", line 41, in
main_test()
File "main_test.py", line 29, in main_test
infer.predict()
File "C:\Users\Venkat M\Downloads\Retina-VesselNet-master\Retina-VesselNet-master\perception\infers\segmention_infer.py", line 33, in predict
orgImg=[orgImg_temp[:,:,1]*0.75]+[orgImg_temp[:,:,0]*0.25]
IndexError: too many indices for array
这个是基于FCN的吧?那在建模的最后为什么要reshape成(None,9216, 2)呢?为什么不直接输出图片?
既然是逐像素分类,像素的标签是在数据集中已经标好了还是在代码中标注的?代码里没看到。
训练过程划分patch是随机划分的,还是每张图片划分出500个patch?
I was looking at your dense_unet model, the input shape is (patch_width, patch_height, 1), so it is channel-last ordering, but then the batch normalization is done on axis=1, which corresponds to channel-first ordering. Is this a bug or did I miss something?
Hello there.
Sorry for bothering you but I ran into this error which stated that it cannot find the image file directory but for some reason after the "ground truth" it added an extra directory "origin" which I find odd because it should not be as so.
Is there a way to fix this problem? because I already revised all the pathing it should be correct. Thank you in advance.
你好,非常感谢大佬提供的如此整洁的代码。但是我在复现这个结果的时候,只能在验证集上达到95%左右的结果,用的是默认的参数配置,patch_size 是96*96,我想知道我该怎样设置参数才能达到98.4%左右的结果呢?
您好,我这边之前给您主页上留的邮箱发了一封邮件,希望能使用您的代码在我的课题上面,并且如果有论文发表,我这边将会给您挂作者,不知道您这边同不同意。希望能得到您的答复。
我直接运行的测试代码,但是并没有显示测试结果指标。请问在哪里显示呢?
就是我下载你的代码和数据集,没有改动任何地方,训练准确率仅达到88%左右,然后跑的测试程序,预测结果没有出来与(VesselNet)/test/result一样的效果,可以说非常差,大神能看看是什么问题吗
I know this function is from orobix's retina-unet repo, but they don't seem to actively maintain that repo now. This function first does Z normalization and then rescale the image back to [0, 255], which is equivalent to just scale the image to [0, 255]? Should the mean and std be calculated only along the batch axis?
This message comes up when running main_training.py
I don't understand where this error is coming from as I cannot find where we are actually looking for a file 'emanual1.tif'.
Did someone run in the same issue?
Hello, I want to use other pictures of fixed size for training. Is it ok? Is there any requirement on the ratio of height to width?Want to change the parameters there?thank youMy email is [email protected]
就是我下载你的代码和数据集,没有改动任何地方,训练准确率仅达到88%左右,然后跑的测试程序,预测结果没有出来与(VesselNet)/test/result一样的效果,可以说非常差,大神能看看是什么问题吗
I am having an issue with the ROC curve and PR graph. Their values are not very good. I tried predefined models as well as trained myself using the data you provided. And more the output images are not good.
Help me if I am doing anything wrong.
I am working on Colab using GPU.
Help me how can I achieve more accuracy.
您好,我运行了main_train.py,但是 出现了这个错误,请问有遇到这个问题的吗?
hello, thank you very much for sharing the great work.
I wonder why you used 40 images instead of 20 images(originally given for training).
what if we use only 20 images for training?
thank you in advance.
where is segmention_config.json? It is not in your files
Hi,
I tried your pretrained model, and re-trained the model my myself, but the final AUC is only about 0.71. Can you check what caused the difference?
Thanks
老哥你是**人吧,直接中文了,我想问这么多层的网络,你用的什么配置,训练了多久,跟u-net训练时间比起来怎么样
It would be helpful for people knowing what are the conditions for using your code.
I downloaded your code, and tested images.It runs!But one image took 2900s,I think it's too slow.Is there any other method?
This message comes up when running main_training.py
I don't understand where this error is coming from as I cannot find where we are actually looking for a file 'emanual1.tif'.
Did someone run in the same issue?
您好,我看了你的项目,觉得非常有意思,现在想用你的模型训练自己的数据,但是在读取图片的时候出现了以下提示,想请教一下。
standerd_loader.py
imgs[index,:,:,0]=np.asarray(orgImg[:,:,1]*0.75+orgImg[:,:,0]*0.25)
IndexError: too many indices for array
想请教一下 imgs[index,:,:,0]=np.asarray(orgImg[:,:,1]*0.75+orgImg[:,:,0]*0.25) 这段代码的目的是什么呢?
i want to train on my own image database other than DRIVE .
AUC = np.round(np.sum((TPR[1:] + TPR[:-1]) * (FPR[:-1] - FPR[1:])) / 2., 4)这里为什么要这样计算啊
Hi Xing ChenCong
Previously big thanks for the good code! I have questions what kind of server / compute you use to achieve the train and test result? And how long it takes?
Thanks
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.