Skip to content

Commit

Permalink
load f06 fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Steve Doyle committed Dec 5, 2024
1 parent 2b78dfc commit a07f8b7
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions pyNastran/f06/gui_flutter.py
Original file line number Diff line number Diff line change
Expand Up @@ -1288,8 +1288,8 @@ def _to_str(value: Optional[int | float]) -> str:

def load_f06_op2(f06_filename: str, log: SimpleLogger,
f06_units: str,
out_units: str) -> list[FlutterResponse]:
responses = []
out_units: str) -> dict[int, FlutterResponse]:
responses = {}
ext = os.path.splitext(f06_filename)[1].lower()
if ext == '.f06':
try:
Expand All @@ -1301,7 +1301,12 @@ def load_f06_op2(f06_filename: str, log: SimpleLogger,
log.error(str(e))
return responses
elif ext == '.op2':
from pyNastran.op2.op2 import OP2
try:
from pyNastran.op2.op2 import OP2
except ImportError as e:
log.error(str(e))
return responses

model = OP2(log=log)
results_to_include = ['eigenvectors']
model.set_results(results_to_include)
Expand Down

0 comments on commit a07f8b7

Please sign in to comment.