This feature is a part of Product CSV. Click here to see all Product CSV features.
In Catalog Settings > Product CSV, you can configure the importer to assign category image from a product:
If the category image is not provided, it will be taken from the product. It works only for categories without any image assigned.