reast cancer is a fatal disease that originates in breast tissue. The disease could affect the majority of women, although men may also be affected. According to the American Cancer Society, almost one in nine women is estimated to develop breast cancer. Hence, mammograms have been introduced as one of the best tools to diagnose the disease at an early stage. The mortality rate of breast cancer can be reduced by early diagnosis and treatment. The computer-aided diagnostic systems help expert physicians to identify the early-stage of breast cancer by mammograms. The function of these computer diagnostic systems generally consists of four main stages including preprocessing, extraction of a region of interest (ROI), features extraction and classification. Although many diagnosis methods are introduced so far, the problem of diagnosing breast cancer automatically by using computers has remained as a challenge due to the complexity of the breast tissue that makes the mass difficult to separate from other dense regions of the breast tissue. Moreover, sometimes, the size of the disorder is too small to be seen by experts. Therefore, considering the great importance of the existence of an automatic diagnostic system for breast cancer, we represent two methods for detecting breast cancer in this study. The first method is based on discriminative dictionary learning on DSIFT descriptors and the second method is based on deep convolutional neural network (CNN). The pre-processing stage consists of extracting breast tissue, removing muscle from the breast and improving the contrast of the mammograms. Then DSIFT feature is represented as a sparse coding in a dictionary-based method. The sparse representations of DSIFT Descriptors are given to the dictionary and linear classifier to learn simultaneously according to the LC-KSVD algorithm. After training the dictionary and the linear classifier, they would be used in order to classify test images. In the second proposed method, which is based on the CNN, after the preprocessing phase, a number of normal and abnormal blocks of the mammography images are extracted and inputted to the network. After training CNN, the obtained weights and biases, in the network, would be used at the test stage. In the end, with the aim of improving the accuracy Keywords: Diagnosis system, breast cancer, mammography, dictionary, sparse coding, deep learning.