[docs]@save_object.register@validate_savesdefsave_string_factor(x:Factor,path:str,**kwargs):"""Method for saving :py:class:`~biocutils.Factor.Factor` objects to their corresponding file representation, see :py:meth:`~dolomite_base.save_object.save_object` for details. Args: x: Object to be saved. path: Path to save the object. kwargs: Further arguments, ignored. Returns: `x` is saved to `path`. """os.mkdir(path)save_object_file(path,"string_factor",{"string_factor":{"version":"1.0"}})withh5py.File(os.path.join(path,"contents.h5"),"w")ashandle:ghandle=handle.create_group("string_factor")save_factor_to_hdf5(ghandle,x)nms=x.get_names()ifnmsisnotNone:strings.save_fixed_length_strings(ghandle,"names",nms.as_list())