Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Using logistic regression to predict parking difficulty (googleblog.com)
170 points by cing on Feb 3, 2017 | hide | past | favorite | 34 comments


I appreciate a good ol' logistic regression model. I know deep learning is hot shit right now, but this right here is probably the best way to solve most real world ML problems. Just good data, insightful features, and a simple classifier.


The dirty secret in ML is that logistic regression, SVM, and random forests often work better than deep learning on real problems.


This is literally how you can distinguish actual machine learners from blog readers.

- Deep learn everything!

vs.

- I took at look at the variable distributions, went with a forest model after transforming some of the data.


> I took at look at the variable distributions, went with a forest model after transforming some of the data.

That's what a statistician does too... I wish statistician word is more in vogue than data science or machine learners. Statistic is the discipline of data.


Uhhh most deep nets for classification or even regression have a regression at the end. You can even use a svm at the end. The power of deep learning is in the feature learning.


Yes, but using an SVM or whatever at the end of a deep network only really works for the same domains that deep networks work well in already - typically audio/visual data and some language datasets.


Most "simple" datasets like insurance prediction from structured data has been solved already via traditional techniques. The difficulty in machine learning was always in the noisy and unstructured datasets like images.


I'm curious what background you have in ML. "The difficulty in machine learning was always in the noisy and unstructured datasets like images" is truly a baffling statement to make.


"solved"

I'm going to disagree with you here.


For image classification, CNN's are still the way to go. But creating your own architecture and training your own novel model aren't necessary for most problems anymore it seems because of transfer learning.


I threw all of the above plus CNNs at MNIST problem and boosted decision trees outperformed CNNs.

Granted if I tuned both perfectly, CNNs probably would have outperformed but with defaults and a small amount of parameter search, boosting worked best.


That's pretty interesting, why are boosted decision trees so effective? I've heard the same meme applied to kaggle competitions (everything is just a way to shove data into xgboost, etc)


The grandparent post contains a hint of something I've already heard in lectures and from ML practicioners: boosting and random forests are more resilient to improper tuning (to put it another way, they are more universal and work well "out of the box").

Which, BTW, makes them more appealing to me personally. In many real-life cases extra few percent of accuracy matters very little, but ability to just apply something to a problem without much fuss matters a lot.


Gradient boosting also often does wonders.


You are absolutely right about that!


Deep Learning is mostly just about automatically creating good features. As an example if you had the driving data and were too lazy to hand engineer features for what looked like loops looking for parking. You could use deep learning and then use logistics regression ontop of the features you learnt


And you can explain the output in simple terms.


Just so you know, there are really powerful "classical statistics" classifier models! Like ordered or multinomial logit/probit which you can incorporate latent classes into, etc. Reference book for those is here[1]

[1] http://pages.stern.nyu.edu/~wgreene/DiscreteChoice/Readings/...


very true


You can't write a blog post on how to build a statistical model without stating how good the model is in actuality, along with validating the other regression details such as independence of features, train/test split, etc. (I am coincidentally working on a blog post along a similar San Francisco dataset which specifically addresses these concerns, so it's on the mind)

Logistic regression in particular has many features which provide more information about feature importance or lack thereof and many metric to confirm model quality, and it is disappointing to see this post only do a high-level overview. Yes, it may be a Google trade secret, but there has to be give-and-take.


> You can't write a blog post on how to build a statistical model without stating how good the model is in actuality

> it is disappointing to see this post only do a high-level overview. Yes, it may be a Google trade secret, but there has to be give-and-take.

Why exaclty? This is not an academic paper. People who get this feature to show up might be curious about how it works, and 99.9% of them won't understand anything about independence of features, train/test split, etc. Worse, they would find the article too boring and technical. Just knowing that it is powered by a ML algorithm (and not some human input) is enough. I'm not sure why there has to be a give-and-take.

The fact that they put links to wikipedia for what Logistic regression is should give a good idea of the intended audience of this blog post.


> Worse, they would find the article too boring and technical.

> The fact that they put links to wikipedia for what Logistic regression is should give a good idea of the intended audience of this blog post.

The Wikipedia page on logistic regression is an order of magnitude more technical than this blog post.


It seems like they could have had a "how good is the model" section where they tested it on a different chunk of data, maybe show a ROC plot... I can't imagine that would have taken away from their message.


I was kind of scratching my head there. I'm programmed to look at this kind of a write-up and just assume that they violated lots of assumptions, had a poor fit, and were weakly predictive when validated against new data.

It's not that any of those things are necessarily true, it's just that I'm used to people at least trying to make a plausible case that they weren't.


> we were able to ... utilize anonymous aggregated information from users who opt to share their location data

That should read, "from users who did not disable the on-by-default sharing of their location data"


Is it actually on by default ? Last time I reset my android phone, I had to agree to sharing my location history etc.


"When we started the training process, many of us thought that the “fingerprint” feature described above would be the “silver bullet” that would crack the problem for us. We were surprised to note that this wasn’t the case at all — in fact, it was features based on the dispersion of parking locations that turned out to be one of the most powerful predictors of parking difficulty."

I assume dispersion of parking locations is the distance from parking location to destination? I would have liked to see more about what kinds of inputs they used and how they cleaned them up to account for the confounding factors they mention (public transit users, private parking.)


> I assume dispersion of parking locations is the distance from parking location to destination?

I would guess its the density of parking locations in a given area, rather than distance to destination?


> in a pre-launch experiment, we saw a significant increase in clicks on the transit travel mode button, indicating that users with additional knowledge of parking difficulty were more likely to consider public transit rather than driving.

This shows pretty clear that we shouldn't try to accommodate cars as much as possible when there already is good public transport at a certain location.


We should also remember that excessive accommodation of cars will often prevent the possibility of good mass transit.


I was just retaking CS261 on Coursera alongside a friend (we're in week 3) and they were asking, "What good is this anyways?"

Related techniques and how to implement them are covered in the first 2 weeks. While a lot more is going on in this system, one could call the core of the system that does this estimation "simple" for the field.


I am wondering how much of this gets to be real-time. Are they computing the difficulty of finding a spot based on Maps/Waze users' live data or using daily/weekly patterns on past data?


If you go to Stein's you better walk or take public transport, though. ;-)


Can we use an API to help test parking prediction by using it in our apps?




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: