code: def test_ebc_model_replacement(self, device: torch.device) -> None:
      eb1_config = EmbeddingBagConfig(
          name="t1",
          embedding_dim=4,
          num_embeddings=10,
          feature_names=["f1"],
      )
      eb2_config = EmbeddingBagConfig(
          name="t2",
          embedding_dim=4,
          num_embeddings=10,
          feature_names=["f2"],
      )
      eb3_config = EmbeddingBagConfig(
          name="t3",
          embedding_dim=4,
          num_embeddings=10,
          feature_names=["f3"],
      )
  
      ebc = EmbeddingBagCollection(
          tables=[eb1_config, eb2_config, eb3_config],
      )
      test_model = TestModel(ebc).to(device)
      test_model = fuse_embedding_optimizer(
          test_model,
          optimizer_type=torch.optim.SGD,
          optimizer_kwargs={"lr": 0.02},
          device=device,
      )
  
      self.assertIsInstance(test_model.ebc, FusedEmbeddingBagCollection)
  
      #     0       1        2  <-- batch
      # f1   [0,1] None    [2]
      # f2   [3]    [4]    [5,6,7]
      # f3   []    [8]    []
      # ^
      # feature
  
      features = KeyedJaggedTensor.from_lengths_sync(
          keys=["f1", "f2", "f3"],
          values=torch.tensor([0, 1, 2, 3, 4, 5, 6, 7, 8]),
          lengths=torch.tensor([2, 0, 1, 1, 1, 3, 0, 1, 0]),
      ).to(device)
      test_model(features)
  
imports: import unittest
  from collections import OrderedDict
  from typing import Any, Dict, List, Optional, Tuple, Type
  import hypothesis.strategies
  import torch
  import torch.fx
  import torchrec
  from fbgemm_gpu.split_table_batched_embeddings_ops_training import EmbeddingLocation
  from hypothesis import given, settings
  from torchrec.modules.embedding_configs import EmbeddingBagConfig, EmbeddingConfig
  from torchrec.modules.embedding_modules import EmbeddingBagCollection, EmbeddingCollection
  from torchrec.modules.fused_embedding_modules import fuse_embedding_optimizer, FusedEmbeddingBagCollection, FusedEmbeddingCollection
  from torchrec.sparse.jagged_tensor import KeyedJaggedTensor
label_desc: Use image node_id 14 for calling the FusedEmbeddingBagCollectionTest obj's underlying member method code with example usage: obj.test_ebc_model_replacement(device) without return types