File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed
src/plugins/intel_cpu/src/transformations/cpu_opset/common/pass Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -226,7 +226,14 @@ CausalMaskPreprocess::CausalMaskPreprocess() {
226
226
ov::intel_cpu::CausalMaskPreprocessNode::Config config;
227
227
config.type = " CausalMaskPreprocess" ;
228
228
229
- auto triu = ov::as_type_ptr<ov::opset1::Constant>(pattern_map.find (const_triu)->second .get_node_shared_ptr ());
229
+ auto const_triu_it = pattern_map.find (const_triu);
230
+ if (const_triu_it == pattern_map.end ()) {
231
+ return false ;
232
+ }
233
+ auto triu = ov::as_type_ptr<ov::opset1::Constant>(const_triu_it->second .get_node_shared_ptr ());
234
+ if (!triu) {
235
+ return false ;
236
+ }
230
237
231
238
auto triu_shape = triu->get_output_shape (0 );
232
239
if (triu_shape.size () != 4 ) {
You can’t perform that action at this time.
0 commit comments