#include<bits/stdc++.h>
#ifdef xay5421
#define D(...) fprintf(stderr,__VA_ARGS__)
#else
#define D(...) ((void)0)
#endif
#define rep(i,a,b) for(int i=(a);i<=(b);++i)
#define per(i,a,b) for(int i=(a);i>=(b);--i)
#define each(x,v) for(auto&x:v)
#define SZ(x) ((int)(x).size())
#define pb push_back
#define eb emplace_back
using namespace std;
using LL=long long;
template<class T>void rd(T&x){
	int f=0,c;
	while(!isdigit(c=getchar()))f^=!(c^45);
	x=(c&15);
	while(isdigit(c=getchar()))x=x*10+(c&15);
	if(f)x=-x;
}
const int P=1e9+7,I=(P+1)>>1;
int ad(int k1,int k2){return k1+k2<P?k1+k2:k1+k2-P;}
int su(int k1,int k2){return k1-k2<0?k1-k2+P:k1-k2;}
void uad(int&k1,int k2){(k1+=k2)>=P&&(k1-=P);}
void usu(int&k1,int k2){(k1-=k2)<0&&(k1+=P);}
int mu(int k1,int k2){return 1LL*k1*k2%P;}
const int N=500005;
int n,m;
vector<int>e[N],E[N];
int dfn[N],low[N],idx,st[N],top,bel[N],cnt,sz[N];
int f0[N],f1[N];
void tarjan(int k1,int k2){
	dfn[k1]=low[k1]=++idx,st[++top]=k1;
	each(x,e[k1])if(x!=k2){
		if(!dfn[x])tarjan(x,k1),low[k1]=min(low[k1],low[x]);
		else low[k1]=min(low[k1],dfn[x]);
	}
	if(low[k1]==dfn[k1]){
		++cnt;
		do{
			++sz[cnt];
			bel[st[top]]=cnt;
		}while(st[top--]!=k1);
	}
}
int dp[N];
int pw[N];
int ans;
void dfs1(int k1,int k2){
	uad(dp[k1],su(pw[sz[k1]],1));
	int w=1,ww=0;
	each(x,E[k1])if(x!=k2){
		dfs1(x,k1);
		w=mu(w,ad(mu(dp[x],I),1));
		uad(ww,mu(dp[x],I));
	}
	usu(w,1);
	uad(dp[k1],mu(pw[sz[k1]],w));
	uad(ans,mu(pw[sz[k1]],su(w,ww)));
	uad(ans,mu(su(pw[sz[k1]],1),ad(ww,1)));
}
int main(){
	freopen("barrack.in","r",stdin);
	freopen("barrack.out","w",stdout);
	pw[0]=1;
	rep(i,1,N-1)pw[i]=ad(pw[i-1],pw[i-1]);
	rd(n),rd(m);
	rep(i,1,m){
		int u,v;
		rd(u),rd(v);
		e[u].pb(v),e[v].pb(u);
	}
	tarjan(1,0);
	rep(u,1,n)each(x,e[u])if(bel[u]!=bel[x])E[bel[u]].pb(bel[x]);
	dfs1(1,0);
	rep(i,1,m)ans=ad(ans,ans);
	printf("%d\n",ans);
	return 0;
}
