robot-grasp-detection icon indicating copy to clipboard operation
robot-grasp-detection copied to clipboard

I want to know how much the last loss

Open HEUzhouhanwen opened this issue 7 years ago • 27 comments

Hello Run grab_det.py, after 10000 steps, the loss is stable at 30000-40000, and how much is the reasonable loss!

HEUzhouhanwen avatar Jan 03 '18 12:01 HEUzhouhanwen

Hi! I don't remember it now. Try evaluating the validation set. I could achieve a little more than 60 percent accuracy.

tnikolla avatar Jan 03 '18 14:01 tnikolla

Hello Try evaluating the validation set.I use ../robot-grasp-detection/models/grasp/m4/m4.ckpt, but the accuracy is about 30%, what is my problem? Thank you!

HEUzhouhanwen avatar Jan 05 '18 13:01 HEUzhouhanwen

How do you calculate the accuracy?

For every test example there are multiple ground truth rectangles (grasp positions) and only one rectangle predicted. The algorithm for evaluating if an example is a success, takes one random GT rectangle from the example and compares it with the predicted one. So you need to run the evaluation (grasp_det.py) multiple times so all the GT rectangles from one example are compared.

I did it like this: Run grasp_det.py the first time and note which example was a success, for example 1,3,6,8 from 10 were a success. Run it a second time and you will get a success for 0,1,3,6. Run it a third time and you get for example, 0,5,6. Accumulating the successes you get 0,1,3,5,6,8 from 10 examples (10 images with their annotated ground truth grasping positions). The accuracy is 6/10 = 60%.

You can code something to do this, instead of running the code manually lots of times and noting which was a success (I did it maybe 15 times).

Temporarly I'm unable to contribute to the repository because I lack a PC to do it. I am stuck with my old personal laptop.

tnikolla avatar Jan 05 '18 16:01 tnikolla

I see! Thank you!

HEUzhouhanwen avatar Jan 06 '18 03:01 HEUzhouhanwen

But I still don not understand why the loss is stable at 30000-40000!

HEUzhouhanwen avatar Jan 06 '18 03:01 HEUzhouhanwen

The algorithm finds one grasping position for every object (image) and this is not true in the dataset and also in the real life. Let's think about an image of a pencil (symmetry). pencil

When training, only one ground truth (red rectangle) is used in one pass (forward- and backprop, updating the weights). The ground truths lie in the text files of the dataset. there are a few for every image (theoretically this number is infinit) After training, the model has learned the average of all ground truths, the green rectangle. Continuing with training, with a batch size of 100 images, there will always be GTs that are far from the predicted rectangle. So, the RMS loss will move around some value.

Now, if we have again the a pencil-like image in the test set, the algorithem will predict a grasp. To find out if this predicted grasp is a success, it will be evaluated (two criterias) using only one random ground truth from the test set. So, if the first GT is randomly chosed, the predicted grasp is no success because of IoU; although we can see that this is a success for a real robot. The predicted grasp will not be a success for every GT except for the forth one where IoU and the angle meet the criteria.

What do you think?

tnikolla avatar Jan 13 '18 13:01 tnikolla

Thank you for your great answer! Very clear! Wonderful description! Shu Guo!&HEUzhouhanwen

xiaoshuguo750 avatar Jan 16 '18 07:01 xiaoshuguo750

When I run grasp_det.py, it seems the x_hat, h_hat, w_hat become NAN with only a few epochs. Is it reasonable and how to avoid that?

clvictory avatar Jan 28 '18 06:01 clvictory

There are some NAN mistakes in the files:

pcd0132cpos.txt pcd0165cpos.txt you can delete them!

At 2018-01-28 14:42:20, "Lu Chen" [email protected] wrote:

When I run grasp_det.py, it seems the x_hat, h_hat, w_hat become NAN with only a few epochs. Is it reasonable and how to avoid that?

— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or mute the thread.

xiaoshuguo750 avatar Jan 29 '18 01:01 xiaoshuguo750

@xiaoshuguo750

It works, thx!

clvictory avatar Jan 30 '18 02:01 clvictory

Are you Chinese?

在 2018-01-30 10:57:51,"Lu Chen" [email protected] 写道:

@xiaoshuguo750

It works, thx!

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.

xiaoshuguo750 avatar Jan 30 '18 03:01 xiaoshuguo750

@xiaoshuguo750

Yeah !

clvictory avatar Feb 01 '18 14:02 clvictory

同学你好 你现在还有在做抓取相关的么

woshisj avatar Apr 25 '18 13:04 woshisj

