mirror of
https://github.com/facebookresearch/pytorch3d.git
synced 2025-12-21 14:50:36 +08:00
lazy all_train_cameras
Summary: Avoid calculating all_train_cameras before it is needed, because it is slow in some datasets. Reviewed By: shapovalov Differential Revision: D38037157 fbshipit-source-id: 95461226655cde2626b680661951ab17ebb0ec75
This commit is contained in:
committed by
Facebook GitHub Bot
parent
b2dc520210
commit
3783437d2f
@@ -10,6 +10,7 @@ from collections import defaultdict
|
||||
from dataclasses import dataclass
|
||||
from itertools import product
|
||||
|
||||
import numpy as np
|
||||
from pytorch3d.implicitron.dataset.data_loader_map_provider import (
|
||||
DoublePoolBatchSampler,
|
||||
)
|
||||
@@ -53,6 +54,7 @@ class MockDataset(DatasetBase):
|
||||
|
||||
class TestSceneBatchSampler(unittest.TestCase):
|
||||
def setUp(self):
|
||||
np.random.seed(42)
|
||||
self.dataset_overfit = MockDataset(1)
|
||||
|
||||
def test_overfit(self):
|
||||
|
||||
Reference in New Issue
Block a user