[Python] Collect images with Icrawler for machine learning [1000 images]

Conclusion

# coding: utf-8
import os
from icrawler.builtin import GoogleImageCrawler

"""----------------   Settings   ------------------"""
search_word = u"Cat"#In the case of Japanese, in the head"u"Put on
dir_ = "./images/"+search_word+"/"
download_num = 1000 #Number of downloads
"""--------------------------------------------------"""


if not os.path.exists(dir_):#Create if there is no folder
    os.makedirs(dir_)

crawler = GoogleImageCrawler(storage={"root_dir": dir_})
crawler.crawl(keyword=search_word, max_num=download_num)

Recommended Posts

[Python] Collect images with Icrawler for machine learning [1000 images]
Amplify images for machine learning with python
[Python] Collect images easily with icrawler!
[Shakyo] Encounter with Python for machine learning
Collect images for machine learning (Bing Search API)
Machine learning with Python! Preparation
Beginning with Python machine learning
Machine learning with python (1) Overall classification
<For beginners> python library <For machine learning>
"Scraping & machine learning with Python" Learning memo
Machine learning with python (2) Simple regression analysis
Why Python is chosen for machine learning
[Python] Web application design for machine learning
[Python] Read images with OpenCV (for beginners)
An introduction to Python for machine learning
Build AI / machine learning environment with Python
Building a Windows 7 environment for getting started with machine learning with Python
[Python] Easy introduction to machine learning with python (SVM)
Learning Python with ChemTHEATER 03
Machine learning starting with Python Personal memorandum Part2
"Object-oriented" learning with python
Learning Python with ChemTHEATER 05-1
Machine learning starting with Python Personal memorandum Part1
Upgrade the Azure Machine Learning SDK for Python
Learning Python with ChemTHEATER 02
Learning Python with ChemTHEATER 01
Collect images using icrawler
I started machine learning with Python Data preprocessing
Build a Python machine learning environment with a container
Align the number of samples between classes of data for machine learning with Python
Python learning notes for machine learning with Chainer Chapters 11 and 12 Introduction to Pandas Matplotlib
Build an interactive environment for machine learning in Python
Run a machine learning pipeline with Cloud Dataflow (Python)
Python learning memo for machine learning by Chainer from Chapter 2
Python learning memo for machine learning by Chainer Chapters 1 and 2
Preparing to start "Python machine learning programming" (for macOS)
Build a machine learning application development environment with Python
[Python] I made a classifier for irises [Machine learning]
Machine Learning with Caffe -1-Category images using reference model
Summary of the basic flow of machine learning with Python
Memo for building a machine learning environment using Python
Machine learning learned with Pokemon
Data set for machine learning
Bordering images with python Part 1
Learning flow for Python beginners
Python learning plan for AI learning
Reinforcement learning starting with Python
Machine learning Minesweeper with PyTorch
Python Machine Learning Programming> Keywords
Checkio's recommendation for learning Python
Python Iteration Learning with Cheminformatics
Try machine learning with Kaggle
[Python] Save PDF from Google Colaboratory to Google Drive! -Let's collect data for machine learning-
I tried to build an environment for machine learning with Python (Mac OS X)
Rebuilding an environment for machine learning with Miniconda (Windows version)
Build an environment for machine learning using Python on MacOSX
I started machine learning with Python Clustering & Dimension Compression & Visualization
Made icrawler easier to use for machine learning data collection
For those who want to start machine learning with TensorFlow2
Python learning memo for machine learning by Chainer Chapter 7 Regression analysis
Create a python machine learning model relearning mechanism with mlflow