KenKundert / psf_utils

Read Spectre PSF files
49 stars 14 forks source link

fix an exception: unknown keyword 'N' #18

Closed booknouse closed 7 months ago

booknouse commented 7 months ago

Use functions to increase the priority of t_NAN to avoid an unknown keyword 'N' exception。 try 'phaseMargin' signal with ascii file:

HEADER "PSFversion" "1.00" "simulator" "spectre" "version" "18.1.0.077" "date" "11:40:59 AM, Mon Jan 15, 2024" "design" "" "analysis type" "margin.stb" "analysis name" "stb" "analysis description" "Stability Analysis `stb': freq = (1 uHz -> 1 GHz)" "xVecSorted" "ascending" "tolerance.relative" 0.00100000 "operating point producer" "stb" "probe" "IPRB0" "gainMarginInfo" "Gain(dB)is always less than zero. The loop is always stable. No gain margin or phase margin." TYPE "dB" FLOAT DOUBLE PROP( "key" "gain" "units" "dB" ) "Deg" FLOAT DOUBLE PROP( "key" "gain" "units" "Deg" ) "Hz" FLOAT DOUBLE PROP( "key" "gain" "units" "Hz" ) "stbstate" STRING * VALUE "gainMargin" "dB" NaN PROP( "gainMarginInfo" "Gain(dB)is always less than zero. The loop is always stable. No gain margin or phase margin." ) "gainMarginFreq" "Hz" NaN "phaseMargin" "Deg" NaN PROP( "phaseMarginInfo" "" ) "phaseMarginFreq" "Hz" NaN "stb_state" "stbstate" "Gain(dB)is always less than zero. The circuit is always stable. No gain margin or phase margin." END

KenKundert commented 7 months ago

Thank you. In addition to accepting your pull request I have also added your test case to the tests.

Let me know if you are expecting to submit any more bug reports or pull requests. If not, I will push this version to PyPi.

booknouse commented 7 months ago

My pleasure! No more bug reports or pull requests at the moment, but I will continue to submit if new problems are found in the future.

Thank you. In addition to accepting your pull request I have also added your test case to the tests.

Let me know if you are expecting to submit any more bug reports or pull requests. If not, I will push this version to PyPi.