-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #7 from skim0119/5_matplotlib_renderer
Add matplotlib renderer for quick debugging. Resolve #5
- Loading branch information
Showing
13 changed files
with
411 additions
and
49 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,6 +9,7 @@ model | |
save | ||
*.mp4 | ||
.DS_Store | ||
.vscode | ||
|
||
*.pov | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
from enum import Enum | ||
|
||
class RendererType(Enum): | ||
POVRAY=1 | ||
MATPLOTLIB=2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
from abc import ABC, abstractmethod | ||
|
||
from gym_softrobot.config import RendererType | ||
|
||
|
||
class BaseRenderer(ABC): | ||
""" | ||
Renderer should contains the methods below. | ||
""" | ||
|
||
@property | ||
@abstractmethod | ||
def type(self) -> RendererType: | ||
pass | ||
|
||
@abstractmethod | ||
def render(self): | ||
pass | ||
|
||
@abstractmethod | ||
def close(self): | ||
pass | ||
|
||
class BaseElasticaRendererSession(ABC): | ||
""" | ||
Elastica-renderer should contains the methods below | ||
""" | ||
|
||
@abstractmethod | ||
def add_rods(self): | ||
pass | ||
|
||
@abstractmethod | ||
def add_rigid_body(self): | ||
pass | ||
|
||
@abstractmethod | ||
def add_point(self): | ||
pass | ||
|
Oops, something went wrong.