ritwikraha commited on
Commit
2fd8016
·
1 Parent(s): da848cd
Files changed (1) hide show
  1. app.py +16 -11
app.py CHANGED
@@ -246,21 +246,26 @@ def show_rendered_image(r,theta,phi):
246
  # app.py text matter starts here
247
  st.title('NeRF:Neural Radiance Fields')
248
  # set the values of r theta phi
249
- r = 4.0
250
- theta = st.slider('Enter a value for theta',min_value = 0.0,max_value = 360.0)
251
- phi = -30.0
252
 
253
 
254
- color,depth = show_rendered_image(r,theta,phi)
255
- color = tf.keras.utils.array_to_img(color)
256
- #depth = tf.keras.utils.array_to_img(depth)
257
 
258
- # fig, ax = plt.subplots()
259
- # im = ax.imshow(color)
260
- # st.pyplot(fig)
261
 
262
- st.image(color, caption = "Color",clamp = True, width = 1000)
263
- #st.image(depth, caption = "Depth",clamp = True, width = 200)
 
 
 
 
 
 
 
 
 
 
 
 
 
 
264
 
265
 
266
 
 
246
  # app.py text matter starts here
247
  st.title('NeRF:Neural Radiance Fields')
248
  # set the values of r theta phi
 
 
 
249
 
250
 
 
 
 
251
 
 
 
 
252
 
253
+ col1, col2= st.columns([1,6])
254
+
255
+ with col1:
256
+ r = 4.0
257
+ theta = st.slider('Enter a value for theta',min_value = 0.0,max_value = 360.0)
258
+ phi = -30.0
259
+
260
+
261
+ with col2:
262
+ color,depth = show_rendered_image(r,theta,phi)
263
+ color = tf.keras.utils.array_to_img(color)
264
+ #depth = tf.keras.utils.array_to_img(depth)
265
+
266
+ st.image(color, caption = "Color",clamp = True, width = 600)
267
+ #st.image(depth, caption = "Depth",clamp = True, width = 200)
268
+
269
 
270
 
271