#include<bits/stdc++.h>
#define MAXN 1010
using namespace std;

typedef long long LL;
const LL INF = (1LL << 60) ;
typedef pair<LL, LL> PII;
typedef pair<PII, int> PIII;
LL dist[MAXN][MAXN][2];
int vis[MAXN][MAXN][2];

int main(){
	int n,p;
	LL X,Y;
	while(scanf("%d%d%lld%lld", &n, &p, &X, &Y) != EOF){
		vector<PII> e[MAXN];
		for(int i = 1; i <= n; i++)
			e[i].clear();
		LL x,y,z;
		for(int i = 0; i < p; i++){
			scanf("%lld%lld%lld", &x, &y, &z);
			e[x].push_back(PII(y, z));
			e[y].push_back(PII(x, z));
		}
		int m;
		scanf("%d", &m);
		int F[MAXN];
		for(int i = 1; i <= n; i++)
			F[i] = 1;
		for(int i = 0; i < m; i++){
			int x;
			scanf("%d", &x);
			F[x] = 0;
		}
		for(int i = 1; i <= n; i++)
			for(int j = 1; j <= n; j++)
				for(int k = 0; k < 2; k++){
					dist[i][j][k] = INF;
					vis[i][j][k] = 0;
				}
		for(int j = 1; j <= n; j++)
			for(int k = 0; k < 2; k++)
				dist[n+1][j][k] = vis[n+1][j][k] = 0;
		queue<PIII> q;
		q.push(PIII(PII(X, 0), 0));
		vis[X][0][0] = 1;
		dist[X][0][0] = 0;
		while(!q.empty()){
			PIII now = q.front();
			LL x = now.first.first;
			LL dep = now.first.second;
			int Wb = now.second;
			vis[x][dep][Wb] = 0;
			q.pop();
			for(int i = 0; i < e[x].size(); i++){
				if (dist[e[x][i].first][dep + 1][Wb | F[e[x][i].first]] > dist[x][dep][Wb] + e[x][i].second){
					dist[e[x][i].first][dep + 1][Wb | F[e[x][i].first]] = dist[x][dep][Wb] + e[x][i].second;
					if (!vis[e[x][i].first][dep + 1][Wb | F[e[x][i].first]]){
						q.push(PIII(PII(e[x][i].first, dep+1), Wb | F[e[x][i].first]));
						vis[e[x][i].first][dep + 1][Wb | F[e[x][i].first]] = 1;
					}
				}
			}
		}
		LL ans = -1;
		for(int i = 1; i < n; i++){
			LL High = INF, Low = 0;
			for(int j = 1; j < i; j++)
				High = min(High, (dist[Y][j][1] - dist[Y][i][0] -1) / (i - j));
			for(int j = i+1; j < n; j++)
				Low = max(Low, (dist[Y][i][0] - dist[Y][j][1]) / (j - i) + 1);
			if (dist[Y][i][0] >= dist[Y][i][1]) 
				High = -1;
			if (High >= Low)
				ans = max(ans, High);
		}
		if (ans==-1) printf("Impossible\n");
		else if (ans>=INF-100000) printf("Infinity\n");
		else printf("%lld\n",ans);
	}
}