weixin:409067552

在 2018-04-25 21:25:24,"sujie" [email protected] 写道:

同学你好 你现在还有在做抓取相关的么

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.

xiaoshuguo750 avatar Apr 29 '18 14:04 xiaoshuguo750

weixin:409067552 在 2018-04-25 21:25:24,"sujie" [email protected] 写道: 同学你好 你现在还有在做抓取相关的么 — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.

同学你好!我现在正在做抓取相关的研究工作,你进展怎么样?我用该代码中已保存的模型测试了我自己的数据,但效果很不理想,然后我有去测试康奈尔抓取数据集中的数据,效果竟然同样很不理想,而且我不知道是什么原因,你测试的结果怎么样呢?

lx-onism avatar Oct 11 '18 03:10 lx-onism

But I still don not understand why the loss is stable at 30000-40000!

同学,我是做抓取新手。在开始阅读代码的时候,我对一步就很不理解,他说需要将imagenet数据转换为tfrecord,然后需要下imagenet的数据集。。。这里我很不理解,文章不是用的cornell grasping dataset,为什么需要下载imagenet数据集,主要是看到Imagenet数据集太大,学校网速太慢了,希望大佬能给解答一下,谢谢。。。

weiwuhuhu avatar Feb 15 '19 11:02 weiwuhuhu

看一下论文 V. EXPERIMENTS AND EVALUATION
C. Pretraining z

But I still don not understand why the loss is stable at 30000-40000!

同学,我是做抓取新手。在开始阅读代码的时候,我对一步就很不理解,他说需要将imagenet数据转换为tfrecord,然后需要下imagenet的数据集。。。这里我很不理解,文章不是用的cornell grasping dataset,为什么需要下载imagenet数据集,主要是看到Imagenet数据集太大,学校网速太慢了,希望大佬能给解答一下,谢谢。。。

woshisj avatar Feb 16 '19 01:02 woshisj

看一下论文 V. EXPERIMENTS AND EVALUATION C. Pretraining z

But I still don not understand why the loss is stable at 30000-40000!

同学,我是做抓取新手。在开始阅读代码的时候,我对一步就很不理解,他说需要将imagenet数据转换为tfrecord,然后需要下imagenet的数据集。。。这里我很不理解,文章不是用的cornell grasping dataset,为什么需要下载imagenet数据集,主要是看到Imagenet数据集太大,学校网速太慢了,希望大佬能给解答一下,谢谢。。。

您好,您给我推荐的论文我没查到。论文名称是:Experiment AND EVALUATION吗?方便加个好友吗

weiwuhuhu avatar Feb 16 '19 02:02 weiwuhuhu

就是这个代码的论文呀 论文名字是:Real-Time Grasp Detection Using Convolutional Neural Networks 第 V 章 C 节

看一下论文 V. EXPERIMENTS AND EVALUATION C. Pretraining z

But I still don not understand why the loss is stable at 30000-40000!

同学,我是做抓取新手。在开始阅读代码的时候,我对一步就很不理解,他说需要将imagenet数据转换为tfrecord,然后需要下imagenet的数据集。。。这里我很不理解,文章不是用的cornell grasping dataset,为什么需要下载imagenet数据集,主要是看到Imagenet数据集太大,学校网速太慢了,希望大佬能给解答一下,谢谢。。。

您好,您给我推荐的论文我没查到。论文名称是:Experiment AND EVALUATION吗?方便加个好友吗

woshisj avatar Feb 16 '19 02:02 woshisj

就是这个代码的论文呀 论文名字是:Real-Time Grasp Detection Using Convolutional Neural Networks 第 V 章 C 节

看一下论文 V. EXPERIMENTS AND EVALUATION C. Pretraining z

But I still don not understand why the loss is stable at 30000-40000!

同学,我是做抓取新手。在开始阅读代码的时候,我对一步就很不理解,他说需要将imagenet数据转换为tfrecord,然后需要下imagenet的数据集。。。这里我很不理解,文章不是用的cornell grasping dataset,为什么需要下载imagenet数据集,主要是看到Imagenet数据集太大,学校网速太慢了,希望大佬能给解答一下,谢谢。。。

您好,您给我推荐的论文我没查到。论文名称是:Experiment AND EVALUATION吗?方便加个好友吗

好的,我再仔细看看,您好,方便加个微信好友吗

weiwuhuhu avatar Feb 16 '19 02:02 weiwuhuhu

在这说吧,看到会回复你的

就是这个代码的论文呀 论文名字是:Real-Time Grasp Detection Using Convolutional Neural Networks 第 V 章 C 节

