Yntec commited on
Commit
b621661
โ€ข
1 Parent(s): eef378b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -51,11 +51,11 @@ def noadd_random_noise(prompt, noise_level=0.00):
51
  num_noise_chars = int(len(prompt) * (percentage_noise/100))
52
  noise_indices = random.sample(range(len(prompt)), num_noise_chars)
53
  prompt_list = list(prompt)
54
- noise_chars = list(string.ascii_letters + string.punctuation + ' ' + string.digits)
55
- noise_chars.extend(['๐Ÿ˜', 'beautiful', '๐Ÿ˜‚', '๐Ÿค”', '๐Ÿ˜Š', '๐Ÿค—', '๐Ÿ˜ญ', '๐Ÿ™„', 'pretty', '๐Ÿคฏ', '๐Ÿคซ', '๐Ÿฅด', 'sitting', '๐Ÿคฉ', '๐Ÿฅณ', '๐Ÿ˜”', '๐Ÿ˜ฉ', '๐Ÿคช', '๐Ÿ˜‡', 'retro', '๐Ÿ˜ˆ', '๐Ÿ‘น', 'masterpiece', '๐Ÿค–', '๐Ÿ‘ฝ', 'high quality', '๐ŸŽƒ', '๐ŸŽ…', '๐ŸŽ„', '๐ŸŽ', '๐ŸŽ‚', '๐ŸŽ‰', '๐ŸŽˆ', '๐ŸŽŠ', '๐ŸŽฎ', 'โค๏ธ', '๐Ÿ’”', '๐Ÿ’•', '๐Ÿ’–', '๐Ÿ’—', '๐Ÿถ', '๐Ÿฑ', 'visible', '๐Ÿน', '๐ŸฆŠ', '๐Ÿป', '๐Ÿจ', '๐Ÿฏ', '๐Ÿฆ', '๐Ÿ˜', '๐Ÿ”ฅ', '๐ŸŒง๏ธ', '๐ŸŒž', '๐ŸŒˆ', '๐Ÿ’ฅ', '๐ŸŒด', '๐ŸŒŠ', '๐ŸŒบ', '๐ŸŒป', '๐ŸŒธ', '๐ŸŽจ', '๐ŸŒ…', '๐ŸŒŒ', 'โ˜๏ธ', 'โ›ˆ๏ธ', 'โ„๏ธ', 'โ˜€๏ธ', '๐ŸŒค๏ธ', 'โ›…๏ธ', '๐ŸŒฅ๏ธ', '๐ŸŒฆ๏ธ', '๐ŸŒง๏ธ', '๐ŸŒฉ๏ธ', '๐ŸŒจ๏ธ', '๐ŸŒซ๏ธ', 'โ˜”๏ธ', '๐ŸŒฌ๏ธ', '๐Ÿ’จ', '๐ŸŒช๏ธ', 'beautiful'])
56
  for index in noise_indices:
57
  prompt_list[index] = random.choice(noise_chars)
58
- return ""
59
 
60
  def send_it1(inputs, noise_level, proc1=proc1):
61
  prompt_with_noise = noadd_random_noise(inputs, noise_level)
 
51
  num_noise_chars = int(len(prompt) * (percentage_noise/100))
52
  noise_indices = random.sample(range(len(prompt)), num_noise_chars)
53
  prompt_list = list(prompt)
54
+ noise_chars = list(string.ascii_letters + string.punctuation + '' + string.digits)
55
+ noise_chars.extend([''])
56
  for index in noise_indices:
57
  prompt_list[index] = random.choice(noise_chars)
58
+ return "".join(prompt_list)
59
 
60
  def send_it1(inputs, noise_level, proc1=proc1):
61
  prompt_with_noise = noadd_random_noise(inputs, noise_level)