code: def test_subgraph_rewriter_pattern_output_pattern_node_can_have_users_that_are_not_matched(
      self,
  ):
      class M(torch.nn.Module):
          def forward(self, x):
              y = torch.relu(x)
              return torch.neg(y) - y
  
      def pattern(x):
          return torch.relu(x)
  
      def replacement(x):
          return torch.sigmoid(x)
  
      def comparison(x):
          y = torch.sigmoid(x)
          return torch.neg(y) - y
  
      traced = symbolic_trace(M())
      comparison_fn = symbolic_trace(comparison)
  
      x = torch.randn(3, 4)
  
      subgraph_rewriter.replace_pattern(traced, pattern, replacement)
  
      traced.graph.lint()
  
      ref_outs = comparison_fn(x)
      test_outs = traced.forward(x)
      self.assertEqual(ref_outs, test_outs)
  
imports: import os
  import sys
  import torch
  from torch.fx import symbolic_trace, subgraph_rewriter
  from torch.fx.annotate import annotate
  from torch.fx.experimental.rewriter import RewritingTracer
  from torch.testing._internal.jit_utils import JitTestCase
label_desc: Use image node_id 10 for calling the TestSubgraphRewriter obj's underlying member method code with example usage: obj.test_subgraph_rewriter_pattern_output_pattern_node_can_have_users_that_are_not_matched() and returns: torch, torch, unknown, unknown