(i, ind_l, landmark, weight)
| 15 | |
| 16 | |
| 17 | def process_observation(i, ind_l, landmark, weight): |
| 18 | # # Get indices for observation i |
| 19 | # ind_l = ind.indices |
| 20 | # ind = ind.data - 1 # Adjust for zero-based indexing |
| 21 | |
| 22 | # Compute weighted landmarks |
| 23 | v = landmark * weight[:, None] |
| 24 | |
| 25 | # Calculate blocks to update the sparse matrices |
| 26 | Q1_block = v.T @ landmark |
| 27 | V1_block = v.sum(axis=0)[:, None] |
| 28 | V2_block = v.T |
| 29 | |
| 30 | # Return the computed blocks with their indices |
| 31 | return i, Q1_block, V1_block, V2_block, ind_l |
| 32 | |
| 33 | |
| 34 | def process_observation_old(i, observation_index, landmarks, weight): |
nothing calls this directly
no outgoing calls
no test coverage detected