Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fann_train_on_file does not set error on bad input training file data #69

Open
jjYBdx4IL opened this issue Jun 16, 2016 · 5 comments · May be fixed by #71
Open

fann_train_on_file does not set error on bad input training file data #69

jjYBdx4IL opened this issue Jun 16, 2016 · 5 comments · May be fixed by #71

Comments

@jjYBdx4IL
Copy link

jjYBdx4IL commented Jun 16, 2016

there is an error logged by the parsing function, but that function has no access to the nn struct containing the error. I'm trying to generate exceptions in fannj for fann error conditions and discovered that the user is not able to detect all errors programmatically, ie. without looking at console output or inconveniently redirecting error output.

@joelself
Copy link
Contributor

You don't specify which functions, but both structs fann and fann_train_data can be cast to a fann_error. See my other comment.

@jjYBdx4IL
Copy link
Author

jjYBdx4IL commented Jun 17, 2016

fann_train_on_file() when called with badly formatted training data, for example. And fann_cascadetrain_on_file(). They both just return without giving any indication of an error it seems, when they bail after failing to read the input data.

@joelself
Copy link
Contributor

Do they just segfault? I don't have a machine to test on right now.

@jjYBdx4IL
Copy link
Author

no, they just return and the user (caller) has no chance to detect the error by any reasonable means.

@bukka
Copy link
Member

bukka commented May 19, 2018

I think it makes sense in general to have some way how to identify error on ann when train data cannot be created. There is an error in error log as you know but it might not be always clear and reliable.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants