Sr. AI Scientist – Computer Vision – Course5 Intelligence – Toronto, ON
From Indeed – Tue, 02 Jul 2019 15:11:23 GMT – View all Toronto, ON jobs
This is a 45 minute talk by Em Grasmeder from GOTO Amsterdam 2019.
https://www.youtube.com/watch?v=HJkzhN7LgrQ&feature=youtu.be&list=PLEx5khR4g7PKT9RvuVyQxJLO8CZUJzNMy
Please give the talk abstract a read below before giving it a watch:
The field of data science is having a little identity crisis. The fundamental questions of what data science is, and who a data scientist is, remain largely undecided. Regardless of where the answer will fall, there are a number of tools and techniques that every data scientist should have in their toolbelt. Although the software languages, frameworks, and algorithms will come in and out of fashion, the fundamentals behind the trade of data science, which we talk about in this session, have existed for centuries and will continue to be used for ages to come.
What will the audience learn from this talk?
The audience will learn an overview and history of the math, philosophy, software engineering, and algorithms that are inseparable from the field of Data Science. We will cover techniques like optimisation theory like principle component analysis, at the level of analysing where and why we use certain techniques, but not how they are implemented or how to use them in a data science pipeline.
submitted by /u/mto96
[link] [comments]
tl;dr: Which log-likelihood function should I use for training VQ-VAE, when I only care about the embeddings?
Hi.
Since no one responded on r/MLQuestions, this might be better suited here:
I have a question concerning the use of VAEs for encoding, as opposed to using them for data generation. In particular, I want to use a vector-quantising variational autoencoder to find a discrete representation of continuous data for some downstream task. I wonder if the choice of the decoder likelihood function would have a noticeable impact on the quality of the discrete representation.
The objective for a batch size of 1 has the following form (omitting some VQ-VAE specific terms):
max log p_dec(x|z_enc) – KL( q(z) || p(z) )
where x is a training sample, z_enc is a latent random value generated by the encoder, p_dec is the likelihood function for the decoder, q is the posterior estimate of the decoder over latent variable z and p(z) is the actual prior.
When I assume p_dec(X | z_enc) to be a multivariate normal distribution where the mean is given by some neural network and the covariance is an identity matrix, I can replace the log-likelihood term with the negative mean squared error, as in normal regression. This is what I’ve seen being used in some implementations.
But I could also let the decoder output an arbitrary covariance matrix. This would of course change the log-likelihood function.
Do you think it makes sense to use a more involved log-likelihood function (i.e. arbitrary pos. semi-definite covariance matrix), so that the encoder is forced to find a representation that is better for explaining data coming from a complex distribution? Do you know of any non-domain-specific papers investigating the use of VQ-VAEs for encoding?
submitted by /u/tanukibellydrum
[link] [comments]
Let’s say someone has chronic pain and they want to log everyday activities(like food eaten, exercises, meds taken, etc) to see if there is any correlation between them and the intensity of pain. But actually there’s no correlation and the intensity behaves like a sin wave across the training examples, like its sequential/temporal.
How do you model this kind of behavior to extract knowledge?
submitted by /u/jim1564
[link] [comments]
Sharing our latest work presented at the ICML workshop “Identifying and Understanding Deep Learning Phenomena”:
Layer rotation: a surprisingly powerful indicator of generalization in deep networks? (arxiv link)
We’re pretty excited about it: we really believe layer rotation (the metric we study) is somehow related to a fundamental aspect of deep learning, and that it is worth much more investigation. For the moment, our work demonstrates that layer rotation’s relation with generalization exhibits a remarkable
We also provide preliminary evidence that layer rotations correlate with the degree to which intermediate features are learned during the training procedure.
Since we also provide tools to monitor and control layer rotation during training, our work could also greatly reduce the current hyperparameter tuning struggle. Code available! Here and here.
Looking forward to your feedback!
Abstract:
Our work presents extensive empirical evidence that layer rotation, i.e. the evolution across training of the cosine distance between each layer’s weight vector and its initialization, constitutes an impressively consistent indicator of generalization performance. In particular, larger cosine distances between final and initial weights of each layer consistently translate into better generalization performance of the final model. Interestingly, this relation admits a network independent optimum: training procedures during which all layers’ weights reach a cosine distance of 1 from their initialization consistently outperform other configurations -by up to 30% test accuracy. Moreover, we show that layer rotations are easily monitored and controlled (helpful for hyperparameter tuning) and potentially provide a unified framework to explain the impact of learning rate tuning, weight decay, learning rate warmups and adaptive gradient methods on generalization and training speed. In an attempt to explain the surprising properties of layer rotation, we show on a 1-layer MLP trained on MNIST that layer rotation correlates with the degree to which features of intermediate layers have been trained.
submitted by /u/Simoncarbo
[link] [comments]
Abstract: This paper proposes an end-to-end emotional speech synthesis (ESS) method which adopts global style tokens (GSTs) for semi-supervised training. This model is built based on the GST-Tacotron framework. The style tokens are defined to present emotion categories. A cross entropy loss function between token weights and emotion labels is designed to obtain the interpretability of style tokens utilizing the small portion of training data with emotion labels. Emotion recognition experiments confirm that this method can achieve one-to-one correspondence between style tokens and emotion categories effectively. Objective and subjective evaluation results show that our model outperforms the conventional Tacotron model for ESS when only 5% of training data has emotion labels. Its subjective performance is close to the Tacotron model trained using all emotion labels. Keywords: emotional speech synthesis, end-to-end, Tacotron, global style tokens, semi-supervised training
submitted by /u/cdossman
[link] [comments]

