code: def test_binary_output_feature():
      binary_output_config = {
          "name": "binary_feature",
          "type": "binary",
          "input_size": BINARY_W_SIZE,
          "decoder": {
              "type": "regressor",
              "input_size": 1,
          },
          "loss": {
              "type": "binary_weighted_cross_entropy",
              "positive_class_weight": 1,
              "robust_lambda": 0,
              "confidence_penalty": 0,
          },
      }
      binary_output_config, _ = load_config_with_kwargs(
          BinaryOutputFeatureConfig, binary_output_config
      )
      binary_output_feature = BinaryOutputFeature(
          binary_output_config, {}
      ).to(DEVICE)
      combiner_outputs = dict()
      combiner_outputs["combiner_output"] = torch.randn(
          [BATCH_SIZE, BINARY_W_SIZE], dtype=torch.float32
      ).to(DEVICE)
  
      binary_output = binary_output_feature(combiner_outputs, {})
  
      assert "last_hidden" in binary_output
      assert "logits" in binary_output
      assert binary_output["logits"].size() == torch.Size([BATCH_SIZE])
  
file_path: ludwig/tests/ludwig/features/test_binary_feature.py
imports: from typing import Dict
  import pytest
  import torch
  from ludwig.constants import ENCODER, ENCODER_OUTPUT
  from ludwig.features.binary_feature import BinaryInputFeature, BinaryOutputFeature
  from ludwig.schema.features.binary_feature import BinaryInputFeatureConfig, BinaryOutputFeatureConfig
  from ludwig.schema.utils import load_config_with_kwargs
  from ludwig.utils.torch_utils import get_torch_device
label_desc: Use image node_id 3 for calling a global function with example usage: test_binary_output_feature() without return types