code: def test_extended_keypoint_sample(self):
      dataset = fod.Dataset("test")
      dataset.default_skeleton = fo.KeypointSkeleton(
          labels=["top-left", "center", "bottom-right"],
          edges=[[0, 1, 2]],
      )
      sample = fos.Sample(
          filepath="video.mp4",
          keypoint=fo.Keypoint(
              label="keypoint",
              points=[[0, 0], [0.5, 0.5], [1, 1]],
              confidence=[0, 0.5, 1],
              dynamic=["one", "two", "three"],
              tags=["keypoint"],
          ),
          keypoints=fo.Keypoints(
              keypoints=[
                  fo.Keypoint(
                      label="keypoint",
                      points=[[0, 0], [0.5, 0.5], [1, 1]],
                      confidence=[0, 0.5, 1],
                      dynamic=["one", "two", "three"],
                      tags=["keypoint"],
                  )
              ]
          ),
      )
  
      dataset.add_sample(sample)
      dataset.add_dynamic_sample_fields()
      dataset.add_dynamic_frame_fields()
  
      filters = {
          "keypoint.label": {
              "values": ["empty"],
              "exclude": False,
          },
      }
      view = fosv.get_view("test", filters=filters)
      self.assertEqual(len(view), 0)
  
      filters = {
          "keypoint.label": {
              "values": ["keypoint"],
              "exclude": True,
          },
      }
      view = fosv.get_view("test", filters=filters)
      self.assertEqual(len(view), 0)
  
      filters = {
          "keypoint.points": {
              "values": ["top-left"],
              "exclude": False,
          },
      }
      view = fosv.get_view("test", filters=filters)
      self.assertEqual(len(view), 1)
      self.assertListEqual(view.first().keypoint.points[0], [0, 0])
      for point in view.first().keypoint.points[1:]:
          self.assertTrue(math.isnan(point[0]))
          self.assertTrue(math.isnan(point[1]))
  
      filters = {
          "keypoint.points": {
              "values": ["top-left"],
              "exclude": False,
          },
      }
      view = fosv.get_view("test", filters=filters)
      self.assertEqual(len(view), 1)
  
imports: import math
  import unittest
  import fiftyone
  import fiftyone.core.dataset
  import fiftyone.core.labels
  import fiftyone.core.odm
  import fiftyone.core.sample
  from fiftyone.server.query import Dataset
  from fiftyone.server.samples import paginate_samples
  import fiftyone.server.view
  from decorators import drop_datasets
  from utils.groups import make_disjoint_groups_dataset
label_desc: Use image node_id 4 for calling the ServerViewTests obj's underlying member method code with example usage: obj.test_extended_keypoint_sample() without return types