SPECFEM / specfem3d

SPECFEM3D_Cartesian simulates acoustic (fluid), elastic (solid), coupled acoustic/elastic, poroelastic or seismic wave propagation in any type of conforming mesh of hexahedra (structured or not).
GNU General Public License v3.0
390 stars 224 forks source link

the SPECFEM3D_Cartesian code does not work from the root directory #109

Closed komatits closed 10 years ago

komatits commented 10 years ago

The SPECFEM3D_Cartesian code does not work from the root directory, when running the defaut Par_file from there the codes try to open a file from a directory one level above (../DATA), which of course does not exist:

user@laptop: ./bin/xdecompose_mesh 40 DATA/Par_file OUTPUT_FILES/DATABASES_MPI/ Can't open '../DATA/Par_file'

opening file failed, please check your file path and run-directory. error opening Par_file

Same problem in xgenerate_databases and xspecfem3D I think.

mpbl commented 10 years ago

I do not know if that is an issue. But that is clearly inconsistent with SPECFEM3D_GLOBE that is ran with ./bin/xspecfem3d from the root directory, while SPECFEM3D_Cartesian is ran with ./xspecfem3d from the bin/ directory.

mpbl commented 10 years ago

By the way, that is pseudo-user-defined in setup/constants.h(.in) (where you specify the directory structure).

komatits commented 10 years ago

Thanks. Let us change it, because both 2D and 3D_GLOBE run from the root dir. (no need to leave the other option of running from "bin", which is confusing)

thanks Dimitri

On 24/03/2014 20:48, Matthieu Lefebvre wrote:

I do not know if that is an issue. But that is clearly inconsistent with SPECFEM3D_GLOBE that is ran with ./bin/xspecfem3d from the root directory, while SPECFEM3D_Cartesian is ran with ./xspecfem3d from the bin/ directory.

— Reply to this email directly or view it on GitHub https://github.com/geodynamics/specfem3d/issues/109#issuecomment-38491851.

Dimitri Komatitsch CNRS Research Director (DR CNRS), Laboratory of Mechanics and Acoustics, UPR 7051, Marseille, France http://komatitsch.free.fr

mpbl commented 10 years ago

@komatits Can you please check that everything is properly changed in the examples? Then we can close this issue. Thanks a lot.

komatits commented 10 years ago

Tested, and works fine. Thanks for fixing it. Let me close the issue then.

On 26/03/2014 15:41, Matthieu Lefebvre wrote:

@komatits https://github.com/komatits Can you please check that everything is properly changed in the examples? Then we can close this issue. Thanks a lot.

— Reply to this email directly or view it on GitHub https://github.com/geodynamics/specfem3d/issues/109#issuecomment-38691346.

Dimitri Komatitsch CNRS Research Director (DR CNRS), Laboratory of Mechanics and Acoustics, UPR 7051, Marseille, France http://komatitsch.free.fr

komatits commented 10 years ago

Not sure if the "process.sh" scripts in the examples still work fine though, now that the paths have changed (I have only tested the two new scripts that I have added a few minutes ago, and which run the two default examples from the root dir)

On 26/03/2014 23:51, Dimitri Komatitsch wrote:

Tested, and works fine. Thanks for fixing it. Let me close the issue then.

On 26/03/2014 15:41, Matthieu Lefebvre wrote:

@komatits https://github.com/komatits Can you please check that everything is properly changed in the examples? Then we can close this issue. Thanks a lot.

— Reply to this email directly or view it on GitHub https://github.com/geodynamics/specfem3d/issues/109#issuecomment-38691346.

Dimitri Komatitsch CNRS Research Director (DR CNRS), Laboratory of Mechanics and Acoustics, UPR 7051, Marseille, France http://komatitsch.free.fr