ChrisChen1023 / HINT

HINT: High-quality INpainting Transformer with Enhanced Attention and Mask-aware Encoding
MIT License
30 stars 4 forks source link

inference time #14

Closed SHIJILIANG01 closed 5 months ago

SHIJILIANG01 commented 5 months ago

Thank you for your excellent work. The paper mentions inference time per image, can you provide the code for reference, thanks!

ChrisChen1023 commented 5 months ago

Hi,

I show the code below. You need to import time at the beginning.

                tsince = int(round(time.time()*1000))
                outputs_img = self.inpaint_model(images, masks)
                ttime_elapsed = int(round(time.time()*1000))-tsince
                print('test time elaspsed {}ms'.format(ttime_elapsed))

I also update in the ./src/HINT.py

Cheers.