Serializing JSON code for drawable objects (and some documentation) (#222)

* some comments and starting serializing comments. on plane w/o formatter

* fixing pylint and black

* removed changes in file

* revert file

* addressing comments

* remove abstract

Co-authored-by: Ethan Weber <ethanweber@Ethans-MacBook-Pro.local>
This commit is contained in:
Ethan WeberandEthan Weber authored and GitHub committed 2022-07-28 13:55:58 -05:00
1 parent 44a7fa288c
commit d13a766b9e
13 files changed
+240 -106

No files matched your search

+6 -6
View File
@@ -82,17 +82,17 @@ class NeRFGraph(Graph):
**kwargs,
)
def register_callbacks(self) -> None:
"""defining callbacks to run after every training iteration"""
self.callbacks = []
def get_training_callbacks(self) -> List[Callback]:
callbacks = []
if self.density_field is not None:
self.callbacks += [
callbacks = [
Callback(
self.density_field.update_every_num_iters,
self.density_field.update_density_grid,
update_every_num_iters=self.density_field.update_every_num_iters,
func=self.density_field.update_density_grid,
density_eval_func=self.field_coarse.density_fn,
)
]
return callbacks # type: ignore
def populate_fields(self):
"""Set the fields."""