#include <bits/stdc++.h>

template <typename InputIterator>
typename InputIterator::value_type summation(InputIterator first,
                                             InputIterator last) {
  return std::accumulate(first, last, typename InputIterator::value_type());
}
template <typename T>
std::istream &operator>>(std::istream &stream, std::vector<T> &v);
template <typename T1, typename T2>
std::istream &operator>>(std::istream &stream, std::pair<T1, T2> &p);
template <typename T>
std::istream &operator>>(std::istream &stream, std::vector<T> &v) {
  for (auto &i : v) {
    stream >> i;
  }
  return stream;
}
template <typename T1, typename T2>
std::istream &operator>>(std::istream &stream, std::pair<T1, T2> &p) {
  stream >> p.first >> p.second;
  return stream;
}
template <typename T>
T modinv(T a, const T m) {
  T b = m, u = 1, v = 0;
  while (b != 0) {
    const auto t = a / b;
    a -= t * b;
    std::swap(a, b);
    u -= t * v;
    std::swap(u, v);
  }
  u %= m;
  if (u < 0) {
    u += m;
  }
  return u;
}

int main() {
  int64_t n;
  std::cin >> n;

  std::vector<std::pair<int64_t, int64_t>> no(n, std::make_pair(-1, -1));
  std::vector<std::set<int64_t>> s(n);

  for (int64_t i = 0; i < n - 1; i++) {
    int64_t a, b;
    std::cin >> a >> b;
    a--;
    b--;
    s[a].insert(b);
    s[b].insert(a);
  }

  std::queue<int64_t> q;
  std::vector<int64_t> deg(n, 0);

  for (int64_t i = 0; i < n; i++) {
    deg[i] = s[i].size();
    if (deg[i] == 1) {
      q.push(i);
    }
  }
  q.pop();

  int64_t ans = 0;
  constexpr int64_t mod = 1000000007;
  while (!q.empty()) {
    const auto i = q.front();
    q.pop();
    if (no[i].first != -1) {
      continue;
    }
    if (s[i].size() == 1) {
      const auto j = *s[i].cbegin();
      if (no[j].first != -1) {
        ans += no[j].second;
        ans %= mod;
        no[i] = std::make_pair(0, 0);
      } else {
        no[i] = std::make_pair(1, 0);
        deg[j] -= 1;
        if (deg[j] <= 1) {
          q.push(j);
        }
      }
    } else {
      std::set<int64_t> done, yet;
      for (const auto j : s[i]) {
        if (no[j].first == -1) {
          yet.insert(j);
        } else {
          done.insert(j);
        }
      }
      if (yet.size() == 1) {
        int64_t prod = 1;
        int64_t first = 0;
        for (const auto j : done) {
          prod *= (no[j].first + 1);
          prod %= mod;
          first += no[j].first;
          first %= mod;
        }
        int64_t val = 0;
        int64_t sum = 0;
        for (const auto j : done) {
          val +=
              (no[j].second * ((prod * modinv(no[j].first + 1, mod) % mod))) %
              mod;
          val %= mod;
          sum += no[j].second;
          sum %= mod;
        }
        ans += val;
        ans %= mod;
        no[i] =
            std::make_pair(prod * 2 - 1, ((val * 2) % mod + prod - 1) % mod);
        if (val < sum) {
          val += mod;
        }
        ans += val - sum + prod - 1 - first;
        ans %= mod;
        const auto j = *yet.cbegin();
        deg[j] -= 1;
        if (deg[j] <= 1) {
          q.push(j);
        }
      }
    }
  }

  int64_t r = 1;
  for (int64_t i = 0; i < n; i++) {
    r *= 2;
    r %= mod;
  }

  /*
  for (const auto &p : no) {
    std::cout << p.first << " " << p.second << std::endl;
  }
  */

  // std::cout << ans << std::endl;
  std::cout << (ans * modinv(r, mod)) % mod << std::endl;
  return 0;
}

Measured memory_bytes: 37224