Skip to content

Commit

Permalink
AWS Neuron SDK 2.16.1: update neuronxcc (#449)
Browse files Browse the repository at this point in the history
* fix(decoder): no need to set model type when exporting

* chore: bump neuronx-cc version

* chore: store AWS Neuron SDK version
  • Loading branch information
dacorvo authored Jan 31, 2024
1 parent de5752d commit c345de4
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 5 deletions.
3 changes: 0 additions & 3 deletions optimum/neuron/modeling_decoder.py
Original file line number Diff line number Diff line change
Expand Up @@ -123,14 +123,11 @@ def __init__(
neuronx_model.load(compiled_dir)

# Compile the Neuron model (if present compiled artifacts will be reloaded instead of compiled)
neuron_cc_flags = os.environ.get("NEURON_CC_FLAGS", "")
os.environ["NEURON_CC_FLAGS"] = neuron_cc_flags + " --model-type=transformer"
checkpoint_id = neuron_config.get("checkpoint_id", None)
# Only create a cache entry if the model comes from the hub
cache_entry = None if checkpoint_id is None else ModelCacheEntry(checkpoint_id, config)
with hub_neuronx_cache(entry=cache_entry):
neuronx_model.to_neuron()
os.environ["NEURON_CC_FLAGS"] = neuron_cc_flags

super().__init__(neuronx_model, config)

Expand Down
2 changes: 2 additions & 0 deletions optimum/neuron/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,5 @@
# limitations under the License.

__version__ = "0.0.18.dev0"

__sdk_version__ = "2.16.1"
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@
],
"neuronx": [
"wheel",
"neuronx-cc==2.12.54.0",
"neuronx-cc==2.12.68.0",
"torch-neuronx==1.13.1.1.13.0",
"transformers-neuronx==0.9.474",
"torch==1.13.1.*",
Expand Down
2 changes: 1 addition & 1 deletion text-generation-inference/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ RUN apt-get update -y \
ENV PATH="/opt/bin/:/opt/aws/neuron/bin:${PATH}"

RUN pip3 install \
neuronx-cc==2.12.54.0 \
neuronx-cc==2.12.68.0 \
torch-neuronx==1.13.1.1.13.0 \
transformers-neuronx==0.9.474 \
--extra-index-url=https://pip.repos.neuron.amazonaws.com
Expand Down

0 comments on commit c345de4

Please sign in to comment.