Comments (5)
The easiest solution seems to be renaming Gs
and Ws
, but the issue really stems from how p_string is constructed in:
def extract_circuit_elements(circuit):
extracted_elements = []
p_string = [x for x in circuit if x not in 'ps(),-/']
from impedance.py.
Ah, so it's because we've used s
to dictate series...
I think there's an elegant way to do this with regular expressions rather than just ignoring characters, but I haven't played around with it much.
from impedance.py.
@BGerwe I think we should just be able to remove s
(since it's never in a circuit string, we use -
) and /
(since we don't us it anymore) from the line you pasted above?
from impedance.py.
That seems to work! Something else I noticed during this, the way elements with >1 parameters is a little confusing now. Ex:
Initial guesses:
R_0 = 1.00e+01 [Ohm]
G_1_0 = 1.00e+02 [Ohm]
G_1_1 = 1.00e-01 [sec]
W_1 = 5.00e+01 [Ohm sec^-1/2]
But we could have it print as
Initial guesses:
R_0 = 1.00e+01 [Ohm]
G_1_p[0] = 1.00e+02 [Ohm]
G_1_p[1] = 1.00e-01 [sec]
W_1 = 5.00e+01 [Ohm sec^-1/2]
without changing much. Are you fine with including that in this issue/PR? This acts funny when you define constants so I won't worry about it.
from impedance.py.
Yeah, I think the double underline is a bit ugly haha. Maybe itβd be nice to have it be something like latex (I.e. Gs_{1,1}).
This does affect a few things though so probably best for a new PR.
from impedance.py.
Related Issues (20)
- [BUG] .append no longer available in pandas > 2.0
- [Element]
- Error in visualization with looping through and fitting multiple data sets HOT 2
- [BUG] Deprecation warnings with Altair v5
- [BUG] Matplotlib warnings when plotting Bode or Nyquist plot HOT 1
- Very confused about fitting HOT 3
- BaseCircuit.predict() won't take float as input
- Confusion with the word "initial_guess" used in CustomCircuit(circuit_string,initial_guess) HOT 1
- Initial_guess HOT 2
- Replace print with proper logging HOT 1
- RC components
- A worked example of .nox Metrohm file reading and pre-processing HOT 3
- high frequency fitting problem HOT 12
- Accuracy of data in .par file about VersaStudio HOT 3
- Ask for help extracting parameter values from fitted circuits HOT 1
- [BUG] error in impedance definition of La-element
- reading data from Excel files
- Circuit Element Unit scalable feature
- Adding Distribution of relaxation times feature HOT 2
- Recommendation for dealing with noisy data?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from impedance.py.