gmastrapas tomaarsen HF staff commited on
Commit
c8d5eac
1 Parent(s): dbc4a34

Add `save_in_root` to the custom Module to allow saving & loading locally (#17)

Browse files

- Add `save_in_root` to the custom Module to allow saving & loading locally (d901c3c1918acb56f0dbbe68ec35b34960057045)


Co-authored-by: Tom Aarsen <[email protected]>

Files changed (1) hide show
  1. custom_st.py +3 -0
custom_st.py CHANGED
@@ -12,6 +12,9 @@ from transformers import AutoConfig, AutoImageProcessor, AutoModel, AutoTokenize
12
 
13
 
14
  class Transformer(nn.Module):
 
 
 
15
  def __init__(
16
  self,
17
  model_name_or_path: str = 'jinaai/jina-clip-v2',
 
12
 
13
 
14
  class Transformer(nn.Module):
15
+
16
+ save_in_root: bool = True
17
+
18
  def __init__(
19
  self,
20
  model_name_or_path: str = 'jinaai/jina-clip-v2',