You can create one material per polygon and assign all the materials using [`MeshPolygon.material_index`][1]. --- I'd suggest create a dictionary based on the actual *face id* and the *image path* beforehand: images_per_polygon = { 0: "city.exr", 1: "courtyard.exr", 2: "forest.exr", 3: "interior.exr", 4: "night.exr", 5: "studio.exr" ... } Then iterate through all [`Mesh.polygons`][3], create a material based on the current index, create the relevant nodes, load and assign the image using [`BlendDataImages.load()`][4] and assign each material to the polygons properly. [![enter image description here][2]][2] Demo on how to setup one image per polygon using the *default cube* and the *built-in hdris* based on https://blender.stackexchange.com/questions/201412/how-to-load-an-image-from-disc-and-assign-it-to-a-newly-created-image-texture-no and https://blender.stackexchange.com/questions/235501/how-can-i-get-the-filepaths-of-all-default-built-in-hdris (6 faces hence 6 images). Make sure the filepaths are correct, the object is selected and run the script: import bpy # Get a reference to the object in context # -> https://blender.stackexchange.com/a/239102/ obj = bpy.context.object # Create the dict images_per_polygon = { 0: "/Applications/Blender.app/Contents/Resources/2.93/datafiles/studiolights/world/city.exr", 1: "/Applications/Blender.app/Contents/Resources/2.93/datafiles/studiolights/world/courtyard.exr", 2: "/Applications/Blender.app/Contents/Resources/2.93/datafiles/studiolights/world/forest.exr", 3: "/Applications/Blender.app/Contents/Resources/2.93/datafiles/studiolights/world/interior.exr", 4: "/Applications/Blender.app/Contents/Resources/2.93/datafiles/studiolights/world/night.exr", 5: "/Applications/Blender.app/Contents/Resources/2.93/datafiles/studiolights/world/studio.exr" } # Remove all material slots from the object # -> https://blender.stackexchange.com/a/146719/ obj.active_material_index = 0 for i in range(len(obj.material_slots)): bpy.ops.object.material_slot_remove({'object': obj}) # Create (if not present) the materials and assign them per polygon for c, p in enumerate(obj.data.polygons): image = images_per_polygon.get(c) if image: # Create the material based on the name if not present # -> https://blender.stackexchange.com/a/23434 mat_name = "Mat{}".format(c) mat = bpy.data.materials.get(mat_name) if not mat: mat = bpy.data.materials.new(mat_name) # Append the materials to the slots and assign each per polygon obj.data.materials.append(mat) p.material_index = c # Material Properties # -> https://blender.stackexchange.com/q/23436/31447 mat.use_nodes = True nodes = mat.node_tree.nodes nodes.clear() # Create Principled Shader node node_principled = nodes.new(type='ShaderNodeBsdfPrincipled') node_principled.location = 0,0 # Create Image Texture node # -> https://blender.stackexchange.com/a/201414 node_tex = nodes.new('ShaderNodeTexImage') # Assign the image node_tex.image = bpy.data.images.load(image) node_tex.location = -400,0 # Create Output node node_output = nodes.new(type='ShaderNodeOutputMaterial') node_output.location = 400,0 # Link all nodes links = mat.node_tree.links link = links.new(node_tex.outputs["Color"], node_principled.inputs["Base Color"]) link = links.new(node_principled.outputs["BSDF"], node_output.inputs["Surface"]) **Further reading** - https://blender.stackexchange.com/questions/28589/meshs-material-index-is-an-index-into-what - https://blender.stackexchange.com/questions/201412/how-to-load-an-image-from-disc-and-assign-it-to-a-newly-created-image-texture-no - https://blender.stackexchange.com/questions/23433/how-to-assign-a-new-material-to-an-object-in-the-scene-from-python - https://blender.stackexchange.com/questions/23436/control-cycles-eevee-material-nodes-and-material-properties-using-python - https://blender.stackexchange.com/questions/146714/removing-all-material-slots-in-one-go - https://blender.stackexchange.com/questions/235501/how-can-i-get-the-filepaths-of-all-default-built-in-hdris [1]: https://docs.blender.org/api/current/bpy.types.MeshPolygon.html?highlight=polygon%20material_index#bpy.types.MeshPolygon.material_index [2]: https://i.sstatic.net/SH5Iv.png [3]: https://docs.blender.org/api/current/bpy.types.Mesh.html?highlight=data%20polygons#bpy.types.Mesh.polygons [4]: https://docs.blender.org/api/current/bpy.types.BlendDataImages.html?highlight=load#bpy.types.BlendDataImages.load