RohitGandikota commited on
Commit
4f7b85a
β€’
1 Parent(s): 2fc9d25

fixing training

Browse files
Files changed (2) hide show
  1. app.py +1 -1
  2. trainscripts/textsliders/demotrain.py +2 -0
app.py CHANGED
@@ -233,7 +233,7 @@ class Demo:
233
  positive_prompt = ''
234
  if negative_prompt is None:
235
  negative_prompt = ''
236
-
237
 
238
  randn = torch.randint(1, 10000000, (1,)).item()
239
  save_name = f"{randn}_{target_concept.replace(',','').replace(' ','').replace('.','')[:10]}_{positive_prompt.replace(',','').replace(' ','').replace('.','')[:10]}"
 
233
  positive_prompt = ''
234
  if negative_prompt is None:
235
  negative_prompt = ''
236
+ print(target_concept, positive_prompt, negative_prompt, attributes_input, is_person)
237
 
238
  randn = torch.randint(1, 10000000, (1,)).item()
239
  save_name = f"{randn}_{target_concept.replace(',','').replace(' ','').replace('.','')[:10]}_{positive_prompt.replace(',','').replace(' ','').replace('.','')[:10]}"
trainscripts/textsliders/demotrain.py CHANGED
@@ -423,6 +423,8 @@ def train_xl(target, postive, negative, lr, iterations, config_file, rank, devic
423
  if attributes is not None:
424
  attributes = attributes.split(',')
425
  attributes = [a.strip() for a in attributes]
 
 
426
  config.network.alpha = 1.0
427
  config.network.rank = rank
428
 
 
423
  if attributes is not None:
424
  attributes = attributes.split(',')
425
  attributes = [a.strip() for a in attributes]
426
+ else:
427
+ attributes = []
428
  config.network.alpha = 1.0
429
  config.network.rank = rank
430