Thank you for reporting this. I could reproduce this error and fixed it.
The problem was that in certain scenarios it was possible to get to method in SegmentStatistics module that used vtkSegmentationCore before it was imported. We haven’t detected this issue either in our automatic tests or when manually used the feature because when you run Segment Editor then it imports the library and the error does not occur.
@jcfr - it is yet another example why fixing https://issues.slicer.org/view.php?id=4385 would be important. It would be great if you could have a look at it