Source identity
| Field | Recorded value |
|---|---|
| Source type | GitHub source |
| Original record | Janady13/seferim-agi-g16 / bindings/c/abi.cpp |
| Date | Not specified in source |
| Repository | Janady13/seferim-agi-g16 |
| Revision | 25f281b08b2f786f5a235b5abebfc39bf44d1044 |
| Branch | main |
| Path or archive member | bindings/c/abi.cpp |
| Original SHA-256 | d019a27f2bfca79733b3a7fcb92855b6816b952b5d2f16ab9990b6c905cbff35 |
| Git blob SHA | be35fa73d04cd9641d08301301d4927358e8faee |
| Reading-copy SHA-256 | d019a27f2bfca79733b3a7fcb92855b6816b952b5d2f16ab9990b6c905cbff35 |
Every recorded occurrence
These 2 records contain identical original source bytes. Their paths and revisions remain part of the archive.
| Original record | Branch or archive | Revision / identifier | Original location |
|---|---|---|---|
| Janady13/seferim-agi-g16 / bindings/c/abi.cpp | main | 25f281b08b2f786f5a235b5abebfc39bf44d1044 | Open original |
| Janady13/seferim-agi-g16 / bindings/c/abi.cpp | copilot/update-code-libraries | 393af96a270295f79582b2b2a77bb49dd1a9a990 | Open original |
Recovered source transcript
Download complete source text ↓36 lines · 0.9 KB
#include "abi.h"
using namespace common;
extern "C" {
void g16_update(const g16_meta_state_c* s_t,
const g16_meta_state_c* s_tm1,
const g16_inputs_c* in_c,
g16_meta_state_c* out) {
MetaState st{}, stm1{};
for (int i = 0; i < 17; ++i) {
st.g[i] = s_t->g[i];
stm1.g[i] = s_tm1->g[i];
}
st.coherence = s_t->coherence;
st.value = s_t->value;
st.uncertainty = s_t->uncertainty;
stm1.coherence = s_tm1->coherence;
stm1.value = s_tm1->value;
stm1.uncertainty = s_tm1->uncertainty;
Inputs in{};
in.dx_norm = in_c->dx_norm;
in.ed_error = in_c->ed_error;
in.utility = in_c->utility;
in.stability = in_c->stability;
MetaState res = update_meta_state(st, stm1, in);
for (int i = 0; i < 17; ++i) out->g[i] = res.g[i];
out->coherence = res.coherence;
out->value = res.value;
out->uncertainty = res.uncertainty;
}
}