How to do skull stripping of PET imaging in FSL

Hi, I am doing preprocessing the PET data in FSL, but I have some problem.
When I used the code

bet2 $inoutdata $outputdata -f 0.5 -g 0 -m 

It shows the error message

/usr/local/fsl/bin/bet: line 399: 365162 Segmentation fault      (core dumped) ${FSLDIR}/bin/bet2 $IN $OUT $bet2opts
/usr/local/fsl/bin/bet failed during command: $input  $output -f 0.5 -g 0 -m

How can I fix them?
FYI, it is the head information for imaging

sizeof_hdr	348
data_type	FLOAT64
dim0		3
dim1		256
dim2		256
dim3		256
dim4		1
dim5		1
dim6		1
dim7		1
vox_units	mm
time_units	s
datatype	64
nbyper		8
bitpix		64
pixdim0		1.000000
pixdim1		1.000000
pixdim2		1.000000
pixdim3		1.000000
pixdim4		1.000000
pixdim5		0.000000
pixdim6		0.000000
pixdim7		0.000000
vox_offset	352

This question is not related to MRtrix. Please seek help at https://www.jiscmail.ac.uk/cgi-bin/webadmin?A0=fsl