Skip to content

GetNextBatch img4.shape[1] issue #77

@Bushpilot2112

Description

@Bushpilot2112

In this function:

(NDArray, NDArray) GetNextBatch(Session sess, string[] x, NDArray y, int start, int end)

The part of the code:

for (int i = start; i < end; i++)
{
NDArray img4 = cv2.imread(x[i], IMREAD_COLOR.IMREAD_GRAYSCALE);
img4 = img4.reshape((img4.shape[0], img4.shape[1], 1));
x_batch[n] = sess.run(normalized, (decodeJpeg, img4));
n++;
}

This line:

img4 = img4.reshape((img4.shape[0], img4.shape[1], 1));

There is an issue with the "img4.shape[1]" being empty. "img4.shape[0]" has a value. When the loop runs at no point the "img4.shape[1]" get set.

Any idea or assistance on this one.

Thanks
Ken

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions