@@ -36,7 +36,7 @@ def __init__(self, cfg, dataset, is_valid=False):
3636
3737 self .cfg = cfg
3838
39- assert cfg .preprocess .use_mel == False
39+ assert cfg .preprocess .use_mel is False
4040 if cfg .preprocess .use_mel :
4141 self .utt2melspec_path = {}
4242 for utt_info in self .metadata :
@@ -52,7 +52,7 @@ def __init__(self, cfg, dataset, is_valid=False):
5252 uid + ".npy" ,
5353 )
5454
55- assert cfg .preprocess .use_code == True
55+ assert cfg .preprocess .use_code is True
5656 if cfg .preprocess .use_code :
5757 self .utt2code_path = {}
5858 for utt_info in self .metadata :
@@ -68,7 +68,7 @@ def __init__(self, cfg, dataset, is_valid=False):
6868 uid + ".npy" ,
6969 )
7070
71- assert cfg .preprocess .use_spkid == True
71+ assert cfg .preprocess .use_spkid is True
7272 if cfg .preprocess .use_spkid :
7373 self .utt2spkid = {}
7474 for utt_info in self .metadata :
@@ -78,7 +78,7 @@ def __init__(self, cfg, dataset, is_valid=False):
7878
7979 self .utt2spkid [utt ] = utt_info ["speaker" ]
8080
81- assert cfg .preprocess .use_pitch == True
81+ assert cfg .preprocess .use_pitch is True
8282 if cfg .preprocess .use_pitch :
8383 self .utt2pitch_path = {}
8484 for utt_info in self .metadata :
@@ -94,7 +94,7 @@ def __init__(self, cfg, dataset, is_valid=False):
9494 uid + ".npy" ,
9595 )
9696
97- assert cfg .preprocess .use_duration == True
97+ assert cfg .preprocess .use_duration is True
9898 if cfg .preprocess .use_duration :
9999 self .utt2duration_path = {}
100100 for utt_info in self .metadata :
@@ -110,7 +110,7 @@ def __init__(self, cfg, dataset, is_valid=False):
110110 uid + ".npy" ,
111111 )
112112
113- assert cfg .preprocess .use_phone == True
113+ assert cfg .preprocess .use_phone is True
114114 if cfg .preprocess .use_phone :
115115 self .utt2phone = {}
116116 for utt_info in self .metadata :
@@ -120,7 +120,7 @@ def __init__(self, cfg, dataset, is_valid=False):
120120
121121 self .utt2phone [utt ] = utt_info ["phones" ]
122122
123- assert cfg .preprocess .use_len == True
123+ assert cfg .preprocess .use_len is True
124124 if cfg .preprocess .use_len :
125125 self .utt2len = {}
126126 for utt_info in self .metadata :
0 commit comments