• Title/Summary/Keyword: Weighted Loss Function

Search Result 52, Processing Time 0.021 seconds

A Derivation of the Representative Unit Hydrograph from Multiperiod Complex Storm by Linear Programming (선형계획법(線型計劃法)에 의한 대표단위도(代表單位圖) 유도(誘導))

  • Kwon, Oh Hun;Ryu, Tae Sang;Yoo, Ju Hwan
    • KSCE Journal of Civil and Environmental Engineering Research
    • /
    • v.13 no.2
    • /
    • pp.173-182
    • /
    • 1993
  • This paper presents an algorithm to derive the representative unit hydrograph for the real environment of a watershed. For a given watershed, the conventional methods give several different unit hydrographs by storm events. In this study the LP model is somewhat modified based on the previous study by Mays et also as follows: the objective function is designed to minimize the sum of weighted residuals. An additional constraint of moving average is added to prevent the unit hydrograph from the occurence of oscillation which was not active in Mays's paper. Configuration of rainfall matrix was improved to reduce its dimension in accordance with Diskin's review point. In spite of the superiority of LP approach in terms of representativeness, all the methods were very sensitive to the validity of baseflow separation and rainfall-loss. Several methods of the separations for rainfall excesses and direct runoffs were applied and no preferred methods were identified. This is the matter of judgement considering catchment and rainfall characteristics. This algorithm was applied to a real watershed of the Wi stream in the Nak-dong river. Compared with the IHP results by conventional methods, this optimized representative unit hydrograph demonstrated relatively smaller and shorter values in terms of the peak discharge and the basin lag respectively, and the oscillation of its falling limb successfully eliminated owing to the additional constraints of moving averages.

  • PDF

A Two-Stage Learning Method of CNN and K-means RGB Cluster for Sentiment Classification of Images (이미지 감성분류를 위한 CNN과 K-means RGB Cluster 이-단계 학습 방안)

  • Kim, Jeongtae;Park, Eunbi;Han, Kiwoong;Lee, Junghyun;Lee, Hong Joo
    • Journal of Intelligence and Information Systems
    • /
    • v.27 no.3
    • /
    • pp.139-156
    • /
    • 2021
  • The biggest reason for using a deep learning model in image classification is that it is possible to consider the relationship between each region by extracting each region's features from the overall information of the image. However, the CNN model may not be suitable for emotional image data without the image's regional features. To solve the difficulty of classifying emotion images, many researchers each year propose a CNN-based architecture suitable for emotion images. Studies on the relationship between color and human emotion were also conducted, and results were derived that different emotions are induced according to color. In studies using deep learning, there have been studies that apply color information to image subtraction classification. The case where the image's color information is additionally used than the case where the classification model is trained with only the image improves the accuracy of classifying image emotions. This study proposes two ways to increase the accuracy by incorporating the result value after the model classifies an image's emotion. Both methods improve accuracy by modifying the result value based on statistics using the color of the picture. When performing the test by finding the two-color combinations most distributed for all training data, the two-color combinations most distributed for each test data image were found. The result values were corrected according to the color combination distribution. This method weights the result value obtained after the model classifies an image's emotion by creating an expression based on the log function and the exponential function. Emotion6, classified into six emotions, and Artphoto classified into eight categories were used for the image data. Densenet169, Mnasnet, Resnet101, Resnet152, and Vgg19 architectures were used for the CNN model, and the performance evaluation was compared before and after applying the two-stage learning to the CNN model. Inspired by color psychology, which deals with the relationship between colors and emotions, when creating a model that classifies an image's sentiment, we studied how to improve accuracy by modifying the result values based on color. Sixteen colors were used: red, orange, yellow, green, blue, indigo, purple, turquoise, pink, magenta, brown, gray, silver, gold, white, and black. It has meaning. Using Scikit-learn's Clustering, the seven colors that are primarily distributed in the image are checked. Then, the RGB coordinate values of the colors from the image are compared with the RGB coordinate values of the 16 colors presented in the above data. That is, it was converted to the closest color. Suppose three or more color combinations are selected. In that case, too many color combinations occur, resulting in a problem in which the distribution is scattered, so a situation fewer influences the result value. Therefore, to solve this problem, two-color combinations were found and weighted to the model. Before training, the most distributed color combinations were found for all training data images. The distribution of color combinations for each class was stored in a Python dictionary format to be used during testing. During the test, the two-color combinations that are most distributed for each test data image are found. After that, we checked how the color combinations were distributed in the training data and corrected the result. We devised several equations to weight the result value from the model based on the extracted color as described above. The data set was randomly divided by 80:20, and the model was verified using 20% of the data as a test set. After splitting the remaining 80% of the data into five divisions to perform 5-fold cross-validation, the model was trained five times using different verification datasets. Finally, the performance was checked using the test dataset that was previously separated. Adam was used as the activation function, and the learning rate was set to 0.01. The training was performed as much as 20 epochs, and if the validation loss value did not decrease during five epochs of learning, the experiment was stopped. Early tapping was set to load the model with the best validation loss value. The classification accuracy was better when the extracted information using color properties was used together than the case using only the CNN architecture.