{'fraction_non_alphanumeric': 0.021379116766467067, 'fraction_numerical': 0.00533308383233533, 'mean_word_length': 4.796366594360086, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 1, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Intelligent System for Skin Disease Prediction using Machine Learning

Skin is an extraordinary human structure. It frequently suffered from many known and unknown disease. Therefore, diagnosis of human skin diseases is the most uncertain and complicated branch of science. It has been observed that most of the cases remain unnoticed because of the lack of better medical infrastructure and facilities. This paper is devoted to solve this challenge. Therefore, this paper effectively proposed (CNN-SVM-MAA) system which combines Convolutional Neural Network with Support Vector Machine classifier to develop a Mobile Android Application. Thus, to evaluate the performance of the proposed system several experiments are conducted on our dataset. This dataset consists around 3000 images which collected from a lot of sources like Beni-Suef University Hospital, Cairo University Hospital and various websites as well to be more accurate and realistic. A comparative study of applying different Feature extraction algorithms with different classifiers was accomplished. The results obtained showed the adequacy of the proposed (CNN-SVM-MAA) system how many skin diseases images have been detected from skin disease dataset. Which lead to detect skin disease and provide the user with the disease name and treatment related prescription with high accuracy.


Introduction
Skin Disease are occurring almost on all groups of ages among people. The rate of skin disease has been increased due to lifestyle and changing environments [1] [21]. In the USA country, it is observed that every one out of five people are infected with any kind of skin disease [22]. They are usually caused by factors like different organism's cells, a different diet, and internal and external factors, such as the hierarchical genetic group of cells, hormones, and immune system of conditions. These factors may act together or in a sequence of skin disease. There are chronic and incurable diseases, like eczema and psoriasis, and malignant diseases like malignant melanoma. Recent researchers have found the availability of cures for these diseases if they are detected in the early stages [3] [23].
From the literature survey, authors of this paper found that, the creation of an expert application of skin disease detection using methods like Naive Bayes, CNN, SVM methods was felt to be very necessary to help all people who want to know about skin diseases that are being experienced or need information about skin diseases [24]. To detect these diseases using the image processing method many research papers has been published and many researchers has contributed a lot which paved a way for our application and gave us a right direction. Without the previous works of these fellow researchers my work on developing any application would never have been easier [5] [6]. Skin diseases are often quite hard to detect at an early stage and it is even harder to classify them separately. Recently, it is well known that, the most dangerous form of skin cancer among the other types of skin cancer is melanoma because it is much more likely to spread to other parts of the body if not diagnosed and treated early. In order to classify these skin diseases, "Support Vector Machine (SVM)" a Machine Learning Algorithm can be used Image classification is one of classical problems of concern in image processing. Support Vector Machine are classified under supervised learning models and is a part of machine learning algorithm which used to analyze structured and unstructured data such as text and images. As an input SVM always requires clean data. In skin disease detection, classifying the images into different types of skin diseases is the problem. This paper gives us the complete overview on existing machine learning and image processing algorithms for detection of skin disease through android application development. It makes use of skin disease dataset for the analysis. From the literature review, it is found that CNN and SVM are the most suitable algorithm for skin disease detections. The methodology is formed and android application is developed. As a part of results, the number of input disease to number of detected diseases are found out for every type of skin disease. The sample skin disease images are shown in figure 1.

Figure 1 : Sample Skin Disease images [25]
In these papers we have used image processing OpenCV along with machine learning algorithms to identify these diseases. We have worked with CNN, SVM and Statistical analysis to detect these diseases. The proposed application is like a combination to detection and suggest for medical treatment.
We have trained our model using more than 3000 images of various kind of skin diseases from Dermanet. We have created a test model on around 800 images of similar kind from the same website. Around 2.3 billion android devices are used around the world which is 1/3 rd of the total world population. Which makes it a most reachable application. Also, sometimes even the dermatologist finds it difficult to identify the disease in its early stages. Using our application helps him to get at least an idea of the possible disease which might be possible. The application also provides the doctor with a dashboard to remotely manage its patient and can identify the disease of a patient at a remote location. Our work is described in the methodology section which gives a glimpse of how we detect the skin disease. Also, we have described the various algorithms and methodologies The organization of the paper is as follows: Section II has a literature survey wherein existing research work and proposed algorithms have been listed out. Section III has methodology in which block diagram, research question and problem definition are being formed. Section IV has android application screenshots and processing steps, section V has results, Section VI concludes the study.

Literature Review
As we mentioned earlier, there are several papers which are proposed on image-processing based detection of skin diseases. We have reviewed the various techniques mentioned in the literature.
In [1] Arifin, S., Kibria, Firoza, A. Amini & Yan H at el. "Dermatologist Disease Diagnosis using color-skin images", has proposed a two-stage method to detect the disease based on color texturebased identification and by using a classification to identify the name of the disease. The first stage has the accuracy of 95.99% and the second stage has 94.016% accuracy.
In [2] Nawal Soliman, & ALKolifi AlEnezi at el. "A method of skin disease detection using Image Processing and machine learning" has proposed early detection method on image processing based on Convolutional neural network to feature extraction and then using color to identify the features.
In [3] Pravin S. Ambad & A. S. Shirsat at el. "An image analysis System to detect skin diseases" has proposed a system for early identification of skin problem using statistical analysis and ad boost classifier. Their research mainly focused on early identification of skin cancer symptoms based on statistical analysis with correlation algorithms.
In [4] Li-sheng Wei, Quan Gan, and Tao ji at el. "Skin Disease recognition method based on image color and texture features" has proposed a model based on feature extraction of image using color texture and using segmentation and SVM on it to identify the disease.
In [5] R. Yasir, M S I Nibir and N. Ahmed at el. "A skin disease detection system for financially unstable people in developing countries" has proposed a system for detection of disease which could be implemented on mobile devices as well as computer using desktop application based upon computer vision technique.
In [6] R Sumithra, M Suhilb and D S guruc at el., "Segmentation and classification of skin lesion for disease diagnosis" has proposed a model for segmentation and classification a skin disease using SVM and KNN algorithms.
In [7] Rahat Yasir, Md. Ashiqur Rahman and Nova Ahmed at el. "Dermatological Disease detection using image processing and artificial neural network" has used various kind of different image processing algorithms for feature extraction and feed forwarding using artificial neural network for training and testing the model. The system works on two parts, in the first part the feature extraction has been taken place based upon the color texture and in the second stage the classifier identifies the possible disease.
In [8] Nidhai k, Al Abbadi, Nizzar Saadi at el., "Psoriasis detection using skin color and texture features" has proposed a model for identification of psoriasis using color feature extraction and classification of the skin image.
In [9] Kumar, V., Kumar S., & Saboo, V. at el, "Dermatological disease detection using Image Processing and machine learning" has proposed a model which uses computer vision and machine learning. The features of image are extracted and algorithms are applied onto it to detect six types of diseases with a accuracy of 95%.
In [10] Pollap D. et al. "An intelligent for monitoring skin disease" has proposed a method of clustering image using navi for classification. They have used SIFT method for detection of key points in the image. After that they have used CNN and SVM for classification and segmentation. They have a accuracy of 84% and a precision of 82%.
In [12] Abbadi et al. "Psoriasis detection using skin color and texture feature" has mentioned color feature extraction method and texture extraction method to detect psoriasis on skin. Color feature are extracted by using own mathematical formula for RGB color. Also, various other texture features are In [13] Megha D. Tijare et al. "Detecting skin disease by accurate skin segmentation using various color spaces" has presented a servey paper on how various skin segmentation techniques are helping in detecting of the skin disease. Also mentioned the various steps which are used alongside the detection of these diseases.
In [14] Ekta Singhal et al. Skin cancer detection using Artificial Neural Network has used Segmentation, Feature Extraction and Classification technique to get the result. Segmentation is done using Thresholding, then features are extracted using 2-D wavelet decomposition. And then classification is done using back propagation neural network and radial basic neural network.
In [15] Manish Kumar and Rajiv Kumar et al. an intelligent System to diagnose the skin disease has proposed formulas for image segmentation and then feature extraction of the image. For feature Extraction various parameters are calculated such as mean, Variance, Energy and Entropy from the image.
In [16] Shashi Rekha at al. Digital Dermatology-Skin disease detection model using image processing has proposed a model for detection of six different skin diseases and skin conditions based on method of feature extraction and classification of the image.
-Skin disease detection and segmentation using dynamic graph cut algorithm and classification through Naive Bayes classifier, graph cut algorithms are used for image processing of skin images and naïve Bayes algorithm used as a classification algorithm.
In [18], Nawal Soliman et. al. -A Method of Skin Disease Detection Using Image Processing and Machine Learning, used image processing techniques and CNN and SVM algorithm as machine learning algorithms.
In [19] Sumitra Ra. Et al. segmentation and classification of skin lesions for disease diagnosis has proposed a method for detection of disease by using the combination of SVM and KNN algorithms. Used segmentation and classification methodology to get the accuracy of F-measure 61%.
In [20] Menzis et al. Frequency and morphologic characteristics of invasive melanomas lacking specific surface microscopic features has proposed SVM classifier-based model for identification of melanomas. They used color feature and texture feature extraction to get a sensitivity result 96 % and specificity of 75%.
From the literature survey, following inferences are can be drawn.
• For skin disease detection and prediction, the support vector machine is mostly used.
• The accuracy of SVM is around 80-90% depending upon the dataset used.
• Skin disease dataset is taken from UCI machine repository as it contains thousands of images for various skin diseases. • The parameters like accuracy, F measure, Specificity, Entropy is used for analysis of the results. The table 1, gives the summary of literature survey and algorithm used in skin disease prediction.

Flow of Research work
The proposed methodology of the research work is as follows (Figure 2): − The problem is defined over a research problem which includes the target domain such asskin disease problem which is to be worked on and listed the literature survey papers which are related to this domain. − We searched the 28 papers from Scopus, Web of Science platform which are related to skin disease prediction, we removed 8 papers from our review study as we feel that they were not pertaining to the quality of the research. − Literature survey is done and we found that SVM is mostly used for classifying the skin diseases using machine learning. − Based on the recommendation of literature review, Support Vector Machine algorithm (SVM) is selected as a classification algorithm. We formulated the problem and research questions based upon SVM. − The SVM is applied to skin disease dataset and results are presented. The appropriate conclusion is drawn.

Problem Statement and Research Questions
The problem statement for the above research is given below:

"Classify and Detect various Skin diseases using Processing and Machine Learning Algorithms (CNN and SVM) and Develop the mobile android application."
The research question for above research problem is as follows: • What is the detection rate of SVM and CNN classifier for various images of skin?
• Which type of skin disease type has highest detection rate?

Dataset Description
Our dataset consists around 3000 images which collected from a lot of sources like Beni-Suef University Hospital, Cairo University Hospital and various websites which are dedicated towards skin diseases and its cure to be more accurate and realistic. The data has been divided into two parts, training set and test sets. The training set data is used to train our model and the test set is used to check if our model is working good or not. Our dataset is then classified into various parts based upon the types of diseases to be trained for each one of them. We have added only those diseases which has been prominent throughout the world. But in the future updates we will add many other diseases solutions which are growing. Table 2 has detailed description of disease dataset.

Figure 3: Process flow of classification algorithm SVM
The figure 3 shows the process flow of classification algorithm using Support Vector Machine. The input skin image is taken from Skin Disease Dataset. In android application, it is considered as Image acquisition phase. It captures image from image gallery of android application. The pre-processing includes the brightness and contrast or resizing the image into accurate directions. For the feature extraction of the image we have to use an algorithm which will work on various layer of the image for the feature extraction from the image. This requirement leads us to using the CNN and SVM algorithm. The results are displayed in the android application itself.

Android application and processing steps
The android application is really simple and easy to use. The main page is login page which consist of two section. First for the doctor and second for the patient. Both doctor and patient have their separate dashboard. The login panel and user data is managed by google Firebase which provided APIs for authentication and data storage. The dashboard for doctor and patient consists of various widgets like click image or load image from database to server for image processing. Also, we have added feature to manually select the symptoms input the users for processing.

Image Acquisition
The dashboard panel consist of features like capture image, open local storage gallery to select the image. The get image feature is added in the doctor panel to get image from the patients which will be uploaded on to the server by the patient himself. Image is selected from either gallery or camera and stored in the local storage of the mobile device. Methods like OnRequestPermissionResult () is used to check for the request permission of the android device.
Public static final int MY_PERMISSOIN_REQUEST_READ_EXTERNAL_STORAGE = 123; Public static final int MY_PERMISSOIN_REQUEST_READ_CAMERA= 124; The image can be gathered either by using navigation drawer consists of user ID and features like generate report of patients and can be used to check previous medical history of the patient.

Preprocessing:
To achieve a high performance of skin disease detection and prediction we required to overcome few problems which occur during loading the data. Such as color contrast and image size. To overcome this problem, we have module in our application which takes care of this thing. The image resizer program in python resize all the image for us before loading them onto the server for processing. Therefore the main target of this step is to removes the background noises such as hair and air bubbles and other noises in the skin disease image. To eliminating those noises from the particular skin image and to get smoothing image, median filtering, mean, var and histogram is used. Then the post processing is applied to improve the shape and edges of skin disease image.

Feature Extraction:
For the feature extraction of the image we have to use an algorithm which will work on various layer of the image for the feature extraction from the image. Therefore, the proposed system tries to implement more algorithms which lead us to using the CNN. Convolutional Neural Network (CNN) is combination of various stacks which has linear and non-linear processes. The CNN consists of three main blocks which are 1. Connected layer 2. Pooling layer 3. ReLU layer (non-linear Rectified Linear units) which are connected to a regular multi-layer fully connected layer.
The main feature which are extracted from the images are color. The color of the infected area of the disease helps in identifying the kind of the disease. An image is converted into binary form and then a color of the skin is extracted using YCbCr algorithm. The detection of skin depends upon the pixels and RGB color ratio of each pixel. The YcbCr values can be generated from the ration of RGB for each pixel. And is put into a formula. False Negative The next feature which we extracted is the size of the infected area. The binary image is converted into a histogram and then the pixels of the histogram is multiplied with the whole area to find out the total area of infection. Identification of the size of the infected area helped our model to ease the prediction of our classifier to find the disease. To train our model we have to do a feedforward backpropagation neural network training to perform our process word The various feature extraction extracted from one of the image we had of one of the most prominent disease which is psoriasis is

Classification:
Support vector machine algorithm is used which is a statistical analysis algorithm based on statistical theory. This is best suitable for the classification of the various diseases. The SVM method is fed with trained data which helps in identifying the disease. Features are extracted from training datasets (color feature and texture feature). A prebuilt model is used here to identify the disease.

Results
Initially, to optimization the skin images, we apply some image processing method by removing the background. Therefore, the histogram is done to identify the injured part and use the appropriate cavities Histogram equalization technique for adjusting image intensities to enhance contrast. It is not necessary that contrast will always be increase. There may be some cases where histogram equalization can be worse. In that case the contrast is decreased, so It shows which skin is infected and which is not by drawing a diagram Separates between colours of skin as shown in this figure 6.

Figure 6 : Image Optimization
The result is based on a pre-trained model and a little modification into it. The images are fed into our model and rate of disease detection are generated as a result. All the six type of diseases have different type of detection ratio which can might vary based upon the properties of the image as shown in table 3.

Figure 7: Rate of Skin Disease Detection
The proposed method is compared with the existing methods listed in [26] and [27], The results are listed in table 4 (a) and (b)

Conclusion
Identification of disease can help in reducing the problem of skin disease spread and will provide a better way to identify the skin problem. This will provide a low-cost way to do medical treatment without any delays. This will also help in early identification and early treatment of disease before they spread because most of the skin disease can get spread easily with touch. In our application we have used a modified pre-trained model of Convolutional neural network and SVM Algorithm. This