def METHOD_NAME(self, srid, geom):
    if not geom.srid:
        geom.srid = int(srid)
    if geom.srid != settings.SRID:
        try:
            geom.transform(settings.SRID)
        except GDALException:
            raise CommandError("SRID is not well configurate, change/add option srid")