generate s2object model