Illustre commited on
Commit
a670533
1 Parent(s): fb8744b

Update model.py

Browse files
Files changed (1) hide show
  1. model.py +8 -1
model.py CHANGED
@@ -84,8 +84,15 @@ class Model:
84
  delete=False,
85
  mode='w+b')
86
  decode_latent_mesh(self.xm, latent).tri_mesh().write_ply(ply_path)
 
87
 
88
- return ply_path.name
 
 
 
 
 
 
89
 
90
  def run_text(self,
91
  prompt: str,
 
84
  delete=False,
85
  mode='w+b')
86
  decode_latent_mesh(self.xm, latent).tri_mesh().write_ply(ply_path)
87
+ ply_path.close() # Close the file after writing
88
 
89
+ # Open the file in binary mode for reading
90
+ with open(ply_path.name, 'rb') as file:
91
+ data = file.read()
92
+
93
+ outputs = [ply_path.name, data]
94
+
95
+ return outputs
96
 
97
  def run_text(self,
98
  prompt: str,