File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -504,6 +504,13 @@ static void write_mean(MEX_ARGS) {
504504 mxFree (mean_proto_file);
505505}
506506
507+ // Usage: caffe_('version')
508+ static void version (MEX_ARGS ) {
509+ mxCHECK (nrhs == 0 , " Usage: caffe_('version')" );
510+ // Return version string
511+ plhs[0 ] = mxCreateString (AS_STRING (CAFFE_VERSION ));
512+ }
513+
507514/* * -----------------------------------------------------------------
508515 ** Available commands.
509516 **/
@@ -542,6 +549,7 @@ static handler_registry handlers[] = {
542549 { " reset" , reset },
543550 { " read_mean" , read_mean },
544551 { " write_mean" , write_mean },
552+ { " version" , version },
545553 // The end.
546554 { " END" , NULL },
547555};
Original file line number Diff line number Diff line change 1+ function version_str = version()
2+ % version()
3+ % show Caffe's version.
4+
5+ version_str = caffe_(' version' );
6+
7+ end
You can’t perform that action at this time.
0 commit comments