Prevent Matlab on OS X from crashing on error

Replace CHECK() and LOG(FATAL) with LOG(ERROR) and mexErrMsgTxt

A failed CHECK() or LOG(FATAL) causes Matlab to crash on OS X 10.9 with Matlab 2014a.
Add command to get number of network inputs
Error on wrong number of arguments
Update comments
Merge pull request #4 from CellScope/matcaffe-num-inputs

Matcaffe num inputs