@@ -43,9 +43,9 @@ Result<uint64_t> MultimodalPrefiller::prefill(
4343 Image image = input.get_image ();
4444
4545 auto method_meta = ET_UNWRAP (
46- module_->method_meta (kImageEncoderMethod ),
46+ module_->method_meta (kVisionEncoderMethod ),
4747 " Failed to get method_meta for %s" ,
48- kImageEncoderMethod );
48+ kVisionEncoderMethod );
4949
5050 ET_CHECK_MSG (
5151 method_meta.num_inputs () > 0 ,
@@ -80,7 +80,7 @@ Result<uint64_t> MultimodalPrefiller::prefill(
8080
8181 // Run image encoder
8282 auto image_encoder_outputs =
83- ET_UNWRAP (module_->execute (kImageEncoderMethod , image_tensor));
83+ ET_UNWRAP (module_->execute (kVisionEncoderMethod , image_tensor));
8484
8585 encoder_output = image_encoder_outputs[0 ];
8686 } else if (input.is_audio ()) {
@@ -175,8 +175,8 @@ ::executorch::runtime::Error MultimodalPrefiller::load() {
175175 ET_UNWRAP (module_->method_names (), " Failed to get method names" );
176176
177177 // Load image_encoder method if exists.
178- if (methods.find (kImageEncoderMethod ) != methods.end ()) {
179- ET_CHECK_OK_OR_RETURN_ERROR (module_->load_method (kImageEncoderMethod ));
178+ if (methods.find (kVisionEncoderMethod ) != methods.end ()) {
179+ ET_CHECK_OK_OR_RETURN_ERROR (module_->load_method (kVisionEncoderMethod ));
180180 }
181181
182182 if (methods.find (kAudioEncoderMethod ) != methods.end ()) {
@@ -203,8 +203,8 @@ bool MultimodalPrefiller::is_method_loaded() {
203203 ET_CHECK_MSG (false , " Failed to get method names" );
204204 }
205205 std::unordered_set<std::string> methods = methods_res.get ();
206- if (methods.find (kImageEncoderMethod ) != methods.end ()) {
207- return module_->is_method_loaded (kImageEncoderMethod );
206+ if (methods.find (kVisionEncoderMethod ) != methods.end ()) {
207+ return module_->is_method_loaded (kVisionEncoderMethod );
208208 }
209209 return true ;
210210}
0 commit comments