Convert RTStruct to DICOM SEG

Hello, how can I convert RTStruct to DICOM Seg? I’m having some difficulties…