shunsukesaito / PIFu

This repository contains the code for the paper "PIFu: Pixel-Aligned Implicit Function for High-Resolution Clothed Human Digitization"

Home Page:https://shunsukesaito.github.io/PIFu/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Data preparation memory leak

kampelmuehler opened this issue · comments

For me when running the rendering pipeline in a loop over multiple objs (

def render_prt_ortho(out_path, folder_name, subject_name, shs, rndr, rndr_uv, im_size, angl_step=4, n_light=1, pitch=[0]):
) the system memory and GPU memory allocation are steadily growing until the process is killed by the OS.

Only workaround I've found is to respawn the entire render pipeline for every single instance (i.e. mesh). Has anyone else had any issues and found a solution?

I think this might be because this function is never called:

def cleanup(self):

calling it within the render loop hinders the infinite memory growth.

Be aware that it fails at this statement though

glDeleteBuffers(1, [])

which I think is safe to remove.

It should then be safe to call rndr.cleanup() (and potentially rndr_uv.cleanup()) after every finished obj.

btw: there's a small leak remaining but not nearly as scary.