The way you get the model out of the dataset is by using :
val model = fpgrowth.fit(dataset)
I think the fit method computes the tre
fit