Error while using vs30 clustering in "ground_motion_correlation_params"

43 views
Skip to first unread message

prashant reshim

unread,
Mar 27, 2015, 11:02:11 AM3/27/15
to openqua...@googlegroups.com

Dear All,

I am running a Scenario based calculation with “vs30 clustering” method “JB2009” and I am getting the following error:

ValueError: '"vs30_clustering": True' is not a valid Python dictionary: could not convert to dictionary: ground_motion_correlation_params="vs30_clustering": True

The same file works in Openquake v1.0 but it does not work in v1.3

(I am using Openquake v1.3 on "Ubuntu 12.04.5 LTS" and Openquake v1.0 on "Ubuntu 12.04.4 LTS")


The [Calculation] part of the file is as follows:

[calculation]

rupture_model_file = rupture_model62.xml

intensity_measure_types = PGA

truncation_level = 3

maximum_distance = 500

gsim = AkkarBommer2010

ground_motion_correlation_model = JB2009

ground_motion_correlation_params = {"vs30_clustering": True}

number_of_ground_motion_fields = 1


Thank you very much in advance for any help.

Kind Regards,

Prashant

Michele Simionato

unread,
Mar 27, 2015, 11:12:57 AM3/27/15
to openqua...@googlegroups.com
Are you sure that you have

ground_motion_correlation_params = {"vs30_clustering": True}

and not

ground_motion_correlation_params = "vs30_clustering": True

it looks like you are missing braces from the error message.

Prashant Reshim

unread,
Mar 27, 2015, 11:18:10 AM3/27/15
to openqua...@googlegroups.com
Hi Michele,

I have tried both with and without braces and they give the error. The error part is form the without braces run.

Michele Simionato

unread,
Mar 28, 2015, 2:57:54 AM3/28/15
to openqua...@googlegroups.com
Then please send the precise error with the braces.
You can try the syntax for yourself, just fire a Python and copy and paste your code. This is correct:

$ python
>>> {"vs30_clustering": True} 
{'vs30_clustering': True}

this is wrong:

>>> "vs30_clustering": True
  File "<stdin>", line 1
    "vs30_clustering": True
                     ^
SyntaxError: invalid syntax
Reply all
Reply to author
Forward
0 new messages