Skip to content

Commit a0552c5

Browse files
committed
changed the file place and deleted unnecessary code
1 parent 8b74b96 commit a0552c5

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

demo/flux_demo.py renamed to examples/apps/flux_demo.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,7 @@
8888
del ep
8989
pipe.transformer = trt_gm
9090
pipe.transformer.config = config
91+
trt_gm.device = torch.device("cuda")
9192
torch.cuda.empty_cache()
9293

9394

py/torch_tensorrt/dynamo/conversion/_TRTInterpreter.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -734,10 +734,9 @@ def run(
734734
builder_config, self.compilation_settings.timing_cache_path
735735
)
736736
# TODO: Memory control prototyping. Under discussion
737-
self.module.to("cpu")
738-
torch.cuda.empty_cache()
739737
del self.module
740738
gc.collect()
739+
torch.cuda.empty_cache()
741740
serialized_engine = self.builder.build_serialized_network(
742741
self.ctx.net, builder_config
743742
)

0 commit comments

Comments
 (0)