from folium.features import CustomIcon
m = folium.Map(location=[45.372, -121.6972], zoom_start=12, tiles='Stamen Terrain')
icon_image = 'http://leafletjs.com/examples/custom-icons/leaf-red.png'
shadow_image = 'http://leafletjs.com/examples/custom-icons/leaf-shadow.png'
icon = CustomIcon(
icon_image,
icon_size=(38, 95),
icon_anchor=(22, 94),
shadow_image=shadow_image,
shadow_size=(50, 64),
shadow_anchor=(4, 62),
popup_anchor=(-3, -76)
)
marker = folium.Marker(location=[45.3288, -121.6625], icon=icon, popup='Mt. Hood Meadows')
m.add_child(marker)
m.save(os.path.join('results', 'CustomIcon.html'))
m