Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reorganize files after flatten #1678

Merged
merged 2 commits into from
Feb 6, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion stan/math/fwd/meta/operands_and_partials.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#define STAN_MATH_FWD_META_OPERANDS_AND_PARTIALS_HPP

#include <stan/math/prim/fun/Eigen.hpp>
#include <stan/math/prim/meta/size.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <stan/math/prim/meta/broadcast_array.hpp>
#include <stan/math/prim/meta/operands_and_partials.hpp>
#include <stan/math/fwd/core/fvar.hpp>
Expand Down
1 change: 1 addition & 0 deletions stan/math/opencl/prim/bernoulli_logit_glm_lpmf.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
#include <stan/math/prim/err.hpp>
#include <stan/math/prim/fun/Eigen.hpp>
#include <stan/math/prim/fun/constants.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <stan/math/prim/fun/size_zero.hpp>
#include <stan/math/prim/fun/sum.hpp>
#include <stan/math/prim/fun/value_of.hpp>
Expand Down
1 change: 1 addition & 0 deletions stan/math/opencl/prim/neg_binomial_2_log_glm_lpmf.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
#include <stan/math/prim/fun/digamma.hpp>
#include <stan/math/prim/fun/lgamma.hpp>
#include <stan/math/prim/fun/multiply_log.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <stan/math/prim/fun/sum.hpp>
#include <stan/math/prim/fun/value_of_rec.hpp>
#include <stan/math/opencl/copy.hpp>
Expand Down
1 change: 1 addition & 0 deletions stan/math/opencl/prim/normal_id_glm_lpdf.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/err.hpp>
#include <stan/math/prim/fun/constants.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <stan/math/prim/fun/size_zero.hpp>
#include <stan/math/prim/fun/sum.hpp>
#include <stan/math/prim/fun/value_of_rec.hpp>
Expand Down
1 change: 1 addition & 0 deletions stan/math/opencl/prim/ordered_logistic_glm_lpmf.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/err.hpp>
#include <stan/math/prim/fun/log1m_exp.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <stan/math/prim/fun/size_zero.hpp>
#include <stan/math/prim/fun/sum.hpp>
#include <stan/math/prim/fun/value_of_rec.hpp>
Expand Down
1 change: 1 addition & 0 deletions stan/math/opencl/prim/poisson_log_glm_lpmf.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/err.hpp>
#include <stan/math/prim/fun/constants.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <stan/math/prim/fun/size_zero.hpp>
#include <stan/math/prim/fun/sum.hpp>
#include <stan/math/prim/fun/value_of.hpp>
Expand Down
1 change: 1 addition & 0 deletions stan/math/opencl/rev/matrix_cl.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

#include <stan/math/prim/err.hpp>
#include <stan/math/prim/fun/Eigen.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <stan/math/prim/fun/typedefs.hpp>
#include <stan/math/prim/fun/vec_concat.hpp>
#include <stan/math/rev/core.hpp>
Expand Down
3 changes: 3 additions & 0 deletions stan/math/prim/err/check_bounded.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@
#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/err/throw_domain_error.hpp>
#include <stan/math/prim/err/throw_domain_error_vec.hpp>
#include <stan/math/prim/fun/get.hpp>
#include <stan/math/prim/fun/max_size.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <string>

