-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathFH.h
More file actions
27 lines (24 loc) · 649 Bytes
/
FH.h
File metadata and controls
27 lines (24 loc) · 649 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#ifndef _FH_H
#define _FH_H
#include <iostream>
#include <iomanip>
#include <fstream>
#include <vector>
#include "gdc.h"
class FH {
private:
std::ifstream _file;
std::string _file_name;
const uint _chunksize = _CHUNK_SIZE;
size_t _row_len;
size_t _col_len;
public:
FH(const std::string &filename);
bool eof() { return _file.eof(); }
size_t col_len() { return _col_len; }
size_t row_len() { return _row_len; }
std::vector<float> parse_line_of_floats(const std::string& line);
static size_t total_vector_size(std::vector<std::vector<float> > data);
std::vector<float> read_data_from_file();
};
#endif