<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _model_params2table(self, fit_model, star_group_size):
 """ Place fitted parameters into an astropy table. Parameters fit_model : `astropy.modeling.Fittable2DModel` instance PSF or PRF model to fit the data. Could be one of the models in this package like `~photutils.psf.sandbox.DiscretePRF`, `~photutils.psf.IntegratedGaussianPRF`, or any other suitable 2D model. star_group_size : int Number of stars in the given group. Returns ------- param_tab : `~astropy.table.Table` Table that contains the fitted parameters. """


        param_tab = Table()

        for param_tab_name in self._pars_to_output.keys():
            param_tab.add_column(Column(name=param_tab_name,
                                        data=np.empty(star_group_size)))

        if star_group_size > 1:
            for i in range(star_group_size):
                for param_tab_name, param_name in self._pars_to_output.items():
                    param_tab[param_tab_name][i] = getattr(fit_model,
                                                           param_name +
                                                           '_' + str(i)).value
        else:
            for param_tab_name, param_name in self._pars_to_output.items():
                param_tab[param_tab_name] = getattr(fit_model, param_name).value

        return param_tab