You can use the docsx2python python module for this.
Firstly, install the module by running the following command:
pip install docx2python
Now just run the following code:
from docx2python import docx2python
content = docx2python('my_document.docx', 'output_image_directory')
The extracted images will be stored in the directory you passed in as the second argument.