Skip to content

Commit

Permalink
wtf is this code
Browse files Browse the repository at this point in the history
  • Loading branch information
TNTwise committed May 12, 2024
1 parent 57686ed commit e4e8805
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/misc/onProgramStart.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
from src.getLinkVideo.get_video import *
from src.getModels.rifeModelsFunctions import rife_cuda_checkboxes
from src.programData.version import returnVersion

import site

def open_link(urll):
url = QUrl(urll)
Expand Down Expand Up @@ -282,7 +282,10 @@ def createDirectories():
os.makedirs(
os.path.join(f"{thisdir}", "models", "custom-models-cuda"), exist_ok=True
)

def exportTRTlibsToPATH(self):
site_packages_dir = site.getsitepackages()[0]
#print(f'export LD_LIBRARY_PATH={site_packages_dir}/nvidia/cuda_runtime/lib:$LD_LIBRARY_PATH')
os.system(f'export LD_LIBRARY_PATH={site_packages_dir}/nvidia/cuda_runtime/lib:$LD_LIBRARY_PATH')
def onApplicationStart(self):
# this is kind of a mess
thisdir = src.programData.thisdir.thisdir()
Expand All @@ -298,6 +301,7 @@ def onApplicationStart(self):

set_model_params(self)
hideChainModeButtons(self)
exportTRTlibsToPATH(self)
# get esrgan models

self.ui.ESRGANModelSelectButton.show()
Expand Down

0 comments on commit e4e8805

Please sign in to comment.