Anomaly detection is the process of identifying unexpected items or events in data sets, which differ from the norm. And anomaly detection is often applied on unlabeled data which is known as unsupervised anomaly detection. Anomaly detection has two basic assumptions:
Before we get to Multivariate anomaly detection, I think its necessary to work through a simple example of Univariate anomaly detection method in which we detect outliers from a distribution of values in a single feature space.
We are using the Super Store Sales data set that can be downloaded from here, and we are going to find patterns in Sales and Profit separately that do not conform to expected behavior. That is, spotting outliers for one variable at a time.
import pandas as pd
import numpy as np
import matplotlib.pyplot as plt
import seaborn as sns
import matplotlib
from sklearn.ensemble import IsolationForest
df = pd.read_excel("Superstore.xls")
df['Sales'].describe()

plt.scatter(range(df.shape[0]), np.sort(df['Sales'].values))
plt.xlabel('index')
plt.ylabel('Sales')
plt.title("Sales distribution")
sns.despine()

sns.distplot(df['Sales'])
plt.title("Distribution of Sales")
sns.despine()

print("Skewness: %f" % df['Sales'].skew())
print("Kurtosis: %f" % df['Sales'].kurt())

The Superstore’s sales distribution is far from a normal distribution, and it has a positive long thin tail, the mass of the distribution is concentrated on the left of the figure. And the tail sales distribution far exceeds the tails of the normal distribution.
There are one region where the data has low probability to appear which is on the right side of the distribution.
df['Profit'].describe()

plt.scatter(range(df.shape[0]), np.sort(df['Profit'].values))
plt.xlabel('index')
plt.ylabel('Profit')
plt.title("Profit distribution")
sns.despine()

sns.distplot(df['Profit'])
plt.title("Distribution of Profit")
sns.despine()

print("Skewness: %f" % df['Profit'].skew())
print("Kurtosis: %f" % df['Profit'].kurt())

The Superstore’s Profit distribution has both a positive tail and negative tail. However, the positive tail is longer than the negative tail. So the distribution is positive skewed, and the data are heavy-tailed or profusion of outliers.
There are two regions where the data has low probability to appear: one on the right side of the distribution, another one on the left.
Isolation Forest is an algorithm to detect outliers that returns the anomaly score of each sample using the IsolationForest algorithm which is based on the fact that anomalies are data points that are few and different. Isolation Forest is a tree-based model. In these trees, partitions are created by first randomly selecting a feature and then selecting a random split value between the minimum and maximum value of the selected feature.
The following process shows how IsolationForest behaves in the case of the Susperstore’s sales, and the algorithm was implemented in Sklearn and the code was largely borrowed from this tutorial

According to the above results and visualization, It seems that Sales that exceeds 1000 would be definitely considered as an outlier.
df.iloc[10]

