Skip to content

DoodleClassifier: Path to data/sqlite3 image-net-file seems to be off #22

@HerrBertling

Description

@HerrBertling

Some train of thought and exploration about this issue with the relevant question at the end 😉 🚂

I get this error when trying to "Add samples": Thread 1: EXC_BAD_ACCESS (code=1, address=0x18)

Up until then, I can adjust the threshold, min/max and
It seems to happen here in the "hack" line, as far as I can tell from what XCode highlights:

vector<float> ofxCcv::encode(const ofPixels& pix, int layer) const {
    convnet->count = layer; // hack to extract a particular layer with encode

    ccv_dense_matrix_t image;

My app is in a different folder than the openFramework stuff, but from what I understood, this shouldn't be a problem.

Also, the XCode console says:

[ error ] Can't find network file ../../../data/../../../../data/image-net-2012.sqlite3
[notice ] Adding samples...

which I already wondered about since it is a relative path to a file.

Using the ml4a-ofx/apps/DoodleClassifier folder with adjustments to the .xml file produces the same error.

Running sh setup.sh did create the image-net-2012.sqlite3 file – not within data but directly within ml4a-ofx. Adjusting the path to that file in https://github.com/ml4a/ml4a-ofx/blob/master/apps/DoodleClassifier/src/ofApp.cpp#L22 (which would then say ccv.setup(ofToDataPath("../../../../image-net-2012.sqlite3")); apparently fixes this issue.

Is this path wrong in general or am I holding it wrong and my setup needs to be fixed? 😊

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions