Skip to content

Commit

Permalink
After format
Browse files Browse the repository at this point in the history
  • Loading branch information
AlvaroHG committed Jun 7, 2024
1 parent 363be8b commit e94dee9
Show file tree
Hide file tree
Showing 301 changed files with 25,267 additions and 15,532 deletions.
22 changes: 12 additions & 10 deletions ai2thor/_quality_settings.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
# GENERATED FILE - DO NOT EDIT
DEFAULT_QUALITY = 'Ultra'
QUALITY_SETTINGS = {'DONOTUSE': 0,
'High': 5,
'High WebGL': 8,
'Low': 2,
'Medium': 3,
'MediumCloseFitShadows': 4,
'Ultra': 7,
'Very High': 6,
'Very Low': 1}
DEFAULT_QUALITY = "Ultra"
QUALITY_SETTINGS = {
"DONOTUSE": 0,
"High": 5,
"High WebGL": 8,
"Low": 2,
"Medium": 3,
"MediumCloseFitShadows": 4,
"Ultra": 7,
"Very High": 6,
"Very Low": 1,
}
163 changes: 75 additions & 88 deletions ai2thor/benchmarking.py

Large diffs are not rendered by default.

37 changes: 15 additions & 22 deletions ai2thor/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,13 @@
from ai2thor.util.lock import LockSh, LockEx
from ai2thor.util import atomic_write
import io
from ai2thor.platform import STR_PLATFORM_MAP, OSXIntel64, Linux64, CloudRendering, StandaloneWindows64
from ai2thor.platform import (
STR_PLATFORM_MAP,
OSXIntel64,
Linux64,
CloudRendering,
StandaloneWindows64,
)
import platform

logger = logging.getLogger(__name__)
Expand Down Expand Up @@ -57,7 +63,9 @@ def __init__(self):
self.server_types = ["FIFO", "WSGI"]
self.url = None
self.unity_proc = None
external_system_platforms = dict(Linux=Linux64, Darwin=OSXIntel64, Windows=StandaloneWindows64)
external_system_platforms = dict(
Linux=Linux64, Darwin=OSXIntel64, Windows=StandaloneWindows64
)
self.platform = external_system_platforms[platform.system()]

def download(self):
Expand All @@ -71,14 +79,7 @@ def lock_sh(self):

@property
def base_dir(self):
return os.path.join(
os.path.dirname(
os.path.dirname(
os.path.realpath(__file__)
)
),
"unity"
)
return os.path.join(os.path.dirname(os.path.dirname(os.path.realpath(__file__))), "unity")


class ExternalBuild(object):
Expand All @@ -101,13 +102,9 @@ def lock_sh(self):

@property
def base_dir(self):
return os.path.dirname(
os.path.dirname(
os.path.dirname(
os.path.dirname(self.executable_path)
)
return os.path.dirname(
os.path.dirname(os.path.dirname(os.path.dirname(self.executable_path)))
)
)


class Build(object):
Expand Down Expand Up @@ -155,9 +152,7 @@ def download(self):
logger.debug("%s exists - skipping download" % (self.executable_path,))

def zipfile(self):
zip_data = ai2thor.downloader.download(
self.url, self.sha256(), self.include_private_scenes
)
zip_data = ai2thor.downloader.download(self.url, self.sha256(), self.include_private_scenes)

return zipfile.ZipFile(io.BytesIO(zip_data))

Expand Down Expand Up @@ -217,9 +212,7 @@ def url(self):

@property
def name(self):
return build_name(
self.platform.name(), self.commit_id, self.include_private_scenes
)
return build_name(self.platform.name(), self.commit_id, self.include_private_scenes)

def unlock(self):
if self._lock:
Expand Down
Loading

0 comments on commit e94dee9

Please sign in to comment.