![Oracle Drags Its Feet in the JavaScript Trademark Dispute](https://cdn.sanity.io/images/cgdhsj6q/production/919c3b22c24f93884c548d60cbb338e819ff2435-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
迪威智能 SONA 服務專用核心開發套件
$ pip install poetry
$ export PYTHON_KEYRING_BACKEND=keyring.backends.null.Keyring
$ poetry add git+ssh://git@github.com/DeepWaveInc/dwave-sona-core.git
from typing import Dict, List
from loguru import logger
from pydantic import BaseModel, Field
from sona.core.inferencer import InferencerBase
from sona.core.messages import File, Result
class InputParamSchema(BaseModel):
param1: int = Field(42, description="this is the value of param1")
param2: str = Field("43", description="this is the value of param2")
class InputFilesSchema(BaseModel):
origin: str = Field("data/test.mp3", description="this is the value of origin")
class SimpleInferencer(InferencerBase):
name = "mock"
description = "This is a simple inferencer"
input_params_schema = InputParamSchema()
input_files_schema = InputFilesSchema()
def on_load(self) -> None:
logger.info(f"Download {self.__class__.__name__} models...")
def inference(self, params: Dict, files: List[File]) -> Result:
logger.info(f"Get params {params}")
logger.info(f"Get files {files}")
return Result(
files=[File(label="output", path=files[0].path)],
data={"output_key": "output_val"},
)
if __name__ == "__main__":
inferencer = SimpleInferencer()
inferencer.cmd()
$ python simple.py --help
Usage: simple.py [OPTIONS] <filepath:origin>
This is a simple inferencer
Options:
--param2 <string> this is the value of param2
--param1 <integer> this is the value of param1
--help Show this message and exit.
$ python tests/simple.py tests/simple.py
2023-10-17 02:18:41.702 | INFO | __main__:on_load:25 - Download SimpleInferencer models...
2023-10-17 02:18:41.702 | INFO | __main__:inference:28 - Get params {'param2': '43', 'param1': 42}
2023-10-17 02:18:41.703 | INFO | __main__:inference:29 - Get files [File(label='origin', path='tests/simple.py', metadata={})]
{"files":[{"label":"output","path":"tests/simple.py","metadata":{}}],"data":{"output_key":"output_val"}}
FAQs
Unknown package
We found that dwave-sona-core demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.