ppsd.times error

Hello all,
I am following this tutorial (https://docs.obspy.org/tutorial/code_snippets/probabilistic_power_spectral_density.html) to calculate PPSDs and getting the following error. Can someone please tell me how I could fix it? Thanks very much!

print(ppsd.times[:2])