I think in your use case it might be easier to manipulate the indices before creating the Subsets as shown in this small example:
from torch.utils.data import Subset
from sklearn.model_selection import train_test_split
import torchvision.datasets as datasets

dataset = datasets.MNIST(
    root='./data',
    transform=transforms.ToTensor()
)

# Get all targets
targets = dataset.targets
# Create target_indices
target_indices = np.arange(len(targets))
# Split into train and validation
train_idx, val_idx = train_test_split(target_indices, train_size=0.8)

# Specify which class to remove from train
classidx_to_remove = 0
# Get indices to keep from train split
idx_to_keep = targets[train_idx]!=classidx_to_remove
# Only keep your desired classes
train_idx = train_idx[idx_to_keep]

train_dataset = Subset(dataset, train_idx)
val_dataset = Subset(dataset, val_idx)

Let me know, if this would work for you.