JMalott commited on
Commit
637070f
1 Parent(s): 0a49682

Update utils.py

Browse files
Files changed (1) hide show
  1. utils.py +8 -8
utils.py CHANGED
@@ -5,14 +5,14 @@ import streamlit as st
5
  import os
6
  import sys
7
  import argparse
8
- #import clip
9
  import numpy as np
10
  from PIL import Image
11
- #from dalle.models import Dalle
12
- #from dalle.utils.utils import set_seed, clip_score
13
  import streamlit.components.v1 as components
14
  import torch
15
- #from IPython.display import display
16
  import random
17
 
18
  def link(link, text, **style):
@@ -113,7 +113,7 @@ def generate2(prompt,crazy,k):
113
  dtype=torch.float32,
114
  device='cpu',
115
  is_mega=False,
116
- is_reusable=False
117
  )
118
 
119
  # Sampling
@@ -126,9 +126,9 @@ def generate2(prompt,crazy,k):
126
  seed=np.random.randint(0,10000),
127
  grid_size=1,
128
  is_seamless=False,
129
- temperature=1,
130
- top_k=256,#2128,
131
- supercondition_factor=1,
132
  is_verbose=False
133
  )
134
 
 
5
  import os
6
  import sys
7
  import argparse
8
+ import clip
9
  import numpy as np
10
  from PIL import Image
11
+ from dalle.models import Dalle
12
+ from dalle.utils.utils import set_seed, clip_score
13
  import streamlit.components.v1 as components
14
  import torch
15
+ from IPython.display import display
16
  import random
17
 
18
  def link(link, text, **style):
 
113
  dtype=torch.float32,
114
  device='cpu',
115
  is_mega=False,
116
+ is_reusable=True
117
  )
118
 
119
  # Sampling
 
126
  seed=np.random.randint(0,10000),
127
  grid_size=1,
128
  is_seamless=False,
129
+ temperature=crazy,
130
+ top_k=k,#2128,
131
+ supercondition_factor=32,
132
  is_verbose=False
133
  )
134