Fleet  0.0.9
Inference in the LOT
HumanDatum.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <map>
4 
14 template<typename HYP,
15  typename _input_t=typename HYP::input_t,
16  typename _output_t=typename HYP::output_t,
17  typename _response_t=std::vector<std::pair<_output_t,size_t>>,
18  typename _data_t=typename HYP::data_t>
19 struct HumanDatum {
20  using data_t = _data_t;
21  using input_t = _input_t;
22  using output_t = _output_t;
23  using response_t = _response_t;
24 
25  data_t* const data;
26  const size_t ndata; // we condition on the first ndata points in data (so we can point to a single stored data)
27  input_t* const predict; // what we compute on now
28  const response_t responses; // vector giving how many of each type of response you see
29  const double chance; // how many responses are alltogether possible? Needed for chance responding.
30  std::vector<int>* const decay_position; // a pointer to memory decay positions for each of ndata (i'th point is decayed (my_decay_position-decay_position[i])**(-decay))
31  const int decay_index; // what position was I in terms of decay?
32 };
33 
34 
35 
37 // * @class HumanDataSeries
38 // * @author Steven Piantadosi
39 // * @date 02/12/23
40 // * @file HumanDatum.h
41 // * @brief A human data series contains a list of human data points, some of which may be presented at the same "position" (meaning there is no decay between)
42 // */
43 //struct HumanDataSeries {
44 // std::vector<int> decay_position;
45 // std::vector<HumanDatum> hd;
46 // int max_decay_position = 0;
47 //
48 //
49 // void add(HumanDatum& d, int decaypos) {
50 // decay_position.push_back(decaypos);
51 // hd.push_back(d);
52 // max_decay_position = std::max(max_decay_position, decaypos);
53 // }
54 //
55 // /**
56 // * @brief Returns the decay time in computing the likelihood for the n'th data point, using the i'th back
57 // * @param n
58 // * @param i
59 // * @return
60 // */
61 // size_t decay_t(size_t n, size_t i) {
62 // return decay_position.at(n)-decay_position.at(i);
63 // }
64 //
65 // size_t size() {
66 // return hd.size();
67 // }
68 //
69 //}
const double chance
Definition: HumanDatum.h:29
data_t *const data
Definition: HumanDatum.h:25
_data_t data_t
Definition: HumanDatum.h:20
const size_t ndata
Definition: HumanDatum.h:26
std::vector< int > *const decay_position
Definition: HumanDatum.h:30
input_t *const predict
Definition: HumanDatum.h:27
_response_t response_t
Definition: HumanDatum.h:23
_input_t input_t
Definition: HumanDatum.h:21
_output_t output_t
Definition: HumanDatum.h:22
Definition: HumanDatum.h:19
const int decay_index
Definition: HumanDatum.h:31
const response_t responses
Definition: HumanDatum.h:28