Skip to content
Snippets Groups Projects
environment_config.yaml 6.25 KiB
Newer Older
  • Learn to ignore specific revisions
  •   clean_plates: 2
    
    Florian Schröder's avatar
    Florian Schröder committed
      # range of seconds until the dirty plate arrives.
    
    Fabian Heinrich's avatar
    Fabian Heinrich committed
      time_limit_seconds: 300
    
      equal: EdgeCounter  # =
    
      P: PlateDispenser
      C: CuttingBoard
      X: Trashcan
    
      at: Plate  # @ just a clean plate on a counter
    
      U: Pot  # with Stove
      Q: Pan  # with Stove
      O: Peel  # with Oven
      F: Basket  # with DeepFryer
      T: Tomato
      N: Onion  # oNioN
      L: Lettuce
      K: Potato  # Kartoffel
      I: Fish  # fIIIsh
      D: Dough
      E: Cheese  # chEEEse
      G: Sausage  # sausaGe
      B: Bun
      M: Meat
    
      question: Counter  # ? mushroom
      : Counter
      ^: Counter
      right: Counter
      left: Counter
      wave: Free  # ~ Water
      minus: Free  # - Ice
      dquote: Counter  # " wall/truck
      p: Counter # second plate return ??
    
      meals:
        all: true
        # if all: false -> only orders for these meals are generated
        # TODO: what if this list is empty?
        list:
    
          #      - TomatoSoup
          #      - OnionSoup
          #      - Salad
          - FriedFish
    
      order_gen_class: !!python/name:cooperative_cuisine.orders.RandomOrderGeneration ''
      # the class to that receives the kwargs. Should be a child class of OrderGeneration in orders.py
    
    Florian Schröder's avatar
    Florian Schröder committed
      order_gen_kwargs:
        order_duration_random_func:
    
          # how long should the orders be alive
          # 'random' library call with getattr, kwargs are passed to the function
    
          func: uniform
          kwargs:
    
            a: 55
            b: 65
    
        max_orders: 6
    
        # maximum number of active orders at the same time
    
        # number of orders generated at the start of the environment
    
    Florian Schröder's avatar
    Florian Schröder committed
        sample_on_dur_random_func:
    
          # 'random' library call with getattr, kwargs are passed to the function
    
          func: uniform
          kwargs:
    
            a: 35
            b: 45
    
        sample_on_serving: false
    
        # Sample the delay for the next order only after a meal was served.
    
      serving_not_ordered_meals: true
      # can meals that are not ordered be served / dropped on the serving window
    
      speed_units_per_seconds: 6
    
    Fabian Heinrich's avatar
    Fabian Heinrich committed
      interaction_range: 1.25
    
    Fabian Heinrich's avatar
    Fabian Heinrich committed
      restricted_view: False
    
      view_angle: 70
    
      view_range: 4  # in grid units, can be "null"
    
    
    effect_manager:
      FireManager:
    
        class: !!python/name:cooperative_cuisine.effects.FireEffectManager ''
    
        kwargs:
          spreading_duration: [ 5, 10 ]
    
      # # ---------------  Scoring  ---------------
      orders:
    
        hooks: [ completed_order ]
        callback_class: !!python/name:cooperative_cuisine.scores.ScoreViaHooks ''
        callback_class_kwargs:
    
          time_dependence_func: !!python/name:cooperative_cuisine.scores.constant_score ''
          time_dependence_kwargs: { }
          static_score: 100
    
          score_on_specific_kwarg: meal_name
          score_map:
            Burger: 15
            OnionSoup: 10
            Salad: 5
            TomatoSoup: 10
    
        hooks: [ serve_not_ordered_meal ]
        callback_class: !!python/name:cooperative_cuisine.scores.ScoreViaHooks ''
        callback_class_kwargs:
          static_score: 2
    
        hooks: [ trashcan_usage ]
        callback_class: !!python/name:cooperative_cuisine.scores.ScoreViaHooks ''
        callback_class_kwargs:
          static_score: -5
    
        hooks: [ order_expired ]
        callback_class: !!python/name:cooperative_cuisine.scores.ScoreViaHooks ''
        callback_class_kwargs:
          static_score: -10
        # --------------- Recording ---------------
    
      #    hooks: [ json_state ]
      #    callback_class: !!python/name:cooperative_cuisine.recording.FileRecorder ''
      #    callback_class_kwargs:
      #      record_path: USER_LOG_DIR/ENV_NAME/json_states.jsonl
    
        hooks: [ pre_perform_action ]
        callback_class: !!python/name:cooperative_cuisine.recording.FileRecorder ''
        callback_class_kwargs:
          record_path: USER_LOG_DIR/ENV_NAME/LOG_RECORD_NAME.jsonl
    
        hooks: [ order_duration_sample, plate_out_of_kitchen_time ]
        callback_class: !!python/name:cooperative_cuisine.recording.FileRecorder ''
        callback_class_kwargs:
          record_path: USER_LOG_DIR/ENV_NAME/LOG_RECORD_NAME.jsonl
          add_hook_ref: true
    
        hooks: [ env_initialized, item_info_config ]
        callback_class: !!python/name:cooperative_cuisine.recording.FileRecorder ''
        callback_class_kwargs:
          record_path: USER_LOG_DIR/ENV_NAME/LOG_RECORD_NAME.jsonl
          add_hook_ref: true
    
        hooks:
          - post_counter_pick_up
          - post_counter_drop_off
          - post_dispenser_pick_up
          - cutting_board_100
          - player_start_interaction
          - player_end_interact
          - post_serving
          - no_serving
          - dirty_plate_arrives
          - trashcan_usage
          - plate_cleaned
          - added_plate_to_sink
          - drop_on_sink_addon
          - pick_up_from_sink_addon
          - serve_not_ordered_meal
          - serve_without_plate
          - completed_order
          - new_orders
          - order_expired
          - action_on_not_reachable_counter
          - new_fire
          - fire_spreading
          - drop_off_on_cooking_equipment
          - players_collide
          - post_plate_dispenser_pick_up
          - post_plate_dispenser_drop_off
    
          - drop_off_on_cooking_equipment_plate_dispenser
    
          - on_item_transition
          - progress_started
          - progress_finished
          - content_ready
    
          - dispenser_item_returned
    
          - additional_state_update
    
        callback_class: !!python/name:cooperative_cuisine.recording.FileRecorder ''
        callback_class_kwargs:
          record_path: USER_LOG_DIR/ENV_NAME/LOG_RECORD_NAME.jsonl
          add_hook_ref: true
    
    fheinrich's avatar
    fheinrich committed
    
    
    Florian Schröder's avatar
    Florian Schröder committed
    #  info_msg:
    
    #    func: !!python/name:cooperative_cuisine.hooks.hooks_via_callback_class ''
    
    Florian Schröder's avatar
    Florian Schröder committed
    #    kwargs:
    #      hooks: [ cutting_board_100 ]
    
    #      callback_class: !!python/name:cooperative_cuisine.info_msg.InfoMsgManager ''
    
    #      callback_class_kwargs:
    
    Florian Schröder's avatar
    Florian Schröder committed
    #        msg: Glückwunsch du hast was geschnitten!
    #  fire_msg:
    
    #    func: !!python/name:cooperative_cuisine.hooks.hooks_via_callback_class ''
    
    Florian Schröder's avatar
    Florian Schröder committed
    #    kwargs:
    #      hooks: [ new_fire ]
    
    #      callback_class: !!python/name:cooperative_cuisine.info_msg.InfoMsgManager ''
    
    #      callback_class_kwargs:
    
    Florian Schröder's avatar
    Florian Schröder committed
    #        msg: Feuer, Feuer, Feuer
    #        level: Warning