mirror of
https://github.com/facebookresearch/pytorch3d.git
synced 2026-03-11 23:06:04 +08:00
Resolve logger warnings (#1981)
Summary: # PR Summary This small PR resolves the annoying deprecation warnings of the `logger` library: ```python DeprecationWarning: The 'warn' method is deprecated, use 'warning' instead ``` Pull Request resolved: https://github.com/facebookresearch/pytorch3d/pull/1981 Reviewed By: MichaelRamamonjisoa Differential Revision: D75287169 Pulled By: bottler fbshipit-source-id: 9ff9f5dd648aca8d8bb5d33577909da711d18647
This commit is contained in:
committed by
Facebook GitHub Bot
parent
f315ac131b
commit
182e845c19
@@ -755,7 +755,7 @@ class SqlIndexDataset(DatasetBase, ReplaceableBase):
|
||||
if pick_sequences:
|
||||
old_len = len(eval_batches)
|
||||
eval_batches = [b for b in eval_batches if b[0][0] in pick_sequences]
|
||||
logger.warn(
|
||||
logger.warning(
|
||||
f"Picked eval batches by sequence/cat: {old_len} -> {len(eval_batches)}"
|
||||
)
|
||||
|
||||
@@ -763,7 +763,7 @@ class SqlIndexDataset(DatasetBase, ReplaceableBase):
|
||||
old_len = len(eval_batches)
|
||||
exclude_sequences = set(self.exclude_sequences)
|
||||
eval_batches = [b for b in eval_batches if b[0][0] not in exclude_sequences]
|
||||
logger.warn(
|
||||
logger.warning(
|
||||
f"Excluded eval batches by sequence: {old_len} -> {len(eval_batches)}"
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user