diff trunk/matlab/bmm/carfac/CARFAC_Close_AGC_Loop.m @ 561:3dff17554c6d

add an ears array level everywhere
author dicklyon@google.com
date Mon, 23 Apr 2012 22:58:40 +0000
parents 95a11cca4619
children 3e2e0ab4f708
line wrap: on
line diff
--- a/trunk/matlab/bmm/carfac/CARFAC_Close_AGC_Loop.m	Mon Apr 23 21:02:04 2012 +0000
+++ b/trunk/matlab/bmm/carfac/CARFAC_Close_AGC_Loop.m	Mon Apr 23 22:58:40 2012 +0000
@@ -24,12 +24,12 @@
 decim1 = CF.AGC_params.decimation(1);
 
 for ear = 1:CF.n_ears
-  extra_damping = CF.AGC_state(ear).AGC_memory(:, 1);  % stage 1 result
+  extra_damping = CF.ears(ear).AGC_state.AGC_memory(:, 1);  % stage 1 result
   % Update the target stage gain for the new damping:
-  new_g = CARFAC_Stage_g(CF.CAR_coeffs, extra_damping);
+  new_g = CARFAC_Stage_g(CF.ears(ear).CAR_coeffs, extra_damping);
   % set the deltas needed to get to the new damping:
-  CF.CAR_state(ear).dzB_memory = ...
-    (extra_damping - CF.CAR_state(ear).zB_memory) / decim1;
-  CF.CAR_state(ear).dg_memory = ...
-    (new_g - CF.CAR_state(ear).g_memory) / decim1;
+  CF.ears(ear).CAR_state.dzB_memory = ...
+    (extra_damping - CF.ears(ear).CAR_state.zB_memory) / decim1;
+  CF.ears(ear).CAR_state.dg_memory = ...
+    (new_g - CF.ears(ear).CAR_state.g_memory) / decim1;
 end