Giter VIP home page Giter VIP logo

Comments (3)

flottman avatar flottman commented on May 23, 2024

yep. It's a known issue. You're going to have to make the circuit fit a numpy value

image

from pyeis.

flottman avatar flottman commented on May 23, 2024

You might just want to grab n-block's version. He seems to be on top of things
(https://github.com/n-bock/PyEIS)

from pyeis.

gimdeokhwan avatar gimdeokhwan commented on May 23, 2024

I've fixed the this issue, but have no authority of "pull request"
but I've tested attached code, works well.

Reason why issue happened is self.KK_circuit_fit[i].real and self.KK_circuit_fit[i].imag not aligned to array data format.

so it should be changed following
(I'm in office so not possible to upload the screen shot and code)

    #changed by Gim
        length_of_kk_circuit_fit = len(self.KK_circuit_fit[i])
        KK_circuit_fit_real = []
        KK_circuit_fit_imag = []
        for idx in range(length_of_kk_circuit_fit):
            KK_circuit_fit_real.append(self.KK_circuit_fit[i][idx+length_of_kk_circuit_fit].real)
            KK_circuit_fit_imag.append(self.KK_circuit_fit[i][idx + length_of_kk_circuit_fit].imag)

        KK_circuit_fit_real = np.array(KK_circuit_fit_real)
        KK_circuit_fit_imag = np.array(KK_circuit_fit_imag)
        self.KK_rr_re.append(residual_real(re=self.df[i].re, fit_re=KK_circuit_fit_real, fit_im=-KK_circuit_fit_imag))#relative residuals for the real part
        self.KK_rr_im.append(residual_imag(im=self.df[i].im, fit_re=KK_circuit_fit_real, fit_im=-KK_circuit_fit_imag)) #relative residuals for the imag part
        # changed by Gim

        #self.KK_rr_re.append(residual_real(re=self.df[i].re, fit_re=self.KK_circuit_fit[i].real, fit_im=-self.KK_circuit_fit[i].imag)) #relative residuals for the real part
        #self.KK_rr_im.append(residual_imag(im=self.df[i].im, fit_re=self.KK_circuit_fit[i].real, fit_im=-self.KK_circuit_fit[i].imag)) #relative residuals for the imag part

from pyeis.

Related Issues (11)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.