(PECL fann >= 1.0.0)
fann_read_train_from_file — ��ȡ�洢ѵ�����ݵ��ļ���
$filename
) : resource��ȡ�洢ѵ�����ݵ��ļ���
filename
�����ļ��ĸ�ʽ����:
num_train_data num_input num_output inputdata seperated by space outputdata seperated by space . . . inputdata seperated by space outputdata seperated by space
Returns a train data resource on success, or FALSE
on error.
Example #1 fann_read_train_from_file() ������ʹ�÷�����
<?php
$train_data = fann_read_train_from_file("xor.data");
if ($train_data) {
// Do something with $train_data for XOR function
}
?>
xor.data �ļ������ݣ�
4 2 1 -1 -1 -1 -1 1 1 1 -1 1 1 1 -1