Rescue workers say 36 people were killed in Oakland, California, in a fire that torched an artist-collective warehouse known locally as the “Ghost Ship.” It may take weeks to identify everyone killed, because the flames have charred some bodies so badly they’ll have to be identified through dental records. The Alameda County Sheriff’s Office has also opened a criminal investigation into what caused the fire. So far, it’s thought to have been an accident—the result of too many people in a place with rampant building-code violations. But already some of the artistic community’s frustration seems aimed at both the warehouse’s artistic leader as well as the Bay Area’s unaffordable rent.

The fire started Friday during a late-night rave being held at the warehouse, home to a couple dozen artists. The blaze grew so quickly that flames and smoke trapped many of the people inside, and forced some to leap out of the second-floor windows. Since firefighters extinguished the flames early Saturday morning, rescue workers have methodically removed bits of ash and debris, putting them in dump trucks to be taken to an offsite location, where they can be sorted and checked in case they contain human remains. It is one of the worst U.S. fires in recent memory, bringing to mind the 2003 blaze in West Warwick, Rhode Island, that killed 100 people at a nightclub called the Station.

The warehouse in Oakland was the subject of many complaints. Last month city officials said they were alerted to illegal construction, but inspectors couldn’t gain access to the site. If they had, they would have seen pianos, couches, beds, wood and fabric partitions closing off artist workspaces, and a staircase made of pallets created by the two dozen people who shared the 10,000-square-foot site.

San Francisco and the greater Bay Area have the some of the highest rents in the country, with the average one-bedroom apartment in Oakland renting for $2,000 per month. That has forced some cities in the area to try and reconcile the rising property costs with the desire to keep a vibrant artistic community. In the meantime, some local artists have created live-and-work spaces inside lofts and warehouses, where a community can share the rent, often at the cost of cramped quarters. “These are people on the fringes of our economy who are just kind of getting by doing what they love and they do get overcrowded in these spaces that are not designed to be residential,” Diego Aguilar-Canabal, who had visited parties at the warehouse, told CNN.

About 40 or 50 people were inside the warehouse when it caught fire at 11:30 p.m. Friday. Smoke quickly filled the building, trapping some people on the second floor. The lights had cut out, one survivor, who identified himself as Chris, told the East Bay Times, and people become jammed on the winding pallet staircase. “When you’re in a burning building, you’re being surrounded by a completely hostile environment,” Chris told the Times. “It was kind of a free-for-all.”

After Chris reached the exit, he said he ran to his car to grab a flashlight. By the time he returned, the smoke made it impossible for him to go back inside. Firefighters arrived within three minutes, but it took four hours to extinguish the flames. As rescue workers dug through the ashes, they found more bodies, and what started as 10 dead, rose to 33 by Sunday, and 36 on Monday. Few people were taken to the hospital with injuries, said Ray Kelly, the Alameda County Sheriff’s Office spokesman, because “people either made it out or didn’t make it out.” In order to help identify those trapped and burned inside, investigators have asked some family members to collect DNA samples from combs and toothbrushes.

The building in Oakland was leased by a man named Derick Ion Almena, who informally ran the collective, and who often hosted parties there to subsidize rent. Almena lived there with his wife and their three children, but that night, because of the music, they’d rented a hotel room. Almena was criticized by members of the community who said they’d warned him previously about the risk of fire.

The warehouse, which had no running water, plumbing, or sprinkler system, and has been described as a labyrinth of flammable materials, had numerous “habitability” complaints lodged against it; the city was investigating those claims. Almena was also criticized for an insensitive Facebook post he made after the fire. In it, he said: “Confirmed. Everything I worked so hard for is gone. Blessed that my children and Micah were at a hotel safe and sound… it’s as if I have awoken from a dream filled with opulence and hope… to be standing now in poverty of self worth.” There was no mention of the victims.

Much of the community is now focused on grieving, and locals started a memorial at a nearby intersection. Kaiser Permanente, which is based in Oakland, said it would donate $50,000 to help those affected by the fire, with matching amounts pledged by the Oakland Athletics, the Golden State Warriors, and the Oakland Raiders, the city’s pro sports teams. Meanwhile, firefighters were sifting Monday through the remains of the warehouse, and the fire battalion chief said the death toll would almost certainly rise.