huyanxin / DeepComplexCRN

Apache License 2.0
398 stars 97 forks source link

While studying, I'd like to reproduce your code. Please could you help #9

Open jiminbot20 opened 3 years ago

jiminbot20 commented 3 years ago

In dc_crn.py inputs and labels are random tensor. How could I process sample wav files? Is it right to change line 305 at dc_crn.py into some kind of wav file read such as sf.read('./noreverb_fileid_6.wav')[0] in conv_stft.py?

Also, I am confuse to put which data should be used in 'labels' in line 306 in dc_crn.py. I'm trying to apply 'ICASSP_blind_test_set' in 'DNS-Challenge' https://github.com/microsoft/DNS-Challenge/tree/master/datasets/ICASSP_blind_test_set

In addition, is there any pretrained model that I could reproduce exactly same result of yours?

It would be pleasure if you help me.

Rodolfo-S commented 3 years ago

I'm not the author but the way I did it was I used the recipe scripts in the asteroid project as a guide to preprocessing data and setting up a DataLoader. Look in egs/dns_challenge/baseline/run.sh They have scripts from downloading the dataset to pre-processing to running the model. They use their version of the model in the asteroid package but you can substitute this version.

jiminbot20 commented 3 years ago

I'm not the author but the way I did it was I used the recipe scripts in the asteroid project as a guide to preprocessing data and setting up a DataLoader. Look in egs/dns_challenge/baseline/run.sh They have scripts from downloading the dataset to pre-processing to running the model. They use their version of the model in the asteroid package but you can substitute this version.

Thanks. I will try. Is it fine to ask more question while I stuck in problem running the code?

Rodolfo-S commented 3 years ago

Sure. If I can answer it and the author can't get to it, I'll try to help.

jiminbot20 commented 3 years ago

Sure. If I can answer it and the author can't get to it, I'll try to help.

currently I finished run 'run.sh' in asteroid/dns-challenge/baseline to train baseline. And now I'm stuck applying DCCRN to asteroid code. Is it right to change model.py in asteroid to _dccrn.py in DCCRN?

Rodolfo-S commented 3 years ago

That's basically what I do. I run each "stage" manually, without a "run.sh" script but I do run my own "train.py" script (based on the baseline version) that runs "_dccrn.py". I also have a modified version of "conf.yml" that includes the correct parameters for the model under "masknet".

jiminbot20 commented 3 years ago

That's basically what I do. I run each "stage" manually, without a "run.sh" script but I do run my own "train.py" script (based on the baseline version) that runs "_dccrn.py". I also have a modified version of "conf.yml" that includes the correct parameters for the model under "masknet".

According to asteroid, stage 2 is train. so you mean, for example, if I want to train, with modified own train.py run stage 2?

By the way, where the 'masknet' came from?

Rodolfo-S commented 3 years ago

if I want to train, with modified own train.py run stage 2?

Yes. You can use the baseline train.py as a template.

where the 'masknet' came from?

'masknet' is a group of parameters in the "local/conf.yml" file. In train.py those parameters are passed as kwargs to the model on instantiation. The baseline version of conf.yml has baseline specific parameters so you're going to want to make a new _confDCCRN.yml file with the appropriated 'masknet' parameters for the _dccrn model.

jiminbot20 commented 3 years ago

if I want to train, with modified own train.py run stage 2?

Yes. You can use the baseline train.py as a template.

where the 'masknet' came from?

'masknet' is a group of parameters in the "local/conf.yml" file. In train.py those parameters are passed as kwargs to the model on instantiation. The baseline version of conf.yml has baseline specific parameters so you're going to want to make a new _confDCCRN.yml file with the appropriated 'masknet' parameters for the _dccrn model.

Thank you. Your replies are huge help to me. I will keep working on it.

XuWink commented 10 months ago

Hello, I am currently learning speech enhancement and want to train the DCCRN model. I see that you have already done this work. Can you share the code with me? Thanks.

Esther2j commented 2 months ago

Hello, I am currently learning speech enhancement and want to train the DCCRN model. I see that you have already done this work. Can you share the code with me? Thanks.你好,我目前正在学习语音增强,想要训练DCCRN模型。我看到你已经完成了这项工作。你能与我分享代码吗?谢谢。

Hello, I am also learning voice enhancement at present. I know from your comments that we have the same needs. Could you share the DCCRN-related code you obtained with me? Look forward to your reply, thank you!