namespace stan {
Expand Down
1 change: 1 addition & 0 deletions stan/math/prim/err/check_consistent_size.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@

#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/err/invalid_argument.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <sstream>
#include <string>

Expand Down
1 change: 1 addition & 0 deletions stan/math/prim/err/check_consistent_size_mvt.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@

#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/err/invalid_argument.hpp>
#include <stan/math/prim/fun/size_mvt.hpp>
#include <sstream>
#include <string>
#include <type_traits>
Expand Down
1 change: 1 addition & 0 deletions stan/math/prim/err/check_consistent_sizes.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@

#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/err/check_consistent_size.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <algorithm>

namespace stan {
Expand Down
2 changes: 1 addition & 1 deletion stan/math/prim/err/check_consistent_sizes_mvt.hpp
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
#ifndef STAN_MATH_PRIM_ERR_CHECK_CONSISTENT_SIZES_MVT_HPP
#define STAN_MATH_PRIM_ERR_CHECK_CONSISTENT_SIZES_MVT_HPP

#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/err/check_consistent_size_mvt.hpp>
#include <stan/math/prim/fun/size_mvt.hpp>
#include <algorithm>

namespace stan {
Expand Down
4 changes: 3 additions & 1 deletion stan/math/prim/err/check_finite.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,11 @@
#include <stan/math/prim/err/is_scal_finite.hpp>
#include <stan/math/prim/err/throw_domain_error.hpp>
#include <stan/math/prim/err/throw_domain_error_vec.hpp>
#include <stan/math/prim/fun/Eigen.hpp>
#include <stan/math/prim/fun/get.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <stan/math/prim/fun/value_of.hpp>
#include <stan/math/prim/fun/value_of_rec.hpp>
#include <stan/math/prim/fun/Eigen.hpp>
#include <cmath>

namespace stan {
Expand Down
2 changes: 2 additions & 0 deletions stan/math/prim/err/check_greater.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/err/throw_domain_error.hpp>
#include <stan/math/prim/err/throw_domain_error_vec.hpp>
#include <stan/math/prim/fun/get.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <functional>
#include <string>

Expand Down
2 changes: 2 additions & 0 deletions stan/math/prim/err/check_greater_or_equal.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/err/throw_domain_error_vec.hpp>
#include <stan/math/prim/err/throw_domain_error.hpp>
#include <stan/math/prim/fun/get.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <string>

namespace stan {
Expand Down
2 changes: 2 additions & 0 deletions stan/math/prim/err/check_less.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/err/throw_domain_error.hpp>
#include <stan/math/prim/err/throw_domain_error_vec.hpp>
#include <stan/math/prim/fun/get.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <functional>
#include <string>

Expand Down
2 changes: 2 additions & 0 deletions stan/math/prim/err/check_less_or_equal.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/err/throw_domain_error.hpp>
#include <stan/math/prim/err/throw_domain_error_vec.hpp>
#include <stan/math/prim/fun/get.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <string>

namespace stan {
Expand Down
2 changes: 2 additions & 0 deletions stan/math/prim/err/check_nonnegative.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/err/throw_domain_error.hpp>
#include <stan/math/prim/err/throw_domain_error_vec.hpp>
#include <stan/math/prim/fun/get.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <type_traits>

namespace stan {
Expand Down
4 changes: 3 additions & 1 deletion stan/math/prim/err/check_not_nan.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,10 @@
#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/err/throw_domain_error.hpp>
#include <stan/math/prim/err/throw_domain_error_vec.hpp>
#include <stan/math/prim/fun/value_of_rec.hpp>
#include <stan/math/prim/fun/get.hpp>
#include <stan/math/prim/fun/is_nan.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <stan/math/prim/fun/value_of_rec.hpp>

namespace stan {
namespace math {
Expand Down
2 changes: 2 additions & 0 deletions stan/math/prim/err/check_positive.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
#include <stan/math/prim/err/throw_domain_error.hpp>
#include <stan/math/prim/err/throw_domain_error_vec.hpp>
#include <stan/math/prim/err/invalid_argument.hpp>
#include <stan/math/prim/fun/get.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <type_traits>
#include <string>

Expand Down
1 change: 1 addition & 0 deletions stan/math/prim/err/invalid_argument_vec.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@

#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/err/invalid_argument.hpp>
#include <stan/math/prim/fun/get.hpp>
#include <sstream>
#include <string>

Expand Down
2 changes: 2 additions & 0 deletions stan/math/prim/err/is_less_or_equal.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
#define STAN_MATH_PRIM_ERR_IS_LESS_OR_EQUAL_HPP

#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/fun/get.hpp>
#include <stan/math/prim/fun/size.hpp>

namespace stan {
namespace math {
Expand Down
4 changes: 3 additions & 1 deletion stan/math/prim/err/is_not_nan.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,10 @@
#define STAN_MATH_PRIM_ERR_IS_NOT_NAN_HPP

#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/fun/value_of_rec.hpp>
#include <stan/math/prim/fun/get.hpp>
#include <stan/math/prim/fun/is_nan.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <stan/math/prim/fun/value_of_rec.hpp>

namespace stan {
namespace math {
Expand Down
2 changes: 2 additions & 0 deletions stan/math/prim/err/is_positive.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
#define STAN_MATH_PRIM_ERR_IS_POSITIVE_HPP

#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/fun/get.hpp>
#include <stan/math/prim/fun/size.hpp>

namespace stan {
namespace math {
Expand Down
2 changes: 2 additions & 0 deletions stan/math/prim/err/is_scal_finite.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
#define STAN_MATH_PRIM_ERR_IS_SCAL_FINITE_HPP

#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/fun/get.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <stan/math/prim/fun/value_of_rec.hpp>
#include <cmath>

Expand Down
1 change: 1 addition & 0 deletions stan/math/prim/err/throw_domain_error_vec.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@

#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/err/throw_domain_error.hpp>
#include <stan/math/prim/fun/get.hpp>
#include <sstream>
#include <string>

Expand Down
6 changes: 5 additions & 1 deletion stan/math/prim/fun.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@
#include <stan/math/prim/fun/cols.hpp>
#include <stan/math/prim/fun/columns_dot_product.hpp>
#include <stan/math/prim/fun/columns_dot_self.hpp>
#include <stan/math/prim/fun/common_type.hpp>
#include <stan/math/prim/fun/constants.hpp>
#include <stan/math/prim/fun/copysign.hpp>
#include <stan/math/prim/fun/corr_constrain.hpp>
Expand Down Expand Up @@ -96,6 +95,7 @@
#include <stan/math/prim/fun/fmin.hpp>
#include <stan/math/prim/fun/gamma_p.hpp>
#include <stan/math/prim/fun/gamma_q.hpp>
#include <stan/math/prim/fun/get.hpp>
#include <stan/math/prim/fun/get_base1.hpp>
#include <stan/math/prim/fun/get_base1_lhs.hpp>
#include <stan/math/prim/fun/get_lp.hpp>
Expand Down Expand Up @@ -183,6 +183,8 @@
#include <stan/math/prim/fun/matrix_exp_multiply.hpp>
#include <stan/math/prim/fun/matrix_power.hpp>
#include <stan/math/prim/fun/max.hpp>
#include <stan/math/prim/fun/max_size.hpp>
#include <stan/math/prim/fun/max_size_mvt.hpp>
#include <stan/math/prim/fun/mdivide_left.hpp>
#include <stan/math/prim/fun/mdivide_left_ldlt.hpp>
#include <stan/math/prim/fun/mdivide_left_spd.hpp>
Expand Down Expand Up @@ -264,6 +266,8 @@
#include <stan/math/prim/fun/sin.hpp>
#include <stan/math/prim/fun/singular_values.hpp>
#include <stan/math/prim/fun/sinh.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <stan/math/prim/fun/size_mvt.hpp>
#include <stan/math/prim/fun/size_zero.hpp>
#include <stan/math/prim/fun/softmax.hpp>
#include <stan/math/prim/fun/sort_asc.hpp>
Expand Down
7 changes: 3 additions & 4 deletions stan/math/prim/meta/get.hpp → stan/math/prim/fun/get.hpp
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
#ifndef STAN_MATH_PRIM_META_GET_HPP
#define STAN_MATH_PRIM_META_GET_HPP
#ifndef STAN_MATH_PRIM_FUN_GET_HPP
#define STAN_MATH_PRIM_FUN_GET_HPP

#include <stan/math/prim/meta/require_generics.hpp>
#include <stan/math/prim/meta/scalar_type.hpp>
#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/fun/Eigen.hpp>
#include <cmath>
#include <cstddef>
Expand Down
1 change: 1 addition & 0 deletions stan/math/prim/fun/gp_exponential_cov.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
#include <stan/math/prim/fun/distance.hpp>
#include <stan/math/prim/fun/divide_columns.hpp>
#include <stan/math/prim/fun/Eigen.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <stan/math/prim/fun/square.hpp>
#include <cmath>
#include <vector>
Expand Down
1 change: 1 addition & 0 deletions stan/math/prim/fun/gp_matern32_cov.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
#include <stan/math/prim/fun/divide.hpp>
#include <stan/math/prim/fun/divide_columns.hpp>
#include <stan/math/prim/fun/distance.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <stan/math/prim/fun/square.hpp>
#include <stan/math/prim/fun/squared_distance.hpp>
#include <cmath>
Expand Down
1 change: 1 addition & 0 deletions stan/math/prim/fun/log_mix.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
#include <stan/math/prim/fun/log.hpp>
#include <stan/math/prim/fun/log1m.hpp>
#include <stan/math/prim/fun/log_sum_exp.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <stan/math/prim/fun/value_of.hpp>
#include <vector>
#include <cmath>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#ifndef STAN_MATH_PRIM_META_MAX_SIZE_HPP
#define STAN_MATH_PRIM_META_MAX_SIZE_HPP
#ifndef STAN_MATH_PRIM_FUN_MAX_SIZE_HPP
#define STAN_MATH_PRIM_FUN_MAX_SIZE_HPP

#include <stan/math/prim/meta/size.hpp>
#include <stan/math/prim/fun/size.hpp>

namespace stan {
namespace math {
Expand Down Expand Up @@ -40,6 +40,7 @@ size_t max_size(const T1& x1, const T2& x2, const T3& x3, const T4& x4,
result = result > size(x5) ? result : size(x5);
return result;
}

} // namespace math
} // namespace stan
#endif
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#ifndef STAN_MATH_PRIM_META_MAX_SIZE_MVT_HPP
#define STAN_MATH_PRIM_META_MAX_SIZE_MVT_HPP
#ifndef STAN_MATH_PRIM_FUN_MAX_SIZE_MVT_HPP
#define STAN_MATH_PRIM_FUN_MAX_SIZE_MVT_HPP

#include <stan/math/prim/meta/size_mvt.hpp>
#include <stan/math/prim/fun/size_mvt.hpp>
#include <cstdlib>

namespace stan {
Expand Down Expand Up @@ -30,6 +30,7 @@ size_t max_size_mvt(const T1& x1, const T2& x2, const T3& x3, const T4& x4) {
result = result > size_mvt(x4) ? result : size_mvt(x4);
return result;
}

} // namespace math
} // namespace stan
#endif
2 changes: 1 addition & 1 deletion stan/math/prim/fun/promote_common.hpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#ifndef STAN_MATH_PRIM_FUN_PROMOTE_COMMON_HPP
#define STAN_MATH_PRIM_FUN_PROMOTE_COMMON_HPP

#include <stan/math/prim/fun/common_type.hpp>
#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/fun/promote_elements.hpp>

namespace stan {
Expand Down
8 changes: 5 additions & 3 deletions stan/math/prim/meta/size.hpp → stan/math/prim/fun/size.hpp
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
#ifndef STAN_MATH_PRIM_META_SIZE_HPP
#define STAN_MATH_PRIM_META_SIZE_HPP
#ifndef STAN_MATH_PRIM_FUN_SIZE_HPP
#define STAN_MATH_PRIM_FUN_SIZE_HPP

#include <stan/math/prim/meta/require_generics.hpp>
#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/fun/Eigen.hpp>
#include <cstdlib>
#include <vector>

namespace stan {
namespace math {

/** \ingroup type_trait
* Returns the length of primitive scalar types
* that are always of length 1.
Expand All @@ -27,6 +28,7 @@ template <typename T, typename = require_not_stan_scalar_t<T>, typename = void>
inline size_t size(const T& m) {
return m.size();
}

} // namespace math
} // namespace stan
#endif
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@

#ifndef STAN_MATH_PRIM_META_SIZE_MVT_HPP
#define STAN_MATH_PRIM_META_SIZE_MVT_HPP
#ifndef STAN_MATH_PRIM_FUN_SIZE_MVT_HPP
#define STAN_MATH_PRIM_FUN_SIZE_MVT_HPP

#include <stan/math/prim/fun/Eigen.hpp>
#include <stdexcept>
Expand Down
1 change: 1 addition & 0 deletions stan/math/prim/functor/coupled_ode_system.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
#define STAN_MATH_PRIM_FUNCTOR_COUPLED_ODE_SYSTEM_HPP

#include <stan/math/prim/err.hpp>
#include <stan/math/prim/fun/size.hpp>
#include <ostream>
#include <vector>

Expand Down
Loading