Skip to content

Commit

Permalink
fix: remove absolute path in module (#44)
Browse files Browse the repository at this point in the history
  • Loading branch information
alonfnt authored Nov 27, 2024
1 parent f2ac00e commit fc1c080
Show file tree
Hide file tree
Showing 8 changed files with 9 additions and 9 deletions.
6 changes: 3 additions & 3 deletions bayex/__init__.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
from bayex.src.optimizer import Optimizer, OptimizerState
from bayex.src import domain
from .optimizer import Optimizer, OptimizerState
from . import domain


__version__ = "0.2.0"
__version__ = "0.2.1c"

__all__ = [
"Optimizer",
Expand Down
2 changes: 1 addition & 1 deletion bayex/src/acq.py → bayex/acq.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import jax.numpy as jnp
from jax.scipy.stats import norm

from bayex.src.gp import GPParams, predict
from bayex.gp import GPParams, predict


def expected_improvement(
Expand Down
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion bayex/src/gp_test.py → bayex/gp_test.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import jax.numpy as jnp
import pytest
from bayex.src.gp import GPParams, gaussian_process, exp_quadratic, cov
from bayex.gp import GPParams, gaussian_process, exp_quadratic, cov

@pytest.mark.parametrize("x1, x2, mask, expected", [
(jnp.array([0]), jnp.array([0]), 1, 1),
Expand Down
4 changes: 2 additions & 2 deletions bayex/src/optimizer.py → bayex/optimizer.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
import jax.numpy as jnp
import numpy as np

import bayex.src.acq as boacq
from bayex.src.gp import GPParams, GPState, posterior_fit
import bayex.acq as boacq
from bayex.gp import GPParams, GPState, posterior_fit


class OptimizerState(NamedTuple):
Expand Down
2 changes: 1 addition & 1 deletion bayex/src/optimizer_test.py → bayex/optimizer_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def f(x):
assert opt_state.best_params['x'] == params['x'][np.argmax(ys)]

assert type(opt_state) == bayex.OptimizerState
assert type(opt_state.gp_state) == bayex.src.gp.GPState # pyright: ignore
assert type(opt_state.gp_state) == bayex.gp.GPState # pyright: ignore

assert opt_state.params['x'].shape == (10,)
assert opt_state.ys.shape == (10,)
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"

[project]
name = "bayex"
version = "0.2.0"
version = "0.2.1c"
description = "Minimal Bayesian Optimization Implementation with Gaussian Processes written in JAX."
readme = "README.md"
requires-python = ">=3.9"
Expand Down

0 comments on commit fc1c080

Please sign in to comment.