wiusdy commited on
Commit
fc0c2dc
1 Parent(s): 24eb62a

solving the model choice bug

Browse files
Files changed (1) hide show
  1. inference.py +3 -3
inference.py CHANGED
@@ -16,11 +16,11 @@ class Inference:
16
 
17
  def inference(self, selected, image, text):
18
  self.logger.info(f"selected model {selected}")
19
- if selected == "Model 1":
20
  return self.__inference_vilt(image, text)
21
- elif selected == "Model 2":
22
  return self.__inference_saffal_blip(image, text)
23
- elif selected == "Model 3":
24
  return self.__inference_control_net_blip(image, text)
25
  else:
26
  self.logger.warning("Please select a model to make the inference..")
 
16
 
17
  def inference(self, selected, image, text):
18
  self.logger.info(f"selected model {selected}")
19
+ if selected == "ViLT":
20
  return self.__inference_vilt(image, text)
21
+ elif selected == "Blip Saffal":
22
  return self.__inference_saffal_blip(image, text)
23
+ elif selected == "Blip CN":
24
  return self.__inference_control_net_blip(image, text)
25
  else:
26
  self.logger.warning("Please select a model to make the inference..")