def precision_recall_f1_score(true_positive, pred_count, val_count):
    """
    Calculates precision, recall and f1 score.

    :param int true_positive: True positive count.
    :param int pred_count: Predict count.
    :param int val_count: Validation count.
    :rtype: float
    :return: (precision, recall, f1)
    """
    precision = true_positive / pred_count
    recall = true_positive / val_count
    f1 = 2 * (precision * recall) / (precision + recall)
    return precision, recall, f1