This purchase seems normal to me expect it was a larger amount of sales compared with the other orders in the data.

According to the above results and visualization, It seems that Profit that below -100 or exceeds 100 would be considered as an outlier, let’s visually examine one example each that determined by our model and to see whether they make sense.
df.iloc[3]

Any negative profit would be an anomaly and should be further investigate, this goes without saying
df.iloc[1]

Our model determined that this order with a large profit is an anomaly. However, when we investigate this order, it could be just a product that has a relatively high margin.
The above two visualizations show the anomaly scores and highlighted the regions where the outliers are. As expected, the anomaly score reflects the shape of the underlying distribution and the outlier regions correspond to low probability areas.
However, Univariate analysis can only get us thus far. We may realize that some of these anomalies that determined by our models are not the anomalies we expected. When our data is multidimensional as opposed to univariate, the approaches to anomaly detection become more computationally intensive and more mathematically complex.
Most of the analysis that we end up doing are multivariate due to complexity of the world we are living in. In multivariate anomaly detection, outlier is a combined unusual score on at least two variables.
So, using the Sales and Profit variables, we are going to build an unsupervised multivariate anomaly detection method based on several models.
We are using PyOD which is a Python library for detecting anomalies in multivariate data. The library was developed by Yue Zhao.
When we are in business, we expect that Sales & Profit are positive correlated. If some of the Sales data points and Profit data points are not positive correlated, they would be considered as outliers and need to be further investigated.
sns.regplot(x="Sales", y="Profit", data=df)
sns.despine();

From the above correlation chart, we can see that some of the data points are obvious outliers such as extreme low and extreme high values.
The CBLOF calculates the outlier score based on cluster-based local outlier factor. An anomaly score is computed by the distance of each instance to its cluster center multiplied by the instances belonging to its cluster. PyOD library includes the CBLOF implementation.
The following code are borrowed from PyOD tutorial combined with this article.

HBOS assumes the feature independence and calculates the degree of anomalies by building histograms. In multivariate anomaly detection, a histogram for each single feature can be computed, scored individually and combined at the end. When using PyOD library, the code are very similar with the CBLOF.

Isolation Forest is similar in principle to Random Forest and is built on the basis of decision trees. Isolation Forest isolates observations by randomly selecting a feature and then randomly selecting a split value between the maximum and minimum values of that selected feature.
The PyOD Isolation Forest module is a wrapper of Scikit-learn Isolation Forest with more functionalities.

KNN is one of the simplest methods in anomaly detection. For a data point, its distance to its kth nearest neighbor could be viewed as the outlier score.

The anomalies predicted by the above four algorithms were not very different.
We may want to investigate each of the outliers that determined by our model, for example, let’s look in details for a couple of outliers that determined by KNN, and try to understand what make them anomalies.
df.iloc[1995]

For this particular order, a customer purchased 5 products with total price at 294.62 and profit at lower than -766, with 80% discount. It seems like a clearance. We should be aware of the loss for each product we sell.
df.iloc[9649]

For this purchase, it seems to me that the profit at around 4.7% is too small and the model determined that this order is an anomaly.
df.iloc[9270]

For the above order, a customer purchased 6 product at 4305 in total price, after 20% discount, we still get over 33% of the profit. We would love to have more of these kind of anomalies.
Jupyter notebook for the above analysis can be found on Github. Enjoy the rest of the week.
Anomaly Detection for Dummies was originally published in Towards Data Science on Medium, where people are continuing the conversation by highlighting and responding to this story.
Hi, I would like to detect defects in some objects. I have multiple pictures of the same object taken from different angles. Some defects are easier to detect, if you look at two (or three) pictures of the same object from different angles, rather than just at one. However, the object detection models I know of (such as RetinaNet, or Faster R-CNN) only look at one image at a time.
Do you know of any model(s) which can look at multiple pictures of the same object at once?
submitted by /u/AndriPi
[link] [comments]
Hey reddit fam! The Machine Intelligence Conference committee is excited to announce our IBM Diversity Scholarship for 2019. This will cover flight and hotel expenses for selected applicants. Please see our website for more details: https://machineintelligence.cc/conference/scholarship
submitted by /u/MICInc
[link] [comments]