def do_internal_run(self, initial_count=<NUM_LIT:0>, subblock=None, update_derr=True):
self._inner_run_counter = initial_count; good_step = True<EOL>n_good_steps = <NUM_LIT:0><EOL>CLOG.debug('<STR_LIT>')<EOL>_last_residuals = self.calc_residuals().copy()<EOL>while ((self._inner_run_counter < self.run_length) & good_step &<EOL>(not self.check_terminate())):<EOL><INDENT>if self.check_Broyden_J() and self._inner_run_counter != <NUM_LIT:0>:<EOL><INDENT>self.update_Broyden_J()<EOL><DEDENT>if self.check_update_eig_J() and self._inner_run_counter != <NUM_LIT:0>:<EOL><INDENT>self.update_eig_J()<EOL><DEDENT>er0 = <NUM_LIT:1>*self.error<EOL>delta_vals = self.find_LM_updates(self.calc_grad(),<EOL>do_correct_damping=False, subblock=subblock)<EOL>er1 = self.update_function(self.param_vals + delta_vals)<EOL>good_step = er1 < er0<EOL>if good_step:<EOL><INDENT>n_good_steps += <NUM_LIT:1><EOL>CLOG.debug('<STR_LIT>' % (er0, er1))<EOL>self.update_param_vals(delta_vals, incremental=True)<EOL>self._last_residuals = _last_residuals.copy()<EOL>if update_derr:<EOL><INDENT>self._last_error = er0<EOL><DEDENT>self.error = er1<EOL>_last_residuals = self.calc_residuals().copy()<EOL><DEDENT>else:<EOL><INDENT>er0_0 = self.update_function(self.param_vals)<EOL>CLOG.debug('<STR_LIT>')<EOL>if np.abs(er0 - er0_0) > <NUM_LIT>:<EOL><INDENT>raise RuntimeError('<STR_LIT>')<EOL><DEDENT><DEDENT>self._inner_run_counter += <NUM_LIT:1><EOL><DEDENT>return n_good_steps<EOL>
Takes more steps without calculating J again.

Given a fixed damping, J, JTJ, iterates calculating steps, with
optional Broyden or eigendirection updates. Iterates either until
a bad step is taken or for self.run_length times.
Called internally by do_run_2() but is also useful on its own.

Parameters
----------
    initial_count : Int, optional
        The initial count of the run. Default is 0. Increasing from
        0 effectively temporarily decreases run_length.
    subblock : None or np.ndarray of bools, optional
        If not None, a boolean mask which determines which sub-
        block of parameters to run over. Default is None, i.e.
        all the parameters.
    update_derr : Bool, optional
        Set to False to not update the variable that determines
        delta_err, preventing premature termination through errtol.

Notes
-----
It might be good to do something similar to update_derr with the
parameter values, but this is trickier because of Broyden updates
and _fresh_J.