當我在64位Matlab中運行此代碼時,它顯示'此函數只能在MS Windows或Linux下運行'。如何在64位linux機器上運行32位matlab?
% Call the binary executable
fpath = fileparts(which(mfilename));
if strncmp(computer,'PC',2) % MS Windows
exec_str = ['"' fpath '/xcv_segment.exe"'];
elseif strcmp(computer,'GLNX86') % Linux
exec_str = [fpath '/xcv_segment'];
else error('This function can run only with MS Windows or Linux');
end
由於這個原因,我試圖安裝lib-32來安裝glnx86。
sudo -i
cd /etc/apt/sources.list.d
echo "deb http://old-releases.ubuntu.com/ubuntu/ raring main restricted universe multiverse" >ia32-libs-raring.list
apt-get update
apt-get install ia32-libs
然後,我運行這個命令來安裝32位MATLAB:./install -glnx86
此安裝完成後,我運行相同的代碼。然而,它仍然繼續使用相同的消息:'This function can run only with MS Windows or Linux'.
但是,我試圖只運行'fpath = fileparts(which(mfilename)); exec_str = [fpath'/ xcv_segment']; '它說'拒絕權限'。 –