Skip to content

Commit

Permalink
bug fix
Browse files Browse the repository at this point in the history
  • Loading branch information
yusuke-a-uchida committed Aug 5, 2018
1 parent 5ecdc50 commit 111beb5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions age_estimation/model.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@


def age_mae(y_true, y_pred):
true_age = K.sum(y_true * K.arange(0, 101), axis=-1)
pred_age = K.sum(y_pred * K.arange(0, 101), axis=-1)
true_age = K.sum(y_true * K.arange(0, 101, dtype="float32"), axis=-1)
pred_age = K.sum(y_pred * K.arange(0, 101, dtype="float32"), axis=-1)
mae = K.mean(K.abs(true_age - pred_age))
return mae

Expand Down

0 comments on commit 111beb5

Please sign in to comment.