A.I, Data and Software Engineering

Tagkeras

Advanced Keras – Custom loss functions

petamind

When working on machine learning problems, sometimes you want to construct your own custom loss function(s). This article will introduce abstract Keras backend for that purpose. Keras loss functions From Keras loss documentation, there are several built-in loss functions, e.g. mean_absolute_percentage_error, cosine_proximity, kullback_leibler_divergence etc. When compiling a Keras model, we often...

Continue training big models on less powerful devices

It would not be a surprise that you may not have a powerful expensive machine to train a complicate model. You may experience the problem of not enough memory during training in some epoch. This article demonstrates a simple workaround for this. The problem Training deep learning models requires a lot of computing power. For most laptop and desktop today, you can still train the models but it can...

MLP for implicit binary collaborative filtering

In this post, we demonstrate Keras implementation of the implicit collaborative filtering. We also introduce some techniques to improve the performance of the current model, including weight initialization, dynamic learning rate, early stopping callback etc. The implicit data For demonstration purposes, we use the dataset generated from negative samples using the technique mentioned in this post...

Generate data on the fly – Keras data generator

Previously, we train our model using the pre-generated dataset, for example, in the recommender system or recurrent neural network. In this article, we will demonstrate using a generator to produce data on the fly for training a model. Keras Data Generator with Sequence There are a couple of ways to create a data generator. However, Tensorflow Keras provides a base class to fit dataset as a...

build a simple recommender system with matrix factorization

We will build a recommender system which recommends top n items for a user using the matrix factorization technique- one of the three most popular used recommender systems. matrix factorization Suppose we have a rating matrix of m users and n items. The rating of user to item is . Similar to PCA, matrix factorization (MF) technique attempts to decompose a (very) large matrix () to smaller...

A.I, Data and Software Engineering

PetaMinds focuses on developing the coolest topics in data science, A.I, and programming, and make them so digestible for everyone to learn and create amazing applications in a short time.

Categories