Skip to content

RC-ELM cannot predict more than one test instance #1

@FabianoVeglianti

Description

@FabianoVeglianti

In the RC-ELM.py file you provided you used a single test instance to test the RCELMModel implementation, but things go wrong as soon as you use more than one test instance.

In the following code I just replicated 3 times the single test instance you provided and I check for the same number of features in the train and testing batch of data

X_test = np.array([[0, 0.455, 0.365, 0.095, 0.514, 0.2245, 0.101, 0.15],[0, 0.455, 0.365, 0.095, 0.514, 0.2245, 0.101, 0.15],[0, 0.455, 0.365, 0.095, 0.514, 0.2245, 0.101, 0.15]])
X_test = X_test.reshape(3, -1)
print(X.shape)
print(X_test.shape)

This is the error:

(4176, 8)
(3, 8)
...
tensorflow.python.framework.errors_impl.InvalidArgumentError: {{function_node __wrapped__Mul_device_/job:localhost/replica:0/task:0/device:CPU:0}} Incompatible shapes: [2,4176,1] vs. [2,3,1] [Op:Mul] name:

I suspect there is a problem in how the model handles the lambdas...

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions