Skip to content

Commit

Permalink
Merge branch 'claudioperez:master' into master
Browse files Browse the repository at this point in the history
  • Loading branch information
claudioperez authored Aug 28, 2024
2 parents 12290a4 + df87e62 commit a7f4a1b
Show file tree
Hide file tree
Showing 6 changed files with 40 additions and 4 deletions.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "opensees"
version = "0.0.62"
version = "0.0.65"
authors = [
{name="Claudio M. Perez"}
# <50180406+claudioperez@users.noreply.github.com>"
Expand Down
8 changes: 7 additions & 1 deletion src/opensees/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
__version__ = "0.0.61"
#===----------------------------------------------------------------------===#
#
# STAIRLab -- STructural Artificial Intelligence Laboratory
#
#===----------------------------------------------------------------------===#
#
__version__ = "0.0.65"

# Imports for this module
import math
Expand Down
8 changes: 8 additions & 0 deletions src/opensees/__main__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
#!/usr/bin/env python3
#===----------------------------------------------------------------------===#
#
# STAIRLab -- STructural Artificial Intelligence Laboratory
#
#===----------------------------------------------------------------------===#
#
"""
This file implements the primary command line interface for
the package which is invoked by running:
Expand Down Expand Up @@ -31,6 +37,8 @@
-v/--verbose
--no-load Do not pre-load the OpenSeesRT library.
"""

"""
Expand Down
17 changes: 15 additions & 2 deletions src/opensees/openseespy.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
#===----------------------------------------------------------------------===#
#
# STAIRLab -- STructural Artificial Intelligence Laboratory
# Berkeley, CA
#
#===----------------------------------------------------------------------===#
#
"""
This module implements the OpenSeesPy interface.
Imports can be performed exactly as one would
Expand Down Expand Up @@ -399,8 +406,14 @@ def setFactor(self, factor):

def element(self, type, tag, *args, **kwds):
if tag is None:
tag = 0
for existing_tag in self.getEleTags():
tag = 1
ele_tags = self.getEleTags()
if ele_tags is None:
ele_tags = []
elif isinstance(ele_tags, int):
ele_tags = [ele_tags]

for existing_tag in ele_tags:
if tag <= existing_tag:
tag = existing_tag + 1

Expand Down
2 changes: 2 additions & 0 deletions src/opensees/series.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@


import math

def triangle(t, period=2*math.pi, amplitude=2.0):
Expand Down
7 changes: 7 additions & 0 deletions src/opensees/tcl.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
#===----------------------------------------------------------------------===#
#
# STAIRLab -- STructural Artificial Intelligence Laboratory
# Berkeley, CA
#
#===----------------------------------------------------------------------===#
#
import os
import sys
import json
Expand Down

0 comments on commit a7f4a1b

Please sign in to comment.