Spaces:
Build error
Build error
Commit
·
b365ec9
1
Parent(s):
c48f075
updates
Browse files
app.py
CHANGED
|
@@ -27,7 +27,7 @@ gridsize=31
|
|
| 27 |
|
| 28 |
n_patches=961
|
| 29 |
|
| 30 |
-
pred=np.load('pred.npy')
|
| 31 |
pred_all=np.load('pred_all.npy').reshape(-1,64)
|
| 32 |
|
| 33 |
random_i=np.load('random.npy')
|
|
@@ -62,7 +62,7 @@ def find():
|
|
| 62 |
#st.write(point)
|
| 63 |
#st.write(pred_all[st.session_state["img"],point[0]*36+point[1]])
|
| 64 |
i=st.session_state["img"]
|
| 65 |
-
p=point[
|
| 66 |
diff=np.linalg.norm(pred_all[np.newaxis,i*n_patches+p,:]-pred_all,axis=-1)
|
| 67 |
#re_pred=pred_all.reshape(20,20,256,64)
|
| 68 |
#diff_re=diff.reshape((20,20,256)).argmin(axis=[])
|
|
|
|
| 27 |
|
| 28 |
n_patches=961
|
| 29 |
|
| 30 |
+
#pred=np.load('pred.npy')
|
| 31 |
pred_all=np.load('pred_all.npy').reshape(-1,64)
|
| 32 |
|
| 33 |
random_i=np.load('random.npy')
|
|
|
|
| 62 |
#st.write(point)
|
| 63 |
#st.write(pred_all[st.session_state["img"],point[0]*36+point[1]])
|
| 64 |
i=st.session_state["img"]
|
| 65 |
+
p=point[1]*gridsize+point[0]
|
| 66 |
diff=np.linalg.norm(pred_all[np.newaxis,i*n_patches+p,:]-pred_all,axis=-1)
|
| 67 |
#re_pred=pred_all.reshape(20,20,256,64)
|
| 68 |
#diff_re=diff.reshape((20,20,256)).argmin(axis=[])
|