PrakhAI commited on
Commit
a3fbe0f
·
1 Parent(s): c7ef840

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -3
app.py CHANGED
@@ -5,9 +5,12 @@ from flax.serialization import msgpack_restore, from_state_dict
5
  fs = HfFileSystem()
6
 
7
  with fs.open("PrakhAI/HelloWorld/checkpoint.msgpack", "rb") as f:
8
- state_dict = msgpack_restore(f.read())
9
- print(state_dict)
10
- print(state_dict.keys())
 
 
 
11
 
12
  x = st.slider('Select a value')
13
  st.write(x, 'squared is', x * x)
 
5
  fs = HfFileSystem()
6
 
7
  with fs.open("PrakhAI/HelloWorld/checkpoint.msgpack", "rb") as f:
8
+ state = msgpack_restore(f.read())
9
+
10
+ print(type(state))
11
+
12
+ # logits = state.apply_fn({'params': state.params}, batch['image'])
13
+ # print(logits)
14
 
15
  x = st.slider('Select a value')
16
  st.write(x, 'squared is', x * x)