check dimension