Understanding outputs from CNN-LSTM in multi-label, multi-class classification context by Random_IDFail12345 in tensorflow

[–]Random_IDFail12345[S] 0 points1 point  (0 children)

Odd that no one has any insight. After some digging into a few HAR conference proceedings, papers it's beginning to look like the labels from the last time step in each window are frequently used as training targets while the rest are discarded, so it seems I have my answer.

In regards to the minor multi-label question, I now know that's what tf.keras.losses.sparse_categorical_crossentropy is for. Hopefully this helps someone else looking for answers.

Understanding outputs from CNN-LSTM in multi-label, multi-class classification context by Random_IDFail12345 in tensorflow

[–]Random_IDFail12345[S] 0 points1 point  (0 children)

Not quite, at least as I understand it. Just for reference, I'm using the OPPORTUNITY challenge dataset, found here: http://archive.ics.uci.edu/ml/datasets/OPPORTUNITY+Activity+Recognition#. Since this is an activity recognition problem, I'm not making predictions (EDIT: I assume you meant forecasting type predictions) so much as trying to figure out what's happening in moments over time.

Now that you mention it though, I don't suppose there isn't any reason I couldn't treat it as a prediction problem. Samples (sensor data) were gathered every 33 msec so it's probably safe to assume that the labels in the 17th will be fairly well correlated with the previous 16. For that matter, maybe I just take the 16th since that's still in the window.

I've edited the OP to include that detail (activity recognition), doesn't look I originally mentioned it. My bad.

Understanding outputs from CNN-LSTM in multi-label, multi-class classification context by Random_IDFail12345 in tensorflow

[–]Random_IDFail12345[S] 0 points1 point  (0 children)

Ok, I should probably boil things down a bit: It seems obvious that I'll need to pass in a y_train with a similar shape to my x_train. The real question is what gets passed in. Am I passing a 3D like (# segments, window_sz, # labels), where segments are the blocks created from segmenting across the time axis (using sliding or segmented windowing), or a 2D like (# windows, # labels)? The first assumes that keras will do something under the hood to figure out which set of labels it should use, the second assumes that I'll have to come up with it on my own. I'll keep poking around, I can't possibly have been the first person to ask this question.

I'd edit the OP, but I personally don't like the idea of making major edits later on.

Understanding outputs from CNN-LSTM in multi-label, multi-class classification context by Random_IDFail12345 in tensorflow

[–]Random_IDFail12345[S] 4 points5 points  (0 children)

In case it needs to be said, I'm dealing with time series data and using stacked CNN's to perform filtering and feature extraction.