def as_dict(self): d = { to_camel_case(c.name): getattr(self, c.name) for c in self.__table__.columns } d["operators"] = self.operators return d
def as_dict(self): d = { to_camel_case(c.name): getattr(self, c.name) for c in self.__table__.columns } d["experiments"] = self.experiments return d
def as_dict(self): d = { to_camel_case(c.name): getattr(self, c.name) for c in self.__table__.columns } d["parameters"] = read_parameters(self.experiment_notebook_path) return d
def as_dict(self): d = { to_camel_case(c.name): getattr(self, c.name) for c in self.__table__.columns } del d["tasks"] d["operators"] = [{"taskId": o} for i, o in enumerate(self.tasks)] return d
def as_dict(self): d = { to_camel_case(c.name): getattr(self, c.name) for c in self.__table__.columns } status = getattr(self, 'status', None) if status: d["status"] = status return d
def as_dict(self): d = { to_camel_case(c.name): getattr(self, c.name) for c in self.__table__.columns } return d
def test_to_camel_case(self): snake = "test_to_camel_case" camel = "testToCamelCase" self.assertEqual(utils.to_camel_case(snake), camel)