solving in batch mode

by Nate on June 2, 2008

Here’s a pretty hidden feature…  did you know you can have GeoStudio solve a whole bunch of analyses and even files automatically?

Solving an Analysis

GeoStudio can be run with command-line parameters that tell it to solve one or more analyses and then shut down.

For example:

geostudio “c:\my file.gsz” “an analysis” /solve

will solve the analysis named “an analysis” in the file “my file.gsz”.

Solving Several Analyses

A bit more interesting:

geostudio “c:\my file.gsz” /solve:all

will solve all analyses in “my file.gsz”.  It solves them in the right order, so that a steady-state analysis, for example, gets solved before the transient analysis that uses its results as initial conditions.

Logging

If there are errors during the solving process, however, you don’t normally want an error message to pop up, because then the whole thing stops and waits for you to hit OK, instead of moving on to the next analysis which may solve just fine.

Specifying a log file like this:

geostudio “c:\my file.gsz” /solve:all /log:”c:\log.txt”

will cause all errors to be written to “log.txt” instead of being displayed on the screen.  After it’s done solving everything you can open log.txt in Notepad and make sure everything ran properly.

Exiting

After GeoStudio is done solving the analyses you told it to, it just sits there with the file open.  If you want it to close when it’s done, use /autoexit:

geostudio “c:\my file.gsz” /solve:all /log:”c:\log.txt” /autoexit

Batch File

Put all those together and you can write a batch file to automatically solve several files in a row.  For example, use Notepad to create a new file named “solve.cmd” with this content:

geostudio “c:\my file.gsz” /solve:all /log:”c:\log.txt” /autoexit
geostudio “c:\my other file.gsz” /solve:all /log:”c:\log.txt” /autoexit

When you run it (double-click the file) GeoStudio will launch and solve all analyses in “my file.gsz” followed by all analyses in “my other file.gsz”, and log.txt will contain the combined logs of all analyses.

Real-Life Application

Is this a useful feature?  I’m not really sure.

It’s very useful for us, it’s a core part of our Quality Assurance process.  Every night we have two quad-core servers crunch away for half the night solving several hundred analyses and comparing the results to make sure we didn’t inadvertantly break something.

But is it useful to the average (or above-average) geotech engineer?  I can imagine a few situations it might be, but I don’t know if they’re realistic or just contrived.  If you have some VADOSE/W analyses that you know will take several hours to run, you could start them in batch mode before going home at the end of the day and have the results ready in the morning. 

Or if you have a large number of interdependant files, and you make a change to one analysis that all the others depend on, you could run a batch to re-solve all the others.

What do you think?  Could you see yourself using a batch file to solve a large number of analyses?  Do you already?  I’d love to hear about the processes you follow in your office to manage all the analyses you must encounter in a large project.

{ 8 comments… read them below or add one }

1

Jack 06.11.09 at 5:30 am

Dear Grokking
I am very interested in the bacth mode, so i have a search using google, and then connected to your site. Your post is very useful for me. My problem is somewhat different from what you have described. I have thousands of analyses to run, but these files only differs in some input parameters. Do we also have an efficient way to create those thousands of files?
Thanks.
Jack

2

Nate 06.15.09 at 11:11 am

Yes, there may be a couple of ways to automate what you are trying to do. The answer will depend a bit on what type of analysis you are running, what parameters you are varying, and what you are wanting to do with the results.

Rather than detailing them here in the comments, I wrote another entry.

I’m curious what it is you’re doing with your thousands of files. Can you share some more detail? Do the tips I mentioned help? We’re working full-force on the next version of GeoStudio at the moment, so this is a great time to hear about features that would be important to you.

3

Jack 09.10.09 at 1:31 am

Dear Grokking
Thank you for your reply and useful tips. My work is often related with reliability analysis, optimization design, and back analysis of geotechnical systems. In these circumstances, to be able to run thousands of similar simulations with different input parameters is very helpful. I believe, if this new feature is incorporated into GeoStudio, the powerfulness of GeoStudio will be greatly extended.
Jack

4

m.moghadari 07.06.10 at 4:03 am

Hi,it is a really useful site.I read about batch file and sensitivity and Montcarlo method in Slope/w,but my problem is some thing else.when we use monte carlo method,we can not control the parameters which each time the software use. I want to do 1000 analysis with slop/w and I want to use my own bunch of parameters which I saved in Excel,how can I do this?

5

m.moghadari 07.06.10 at 4:19 am

sorry.I forgot to say that there isn`t any logical function between my data,I mean they are just different sets of data

6

Nate 07.21.10 at 10:06 am

@m.moghadari: I can’t think of a way to do exactly what you’re asking.

When I first read your question I thought it could probably be done using an Add-In (choose “Generalized Spline” as the distribution type, then create a function and set its type to Add-In), but in the end I don’t think that will give you what you want–the function will define the probability of various values being used rather than return the actual value you want on each iteration.

If you’re wanting a probability of failure, you could (using Excel or some other tool) create a probability function from your data, then use that probability function in SLOPE/W. That’s not exactly what you’re asking–it won’t use the exact values from your spreadsheet–but it may be close enough.

If you’re trying to do a sensitivity analysis, you could specify a min and max range that encompasses all your samples and a step size small enough to hit or at least be near your samples.

In the end I’m not really sure what you’re trying to accomplish. I would suggest you contact support@geo-slope.com and explain to them what you are trying to model, and they may be able to suggest a different approach. Or this may be a feature we could consider for a future version.

7

m.moghadari 07.31.10 at 10:02 am

thank you so much for your help

8

Frethistifs 08.17.11 at 9:50 am

ABTFHUAMIZ Union Plus Credit Card payment ollajnjuamvev

Leave a Comment

You can use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>