#include <bits/stdc++.h>
using namespace std;
const int N=500000,P=1000000007,v2=500000004;
int Power(int x,int y) {
	int res=1;
	while (y) {
		if (y&1) res=1ll*res*x%P;
		x=1ll*x*x%P,y>>=1;
	}
	return res;
}

int n;
int x[N+9];
vector<int> E[N+9],EE[N+9];
vector<int> id[N+9];

int group[N+9],s,siz[N+9];
int dfn[N+9],low[N+9],stk[N+9],top,ind;
bool flag[N+9];
void tarjan(int now,int lst) {
	dfn[now]=low[now]=++ind,stk[++top]=now,flag[now]=1;
	for (int i=0;i<E[now].size();i++) {
		int nxt=E[now][i];
		if (lst!=i+1) {
			if (!dfn[nxt]) tarjan(nxt,id[now][i]);
			if (flag[nxt]) low[now]=min(low[now],low[nxt]);
		}
	}
	if (dfn[now]==low[now]) {
		s++;
		while (1) {
			int u=stk[top--];
			group[u]=s,siz[s]++,flag[u]=0;
			if (u==now) break;
		}
	}
}

int val[N+9],dp[N+9][3];
void dfs(int now,int lst) {
	val[now]=Power(2,siz[now]);
	dp[now][0]=1,dp[now][1]=0;
	for (auto nxt:EE[now])
		if (nxt!=lst) {
			dfs(nxt,now);
			int g=(1ll*dp[nxt][0]+dp[nxt][2]+1ll*(1ll*dp[nxt][1]*val[nxt]%P)*Power(val[nxt]-1,P-2)%P)%P;
			dp[now][0]=dp[now][0]*(g+1ll)%P;
			dp[now][1]=(1ll*dp[now][1]+g)%P;
		}
	dp[now][0]=(1ll*dp[now][0]-dp[now][1]-1+P)*val[now]%P*1ll*v2%P;
	dp[now][1]=1ll*dp[now][1]*v2%P*(val[now]-1ll)%P;
	dp[now][2]=(val[now]-1ll)*v2%P;
}

int main() {
	freopen("barrack.in","r",stdin);
	freopen("barrack.out","w",stdout);
	int m;
	scanf("%d%d",&n,&m);
	for (int i=1;i<=m;i++) {
		int u,v;
		scanf("%d%d",&u,&v);
		E[u].push_back(v),E[v].push_back(u);
		id[u].push_back(E[v].size()),id[v].push_back(E[u].size());
	}
	tarjan(1,0);
	for (int i=1;i<=n;i++)
		for (auto j:E[i])
			if (group[i]!=group[j]) EE[group[i]].push_back(group[j]);
	dfs(1,0);
	int Ans=0;
	for (int i=1;i<=n;i++) Ans=(1ll*Ans+dp[i][0]+dp[i][1]+dp[i][2])%P;
	Ans=1ll*Ans*Power(2,m+1)%P;
	printf("%d\n",Ans);
	return 0;
}
