KingNish commited on
Commit
27c2637
·
verified ·
1 Parent(s): 9c0d551

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -158,8 +158,8 @@ def generate_music(
158
  raw_output = None
159
 
160
  # Decoding config
161
- top_p = 0.9
162
- temperature = 0.9
163
  repetition_penalty = 1.2
164
  start_of_segment = mmtokenizer.tokenize('[start_of_segment]')
165
  end_of_segment = mmtokenizer.tokenize('[end_of_segment]')
@@ -220,7 +220,7 @@ def generate_music(
220
  logits_processor=LogitsProcessorList([BlockTokenRangeProcessor(0, 32002), BlockTokenRangeProcessor(32016, 32016)]),
221
  guidance_scale=guidance_scale,
222
  use_cache=True,
223
- num_beams=3
224
  )
225
  if output_seq[0][-1].item() != mmtokenizer.eoa:
226
  tensor_eoa = torch.as_tensor([[mmtokenizer.eoa]]).to(model.device)
 
158
  raw_output = None
159
 
160
  # Decoding config
161
+ top_p = 0.93
162
+ temperature = 1.0
163
  repetition_penalty = 1.2
164
  start_of_segment = mmtokenizer.tokenize('[start_of_segment]')
165
  end_of_segment = mmtokenizer.tokenize('[end_of_segment]')
 
220
  logits_processor=LogitsProcessorList([BlockTokenRangeProcessor(0, 32002), BlockTokenRangeProcessor(32016, 32016)]),
221
  guidance_scale=guidance_scale,
222
  use_cache=True,
223
+ num_beams=1
224
  )
225
  if output_seq[0][-1].item() != mmtokenizer.eoa:
226
  tensor_eoa = torch.as_tensor([[mmtokenizer.eoa]]).to(model.device)