WHEN LAUNCHING:
πΏ main ~/github/privacy-filter % opf "Alice was born on 1990-01-02."
Traceback (most recent call last):
File "/opt/homebrew/bin/opf", line 6, in
sys.exit(main())
~~~~^^
File "/Users/luca/github/privacy-filter/opf/main.py", line 209, in main
_run_redaction_command(argv_list)
~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^
File "/Users/luca/github/privacy-filter/opf/main.py", line 136, in _run_redaction_command
result = redactor.redact(text)
File "/Users/luca/github/privacy-filter/opf/_api.py", line 257, in redact
runtime, decoder = self.get_prediction_components(decode=decode)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^
File "/Users/luca/github/privacy-filter/opf/_api.py", line 451, in get_prediction_components
runtime = self.get_runtime()
File "/Users/luca/github/privacy-filter/opf/_api.py", line 405, in get_runtime
self._runtime = load_inference_runtime(
~~~~~~~~~~~~~~~~~~~~~~^
checkpoint=self._checkpoint,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...<4 lines>...
output_mode=self._output_mode,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
)
^
File "/Users/luca/github/privacy-filter/opf/_core/runtime.py", line 231, in load_inference_runtime
model = Transformer.from_checkpoint(
checkpoint,
device=device,
)
File "/Users/luca/github/privacy-filter/opf/_model/model.py", line 1015, in from_checkpoint
model = Transformer(
config=config,
device=device,
)
File "/Users/luca/github/privacy-filter/opf/_model/model.py", line 929, in init
self.embedding = torch.nn.Embedding(
~~~~~~~~~~~~~~~~~~^
config.vocab_size, config.hidden_size, device=device, dtype=param_dtype
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
)
^
File "/opt/homebrew/lib/python3.14/site-packages/torch/nn/modules/sparse.py", line 166, in init
torch.empty((num_embeddings, embedding_dim), **factory_kwargs),
~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/homebrew/lib/python3.14/site-packages/torch/cuda/init.py", line 471, in _lazy_init
raise AssertionError("Torch not compiled with CUDA enabled")
AssertionError: Torch not compiled with CUDA enabled
WHILE:
πΏ main ~/github/privacy-filter % opf --device cpu "Alice was born on 1990-01-02."
Alice was born on <PRIVATE_DATE>.
WHEN LAUNCHING:
πΏ main ~/github/privacy-filter % opf "Alice was born on 1990-01-02."
Traceback (most recent call last):
File "/opt/homebrew/bin/opf", line 6, in
sys.exit(main())
~~~~^^
File "/Users/luca/github/privacy-filter/opf/main.py", line 209, in main
_run_redaction_command(argv_list)
~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^
File "/Users/luca/github/privacy-filter/opf/main.py", line 136, in _run_redaction_command
result = redactor.redact(text)
File "/Users/luca/github/privacy-filter/opf/_api.py", line 257, in redact
runtime, decoder = self.get_prediction_components(decode=decode)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^
File "/Users/luca/github/privacy-filter/opf/_api.py", line 451, in get_prediction_components
runtime = self.get_runtime()
File "/Users/luca/github/privacy-filter/opf/_api.py", line 405, in get_runtime
self._runtime = load_inference_runtime(
~~~~~~~~~~~~~~~~~~~~~~^
checkpoint=self._checkpoint,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...<4 lines>...
output_mode=self._output_mode,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
)
^
File "/Users/luca/github/privacy-filter/opf/_core/runtime.py", line 231, in load_inference_runtime
model = Transformer.from_checkpoint(
checkpoint,
device=device,
)
File "/Users/luca/github/privacy-filter/opf/_model/model.py", line 1015, in from_checkpoint
model = Transformer(
config=config,
device=device,
)
File "/Users/luca/github/privacy-filter/opf/_model/model.py", line 929, in init
self.embedding = torch.nn.Embedding(
~~~~~~~~~~~~~~~~~~^
config.vocab_size, config.hidden_size, device=device, dtype=param_dtype
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
)
^
File "/opt/homebrew/lib/python3.14/site-packages/torch/nn/modules/sparse.py", line 166, in init
torch.empty((num_embeddings, embedding_dim), **factory_kwargs),
~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/homebrew/lib/python3.14/site-packages/torch/cuda/init.py", line 471, in _lazy_init
raise AssertionError("Torch not compiled with CUDA enabled")
AssertionError: Torch not compiled with CUDA enabled
WHILE:
πΏ main ~/github/privacy-filter % opf --device cpu "Alice was born on 1990-01-02."
Alice was born on <PRIVATE_DATE>.