MCPcopy Create free account
hub / github.com/davisking/dlib / mat_row__getitem__

Function mat_row__getitem__

tools/python/src/matrix.cpp:162–173  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

160}
161
162double mat_row__getitem__(mat_row& m, long r)
163{
164 if (r < 0) {
165 r = m.size + r; // negative index
166 }
167 if (r > m.size-1 || r < 0) {
168 PyErr_SetString( PyExc_IndexError, "1 index out of range"
169 );
170 throw py::error_already_set();
171 }
172 return m.data[r];
173}
174
175mat_row matrix_double__getitem__(matrix<double>& m, long r)
176{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected