开云体育

Execute .meas file


 

开云体育

  1. Which temporary file(s) do we need to keep, if we want to return to a model and execute one of several .meas scripts?
  2. Is there a way (maybe in batch mode?) to execute a meas script without re-running the simulation?

I have several worst-case analysis models that take at least several minutes to run (8, 9, + variables).

I’d like to run the meas scripts to extract different sets of measurements, drawn from one Run.

At least in XVII, the Execute script command is only under the File menu on the Plot page…

?

Thanks,

Dave

?

?


 

I am not in the habit of running .MEAS scripts, so my answers may or may not help
?
Bell, Dave wrote:
  1. Which temporary file(s) do we need to keep, if we want to return to a model and execute one of several .meas scripts?
I would not think you need any temporary files.? I could be wrong, but I think you need only the .MEAS script files themselves, and of course the .RAW output file.

2. Is there a way (maybe in batch mode?) to execute a meas script without re-running the simulation?
If you come back to a previously run simulation and want to examine the results without re-running the simulation, use Right-click > View > Visible Traces.? That loads the .RAW file back into LTspice and you should be back to where you were when the simulation completed.? I'm assuming that would be all you need to do before executing .MEAS scripts.
?
The alternative to Right-click is: View (menu bar) > Visible Traces.? The hotkeys are Alt-V-V (in older LTspice versions).
?
Andy
?


 

开云体育

Thanks, Andy!

?

  1. Yeah, the .RAW is what I thought.

But if I rename that with a different extension, it still runs the script.

In the Help. there’s a hint that it can also derive data from the Plot.

  1. Ah-hah!? I will try that.

That would load everything back into memory.

?

?

From: [email protected] <[email protected]> On Behalf Of Andy I via groups.io
Sent: Monday, May 19, 2025 3:33 PM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] Execute .meas file

?

I am not in the habit of running .MEAS scripts, so my answers may or may not help

?

Bell, Dave wrote:

  1. Which temporary file(s) do we need to keep, if we want to return to a model and execute one of several .meas scripts?

I would not think you need any temporary files.? I could be wrong, but I think you need only the .MEAS script files themselves, and of course the .RAW output file.

?

2. Is there a way (maybe in batch mode?) to execute a meas script without re-running the simulation?

If you come back to a previously run simulation and want to examine the results without re-running the simulation, use Right-click > View > Visible Traces.? That loads the .RAW file back into LTspice and you should be back to where you were when the simulation completed.? I'm assuming that would be all you need to do before executing .MEAS scripts.

?

The alternative to Right-click is: View (menu bar) > Visible Traces.? The hotkeys are Alt-V-V (in older LTspice versions).

?

Andy

?


 

You can also open a .RAW file directly into LTspice, and see all your waveforms, and maybe run .MEAS scripts.? But doing it that way, they won't be associated with a schematic.? To re-establish the ability to click on schematic nets to see waveforms, you have to open the schematic first, then View > Visible Traces.
?
I went my first few years using LTspice, not aware that I should do that - until Helmut pointed it out.
?
Andy
?


 

开云体育

I closed LTspice along with the schematic, then opened just the sch.

View, either by right-clicking the schematic, or from the View menu option, has Visible Traces grayed out until a Run.

?

I haven’t yet tried opening a RAW file directly. That’s next…

?

From: [email protected] <[email protected]> On Behalf Of Andy I via groups.io
Sent: Monday, May 19, 2025 5:00 PM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] Execute .meas file

?

You can also open a .RAW file directly into LTspice, and see all your waveforms, and maybe run .MEAS scripts.? But doing it that way, they won't be associated with a schematic.? To re-establish the ability to click on schematic nets to see waveforms, you have to open the schematic first, then View > Visible Traces.

?

I went my first few years using LTspice, not aware that I should do that - until Helmut pointed it out.

?

Andy

?


 

开云体育

To follow up, loading a .raw file directly then works to execute .meas files.

So, answering my original question, after a complete Run, save (in Settings) the raw file(s), or make a copy, while the simulation is still in the app,

Reloading that .raw file gives access to the large data from a long and multipart simulation.

?

Dave

?

From: [email protected] <[email protected]> On Behalf Of Bell, Dave via groups.io
Sent: Monday, May 19, 2025 5:27 PM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] Execute .meas file

?

I closed LTspice along with the schematic, then opened just the sch.

View, either by right-clicking the schematic, or from the View menu option, has Visible Traces grayed out until a Run.

?

I haven’t yet tried opening a RAW file directly. That’s next…

?

From: [email protected] <[email protected]> On Behalf Of Andy I via groups.io
Sent: Monday, May 19, 2025 5:00 PM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] Execute .meas file

?

You can also open a .RAW file directly into LTspice, and see all your waveforms, and maybe run .MEAS scripts.? But doing it that way, they won't be associated with a schematic.? To re-establish the ability to click on schematic nets to see waveforms, you have to open the schematic first, then View > Visible Traces.

?

I went my first few years using LTspice, not aware that I should do that - until Helmut pointed it out.

?

Andy

?


 

Dave,
?
When you loaded the schematic, and View > Visible Traces didn't work, was the .RAW file in the same place?
?
That would make LTspice unable to find it.? That's the only thing I can think of.
?
Andy


 

On Mon, May 19, 2025 at 09:56 PM, Bell, Dave wrote:

So, answering my original question, after a complete Run, save (in Settings) the raw file(s), or make a copy, while the simulation is still in the app,

Reloading that .raw file gives access to the large data from a long and multipart simulation.

Dave, I think you are making this more complicated than it is, by doing it that way.
?
Unless you have your LTspice configured to "Automatically delete .RAW files", uou should never need to make a copy of a .RAW file.? But if you find the need to make a copy, then why delete the original?
?
The only reason to "Automatically delete .RAW files" is if you never ever want to revisit old simulations.? Otherwise, don't do that.? That setting is in Control Panel/Settings > Operation.
?
The .RAW file IS your output data!? It is not just a "temporary" file.? It contains all the waveforms and simulated data (except for what little bit goes into the Error Log file), so deleting it seems pointless.? Without that file, you've lost all your simulated data.
?
View > Visible Traces re-loads the .RAW file data.? If View > Visible Traces is greyed-out,? then there is no .RAW file to load.? That happens either because
  • You have not run the simulation yet,
  • You deleted the .RAW file,
  • You renamed the .RAW file so the original one essentially does not exist,
  • You moved the .RAW file somewhere else.
Clearly you first have to know what you are doing.? If there's no .RAW file, then there is nothing to load.
?
LTspice has a setting (in Control Panel/Settings > Waveforms) to save the output files including .RAW in a specific directory instead of the normal one with the schematic, and I am not sure if or how it affects its ability to find and re-open the .RAW file.? Obviously, if you re-use a schematic filename (e.g., "Draft1", it will overwrite the old .RAW file.? The schematics can be distinct because they were in different folders, but the .RAW files are not because they are all in one big barrel - with that setting.
?

Reloading that .raw file gives access to the large data from a long and multipart simulation.

It does.? Reloading it with its schematic is most ideal - for me, anyway - because it allows you to look at its schematic and pick what you want to plot.? But if your only objective is to re-run a .MEAS script and nothing else, then the only things needed are the .RAW file and the .MEAS scripts.? Yes, you can do that blindly.
?
Andy
?


 

开云体育

Andy, you’re right, across the board.

I do have Automatically Delete raw Files set to avoid accumulating large (sometimes huge) data files that I rarely need to refer to. Most simulations I do are quick to run, or re-run if I do want to dive deeper into logged data.

?

These WCAs I’m working on are unusual in taking minutes to execute and creating very large outputs. My questions about the process and the responses I’ve received have been leading me to making Save exceptions for these runs, and learning just which files are required to revisit prior data for new queries.

?

Thanks for your help!

?

Dave

?

From: [email protected] <[email protected]> On Behalf Of Andy I via groups.io
Sent: Tuesday, May 20, 2025 6:59 AM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] Execute .meas file

?

On Mon, May 19, 2025 at 09:56 PM, Bell, Dave wrote:

So, answering my original question, after a complete Run, save (in Settings) the raw file(s), or make a copy, while the simulation is still in the app,

Reloading that .raw file gives access to the large data from a long and multipart simulation.

Dave, I think you are making this more complicated than it is, by doing it that way.

?

Unless you have your LTspice configured to "Automatically delete .RAW files", uou should never need to make a copy of a .RAW file.? But if you find the need to make a copy, then why delete the original?

?

The only reason to "Automatically delete .RAW files" is if you never ever want to revisit old simulations.? Otherwise, don't do that.? That setting is in Control Panel/Settings > Operation.

?

The .RAW file IS your output data!? It is not just a "temporary" file.? It contains all the waveforms and simulated data (except for what little bit goes into the Error Log file), so deleting it seems pointless.? Without that file, you've lost all your simulated data.

?

View > Visible Traces re-loads the .RAW file data.? If View > Visible Traces is greyed-out,? then there is no .RAW file to load.? That happens either because

  • You have not run the simulation yet,
  • You deleted the .RAW file,
  • You renamed the .RAW file so the original one essentially does not exist,
  • You moved the .RAW file somewhere else.

Clearly you first have to know what you are doing.? If there's no .RAW file, then there is nothing to load.

?

LTspice has a setting (in Control Panel/Settings > Waveforms) to save the output files including .RAW in a specific directory instead of the normal one with the schematic, and I am not sure if or how it affects its ability to find and re-open the .RAW file.? Obviously, if you re-use a schematic filename (e.g., "Draft1", it will overwrite the old .RAW file.? The schematics can be distinct because they were in different folders, but the .RAW files are not because they are all in one big barrel - with that setting.

?

Reloading that .raw file gives access to the large data from a long and multipart simulation.

It does.? Reloading it with its schematic is most ideal - for me, anyway - because it allows you to look at its schematic and pick what you want to plot.? But if your only objective is to re-run a .MEAS script and nothing else, then the only things needed are the .RAW file and the .MEAS scripts.? Yes, you can do that blindly.

?

Andy

?


 

开云体育

BTW, for a quick update

?

This is for one particular WC simulation, a smallish circuit with 9 variables (2**9,+1, 513, executions.)

With Compression normal, Window=1024, the raw file was >206MB.

With Window=0, the raw file is >710MB.

Both cases took almost exactly the same time, to my surprise, 340 seconds.

?

I will probably leave Automatically Delete checked, but before closing a simulation, add a run number, or other code to the Raw file name (leaving the extension alone…)

?

Dave

?

From: [email protected] <[email protected]> On Behalf Of Bell, Dave via groups.io
Sent: Tuesday, May 20, 2025 8:45 AM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] Execute .meas file

?

Andy, you’re right, across the board.

I do have Automatically Delete raw Files set to avoid accumulating large (sometimes huge) data files that I rarely need to refer to. Most simulations I do are quick to run, or re-run if I do want to dive deeper into logged data.

?

These WCAs I’m working on are unusual in taking minutes to execute and creating very large outputs. My questions about the process and the responses I’ve received have been leading me to making Save exceptions for these runs, and learning just which files are required to revisit prior data for new queries.

?

Thanks for your help!

?

Dave

?

From: [email protected] <[email protected]> On Behalf Of Andy I via groups.io
Sent: Tuesday, May 20, 2025 6:59 AM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] Execute .meas file

?

On Mon, May 19, 2025 at 09:56 PM, Bell, Dave wrote:

So, answering my original question, after a complete Run, save (in Settings) the raw file(s), or make a copy, while the simulation is still in the app,

Reloading that .raw file gives access to the large data from a long and multipart simulation.

Dave, I think you are making this more complicated than it is, by doing it that way.

?

Unless you have your LTspice configured to "Automatically delete .RAW files", uou should never need to make a copy of a .RAW file.? But if you find the need to make a copy, then why delete the original?

?

The only reason to "Automatically delete .RAW files" is if you never ever want to revisit old simulations.? Otherwise, don't do that.? That setting is in Control Panel/Settings > Operation.

?

The .RAW file IS your output data!? It is not just a "temporary" file.? It contains all the waveforms and simulated data (except for what little bit goes into the Error Log file), so deleting it seems pointless.? Without that file, you've lost all your simulated data.

?

View > Visible Traces re-loads the .RAW file data.? If View > Visible Traces is greyed-out,? then there is no .RAW file to load.? That happens either because

  • You have not run the simulation yet,
  • You deleted the .RAW file,
  • You renamed the .RAW file so the original one essentially does not exist,
  • You moved the .RAW file somewhere else.

Clearly you first have to know what you are doing.? If there's no .RAW file, then there is nothing to load.

?

LTspice has a setting (in Control Panel/Settings > Waveforms) to save the output files including .RAW in a specific directory instead of the normal one with the schematic, and I am not sure if or how it affects its ability to find and re-open the .RAW file.? Obviously, if you re-use a schematic filename (e.g., "Draft1", it will overwrite the old .RAW file.? The schematics can be distinct because they were in different folders, but the .RAW files are not because they are all in one big barrel - with that setting.

?

Reloading that .raw file gives access to the large data from a long and multipart simulation.

It does.? Reloading it with its schematic is most ideal - for me, anyway - because it allows you to look at its schematic and pick what you want to plot.? But if your only objective is to re-run a .MEAS script and nothing else, then the only things needed are the .RAW file and the .MEAS scripts.? Yes, you can do that blindly.

?

Andy

?


 

开云体育

I have to phrase my question carefully: what? does the two-letter abbreviation mean in the context of electronics?? I am totally baffled by the rest of the sentence, but that is not unusual.

On 2025-05-20 18:43, Bell, Dave via groups.io wrote:

?

This is for one particular WC simulation, a smallish circuit with 9 variables (2**9,+1, 513, executions.)

--
Best wishes John Woodgate RAYLEIGH Essex OOO-Own Opinions Only If something is true: * as far as we know - it's science *for certain - it's mathematics *unquestionably - it's religion

Virus-free.


 

开云体育

Worst Case (Analysis)

Iterating over a number of components whose values are individually set to minimum tolerance and maximum tolerance in a binary sequence, resulting in 2^n sets of data rolled into a single .raw file.

Later analyses can run .meas scripts on the saved data to extract query results.

?

Dave

?

From: [email protected] <[email protected]> On Behalf Of John Woodgate
Sent: Tuesday, May 20, 2025 11:08 AM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] Execute .meas file

?

I have to phrase my question carefully: what? does the two-letter abbreviation mean in the context of electronics?? I am totally baffled by the rest of the sentence, but that is not unusual.

On 2025-05-20 18:43, Bell, Dave via groups.io wrote:

?

This is for one particular WC simulation, a smallish circuit with 9 variables (2**9,+1, 513, executions.)

--
Best wishes John Woodgate RAYLEIGH Essex OOO-Own Opinions Only If something is true: * as far as we know - it's science *for certain - it's mathematics *unquestionably - it's religion

?

Virus-free.


 

开云体育

Thank you. Unless you plan to make millions of the product, that universe will remain largely unexplored.

On 2025-05-20 19:16, Bell, Dave via groups.io wrote:

Worst Case (Analysis)

Iterating over a number of components whose values are individually set to minimum tolerance and maximum tolerance in a binary sequence, resulting in 2^n sets of data rolled into a single .raw file.

Later analyses can run .meas scripts on the saved data to extract query results.

?

Dave

?

From: [email protected] <[email protected]> On Behalf Of John Woodgate
Sent: Tuesday, May 20, 2025 11:08 AM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] Execute .meas file

?

I have to phrase my question carefully: what? does the two-letter abbreviation mean in the context of electronics?? I am totally baffled by the rest of the sentence, but that is not unusual.

On 2025-05-20 18:43, Bell, Dave via groups.io wrote:

?

This is for one particular WC simulation, a smallish circuit with 9 variables (2**9,+1, 513, executions.)

--
Best wishes John Woodgate RAYLEIGH Essex OOO-Own Opinions Only If something is true: * as far as we know - it's science *for certain - it's mathematics *unquestionably - it's religion

?

Virus-free.

--
Best wishes John Woodgate RAYLEIGH Essex OOO-Own Opinions Only If something is true: * as far as we know - it's science *for certain - it's mathematics *unquestionably - it's religion


 

开云体育

IF this were a commercial product analysis, I’d tend to agree with that.

In this case, it’s a matter of a deep dive into a space-qualified design, to satisfy Specification requirements.

An application of What-If determination, with tight tolerances on, for example, a circuit’s output to *another* circuit, accounting for component tolerances, powr supply variation, etc.

?

Dave

?

From: [email protected] <[email protected]> On Behalf Of John Woodgate
Sent: Tuesday, May 20, 2025 11:33 AM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] Execute .meas file

?

Thank you. Unless you plan to make millions of the product, that universe will remain largely unexplored.

On 2025-05-20 19:16, Bell, Dave via groups.io wrote:

Worst Case (Analysis)

Iterating over a number of components whose values are individually set to minimum tolerance and maximum tolerance in a binary sequence, resulting in 2^n sets of data rolled into a single .raw file.

Later analyses can run .meas scripts on the saved data to extract query results.

?

Dave

?

From: [email protected] <[email protected]> On Behalf Of John Woodgate
Sent: Tuesday, May 20, 2025 11:08 AM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] Execute .meas file

?

I have to phrase my question carefully: what? does the two-letter abbreviation mean in the context of electronics?? I am totally baffled by the rest of the sentence, but that is not unusual.

On 2025-05-20 18:43, Bell, Dave via groups.io wrote:

?

This is for one particular WC simulation, a smallish circuit with 9 variables (2**9,+1, 513, executions.)

--
Best wishes John Woodgate RAYLEIGH Essex OOO-Own Opinions Only If something is true: * as far as we know - it's science *for certain - it's mathematics *unquestionably - it's religion

?

Virus-free.

--
Best wishes John Woodgate RAYLEIGH Essex OOO-Own Opinions Only If something is true: * as far as we know - it's science *for certain - it's mathematics *unquestionably - it's religion


 

开云体育

I suspected something like that, maybe a medical product. But it's still not realistic; other sources of malfunction are more probable.

On 2025-05-20 19:40, Bell, Dave via groups.io wrote:

IF this were a commercial product analysis, I’d tend to agree with that.

In this case, it’s a matter of a deep dive into a space-qualified design, to satisfy Specification requirements.

An application of What-If determination, with tight tolerances on, for example, a circuit’s output to *another* circuit, accounting for component tolerances, powr supply variation, etc.

?

Dave

?

From: [email protected] <[email protected]> On Behalf Of John Woodgate
Sent: Tuesday, May 20, 2025 11:33 AM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] Execute .meas file

?

Thank you. Unless you plan to make millions of the product, that universe will remain largely unexplored.

On 2025-05-20 19:16, Bell, Dave via groups.io wrote:

Worst Case (Analysis)

Iterating over a number of components whose values are individually set to minimum tolerance and maximum tolerance in a binary sequence, resulting in 2^n sets of data rolled into a single .raw file.

Later analyses can run .meas scripts on the saved data to extract query results.

?

Dave

?

From: [email protected] <[email protected]> On Behalf Of John Woodgate
Sent: Tuesday, May 20, 2025 11:08 AM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] Execute .meas file

?

I have to phrase my question carefully: what? does the two-letter abbreviation mean in the context of electronics?? I am totally baffled by the rest of the sentence, but that is not unusual.

On 2025-05-20 18:43, Bell, Dave via groups.io wrote:

?

This is for one particular WC simulation, a smallish circuit with 9 variables (2**9,+1, 513, executions.)

--
Best wishes John Woodgate RAYLEIGH Essex OOO-Own Opinions Only If something is true: * as far as we know - it's science *for certain - it's mathematics *unquestionably - it's religion

?

Virus-free.

--
Best wishes John Woodgate RAYLEIGH Essex OOO-Own Opinions Only If something is true: * as far as we know - it's science *for certain - it's mathematics *unquestionably - it's religion

--
Best wishes John Woodgate RAYLEIGH Essex OOO-Own Opinions Only If something is true: * as far as we know - it's science *for certain - it's mathematics *unquestionably - it's religion


 

开云体育

Indeed! There are checks for stress related to many other components…

?

From: [email protected] <[email protected]> On Behalf Of John Woodgate
Sent: Tuesday, May 20, 2025 11:55 AM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] Execute .meas file

?

I suspected something like that, maybe a medical product. But it's still not realistic; other sources of malfunction are more probable.

On 2025-05-20 19:40, Bell, Dave via groups.io wrote:

IF this were a commercial product analysis, I’d tend to agree with that.

In this case, it’s a matter of a deep dive into a space-qualified design, to satisfy Specification requirements.

An application of What-If determination, with tight tolerances on, for example, a circuit’s output to *another* circuit, accounting for component tolerances, powr supply variation, etc.

?

Dave

?

From: [email protected] <[email protected]> On Behalf Of John Woodgate
Sent: Tuesday, May 20, 2025 11:33 AM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] Execute .meas file

?

Thank you. Unless you plan to make millions of the product, that universe will remain largely unexplored.

On 2025-05-20 19:16, Bell, Dave via groups.io wrote:

Worst Case (Analysis)

Iterating over a number of components whose values are individually set to minimum tolerance and maximum tolerance in a binary sequence, resulting in 2^n sets of data rolled into a single .raw file.

Later analyses can run .meas scripts on the saved data to extract query results.

?

Dave

?

From: [email protected] <[email protected]> On Behalf Of John Woodgate
Sent: Tuesday, May 20, 2025 11:08 AM
To: [email protected]
Subject: EXTERNAL: Re: [LTspice] Execute .meas file

?

I have to phrase my question carefully: what? does the two-letter abbreviation mean in the context of electronics?? I am totally baffled by the rest of the sentence, but that is not unusual.

On 2025-05-20 18:43, Bell, Dave via groups.io wrote:

?

This is for one particular WC simulation, a smallish circuit with 9 variables (2**9,+1, 513, executions.)

--
Best wishes John Woodgate RAYLEIGH Essex OOO-Own Opinions Only If something is true: * as far as we know - it's science *for certain - it's mathematics *unquestionably - it's religion

?

Virus-free.

--
Best wishes John Woodgate RAYLEIGH Essex OOO-Own Opinions Only If something is true: * as far as we know - it's science *for certain - it's mathematics *unquestionably - it's religion

--
Best wishes John Woodgate RAYLEIGH Essex OOO-Own Opinions Only If something is true: * as far as we know - it's science *for certain - it's mathematics *unquestionably - it's religion


 

On Tue, May 20, 2025 at 01:44 PM, Bell, Dave wrote:

With Compression normal, Window=1024, the raw file was >206MB.

With Window=0, the raw file is >710MB.

Both cases took almost exactly the same time, to my surprise, 340 seconds.

That should not surprise you.
?
The two simulations are identical.? The only time difference is the time needed to write the data to a file, 710MB versus 206MB, which is not that different.? There is a slight computational difference when LTspice decides whether or not to save a point, but that is usually small.
?
So it mostly boils down to the overhead caused by your computer's file system and the (now unlikely) possibility that it has rotating parts.
?
Of course this depends on the complexity of the circuit and things like nonlinearities.? If the simulation itself is trivial, then most of the time would be spent saving data instead of calculating data (simulating), and you would see that difference.
?
Andy
?


 

These WCAs I’m working on ..

I have seen "WC" often enough and am familiar with that acronym, but "WCA" is more foreign to me.? I did not know what you meant until the next reply where you used "WC".
?
Andy
?
?