shyamsn97/mario-gpt

Doesn't works

zwobot1980 opened this issue · 3 comments

Hi, i did try to use your exemple but it doesnt works. See the message on the screenshot.
Mario-GPT

you example script

from mario_gpt.lm import MarioLM
from mario_gpt.utils import view_level, convert_level_to_png

pretrained_model = shyamsn97/Mario-GPT2-700-context-length

mario_lm = MarioLM()

prompts = ["many pipes, many enemies, many blocks, high elevation"]

generate level of size 700, pump temperature up to ~2.4 for more stochastic but playable levels

generated_level = mario_lm.sample(
prompts=prompts,
num_steps=700,
temperature=2.0,
use_tqdm=True
)

show string list

view_level(generated_level, mario_lm.tokenizer)
convert_level_to_png(generated_level, "generated_level.png", mario_lm.tokenizer)

Hey! In the works to update the pypi package. Right now you can either use num_steps = ((anything divisible by 14) - 1) or you can install the package from source

Should be working now, feel free to open another issue if theres additional errors!