看一下论文 V. EXPERIMENTS AND EVALUATION C. Pretraining z

But I still don not understand why the loss is stable at 30000-40000!

同学,我是做抓取新手。在开始阅读代码的时候,我对一步就很不理解,他说需要将imagenet数据转换为tfrecord,然后需要下imagenet的数据集。。。这里我很不理解,文章不是用的cornell grasping dataset,为什么需要下载imagenet数据集,主要是看到Imagenet数据集太大,学校网速太慢了,希望大佬能给解答一下,谢谢。。。

您好,您给我推荐的论文我没查到。论文名称是:Experiment AND EVALUATION吗?方便加个好友吗

好的,我再仔细看看,您好,方便加个微信好友吗

woshisj avatar Feb 16 '19 02:02 woshisj

在这说吧,看到会回复你的

就是这个代码的论文呀 论文名字是:Real-Time Grasp Detection Using Convolutional Neural Networks 第 V 章 C 节

看一下论文 V. EXPERIMENTS AND EVALUATION C. Pretraining z

But I still don not understand why the loss is stable at 30000-40000!

同学,我是做抓取新手。在开始阅读代码的时候,我对一步就很不理解,他说需要将imagenet数据转换为tfrecord,然后需要下imagenet的数据集。。。这里我很不理解,文章不是用的cornell grasping dataset,为什么需要下载imagenet数据集,主要是看到Imagenet数据集太大,学校网速太慢了,希望大佬能给解答一下,谢谢。。。

您好,您给我推荐的论文我没查到。论文名称是:Experiment AND EVALUATION吗?方便加个好友吗

好的,我再仔细看看,您好,方便加个微信好友吗

所以得需要俩个数据集一个是生成抓取姿态的数据集 Cornell grasping dataset还有imagedataset,那个imagedataset数据集150个G都需要下载吗???

weiwuhuhu avatar Feb 16 '19 02:02 weiwuhuhu

But I still don not understand why the loss is stable at 30000-40000!

同学,我是做抓取新手。在开始阅读代码的时候,我对一步就很不理解,他说需要将imagenet数据转换为tfrecord,然后需要下imagenet的数据集。。。这里我很不理解,文章不是用的cornell grasping dataset,为什么需要下载imagenet数据集,主要是看到Imagenet数据集太大,学校网速太慢了,希望大佬能给解答一下,谢谢。。。

哥们,你现在抓取搞的怎么样了,方便留个邮箱吗?想交流一下。。

1458763783 avatar Jun 21 '20 13:06 1458763783

weihuhuhu同学,你的代码跑通了吗

woyuni avatar Nov 09 '20 09:11 woyuni

我没有在跑这个程序了,但是我也在做抓取策略生成,可以加微信交流18798824036

| | 贵州大学白强 | | [email protected] | 签名由网易邮箱大师定制 On 11/9/2020 17:20,2017301500326[email protected] wrote:

weihuhuhu同学,你的代码跑通了吗

— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.

1458763783 avatar Nov 11 '20 04:11 1458763783

Thank you for your great answer! Very clear! Wonderful description! Shu Guo!&HEUzhouhanwen

ValueError: Tensor conversion requested dtype int32 for Tensor with dtype float64: 'Tensor("truediv:0", shape=(), dtype=float64, device=/device:CPU:0)' How to solve the error when running the grasp_det.py?

zhoumo1121 avatar Jul 05 '21 12:07 zhoumo1121

在这说吧,看到会回复你的

就是这个代码的论文呀 论文名字是:Real-Time Grasp Detection Using Convolutional Neural Networks 第 V 章 C 节

看一下论文 V. EXPERIMENTS AND EVALUATION C. Pretraining z

But I still don not understand why the loss is stable at 30000-40000!

同学,我是做抓取新手。在开始阅读代码的时候,我对一步就很不理解,他说需要将imagenet数据转换为tfrecord,然后需要下imagenet的数据集。。。这里我很不理解,文章不是用的cornell grasping dataset,为什么需要下载imagenet数据集,主要是看到Imagenet数据集太大,学校网速太慢了,希望大佬能给解答一下,谢谢。。。

您好,您给我推荐的论文我没查到。论文名称是:Experiment AND EVALUATION吗?方便加个好友吗

好的,我再仔细看看,您好,方便加个微信好友吗

哥,我想请问一下,如果我要自己训练模型的话,数据集的照片要用RGB-D吗?还是说只要RBG就可以了?

Jonho111 avatar Jul 16 '21 08:07 Jonho111