I found an example of how to do this in this blog post. Below I've rewritten the example using my Publisher/Book/BookImage models, and generic class-based views, for future reference.
The form also allows the user to edit the titles of the Books, which wasn't what I originally wanted, but this seems easier than not doing it; the inline Book forms require at least one field each, so we may as well include the Book's title.
Also, to see how this worked, I've put together a small Django project using this code, and a little more detail, available on GitHub.
models.py:
from django.db import models
class Publisher(models.Model):
    name = models.CharField(max_length=255)
class Book(models.Model):
    title = models.CharField(max_length=255)
    publisher = models.ForeignKey('Publisher', on_delete=models.CASCADE)
class BookImage(models.Model):
    book = models.ForeignKey('Book', on_delete=models.CASCADE)
    image = models.ImageField(max_length=255)
    alt_text = models.CharField(max_length=255)
forms.py:
from django.forms.models import BaseInlineFormSet, inlineformset_factory
from .models import Publisher, Book, BookImage
# The formset for editing the BookImages that belong to a Book.
BookImageFormset = inlineformset_factory(
                                        Book,
                                        BookImage,
                                        fields=('image', 'alt_text')),
                                        extra=1)
class BaseBooksWithImagesFormset(BaseInlineFormSet):
    """
    The base formset for editing Books belonging to a Publisher, and the
    BookImages belonging to those Books.
    """
    def add_fields(self, form, index):
        super().add_fields(form, index)
        # Save the formset for a Book's Images in a custom `nested` property.
        form.nested = BookImageFormset(
                                instance=form.instance,
                                data=form.data if form.is_bound else None,
                                files=form.files if form.is_bound else None,
                                prefix='bookimage-%s-%s' % (
                                    form.prefix,
                                    BookImageFormset.get_default_prefix()),
                            )
    def is_valid(self):
        "Also validate the `nested` formsets."
        result = super().is_valid()
        if self.is_bound:
            for form in self.forms:
                if hasattr(form, 'nested'):
                    result = result and form.nested.is_valid()
        return result
    def save(self, commit=True):
        "Also save the `nested` formsets."
        result = super().save(commit=commit)
        for form in self.forms:
            if hasattr(form, 'nested'):
                if not self._should_delete_form(form):
                    form.nested.save(commit=commit)
        return result
# This is the formset for the Books belonging to a Publisher and the
# BookImages belonging to those Books.
PublisherBooksWithImagesFormset = inlineformset_factory(
                                        Publisher,
                                        Book,
                                        formset=BaseBooksWithImagesFormset,
                                        fields=('title',),
                                        extra=1)
views.py:
from django.http import HttpResponseRedirect
from django.views.generic import FormView
from django.views.generic.detail import SingleObjectMixin
from .forms import PublisherBooksWithImagesFormset
from .models import Publisher, Book, BookImage
class PublisherUpdateView(SingleObjectMixin, FormView):
    model = Publisher
    success_url = 'publishers/updated/'
    template_name = 'publisher_update.html'
    def get(self, request, *args, **kwargs):
        # The Publisher whose Books we're editing:
        self.object = self.get_object(queryset=Publisher.objects.all())
        return super().get(request, *args, **kwargs)
    def post(self, request, *args, **kwargs):
        # The Publisher whose Books we're editing:
        self.object = self.get_object(queryset=Publisher.objects.all())
        return super().post(request, *args, **kwargs)
    def get_form(self, form_class=None):
        "Use our formset of formsets, and pass in the Publisher object."
        return PublisherBooksWithImagesFormset(
                            **self.get_form_kwargs(), instance=self.object)
    def form_valid(self, form):            
        form.save()
        return HttpResponseRedirect(self.get_success_url())
templates/publisher_update.html:
{% extends 'base.html' %}
{% block content %}
  <form action="" method="post" enctype="multipart/form-data">
    {% for hidden_field in form.hidden_fields %}
      {{ hidden_field.errors }}
      {{ hidden_field }}
    {% endfor %}
    {% csrf_token %}
    {{ form.management_form }}
    {{ form.non_form_errors }}
    {% for book_form in form.forms %}
      {# Output a Book form. #}
      {% for hidden_field in book_form.hidden_fields %}
        {{ hidden_field.errors }}
      {% endfor %}
      <table>
        {{ book_form.as_table }}
      </table>
      {# Check if our `nested` property exists, with BookImage forms in it. #}
      {% if book_form.nested %}
          {{ book_form.nested.management_form }}
          {{ book_form.nested.non_form_errors }}
            {% for bookimage_form in book_form.nested.forms %}
              {# Output the BookImage forms for this Book. #}
              {% for hidden_field in bookimage_form.hidden_fields %}
                {{ hidden_field.errors }}
              {% endfor %}
              <table>
                {{ bookimage_form.as_table }}
              </table>
            {% endfor %}
      {% endif %}
    {% endfor %}
    <input type="submit" value="Update books">
  </form>
{% endblock content %}