Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dataset #56

Closed
geshihuazhong opened this issue Jan 23, 2021 · 19 comments
Closed

dataset #56

geshihuazhong opened this issue Jan 23, 2021 · 19 comments

Comments

@geshihuazhong
Copy link

Hello, I was just wondering, what dataset are you using for your pre-trained model?I'm currently training with Adobe Matting datasets, but I'm not getting the results I want.

@ZHKKKe
Copy link
Owner

ZHKKKe commented Jan 25, 2021

Hi, thanks for your attention.

We use the Supervisely human segmentation dataset for pretraining.

@geshihuazhong
Copy link
Author

@ZHKKKe
HI, Thank you for your answer.
Is it this dataset? https://supervise.ly/explore/projects/supervisely-person-dataset-23304/datasets

I notice that this is a segmentation dataset, and it only provides Matting (0 or 1) information, Unlike typical Matting DataSets, such as Adobe Matting DataSets, which provide alpha (0-255) channels.That is to say, the edge of the image is not detailed, then how to predict the edge details?

@ZHKKKe
Copy link
Owner

ZHKKKe commented Jan 28, 2021

Sorry for misunderstanding. In my response, pretraining refers to pre-training the LR-Branch of MODNet by a human segmentation dataset.
For your question, we trained MODNet on our own labeled portrait matting dataset, which will not be released (sorry for this). Another recent work, Background Matting V2, seems to be releasing their labeled portrait matting dataset. Maybe you can pay attention to it.

@geshihuazhong
Copy link
Author

发现可以说中文(⊙.⊙),thanks, 谢谢你的回答
另外我还有几个问题想了解一下,
1、你们这个不开放的数据集,大概有多少张。
2、预训练好LR-Branch后,训练后面的细节处理时,会冻结LR-Branch的参数吗?如果不冻结参数不会被破坏吗?
3、训练图片的尺寸是固定的吗?我看到推理时,只是把图像短边设置为512,长边自适应。如果训练尺寸是固定的,为什么不采用训练尺寸,自适应不会使得训练和测试的数据集分布不同。

@ZHKKKe
Copy link
Owner

ZHKKKe commented Feb 1, 2021

@geshihuazhong

  1. 数据集中前景大概3000张
  2. 不会的。预训练用的是人像分割数据集。
  3. 训练时候我们使用512x512的输入。我们发现使用固定尺寸输入训练的模型可以适应不同分辨率的测试图片。

@lblbk
Copy link

lblbk commented Feb 2, 2021

Hi, thanks for your attention.

We use the Supervisely human segmentation dataset for pretraining.

那是不是可以先训练 backboneLR-Branch 分支,冻结这两个分支后再训练后面两个分支,我用这种方式训练发现效果会好一点,但是后面两个分支loss很难下降,除了改变损失函数的权重以外还有其他方式吗
另外我一直怀疑我们数据集有问题,所以想问你一下你们大概一共用了多少张训练

@ZHKKKe
Copy link
Owner

ZHKKKe commented Feb 2, 2021

@lblbk

我们在使用matting数据集训练后面两个分支时,不冻结backboneLR-Branch的实验获得了更好结果,这可能和使用的matting数据集有关。
我们的matting训练集包含3000个前景,对于每个前景,我们使用20个背景图片来合成训练样本。

@geshihuazhong
Copy link
Author

@geshihuazhong

  1. 数据集中前景大概3000张
  2. 不会的。预训练用的是人像分割数据集。
  3. 训练时候我们使用512x512的输入。我们发现使用固定尺寸输入训练的模型可以适应不同分辨率的测试图片。

3、我也试过,模型确实可以适应不同的尺寸。但是我训练过程中,是用512512的尺寸来做测试的,并且是以测试集的loss来保存模型的。最终发现还是以512512的尺寸效果,测试集的loss更小,验证集效果会更好一些。 不知道你们这边是否做过这样的试验?确实自适应尺寸的loss、或者其他评估指标(MSE,SAD....)更小。

@moiling
Copy link

moiling commented Feb 2, 2021

@geshihuazhong

  1. 数据集中前景大概3000张
  2. 不会的。预训练用的是人像分割数据集。
  3. 训练时候我们使用512x512的输入。我们发现使用固定尺寸输入训练的模型可以适应不同分辨率的测试图片。

3、我也试过,模型确实可以适应不同的尺寸。但是我训练过程中,是用512_512的尺寸来做测试的,并且是以测试集的loss来保存模型的。最终发现还是以512_512的尺寸效果,测试集的loss更小,验证集效果会更好一些。 不知道你们这边是否做过这样的试验?确实自适应尺寸的loss、或者其他评估指标(MSE,SAD....)更小。

+1

@ZHKKKe
Copy link
Owner

ZHKKKe commented Feb 2, 2021

@geshihuazhong 抱歉,我们目前没有对此进行进一步的实验。

@rose-jinyang
Copy link

Hi @ZHKKKe
Could u please provide a few samples of your training data and the full scripts for training?
Thanks

@ZHKKKe
Copy link
Owner

ZHKKKe commented Feb 19, 2021

@rose-jinyang
Sorry for late response.
The full scripts for training may be provided when this work is accepted by a conference or a journal.

@fanrupin
Copy link

fanrupin commented Apr 7, 2021

@lblbk

我们在使用matting数据集训练后面两个分支时,不冻结backboneLR-Branch的实验获得了更好结果,这可能和使用的matting数据集有关。
我们的matting训练集包含3000个前景,对于每个前景,我们使用20个背景图片来合成训练样本。

3000个前景,是人工标注边缘后通过传统算法得到的吗?还是现有matting数据集?

@ZHKKKe
Copy link
Owner

ZHKKKe commented Apr 9, 2021

@fanrupin
你好,是使用PS精细标注的matting前景数据集。

@huang5656151
Copy link

@ZHKKKe 请问一下用前景和背景合成的时候是用GAN么?还是用了其他方法

@fanrupin
Copy link

fanrupin commented Apr 9, 2021

 多谢,那通过ps的得到的是alpha 0-255的label吗?训练是用的alpha label,还是二值化的label呢?

@ZHKKKe
Copy link
Owner

ZHKKKe commented Apr 9, 2021

@huang5656151
前景和背景合成用的是matting的基本公式
@fanrupin
训练时候用的是归一化到[0, 1]的alpha label

@huang5656151
Copy link

@ZHKKKe Hi, I wan to ask how to get the alpha images of foreground images, I know the foreground images is get by PS. Thax!

@ZHKKKe
Copy link
Owner

ZHKKKe commented May 9, 2021

@huang5656151
You may can find many tutorials from YouTube.
We just follow and improve one of the tutorials.

@ZHKKKe ZHKKKe closed this as completed Jun 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants