Skip to content

Unsupported Operand when Data Farming Amusement Park Model #200

@Grochocinski

Description

@Grochocinski

Describe the Bug

When attempting to data farm the Amusement Park model via the GUI, I get the following error:

Exception in Tkinter callback
Traceback (most recent call last):
  File "C:\Users\will_\AppData\Roaming\uv\python\cpython-3.13.9-windows-x86_64-none\Lib\tkinter\__init__.py", line 2074, in __call__
    return self.func(*args)
           ~~~~~~~~~^^^^^^^
  File "c:\Users\will_\Documents\repos\simopt\simopt\gui\data_farming_window.py", line 1300, in run_experiment
    myexperiment.run(n_reps=n_reps, crn_across_design_pts=crn_across_design_pts)
    ~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "c:\Users\will_\Documents\repos\simopt\simopt\data_farming_base.py", line 347, in run
    design_pt.simulate(n_reps)
    ~~~~~~~~~~~~~~~~~~^^^^^^^^
  File "c:\Users\will_\Documents\repos\simopt\simopt\data_farming_base.py", line 146, in simulate
    responses, gradients = self.model.replicate()
                           ~~~~~~~~~~~~~~~~~~~~^^
  File "c:\Users\will_\Documents\repos\simopt\simopt\models\amusementpark.py", line 361, in replicate
    arrival_prob_sum: float = float(sum(arrival_gammas))
                                    ~~~^^^^^^^^^^^^^^^^
TypeError: unsupported operand type(s) for +: 'int' and 'str'

Steps To Reproduce

  1. Launch GUI (python -m simopt)
  2. Click Data Farm Models
  3. Select Amusement Park from the model dropdown
  4. Click Create Design
  5. Click OK
  6. Enter 1 in the replications input field
  7. Click Run All

Expected Behavior

Not erroring

Environment

Please provide some details about your environment to help us replicate the bug:

  • Operating System: Windows 11
  • Python Version: 3.13.9

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions