Skip to content

BaseCircuit.predict() won't take float as input #277

@Yugal0

Description

@Yugal0

BaseCiruit.predict() only accepts a nd.array as an input,
hence the frequency data need to be compulsory supplied as an array
But If I want to predict the impedance at a particular frequency, then BaseCircuit.predict() should also accept a single float value instead of forcing me to write it as an array containing a single element. or exampl
For example-
from impedance.models.circuits import CustomCircuit
RC_parallel=CustomCircuit("p(R0,C0)",initial_guess=[1e2,1e-3])

print(RC_parallel.predict([9]))
and
print(RC_parallel.predict(9))

should both be valid.

But as of now, the print(RC_parallel.predict(9)) gives error.

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