SHOGUN  5.0.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules
Macros
StreamingAsciiFile.cpp File Reference

Go to the source code of this file.

Macros

#define GET_VECTOR(fname, conv, sg_type)
 
#define GET_FLOAT_VECTOR(sg_type)
 
#define GET_VECTOR_AND_LABEL(fname, conv, sg_type)
 
#define GET_FLOAT_VECTOR_AND_LABEL(sg_type)
 
#define GET_STRING(fname, conv, sg_type)
 
#define GET_STRING_AND_LABEL(fname, conv, sg_type)
 
#define GET_SPARSE_VECTOR(fname, conv, sg_type)
 
#define GET_SPARSE_VECTOR_AND_LABEL(fname, conv, sg_type)
 

Macro Definition Documentation

#define GET_FLOAT_VECTOR (   sg_type)

Definition at line 123 of file StreamingAsciiFile.cpp.

#define GET_FLOAT_VECTOR_AND_LABEL (   sg_type)

Definition at line 248 of file StreamingAsciiFile.cpp.

#define GET_SPARSE_VECTOR (   fname,
  conv,
  sg_type 
)

Definition at line 403 of file StreamingAsciiFile.cpp.

#define GET_SPARSE_VECTOR_AND_LABEL (   fname,
  conv,
  sg_type 
)

Definition at line 497 of file StreamingAsciiFile.cpp.

#define GET_STRING (   fname,
  conv,
  sg_type 
)
Value:
void CStreamingAsciiFile::get_string(sg_type*& vector, int32_t& len) \
{ \
char* buffer = NULL; \
ssize_t bytes_read; \
\
bytes_read = buf->read_line(buffer); \
\
if (bytes_read<=1) \
{ \
vector=NULL; \
len=-1; \
return; \
} \
SG_DEBUG("Line read from the file:\n%s\n", buffer) \
/* Remove the terminating \n */ \
if (buffer[bytes_read-1]=='\n') \
{ \
len=bytes_read-1; \
buffer[bytes_read-1]='\0'; \
} \
else \
len=bytes_read; \
vector=(sg_type *) buffer; \
}
#define SG_RESET_LOCALE
Definition: SGIO.h:86
#define SG_SET_LOCALE_C
Definition: SGIO.h:85
#define SG_DEBUG(...)
Definition: SGIO.h:107

Definition at line 289 of file StreamingAsciiFile.cpp.

#define GET_STRING_AND_LABEL (   fname,
  conv,
  sg_type 
)

Definition at line 336 of file StreamingAsciiFile.cpp.

#define GET_VECTOR (   fname,
  conv,
  sg_type 
)

Definition at line 39 of file StreamingAsciiFile.cpp.

#define GET_VECTOR_AND_LABEL (   fname,
  conv,
  sg_type 
)

Definition at line 162 of file StreamingAsciiFile.cpp.


SHOGUN Machine Learning Toolbox - Documentation