<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def owl_str_to_model(owl_str):
 """Return a BioPAX model object from an OWL string. Parameters owl_str : str The model as an OWL string. Returns ------- biopax_model : org.biopax.paxtools.model.Model A BioPAX model object (java object). """

    io_class = autoclass('org.biopax.paxtools.io.SimpleIOHandler')
    io = io_class(autoclass('org.biopax.paxtools.model.BioPAXLevel').L3)
    bais = autoclass('java.io.ByteArrayInputStream')
    scs = autoclass('java.nio.charset.StandardCharsets')
    jstr = autoclass('java.lang.String')
    istream = bais(owl_str)
    biopax_model = io.convertFromOWL(istream)
    return biopax_model