O'Reilly logo

Effective Amazon Machine Learning by Alexis Perrier

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Producing tweets

A Kinesis producer can take many shapes as long as it sends data to the Kinesis Stream. We will use the Python Firehose SDK and write a simple script that collects Tweets from the twitter API, filters some of them, and sends them to the Kinesis Firehose. We use the Python-Twitter library.

There are several Twitter API Python packages available on GitHub. Two of the more popular ones, Twitter and Python-Twitter (https://pypi.python.org/pypi/python-twitter/) share the same import calls import twitter, but not the same method calls, which can lead to confusion and time being wasted.

The Python-Twitter package offers a GetSearch method that takes either a query string term or a raw_query as a parameter for the Twitter search: ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required