| 300 | }; |
| 301 | |
| 302 | static inline NPY_DATETIMEUNIT NumPyFrequency(TimeUnit::type unit) { |
| 303 | switch (unit) { |
| 304 | case TimestampType::Unit::SECOND: |
| 305 | return NPY_FR_s; |
| 306 | case TimestampType::Unit::MILLI: |
| 307 | return NPY_FR_ms; |
| 308 | break; |
| 309 | case TimestampType::Unit::MICRO: |
| 310 | return NPY_FR_us; |
| 311 | default: |
| 312 | // NANO |
| 313 | return NPY_FR_ns; |
| 314 | } |
| 315 | } |
| 316 | |
| 317 | static inline int NumPyTypeSize(int npy_type) { |
| 318 | npy_type = fix_numpy_type_num(npy_type); |
no outgoing calls
no test coverage detected