How to Solve NameError: name 'product' is not defined -- itertools
Solution: Import the 'product' module
To Solve the error, add the following line to the top of your code.
from itertools import product
For more information:
Python itertools product