First off, I should mention that I patched the matplotlib's fontmanager.py according to the 'Error on import matplotlib.pyplot (on Anaconda3 for Windows 10 Home 64-bit PC)'. I am using Windows 10 and python3.5.2 and was just running super simple plotting using matplotlib in ipython notebook. The code is presented below.
import numpy as np
import matplotlib.pyplot as plt
num_points = 1000
vectors_set = []
for i in range(num_points):
x1 = np.random.normal(0.0, 0.55)
y1 = x1*0.1 + 0.3 + np.random.normal(0.0, 0.03)
vectors_set.append([x1, y1])
x_data =[v[0] for v in vectors_set]
y_data =[v[1] for v in vectors_set]
plt.plot(x_data, y_data)
plt.show()
But I still get the same error. Here's my error messages.
c:\python35\lib\site-packages\matplotlib\font_manager.py in findSystemFonts(fontpaths, fontext)
323 fontpaths = [fontdir]
324 # now get all installed fonts directly...
--> 325 for f in win32InstalledFonts(fontdir):
326 base, ext = os.path.splitext(f)
327 if len(ext)>1 and ext[1:].lower() in fontexts:
c:\python35\lib\site-packages\matplotlib\font_manager.py in win32InstalledFonts(directory, fontext)
239 if not os.path.dirname(direc):
240 direc = os.path.join(directory, direc)
--> 241 direc = direc.split('\0', 1)[0]
242 if os.path.splitext(direc)[1][1:] in fontext:
243 items[direc] = 1
c:\python35\lib\ntpath.py in abspath(path)
533 if path: # Empty path must return current working directory.
534 try:
--> 535 path = _getfullpathname(path)
536 except OSError:
537 pass # Bad path - return unchanged.
ValueError: _getfullpathname: embedded null character
At line 241, it says:
direc = direc.split('\0', 1)[0]
like @simonzack suggested.